Closed Bug 1170421 Opened 7 years ago Closed 7 years ago
fontconfig platform fontlist should return actual default font not serif
The code in gfxFcPlatformFontList::GetDefaultFont currently returns the default serif face for x-western. It should return whatever fontconfig suggests is the first non-scalable font to use for a given language.
Use the code in FindGenericFamily to determine the default font for a given language by passing in a fake family name ("-moz-default") and using the first font it suggests.
Attachment #8613866 - Flags: review?(karlt)
Comment on attachment 8613866 [details] [diff] [review] patch, use the first font fontconfig suggests as the default font For when the configured UI font doesn't exist. https://bugzilla.mozilla.org/show_bug.cgi?id=1165179#c18 >+ // Get the default font by using a fake name to retrieve the first >+ // non-scalable font that fontconfig suggests for the given language. Please remove "non-", as it will find a scalable font.
Attachment #8613866 - Flags: review?(karlt) → review+
Since I'm about to leave for a week, I just grabbed an early build from treeherder. There, the problem is fixed, I get sans-serif fonts now again on this machine. Looks all good! Thanks!
You need to log in before you can comment on or make changes to this bug.