diff options
author | Allan Sandfeld Jensen <allan.jensen@qt.io> | 2017-05-16 14:59:28 +0200 |
---|---|---|
committer | Allan Sandfeld Jensen <allan.jensen@qt.io> | 2017-05-29 14:09:47 +0000 |
commit | 2a0d96daa8a3aea72172340be1df1029ac38700d (patch) | |
tree | f51ab69140409934b0f06199e6d4e98774106f88 /src/platformsupport/fontdatabases | |
parent | ad8b4ba0145696ad0da3ab9fad0dee9bad6d567a (diff) |
Do not use FT_LOAD_TARGET_LCD when full hinting is requested
In FreeType 2.8.0 FT_LOAD_TARGET_LCD is now a variant of
FT_LOAD_TARGET_LIGHT instead of of FT_LOAD_TARGET_NORMAL. This means
requesting it will get us light hinting.
See https://sourceforge.net/projects/freetype/files/freetype2/2.8
We should just avoid using it all together since we request the LCD
mode separately anyway with FT_RENDER_MODE later.
Change-Id: I9ea2e39a6e9ba25ba11604a194e552fe4240a127
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
Diffstat (limited to 'src/platformsupport/fontdatabases')
-rw-r--r-- | src/platformsupport/fontdatabases/freetype/qfontengine_ft.cpp | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/src/platformsupport/fontdatabases/freetype/qfontengine_ft.cpp b/src/platformsupport/fontdatabases/freetype/qfontengine_ft.cpp index 39b6814a57..64a0ef6fe8 100644 --- a/src/platformsupport/fontdatabases/freetype/qfontengine_ft.cpp +++ b/src/platformsupport/fontdatabases/freetype/qfontengine_ft.cpp @@ -967,15 +967,10 @@ int QFontEngineFT::loadFlags(QGlyphSet *set, GlyphFormat format, int flags, if (format == Format_Mono) { load_target = FT_LOAD_TARGET_MONO; } else if (format == Format_A32) { - if (subpixelType == Subpixel_RGB || subpixelType == Subpixel_BGR) { - if (default_hint_style == HintFull) - load_target = FT_LOAD_TARGET_LCD; + if (subpixelType == Subpixel_RGB || subpixelType == Subpixel_BGR) hsubpixel = true; - } else if (subpixelType == Subpixel_VRGB || subpixelType == Subpixel_VBGR) { - if (default_hint_style == HintFull) - load_target = FT_LOAD_TARGET_LCD_V; + else if (subpixelType == Subpixel_VRGB || subpixelType == Subpixel_VBGR) vfactor = 3; - } } else if (format == Format_ARGB) { #ifdef FT_LOAD_COLOR load_flags |= FT_LOAD_COLOR; |