X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Ffont.cpp;h=7cea86957dc16568c4119de3943a66e9c1c8e5d4;hb=f098a871fc6dc7b61a5aca5581fa327e4124c036;hp=2cab462c04e9eaef76b27066d327cebb15a93396;hpb=48420e9e3f950cfe1e3ced8f8ea92d89671ae8c4;p=libs%2Fgl.git diff --git a/source/font.cpp b/source/font.cpp index 2cab462c..7cea8695 100644 --- a/source/font.cpp +++ b/source/font.cpp @@ -1,3 +1,10 @@ +/* $Id$ + +This file is part of libmspgl +Copyright © 2007 Mikko Rasa, Mikkosoft Productions +Distributed under the LGPL +*/ + #include #include "font.h" #include "texture2d.h" @@ -177,8 +184,8 @@ Font::Glyph::Loader::Loader(Glyph &g): glyph(g) { add("texcoords", &Loader::texcoords); - add("size", &Loader::size); - add("offset", &Loader::offset); + add("size", &Glyph::w, &Glyph::h); + add("offset", &Glyph::off_x, &Glyph::off_y); add("advance", &Glyph::advance); } @@ -190,17 +197,5 @@ void Font::Glyph::Loader::texcoords(float x1, float y1, float x2, float y2) glyph.y2=y2; } -void Font::Glyph::Loader::size(float w, float h) -{ - glyph.w=w; - glyph.h=h; -} - -void Font::Glyph::Loader::offset(float x, float y) -{ - glyph.off_x=x; - glyph.off_y=y; -} - } // namespace GL } // namespace Msp