Thursday, 20 March 2008

Experiment of the day

For the bleeding-edge Safari and Opera users in the audience, I decided to add CSS3 Web Fonts support to the blog, providing a decent set of fallback fonts for readers; I’m currently using the freely-available DejaVu Sans and Inconsolata typefaces, with the stylesheet designed to only download the fonts if they are not locally-installed already. (Most Linux distributions these days at least include the DejaVu fonts; the next version of Debian will include a ttf-inconsolata package as well.)

Friday, 21 March 2008

Web fonts in Safari are funky

As mentioned below, I added a web fonts stylesheet to the blog for users of Safari 3.1 and later; however, there’s a deviation between the specification and Safari’s behavior, it seems. The spec says that you should specify a local font to use if available instead of downloading using the full font name of the local font (e.g. “DejaVu Sans Bold Oblique” or “Inconsolata Medium”), but Safari seems to only work right if you specify the family name (“DejaVu Sans” or “Inconsolata”). I think this is a bug in WebKit, and will file a bug report as soon as I get a password to do so, but the specification may be misleading here.

Update: Bug report filed.