[Fontconfig] Firefox & Typeface Selection
rs at mytum.de
Wed Apr 16 08:30:20 PDT 2014
Jorge Fábregas wrote:
> Their new CSS font-family property is:
> "Helvetica Neue", Helvetica, Arial, sans-serif;
> When I go to Wikipedia, the actual font being rendered is "Nimbus Sans
> L" (confirmed by various Firefox addons I have). This is the 2nd option
> in the CSS property (Helvetica).
> My question is: Since I don't have any of these typefaces, why is the
> 2nd option being selected & not the 1st one (Helvetica Nueue)? Is there
> some notion of "preference" in fontconfig? Or is it a Firefox issue?
> That is, Firefox decided to use the 2nd option and asked fontconfig for it?
FC_DEBUG=1 fc-match "Helvetica Neue, Helvetica, Arial, sans-serif"
give you? (It is unlikely that Firefox executes several distinct
FcFontMatch calls as in your example)
The above command prints the full pattern (with the family names you
gave) after config substitution (i. e. after fontconfig executes all
"pattern" rules that occur in your configuration files), as well as the
font that gets the best score. Maybe the substituted pattern already
tells you why Nimbus Sans L is used with higher precedence on your
machine. I would guess that Deja Vu Sans is only used as "default"
fallback, hence it has not a very prominent position in the substituted
Worringer Str 31 Duesseldorf 40211 DE home: <rs at mytum.de>
+49-179-2981632 icq 16845346 work: <rs at interface-ag.de>
More information about the Fontconfig