<?xml version="1.0"?>
<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
<fontconfig>
<!--
Copyright (c) 2009, Oracle and/or its affiliates. All rights reserved.

Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice (including the next
paragraph) shall be included in all copies or substantial portions of the
Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL
THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
-->

	<!-- We have enabled full and auto hinting -->
	<match target="font" >
	    <edit mode="assign" name="hinting" >
		<bool>true</bool>
	    </edit>
	</match>
	<match target="font" >
	    <edit mode="assign" name="hintstyle" >
		<const>hintfull</const>
	    </edit>
	</match>
	<match target="font" >
	    <edit mode="assign" name="rgba" >
		<const>none</const>
	    </edit>
	</match>

	<!--
	 Hinting for CJK fonts doesn't yet work as well as for Latin fonts.
	 Some people may want to turn it off:

	<match target="font">
		<test name="lang" compare="contains">
			<string>zh</string>
			<string>ko</string>
			<string>ja</string>
		</test>
		<edit name="hinting" mode="assign">
			<bool>false</bool>
		</edit>
	</match>
	 -->


	<!--
	 Chinese fonts are too light. We want to darken them up.
	 darken_value is an int between 1 and 9 where 1 is a little
	 darker and 9 is very dark. The default is 6.
	 -->

	<match target="font">
	        <test name="lang" compare="contains">
	                <string>zh</string>
	        </test>
	        <edit name="darken" mode="assign">
	                <bool>true</bool>
	        </edit>
	        <edit name="darken_value" mode="assign">
	                <int>6</int>
	        </edit>
	</match>

	<!--
	  To avoid using embedded bitmaps in TrueType fonts
	  put the following rule in your personal ~/.fonts.conf file:

	  <match target="pattern">
	        <edit name="prefer_bitmap">
	                <bool>false</bool>
	        </edit>
	  </match>
	-->
	<match target="pattern">
		<edit name="prefer_bitmap">
			<bool>true</bool>
		</edit>
	</match>
	<match target="font">
		<!-- check to see if the font is roman -->
		<test name="slant">
			<const>roman</const>
		</test>
		<!-- check to see if the pattern requested non-roman -->
		<test target="pattern" name="slant" compare="not_eq">
			<const>roman</const>
		</test>
		<edit name="prefer_bitmap">
			<bool>false</bool>
		</edit>
	</match>
	<!-- Latin fonts should not be used for ASCII characters when using
	     Japanese monospace families -->
	<match target="pattern">
		<test name="family">
			<string>monospace</string>
		</test>
		<test name="lang" compare="eq">
			<string>ja-jp</string>
		</test>
		<edit name="disable_pango_script">
			<bool>true</bool>
		</edit>
	</match>

</fontconfig>
