patrick@0
|
1 |
# $Id$
|
patrick@0
|
2 |
|
patrick@0
|
3 |
start = publidoc
|
patrick@0
|
4 |
|
patrick@0
|
5 |
|
patrick@0
|
6 |
publidoc = element publidoc {
|
patrick@0
|
7 |
publidoc.attributes,
|
patrick@0
|
8 |
publidoc.content
|
patrick@0
|
9 |
}
|
patrick@0
|
10 |
|
patrick@0
|
11 |
publidoc.attributes =
|
patrick@0
|
12 |
version.attribute
|
patrick@0
|
13 |
version.attribute = attribute version { "1.0" }
|
patrick@0
|
14 |
|
patrick@0
|
15 |
publidoc.content =
|
patrick@0
|
16 |
document
|
patrick@0
|
17 |
| top.topic
|
Coraline@419
|
18 |
| glossary
|
patrick@0
|
19 |
|
patrick@0
|
20 |
# =============================================================================
|
Patrick@310
|
21 |
# HEAD LEVEL
|
Patrick@310
|
22 |
# =============================================================================
|
Patrick@310
|
23 |
|
Patrick@310
|
24 |
# ~~~~~~~~~~~~~~~~~~~~~~~ title, shorttitle, subtitle ~~~~~~~~~~~~~~~~~~~~~~~~~
|
Patrick@310
|
25 |
|
Patrick@310
|
26 |
title = element title { title.content }
|
Patrick@310
|
27 |
shorttitle = element shorttitle { title.content }
|
Patrick@310
|
28 |
subtitle = element subtitle { title.content }
|
Patrick@310
|
29 |
|
Patrick@310
|
30 |
title.content = inlines
|
Patrick@310
|
31 |
|
Patrick@310
|
32 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ identifier ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Patrick@310
|
33 |
|
Patrick@310
|
34 |
# ~~~~~~ identifier
|
Patrick@310
|
35 |
identifier = element identifier {
|
Patrick@310
|
36 |
(attribute type { "ean" }, for.attribute?, xsd:token {pattern = "\d{13}"})
|
Patrick@310
|
37 |
| (attribute type { "uri" }, for.attribute?, xsd:anyURI)
|
Patrick@310
|
38 |
}
|
Patrick@310
|
39 |
|
Patrick@310
|
40 |
# ~~~~~~ identifier.ean
|
Patrick@310
|
41 |
identifier.ean = element identifier {
|
Patrick@310
|
42 |
attribute type { "ean" }, for.attribute?, xsd:token {pattern = "\d{13}"}
|
Patrick@310
|
43 |
}
|
Patrick@310
|
44 |
|
Patrick@310
|
45 |
# ~~~~~~ identifier.uri
|
Patrick@310
|
46 |
identifier.uri = element identifier {
|
Patrick@310
|
47 |
attribute type { "uri" }, for.attribute?, xsd:anyURI
|
Patrick@310
|
48 |
}
|
Patrick@310
|
49 |
|
Patrick@310
|
50 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ copyright ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Patrick@310
|
51 |
|
Patrick@310
|
52 |
copyright = element copyright { copyright.content }
|
Patrick@310
|
53 |
|
Patrick@310
|
54 |
copyright.content = simple.inlines
|
Patrick@310
|
55 |
|
Patrick@310
|
56 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ collection ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Patrick@310
|
57 |
|
Patrick@310
|
58 |
collection = element collection { collection.content }
|
Patrick@310
|
59 |
|
Patrick@310
|
60 |
collection.content = simple.inlines
|
Patrick@310
|
61 |
|
Patrick@310
|
62 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ contributors ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Patrick@310
|
63 |
|
Patrick@310
|
64 |
# ~~~~~~ contributors
|
Patrick@310
|
65 |
contributors = element contributors { contributors.content }
|
Patrick@310
|
66 |
|
Patrick@310
|
67 |
contributors.content =
|
Patrick@310
|
68 |
contributor+
|
Patrick@310
|
69 |
|
Patrick@310
|
70 |
# ~~~~~~ contributor
|
Patrick@310
|
71 |
contributor = element contributor { contributor.content }
|
Patrick@310
|
72 |
|
Patrick@310
|
73 |
contributor.content =
|
Patrick@310
|
74 |
identifier.uri?,
|
Patrick@350
|
75 |
((firstname?, lastname) | label),
|
Patrick@310
|
76 |
address?,
|
Patrick@310
|
77 |
link?,
|
Patrick@310
|
78 |
role+
|
Patrick@310
|
79 |
|
Patrick@310
|
80 |
# ~~~~~~ firstname, secondname, lastname, label
|
Patrick@310
|
81 |
firstname = element firstname { firstname.content }
|
Patrick@310
|
82 |
lastname = element lastname { lastname.content }
|
Patrick@310
|
83 |
label = element label { label.content }
|
Patrick@310
|
84 |
|
Patrick@310
|
85 |
firstname.content = simple.inlines
|
Patrick@310
|
86 |
lastname.content = simple.inlines
|
Patrick@310
|
87 |
label.content = simple.inlines
|
Patrick@310
|
88 |
|
Patrick@310
|
89 |
# ~~~~~~ address
|
Patrick@310
|
90 |
address = element address { address.content }
|
Patrick@310
|
91 |
|
Patrick@310
|
92 |
address.content = simple.inlines
|
Patrick@310
|
93 |
|
Patrick@310
|
94 |
# ~~~~~~ role
|
Patrick@310
|
95 |
role = element role { role.content }
|
Patrick@310
|
96 |
|
Patrick@310
|
97 |
role.content = "author" | "illustrator" | "publisher" | "packager"
|
Coraline@416
|
98 |
| "translator"
|
Patrick@310
|
99 |
|
Patrick@310
|
100 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ place ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Patrick@310
|
101 |
|
Patrick@310
|
102 |
place = element place { place.content }
|
Patrick@310
|
103 |
|
Patrick@310
|
104 |
place.content = simple.inlines
|
Patrick@310
|
105 |
|
Patrick@310
|
106 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ source ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Patrick@310
|
107 |
|
Patrick@310
|
108 |
source = element source {
|
Patrick@310
|
109 |
( (attribute type { "book" }, bibliography.entry.content)
|
Patrick@310
|
110 |
| (attribute type { "file" }, source.content.file)),
|
Patrick@310
|
111 |
source.content
|
Patrick@310
|
112 |
}
|
Patrick@310
|
113 |
|
Patrick@310
|
114 |
source.content.file =
|
Patrick@310
|
115 |
identifier.uri
|
Patrick@310
|
116 |
source.content =
|
Patrick@364
|
117 |
annotation?
|
Patrick@310
|
118 |
|
Patrick@310
|
119 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ keyword & subject ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Patrick@310
|
120 |
|
Patrick@310
|
121 |
# ~~~~~~ keywordset
|
Patrick@310
|
122 |
keywordset = element keywordset { keywordset.content }
|
Patrick@310
|
123 |
|
Patrick@310
|
124 |
keywordset.content = keyword+
|
Patrick@310
|
125 |
|
Patrick@310
|
126 |
# ~~~~~~ keyword
|
Patrick@310
|
127 |
keyword = element keyword { keyword.content }
|
Patrick@310
|
128 |
|
Patrick@310
|
129 |
keyword.content = simple.inlines
|
Patrick@310
|
130 |
|
Patrick@310
|
131 |
# ~~~~~~ subjectset
|
Patrick@310
|
132 |
subjectset = element subjectset { subjectset.content }
|
Patrick@310
|
133 |
|
Patrick@310
|
134 |
subjectset.content = subject+
|
Patrick@310
|
135 |
|
Patrick@310
|
136 |
# ~~~~~~ subject
|
Patrick@310
|
137 |
subject = element subject { subject.content }
|
Patrick@310
|
138 |
|
Patrick@310
|
139 |
subject.content = simple.inlines
|
Patrick@310
|
140 |
|
Patrick@310
|
141 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ index ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Patrick@310
|
142 |
|
Patrick@355
|
143 |
# ~~~~~~ indexset
|
Patrick@355
|
144 |
indexset = element indexset { indexset.content }
|
Patrick@355
|
145 |
|
Patrick@355
|
146 |
indexset.content = head.index+
|
Patrick@355
|
147 |
|
Patrick@310
|
148 |
# ~~~~~~ index
|
Patrick@310
|
149 |
index = element index { index.content }
|
Patrick@310
|
150 |
head.index = element index { head.index.content }
|
Patrick@310
|
151 |
|
Patrick@310
|
152 |
index.content =
|
Patrick@310
|
153 |
(index.w, index.entry?)
|
Patrick@310
|
154 |
| (index.entry, (index.w | index.entry)?)
|
Patrick@310
|
155 |
head.index.content =
|
Patrick@310
|
156 |
index.entry, index.entry?
|
Patrick@310
|
157 |
|
Patrick@310
|
158 |
# ~~~~~~ index.w
|
Patrick@310
|
159 |
index.w = element w { simple.inlines }
|
Patrick@310
|
160 |
|
Patrick@310
|
161 |
# ~~~~~~ index.entry
|
Patrick@310
|
162 |
index.entry = element entry { simple.inlines }
|
Patrick@310
|
163 |
|
Patrick@310
|
164 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ abstract ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Patrick@310
|
165 |
|
Patrick@310
|
166 |
abstract = element abstract { abstract.content }
|
Patrick@310
|
167 |
|
Patrick@310
|
168 |
abstract.content =
|
Patrick@310
|
169 |
p+
|
Patrick@310
|
170 |
|
Patrick@310
|
171 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ cover ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Patrick@310
|
172 |
|
Patrick@310
|
173 |
cover = element cover { cover.content }
|
Patrick@310
|
174 |
|
Patrick@310
|
175 |
cover.content =
|
Patrick@310
|
176 |
cover.image
|
Patrick@310
|
177 |
|
Patrick@310
|
178 |
cover.image = element image { cover.image.attributes }
|
Patrick@310
|
179 |
|
Patrick@310
|
180 |
cover.image.attributes =
|
Patrick@310
|
181 |
media.id.attribute
|
Patrick@310
|
182 |
|
Patrick@310
|
183 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ annotation ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Patrick@310
|
184 |
|
Patrick@310
|
185 |
annotation = element annotation { annotation.content }
|
Patrick@310
|
186 |
|
Patrick@364
|
187 |
annotation.content =
|
Patrick@364
|
188 |
inlines | p+
|
Patrick@310
|
189 |
|
Patrick@310
|
190 |
|
Patrick@310
|
191 |
# =============================================================================
|
patrick@20
|
192 |
# TOP LEVEL
|
patrick@0
|
193 |
# =============================================================================
|
patrick@0
|
194 |
|
patrick@98
|
195 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ top.head ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
patrick@90
|
196 |
|
patrick@90
|
197 |
top.head = element head { top.head.content }
|
patrick@90
|
198 |
|
patrick@90
|
199 |
top.head.content =
|
Patrick@384
|
200 |
(title & shorttitle? & subtitle*)?
|
Patrick@256
|
201 |
& identifier*
|
patrick@181
|
202 |
& copyright*
|
Patrick@155
|
203 |
& collection?
|
patrick@90
|
204 |
& contributors?
|
patrick@90
|
205 |
& date?
|
patrick@90
|
206 |
& place?
|
patrick@156
|
207 |
& (source, source?)?
|
patrick@90
|
208 |
& keywordset?
|
patrick@90
|
209 |
& subjectset?
|
Patrick@355
|
210 |
& indexset?
|
patrick@90
|
211 |
& abstract?
|
patrick@90
|
212 |
& cover?
|
Patrick@364
|
213 |
& annotation?
|
patrick@90
|
214 |
|
patrick@0
|
215 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ document ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
patrick@0
|
216 |
|
patrick@0
|
217 |
document = element document { document.attributes, document.content }
|
patrick@0
|
218 |
|
patrick@0
|
219 |
document.attributes =
|
Patrick@388
|
220 |
document.id.attribute?
|
patrick@142
|
221 |
& document.type.attribute?
|
patrick@66
|
222 |
& lang.attribute?
|
patrick@117
|
223 |
document.id.attribute = attribute id { xsd:NMTOKEN }
|
patrick@142
|
224 |
document.type.attribute = attribute type { xsd:NCName }
|
patrick@66
|
225 |
lang.attribute = attribute xml:lang { xsd:language }
|
patrick@0
|
226 |
|
patrick@0
|
227 |
document.content =
|
patrick@20
|
228 |
top.head?,
|
Coraline@419
|
229 |
(division | topic | glossary)+
|
patrick@0
|
230 |
|
Patrick@310
|
231 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ top.topic ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
patrick@0
|
232 |
|
patrick@18
|
233 |
top.topic = element topic { top.topic.attributes, top.topic.content }
|
patrick@0
|
234 |
|
patrick@20
|
235 |
top.topic.attributes =
|
Patrick@388
|
236 |
topic.id.attribute?
|
patrick@20
|
237 |
& topic.type.attribute?
|
patrick@66
|
238 |
& lang.attribute?
|
patrick@117
|
239 |
topic.id.attribute = attribute id { xsd:NMTOKEN }
|
patrick@20
|
240 |
topic.type.attribute = attribute type { xsd:NCName }
|
patrick@20
|
241 |
|
patrick@20
|
242 |
top.topic.content =
|
patrick@20
|
243 |
top.head?,
|
Patrick@137
|
244 |
header?,
|
Patrick@190
|
245 |
((section+, bibliography?) | bibliography),
|
Patrick@137
|
246 |
footer?
|
patrick@0
|
247 |
|
patrick@40
|
248 |
|
Coraline@419
|
249 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ glossary ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Coraline@419
|
250 |
|
Coraline@419
|
251 |
glossary = element glossary { glossary.attributes, glossary.content }
|
Coraline@419
|
252 |
|
Coraline@419
|
253 |
glossary.attributes =
|
Coraline@419
|
254 |
glossary.type.attribute?
|
Coraline@419
|
255 |
& langfrom.attribute?
|
Coraline@419
|
256 |
& langto.attribute?
|
Coraline@419
|
257 |
glossary.type.attribute = attribute type { xsd:NCName }
|
Coraline@419
|
258 |
langfrom.attribute = attribute langfrom { xsd:language }
|
Coraline@419
|
259 |
langto.attribute = attribute langto { xsd:language }
|
Coraline@419
|
260 |
|
Coraline@419
|
261 |
glossary.content =
|
Coraline@419
|
262 |
glossary.entry+
|
Coraline@419
|
263 |
|
Coraline@419
|
264 |
|
patrick@0
|
265 |
# =============================================================================
|
patrick@20
|
266 |
# DIVISION LEVEL
|
patrick@0
|
267 |
# =============================================================================
|
patrick@0
|
268 |
|
Patrick@310
|
269 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ division.head ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Patrick@310
|
270 |
|
Patrick@310
|
271 |
division.head = element head { division.head.content }
|
Patrick@310
|
272 |
|
Patrick@310
|
273 |
division.head.content =
|
Patrick@384
|
274 |
(title & shorttitle? & subtitle*)?
|
Patrick@355
|
275 |
& indexset?
|
Patrick@310
|
276 |
& abstract?
|
Patrick@364
|
277 |
& annotation?
|
Patrick@310
|
278 |
|
patrick@70
|
279 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ division ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
patrick@0
|
280 |
|
Patrick@232
|
281 |
division = element division { division.attributes, division.content }
|
Patrick@232
|
282 |
|
Patrick@232
|
283 |
division.attributes =
|
Patrick@232
|
284 |
division.type.attribute?
|
Patrick@232
|
285 |
division.type.attribute = attribute type { xsd:NCName }
|
patrick@0
|
286 |
|
patrick@0
|
287 |
division.content =
|
patrick@20
|
288 |
division.head?,
|
Patrick@217
|
289 |
front?,
|
patrick@56
|
290 |
(division | topic)+
|
patrick@0
|
291 |
|
Patrick@310
|
292 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ front ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
patrick@90
|
293 |
|
Patrick@217
|
294 |
front = element front { front.content }
|
Patrick@217
|
295 |
|
Patrick@217
|
296 |
front.content =
|
Patrick@217
|
297 |
section+
|
Patrick@217
|
298 |
|
patrick@0
|
299 |
|
patrick@0
|
300 |
# =============================================================================
|
patrick@90
|
301 |
# COMPONENT LEVEL
|
patrick@0
|
302 |
# =============================================================================
|
patrick@0
|
303 |
|
patrick@90
|
304 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ component.head ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
patrick@90
|
305 |
|
patrick@90
|
306 |
component.head = element head { component.head.content }
|
patrick@90
|
307 |
|
patrick@90
|
308 |
component.head.content =
|
Patrick@384
|
309 |
(title & shorttitle? & subtitle*)?
|
patrick@90
|
310 |
& contributors?
|
patrick@143
|
311 |
& date?
|
patrick@143
|
312 |
& place?
|
patrick@143
|
313 |
& keywordset?
|
patrick@143
|
314 |
& subjectset?
|
Patrick@355
|
315 |
& indexset?
|
patrick@90
|
316 |
& abstract?
|
Patrick@364
|
317 |
& annotation?
|
patrick@90
|
318 |
|
patrick@0
|
319 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ topic ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
patrick@0
|
320 |
|
patrick@0
|
321 |
topic = element topic { topic.attributes, topic.content }
|
patrick@0
|
322 |
|
patrick@0
|
323 |
topic.attributes =
|
Patrick@191
|
324 |
(topic.id.attribute | xmlid.attribute)?
|
patrick@0
|
325 |
& topic.type.attribute?
|
patrick@69
|
326 |
& lang.attribute?
|
Patrick@191
|
327 |
xmlid.attribute = attribute xml:id { xsd:ID }
|
patrick@0
|
328 |
|
patrick@0
|
329 |
topic.content =
|
patrick@20
|
330 |
component.head?,
|
Patrick@137
|
331 |
header?,
|
Patrick@190
|
332 |
((section+, bibliography?) | bibliography),
|
Patrick@137
|
333 |
footer?
|
patrick@0
|
334 |
|
patrick@0
|
335 |
|
patrick@0
|
336 |
# =============================================================================
|
patrick@20
|
337 |
# SECTION LEVEL
|
patrick@0
|
338 |
# =============================================================================
|
patrick@0
|
339 |
|
Patrick@310
|
340 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ section.head ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Patrick@310
|
341 |
|
Patrick@310
|
342 |
section.head = element head { section.head.content }
|
Patrick@310
|
343 |
|
Patrick@310
|
344 |
section.head.content =
|
Patrick@384
|
345 |
(title & shorttitle? & subtitle*)?
|
Patrick@310
|
346 |
& keywordset?
|
Patrick@310
|
347 |
& subjectset?
|
Patrick@355
|
348 |
& indexset?
|
Patrick@310
|
349 |
& abstract?
|
Patrick@310
|
350 |
& audio*
|
Patrick@364
|
351 |
& annotation?
|
Patrick@310
|
352 |
|
Patrick@137
|
353 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ header ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Patrick@137
|
354 |
|
Patrick@137
|
355 |
header = element header { header.content }
|
Patrick@137
|
356 |
|
Patrick@137
|
357 |
header.content =
|
Patrick@137
|
358 |
block+
|
Patrick@137
|
359 |
|
patrick@20
|
360 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ section ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
patrick@0
|
361 |
|
patrick@58
|
362 |
section = element section { section.attributes, section.content }
|
patrick@58
|
363 |
|
patrick@58
|
364 |
section.attributes =
|
Patrick@279
|
365 |
xmlid.attribute?
|
Patrick@279
|
366 |
& section.type.attribute?
|
patrick@64
|
367 |
& lang.attribute?
|
patrick@166
|
368 |
& for.attribute?
|
patrick@58
|
369 |
section.type.attribute = attribute type { xsd:NCName }
|
patrick@166
|
370 |
for.attribute = attribute for { xsd:NCName }
|
patrick@0
|
371 |
|
patrick@0
|
372 |
section.content =
|
patrick@20
|
373 |
section.head?,
|
patrick@9
|
374 |
(section+ | block+)
|
patrick@0
|
375 |
|
Patrick@189
|
376 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ bibliography ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Patrick@189
|
377 |
|
Patrick@189
|
378 |
bibliography = element bibliography { bibliography.content }
|
Patrick@189
|
379 |
|
Patrick@189
|
380 |
bibliography.content =
|
Patrick@189
|
381 |
bibliography.entry+
|
Patrick@189
|
382 |
|
Patrick@137
|
383 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ footer ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Patrick@137
|
384 |
|
Patrick@137
|
385 |
footer = element footer { footer.content }
|
Patrick@137
|
386 |
|
Patrick@137
|
387 |
footer.content =
|
Patrick@137
|
388 |
block+
|
Patrick@137
|
389 |
|
Coraline@419
|
390 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ glossary.entry ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Coraline@419
|
391 |
# ~~~~~~ glossary.entry
|
Coraline@419
|
392 |
glossary.entry= element entry {
|
Coraline@419
|
393 |
glossary.entry.attributes, glossary.entry.content }
|
Coraline@419
|
394 |
|
Coraline@419
|
395 |
glossary.entry.attributes =
|
Coraline@419
|
396 |
xmlid.attribute
|
Coraline@419
|
397 |
|
Coraline@419
|
398 |
glossary.entry.content =
|
Coraline@419
|
399 |
mainterm,
|
Coraline@423
|
400 |
media?,
|
Coraline@419
|
401 |
meanings+,
|
Coraline@419
|
402 |
seealso*
|
Coraline@419
|
403 |
|
Coraline@419
|
404 |
# ~~~~~~ mainterm
|
Coraline@419
|
405 |
mainterm = element mainterm { mainterm.content }
|
Coraline@419
|
406 |
mainterm.content = simple.inlines
|
patrick@0
|
407 |
|
patrick@0
|
408 |
# =============================================================================
|
patrick@20
|
409 |
# BLOCK LEVEL
|
patrick@0
|
410 |
# =============================================================================
|
patrick@0
|
411 |
|
Patrick@310
|
412 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ block.head ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
patrick@9
|
413 |
|
patrick@90
|
414 |
block.head = element head { block.head.content }
|
patrick@90
|
415 |
|
patrick@90
|
416 |
block.head.content =
|
Patrick@384
|
417 |
(title & shorttitle? & subtitle*)?
|
Patrick@355
|
418 |
& indexset?
|
Patrick@364
|
419 |
& annotation?
|
patrick@90
|
420 |
|
Patrick@310
|
421 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ block ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Patrick@310
|
422 |
|
Patrick@313
|
423 |
block = (p | \list | blockquote | speech | table | table.cals | media)
|
Patrick@310
|
424 |
|
patrick@42
|
425 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ p ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
patrick@0
|
426 |
|
patrick@20
|
427 |
p = element p { p.content }
|
patrick@0
|
428 |
|
patrick@20
|
429 |
p.content =
|
patrick@0
|
430 |
inlines
|
patrick@0
|
431 |
|
patrick@17
|
432 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ list ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
patrick@9
|
433 |
|
patrick@9
|
434 |
# ~~~~~~ list
|
patrick@75
|
435 |
\list = element list {
|
patrick@20
|
436 |
block.head?,
|
patrick@71
|
437 |
( (attribute type {"ordered"}?, item, item+)
|
Coraline@419
|
438 |
| (attribute type {"glossary"}, item.glossary+) )
|
patrick@75
|
439 |
}
|
patrick@9
|
440 |
|
patrick@9
|
441 |
# ~~~~~~ item
|
patrick@9
|
442 |
item = element item { item.content }
|
patrick@9
|
443 |
|
patrick@30
|
444 |
item.content =
|
patrick@73
|
445 |
inlines
|
patrick@73
|
446 |
| block+
|
patrick@9
|
447 |
|
Coraline@419
|
448 |
# ~~~~~~ item.glossary
|
Coraline@419
|
449 |
item.glossary = element item { item.glossary.content }
|
patrick@9
|
450 |
|
Coraline@419
|
451 |
item.glossary.content =
|
patrick@9
|
452 |
label,
|
patrick@9
|
453 |
block+
|
patrick@9
|
454 |
|
patrick@44
|
455 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ blockquote ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
patrick@44
|
456 |
|
patrick@44
|
457 |
# ~~~~~~ blockquote
|
Patrick@306
|
458 |
blockquote = element blockquote { blockquote.attributes, blockquote.content }
|
patrick@44
|
459 |
|
Patrick@306
|
460 |
blockquote.attributes =
|
Patrick@306
|
461 |
blockquote.type.attribute?
|
Patrick@306
|
462 |
blockquote.type.attribute = attribute type { xsd:NCName }
|
Patrick@310
|
463 |
|
patrick@44
|
464 |
blockquote.content =
|
patrick@44
|
465 |
block.head?,
|
patrick@44
|
466 |
(p | speech | \list)+,
|
patrick@44
|
467 |
attribution?
|
patrick@44
|
468 |
|
patrick@44
|
469 |
# ~~~~~~ attribution
|
patrick@72
|
470 |
attribution = element attribution { attribution.content }
|
patrick@44
|
471 |
|
Patrick@225
|
472 |
attribution.content = mixed {
|
Patrick@225
|
473 |
sup* & number* & date* & name* & foreign* & acronym* & term* & literal*
|
Patrick@238
|
474 |
& highlight* & emphasis* & mentioned* & note* & warning* }
|
patrick@44
|
475 |
|
Patrick@313
|
476 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ speech ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Patrick@313
|
477 |
|
Patrick@313
|
478 |
# ~~~~~~ speech
|
Patrick@313
|
479 |
speech = element speech { speech.content }
|
Patrick@313
|
480 |
|
Patrick@313
|
481 |
speech.content =
|
Patrick@313
|
482 |
speaker?,
|
Patrick@313
|
483 |
stage?,
|
Patrick@313
|
484 |
(p | blockquote)+
|
Patrick@313
|
485 |
|
Patrick@313
|
486 |
# ~~~~~~ speaker
|
Patrick@313
|
487 |
speaker = element speaker { speaker.content }
|
Patrick@313
|
488 |
|
Patrick@313
|
489 |
speaker.content = inlines
|
Patrick@313
|
490 |
|
patrick@248
|
491 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ table ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
patrick@17
|
492 |
|
patrick@73
|
493 |
# ~~~~~~ table
|
patrick@248
|
494 |
table = element table { table.attributes, table.content }
|
patrick@248
|
495 |
|
patrick@248
|
496 |
table.attributes =
|
patrick@248
|
497 |
table.type.attribute?
|
patrick@248
|
498 |
table.type.attribute = attribute type { xsd:NCName }
|
patrick@17
|
499 |
|
patrick@17
|
500 |
table.content =
|
patrick@20
|
501 |
block.head?,
|
Patrick@358
|
502 |
((thead?, tbody+) | tr+),
|
patrick@109
|
503 |
table.caption?
|
patrick@17
|
504 |
|
patrick@248
|
505 |
# ~~~~~~ thead, tbody
|
patrick@248
|
506 |
thead = element thead { thead.content }
|
patrick@248
|
507 |
tbody = element tbody { tbody.content }
|
patrick@17
|
508 |
|
patrick@248
|
509 |
thead.content =
|
patrick@248
|
510 |
tr+
|
patrick@248
|
511 |
tbody.content =
|
patrick@248
|
512 |
tr+
|
patrick@17
|
513 |
|
patrick@248
|
514 |
# ~~~~~~ tr
|
patrick@248
|
515 |
tr = element tr { tr.attributes, tr.content }
|
patrick@248
|
516 |
|
patrick@248
|
517 |
tr.attributes =
|
patrick@248
|
518 |
align.attribute?
|
patrick@248
|
519 |
& valign.attribute?
|
Tiphanie@309
|
520 |
& cell.type.attribute?
|
patrick@17
|
521 |
align.attribute = attribute align { "left" | "right" | "center" | "justify" }
|
patrick@22
|
522 |
valign.attribute = attribute valign { "top" | "middle" | "bottom" }
|
Tiphanie@309
|
523 |
cell.type.attribute = attribute type { xsd:NCName }
|
patrick@75
|
524 |
|
patrick@248
|
525 |
tr.content =
|
patrick@248
|
526 |
(td | th)+
|
patrick@17
|
527 |
|
patrick@248
|
528 |
# ~~~~~~ td, th
|
patrick@248
|
529 |
td = element td { td.attributes, td.content }
|
patrick@248
|
530 |
th = element th { td.attributes, td.content }
|
patrick@17
|
531 |
|
patrick@248
|
532 |
td.attributes =
|
patrick@146
|
533 |
align.attribute?
|
patrick@146
|
534 |
& valign.attribute?
|
patrick@248
|
535 |
& colspan.attribute?
|
patrick@248
|
536 |
& rowspan.attribute?
|
Tiphanie@309
|
537 |
& cell.type.attribute?
|
patrick@248
|
538 |
colspan.attribute = attribute colspan { xsd:positiveInteger }
|
patrick@248
|
539 |
rowspan.attribute = attribute rowspan { xsd:positiveInteger }
|
patrick@17
|
540 |
|
patrick@248
|
541 |
td.content =
|
patrick@17
|
542 |
inlines
|
patrick@37
|
543 |
| (p | media)+
|
patrick@17
|
544 |
|
patrick@109
|
545 |
# ~~~~~~ table.caption
|
patrick@109
|
546 |
table.caption = element caption { caption.content }
|
patrick@17
|
547 |
|
patrick@17
|
548 |
caption.content =
|
patrick@20
|
549 |
inlines
|
Patrick@138
|
550 |
| (p | speech | \list | blockquote)+
|
patrick@17
|
551 |
|
patrick@248
|
552 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ table.cals ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
patrick@248
|
553 |
|
patrick@248
|
554 |
# ~~~~~~ table.cals
|
patrick@248
|
555 |
table.cals = element table { table.attributes, table.cals.content }
|
patrick@248
|
556 |
|
patrick@248
|
557 |
table.cals.content =
|
patrick@248
|
558 |
block.head?,
|
patrick@248
|
559 |
tgroup+,
|
patrick@248
|
560 |
table.caption?
|
patrick@248
|
561 |
|
patrick@248
|
562 |
# ~~~~~~ tgroup
|
patrick@248
|
563 |
tgroup = element tgroup { tgroup.attributes, tgroup.content }
|
patrick@248
|
564 |
|
patrick@248
|
565 |
tgroup.attributes =
|
patrick@248
|
566 |
cols.attribute
|
patrick@248
|
567 |
cols.attribute = attribute cols { xsd:positiveInteger }
|
patrick@248
|
568 |
|
patrick@248
|
569 |
tgroup.content =
|
patrick@248
|
570 |
thead.cals?,
|
patrick@248
|
571 |
tbody.cals
|
patrick@248
|
572 |
|
patrick@248
|
573 |
# ~~~~~~ thead, tbody
|
patrick@248
|
574 |
thead.cals = element thead { thead.cals.content }
|
patrick@248
|
575 |
tbody.cals = element tbody { tbody.cals.content }
|
patrick@248
|
576 |
|
patrick@248
|
577 |
thead.cals.content =
|
patrick@248
|
578 |
row+
|
patrick@248
|
579 |
tbody.cals.content =
|
patrick@248
|
580 |
row+
|
patrick@248
|
581 |
|
patrick@248
|
582 |
# ~~~~~~ row
|
patrick@248
|
583 |
row = element row { row.attributes, row.content }
|
patrick@248
|
584 |
|
patrick@248
|
585 |
row.attributes =
|
patrick@248
|
586 |
valign.attribute?
|
patrick@248
|
587 |
|
patrick@248
|
588 |
row.content =
|
patrick@248
|
589 |
table.cals.entry+
|
patrick@248
|
590 |
|
patrick@248
|
591 |
# ~~~~~~ table.cals.entry
|
patrick@248
|
592 |
table.cals.entry = element entry {
|
patrick@248
|
593 |
table.cals.entry.attributes, table.cals.entry.content }
|
patrick@248
|
594 |
|
patrick@248
|
595 |
table.cals.entry.attributes =
|
patrick@248
|
596 |
align.attribute?
|
patrick@248
|
597 |
& valign.attribute?
|
patrick@248
|
598 |
|
patrick@248
|
599 |
table.cals.entry.content =
|
patrick@248
|
600 |
inlines
|
patrick@248
|
601 |
| (p | media)+
|
patrick@248
|
602 |
|
patrick@35
|
603 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ media ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
patrick@0
|
604 |
|
patrick@2
|
605 |
# ~~~~~~ media
|
patrick@245
|
606 |
media = element media { media.attributes, media.content }
|
patrick@245
|
607 |
|
patrick@245
|
608 |
media.attributes =
|
Patrick@279
|
609 |
xmlid.attribute?
|
Patrick@279
|
610 |
& media.type.attribute?
|
patrick@245
|
611 |
media.type.attribute = attribute type { xsd:NCName }
|
patrick@0
|
612 |
|
patrick@0
|
613 |
media.content =
|
patrick@24
|
614 |
block.head?,
|
Patrick@288
|
615 |
(media.image | audio | video)+,
|
patrick@109
|
616 |
media.caption?,
|
patrick@36
|
617 |
link?
|
patrick@0
|
618 |
|
patrick@2
|
619 |
# ~~~~~~ image
|
Patrick@288
|
620 |
image = element image { image.attributes }
|
Patrick@288
|
621 |
media.image = element image { image.attributes, media.image.content }
|
patrick@0
|
622 |
|
patrick@0
|
623 |
image.attributes =
|
patrick@104
|
624 |
media.id.attribute
|
Patrick@312
|
625 |
& image.type.attribute?
|
Coraline@407
|
626 |
& image.zoom.attribute?
|
Patrick@312
|
627 |
& alt.attribute?
|
patrick@17
|
628 |
media.id.attribute = attribute id { xsd:NMTOKEN }
|
Patrick@312
|
629 |
image.type.attribute = attribute type {
|
Patrick@312
|
630 |
"cover" | "thumbnail" | "icon" | "animation" }
|
Coraline@407
|
631 |
image.zoom.attribute = attribute zoom {"true" | "false"}
|
Patrick@312
|
632 |
alt.attribute = attribute alt { text }
|
patrick@0
|
633 |
|
Patrick@288
|
634 |
media.image.content =
|
patrick@111
|
635 |
copyright?,
|
Patrick@176
|
636 |
hotspot*
|
patrick@0
|
637 |
|
patrick@45
|
638 |
# ~~~~~~ audio
|
patrick@45
|
639 |
audio = element audio { audio.attributes }
|
patrick@43
|
640 |
|
patrick@45
|
641 |
audio.attributes =
|
patrick@43
|
642 |
media.id.attribute
|
patrick@104
|
643 |
& audio.type?
|
Coraline@409
|
644 |
audio.type = attribute type { "music" | "voice" | "en" | "fr" | "background"
|
Coraline@409
|
645 |
| "smil" }
|
patrick@43
|
646 |
|
patrick@119
|
647 |
# ~~~~~~ video
|
patrick@119
|
648 |
video = element video { video.attributes }
|
patrick@119
|
649 |
|
patrick@119
|
650 |
video.attributes =
|
patrick@119
|
651 |
media.id.attribute
|
patrick@119
|
652 |
|
patrick@122
|
653 |
# ~~~~~~ hotspot
|
patrick@122
|
654 |
hotspot = element hotspot { hotspot.attributes, hotspot.content }
|
patrick@122
|
655 |
|
patrick@122
|
656 |
hotspot.attributes =
|
patrick@122
|
657 |
x.attribute
|
patrick@122
|
658 |
& y.attribute
|
patrick@182
|
659 |
& w.attribute
|
Patrick@183
|
660 |
& h.attribute?
|
Patrick@236
|
661 |
& hotspot.display.attribute?
|
Patrick@237
|
662 |
& hotspot.type.attribute?
|
Patrick@191
|
663 |
& xmlid.attribute?
|
Patrick@173
|
664 |
x.attribute = attribute x { xsd:token {pattern = "\d{1,2}(\.\d{1,2})?%"} }
|
Patrick@173
|
665 |
y.attribute = attribute y { xsd:token {pattern = "\d{1,2}(\.\d{1,2})?%"} }
|
patrick@182
|
666 |
w.attribute = attribute w { xsd:token {pattern = "\d{1,2}(\.\d{1,2})?%"} }
|
patrick@182
|
667 |
h.attribute = attribute h { xsd:token {pattern = "\d{1,2}(\.\d{1,2})?%"} }
|
Patrick@236
|
668 |
hotspot.display.attribute = attribute display { "normal" | "visible" | "pulse" }
|
Patrick@237
|
669 |
hotspot.type.attribute = attribute type { xsd:NCName }
|
Patrick@310
|
670 |
|
Patrick@191
|
671 |
hotspot.content =
|
Patrick@288
|
672 |
((link | p+ | image | audio | video), (spot, scenario?)?)
|
Patrick@191
|
673 |
| (spot, scenario?)
|
Patrick@310
|
674 |
| empty
|
Patrick@310
|
675 |
|
Patrick@191
|
676 |
# ~~~~~~ spot
|
Patrick@191
|
677 |
spot = element spot { spot.attributes, spot.content }
|
Patrick@191
|
678 |
|
Patrick@191
|
679 |
spot.attributes =
|
Patrick@191
|
680 |
dx.attribute?
|
Patrick@191
|
681 |
& dy.attribute?
|
Patrick@191
|
682 |
& dw.attribute?
|
Patrick@191
|
683 |
& dh.attribute?
|
patrick@188
|
684 |
dx.attribute = attribute dx { xsd:token {pattern = "-?\d{1,2}(\.\d{1,2})?%"} }
|
patrick@188
|
685 |
dy.attribute = attribute dy { xsd:token {pattern = "-?\d{1,2}(\.\d{1,2})?%"} }
|
Patrick@191
|
686 |
dw.attribute = attribute dw { xsd:token {pattern = "-?\d{1,2}(\.\d{1,2})?%"} }
|
Patrick@191
|
687 |
dh.attribute = attribute dh { xsd:token {pattern = "-?\d{1,2}(\.\d{1,2})?%"} }
|
Patrick@191
|
688 |
|
Patrick@191
|
689 |
spot.content =
|
Patrick@191
|
690 |
((p+ | image), audio?)
|
Patrick@191
|
691 |
| audio
|
Patrick@191
|
692 |
| video
|
Patrick@191
|
693 |
|
patrick@109
|
694 |
# ~~~~~~ media.caption
|
patrick@109
|
695 |
media.caption = element caption { caption.attributes, caption.content }
|
patrick@109
|
696 |
|
patrick@109
|
697 |
caption.attributes =
|
patrick@109
|
698 |
x.attribute?
|
patrick@109
|
699 |
& y.attribute?
|
patrick@109
|
700 |
|
Patrick@191
|
701 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ scenario ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Patrick@191
|
702 |
|
Patrick@191
|
703 |
# ~~~~~~ scenario
|
Patrick@191
|
704 |
scenario = element scenario { scenario.content }
|
Patrick@191
|
705 |
|
Patrick@191
|
706 |
scenario.content =
|
Patrick@191
|
707 |
init*,
|
Patrick@191
|
708 |
onclick*
|
Patrick@191
|
709 |
|
Patrick@191
|
710 |
# ~~~~~~ init
|
Patrick@191
|
711 |
init = element init { init.attributes }
|
Patrick@191
|
712 |
|
Patrick@191
|
713 |
init.attributes =
|
Patrick@191
|
714 |
init.action.attribute
|
Patrick@191
|
715 |
& target.attribute?
|
Patrick@191
|
716 |
init.action.attribute = attribute action { "hide" }
|
Patrick@191
|
717 |
target.attribute = attribute target { "hotspot" | "spot" }
|
Patrick@191
|
718 |
|
Patrick@191
|
719 |
# ~~~~~~ onclick
|
Patrick@191
|
720 |
onclick = element onclick { onclick.attributes }
|
Patrick@191
|
721 |
|
Patrick@191
|
722 |
onclick.attributes =
|
Patrick@191
|
723 |
onclick.action.attribute
|
Patrick@191
|
724 |
& target.attribute?
|
Patrick@191
|
725 |
onclick.action.attribute = attribute action { "show" }
|
Patrick@191
|
726 |
|
Patrick@397
|
727 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ bibliography.entry ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Patrick@189
|
728 |
|
Patrick@189
|
729 |
# ~~~~~~ bibliography.entry
|
Patrick@189
|
730 |
bibliography.entry = element entry { bibliography.entry.content }
|
Patrick@189
|
731 |
|
Patrick@189
|
732 |
bibliography.entry.content =
|
Patrick@189
|
733 |
identifier.ean?
|
Patrick@189
|
734 |
& title
|
Patrick@189
|
735 |
& subtitle?
|
Patrick@189
|
736 |
& copyright?
|
Patrick@189
|
737 |
& collection?
|
Patrick@189
|
738 |
& contributors?
|
Patrick@189
|
739 |
& date?
|
Patrick@189
|
740 |
& place?
|
Patrick@189
|
741 |
& folio?
|
Patrick@189
|
742 |
& pages?
|
Patrick@189
|
743 |
|
Patrick@189
|
744 |
# ~~~~~~ folio
|
Patrick@189
|
745 |
folio = element folio { folio.content }
|
Patrick@189
|
746 |
|
Patrick@189
|
747 |
folio.content = xsd:positiveInteger | xsd:token {pattern = "[DLXVI]+"}
|
Patrick@189
|
748 |
|
Patrick@189
|
749 |
# ~~~~~~ pages
|
Patrick@189
|
750 |
pages = element pages { pages.content }
|
Patrick@189
|
751 |
|
Patrick@189
|
752 |
pages.content = xsd:positiveInteger
|
Patrick@189
|
753 |
|
Coraline@419
|
754 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ meanings ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Coraline@419
|
755 |
|
Coraline@419
|
756 |
# ~~~~~~ meanings
|
Coraline@419
|
757 |
meanings = element meanings { meanings.attributes, meanings.content }
|
Coraline@419
|
758 |
|
Coraline@419
|
759 |
meanings.attributes =
|
Coraline@419
|
760 |
gramcode.attribute?
|
Coraline@419
|
761 |
gramcode.attribute = attribute gramcode { xsd:NMTOKEN }
|
Coraline@419
|
762 |
|
Coraline@419
|
763 |
meanings.content =
|
Coraline@419
|
764 |
female?,
|
Coraline@419
|
765 |
plural?,
|
Coraline@419
|
766 |
meaning+
|
Coraline@419
|
767 |
|
Coraline@419
|
768 |
# ~~~~~~ female, plural
|
Coraline@419
|
769 |
female = element female { inlines }
|
Coraline@419
|
770 |
plural = element plural { inlines }
|
Coraline@419
|
771 |
|
Coraline@419
|
772 |
# ~~~~~~ meaning
|
Coraline@419
|
773 |
meaning = element meaning { meaning.attributes, meaning.content }
|
Coraline@419
|
774 |
|
Coraline@419
|
775 |
meaning.attributes =
|
Coraline@419
|
776 |
meaning.domain.attribute?
|
Coraline@419
|
777 |
& langlevel.attribute?
|
Coraline@419
|
778 |
meaning.domain.attribute = attribute domain { xsd:NMTOKEN }
|
Coraline@419
|
779 |
langlevel.attribute = attribute langlevel { xsd:NMTOKEN }
|
Coraline@419
|
780 |
|
Coraline@419
|
781 |
meaning.content =
|
Coraline@419
|
782 |
((definition, example*, synonym*, antonym*, translation*)
|
Coraline@419
|
783 |
| (definition?, example*, synonym*, antonym*, translation+)
|
Coraline@419
|
784 |
| (definition?, example*, synonym+, antonym*, translation*)
|
Coraline@419
|
785 |
| (definition?, example*, synonym*, antonym+, translation*)),
|
Coraline@419
|
786 |
dictum*
|
Coraline@419
|
787 |
|
Coraline@419
|
788 |
# ~~~~~~ definition
|
Coraline@419
|
789 |
definition = element definition { inlines }
|
Coraline@419
|
790 |
|
Coraline@419
|
791 |
# ~~~~~~ synonym, antonym
|
Coraline@419
|
792 |
synonym = element synonym { simple.inlines }
|
Coraline@419
|
793 |
antonym = element antonym { simple.inlines }
|
Coraline@419
|
794 |
|
Coraline@419
|
795 |
# ~~~~~~ translation
|
Coraline@419
|
796 |
translation = element translation { simple.inlines }
|
Coraline@419
|
797 |
|
Coraline@419
|
798 |
# ~~~~~~ dictum
|
Coraline@423
|
799 |
dictum = element dictum { dictum.content }
|
Coraline@423
|
800 |
dictum.content = p+
|
Coraline@419
|
801 |
|
Coraline@419
|
802 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ seealso ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Coraline@419
|
803 |
|
Coraline@419
|
804 |
seealso = element seealso { seealso.attributes }
|
Coraline@419
|
805 |
|
Coraline@419
|
806 |
seealso.attributes =
|
Coraline@419
|
807 |
gloss.ref.attribute
|
Coraline@419
|
808 |
|
patrick@0
|
809 |
|
patrick@0
|
810 |
# =============================================================================
|
patrick@20
|
811 |
# INLINE LEVEL
|
patrick@0
|
812 |
# =============================================================================
|
patrick@0
|
813 |
|
patrick@0
|
814 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ inlines ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
patrick@0
|
815 |
|
Patrick@288
|
816 |
simple.inlines = mixed {
|
patrick@0
|
817 |
sup*
|
patrick@0
|
818 |
& sub*
|
patrick@42
|
819 |
& var*
|
patrick@13
|
820 |
& number*
|
Patrick@212
|
821 |
& acronym*
|
Patrick@288
|
822 |
& warning*
|
Patrick@288
|
823 |
}
|
Patrick@288
|
824 |
|
Patrick@293
|
825 |
inlines = mixed {
|
Patrick@293
|
826 |
sup*
|
Patrick@293
|
827 |
& sub*
|
Patrick@293
|
828 |
& var*
|
Patrick@293
|
829 |
& number*
|
Patrick@293
|
830 |
& acronym*
|
Patrick@293
|
831 |
& warning*
|
Patrick@293
|
832 |
|
Patrick@212
|
833 |
& highlight*
|
Patrick@238
|
834 |
& emphasis*
|
Patrick@212
|
835 |
& mentioned*
|
Patrick@350
|
836 |
& literal*
|
Patrick@350
|
837 |
& term*
|
Coraline@419
|
838 |
& example*
|
Patrick@288
|
839 |
& stage*
|
Patrick@350
|
840 |
& name*
|
Patrick@350
|
841 |
& foreign*
|
Patrick@350
|
842 |
& date*
|
Patrick@350
|
843 |
& math*
|
Patrick@351
|
844 |
& quote*
|
Patrick@212
|
845 |
& initial*
|
Patrick@288
|
846 |
& note*
|
Patrick@288
|
847 |
& link*
|
Patrick@288
|
848 |
& anchor*
|
Patrick@288
|
849 |
& index*
|
Coraline@419
|
850 |
& gloss*
|
Patrick@351
|
851 |
& image*
|
Patrick@351
|
852 |
& audio*
|
Patrick@351
|
853 |
& smil*
|
Patrick@293
|
854 |
}
|
patrick@0
|
855 |
|
patrick@42
|
856 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ sub, sup, var ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
patrick@0
|
857 |
|
patrick@252
|
858 |
sup = element sup { mixed { var* & warning* } }
|
patrick@0
|
859 |
|
patrick@252
|
860 |
sub = element sub { mixed { var* & warning* } }
|
patrick@42
|
861 |
|
Patrick@225
|
862 |
var = element var { mixed { warning* } }
|
patrick@42
|
863 |
|
patrick@90
|
864 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ number ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
patrick@90
|
865 |
|
patrick@90
|
866 |
number = element number {
|
patrick@90
|
867 |
( attribute type {"roman"}, number.attributes, number.roman.content )
|
patrick@90
|
868 |
| ( number.attributes, number.content)
|
patrick@90
|
869 |
}
|
patrick@90
|
870 |
|
patrick@90
|
871 |
number.attributes =
|
patrick@90
|
872 |
number.value.attribute?
|
patrick@90
|
873 |
number.value.attribute = attribute value { xsd:integer | xsd:decimal }
|
patrick@90
|
874 |
|
Patrick@212
|
875 |
number.content = mixed { sup* & warning* }
|
patrick@246
|
876 |
number.roman.content = xsd:token {pattern = "[MCLXVI]+"}
|
patrick@90
|
877 |
|
Patrick@350
|
878 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ acronym ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Patrick@350
|
879 |
|
Patrick@350
|
880 |
acronym = element acronym { acronym.content }
|
Patrick@350
|
881 |
|
Patrick@350
|
882 |
acronym.content = mixed { sup* & warning* }
|
Patrick@350
|
883 |
|
Patrick@350
|
884 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ highlight ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Patrick@350
|
885 |
|
Patrick@350
|
886 |
highlight = element highlight { highlight.content }
|
Patrick@350
|
887 |
|
Patrick@350
|
888 |
highlight.content = inlines
|
Patrick@350
|
889 |
|
Patrick@350
|
890 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ emphasis ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Patrick@350
|
891 |
|
Patrick@350
|
892 |
emphasis = element emphasis { emphasis.content }
|
Patrick@350
|
893 |
|
Patrick@350
|
894 |
emphasis.content = inlines
|
Patrick@350
|
895 |
|
Patrick@350
|
896 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ mentioned ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Patrick@350
|
897 |
|
Patrick@350
|
898 |
mentioned = element mentioned { mentioned.content }
|
Patrick@350
|
899 |
|
Patrick@350
|
900 |
mentioned.content = inlines
|
Patrick@350
|
901 |
|
Patrick@350
|
902 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ literal ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Patrick@350
|
903 |
|
Patrick@350
|
904 |
literal = element literal { literal.content }
|
Patrick@350
|
905 |
|
Patrick@350
|
906 |
literal.content = inlines
|
Patrick@350
|
907 |
|
Patrick@350
|
908 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ term ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Patrick@350
|
909 |
|
Patrick@350
|
910 |
term = element term { term.content }
|
Patrick@350
|
911 |
|
Patrick@350
|
912 |
term.content = mixed { sup* & warning* }
|
Patrick@350
|
913 |
|
Coraline@419
|
914 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ example ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Coraline@419
|
915 |
|
Coraline@419
|
916 |
example = element example { example.content }
|
Coraline@419
|
917 |
|
Coraline@419
|
918 |
example.content = inlines
|
Coraline@419
|
919 |
|
Patrick@350
|
920 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ stage ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Patrick@350
|
921 |
|
Patrick@350
|
922 |
stage = element stage { stage.content }
|
Patrick@350
|
923 |
|
Patrick@350
|
924 |
stage.content = inlines
|
Patrick@350
|
925 |
|
Patrick@350
|
926 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ name ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Patrick@350
|
927 |
|
Patrick@350
|
928 |
name = element name { name.attributes, name.content }
|
Patrick@350
|
929 |
|
Patrick@350
|
930 |
name.attributes =
|
Patrick@350
|
931 |
name.of.attribute?
|
Patrick@350
|
932 |
name.of.attribute = attribute of {
|
Patrick@350
|
933 |
"person" | "company" | "book" | "newspaper" | "party" | "movie"
|
Patrick@350
|
934 |
| "painting" }
|
Patrick@350
|
935 |
|
Patrick@350
|
936 |
name.content = mixed { sup* & number* & acronym* & warning* }
|
Patrick@350
|
937 |
|
Patrick@350
|
938 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ foreign ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Patrick@350
|
939 |
|
Patrick@350
|
940 |
foreign = element foreign { foreign.attributes, foreign.content }
|
Patrick@350
|
941 |
|
Patrick@350
|
942 |
foreign.attributes =
|
Patrick@350
|
943 |
lang.attribute?
|
Patrick@350
|
944 |
|
Patrick@350
|
945 |
foreign.content = inlines
|
Patrick@350
|
946 |
|
Patrick@350
|
947 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ date ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Patrick@350
|
948 |
|
Patrick@350
|
949 |
date = element date { date.attributes, date.content }
|
Patrick@350
|
950 |
|
Patrick@350
|
951 |
date.attributes =
|
Patrick@350
|
952 |
date.value.attribute
|
Patrick@350
|
953 |
& date.of.attribute?
|
Patrick@350
|
954 |
date.value.attribute = attribute value { xsd:date | xsd:gYearMonth | xsd:gYear }
|
Patrick@350
|
955 |
date.of.attribute = attribute of { "birth" | "death" }
|
Patrick@350
|
956 |
|
Patrick@350
|
957 |
date.content = mixed { sup* & number* & warning* }
|
Patrick@350
|
958 |
|
patrick@42
|
959 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ math ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
patrick@42
|
960 |
|
Patrick@274
|
961 |
# ~~~~~~ math
|
Patrick@274
|
962 |
math = element math { math.attributes, math.content }
|
patrick@42
|
963 |
|
patrick@42
|
964 |
math.attributes =
|
Patrick@280
|
965 |
xmlid.attribute?
|
Patrick@280
|
966 |
& math.display.attribute?
|
Patrick@274
|
967 |
math.display.attribute = attribute display {
|
Patrick@272
|
968 |
"wide" | "numbered" | "box" | "numbered-box" }
|
patrick@42
|
969 |
|
Patrick@274
|
970 |
math.content =
|
Patrick@274
|
971 |
mixed { sup* & sub* & var* & warning* }
|
Patrick@274
|
972 |
| latex
|
Patrick@274
|
973 |
|
Patrick@274
|
974 |
# ~~~~~~ latex
|
Patrick@274
|
975 |
latex = element latex { latex.attributes, latex.content }
|
Patrick@274
|
976 |
|
Patrick@274
|
977 |
latex.attributes =
|
Patrick@274
|
978 |
plain.attritute?
|
Patrick@274
|
979 |
plain.attritute = attribute plain { xsd:boolean }
|
Patrick@274
|
980 |
|
Patrick@274
|
981 |
latex.content = text
|
patrick@0
|
982 |
|
patrick@36
|
983 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ quote ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
patrick@5
|
984 |
|
patrick@5
|
985 |
quote = element quote { quote.content }
|
patrick@5
|
986 |
|
patrick@131
|
987 |
quote.content =
|
patrick@131
|
988 |
(phrase, attribution) | inlines
|
patrick@131
|
989 |
|
patrick@131
|
990 |
phrase = element phrase { phrase.content }
|
patrick@131
|
991 |
|
patrick@131
|
992 |
phrase.content = inlines
|
patrick@5
|
993 |
|
Patrick@351
|
994 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ initial ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
patrick@105
|
995 |
|
Patrick@351
|
996 |
initial = element initial { initial.content }
|
patrick@105
|
997 |
|
Patrick@351
|
998 |
initial.content =
|
Patrick@351
|
999 |
initial.c,
|
Patrick@351
|
1000 |
initial.w?
|
patrick@105
|
1001 |
|
Patrick@351
|
1002 |
initial.c = element c { text }
|
Patrick@351
|
1003 |
initial.w = element w { inlines }
|
Patrick@205
|
1004 |
|
Patrick@288
|
1005 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ note ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Patrick@288
|
1006 |
|
Patrick@288
|
1007 |
note = element note { note.attributes, note.content }
|
Patrick@288
|
1008 |
|
Patrick@288
|
1009 |
note.attributes =
|
Patrick@288
|
1010 |
note.label.attribute?
|
Patrick@288
|
1011 |
note.label.attribute = attribute label { text }
|
Patrick@288
|
1012 |
|
Patrick@288
|
1013 |
note.content =
|
Patrick@288
|
1014 |
(note.w?, block+)
|
Patrick@288
|
1015 |
| inlines
|
Patrick@288
|
1016 |
|
Patrick@288
|
1017 |
note.w = element w { inlines }
|
Patrick@288
|
1018 |
|
Patrick@288
|
1019 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ link ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Patrick@288
|
1020 |
|
Patrick@288
|
1021 |
link = element link { link.attributes, link.content }
|
Patrick@288
|
1022 |
|
Patrick@288
|
1023 |
link.attributes =
|
Patrick@288
|
1024 |
(uri.attribute | idref.attribute)
|
Patrick@288
|
1025 |
uri.attribute = attribute uri { xsd:anyURI }
|
Patrick@288
|
1026 |
idref.attribute = attribute idref { xsd:IDREF }
|
Patrick@288
|
1027 |
|
Patrick@288
|
1028 |
link.content = simple.inlines
|
Patrick@288
|
1029 |
|
Patrick@288
|
1030 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ anchor ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Patrick@288
|
1031 |
|
Patrick@288
|
1032 |
anchor = element anchor { anchor.attributes, anchor.content }
|
Patrick@288
|
1033 |
|
Patrick@288
|
1034 |
anchor.attributes =
|
Patrick@288
|
1035 |
anchor.id.attribute
|
Patrick@288
|
1036 |
anchor.id.attribute = attribute xml:id { xsd:ID }
|
Patrick@288
|
1037 |
|
Patrick@288
|
1038 |
anchor.content = simple.inlines
|
Patrick@288
|
1039 |
|
Coraline@419
|
1040 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ gloss ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Coraline@419
|
1041 |
|
Coraline@419
|
1042 |
gloss = element gloss { gloss.attributes, gloss.content }
|
Coraline@419
|
1043 |
|
Coraline@419
|
1044 |
gloss.attributes =
|
Coraline@419
|
1045 |
gloss.ref.attribute
|
Coraline@419
|
1046 |
gloss.ref.attribute = attribute ref { xsd:NCName }
|
Coraline@419
|
1047 |
|
Coraline@419
|
1048 |
gloss.content = simple.inlines
|
Coraline@419
|
1049 |
|
Patrick@351
|
1050 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ smil ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Patrick@351
|
1051 |
|
Patrick@351
|
1052 |
smil = element smil { smil.attributes, smil.content }
|
Patrick@351
|
1053 |
|
Patrick@351
|
1054 |
smil.attributes =
|
Patrick@351
|
1055 |
audio.attribute?
|
Patrick@351
|
1056 |
& begin.attribute?
|
Patrick@351
|
1057 |
& end.attribute?
|
Patrick@351
|
1058 |
audio.attribute = attribute audio { xsd:anyURI }
|
Patrick@351
|
1059 |
begin.attribute = attribute begin { xsd:decimal }
|
Patrick@351
|
1060 |
end.attribute = attribute end { xsd:decimal }
|
Patrick@351
|
1061 |
|
Patrick@351
|
1062 |
smil.content = inlines
|
Patrick@351
|
1063 |
|
Patrick@205
|
1064 |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ warning ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
Patrick@205
|
1065 |
|
Patrick@285
|
1066 |
warning = element warning { warning.attributes, warning.content }
|
Patrick@285
|
1067 |
|
Patrick@285
|
1068 |
warning.attributes =
|
Patrick@285
|
1069 |
warning.type.attribute?
|
Patrick@285
|
1070 |
warning.type.attribute = attribute type { xsd:NCName }
|
Patrick@205
|
1071 |
|
Patrick@231
|
1072 |
warning.content = inlines
|