Веб-сайт самохостера Lotigara

summaryrefslogtreecommitdiff
path: root/source/core/StarFont.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'source/core/StarFont.cpp')
-rw-r--r--source/core/StarFont.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/source/core/StarFont.cpp b/source/core/StarFont.cpp
index 2c0d6a7..8b531a0 100644
--- a/source/core/StarFont.cpp
+++ b/source/core/StarFont.cpp
@@ -79,7 +79,7 @@ unsigned Font::width(String::Char c) {
return *width;
} else {
FT_Load_Char(m_fontImpl->face, c, FontLoadFlags);
- unsigned newWidth = (m_fontImpl->face->glyph->advance.x + 32) / 64;
+ unsigned newWidth = (m_fontImpl->face->glyph->linearHoriAdvance + 32768) / 65536;
m_widthCache.insert({c, m_pixelSize}, newWidth);
return newWidth;
}