- From: L. David Baron <dbaron@dbaron.org>
- Date: Wed, 22 Aug 2007 11:56:35 -0700
- To: www-style@w3.org
- Message-ID: <20070822185635.GA19736@ridley.dbaron.org>
On Wednesday 2007-08-22 18:17 +0200, Bert Bos wrote: > It used to be that the font APIs on many operating systems weren't rich > enough to put more than two weights in one family. That's no longer the > case, but most browsers still don't seem to recognize any weights other > than 'normal' or 'bold'. Why is that? > > E.g., the fontconfig library on my system finds all three weights of > Gill Sans, but my browser doesn't: > > $ fc-match "Gill Sans:weight=thin:slant=roman" # 100 > GillSansLight.ttf: "Gill Sans" "Light" Firefox has code to handle this. For X11-ish platforms (since you're talking about fontconfig), on the 1.8 branch (Firefox 1.5 and Firefox 2), see: http://bonsai.mozilla.org/cvsblame.cgi?file=/mozilla/gfx/src/gtk/nsFontMetricsXft.cpp&rev=1.69.4.2&mark=1116-1118#1106 http://bonsai.mozilla.org/cvsblame.cgi?file=/mozilla/gfx/src/gtk/nsFontMetricsXft.cpp&rev=1.69.4.2&mark=1116-1118#1106 or on the trunk (for Firefox 3, etc.), see: http://bonsai.mozilla.org/cvsblame.cgi?file=/mozilla/gfx/thebes/src/gfxPangoFonts.cpp&rev=1.94&mark=312-362,388#312 I'm not sure if I have any fonts that I could test this on, though. Are there free fonts that it should work with? -David -- L. David Baron http://dbaron.org/ Mozilla Corporation http://www.mozilla.com/
Received on Wednesday, 22 August 2007 18:56:44 UTC