From: Dmitry Timoshkov Subject: gdi32: Improve detection of symbol charset for old truetype fonts. Message-Id: <20151118141636.114a9b9f.dmitry@baikal.ru> Date: Wed, 18 Nov 2015 14:16:36 +0800 This patch uses same check for symbol charset that get_outline_text_metrics() already does, and allows the font attached to the bug 33117 be correctly recognized as a symbol ttf (like Windows does). Signed-off-by: Dmitry Timoshkov --- dlls/gdi32/freetype.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/dlls/gdi32/freetype.c b/dlls/gdi32/freetype.c index 693a54d..a6c8097 100644 --- a/dlls/gdi32/freetype.c +++ b/dlls/gdi32/freetype.c @@ -1980,7 +1980,6 @@ static inline void get_bitmap_size( FT_Face ft_face, Bitmap_Size *face_size ) static inline void get_fontsig( FT_Face ft_face, FONTSIGNATURE *fs ) { TT_OS2 *os2; - FT_UInt dummy; CHARSETINFO csi; FT_WinFNT_HeaderRec winfnt_header; int i; @@ -1997,10 +1996,10 @@ static inline void get_fontsig( FT_Face ft_face, FONTSIGNATURE *fs ) if (os2->version == 0) { - if (pFT_Get_First_Char( ft_face, &dummy ) < 0x100) - fs->fsCsb[0] = FS_LATIN1; - else + if (os2->usFirstCharIndex >= 0xf000 && os2->usFirstCharIndex < 0xf100) fs->fsCsb[0] = FS_SYMBOL; + else + fs->fsCsb[0] = FS_LATIN1; } else { -- 2.6.3