Rémi Bernon : gdi32: Compare full name before discarding faces.

Alexandre Julliard julliard at winehq.org
Tue Sep 8 15:36:15 CDT 2020


Module: wine
Branch: master
Commit: 74357b7d970b02d628e01ab1b6ee558bee4605b8
URL:    https://source.winehq.org/git/wine.git/?a=commit;h=74357b7d970b02d628e01ab1b6ee558bee4605b8

Author: Rémi Bernon <rbernon at codeweavers.com>
Date:   Mon Sep  7 15:18:59 2020 +0200

gdi32: Compare full name before discarding faces.

Signed-off-by: Rémi Bernon <rbernon at codeweavers.com>
Signed-off-by: Huw Davies <huw at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>

---

 dlls/gdi32/freetype.c   | 2 +-
 dlls/gdi32/tests/font.c | 3 ---
 2 files changed, 1 insertion(+), 4 deletions(-)

diff --git a/dlls/gdi32/freetype.c b/dlls/gdi32/freetype.c
index b40be5b92e..cf53f148ad 100644
--- a/dlls/gdi32/freetype.c
+++ b/dlls/gdi32/freetype.c
@@ -1521,7 +1521,7 @@ static WCHAR *ft_face_get_full_name( FT_Face ft_face, LANGID langid )
 
 static inline BOOL faces_equal( const Face *f1, const Face *f2 )
 {
-    if (strcmpiW( f1->style_name, f2->style_name )) return FALSE;
+    if (strcmpiW( f1->full_name, f2->full_name )) return FALSE;
     if (f1->scalable) return TRUE;
     if (f1->size.y_ppem != f2->size.y_ppem) return FALSE;
     return !memcmp( &f1->fs, &f2->fs, sizeof(f1->fs) );
diff --git a/dlls/gdi32/tests/font.c b/dlls/gdi32/tests/font.c
index b1848a4374..f5c8d4dac3 100644
--- a/dlls/gdi32/tests/font.c
+++ b/dlls/gdi32/tests/font.c
@@ -6984,13 +6984,11 @@ static void test_ttf_names(void)
     strcpy(font.lfFaceName, "Wine TTF Names Long Family1 Ext");
     memset(&efnd, 0, sizeof(efnd));
     EnumFontFamiliesExA(dc, &font, enum_fullname_data_proc, (LPARAM)&efnd, 0);
-    todo_wine
     ok(efnd.total == 2, "EnumFontFamiliesExA found %d fonts, expected 2.\n", efnd.total);
 
     strcpy(font.lfFaceName, "Wine TTF Names Long Family1 Con");
     memset(&efnd, 0, sizeof(efnd));
     EnumFontFamiliesExA(dc, &font, enum_fullname_data_proc, (LPARAM)&efnd, 0);
-    todo_wine
     ok(efnd.total == 2, "EnumFontFamiliesExA found %d fonts, expected 2.\n", efnd.total);
 
     handle_font = CreateFontIndirectA(&font);
@@ -6998,7 +6996,6 @@ static void test_ttf_names(void)
     DeleteObject(handle_font);
 
     ret = RemoveFontResourceExA(ttf_name_bold, FR_PRIVATE, 0);
-    todo_wine
     ok(ret, "RemoveFontResourceEx() failed\n");
 
     DeleteFileA(ttf_name_bold);




More information about the wine-cvs mailing list