[Bug 60087] New: GDI+ cannot find a private font family by its reported name
http://bugs.winehq.org/show_bug.cgi?id=60087 Bug ID: 60087 Summary: GDI+ cannot find a private font family by its reported name Product: Wine Version: 11.14 Hardware: x86-64 OS: Linux Status: UNCONFIRMED Severity: normal Priority: P2 Component: gdiplus Assignee: wine-bugs@list.winehq.org Reporter: brandowlucas@gmail.com Target Milestone: --- Distribution: ArchLinux Created attachment 81608 --> http://bugs.winehq.org/attachment.cgi?id=81608 +timestamp,+tid,+gdiplus,+font When running Adobe Premiere Pro 2025 25.5 with Wine 11.14-14-g84fe968b936, startup fails with the following message after the Adobe Clean fonts have been installed and registered: unable to load operating system font. GDI Status: FontFamilyNotFound Font: Adobe Clean Style The same behavior can be reproduced without Adobe using the existing long font name resource in the GDI+ font tests. After a private font is loaded, `GdipGetFamilyName()` reports its family name, but passing that name and the same collection to `GdipCreateFontFamilyFromName()` returns `FontFamilyNotFound`. The reduced trace shows: trace:gdiplus:GdipGetFamilyName 0000000000837220, 000000000031F9F0, 0 trace:gdiplus:GdipCreateFontFamilyFromName L"wine_3_this_is_a_very_long_name", 0000000000823FC0 000000000031F9E0 trace:font:font_EnumFonts facename = L"wine_3_this_is_a_very_long_name" charset 1 font.c:124: Test failed: GdipCreateFontFamilyFromName failed: 14 `GdipCreateFontFamilyFromName()` currently asks GDI to enumerate the requested name and compares the resulting `LOGFONTW.lfFaceName` with the family names stored in the private collection: if (!wcsicmp(lf.lfFaceName, collection->FontFamilies[i]->FamilyName)) The name returned by GDI can differ from the name stored and reported by GDI+. This causes a valid family in the supplied private collection to be rejected. Steps to reproduce: 1. Add a font with a long family name to a private GDI+ font collection. 2. Obtain its name with `GdipGetFamilyName()`. 3. Pass that name and the same collection to `GdipCreateFontFamilyFromName()`. 4. Observe that unpatched Wine returns `FontFamilyNotFound` with status 14. The candidate patch first compares the requested name with the family names in the supplied collection. It retains the existing comparison with the name returned by GDI as a fallback. The patch also extends `test_long_name()` to exercise this lookup. The new check fails on unpatched Wine in both 32 bit and 64 bit tests: font.c:124: Test failed: GdipCreateFontFamilyFromName failed: 14 The check passes with the candidate patch in both architectures. The complete local font test still has four unrelated metric failures at `font.c:452`, which occur with both the patched and unpatched builds. Application verification confirms that the patch removes the Adobe Clean `FontFamilyNotFound` startup failure. Native Windows test results have not been tested. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
http://bugs.winehq.org/show_bug.cgi?id=60087 --- Comment #1 from brandow <brandowlucas@gmail.com> --- Created attachment 81609 --> http://bugs.winehq.org/attachment.cgi?id=81609 candidate patch -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
http://bugs.winehq.org/show_bug.cgi?id=60087 Ken Sharp <imwellcushtymelike@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords| |patch -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
participants (1)
-
WineHQ Bugzilla