Ignore more build detritus
[platform/upstream/fontconfig.git] / fonts.dtd
1 <!-- This is the Document Type Definition for font configuration files -->
2 <!ELEMENT fontconfig (dir | 
3                       cache | 
4                       include | 
5                       config |
6                       selectfont |
7                       match | 
8                       alias)* >
9
10 <!-- 
11     Add a directory that provides fonts
12 -->
13 <!ELEMENT dir (#PCDATA)>
14 <!ATTLIST dir xml:space (default|preserve) 'preserve'>
15
16 <!--
17     Define the per-user file that holds cache font information.
18
19     If the filename begins with '~', it is replaced with the users
20     home directory path.
21 -->
22 <!ELEMENT cache (#PCDATA)>
23 <!ATTLIST cache xml:space (default|preserve) 'preserve'>
24
25 <!--
26     Reference another configuration file; note that this
27     is another complete font configuration file and not
28     just a file included by the XML parser.
29
30     Set 'ignore_missing' to 'yes' if errors are to be ignored.
31
32     If the filename begins with '~', it is replaced with the users
33     home directory path.
34 -->
35 <!ELEMENT include (#PCDATA)>
36 <!ATTLIST include
37           ignore_missing    (no|yes)            "no"
38           xml:space         (default|preserve)  "preserve">
39
40 <!--
41     Global library configuration data
42  -->
43 <!ELEMENT config (blank|rescan)*>
44
45 <!--
46     Specify the set of Unicode encoding values which
47     represent glyphs that are allowed to contain no
48     data.  With this list, fontconfig can examine
49     fonts for broken glyphs and eliminate them from
50     the set of valid Unicode chars.  This idea
51     was borrowed from Mozilla
52  -->
53 <!ELEMENT blank (int)*>
54
55 <!--
56     Aliases are just a special case for multiple match elements
57
58     They are syntactically equivalent to:
59
60     <match>
61         <test name="family">
62             <string value=[family]/>
63         </test>
64         <edit name="family" mode="prepend">
65             <string value=[prefer]/>
66             ...
67         </edit>
68         <edit name="family" mode="append">
69             <string value=[accept]/>
70             ...
71         </edit>
72         <edit name="family" mode="append_last">
73             <string value=[default]/>
74             ...
75         </edit>
76     </match>
77 -->
78 <!--
79     Periodically rescan the font configuration and
80     directories to synch internal state with filesystem
81  -->
82 <!ELEMENT rescan (int)>
83
84 <!--
85     Edit list of available fonts at startup/reload time
86  -->
87 <!ELEMENT selectfont (rejectfont | acceptfont)* >
88
89 <!ELEMENT rejectfont (glob | pattern)*>
90
91 <!ELEMENT acceptfont (glob | pattern)*>
92
93 <!ELEMENT glob (#PCDATA)>
94
95 <!ELEMENT pattern (patelt)*>
96
97 <!ELEMENT patelt (constant)*>
98 <!ATTLIST patelt
99           name CDATA    #REQUIRED>
100
101 <!ELEMENT constant (int|double|string|matrix|bool|charset|const)>
102
103 <!ELEMENT alias (family*, prefer?, accept?, default?)>
104 <!ELEMENT prefer (family)*>
105 <!ELEMENT accept (family)*>
106 <!ELEMENT default (family)*>
107 <!ELEMENT family (#PCDATA)>
108 <!ATTLIST family xml:space (default|preserve) 'preserve'>
109
110 <!ENTITY % expr 'int|double|string|matrix|bool|charset
111                 |name|const
112                 |or|and|eq|not_eq|less|less_eq|more|more_eq|contains|not_contains
113                 |plus|minus|times|divide|not|if|floor|ceil|round|trunc'>
114
115 <!--
116     Match and edit patterns.
117
118     If 'target' is 'pattern', execute the match before selecting a font.
119     if 'target' is 'font', execute the match on the result of a font
120     selection.
121 -->
122 <!ELEMENT match (test*, edit*)>
123 <!ATTLIST match
124           target (pattern|font) "pattern">
125
126 <!--
127     Match a field in a pattern
128
129     if 'qual' is 'any', then the match succeeds if any value in the field matches.
130     if 'qual' is 'all', then the match succeeds only if all values match.
131     if 'qual' is 'first', then the match succeeds only if the first value matches.
132     if 'qual' is 'not_first', then the match succeeds only if any value other than
133         the first matches.
134     For match elements with target=font, if test 'target' is 'pattern',
135     then the test is applied to the pattern used in matching rather than
136     to the resulting font.
137 -->
138 <!ELEMENT test (%expr;)*>
139 <!ATTLIST test 
140           qual (any|all|first|not_first)    "any"
141           name CDATA        #REQUIRED
142           target (pattern|font|default)         "default"
143           compare (eq|not_eq|less|less_eq|more|more_eq|contains|not_contains)   "eq">
144
145 <!--
146     Edit a field in a pattern
147
148     The enclosed values are used together to edit the list of values
149     associated with 'name'.
150
151     If 'name' matches one of those used in a test element for this match element:
152         if 'mode' is 'assign', replace the matched value.
153         if 'mode' is 'assign_replace', replace all of the values
154         if 'mode' is 'prepend', insert before the matched value
155         if 'mode' is 'append', insert after the matched value
156         if 'mode' is 'prepend_first', insert before all of the values
157         if 'mode' is 'append_last', insert after all of the values
158     If 'name' doesn't match any of those used in a test element:
159         if 'mode' is 'assign' or 'assign_replace, replace all of the values
160         if 'mode' is 'prepend' or 'prepend_first', insert before all of the values
161         if 'mode' is 'append' or 'append_last', insert after all of the values
162 -->
163 <!ELEMENT edit (%expr;)*>
164 <!ATTLIST edit
165           name CDATA        #REQUIRED
166           mode (assign|assign_replace|prepend|append|prepend_first|append_last) "assign"
167           binding (weak|strong|same) "weak">
168
169 <!--
170     Elements of expressions follow
171 -->
172 <!ELEMENT int (#PCDATA)>
173 <!ATTLIST int xml:space (default|preserve) 'preserve'>
174 <!ELEMENT double (#PCDATA)>
175 <!ATTLIST double xml:space (default|preserve) 'preserve'>
176 <!ELEMENT string (#PCDATA)>
177 <!ATTLIST string xml:space (default|preserve) 'preserve'>
178 <!ELEMENT matrix (double,double,double,double)>
179 <!ELEMENT bool (#PCDATA)>
180 <!ELEMENT charset (#PCDATA)>
181 <!ATTLIST charset xml:space (default|preserve) 'preserve'>
182 <!ELEMENT name (#PCDATA)>
183 <!ATTLIST name xml:space (default|preserve) 'preserve'>
184 <!ELEMENT const (#PCDATA)>
185 <!ATTLIST const xml:space (default|preserve) 'preserve'>
186 <!ELEMENT or (%expr;)*>
187 <!ELEMENT and (%expr;)*>
188 <!ELEMENT eq ((%expr;), (%expr;))>
189 <!ELEMENT not_eq ((%expr;), (%expr;))>
190 <!ELEMENT less ((%expr;), (%expr;))>
191 <!ELEMENT less_eq ((%expr;), (%expr;))>
192 <!ELEMENT more ((%expr;), (%expr;))>
193 <!ELEMENT more_eq ((%expr;), (%expr;))>
194 <!ELEMENT contains ((%expr;), (%expr;))>
195 <!ELEMENT not_contains ((%expr;), (%expr;))>
196 <!ELEMENT plus (%expr;)*>
197 <!ELEMENT minus (%expr;)*>
198 <!ELEMENT times (%expr;)*>
199 <!ELEMENT divide (%expr;)*>
200 <!ELEMENT not (%expr;)>
201 <!ELEMENT if ((%expr;), (%expr;), (%expr;))>
202 <!ELEMENT floor (%expr;)>
203 <!ELEMENT ceil (%expr;)>
204 <!ELEMENT round (%expr;)>
205 <!ELEMENT trunc (%expr;)>