Ubuntu Edgy and X11 font bogosity

Using Ubuntu Edgy recently. I’d installed the great bitstream vera fonts and could use them in gnome, but could not see them in X applications, in particular emacs.

Turned out that /etc/X11/xorg.conf had a wrong configuration for fonts. It originally said:

Section “Files”
FontPath “/usr/share/X11/fonts/misc”
FontPath “/usr/share/X11/fonts/cyrillic”
FontPath “/usr/share/X11/fonts/100dpi/:unscaled”
FontPath “/usr/share/X11/fonts/75dpi/:unscaled”
FontPath “/usr/share/X11/fonts.Type1”
FontPath “/usr/share/X11/fonts/100dpi”
FontPath “/usr/share/X11/fonts/75dpi”
FontPath “/usr/share/X11/fonts/misc”
# path to defoma fonts
FontPath “/var/lib/defoma/x-ttcidfont-conf.d/dirs/TrueType”
EndSection

Turns out that the directory “/usr/share/X11/fonts” is wrong and should be “/usr/share/fonts/X11”, I changed the section to:

Section “Files”
FontPath “/usr/share/fonts/X11/misc”
FontPath “/usr/share/fonts/X11/cyrillic”
FontPath “/usr/share/fonts/X11/100dpi/:unscaled”
FontPath “/usr/share/fonts/X11/75dpi/:unscaled”
FontPath “/usr/share/fonts/X11/Type1”
FontPath “/usr/share/fonts/X11/100dpi”
FontPath “/usr/share/fonts/X11/75dpi”
FontPath “/usr/share/fonts/X11/misc”
# path to defoma fonts
FontPath “/var/lib/defoma/x-ttcidfont-conf.d/dirs/TrueType”
FontPath “/var/lib/defoma/x-ttcidfont-conf.d/dirs/CID”
EndSection

Then I restarted X. But no go. xlsfonts would still not list the bitstream fonts.
The bitstream fonts were linked to from “/var/lib/defoma/x-ttcidfont-conf.d/dirs/TrueType”. I went into that directory, and ran

$ sudo ttmkfdir -o fonts.dir -d .

Then I restarted X again. And yes, this time xlsfonts could see the bitstream fonts. So the problems were the wrong font paths and the fact that the fonts.dir file had not been created in the defoma directory. It seems that this is a new bug in Edgy.

Advertisements
Post a comment or leave a trackback: Trackback URL.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: