Fixed font glyphs always being 2 pixels larger than they are supposed to be in each dimension, fixed wrong underline offset with some fonts, offset underline and strike through by half of their thickness so their center is positioned correctly, changed glyph and font metrics to use floats instead of ints to support scaling better.

This commit is contained in:
binary1248 2014-08-28 03:39:26 +02:00
parent c36ea074d8
commit b27cbd5036
4 changed files with 58 additions and 56 deletions

View file

@ -51,9 +51,9 @@ public :
////////////////////////////////////////////////////////////
// Member data
////////////////////////////////////////////////////////////
int advance; ///< Offset to move horizontically to the next character
IntRect bounds; ///< Bounding rectangle of the glyph, in coordinates relative to the baseline
IntRect textureRect; ///< Texture coordinates of the glyph inside the font's texture
float advance; ///< Offset to move horizontically to the next character
FloatRect bounds; ///< Bounding rectangle of the glyph, in coordinates relative to the baseline
IntRect textureRect; ///< Texture coordinates of the glyph inside the font's texture
};
} // namespace sf