January 23, 2008
Locating a font’s files by its name
Over the last months I had a problem when browsing sites using the YUI font library. Those sites would have a hard to read monospaced font instead of a variable-width sans-serif one.
Today I decided to find out what was the culprit of this. I started Firebug and inspected the offending CSS. It turned out that they mention the font name clean in their font-family path, and that removing this from the valid families helped restore order among the glyphs. To make this permanent I had to find the offending font and delete it.
xlsfonts | grep -i clean
told me that the subject was “Schumacher Clean”, but not more. After messing around with Fontmatrix (which doesn’t attempt to find the fonts registered with the X server by itself) and GNOME Specimen (which didn’t knew about or refused to tell me the location of a font’s files), this helped:
fc-cat | grep -i clean # showed something like clR6x12.pcf.gz locate clR6x12.pcf.gz # gave me the location sudo rm /usr/share/fonts/misc/clR* # removed all incarnations of the font sudo fc-cache # informed the X server
Once again command-line tools proved to be the solution. Great for me, but quite problematic in a world where more than 99% of users don’t use it (because they don’t know what it is or how to use it productively).