1 <!-- This is the Document Type Definition for font configuration files -->
2 <!ELEMENT fontconfig (dir |
12 Add a directory that provides fonts
14 <!ELEMENT dir (#PCDATA)>
16 prefix (#PCDATA) "default"
17 xml:space (default|preserve) 'preserve'>
20 Define the per-user file that holds cache font information.
22 If the filename begins with '~', it is replaced with the users
25 <!ELEMENT cache (#PCDATA)>
26 <!ATTLIST cache xml:space (default|preserve) 'preserve'>
29 Add a directory that is searched for font cache files.
30 These hold per-directory cache data and are searched in
31 order for each directory. When writing cache files, the first
32 directory which allows the cache file to be created is used.
34 A leading '~' in a directory name is replaced with the users
37 <!ELEMENT cachedir (#PCDATA)>
39 prefix (#PCDATA) "default"
40 xml:space (default|preserve) 'preserve'>
43 Reference another configuration file; note that this
44 is another complete font configuration file and not
45 just a file included by the XML parser.
47 Set 'ignore_missing' to 'yes' if errors are to be ignored.
49 If the filename begins with '~', it is replaced with the users
52 <!ELEMENT include (#PCDATA)>
54 ignore_missing (no|yes) "no"
55 prefix (#PCDATA) "default"
56 deprecated (#PCDATA) "no"
57 xml:space (default|preserve) "preserve">
60 Global library configuration data
62 <!ELEMENT config (blank|rescan)*>
65 Specify the set of Unicode encoding values which
66 represent glyphs that are allowed to contain no
67 data. With this list, fontconfig can examine
68 fonts for broken glyphs and eliminate them from
69 the set of valid Unicode chars. This idea
70 was borrowed from Mozilla
72 <!ELEMENT blank (int|range)*>
75 Aliases are just a special case for multiple match elements
77 They are syntactically equivalent to:
81 <string value=[family]/>
83 <edit name="family" mode="prepend">
84 <string value=[prefer]/>
87 <edit name="family" mode="append">
88 <string value=[accept]/>
91 <edit name="family" mode="append_last">
92 <string value=[default]/>
98 Periodically rescan the font configuration and
99 directories to synch internal state with filesystem
101 <!ELEMENT rescan (int)>
104 Edit list of available fonts at startup/reload time
106 <!ELEMENT selectfont (rejectfont | acceptfont)* >
108 <!ELEMENT rejectfont (glob | pattern)*>
110 <!ELEMENT acceptfont (glob | pattern)*>
112 <!ELEMENT glob (#PCDATA)>
114 <!ELEMENT pattern (patelt)*>
116 <!ENTITY % constant 'int|double|string|matrix|bool|charset|langset|const'>
118 <!ELEMENT patelt (%constant;)*>
120 name CDATA #REQUIRED>
122 <!ELEMENT alias (test?, family*, prefer?, accept?, default?)>
124 binding (weak|strong|same) "weak">
125 <!ELEMENT prefer (family)*>
126 <!ELEMENT accept (family)*>
127 <!ELEMENT default (family)*>
128 <!ELEMENT family (#PCDATA)>
129 <!ATTLIST family xml:space (default|preserve) 'preserve'>
131 <!ENTITY % expr 'int|double|string|matrix|bool|charset|langset
133 |or|and|eq|not_eq|less|less_eq|more|more_eq|contains|not_contains
134 |plus|minus|times|divide|not|if|floor|ceil|round|trunc'>
137 Match and edit patterns.
139 If 'target' is 'pattern', execute the match before selecting a font.
140 if 'target' is 'font', execute the match on the result of a font
143 <!ELEMENT match (test*, edit*)>
145 target (pattern|font|scan) "pattern">
148 Match a field in a pattern
150 if 'qual' is 'any', then the match succeeds if any value in the field matches.
151 if 'qual' is 'all', then the match succeeds only if all values match.
152 if 'qual' is 'first', then the match succeeds only if the first value matches.
153 if 'qual' is 'not_first', then the match succeeds only if any value other than
155 For match elements with target=font, if test 'target' is 'pattern',
156 then the test is applied to the pattern used in matching rather than
157 to the resulting font.
159 Match elements with target=scan are applied as fonts are scanned.
160 They edit the pattern generated from the scanned font and affect
161 what the fontconfig database contains.
163 <!ELEMENT test (%expr;)*>
165 qual (any|all|first|not_first) "any"
167 target (pattern|font|default) "default"
168 ignore-blanks (#PCDATA) "false"
169 compare (eq|not_eq|less|less_eq|more|more_eq|contains|not_contains) "eq">
172 Edit a field in a pattern
174 The enclosed values are used together to edit the list of values
175 associated with 'name'.
177 If 'name' matches one of those used in a test element for this match element:
178 if 'mode' is 'assign', replace the matched value.
179 if 'mode' is 'assign_replace', replace all of the values
180 if 'mode' is 'prepend', insert before the matched value
181 if 'mode' is 'append', insert after the matched value
182 if 'mode' is 'prepend_first', insert before all of the values
183 if 'mode' is 'append_last', insert after all of the values
184 If 'name' doesn't match any of those used in a test element:
185 if 'mode' is 'assign' or 'assign_replace, replace all of the values
186 if 'mode' is 'prepend' or 'prepend_first', insert before all of the values
187 if 'mode' is 'append' or 'append_last', insert after all of the values
189 <!ELEMENT edit (%expr;)*>
192 mode (assign|assign_replace|prepend|append|prepend_first|append_last) "assign"
193 binding (weak|strong|same) "weak">
196 Elements of expressions follow
198 <!ELEMENT int (#PCDATA)>
199 <!ATTLIST int xml:space (default|preserve) 'preserve'>
200 <!ELEMENT double (#PCDATA)>
201 <!ATTLIST double xml:space (default|preserve) 'preserve'>
202 <!ELEMENT string (#PCDATA)>
203 <!ATTLIST string xml:space (default|preserve) 'preserve'>
204 <!ELEMENT matrix (double,double,double,double)>
205 <!ELEMENT bool (#PCDATA)>
206 <!ELEMENT charset (int|range)*>
207 <!ELEMENT range (int,int)>
208 <!ELEMENT langset (string)*>
209 <!ELEMENT name (#PCDATA)>
210 <!ATTLIST name xml:space (default|preserve) 'preserve'>
211 <!ELEMENT const (#PCDATA)>
212 <!ATTLIST const xml:space (default|preserve) 'preserve'>
213 <!ELEMENT or (%expr;)*>
214 <!ELEMENT and (%expr;)*>
215 <!ELEMENT eq ((%expr;), (%expr;))>
216 <!ELEMENT not_eq ((%expr;), (%expr;))>
217 <!ELEMENT less ((%expr;), (%expr;))>
218 <!ELEMENT less_eq ((%expr;), (%expr;))>
219 <!ELEMENT more ((%expr;), (%expr;))>
220 <!ELEMENT more_eq ((%expr;), (%expr;))>
221 <!ELEMENT contains ((%expr;), (%expr;))>
222 <!ELEMENT not_contains ((%expr;), (%expr;))>
223 <!ELEMENT plus (%expr;)*>
224 <!ELEMENT minus (%expr;)*>
225 <!ELEMENT times (%expr;)*>
226 <!ELEMENT divide (%expr;)*>
227 <!ELEMENT not (%expr;)>
228 <!ELEMENT if ((%expr;), (%expr;), (%expr;))>
229 <!ELEMENT floor (%expr;)>
230 <!ELEMENT ceil (%expr;)>
231 <!ELEMENT round (%expr;)>
232 <!ELEMENT trunc (%expr;)>