[Fontconfig] Re: Bug with fc-match

Patrick Lam plam at MIT.EDU
Fri Feb 10 11:36:06 PST 2006

Mike FABIAN wrote:
> There is a similar problem with "spacing". It works fine
> when using "fc-list":
> mfabian at magellan:~$ fc-list :lang=fa:style=Regular:spacing=100
> Courier New:style=Regular,Normal,obyčejné,Standard,Κανονικά,Normaali,Normál,Normale,Standaard,Normalny,Обычный,Normálne,Navadno,thường,Arrunta
> mfabian at magellan:~$

In this case, the FcDefaultSubstitute is adding the following constraint:

        family: "Bitstream Vera Sans"(w) "Verdana"(w) "Arial"(w) "Albany
AMT"(w) "Luxi Sans"(w) "Nimbus Sans L"(w) "Helvetica"(w) "Nachlieli"(w)
"MgOpen Modata"(w) "FreeSans"(w) "Kochi Gothic"(w) "AR PL KaitiM GB"(w)
"AR PL KaitiM Big5"(w)
"MS ゴシック"(w) "Baekmuk Dotum"(w) "SimSun"(w) "sans-serif"(w)
"Roya"(w) "Koodak"(w) "Terafik"(w)

This does not include "Courier New", but it does include "Arial".  This
does match:

$ fc-match/fc-match 'Courier New':lang=fa:style=Regular:spacing=100
Courier_New.ttf: "Courier New" "Regular"

If you want Courier New to match that way, you'll have to modify
fonts.conf.  But you probably shouldn't, since it is trying to match a
sans-serif font by default.  If you try to match a monospace font...

plam at fermat:~/hacks/fontconfig$ fc-match/fc-match
Courier_New.ttf: "Courier New" "Regular"

... then it works as it should.

(FC_DEBUG=3 helps when diagnosing these problems.)


More information about the Fontconfig mailing list