From df81407756227f844d76c50f90f7335a42fb7faa Mon Sep 17 00:00:00 2001 From: yvt Date: Wed, 26 Feb 2014 16:14:15 +0900 Subject: [PATCH] Fallback font is now aligned correctly --- Sources/Client/IFont.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Sources/Client/IFont.cpp b/Sources/Client/IFont.cpp index 4317412b..01bedc52 100644 --- a/Sources/Client/IFont.cpp +++ b/Sources/Client/IFont.cpp @@ -107,7 +107,7 @@ namespace spades { if(s->Read(&fontSize, 4) < 4) { SPRaise("Reading %s: file truncated", path.c_str()); } - fontSize = (float)fontSize; + this->fontSize = (float)fontSize; fontSizeInverse = 1.f / fontSize; std::vector infos; @@ -240,7 +240,6 @@ namespace spades { float newScale = scale <= .8f ? 0.5f : std::max(1.f, floorf(scale)); // vertical-align: baseline - // FIXME: not working correctly offset.y += (scale - newScale) * glyph.size; scale = newScale; }