"Aric Stewart" <[EMAIL PROTECTED]> wrote: > diff --git a/dlls/gdi32/freetype.c b/dlls/gdi32/freetype.c > index 145be9b..c427694 100644 > --- a/dlls/gdi32/freetype.c > +++ b/dlls/gdi32/freetype.c > @@ -3408,8 +3408,8 @@ GdiFont *WineEngCreateFontInstance(DC *dc, HFONT hfont) > */ > LIST_FOR_EACH(family_elem_ptr, &font_list) { > family = LIST_ENTRY(family_elem_ptr, Family, entry); > - if (!strcmpiW(family->FamilyName, FaceName) || > - (psub && !strcmpiW(family->FamilyName, psub->to.name))) > + if (( psub && !strcmpiW(family->FamilyName, psub->to.name)) || > + (!psub && !strcmpiW(family->FamilyName, FaceName))) > { > LIST_FOR_EACH(face_elem_ptr, &family->faces) { > face = LIST_ENTRY(face_elem_ptr, Face, entry);
After loking at this change once more I think it's not correct. It will lead to failures to find a font if there is a substitution but a face specified by substitution doesn't exist. I'd suggest to test what Windows does in that case, and if Windows allows to substitute existing faces at all. Do you have a test cases which passes with your patch but doesn't without it? -- Dmitry.