<?xml version="1.0"?>
<!DOCTYPE fontconfig SYSTEM "fonts.dtd">

<!-- ~/.fonts/local.conf file for local customization -->

<fontconfig>
	<!-- Setup pixel order. This is set to 'none' because X
	     already knows about LCD pixel order. If it doesn't work, 
	     try changing 'none' to 'rgb' (standard for LCDs -->
	<match target="font">
		<edit mode="assign" name="rgba">
			<const>none</const>
		</edit>
	</match>

	<!-- Enable sub-pixel hinting. This is the real deal -->
	<match target="font">
		<edit mode="assign" name="hinting">
			<bool>true</bool>
		</edit>
	</match>
	
	<!-- Set hinting amount. 'hintfull' is probably ok, but
	     'none', 'hintslight', 'hintmedium' and 'hintfull' are
	     also accepted and should be fairly self explanatory -->
	<match target="font">
		<edit mode="assign" name="hintstyle">
			<const>hintfull</const>
		</edit>
	</match>

	<!-- Enable anti-aliasing. We'll enable the non-patented
	     FreeType autohinter and antialiasing algorithms. The alternative
	     is the patented bytecode interpreter, which is said to look
	     better, but it is not detailed here. -->
	<match target="font">
		<edit mode="assign" name="antialias">
			<bool>true</bool>
		</edit>
	</match>
	<match target="pattern">
		<edit mode="assign" name="autohint">
			<bool>true</bool>
		</edit>
	</match>

	<!-- Disable hinting for bold fonts -->
	<match target="font" name="family">
		<test name="weight" compare="more">
			<const>medium</const>
		</test>
		<edit mode="assign" name="autohint">
			<bool>false</bool>
		</edit>
	</match>
 
	<!-- Change the non TrueType font Helvetica into
	        a TrueType sans-serif font. This is easily reusable
		with other fonts. -->
	<match target="pattern" name="family">
		<test name="family" qual="any">
			<string>Helvetica</string>
		</test>
		<edit mode="assign" name="family">
			<string>sans-serif</string>
		</edit>
	</match>
	
</fontconfig>
