! From http://johan.kiviniemi.name/blag/2008/01/12/ubuntu-hardy-fonts/
! Needed because cairo cannot read fontconfig's settings, apparently.
! Choices: lcdfilternone, lcdfilterdefault, lcdfilterlight, lcdfilterlegacy
! create ~/.Xresources and put this in it
Xft.lcdfilter: lcdfilterlegacy
Xft.hintstyle: hintfull
!now in a term do
xrdb -merge ~/.Xresources
! if getting blurriy fonts then create ~/.fonts.conf
! Play with the "rgba" setting where the "Blurry fonts" comment is. Then close and
! re-open firefox, to see the change.
! I'm not sure whether lcdfilter set in ~/.fonts.conf takes effect, but it doesn't hurt.
<?xml version="1.0"?>
<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
<fontconfig>
<!-- Info:
xeffects thread: http://forums.gentoo.org/viewtopic-t-511382.html
http://gentoo-wiki.com/HOWTO_Xorg_and_Fonts
http://wiki.archlinux.org/index.php/XOrg_Font_Configuration
http://antigrain.com/research/font_rasterization/index.html
-->
<!-- Blurry fonts: Try rgb, bgr, vrgb, vbgr for "rgba" -->
<match target="font">
<edit name="rgba" mode="assign"><const>rgb</const></edit>
<edit name="autohint" mode="assign"><bool>false</bool></edit>
<edit name="antialias" mode="assign"><bool>true</bool></edit>
<edit name="hinting" mode="assign"><bool>true</bool></edit>
<edit name="hintstyle" mode="assign"><const>hintfull</const></edit>
<edit name="lcdfilter" mode="assign"><const>lcdfilterlegacy</const></edit></edit>
</match>
<!-- Greyscale for small fonts -->
<match target="font">
<test name="size" compare="less_eq"><double>7</double></test>
<edit name="rgba"><const>none</const></edit>
</match>
</fontconfig>