Fix #7032: use the same mode to load and render glyphs

This commit is contained in:
glx 2019-01-17 17:50:54 +01:00 committed by Charles Pigott
parent 6535abb88b
commit 1623cb553b

View File

@ -546,7 +546,7 @@ const Sprite *FreeTypeFontCache::GetGlyph(GlyphID key)
return glyph->sprite;
}
}
FT_Load_Glyph(this->face, key, FT_LOAD_DEFAULT);
FT_Load_Glyph(this->face, key, aa ? FT_LOAD_TARGET_NORMAL : FT_LOAD_TARGET_MONO);
FT_Render_Glyph(this->face->glyph, aa ? FT_RENDER_MODE_NORMAL : FT_RENDER_MODE_MONO);
/* Despite requesting a normal glyph, FreeType may have returned a bitmap */