From c29623539ac1e8d956e23893de5807aa6b5fe901 Mon Sep 17 00:00:00 2001 From: Daria Volvenkova Date: Tue, 17 Jan 2017 17:26:13 +0300 Subject: [PATCH] Large non-sdf text rendering fixed. --- drape_frontend/text_layout.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drape_frontend/text_layout.cpp b/drape_frontend/text_layout.cpp index 219be61367..da11b194ef 100644 --- a/drape_frontend/text_layout.cpp +++ b/drape_frontend/text_layout.cpp @@ -345,9 +345,9 @@ void TextLayout::Init(strings::UniString const & text, float fontSize, bool isSd ref_ptr textures) { m_text = text; - m_textSizeRatio = isSdf ? (fontSize / VisualParams::Instance().GetGlyphBaseSize()) : 1.0; - m_textSizeRatio *= VisualParams::Instance().GetFontScale(); - m_fixedHeight = isSdf ? dp::GlyphManager::kDynamicGlyphSize : fontSize; + double const fontScale = VisualParams::Instance().GetFontScale(); + m_textSizeRatio = isSdf ? (fontSize * fontScale / VisualParams::Instance().GetGlyphBaseSize()) : 1.0; + m_fixedHeight = isSdf ? dp::GlyphManager::kDynamicGlyphSize : fontSize * fontScale; textures->GetGlyphRegions(text, m_fixedHeight, m_metrics); }