diff options
Diffstat (limited to 'src/Text.cpp')
-rw-r--r-- | src/Text.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/Text.cpp b/src/Text.cpp index 3cde45f..3ebd303 100644 --- a/src/Text.cpp +++ b/src/Text.cpp @@ -425,7 +425,7 @@ namespace QuickMedia int vertexStart = vertices[vertices_index].getVertexCount(); EmojiRectangle emoji_rec = emoji_get_extents(codePoint); - const float font_height_offset = -latin_font_height * 1.2f; + const float font_height_offset = std::floor(-latin_font_height * 1.2f); sf::Vector2f vertexTopLeft(glyphPos.x, glyphPos.y + font_height_offset - std::floor(emoji_rec.height * get_ui_scale()) * 0.5f); sf::Vector2f vertexTopRight(glyphPos.x + std::floor(emoji_rec.width * get_ui_scale()), glyphPos.y + font_height_offset - std::floor(emoji_rec.height * get_ui_scale()) * 0.5f); sf::Vector2f vertexBottomLeft(glyphPos.x, glyphPos.y + font_height_offset + emoji_rec.height * get_ui_scale() * 0.5f); |