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)>
15 <!ATTLIST dir xml:space (default|preserve) 'preserve'>
18 Define the per-user file that holds cache font information.
20 If the filename begins with '~', it is replaced with the users
23 <!ELEMENT cache (#PCDATA)>
24 <!ATTLIST cache xml:space (default|preserve) 'preserve'>
27 Add a directory that is searched for font cache files.
28 These hold per-directory cache data and are searched in
29 order for each directory. When writing cache files, the first
30 directory which allows the cache file to be created is used.
32 A leading '~' in a directory name is replaced with the users
35 <!ELEMENT cachedir (#PCDATA)>
36 <!ATTLIST cachedir xml:space (default|preserve) 'preserve'>
39 Reference another configuration file; note that this
40 is another complete font configuration file and not
41 just a file included by the XML parser.
43 Set 'ignore_missing' to 'yes' if errors are to be ignored.
45 If the filename begins with '~', it is replaced with the users
48 <!ELEMENT include (#PCDATA)>
50 ignore_missing (no|yes) "no"
51 xml:space (default|preserve) "preserve">
54 Global library configuration data
56 <!ELEMENT config (blank|rescan)*>
59 Specify the set of Unicode encoding values which
60 represent glyphs that are allowed to contain no
61 data. With this list, fontconfig can examine
62 fonts for broken glyphs and eliminate them from
63 the set of valid Unicode chars. This idea
64 was borrowed from Mozilla
66 <!ELEMENT blank (int)*>
69 Aliases are just a special case for multiple match elements
71 They are syntactically equivalent to:
75 <string value=[family]/>
77 <edit name="family" mode="prepend">
78 <string value=[prefer]/>
81 <edit name="family" mode="append">
82 <string value=[accept]/>
85 <edit name="family" mode="append_last">
86 <string value=[default]/>
92 Periodically rescan the font configuration and
93 directories to synch internal state with filesystem
95 <!ELEMENT rescan (int)>
98 Edit list of available fonts at startup/reload time
100 <!ELEMENT selectfont (rejectfont | acceptfont)* >
102 <!ELEMENT rejectfont (glob | pattern)*>
104 <!ELEMENT acceptfont (glob | pattern)*>
106 <!ELEMENT glob (#PCDATA)>
108 <!ELEMENT pattern (patelt)*>
110 <!ENTITY % constant 'int|double|string|matrix|bool|charset|const'>
112 <!ELEMENT patelt (%constant;)*>
114 name CDATA #REQUIRED>
116 <!ELEMENT alias (family*, prefer?, accept?, default?)>
118 binding (weak|strong|same) "weak">
119 <!ELEMENT prefer (family)*>
120 <!ELEMENT accept (family)*>
121 <!ELEMENT default (family)*>
122 <!ELEMENT family (#PCDATA)>
123 <!ATTLIST family xml:space (default|preserve) 'preserve'>
125 <!ENTITY % expr 'int|double|string|matrix|bool|charset
127 |or|and|eq|not_eq|less|less_eq|more|more_eq|contains|not_contains
128 |plus|minus|times|divide|not|if|floor|ceil|round|trunc'>
131 Match and edit patterns.
133 If 'target' is 'pattern', execute the match before selecting a font.
134 if 'target' is 'font', execute the match on the result of a font
137 <!ELEMENT match (test*, edit*)>
139 target (pattern|font|scan) "pattern">
142 Match a field in a pattern
144 if 'qual' is 'any', then the match succeeds if any value in the field matches.
145 if 'qual' is 'all', then the match succeeds only if all values match.
146 if 'qual' is 'first', then the match succeeds only if the first value matches.
147 if 'qual' is 'not_first', then the match succeeds only if any value other than
149 For match elements with target=font, if test 'target' is 'pattern',
150 then the test is applied to the pattern used in matching rather than
151 to the resulting font.
153 Match elements with target=scan are applied as fonts are scanned.
154 They edit the pattern generated from the scanned font and affect
155 what the fontconfig database contains.
157 <!ELEMENT test (%expr;)*>
159 qual (any|all|first|not_first) "any"
161 target (pattern|font|default) "default"
162 compare (eq|not_eq|less|less_eq|more|more_eq|contains|not_contains) "eq">
165 Edit a field in a pattern
167 The enclosed values are used together to edit the list of values
168 associated with 'name'.
170 If 'name' matches one of those used in a test element for this match element:
171 if 'mode' is 'assign', replace the matched value.
172 if 'mode' is 'assign_replace', replace all of the values
173 if 'mode' is 'prepend', insert before the matched value
174 if 'mode' is 'append', insert after the matched value
175 if 'mode' is 'prepend_first', insert before all of the values
176 if 'mode' is 'append_last', insert after all of the values
177 If 'name' doesn't match any of those used in a test element:
178 if 'mode' is 'assign' or 'assign_replace, replace all of the values
179 if 'mode' is 'prepend' or 'prepend_first', insert before all of the values
180 if 'mode' is 'append' or 'append_last', insert after all of the values
182 <!ELEMENT edit (%expr;)*>
185 mode (assign|assign_replace|prepend|append|prepend_first|append_last) "assign"
186 binding (weak|strong|same) "weak">
189 Elements of expressions follow
191 <!ELEMENT int (#PCDATA)>
192 <!ATTLIST int xml:space (default|preserve) 'preserve'>
193 <!ELEMENT double (#PCDATA)>
194 <!ATTLIST double xml:space (default|preserve) 'preserve'>
195 <!ELEMENT string (#PCDATA)>
196 <!ATTLIST string xml:space (default|preserve) 'preserve'>
197 <!ELEMENT matrix (double,double,double,double)>
198 <!ELEMENT bool (#PCDATA)>
199 <!ELEMENT charset (#PCDATA)>
200 <!ATTLIST charset xml:space (default|preserve) 'preserve'>
201 <!ELEMENT name (#PCDATA)>
202 <!ATTLIST name xml:space (default|preserve) 'preserve'>
203 <!ELEMENT const (#PCDATA)>
204 <!ATTLIST const xml:space (default|preserve) 'preserve'>
205 <!ELEMENT or (%expr;)*>
206 <!ELEMENT and (%expr;)*>
207 <!ELEMENT eq ((%expr;), (%expr;))>
208 <!ELEMENT not_eq ((%expr;), (%expr;))>
209 <!ELEMENT less ((%expr;), (%expr;))>
210 <!ELEMENT less_eq ((%expr;), (%expr;))>
211 <!ELEMENT more ((%expr;), (%expr;))>
212 <!ELEMENT more_eq ((%expr;), (%expr;))>
213 <!ELEMENT contains ((%expr;), (%expr;))>
214 <!ELEMENT not_contains ((%expr;), (%expr;))>
215 <!ELEMENT plus (%expr;)*>
216 <!ELEMENT minus (%expr;)*>
217 <!ELEMENT times (%expr;)*>
218 <!ELEMENT divide (%expr;)*>
219 <!ELEMENT not (%expr;)>
220 <!ELEMENT if ((%expr;), (%expr;), (%expr;))>
221 <!ELEMENT floor (%expr;)>
222 <!ELEMENT ceil (%expr;)>
223 <!ELEMENT round (%expr;)>
224 <!ELEMENT trunc (%expr;)>