Avoid Freetype synthesizing for large font sizes
Freetype's fake emboldening does not give good results for large font sizes. Pick-to: 5.15 Fixes: QTBUG-84570 Change-Id: I1a7722c1482e3450e5a549c31c9766d930fcd13a Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
This commit is contained in:
parent
b862788e62
commit
f5c132ef28
@ -750,7 +750,7 @@ bool QFontEngineFT::init(FaceId faceId, bool antialias, GlyphFormat format,
|
||||
// fake bold
|
||||
if ((fontDef.weight >= QFont::Bold) && !(face->style_flags & FT_STYLE_FLAG_BOLD) && !FT_IS_FIXED_WIDTH(face) && !qEnvironmentVariableIsSet("QT_NO_SYNTHESIZED_BOLD")) {
|
||||
if (const TT_OS2 *os2 = reinterpret_cast<const TT_OS2 *>(FT_Get_Sfnt_Table(face, ft_sfnt_os2))) {
|
||||
if (os2->usWeightClass < 700)
|
||||
if (os2->usWeightClass < 700 && fontDef.pixelSize < 64)
|
||||
embolden = true;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user