Merge branch 'maint'
[org-mode.git] / etc / schema / od-schema-v1.2-os.rnc
blobc019fba56ac2c43c1dd30cc7b1af0b1834ddadcd
1 # Open Document Format for Office Applications (OpenDocument) Version 1.2
2 # OASIS Standard, 29 September 2011
3 # Relax-NG Schema
4 # Source: http://docs.oasis-open.org/office/v1.2/os/
5 # Copyright (c) OASIS Open 2002-2011, 2013. All Rights Reserved.
6
7 # All capitalized terms in the following text have the meanings assigned to them
8 # in the OASIS Intellectual Property Rights Policy (the "OASIS IPR Policy"). The
9 # full Policy may be found at the OASIS website.
10
11 # This document and translations of it may be copied and furnished to others, and
12 # derivative works that comment on or otherwise explain it or assist in its
13 # implementation may be prepared, copied, published, and distributed, in whole or
14 # in part, without restriction of any kind, provided that the above copyright
15 # notice and this section are included on all such copies and derivative works.
16 # However, this document itself may not be modified in any way, including by
17 # removing the copyright notice or references to OASIS, except as needed for the
18 # purpose of developing any document or deliverable produced by an OASIS
19 # Technical Committee (in which case the rules applicable to copyrights, as set
20 # forth in the OASIS IPR Policy, must be followed) or as required to translate it
21 # into languages other than English.
22
23 # The limited permissions granted above are perpetual and will not be revoked by
24 # OASIS or its successors or assigns.
25
26 # This document and the information contained herein is provided on an "AS IS"
27 # basis and OASIS DISCLAIMS ALL WARRANTIES, EXPRESS OR IMPLIED, INCLUDING BUT NOT
28 # LIMITED TO ANY WARRANTY THAT THE USE OF THE INFORMATION HEREIN WILL NOT
29 # INFRINGE ANY OWNERSHIP RIGHTS OR ANY IMPLIED WARRANTIES OF MERCHANTABILITY OR
30 # FITNESS FOR A PARTICULAR PURPOSE. 
32 namespace anim = "urn:oasis:names:tc:opendocument:xmlns:animation:1.0"
33 namespace chart = "urn:oasis:names:tc:opendocument:xmlns:chart:1.0"
34 namespace config = "urn:oasis:names:tc:opendocument:xmlns:config:1.0"
35 namespace db = "urn:oasis:names:tc:opendocument:xmlns:database:1.0"
36 namespace dc = "http://purl.org/dc/elements/1.1/"
37 namespace dr3d = "urn:oasis:names:tc:opendocument:xmlns:dr3d:1.0"
38 namespace draw = "urn:oasis:names:tc:opendocument:xmlns:drawing:1.0"
39 namespace fo =
40   "urn:oasis:names:tc:opendocument:xmlns:xsl-fo-compatible:1.0"
41 namespace form = "urn:oasis:names:tc:opendocument:xmlns:form:1.0"
42 namespace grddl = "http://www.w3.org/2003/g/data-view#"
43 namespace math = "http://www.w3.org/1998/Math/MathML"
44 namespace meta = "urn:oasis:names:tc:opendocument:xmlns:meta:1.0"
45 namespace number = "urn:oasis:names:tc:opendocument:xmlns:datastyle:1.0"
46 namespace office = "urn:oasis:names:tc:opendocument:xmlns:office:1.0"
47 namespace presentation =
48   "urn:oasis:names:tc:opendocument:xmlns:presentation:1.0"
49 namespace script = "urn:oasis:names:tc:opendocument:xmlns:script:1.0"
50 namespace smil =
51   "urn:oasis:names:tc:opendocument:xmlns:smil-compatible:1.0"
52 namespace style = "urn:oasis:names:tc:opendocument:xmlns:style:1.0"
53 namespace svg =
54   "urn:oasis:names:tc:opendocument:xmlns:svg-compatible:1.0"
55 namespace table = "urn:oasis:names:tc:opendocument:xmlns:table:1.0"
56 namespace text = "urn:oasis:names:tc:opendocument:xmlns:text:1.0"
57 namespace xforms = "http://www.w3.org/2002/xforms"
58 namespace xhtml = "http://www.w3.org/1999/xhtml"
59 namespace xlink = "http://www.w3.org/1999/xlink"
61 office-process-content = attribute office:process-content { boolean }?
62 start =
63   office-document
64   | office-document-content
65   | office-document-styles
66   | office-document-meta
67   | office-document-settings
68 office-document =
69   element office:document {
70     office-document-attrs,
71     office-document-common-attrs,
72     office-meta,
73     office-settings,
74     office-scripts,
75     office-font-face-decls,
76     office-styles,
77     office-automatic-styles,
78     office-master-styles,
79     office-body
80   }
81 office-document-content =
82   element office:document-content {
83     office-document-common-attrs,
84     office-scripts,
85     office-font-face-decls,
86     office-automatic-styles,
87     office-body
88   }
89 office-document-styles =
90   element office:document-styles {
91     office-document-common-attrs,
92     office-font-face-decls,
93     office-styles,
94     office-automatic-styles,
95     office-master-styles
96   }
97 office-document-meta =
98   element office:document-meta {
99     office-document-common-attrs, office-meta
100   }
101 office-document-settings =
102   element office:document-settings {
103     office-document-common-attrs, office-settings
104   }
105 office-document-common-attrs =
106   attribute office:version { "1.2" }
107   & attribute grddl:transformation {
108       list { anyIRI* }
109     }?
110 office-document-attrs = attribute office:mimetype { \string }
111 office-meta = element office:meta { office-meta-content-strict }?
112 office-meta-content-strict = office-meta-data*
113 office-body = element office:body { office-body-content }
114 office-body-content =
115   element office:text {
116     office-text-attlist,
117     office-text-content-prelude,
118     office-text-content-main,
119     office-text-content-epilogue
120   }
121   | element office:drawing {
122       office-drawing-attlist,
123       office-drawing-content-prelude,
124       office-drawing-content-main,
125       office-drawing-content-epilogue
126     }
127   | element office:presentation {
128       office-presentation-attlist,
129       office-presentation-content-prelude,
130       office-presentation-content-main,
131       office-presentation-content-epilogue
132     }
133   | element office:spreadsheet {
134       office-spreadsheet-attlist,
135       office-spreadsheet-content-prelude,
136       office-spreadsheet-content-main,
137       office-spreadsheet-content-epilogue
138     }
139   | element office:chart {
140       office-chart-attlist,
141       office-chart-content-prelude,
142       office-chart-content-main,
143       office-chart-content-epilogue
144     }
145   | element office:image {
146       office-image-attlist,
147       office-image-content-prelude,
148       office-image-content-main,
149       office-image-content-epilogue
150     }
151   | office-database
152 office-text-content-prelude =
153   office-forms, text-tracked-changes, text-decls, table-decls
154 office-text-content-main =
155   text-content*
156   | (text-page-sequence, (shape)*)
157 text-content =
158   text-h
159   | text-p
160   | text-list
161   | text-numbered-paragraph
162   | table-table
163   | text-section
164   | text-soft-page-break
165   | text-table-of-content
166   | text-illustration-index
167   | text-table-index
168   | text-object-index
169   | text-user-index
170   | text-alphabetical-index
171   | text-bibliography
172   | shape
173   | change-marks
174 office-text-content-epilogue = table-functions
175 office-text-attlist =
176   attribute text:global { boolean }?
177   & attribute text:use-soft-page-breaks { boolean }?
178 office-drawing-attlist = empty
179 office-drawing-content-prelude = text-decls, table-decls
180 office-drawing-content-main = draw-page*
181 office-drawing-content-epilogue = table-functions
182 office-presentation-attlist = empty
183 office-presentation-content-prelude =
184   text-decls, table-decls, presentation-decls
185 office-presentation-content-main = draw-page*
186 office-presentation-content-epilogue =
187   presentation-settings, table-functions
188 office-spreadsheet-content-prelude =
189   table-tracked-changes?, text-decls, table-decls
190 table-decls =
191   table-calculation-settings?,
192   table-content-validations?,
193   table-label-ranges?
194 office-spreadsheet-content-main = table-table*
195 office-spreadsheet-content-epilogue = table-functions
196 table-functions =
197   table-named-expressions?,
198   table-database-ranges?,
199   table-data-pilot-tables?,
200   table-consolidation?,
201   table-dde-links?
202 office-chart-attlist = empty
203 office-chart-content-prelude = text-decls, table-decls
204 office-chart-content-main = chart-chart
205 office-chart-content-epilogue = table-functions
206 office-image-attlist = empty
207 office-image-content-prelude = empty
208 office-image-content-main = draw-frame
209 office-image-content-epilogue = empty
210 office-settings = element office:settings { config-config-item-set+ }?
211 config-config-item-set =
212   element config:config-item-set {
213     config-config-item-set-attlist, config-items
214   }
215 config-items =
216   (config-config-item
217    | config-config-item-set
218    | config-config-item-map-named
219    | config-config-item-map-indexed)+
220 config-config-item-set-attlist = attribute config:name { \string }
221 config-config-item =
222   element config:config-item { config-config-item-attlist, text }
223 config-config-item-attlist =
224   attribute config:name { \string }
225   & attribute config:type {
226       "boolean"
227       | "short"
228       | "int"
229       | "long"
230       | "double"
231       | "string"
232       | "datetime"
233       | "base64Binary"
234     }
235 config-config-item-map-indexed =
236   element config:config-item-map-indexed {
237     config-config-item-map-indexed-attlist,
238     config-config-item-map-entry+
239   }
240 config-config-item-map-indexed-attlist =
241   attribute config:name { \string }
242 config-config-item-map-entry =
243   element config:config-item-map-entry {
244     config-config-item-map-entry-attlist, config-items
245   }
246 config-config-item-map-entry-attlist =
247   attribute config:name { \string }?
248 config-config-item-map-named =
249   element config:config-item-map-named {
250     config-config-item-map-named-attlist, config-config-item-map-entry+
251   }
252 config-config-item-map-named-attlist = attribute config:name { \string }
253 office-scripts =
254   element office:scripts { office-script*, office-event-listeners? }?
255 office-script =
256   element office:script {
257     office-script-attlist,
258     mixed { anyElements }
259   }
260 office-script-attlist = attribute script:language { \string }
261 office-font-face-decls =
262   element office:font-face-decls { style-font-face* }?
263 office-styles =
264   element office:styles {
265     styles
266     & style-default-style*
267     & style-default-page-layout?
268     & text-outline-style?
269     & text-notes-configuration*
270     & text-bibliography-configuration?
271     & text-linenumbering-configuration?
272     & draw-gradient*
273     & svg-linearGradient*
274     & svg-radialGradient*
275     & draw-hatch*
276     & draw-fill-image*
277     & draw-marker*
278     & draw-stroke-dash*
279     & draw-opacity*
280     & style-presentation-page-layout*
281     & table-table-template*
282   }?
283 office-automatic-styles =
284   element office:automatic-styles { styles & style-page-layout* }?
285 office-master-styles =
286   element office:master-styles {
287     style-master-page* & style-handout-master? & draw-layer-set?
288   }?
289 styles =
290   style-style*
291   & text-list-style*
292   & number-number-style*
293   & number-currency-style*
294   & number-percentage-style*
295   & number-date-style*
296   & number-time-style*
297   & number-boolean-style*
298   & number-text-style*
299 office-meta-data =
300   element meta:generator { \string }
301   | element dc:title { \string }
302   | element dc:description { \string }
303   | element dc:subject { \string }
304   | element meta:keyword { \string }
305   | element meta:initial-creator { \string }
306   | dc-creator
307   | element meta:printed-by { \string }
308   | element meta:creation-date { dateTime }
309   | dc-date
310   | element meta:print-date { dateTime }
311   | element meta:template {
312       attribute xlink:type { "simple" },
313       attribute xlink:href { anyIRI },
314       attribute xlink:actuate { "onRequest" }?,
315       attribute xlink:title { \string }?,
316       attribute meta:date { dateTime }?
317     }
318   | element meta:auto-reload {
319       (attribute xlink:type { "simple" },
320        attribute xlink:href { anyIRI },
321        attribute xlink:show { "replace" }?,
322        attribute xlink:actuate { "onLoad" }?)?,
323       attribute meta:delay { duration }?
324     }
325   | element meta:hyperlink-behaviour {
326       attribute office:target-frame-name { targetFrameName }?,
327       attribute xlink:show { "new" | "replace" }?
328     }
329   | element dc:language { language }
330   | element meta:editing-cycles { nonNegativeInteger }
331   | element meta:editing-duration { duration }
332   | element meta:document-statistic {
333       attribute meta:page-count { nonNegativeInteger }?,
334       attribute meta:table-count { nonNegativeInteger }?,
335       attribute meta:draw-count { nonNegativeInteger }?,
336       attribute meta:image-count { nonNegativeInteger }?,
337       attribute meta:ole-object-count { nonNegativeInteger }?,
338       attribute meta:object-count { nonNegativeInteger }?,
339       attribute meta:paragraph-count { nonNegativeInteger }?,
340       attribute meta:word-count { nonNegativeInteger }?,
341       attribute meta:character-count { nonNegativeInteger }?,
342       attribute meta:frame-count { nonNegativeInteger }?,
343       attribute meta:sentence-count { nonNegativeInteger }?,
344       attribute meta:syllable-count { nonNegativeInteger }?,
345       attribute meta:non-whitespace-character-count {
346         nonNegativeInteger
347       }?,
348       attribute meta:row-count { nonNegativeInteger }?,
349       attribute meta:cell-count { nonNegativeInteger }?
350     }
351   | element meta:user-defined {
352       attribute meta:name { \string },
353       ((attribute meta:value-type { "float" },
354         double)
355        | (attribute meta:value-type { "date" },
356           dateOrDateTime)
357        | (attribute meta:value-type { "time" },
358           duration)
359        | (attribute meta:value-type { "boolean" },
360           boolean)
361        | (attribute meta:value-type { "string" },
362           \string)
363        | text)
364     }
365 dc-creator = element dc:creator { \string }
366 dc-date = element dc:date { dateTime }
367 text-h =
368   element text:h {
369     heading-attrs,
370     paragraph-attrs,
371     text-number?,
372     paragraph-content-or-hyperlink*
373   }
374 heading-attrs =
375   attribute text:outline-level { positiveInteger }
376   & attribute text:restart-numbering { boolean }?
377   & attribute text:start-value { nonNegativeInteger }?
378   & attribute text:is-list-header { boolean }?
379 text-number = element text:number { \string }
380 text-p =
381   element text:p { paragraph-attrs, paragraph-content-or-hyperlink* }
382 paragraph-attrs =
383   attribute text:style-name { styleNameRef }?
384   & attribute text:class-names { styleNameRefs }?
385   & attribute text:cond-style-name { styleNameRef }?
386   & (xml-id,
387      attribute text:id { NCName }?)?
388   & common-in-content-meta-attlist?
389 text-page-sequence = element text:page-sequence { text-page+ }
390 text-page = element text:page { text-page-attlist, empty }
391 text-page-attlist = attribute text:master-page-name { styleNameRef }
392 text-list =
393   element text:list {
394     text-list-attr, text-list-header?, text-list-item*
395   }
396 text-list-attr =
397   attribute text:style-name { styleNameRef }?
398   & attribute text:continue-numbering { boolean }?
399   & attribute text:continue-list { IDREF }?
400   & xml-id?
401 text-list-item =
402   element text:list-item { text-list-item-attr, text-list-item-content }
403 text-list-item-content =
404   text-number?, (text-p | text-h | text-list | text-soft-page-break)*
405 text-list-item-attr =
406   attribute text:start-value { nonNegativeInteger }?
407   & attribute text:style-override { styleNameRef }?
408   & xml-id?
409 text-list-header =
410   element text:list-header {
411     text-list-header-attr, text-list-item-content
412   }
413 text-list-header-attr = xml-id?
414 text-numbered-paragraph =
415   element text:numbered-paragraph {
416     text-numbered-paragraph-attr, text-number?, (text-p | text-h)
417   }
418 text-numbered-paragraph-attr =
419   attribute text:list-id { NCName }
420   & attribute text:level { positiveInteger }?
421   & (attribute text:style-name { styleNameRef },
422      attribute text:continue-numbering { boolean },
423      attribute text:start-value { nonNegativeInteger })?
424   & xml-id?
425 text-section =
426   element text:section {
427     text-section-attlist,
428     (text-section-source | text-section-source-dde | empty),
429     text-content*
430   }
431 text-section-attlist =
432   common-section-attlist
433   & (attribute text:display { "true" | "none" }
434      | (attribute text:display { "condition" },
435         attribute text:condition { \string })
436      | empty)
437 common-section-attlist =
438   attribute text:style-name { styleNameRef }?
439   & attribute text:name { \string }
440   & attribute text:protected { boolean }?
441   & attribute text:protection-key { \string }?
442   & attribute text:protection-key-digest-algorithm { anyIRI }?
443   & xml-id?
444 text-section-source =
445   element text:section-source { text-section-source-attr }
446 text-section-source-attr =
447   (attribute xlink:type { "simple" },
448    attribute xlink:href { anyIRI },
449    attribute xlink:show { "embed" }?)?
450   & attribute text:section-name { \string }?
451   & attribute text:filter-name { \string }?
452 text-section-source-dde = office-dde-source
453 text-tracked-changes =
454   element text:tracked-changes {
455     text-tracked-changes-attr, text-changed-region*
456   }?
457 text-tracked-changes-attr = attribute text:track-changes { boolean }?
458 text-changed-region =
459   element text:changed-region {
460     text-changed-region-attr, text-changed-region-content
461   }
462 text-changed-region-attr =
463   xml-id,
464   attribute text:id { NCName }?
465 text-changed-region-content =
466   element text:insertion { office-change-info }
467   | element text:deletion { office-change-info, text-content* }
468   | element text:format-change { office-change-info }
469 change-marks =
470   element text:change { change-mark-attr }
471   | element text:change-start { change-mark-attr }
472   | element text:change-end { change-mark-attr }
473 change-mark-attr = attribute text:change-id { IDREF }
474 text-soft-page-break = element text:soft-page-break { empty }
475 text-decls =
476   element text:variable-decls { text-variable-decl* }?,
477   element text:sequence-decls { text-sequence-decl* }?,
478   element text:user-field-decls { text-user-field-decl* }?,
479   element text:dde-connection-decls { text-dde-connection-decl* }?,
480   text-alphabetical-index-auto-mark-file?
481 paragraph-content-or-hyperlink = paragraph-content | text-a
482 paragraph-content =
483   text
484   | element text:s {
485       attribute text:c { nonNegativeInteger }?
486     }
487   | element text:tab { text-tab-attr }
488   | element text:line-break { empty }
489   | text-soft-page-break
490   | element text:span {
491       attribute text:style-name { styleNameRef }?,
492       attribute text:class-names { styleNameRefs }?,
493       paragraph-content-or-hyperlink*
494     }
495   | element text:meta {
496       text-meta-attlist, paragraph-content-or-hyperlink*
497     }
498   | (text-bookmark | text-bookmark-start | text-bookmark-end)
499   | element text:reference-mark {
500       attribute text:name { \string }
501     }
502   | (element text:reference-mark-start {
503        attribute text:name { \string }
504      }
505      | element text:reference-mark-end {
506          attribute text:name { \string }
507        })
508   | element text:note {
509       text-note-class,
510       attribute text:id { \string }?,
511       element text:note-citation {
512         attribute text:label { \string }?,
513         text
514       },
515       element text:note-body { text-content* }
516     }
517   | element text:ruby {
518       attribute text:style-name { styleNameRef }?,
519       element text:ruby-base { paragraph-content-or-hyperlink* },
520       element text:ruby-text {
521         attribute text:style-name { styleNameRef }?,
522         text
523       }
524     }
525   | (office-annotation | office-annotation-end)
526   | change-marks
527   | shape
528   | element text:date { text-date-attlist, text }
529   | element text:time { text-time-attlist, text }
530   | element text:page-number { text-page-number-attlist, text }
531   | element text:page-continuation {
532       text-page-continuation-attlist, text
533     }
534   | element text:sender-firstname { common-field-fixed-attlist, text }
535   | element text:sender-lastname { common-field-fixed-attlist, text }
536   | element text:sender-initials { common-field-fixed-attlist, text }
537   | element text:sender-title { common-field-fixed-attlist, text }
538   | element text:sender-position { common-field-fixed-attlist, text }
539   | element text:sender-email { common-field-fixed-attlist, text }
540   | element text:sender-phone-private {
541       common-field-fixed-attlist, text
542     }
543   | element text:sender-fax { common-field-fixed-attlist, text }
544   | element text:sender-company { common-field-fixed-attlist, text }
545   | element text:sender-phone-work { common-field-fixed-attlist, text }
546   | element text:sender-street { common-field-fixed-attlist, text }
547   | element text:sender-city { common-field-fixed-attlist, text }
548   | element text:sender-postal-code { common-field-fixed-attlist, text }
549   | element text:sender-country { common-field-fixed-attlist, text }
550   | element text:sender-state-or-province {
551       common-field-fixed-attlist, text
552     }
553   | element text:author-name { common-field-fixed-attlist, text }
554   | element text:author-initials { common-field-fixed-attlist, text }
555   | element text:chapter { text-chapter-attlist, text }
556   | element text:file-name { text-file-name-attlist, text }
557   | element text:template-name { text-template-name-attlist, text }
558   | element text:sheet-name { text }
559   | element text:variable-set {
560       (common-field-name-attlist
561        & common-field-formula-attlist
562        & common-value-and-type-attlist
563        & common-field-display-value-none-attlist
564        & common-field-data-style-name-attlist),
565       text
566     }
567   | element text:variable-get {
568       (common-field-name-attlist
569        & common-field-display-value-formula-attlist
570        & common-field-data-style-name-attlist),
571       text
572     }
573   | element text:variable-input {
574       (common-field-name-attlist
575        & common-field-description-attlist
576        & common-value-type-attlist
577        & common-field-display-value-none-attlist
578        & common-field-data-style-name-attlist),
579       text
580     }
581   | element text:user-field-get {
582       (common-field-name-attlist
583        & common-field-display-value-formula-none-attlist
584        & common-field-data-style-name-attlist),
585       text
586     }
587   | element text:user-field-input {
588       (common-field-name-attlist
589        & common-field-description-attlist
590        & common-field-data-style-name-attlist),
591       text
592     }
593   | element text:sequence {
594       (common-field-name-attlist
595        & common-field-formula-attlist
596        & common-field-num-format-attlist
597        & text-sequence-ref-name),
598       text
599     }
600   | element text:expression {
601       (common-field-formula-attlist
602        & common-value-and-type-attlist?
603        & common-field-display-value-formula-attlist
604        & common-field-data-style-name-attlist),
605       text
606     }
607   | element text:text-input { common-field-description-attlist, text }
608   | element text:initial-creator { common-field-fixed-attlist, text }
609   | element text:creation-date {
610       (common-field-fixed-attlist
611        & common-field-data-style-name-attlist
612        & attribute text:date-value { dateOrDateTime }?),
613       text
614     }
615   | element text:creation-time {
616       (common-field-fixed-attlist
617        & common-field-data-style-name-attlist
618        & attribute text:time-value { timeOrDateTime }?),
619       text
620     }
621   | element text:description { common-field-fixed-attlist, text }
622   | element text:user-defined {
623       (common-field-fixed-attlist
624        & attribute text:name { \string }
625        & common-field-data-style-name-attlist
626        & attribute office:value { double }?
627        & attribute office:date-value { dateOrDateTime }?
628        & attribute office:time-value { duration }?
629        & attribute office:boolean-value { boolean }?
630        & attribute office:string-value { \string }?),
631       text
632     }
633   | element text:print-time {
634       (common-field-fixed-attlist
635        & common-field-data-style-name-attlist
636        & attribute text:time-value { time }?),
637       text
638     }
639   | element text:print-date {
640       (common-field-fixed-attlist
641        & common-field-data-style-name-attlist
642        & attribute text:date-value { date }?),
643       text
644     }
645   | element text:printed-by { common-field-fixed-attlist, text }
646   | element text:title { common-field-fixed-attlist, text }
647   | element text:subject { common-field-fixed-attlist, text }
648   | element text:keywords { common-field-fixed-attlist, text }
649   | element text:editing-cycles { common-field-fixed-attlist, text }
650   | element text:editing-duration {
651       (common-field-fixed-attlist
652        & common-field-data-style-name-attlist
653        & attribute text:duration { duration }?),
654       text
655     }
656   | element text:modification-time {
657       (common-field-fixed-attlist
658        & common-field-data-style-name-attlist
659        & attribute text:time-value { time }?),
660       text
661     }
662   | element text:modification-date {
663       (common-field-fixed-attlist
664        & common-field-data-style-name-attlist
665        & attribute text:date-value { date }?),
666       text
667     }
668   | element text:creator { common-field-fixed-attlist, text }
669   | element text:page-count
670             | text:paragraph-count
671             | text:word-count
672             | text:character-count
673             | text:table-count
674             | text:image-count
675             | text:object-count {
676       common-field-num-format-attlist, text
677     }
678   | element text:database-display {
679       text-database-display-attlist, text
680     }
681   | element text:database-next { text-database-next-attlist }
682   | element text:database-row-select {
683       text-database-row-select-attlist
684     }
685   | element text:database-row-number {
686       (common-field-database-table
687        & common-field-num-format-attlist
688        & attribute text:value { nonNegativeInteger }?),
689       text
690     }
691   | element text:database-name { common-field-database-table, text }
692   | element text:page-variable-set {
693       text-set-page-variable-attlist, text
694     }
695   | element text:page-variable-get {
696       text-get-page-variable-attlist, text
697     }
698   | element text:placeholder { text-placeholder-attlist, text }
699   | element text:conditional-text {
700       text-conditional-text-attlist, text
701     }
702   | element text:hidden-text { text-hidden-text-attlist, text }
703   | element text:reference-ref | text:bookmark-ref {
704       text-common-ref-content & text-bookmark-ref-content
705     }
706   | element text:note-ref {
707       text-common-ref-content & text-note-ref-content
708     }
709   | element text:sequence-ref {
710       text-common-ref-content & text-sequence-ref-content
711     }
712   | element text:script {
713       ((attribute xlink:type { "simple" },
714         attribute xlink:href { anyIRI })
715        | text)
716       & attribute script:language { \string }?
717     }
718   | element text:execute-macro {
719       attribute text:name { \string }?,
720       office-event-listeners?,
721       text
722     }
723   | element text:hidden-paragraph {
724       text-hidden-paragraph-attlist, text
725     }
726   | element text:dde-connection {
727       attribute text:connection-name { \string },
728       text
729     }
730   | element text:measure {
731       attribute text:kind { "value" | "unit" | "gap" },
732       text
733     }
734   | element text:table-formula {
735       (common-field-formula-attlist
736        & common-field-display-value-formula-attlist
737        & common-field-data-style-name-attlist),
738       text
739     }
740   | element text:meta-field {
741       text-meta-field-attlist, paragraph-content-or-hyperlink*
742     }
743   | element text:toc-mark-start { text-toc-mark-start-attrs }
744   | element text:toc-mark-end { text-id }
745   | element text:toc-mark {
746       attribute text:string-value { \string },
747       text-outline-level
748     }
749   | element text:user-index-mark-start {
750       text-id, text-outline-level, text-index-name
751     }
752   | element text:user-index-mark-end { text-id }
753   | element text:user-index-mark {
754       attribute text:string-value { \string },
755       text-outline-level,
756       text-index-name
757     }
758   | element text:alphabetical-index-mark-start {
759       text-id, text-alphabetical-index-mark-attrs
760     }
761   | element text:alphabetical-index-mark-end { text-id }
762   | element text:alphabetical-index-mark {
763       attribute text:string-value { \string },
764       text-alphabetical-index-mark-attrs
765     }
766   | element text:bibliography-mark {
767       attribute text:bibliography-type { text-bibliography-types },
768       attribute text:identifier
769                 | text:address
770                 | text:annote
771                 | text:author
772                 | text:booktitle
773                 | text:chapter
774                 | text:edition
775                 | text:editor
776                 | text:howpublished
777                 | text:institution
778                 | text:journal
779                 | text:month
780                 | text:note
781                 | text:number
782                 | text:organizations
783                 | text:pages
784                 | text:publisher
785                 | text:school
786                 | text:series
787                 | text:title
788                 | text:report-type
789                 | text:volume
790                 | text:year
791                 | text:url
792                 | text:custom1
793                 | text:custom2
794                 | text:custom3
795                 | text:custom4
796                 | text:custom5
797                 | text:isbn
798                 | text:issn { \string }*,
799       text
800     }
801   | element presentation:header { empty }
802   | element presentation:footer { empty }
803   | element presentation:date-time { empty }
804 text-tab-attr = attribute text:tab-ref { nonNegativeInteger }?
805 text-a =
806   element text:a {
807     text-a-attlist, office-event-listeners?, paragraph-content*
808   }
809 text-a-attlist =
810   attribute office:name { \string }?
811   & attribute office:title { \string }?
812   & attribute xlink:type { "simple" }
813   & attribute xlink:href { anyIRI }
814   & attribute xlink:actuate { "onRequest" }?
815   & attribute office:target-frame-name { targetFrameName }?
816   & attribute xlink:show { "new" | "replace" }?
817   & attribute text:style-name { styleNameRef }?
818   & attribute text:visited-style-name { styleNameRef }?
819 text-meta-attlist = common-in-content-meta-attlist? & xml-id?
820 text-bookmark = element text:bookmark { text-bookmark-attlist, empty }
821 text-bookmark-start =
822   element text:bookmark-start { text-bookmark-start-attlist, empty }
823 text-bookmark-end =
824   element text:bookmark-end { text-bookmark-end-attlist, empty }
825 text-bookmark-attlist =
826   attribute text:name { \string }
827   & xml-id?
828 text-bookmark-start-attlist =
829   attribute text:name { \string }
830   & xml-id?
831   & common-in-content-meta-attlist?
832 text-bookmark-end-attlist = attribute text:name { \string }
833 text-note-class = attribute text:note-class { "footnote" | "endnote" }
834 text-date-attlist =
835   (common-field-fixed-attlist & common-field-data-style-name-attlist)
836   & attribute text:date-value { dateOrDateTime }?
837   & attribute text:date-adjust { duration }?
838 text-time-attlist =
839   (common-field-fixed-attlist & common-field-data-style-name-attlist)
840   & attribute text:time-value { timeOrDateTime }?
841   & attribute text:time-adjust { duration }?
842 text-page-number-attlist =
843   (common-field-num-format-attlist & common-field-fixed-attlist)
844   & attribute text:page-adjust { integer }?
845   & attribute text:select-page { "previous" | "current" | "next" }?
846 text-page-continuation-attlist =
847   attribute text:select-page { "previous" | "next" }
848   & attribute text:string-value { \string }?
849 text-chapter-attlist =
850   attribute text:display {
851     "name"
852     | "number"
853     | "number-and-name"
854     | "plain-number-and-name"
855     | "plain-number"
856   }
857   & attribute text:outline-level { nonNegativeInteger }
858 text-file-name-attlist =
859   attribute text:display {
860     "full" | "path" | "name" | "name-and-extension"
861   }?
862   & common-field-fixed-attlist
863 text-template-name-attlist =
864   attribute text:display {
865     "full" | "path" | "name" | "name-and-extension" | "area" | "title"
866   }?
867 text-variable-decl =
868   element text:variable-decl {
869     common-field-name-attlist, common-value-type-attlist
870   }
871 text-user-field-decl =
872   element text:user-field-decl {
873     common-field-name-attlist,
874     common-field-formula-attlist?,
875     common-value-and-type-attlist
876   }
877 text-sequence-decl =
878   element text:sequence-decl { text-sequence-decl-attlist }
879 text-sequence-decl-attlist =
880   common-field-name-attlist
881   & attribute text:display-outline-level { nonNegativeInteger }
882   & attribute text:separation-character { character }?
883 text-sequence-ref-name = attribute text:ref-name { \string }?
884 common-field-database-table =
885   common-field-database-table-attlist, common-field-database-name
886 common-field-database-name =
887   attribute text:database-name { \string }?
888   | form-connection-resource
889 common-field-database-table-attlist =
890   attribute text:table-name { \string }
891   & attribute text:table-type { "table" | "query" | "command" }?
892 text-database-display-attlist =
893   common-field-database-table
894   & common-field-data-style-name-attlist
895   & attribute text:column-name { \string }
896 text-database-next-attlist =
897   common-field-database-table
898   & attribute text:condition { \string }?
899 text-database-row-select-attlist =
900   common-field-database-table
901   & attribute text:condition { \string }?
902   & attribute text:row-number { nonNegativeInteger }?
903 text-set-page-variable-attlist =
904   attribute text:active { boolean }?
905   & attribute text:page-adjust { integer }?
906 text-get-page-variable-attlist = common-field-num-format-attlist
907 text-placeholder-attlist =
908   attribute text:placeholder-type {
909     "text" | "table" | "text-box" | "image" | "object"
910   }
911   & common-field-description-attlist
912 text-conditional-text-attlist =
913   attribute text:condition { \string }
914   & attribute text:string-value-if-true { \string }
915   & attribute text:string-value-if-false { \string }
916   & attribute text:current-value { boolean }?
917 text-hidden-text-attlist =
918   attribute text:condition { \string }
919   & attribute text:string-value { \string }
920   & attribute text:is-hidden { boolean }?
921 text-common-ref-content =
922   text
923   & attribute text:ref-name { \string }?
924 text-bookmark-ref-content =
925   attribute text:reference-format {
926     common-ref-format-values
927     | "number-no-superior"
928     | "number-all-superior"
929     | "number"
930   }?
931 text-note-ref-content =
932   attribute text:reference-format { common-ref-format-values }?
933   & text-note-class
934 text-sequence-ref-content =
935   attribute text:reference-format {
936     common-ref-format-values
937     | "category-and-value"
938     | "caption"
939     | "value"
940   }?
941 common-ref-format-values = "page" | "chapter" | "direction" | "text"
942 text-hidden-paragraph-attlist =
943   attribute text:condition { \string }
944   & attribute text:is-hidden { boolean }?
945 text-meta-field-attlist = xml-id & common-field-data-style-name-attlist
946 common-value-type-attlist = attribute office:value-type { valueType }
947 common-value-and-type-attlist =
948   (attribute office:value-type { "float" },
949    attribute office:value { double })
950   | (attribute office:value-type { "percentage" },
951      attribute office:value { double })
952   | (attribute office:value-type { "currency" },
953      attribute office:value { double },
954      attribute office:currency { \string }?)
955   | (attribute office:value-type { "date" },
956      attribute office:date-value { dateOrDateTime })
957   | (attribute office:value-type { "time" },
958      attribute office:time-value { duration })
959   | (attribute office:value-type { "boolean" },
960      attribute office:boolean-value { boolean })
961   | (attribute office:value-type { "string" },
962      attribute office:string-value { \string }?)
963 common-field-fixed-attlist = attribute text:fixed { boolean }?
964 common-field-name-attlist = attribute text:name { variableName }
965 common-field-description-attlist =
966   attribute text:description { \string }?
967 common-field-display-value-none-attlist =
968   attribute text:display { "value" | "none" }?
969 common-field-display-value-formula-none-attlist =
970   attribute text:display { "value" | "formula" | "none" }?
971 common-field-display-value-formula-attlist =
972   attribute text:display { "value" | "formula" }?
973 common-field-formula-attlist = attribute text:formula { \string }?
974 common-field-data-style-name-attlist =
975   attribute style:data-style-name { styleNameRef }?
976 common-field-num-format-attlist = common-num-format-attlist?
977 text-toc-mark-start-attrs = text-id, text-outline-level
978 text-outline-level = attribute text:outline-level { positiveInteger }?
979 text-id = attribute text:id { \string }
980 text-index-name = attribute text:index-name { \string }
981 text-alphabetical-index-mark-attrs =
982   attribute text:key1 { \string }?
983   & attribute text:key2 { \string }?
984   & attribute text:string-value-phonetic { \string }?
985   & attribute text:key1-phonetic { \string }?
986   & attribute text:key2-phonetic { \string }?
987   & attribute text:main-entry { boolean }?
988 text-bibliography-types =
989   "article"
990   | "book"
991   | "booklet"
992   | "conference"
993   | "custom1"
994   | "custom2"
995   | "custom3"
996   | "custom4"
997   | "custom5"
998   | "email"
999   | "inbook"
1000   | "incollection"
1001   | "inproceedings"
1002   | "journal"
1003   | "manual"
1004   | "mastersthesis"
1005   | "misc"
1006   | "phdthesis"
1007   | "proceedings"
1008   | "techreport"
1009   | "unpublished"
1010   | "www"
1011 text-index-body = element text:index-body { index-content-main* }
1012 index-content-main = text-content | text-index-title
1013 text-index-title =
1014   element text:index-title {
1015     common-section-attlist, index-content-main*
1016   }
1017 text-table-of-content =
1018   element text:table-of-content {
1019     common-section-attlist,
1020     text-table-of-content-source,
1021     text-index-body
1022   }
1023 text-table-of-content-source =
1024   element text:table-of-content-source {
1025     text-table-of-content-source-attlist,
1026     text-index-title-template?,
1027     text-table-of-content-entry-template*,
1028     text-index-source-styles*
1029   }
1030 text-table-of-content-source-attlist =
1031   attribute text:outline-level { positiveInteger }?
1032   & attribute text:use-outline-level { boolean }?
1033   & attribute text:use-index-marks { boolean }?
1034   & attribute text:use-index-source-styles { boolean }?
1035   & attribute text:index-scope { "document" | "chapter" }?
1036   & attribute text:relative-tab-stop-position { boolean }?
1037 text-table-of-content-entry-template =
1038   element text:table-of-content-entry-template {
1039     text-table-of-content-entry-template-attlist,
1040     text-table-of-content-children*
1041   }
1042 text-table-of-content-children =
1043   text-index-entry-chapter
1044   | text-index-entry-page-number
1045   | text-index-entry-text
1046   | text-index-entry-span
1047   | text-index-entry-tab-stop
1048   | text-index-entry-link-start
1049   | text-index-entry-link-end
1050 text-table-of-content-entry-template-attlist =
1051   attribute text:outline-level { positiveInteger }
1052   & attribute text:style-name { styleNameRef }
1053 text-illustration-index =
1054   element text:illustration-index {
1055     common-section-attlist,
1056     text-illustration-index-source,
1057     text-index-body
1058   }
1059 text-illustration-index-source =
1060   element text:illustration-index-source {
1061     text-illustration-index-source-attrs,
1062     text-index-title-template?,
1063     text-illustration-index-entry-template?
1064   }
1065 text-illustration-index-source-attrs =
1066   text-index-scope-attr
1067   & text-relative-tab-stop-position-attr
1068   & attribute text:use-caption { boolean }?
1069   & attribute text:caption-sequence-name { \string }?
1070   & attribute text:caption-sequence-format {
1071       "text" | "category-and-value" | "caption"
1072     }?
1073 text-index-scope-attr =
1074   attribute text:index-scope { "document" | "chapter" }?
1075 text-relative-tab-stop-position-attr =
1076   attribute text:relative-tab-stop-position { boolean }?
1077 text-illustration-index-entry-template =
1078   element text:illustration-index-entry-template {
1079     text-illustration-index-entry-content
1080   }
1081 text-illustration-index-entry-content =
1082   text-illustration-index-entry-template-attrs,
1083   (text-index-entry-chapter
1084    | text-index-entry-page-number
1085    | text-index-entry-text
1086    | text-index-entry-span
1087    | text-index-entry-tab-stop)*
1088 text-illustration-index-entry-template-attrs =
1089   attribute text:style-name { styleNameRef }
1090 text-table-index =
1091   element text:table-index {
1092     common-section-attlist, text-table-index-source, text-index-body
1093   }
1094 text-table-index-source =
1095   element text:table-index-source {
1096     text-illustration-index-source-attrs,
1097     text-index-title-template?,
1098     text-table-index-entry-template?
1099   }
1100 text-table-index-entry-template =
1101   element text:table-index-entry-template {
1102     text-illustration-index-entry-content
1103   }
1104 text-object-index =
1105   element text:object-index {
1106     common-section-attlist, text-object-index-source, text-index-body
1107   }
1108 text-object-index-source =
1109   element text:object-index-source {
1110     text-object-index-source-attrs,
1111     text-index-title-template?,
1112     text-object-index-entry-template?
1113   }
1114 text-object-index-source-attrs =
1115   text-index-scope-attr
1116   & text-relative-tab-stop-position-attr
1117   & attribute text:use-spreadsheet-objects { boolean }?
1118   & attribute text:use-math-objects { boolean }?
1119   & attribute text:use-draw-objects { boolean }?
1120   & attribute text:use-chart-objects { boolean }?
1121   & attribute text:use-other-objects { boolean }?
1122 text-object-index-entry-template =
1123   element text:object-index-entry-template {
1124     text-illustration-index-entry-content
1125   }
1126 text-user-index =
1127   element text:user-index {
1128     common-section-attlist, text-user-index-source, text-index-body
1129   }
1130 text-user-index-source =
1131   element text:user-index-source {
1132     text-user-index-source-attr,
1133     text-index-title-template?,
1134     text-user-index-entry-template*,
1135     text-index-source-styles*
1136   }
1137 text-user-index-source-attr =
1138   text-index-scope-attr
1139   & text-relative-tab-stop-position-attr
1140   & attribute text:use-index-marks { boolean }?
1141   & attribute text:use-index-source-styles { boolean }?
1142   & attribute text:use-graphics { boolean }?
1143   & attribute text:use-tables { boolean }?
1144   & attribute text:use-floating-frames { boolean }?
1145   & attribute text:use-objects { boolean }?
1146   & attribute text:copy-outline-levels { boolean }?
1147   & attribute text:index-name { \string }
1148 text-user-index-entry-template =
1149   element text:user-index-entry-template {
1150     text-user-index-entry-template-attrs,
1151     (text-index-entry-chapter
1152      | text-index-entry-page-number
1153      | text-index-entry-text
1154      | text-index-entry-span
1155      | text-index-entry-tab-stop)*
1156   }
1157 text-user-index-entry-template-attrs =
1158   attribute text:outline-level { positiveInteger }
1159   & attribute text:style-name { styleNameRef }
1160 text-alphabetical-index =
1161   element text:alphabetical-index {
1162     common-section-attlist,
1163     text-alphabetical-index-source,
1164     text-index-body
1165   }
1166 text-alphabetical-index-source =
1167   element text:alphabetical-index-source {
1168     text-alphabetical-index-source-attrs,
1169     text-index-title-template?,
1170     text-alphabetical-index-entry-template*
1171   }
1172 text-alphabetical-index-source-attrs =
1173   text-index-scope-attr
1174   & text-relative-tab-stop-position-attr
1175   & attribute text:ignore-case { boolean }?
1176   & attribute text:main-entry-style-name { styleNameRef }?
1177   & attribute text:alphabetical-separators { boolean }?
1178   & attribute text:combine-entries { boolean }?
1179   & attribute text:combine-entries-with-dash { boolean }?
1180   & attribute text:combine-entries-with-pp { boolean }?
1181   & attribute text:use-keys-as-entries { boolean }?
1182   & attribute text:capitalize-entries { boolean }?
1183   & attribute text:comma-separated { boolean }?
1184   & attribute fo:language { languageCode }?
1185   & attribute fo:country { countryCode }?
1186   & attribute fo:script { scriptCode }?
1187   & attribute style:rfc-language-tag { language }?
1188   & attribute text:sort-algorithm { \string }?
1189 text-alphabetical-index-auto-mark-file =
1190   element text:alphabetical-index-auto-mark-file {
1191     attribute xlink:type { "simple" },
1192     attribute xlink:href { anyIRI }
1193   }
1194 text-alphabetical-index-entry-template =
1195   element text:alphabetical-index-entry-template {
1196     text-alphabetical-index-entry-template-attrs,
1197     (text-index-entry-chapter
1198      | text-index-entry-page-number
1199      | text-index-entry-text
1200      | text-index-entry-span
1201      | text-index-entry-tab-stop)*
1202   }
1203 text-alphabetical-index-entry-template-attrs =
1204   attribute text:outline-level { "1" | "2" | "3" | "separator" }
1205   & attribute text:style-name { styleNameRef }
1206 text-bibliography =
1207   element text:bibliography {
1208     common-section-attlist, text-bibliography-source, text-index-body
1209   }
1210 text-bibliography-source =
1211   element text:bibliography-source {
1212     text-index-title-template?, text-bibliography-entry-template*
1213   }
1214 text-bibliography-entry-template =
1215   element text:bibliography-entry-template {
1216     text-bibliography-entry-template-attrs,
1217     (text-index-entry-span
1218      | text-index-entry-tab-stop
1219      | text-index-entry-bibliography)*
1220   }
1221 text-bibliography-entry-template-attrs =
1222   attribute text:bibliography-type { text-bibliography-types }
1223   & attribute text:style-name { styleNameRef }
1224 text-index-source-styles =
1225   element text:index-source-styles {
1226     attribute text:outline-level { positiveInteger },
1227     text-index-source-style*
1228   }
1229 text-index-source-style =
1230   element text:index-source-style {
1231     attribute text:style-name { styleName },
1232     empty
1233   }
1234 text-index-title-template =
1235   element text:index-title-template {
1236     attribute text:style-name { styleNameRef }?,
1237     text
1238   }
1239 text-index-entry-chapter =
1240   element text:index-entry-chapter {
1241     attribute text:style-name { styleNameRef }?,
1242     text-index-entry-chapter-attrs
1243   }
1244 text-index-entry-chapter-attrs =
1245   attribute text:display {
1246     "name"
1247     | "number"
1248     | "number-and-name"
1249     | "plain-number"
1250     | "plain-number-and-name"
1251   }?
1252   & attribute text:outline-level { positiveInteger }?
1253 text-index-entry-text =
1254   element text:index-entry-text {
1255     attribute text:style-name { styleNameRef }?
1256   }
1257 text-index-entry-page-number =
1258   element text:index-entry-page-number {
1259     attribute text:style-name { styleNameRef }?
1260   }
1261 text-index-entry-span =
1262   element text:index-entry-span {
1263     attribute text:style-name { styleNameRef }?,
1264     text
1265   }
1266 text-index-entry-bibliography =
1267   element text:index-entry-bibliography {
1268     text-index-entry-bibliography-attrs
1269   }
1270 text-index-entry-bibliography-attrs =
1271   attribute text:style-name { styleNameRef }?
1272   & attribute text:bibliography-data-field {
1273       "address"
1274       | "annote"
1275       | "author"
1276       | "bibliography-type"
1277       | "booktitle"
1278       | "chapter"
1279       | "custom1"
1280       | "custom2"
1281       | "custom3"
1282       | "custom4"
1283       | "custom5"
1284       | "edition"
1285       | "editor"
1286       | "howpublished"
1287       | "identifier"
1288       | "institution"
1289       | "isbn"
1290       | "issn"
1291       | "journal"
1292       | "month"
1293       | "note"
1294       | "number"
1295       | "organizations"
1296       | "pages"
1297       | "publisher"
1298       | "report-type"
1299       | "school"
1300       | "series"
1301       | "title"
1302       | "url"
1303       | "volume"
1304       | "year"
1305     }
1306 text-index-entry-tab-stop =
1307   element text:index-entry-tab-stop {
1308     attribute text:style-name { styleNameRef }?,
1309     text-index-entry-tab-stop-attrs
1310   }
1311 text-index-entry-tab-stop-attrs =
1312   attribute style:leader-char { character }?
1313   & (attribute style:type { "right" }
1314      | (attribute style:type { "left" },
1315         attribute style:position { length }))
1316 text-index-entry-link-start =
1317   element text:index-entry-link-start {
1318     attribute text:style-name { styleNameRef }?
1319   }
1320 text-index-entry-link-end =
1321   element text:index-entry-link-end {
1322     attribute text:style-name { styleNameRef }?
1323   }
1324 table-table =
1325   element table:table {
1326     table-table-attlist,
1327     table-title?,
1328     table-desc?,
1329     table-table-source?,
1330     office-dde-source?,
1331     table-scenario?,
1332     office-forms?,
1333     table-shapes?,
1334     table-columns-and-groups,
1335     table-rows-and-groups,
1336     table-named-expressions?
1337   }
1338 table-columns-and-groups =
1339   (table-table-column-group | table-columns-no-group)+
1340 table-columns-no-group =
1341   (table-columns, (table-table-header-columns, table-columns?)?)
1342   | (table-table-header-columns, table-columns?)
1343 table-columns = table-table-columns | table-table-column+
1344 table-rows-and-groups = (table-table-row-group | table-rows-no-group)+
1345 table-rows-no-group =
1346   (table-rows, (table-table-header-rows, table-rows?)?)
1347   | (table-table-header-rows, table-rows?)
1348 table-rows =
1349   table-table-rows | (text-soft-page-break?, table-table-row)+
1350 table-table-attlist =
1351   attribute table:name { \string }?
1352   & attribute table:style-name { styleNameRef }?
1353   & attribute table:template-name { \string }?
1354   & attribute table:use-first-row-styles { boolean }?
1355   & attribute table:use-last-row-styles { boolean }?
1356   & attribute table:use-first-column-styles { boolean }?
1357   & attribute table:use-last-column-styles { boolean }?
1358   & attribute table:use-banding-rows-styles { boolean }?
1359   & attribute table:use-banding-columns-styles { boolean }?
1360   & attribute table:protected { boolean }?
1361   & attribute table:protection-key { \string }?
1362   & attribute table:protection-key-digest-algorithm { anyIRI }?
1363   & attribute table:print { boolean }?
1364   & attribute table:print-ranges { cellRangeAddressList }?
1365   & xml-id?
1366   & attribute table:is-sub-table { boolean }?
1367 table-title = element table:title { text }
1368 table-desc = element table:desc { text }
1369 table-table-row =
1370   element table:table-row {
1371     table-table-row-attlist,
1372     (table-table-cell | table-covered-table-cell)+
1373   }
1374 table-table-row-attlist =
1375   attribute table:number-rows-repeated { positiveInteger }?
1376   & attribute table:style-name { styleNameRef }?
1377   & attribute table:default-cell-style-name { styleNameRef }?
1378   & attribute table:visibility { table-visibility-value }?
1379   & xml-id?
1380 table-visibility-value = "visible" | "collapse" | "filter"
1381 table-table-cell =
1382   element table:table-cell {
1383     table-table-cell-attlist,
1384     table-table-cell-attlist-extra,
1385     table-table-cell-content
1386   }
1387 table-covered-table-cell =
1388   element table:covered-table-cell {
1389     table-table-cell-attlist, table-table-cell-content
1390   }
1391 table-table-cell-content =
1392   table-cell-range-source?,
1393   office-annotation?,
1394   table-detective?,
1395   text-content*
1396 table-table-cell-attlist =
1397   attribute table:number-columns-repeated { positiveInteger }?
1398   & attribute table:style-name { styleNameRef }?
1399   & attribute table:content-validation-name { \string }?
1400   & attribute table:formula { \string }?
1401   & common-value-and-type-attlist?
1402   & attribute table:protect { boolean }?
1403   & attribute table:protected { boolean }?
1404   & xml-id?
1405   & common-in-content-meta-attlist?
1406 table-table-cell-attlist-extra =
1407   attribute table:number-columns-spanned { positiveInteger }?
1408   & attribute table:number-rows-spanned { positiveInteger }?
1409   & attribute table:number-matrix-columns-spanned { positiveInteger }?
1410   & attribute table:number-matrix-rows-spanned { positiveInteger }?
1411 table-table-column =
1412   element table:table-column { table-table-column-attlist, empty }
1413 table-table-column-attlist =
1414   attribute table:number-columns-repeated { positiveInteger }?
1415   & attribute table:style-name { styleNameRef }?
1416   & attribute table:visibility { table-visibility-value }?
1417   & attribute table:default-cell-style-name { styleNameRef }?
1418   & xml-id?
1419 table-table-header-columns =
1420   element table:table-header-columns { table-table-column+ }
1421 table-table-columns =
1422   element table:table-columns { table-table-column+ }
1423 table-table-column-group =
1424   element table:table-column-group {
1425     table-table-column-group-attlist, table-columns-and-groups
1426   }
1427 table-table-column-group-attlist = attribute table:display { boolean }?
1428 table-table-header-rows =
1429   element table:table-header-rows {
1430     (text-soft-page-break?, table-table-row)+
1431   }
1432 table-table-rows =
1433   element table:table-rows { (text-soft-page-break?, table-table-row)+ }
1434 table-table-row-group =
1435   element table:table-row-group {
1436     table-table-row-group-attlist, table-rows-and-groups
1437   }
1438 table-table-row-group-attlist = attribute table:display { boolean }?
1439 cellAddress =
1440   xsd:string {
1441     pattern = "($?([^\. ']+|'([^']|'')+'))?\.$?[A-Z]+$?[0-9]+"
1442   }
1443 cellRangeAddress =
1444   xsd:string {
1445     pattern =
1446       "($?([^\. ']+|'([^']|'')+'))?\.$?[A-Z]+$?[0-9]+(:($?([^\. ']+|'([^']|'')+'))?\.$?[A-Z]+$?[0-9]+)?"
1447   }
1448   | xsd:string {
1449       pattern =
1450         "($?([^\. ']+|'([^']|'')+'))?\.$?[0-9]+:($?([^\. ']+|'([^']|'')+'))?\.$?[0-9]+"
1451     }
1452   | xsd:string {
1453       pattern =
1454         "($?([^\. ']+|'([^']|'')+'))?\.$?[A-Z]+:($?([^\. ']+|'([^']|'')+'))?\.$?[A-Z]+"
1455     }
1456 cellRangeAddressList =
1457   xsd:string
1458   >> dc:description [
1459        'Value is a space separated list of "cellRangeAddress" patterns'
1460      ]
1461 table-table-source =
1462   element table:table-source {
1463     table-table-source-attlist, table-linked-source-attlist, empty
1464   }
1465 table-table-source-attlist =
1466   attribute table:mode { "copy-all" | "copy-results-only" }?
1467   & attribute table:table-name { \string }?
1468 table-linked-source-attlist =
1469   attribute xlink:type { "simple" }
1470   & attribute xlink:href { anyIRI }
1471   & attribute xlink:actuate { "onRequest" }?
1472   & attribute table:filter-name { \string }?
1473   & attribute table:filter-options { \string }?
1474   & attribute table:refresh-delay { duration }?
1475 table-scenario =
1476   element table:scenario { table-scenario-attlist, empty }
1477 table-scenario-attlist =
1478   attribute table:scenario-ranges { cellRangeAddressList }
1479   & attribute table:is-active { boolean }
1480   & attribute table:display-border { boolean }?
1481   & attribute table:border-color { color }?
1482   & attribute table:copy-back { boolean }?
1483   & attribute table:copy-styles { boolean }?
1484   & attribute table:copy-formulas { boolean }?
1485   & attribute table:comment { \string }?
1486   & attribute table:protected { boolean }?
1487 table-shapes = element table:shapes { shape+ }
1488 table-cell-range-source =
1489   element table:cell-range-source {
1490     table-table-cell-range-source-attlist,
1491     table-linked-source-attlist,
1492     empty
1493   }
1494 table-table-cell-range-source-attlist =
1495   attribute table:name { \string }
1496   & attribute table:last-column-spanned { positiveInteger }
1497   & attribute table:last-row-spanned { positiveInteger }
1498 table-detective =
1499   element table:detective { table-highlighted-range*, table-operation* }
1500 table-operation =
1501   element table:operation { table-operation-attlist, empty }
1502 table-operation-attlist =
1503   attribute table:name {
1504     "trace-dependents"
1505     | "remove-dependents"
1506     | "trace-precedents"
1507     | "remove-precedents"
1508     | "trace-errors"
1509   }
1510   & attribute table:index { nonNegativeInteger }
1511 table-highlighted-range =
1512   element table:highlighted-range {
1513     (table-highlighted-range-attlist
1514      | table-highlighted-range-attlist-invalid),
1515     empty
1516   }
1517 table-highlighted-range-attlist =
1518   attribute table:cell-range-address { cellRangeAddress }?
1519   & attribute table:direction {
1520       "from-another-table" | "to-another-table" | "from-same-table"
1521     }
1522   & attribute table:contains-error { boolean }?
1523 table-highlighted-range-attlist-invalid =
1524   attribute table:marked-invalid { boolean }
1525 office-spreadsheet-attlist =
1526   attribute table:structure-protected { boolean }?,
1527   attribute table:protection-key { \string }?,
1528   attribute table:protection-key-digest-algorithm { anyIRI }?
1529 table-calculation-settings =
1530   element table:calculation-settings {
1531     table-calculation-setting-attlist,
1532     table-null-date?,
1533     table-iteration?
1534   }
1535 table-calculation-setting-attlist =
1536   attribute table:case-sensitive { boolean }?
1537   & attribute table:precision-as-shown { boolean }?
1538   & attribute table:search-criteria-must-apply-to-whole-cell {
1539       boolean
1540     }?
1541   & attribute table:automatic-find-labels { boolean }?
1542   & attribute table:use-regular-expressions { boolean }?
1543   & attribute table:use-wildcards { boolean }?
1544   & attribute table:null-year { positiveInteger }?
1545 table-null-date =
1546   element table:null-date {
1547     attribute table:value-type { "date" }?,
1548     attribute table:date-value { date }?,
1549     empty
1550   }
1551 table-iteration =
1552   element table:iteration {
1553     attribute table:status { "enable" | "disable" }?,
1554     attribute table:steps { positiveInteger }?,
1555     attribute table:maximum-difference { double }?,
1556     empty
1557   }
1558 table-content-validations =
1559   element table:content-validations { table-content-validation+ }
1560 table-content-validation =
1561   element table:content-validation {
1562     table-validation-attlist,
1563     table-help-message?,
1564     (table-error-message | (table-error-macro, office-event-listeners))?
1565   }
1566 table-validation-attlist =
1567   attribute table:name { \string }
1568   & attribute table:condition { \string }?
1569   & attribute table:base-cell-address { cellAddress }?
1570   & attribute table:allow-empty-cell { boolean }?
1571   & attribute table:display-list {
1572       "none" | "unsorted" | "sort-ascending"
1573     }?
1574 table-help-message =
1575   element table:help-message {
1576     attribute table:title { \string }?,
1577     attribute table:display { boolean }?,
1578     text-p*
1579   }
1580 table-error-message =
1581   element table:error-message {
1582     attribute table:title { \string }?,
1583     attribute table:display { boolean }?,
1584     attribute table:message-type {
1585       "stop" | "warning" | "information"
1586     }?,
1587     text-p*
1588   }
1589 table-error-macro =
1590   element table:error-macro {
1591     attribute table:execute { boolean }?
1592   }
1593 table-label-ranges = element table:label-ranges { table-label-range* }
1594 table-label-range =
1595   element table:label-range { table-label-range-attlist, empty }
1596 table-label-range-attlist =
1597   attribute table:label-cell-range-address { cellRangeAddress }
1598   & attribute table:data-cell-range-address { cellRangeAddress }
1599   & attribute table:orientation { "column" | "row" }
1600 table-named-expressions =
1601   element table:named-expressions {
1602     (table-named-range | table-named-expression)*
1603   }
1604 table-named-range =
1605   element table:named-range { table-named-range-attlist, empty }
1606 table-named-range-attlist =
1607   attribute table:name { \string },
1608   attribute table:cell-range-address { cellRangeAddress },
1609   attribute table:base-cell-address { cellAddress }?,
1610   attribute table:range-usable-as {
1611     "none"
1612     | list {
1613         ("print-range" | "filter" | "repeat-row" | "repeat-column")+
1614       }
1615   }?
1616 table-named-expression =
1617   element table:named-expression {
1618     table-named-expression-attlist, empty
1619   }
1620 table-named-expression-attlist =
1621   attribute table:name { \string },
1622   attribute table:expression { \string },
1623   attribute table:base-cell-address { cellAddress }?
1624 table-database-ranges =
1625   element table:database-ranges { table-database-range* }
1626 table-database-range =
1627   element table:database-range {
1628     table-database-range-attlist,
1629     (table-database-source-sql
1630      | table-database-source-table
1631      | table-database-source-query)?,
1632     table-filter?,
1633     table-sort?,
1634     table-subtotal-rules?
1635   }
1636 table-database-range-attlist =
1637   attribute table:name { \string }?
1638   & attribute table:is-selection { boolean }?
1639   & attribute table:on-update-keep-styles { boolean }?
1640   & attribute table:on-update-keep-size { boolean }?
1641   & attribute table:has-persistent-data { boolean }?
1642   & attribute table:orientation { "column" | "row" }?
1643   & attribute table:contains-header { boolean }?
1644   & attribute table:display-filter-buttons { boolean }?
1645   & attribute table:target-range-address { cellRangeAddress }
1646   & attribute table:refresh-delay { boolean }?
1647 table-database-source-sql =
1648   element table:database-source-sql {
1649     table-database-source-sql-attlist, empty
1650   }
1651 table-database-source-sql-attlist =
1652   attribute table:database-name { \string }
1653   & attribute table:sql-statement { \string }
1654   & attribute table:parse-sql-statement { boolean }?
1655 table-database-source-query =
1656   element table:database-source-table {
1657     table-database-source-table-attlist, empty
1658   }
1659 table-database-source-table-attlist =
1660   attribute table:database-name { \string }
1661   & attribute table:database-table-name { \string }
1662 table-database-source-table =
1663   element table:database-source-query {
1664     table-database-source-query-attlist, empty
1665   }
1666 table-database-source-query-attlist =
1667   attribute table:database-name { \string }
1668   & attribute table:query-name { \string }
1669 table-sort = element table:sort { table-sort-attlist, table-sort-by+ }
1670 table-sort-attlist =
1671   attribute table:bind-styles-to-content { boolean }?
1672   & attribute table:target-range-address { cellRangeAddress }?
1673   & attribute table:case-sensitive { boolean }?
1674   & attribute table:language { languageCode }?
1675   & attribute table:country { countryCode }?
1676   & attribute table:script { scriptCode }?
1677   & attribute table:rfc-language-tag { language }?
1678   & attribute table:algorithm { \string }?
1679   & attribute table:embedded-number-behavior {
1680       "alpha-numeric" | "integer" | "double"
1681     }?
1682 table-sort-by = element table:sort-by { table-sort-by-attlist, empty }
1683 table-sort-by-attlist =
1684   attribute table:field-number { nonNegativeInteger }
1685   & attribute table:data-type {
1686       "text" | "number" | "automatic" | \string
1687     }?
1688   & attribute table:order { "ascending" | "descending" }?
1689 table-subtotal-rules =
1690   element table:subtotal-rules {
1691     table-subtotal-rules-attlist,
1692     table-sort-groups?,
1693     table-subtotal-rule*
1694   }
1695 table-subtotal-rules-attlist =
1696   attribute table:bind-styles-to-content { boolean }?
1697   & attribute table:case-sensitive { boolean }?
1698   & attribute table:page-breaks-on-group-change { boolean }?
1699 table-sort-groups =
1700   element table:sort-groups { table-sort-groups-attlist, empty }
1701 table-sort-groups-attlist =
1702   attribute table:data-type {
1703     "text" | "number" | "automatic" | \string
1704   }?
1705   & attribute table:order { "ascending" | "descending" }?
1706 table-subtotal-rule =
1707   element table:subtotal-rule {
1708     table-subtotal-rule-attlist, table-subtotal-field*
1709   }
1710 table-subtotal-rule-attlist =
1711   attribute table:group-by-field-number { nonNegativeInteger }
1712 table-subtotal-field =
1713   element table:subtotal-field { table-subtotal-field-attlist, empty }
1714 table-subtotal-field-attlist =
1715   attribute table:field-number { nonNegativeInteger }
1716   & attribute table:function {
1717       "average"
1718       | "count"
1719       | "countnums"
1720       | "max"
1721       | "min"
1722       | "product"
1723       | "stdev"
1724       | "stdevp"
1725       | "sum"
1726       | "var"
1727       | "varp"
1728       | \string
1729     }
1730 table-filter =
1731   element table:filter {
1732     table-filter-attlist,
1733     (table-filter-condition | table-filter-and | table-filter-or)
1734   }
1735 table-filter-attlist =
1736   attribute table:target-range-address { cellRangeAddress }?
1737   & attribute table:condition-source { "self" | "cell-range" }?
1738   & attribute table:condition-source-range-address { cellRangeAddress }?
1739   & attribute table:display-duplicates { boolean }?
1740 table-filter-and =
1741   element table:filter-and {
1742     (table-filter-or | table-filter-condition)+
1743   }
1744 table-filter-or =
1745   element table:filter-or {
1746     (table-filter-and | table-filter-condition)+
1747   }
1748 table-filter-condition =
1749   element table:filter-condition {
1750     table-filter-condition-attlist, table-filter-set-item*
1751   }
1752 table-filter-condition-attlist =
1753   attribute table:field-number { nonNegativeInteger }
1754   & attribute table:value { \string | double }
1755   & attribute table:operator { \string }
1756   & attribute table:case-sensitive { \string }?
1757   & attribute table:data-type { "text" | "number" }?
1758 table-filter-set-item =
1759   element table:filter-set-item {
1760     attribute table:value { \string },
1761     empty
1762   }
1763 table-data-pilot-tables =
1764   element table:data-pilot-tables { table-data-pilot-table* }
1765 table-data-pilot-table =
1766   element table:data-pilot-table {
1767     table-data-pilot-table-attlist,
1768     (table-database-source-sql
1769      | table-database-source-table
1770      | table-database-source-query
1771      | table-source-service
1772      | table-source-cell-range)?,
1773     table-data-pilot-field+
1774   }
1775 table-data-pilot-table-attlist =
1776   attribute table:name { \string }
1777   & attribute table:application-data { \string }?
1778   & attribute table:grand-total { "none" | "row" | "column" | "both" }?
1779   & attribute table:ignore-empty-rows { boolean }?
1780   & attribute table:identify-categories { boolean }?
1781   & attribute table:target-range-address { cellRangeAddress }
1782   & attribute table:buttons { cellRangeAddressList }?
1783   & attribute table:show-filter-button { boolean }?
1784   & attribute table:drill-down-on-double-click { boolean }?
1785 table-source-cell-range =
1786   element table:source-cell-range {
1787     table-source-cell-range-attlist, table-filter?
1788   }
1789 table-source-cell-range-attlist =
1790   attribute table:cell-range-address { cellRangeAddress }
1791 table-source-service =
1792   element table:source-service { table-source-service-attlist, empty }
1793 table-source-service-attlist =
1794   attribute table:name { \string }
1795   & attribute table:source-name { \string }
1796   & attribute table:object-name { \string }
1797   & attribute table:user-name { \string }?
1798   & attribute table:password { \string }?
1799 table-data-pilot-field =
1800   element table:data-pilot-field {
1801     table-data-pilot-field-attlist,
1802     table-data-pilot-level?,
1803     table-data-pilot-field-reference?,
1804     table-data-pilot-groups?
1805   }
1806 table-data-pilot-field-attlist =
1807   attribute table:source-field-name { \string }
1808   & (attribute table:orientation {
1809        "row" | "column" | "data" | "hidden"
1810      }
1811      | (attribute table:orientation { "page" },
1812         attribute table:selected-page { \string }))
1813   & attribute table:is-data-layout-field { \string }?
1814   & attribute table:function {
1815       "auto"
1816       | "average"
1817       | "count"
1818       | "countnums"
1819       | "max"
1820       | "min"
1821       | "product"
1822       | "stdev"
1823       | "stdevp"
1824       | "sum"
1825       | "var"
1826       | "varp"
1827       | \string
1828     }?
1829   & attribute table:used-hierarchy { integer }?
1830 table-data-pilot-level =
1831   element table:data-pilot-level {
1832     table-data-pilot-level-attlist,
1833     table-data-pilot-subtotals?,
1834     table-data-pilot-members?,
1835     table-data-pilot-display-info?,
1836     table-data-pilot-sort-info?,
1837     table-data-pilot-layout-info?
1838   }
1839 table-data-pilot-level-attlist = attribute table:show-empty { boolean }?
1840 table-data-pilot-subtotals =
1841   element table:data-pilot-subtotals { table-data-pilot-subtotal* }
1842 table-data-pilot-subtotal =
1843   element table:data-pilot-subtotal {
1844     table-data-pilot-subtotal-attlist, empty
1845   }
1846 table-data-pilot-subtotal-attlist =
1847   attribute table:function {
1848     "auto"
1849     | "average"
1850     | "count"
1851     | "countnums"
1852     | "max"
1853     | "min"
1854     | "product"
1855     | "stdev"
1856     | "stdevp"
1857     | "sum"
1858     | "var"
1859     | "varp"
1860     | \string
1861   }
1862 table-data-pilot-members =
1863   element table:data-pilot-members { table-data-pilot-member* }
1864 table-data-pilot-member =
1865   element table:data-pilot-member {
1866     table-data-pilot-member-attlist, empty
1867   }
1868 table-data-pilot-member-attlist =
1869   attribute table:name { \string }
1870   & attribute table:display { boolean }?
1871   & attribute table:show-details { boolean }?
1872 table-data-pilot-display-info =
1873   element table:data-pilot-display-info {
1874     table-data-pilot-display-info-attlist, empty
1875   }
1876 table-data-pilot-display-info-attlist =
1877   attribute table:enabled { boolean }
1878   & attribute table:data-field { \string }
1879   & attribute table:member-count { nonNegativeInteger }
1880   & attribute table:display-member-mode { "from-top" | "from-bottom" }
1881 table-data-pilot-sort-info =
1882   element table:data-pilot-sort-info {
1883     table-data-pilot-sort-info-attlist, empty
1884   }
1885 table-data-pilot-sort-info-attlist =
1886   ((attribute table:sort-mode { "data" },
1887     attribute table:data-field { \string })
1888    | attribute table:sort-mode { "none" | "manual" | "name" })
1889   & attribute table:order { "ascending" | "descending" }
1890 table-data-pilot-layout-info =
1891   element table:data-pilot-layout-info {
1892     table-data-pilot-layout-info-attlist, empty
1893   }
1894 table-data-pilot-layout-info-attlist =
1895   attribute table:layout-mode {
1896     "tabular-layout"
1897     | "outline-subtotals-top"
1898     | "outline-subtotals-bottom"
1899   }
1900   & attribute table:add-empty-lines { boolean }
1901 table-data-pilot-field-reference =
1902   element table:data-pilot-field-reference {
1903     table-data-pilot-field-reference-attlist
1904   }
1905 table-data-pilot-field-reference-attlist =
1906   attribute table:field-name { \string }
1907   & ((attribute table:member-type { "named" },
1908       attribute table:member-name { \string })
1909      | attribute table:member-type { "previous" | "next" })
1910   & attribute table:type {
1911       "none"
1912       | "member-difference"
1913       | "member-percentage"
1914       | "member-percentage-difference"
1915       | "running-total"
1916       | "row-percentage"
1917       | "column-percentage"
1918       | "total-percentage"
1919       | "index"
1920     }
1921 table-data-pilot-groups =
1922   element table:data-pilot-groups {
1923     table-data-pilot-groups-attlist, table-data-pilot-group+
1924   }
1925 table-data-pilot-groups-attlist =
1926   attribute table:source-field-name { \string }
1927   & (attribute table:date-start { dateOrDateTime | "auto" }
1928      | attribute table:start { double | "auto" })
1929   & (attribute table:date-end { dateOrDateTime | "auto" }
1930      | attribute table:end { double | "auto" })
1931   & attribute table:step { double }
1932   & attribute table:grouped-by {
1933       "seconds"
1934       | "minutes"
1935       | "hours"
1936       | "days"
1937       | "months"
1938       | "quarters"
1939       | "years"
1940     }
1941 table-data-pilot-group =
1942   element table:data-pilot-group {
1943     table-data-pilot-group-attlist, table-data-pilot-group-member+
1944   }
1945 table-data-pilot-group-attlist = attribute table:name { \string }
1946 table-data-pilot-group-member =
1947   element table:data-pilot-group-member {
1948     table-data-pilot-group-member-attlist
1949   }
1950 table-data-pilot-group-member-attlist = attribute table:name { \string }
1951 table-consolidation =
1952   element table:consolidation { table-consolidation-attlist, empty }
1953 table-consolidation-attlist =
1954   attribute table:function {
1955     "average"
1956     | "count"
1957     | "countnums"
1958     | "max"
1959     | "min"
1960     | "product"
1961     | "stdev"
1962     | "stdevp"
1963     | "sum"
1964     | "var"
1965     | "varp"
1966     | \string
1967   }
1968   & attribute table:source-cell-range-addresses { cellRangeAddressList }
1969   & attribute table:target-cell-address { cellAddress }
1970   & attribute table:use-labels { "none" | "row" | "column" | "both" }?
1971   & attribute table:link-to-source-data { boolean }?
1972 table-dde-links = element table:dde-links { table-dde-link+ }
1973 table-tracked-changes =
1974   element table:tracked-changes {
1975     table-tracked-changes-attlist,
1976     (table-cell-content-change
1977      | table-insertion
1978      | table-deletion
1979      | table-movement)*
1980   }
1981 table-tracked-changes-attlist =
1982   attribute table:track-changes { boolean }?
1983 table-insertion =
1984   element table:insertion {
1985     table-insertion-attlist,
1986     common-table-change-attlist,
1987     office-change-info,
1988     table-dependencies?,
1989     table-deletions?
1990   }
1991 table-insertion-attlist =
1992   attribute table:type { "row" | "column" | "table" }
1993   & attribute table:position { integer }
1994   & attribute table:count { positiveInteger }?
1995   & attribute table:table { integer }?
1996 table-dependencies = element table:dependencies { table-dependency+ }
1997 table-dependency =
1998   element table:dependency {
1999     attribute table:id { \string },
2000     empty
2001   }
2002 table-deletions =
2003   element table:deletions {
2004     (table-cell-content-deletion | table-change-deletion)+
2005   }
2006 table-cell-content-deletion =
2007   element table:cell-content-deletion {
2008     attribute table:id { \string }?,
2009     table-cell-address?,
2010     table-change-track-table-cell?
2011   }
2012 table-change-deletion =
2013   element table:change-deletion {
2014     attribute table:id { \string }?,
2015     empty
2016   }
2017 table-deletion =
2018   element table:deletion {
2019     table-deletion-attlist,
2020     common-table-change-attlist,
2021     office-change-info,
2022     table-dependencies?,
2023     table-deletions?,
2024     table-cut-offs?
2025   }
2026 table-deletion-attlist =
2027   attribute table:type { "row" | "column" | "table" }
2028   & attribute table:position { integer }
2029   & attribute table:table { integer }?
2030   & attribute table:multi-deletion-spanned { integer }?
2031 table-cut-offs =
2032   element table:cut-offs {
2033     table-movement-cut-off+
2034     | (table-insertion-cut-off, table-movement-cut-off*)
2035   }
2036 table-insertion-cut-off =
2037   element table:insertion-cut-off {
2038     table-insertion-cut-off-attlist, empty
2039   }
2040 table-insertion-cut-off-attlist =
2041   attribute table:id { \string }
2042   & attribute table:position { integer }
2043 table-movement-cut-off =
2044   element table:movement-cut-off {
2045     table-movement-cut-off-attlist, empty
2046   }
2047 table-movement-cut-off-attlist =
2048   attribute table:position { integer }
2049   | (attribute table:start-position { integer },
2050      attribute table:end-position { integer })
2051 table-movement =
2052   element table:movement {
2053     common-table-change-attlist,
2054     table-source-range-address,
2055     table-target-range-address,
2056     office-change-info,
2057     table-dependencies?,
2058     table-deletions?
2059   }
2060 table-source-range-address =
2061   element table:source-range-address {
2062     common-table-range-attlist, empty
2063   }
2064 table-target-range-address =
2065   element table:target-range-address {
2066     common-table-range-attlist, empty
2067   }
2068 common-table-range-attlist =
2069   common-table-cell-address-attlist
2070   | common-table-cell-range-address-attlist
2071 common-table-cell-address-attlist =
2072   attribute table:column { integer },
2073   attribute table:row { integer },
2074   attribute table:table { integer }
2075 common-table-cell-range-address-attlist =
2076   attribute table:start-column { integer },
2077   attribute table:start-row { integer },
2078   attribute table:start-table { integer },
2079   attribute table:end-column { integer },
2080   attribute table:end-row { integer },
2081   attribute table:end-table { integer }
2082 table-change-track-table-cell =
2083   element table:change-track-table-cell {
2084     table-change-track-table-cell-attlist, text-p*
2085   }
2086 table-change-track-table-cell-attlist =
2087   attribute table:cell-address { cellAddress }?
2088   & attribute table:matrix-covered { boolean }?
2089   & attribute table:formula { \string }?
2090   & attribute table:number-matrix-columns-spanned { positiveInteger }?
2091   & attribute table:number-matrix-rows-spanned { positiveInteger }?
2092   & common-value-and-type-attlist?
2093 table-cell-content-change =
2094   element table:cell-content-change {
2095     common-table-change-attlist,
2096     table-cell-address,
2097     office-change-info,
2098     table-dependencies?,
2099     table-deletions?,
2100     table-previous
2101   }
2102 table-cell-address =
2103   element table:cell-address {
2104     common-table-cell-address-attlist, empty
2105   }
2106 table-previous =
2107   element table:previous {
2108     attribute table:id { \string }?,
2109     table-change-track-table-cell
2110   }
2111 common-table-change-attlist =
2112   attribute table:id { \string }
2113   & attribute table:acceptance-state {
2114       "accepted" | "rejected" | "pending"
2115     }?
2116   & attribute table:rejecting-change-id { \string }?
2117 style-handout-master =
2118   element style:handout-master {
2119     common-presentation-header-footer-attlist,
2120     style-handout-master-attlist,
2121     shape*
2122   }
2123 style-handout-master-attlist =
2124   attribute presentation:presentation-page-layout-name { styleNameRef }?
2125   & attribute style:page-layout-name { styleNameRef }
2126   & attribute draw:style-name { styleNameRef }?
2127 draw-layer-set = element draw:layer-set { draw-layer* }
2128 draw-layer =
2129   element draw:layer { draw-layer-attlist, svg-title?, svg-desc? }
2130 draw-layer-attlist =
2131   attribute draw:name { \string }
2132   & attribute draw:protected { boolean }?
2133   & attribute draw:display { "always" | "screen" | "printer" | "none" }?
2134 draw-page =
2135   element draw:page {
2136     common-presentation-header-footer-attlist,
2137     draw-page-attlist,
2138     svg-title?,
2139     svg-desc?,
2140     draw-layer-set?,
2141     office-forms?,
2142     shape*,
2143     (presentation-animations | animation-element)?,
2144     presentation-notes?
2145   }
2146 draw-page-attlist =
2147   attribute draw:name { \string }?
2148   & attribute draw:style-name { styleNameRef }?
2149   & attribute draw:master-page-name { styleNameRef }
2150   & attribute presentation:presentation-page-layout-name {
2151       styleNameRef
2152     }?
2153   & (xml-id,
2154      attribute draw:id { NCName }?)?
2155   & attribute draw:nav-order { IDREFS }?
2156 common-presentation-header-footer-attlist =
2157   attribute presentation:use-header-name { \string }?
2158   & attribute presentation:use-footer-name { \string }?
2159   & attribute presentation:use-date-time-name { \string }?
2160 shape = shape-instance | draw-a
2161 shape-instance =
2162   draw-rect
2163   | draw-line
2164   | draw-polyline
2165   | draw-polygon
2166   | draw-regular-polygon
2167   | draw-path
2168   | draw-circle
2169   | draw-ellipse
2170   | draw-g
2171   | draw-page-thumbnail
2172   | draw-frame
2173   | draw-measure
2174   | draw-caption
2175   | draw-connector
2176   | draw-control
2177   | dr3d-scene
2178   | draw-custom-shape
2179 draw-rect =
2180   element draw:rect {
2181     draw-rect-attlist,
2182     common-draw-position-attlist,
2183     common-draw-size-attlist,
2184     common-draw-shape-with-text-and-styles-attlist,
2185     common-draw-caption-id-attlist,
2186     svg-title?,
2187     svg-desc?,
2188     office-event-listeners?,
2189     draw-glue-point*,
2190     draw-text
2191   }
2192 draw-rect-attlist =
2193   attribute draw:corner-radius { nonNegativeLength }?
2194   | (attribute svg:rx { nonNegativeLength }?,
2195      attribute svg:ry { nonNegativeLength }?)
2196 draw-line =
2197   element draw:line {
2198     draw-line-attlist,
2199     common-draw-shape-with-text-and-styles-attlist,
2200     common-draw-caption-id-attlist,
2201     svg-title?,
2202     svg-desc?,
2203     office-event-listeners?,
2204     draw-glue-point*,
2205     draw-text
2206   }
2207 draw-line-attlist =
2208   attribute svg:x1 { coordinate }
2209   & attribute svg:y1 { coordinate }
2210   & attribute svg:x2 { coordinate }
2211   & attribute svg:y2 { coordinate }
2212 draw-polyline =
2213   element draw:polyline {
2214     common-draw-points-attlist,
2215     common-draw-position-attlist,
2216     common-draw-size-attlist,
2217     common-draw-viewbox-attlist,
2218     common-draw-shape-with-text-and-styles-attlist,
2219     common-draw-caption-id-attlist,
2220     svg-title?,
2221     svg-desc?,
2222     office-event-listeners?,
2223     draw-glue-point*,
2224     draw-text
2225   }
2226 common-draw-points-attlist = attribute draw:points { points }
2227 draw-polygon =
2228   element draw:polygon {
2229     common-draw-points-attlist,
2230     common-draw-position-attlist,
2231     common-draw-size-attlist,
2232     common-draw-viewbox-attlist,
2233     common-draw-shape-with-text-and-styles-attlist,
2234     common-draw-caption-id-attlist,
2235     svg-title?,
2236     svg-desc?,
2237     office-event-listeners?,
2238     draw-glue-point*,
2239     draw-text
2240   }
2241 draw-regular-polygon =
2242   element draw:regular-polygon {
2243     draw-regular-polygon-attlist,
2244     common-draw-position-attlist,
2245     common-draw-size-attlist,
2246     common-draw-shape-with-text-and-styles-attlist,
2247     common-draw-caption-id-attlist,
2248     svg-title?,
2249     svg-desc?,
2250     office-event-listeners?,
2251     draw-glue-point*,
2252     draw-text
2253   }
2254 draw-regular-polygon-attlist =
2255   (attribute draw:concave { "false" }
2256    | (attribute draw:concave { "true" },
2257       draw-regular-polygon-sharpness-attlist))
2258   & attribute draw:corners { positiveInteger }
2259 draw-regular-polygon-sharpness-attlist =
2260   attribute draw:sharpness { percent }
2261 draw-path =
2262   element draw:path {
2263     common-draw-path-data-attlist,
2264     common-draw-position-attlist,
2265     common-draw-size-attlist,
2266     common-draw-viewbox-attlist,
2267     common-draw-shape-with-text-and-styles-attlist,
2268     common-draw-caption-id-attlist,
2269     svg-title?,
2270     svg-desc?,
2271     office-event-listeners?,
2272     draw-glue-point*,
2273     draw-text
2274   }
2275 common-draw-path-data-attlist = attribute svg:d { pathData }
2276 draw-circle =
2277   element draw:circle {
2278     ((draw-circle-attlist, common-draw-circle-ellipse-pos-attlist)
2279      | (common-draw-position-attlist, common-draw-size-attlist)),
2280     common-draw-circle-ellipse-attlist,
2281     common-draw-shape-with-text-and-styles-attlist,
2282     common-draw-caption-id-attlist,
2283     svg-title?,
2284     svg-desc?,
2285     office-event-listeners?,
2286     draw-glue-point*,
2287     draw-text
2288   }
2289 common-draw-circle-ellipse-pos-attlist =
2290   attribute svg:cx { coordinate },
2291   attribute svg:cy { coordinate }
2292 draw-circle-attlist = attribute svg:r { length }
2293 common-draw-circle-ellipse-attlist =
2294   attribute draw:kind { "full" | "section" | "cut" | "arc" }?
2295   & attribute draw:start-angle { angle }?
2296   & attribute draw:end-angle { angle }?
2297 draw-ellipse =
2298   element draw:ellipse {
2299     ((draw-ellipse-attlist, common-draw-circle-ellipse-pos-attlist)
2300      | (common-draw-position-attlist, common-draw-size-attlist)),
2301     common-draw-circle-ellipse-attlist,
2302     common-draw-shape-with-text-and-styles-attlist,
2303     common-draw-caption-id-attlist,
2304     svg-title?,
2305     svg-desc?,
2306     office-event-listeners?,
2307     draw-glue-point*,
2308     draw-text
2309   }
2310 draw-ellipse-attlist =
2311   attribute svg:rx { length },
2312   attribute svg:ry { length }
2313 draw-connector =
2314   element draw:connector {
2315     draw-connector-attlist,
2316     common-draw-shape-with-text-and-styles-attlist,
2317     common-draw-caption-id-attlist,
2318     common-draw-viewbox-attlist,
2319     svg-title?,
2320     svg-desc?,
2321     office-event-listeners?,
2322     draw-glue-point*,
2323     draw-text
2324   }
2325 draw-connector-attlist =
2326   attribute draw:type { "standard" | "lines" | "line" | "curve" }?
2327   & (attribute svg:x1 { coordinate },
2328      attribute svg:y1 { coordinate })?
2329   & attribute draw:start-shape { IDREF }?
2330   & attribute draw:start-glue-point { nonNegativeInteger }?
2331   & (attribute svg:x2 { coordinate },
2332      attribute svg:y2 { coordinate })?
2333   & attribute draw:end-shape { IDREF }?
2334   & attribute draw:end-glue-point { nonNegativeInteger }?
2335   & attribute draw:line-skew {
2336       list { length, (length, length?)? }
2337     }?
2338   & attribute svg:d { pathData }?
2339 draw-caption =
2340   element draw:caption {
2341     draw-caption-attlist,
2342     common-draw-position-attlist,
2343     common-draw-size-attlist,
2344     common-draw-shape-with-text-and-styles-attlist,
2345     common-draw-caption-id-attlist,
2346     svg-title?,
2347     svg-desc?,
2348     office-event-listeners?,
2349     draw-glue-point*,
2350     draw-text
2351   }
2352 draw-caption-attlist =
2353   (attribute draw:caption-point-x { coordinate },
2354    attribute draw:caption-point-y { coordinate })?
2355   & attribute draw:corner-radius { nonNegativeLength }?
2356 draw-measure =
2357   element draw:measure {
2358     draw-measure-attlist,
2359     common-draw-shape-with-text-and-styles-attlist,
2360     common-draw-caption-id-attlist,
2361     svg-title?,
2362     svg-desc?,
2363     office-event-listeners?,
2364     draw-glue-point*,
2365     draw-text
2366   }
2367 draw-measure-attlist =
2368   attribute svg:x1 { coordinate }
2369   & attribute svg:y1 { coordinate }
2370   & attribute svg:x2 { coordinate }
2371   & attribute svg:y2 { coordinate }
2372 draw-control =
2373   element draw:control {
2374     draw-control-attlist,
2375     common-draw-position-attlist,
2376     common-draw-size-attlist,
2377     common-draw-shape-with-text-and-styles-attlist,
2378     common-draw-caption-id-attlist,
2379     svg-title?,
2380     svg-desc?,
2381     draw-glue-point*
2382   }
2383 draw-control-attlist = attribute draw:control { IDREF }
2384 draw-page-thumbnail =
2385   element draw:page-thumbnail {
2386     draw-page-thumbnail-attlist,
2387     common-draw-position-attlist,
2388     common-draw-size-attlist,
2389     presentation-shape-attlist,
2390     common-draw-shape-with-styles-attlist,
2391     common-draw-caption-id-attlist,
2392     svg-title?,
2393     svg-desc?
2394   }
2395 draw-page-thumbnail-attlist =
2396   attribute draw:page-number { positiveInteger }?
2397 draw-g =
2398   element draw:g {
2399     draw-g-attlist,
2400     common-draw-z-index-attlist,
2401     common-draw-name-attlist,
2402     common-draw-id-attlist,
2403     common-draw-style-name-attlist,
2404     common-text-spreadsheet-shape-attlist,
2405     common-draw-caption-id-attlist,
2406     svg-title?,
2407     svg-desc?,
2408     office-event-listeners?,
2409     draw-glue-point*,
2410     shape*
2411   }
2412 draw-g-attlist = attribute svg:y { coordinate }?
2413 common-draw-name-attlist = attribute draw:name { \string }?
2414 common-draw-caption-id-attlist = attribute draw:caption-id { IDREF }?
2415 common-draw-position-attlist =
2416   attribute svg:x { coordinate }?,
2417   attribute svg:y { coordinate }?
2418 common-draw-size-attlist =
2419   attribute svg:width { length }?,
2420   attribute svg:height { length }?
2421 common-draw-transform-attlist = attribute draw:transform { \string }?
2422 common-draw-viewbox-attlist =
2423   attribute svg:viewBox {
2424     list { integer, integer, integer, integer }
2425   }
2426 common-draw-style-name-attlist =
2427   (attribute draw:style-name { styleNameRef }?,
2428    attribute draw:class-names { styleNameRefs }?)
2429   | (attribute presentation:style-name { styleNameRef }?,
2430      attribute presentation:class-names { styleNameRefs }?)
2431 common-draw-text-style-name-attlist =
2432   attribute draw:text-style-name { styleNameRef }?
2433 common-draw-layer-name-attlist = attribute draw:layer { \string }?
2434 common-draw-id-attlist =
2435   (xml-id,
2436    attribute draw:id { NCName }?)?
2437 common-draw-z-index-attlist =
2438   attribute draw:z-index { nonNegativeInteger }?
2439 common-text-spreadsheet-shape-attlist =
2440   attribute table:end-cell-address { cellAddress }?
2441   & attribute table:end-x { coordinate }?
2442   & attribute table:end-y { coordinate }?
2443   & attribute table:table-background { boolean }?
2444   & common-text-anchor-attlist
2445 common-text-anchor-attlist =
2446   attribute text:anchor-type {
2447     "page" | "frame" | "paragraph" | "char" | "as-char"
2448   }?
2449   & attribute text:anchor-page-number { positiveInteger }?
2450 draw-text = (text-p | text-list)*
2451 common-draw-shape-with-styles-attlist =
2452   common-draw-z-index-attlist,
2453   common-draw-id-attlist,
2454   common-draw-layer-name-attlist,
2455   common-draw-style-name-attlist,
2456   common-draw-transform-attlist,
2457   common-draw-name-attlist,
2458   common-text-spreadsheet-shape-attlist
2459 common-draw-shape-with-text-and-styles-attlist =
2460   common-draw-shape-with-styles-attlist,
2461   common-draw-text-style-name-attlist
2462 draw-glue-point =
2463   element draw:glue-point { draw-glue-point-attlist, empty }
2464 draw-glue-point-attlist =
2465   attribute draw:id { nonNegativeInteger }
2466   & attribute svg:x { distance | percent }
2467   & attribute svg:y { distance | percent }
2468   & attribute draw:align {
2469       "top-left"
2470       | "top"
2471       | "top-right"
2472       | "left"
2473       | "center"
2474       | "right"
2475       | "bottom-left"
2476       | "bottom-right"
2477     }?
2478   & attribute draw:escape-direction {
2479       "auto"
2480       | "left"
2481       | "right"
2482       | "up"
2483       | "down"
2484       | "horizontal"
2485       | "vertical"
2486     }
2487 svg-title = element svg:title { text }
2488 svg-desc = element svg:desc { text }
2489 draw-frame =
2490   element draw:frame {
2491     common-draw-shape-with-text-and-styles-attlist,
2492     common-draw-position-attlist,
2493     common-draw-rel-size-attlist,
2494     common-draw-caption-id-attlist,
2495     presentation-shape-attlist,
2496     draw-frame-attlist,
2497     (draw-text-box
2498      | draw-image
2499      | draw-object
2500      | draw-object-ole
2501      | draw-applet
2502      | draw-floating-frame
2503      | draw-plugin
2504      | table-table)*,
2505     office-event-listeners?,
2506     draw-glue-point*,
2507     draw-image-map?,
2508     svg-title?,
2509     svg-desc?,
2510     (draw-contour-polygon | draw-contour-path)?
2511   }
2512 common-draw-rel-size-attlist =
2513   common-draw-size-attlist,
2514   attribute style:rel-width { percent | "scale" | "scale-min" }?,
2515   attribute style:rel-height { percent | "scale" | "scale-min" }?
2516 draw-frame-attlist = attribute draw:copy-of { \string }?
2517 draw-text-box =
2518   element draw:text-box { draw-text-box-attlist, text-content* }
2519 draw-text-box-attlist =
2520   attribute draw:chain-next-name { \string }?
2521   & attribute draw:corner-radius { nonNegativeLength }?
2522   & attribute fo:min-height { length | percent }?
2523   & attribute fo:min-width { length | percent }?
2524   & attribute fo:max-height { length | percent }?
2525   & attribute fo:max-width { length | percent }?
2526   & (xml-id,
2527      attribute text:id { NCName }?)?
2528 draw-image =
2529   element draw:image {
2530     draw-image-attlist,
2531     (common-draw-data-attlist | office-binary-data),
2532     draw-text
2533   }
2534 common-draw-data-attlist =
2535   attribute xlink:type { "simple" },
2536   attribute xlink:href { anyIRI },
2537   attribute xlink:show { "embed" }?,
2538   attribute xlink:actuate { "onLoad" }?
2539 office-binary-data = element office:binary-data { base64Binary }
2540 draw-image-attlist =
2541   attribute draw:filter-name { \string }?
2542   & xml-id?
2543 draw-object =
2544   element draw:object {
2545     draw-object-attlist,
2546     (common-draw-data-attlist | office-document | math-math)
2547   }
2548 draw-object-ole =
2549   element draw:object-ole {
2550     draw-object-ole-attlist,
2551     (common-draw-data-attlist | office-binary-data)
2552   }
2553 draw-object-attlist =
2554   attribute draw:notify-on-update-of-ranges {
2555     cellRangeAddressList | \string
2556   }?
2557   & xml-id?
2558 draw-object-ole-attlist =
2559   attribute draw:class-id { \string }?
2560   & xml-id?
2561 draw-applet =
2562   element draw:applet {
2563     draw-applet-attlist, common-draw-data-attlist?, draw-param*
2564   }
2565 draw-applet-attlist =
2566   attribute draw:code { \string }?
2567   & attribute draw:object { \string }?
2568   & attribute draw:archive { \string }?
2569   & attribute draw:may-script { boolean }?
2570   & xml-id?
2571 draw-plugin =
2572   element draw:plugin {
2573     draw-plugin-attlist, common-draw-data-attlist, draw-param*
2574   }
2575 draw-plugin-attlist =
2576   attribute draw:mime-type { \string }?
2577   & xml-id?
2578 draw-param = element draw:param { draw-param-attlist, empty }
2579 draw-param-attlist =
2580   attribute draw:name { \string }?
2581   & attribute draw:value { \string }?
2582 draw-floating-frame =
2583   element draw:floating-frame {
2584     draw-floating-frame-attlist, common-draw-data-attlist
2585   }
2586 draw-floating-frame-attlist =
2587   attribute draw:frame-name { \string }?
2588   & xml-id?
2589 draw-contour-polygon =
2590   element draw:contour-polygon {
2591     common-contour-attlist,
2592     common-draw-size-attlist,
2593     common-draw-viewbox-attlist,
2594     common-draw-points-attlist,
2595     empty
2596   }
2597 draw-contour-path =
2598   element draw:contour-path {
2599     common-contour-attlist,
2600     common-draw-size-attlist,
2601     common-draw-viewbox-attlist,
2602     common-draw-path-data-attlist,
2603     empty
2604   }
2605 common-contour-attlist = attribute draw:recreate-on-edit { boolean }
2606 draw-a = element draw:a { draw-a-attlist, shape-instance }
2607 draw-a-attlist =
2608   attribute xlink:type { "simple" }
2609   & attribute xlink:href { anyIRI }
2610   & attribute xlink:actuate { "onRequest" }?
2611   & attribute office:target-frame-name { targetFrameName }?
2612   & attribute xlink:show { "new" | "replace" }?
2613   & attribute office:name { \string }?
2614   & attribute office:title { \string }?
2615   & attribute office:server-map { boolean }?
2616   & xml-id?
2617 draw-image-map =
2618   element draw:image-map {
2619     (draw-area-rectangle | draw-area-circle | draw-area-polygon)*
2620   }
2621 draw-area-rectangle =
2622   element draw:area-rectangle {
2623     common-draw-area-attlist,
2624     attribute svg:x { coordinate },
2625     attribute svg:y { coordinate },
2626     attribute svg:width { length },
2627     attribute svg:height { length },
2628     svg-title?,
2629     svg-desc?,
2630     office-event-listeners?
2631   }
2632 draw-area-circle =
2633   element draw:area-circle {
2634     common-draw-area-attlist,
2635     attribute svg:cx { coordinate },
2636     attribute svg:cy { coordinate },
2637     attribute svg:r { length },
2638     svg-title?,
2639     svg-desc?,
2640     office-event-listeners?
2641   }
2642 draw-area-polygon =
2643   element draw:area-polygon {
2644     common-draw-area-attlist,
2645     attribute svg:x { coordinate },
2646     attribute svg:y { coordinate },
2647     attribute svg:width { length },
2648     attribute svg:height { length },
2649     common-draw-viewbox-attlist,
2650     common-draw-points-attlist,
2651     svg-title?,
2652     svg-desc?,
2653     office-event-listeners?
2654   }
2655 common-draw-area-attlist =
2656   (attribute xlink:type { "simple" },
2657    attribute xlink:href { anyIRI },
2658    attribute office:target-frame-name { targetFrameName }?,
2659    attribute xlink:show { "new" | "replace" }?)?
2660   & attribute office:name { \string }?
2661   & attribute draw:nohref { "nohref" }?
2662 dr3d-scene =
2663   element dr3d:scene {
2664     dr3d-scene-attlist,
2665     common-draw-position-attlist,
2666     common-draw-size-attlist,
2667     common-draw-style-name-attlist,
2668     common-draw-z-index-attlist,
2669     common-draw-id-attlist,
2670     common-draw-layer-name-attlist,
2671     common-text-spreadsheet-shape-attlist,
2672     common-dr3d-transform-attlist,
2673     common-draw-caption-id-attlist,
2674     svg-title?,
2675     svg-desc?,
2676     dr3d-light*,
2677     shapes3d*,
2678     draw-glue-point*
2679   }
2680 shapes3d =
2681   dr3d-scene | dr3d-extrude | dr3d-sphere | dr3d-rotate | dr3d-cube
2682 dr3d-scene-attlist =
2683   attribute dr3d:vrp { vector3D }?
2684   & attribute dr3d:vpn { vector3D }?
2685   & attribute dr3d:vup { vector3D }?
2686   & attribute dr3d:projection { "parallel" | "perspective" }?
2687   & attribute dr3d:distance { length }?
2688   & attribute dr3d:focal-length { length }?
2689   & attribute dr3d:shadow-slant { angle }?
2690   & attribute dr3d:shade-mode {
2691       "flat" | "phong" | "gouraud" | "draft"
2692     }?
2693   & attribute dr3d:ambient-color { color }?
2694   & attribute dr3d:lighting-mode { boolean }?
2695 common-dr3d-transform-attlist = attribute dr3d:transform { \string }?
2696 dr3d-light = element dr3d:light { dr3d-light-attlist, empty }
2697 dr3d-light-attlist =
2698   attribute dr3d:diffuse-color { color }?
2699   & attribute dr3d:direction { vector3D }
2700   & attribute dr3d:enabled { boolean }?
2701   & attribute dr3d:specular { boolean }?
2702 dr3d-cube =
2703   element dr3d:cube {
2704     dr3d-cube-attlist,
2705     common-draw-z-index-attlist,
2706     common-draw-id-attlist,
2707     common-draw-layer-name-attlist,
2708     common-draw-style-name-attlist,
2709     common-dr3d-transform-attlist,
2710     empty
2711   }
2712 dr3d-cube-attlist =
2713   attribute dr3d:min-edge { vector3D }?,
2714   attribute dr3d:max-edge { vector3D }?
2715 dr3d-sphere =
2716   element dr3d:sphere {
2717     dr3d-sphere-attlist,
2718     common-draw-z-index-attlist,
2719     common-draw-id-attlist,
2720     common-draw-layer-name-attlist,
2721     common-draw-style-name-attlist,
2722     common-dr3d-transform-attlist,
2723     empty
2724   }
2725 dr3d-sphere-attlist =
2726   attribute dr3d:center { vector3D }?
2727   & attribute dr3d:size { vector3D }?
2728 dr3d-extrude =
2729   element dr3d:extrude {
2730     common-draw-path-data-attlist,
2731     common-draw-viewbox-attlist,
2732     common-draw-id-attlist,
2733     common-draw-z-index-attlist,
2734     common-draw-layer-name-attlist,
2735     common-draw-style-name-attlist,
2736     common-dr3d-transform-attlist,
2737     empty
2738   }
2739 dr3d-rotate =
2740   element dr3d:rotate {
2741     common-draw-viewbox-attlist,
2742     common-draw-path-data-attlist,
2743     common-draw-z-index-attlist,
2744     common-draw-id-attlist,
2745     common-draw-layer-name-attlist,
2746     common-draw-style-name-attlist,
2747     common-dr3d-transform-attlist,
2748     empty
2749   }
2750 draw-custom-shape =
2751   element draw:custom-shape {
2752     draw-custom-shape-attlist,
2753     common-draw-position-attlist,
2754     common-draw-size-attlist,
2755     common-draw-shape-with-text-and-styles-attlist,
2756     common-draw-caption-id-attlist,
2757     svg-title?,
2758     svg-desc?,
2759     office-event-listeners?,
2760     draw-glue-point*,
2761     draw-text,
2762     draw-enhanced-geometry?
2763   }
2764 draw-custom-shape-attlist =
2765   attribute draw:engine { namespacedToken }?
2766   & attribute draw:data { \string }?
2767 draw-enhanced-geometry =
2768   element draw:enhanced-geometry {
2769     draw-enhanced-geometry-attlist, draw-equation*, draw-handle*
2770   }
2771 draw-enhanced-geometry-attlist =
2772   attribute draw:type { custom-shape-type }?
2773   & attribute svg:viewBox {
2774       list { integer, integer, integer, integer }
2775     }?
2776   & attribute draw:mirror-vertical { boolean }?
2777   & attribute draw:mirror-horizontal { boolean }?
2778   & attribute draw:text-rotate-angle { angle }?
2779   & attribute draw:extrusion-allowed { boolean }?
2780   & attribute draw:text-path-allowed { boolean }?
2781   & attribute draw:concentric-gradient-fill-allowed { boolean }?
2782   & attribute draw:extrusion { boolean }?
2783   & attribute draw:extrusion-brightness { zeroToHundredPercent }?
2784   & attribute draw:extrusion-depth {
2785       list { length, double }
2786     }?
2787   & attribute draw:extrusion-diffusion { percent }?
2788   & attribute draw:extrusion-number-of-line-segments { integer }?
2789   & attribute draw:extrusion-light-face { boolean }?
2790   & attribute draw:extrusion-first-light-harsh { boolean }?
2791   & attribute draw:extrusion-second-light-harsh { boolean }?
2792   & attribute draw:extrusion-first-light-level { zeroToHundredPercent }?
2793   & attribute draw:extrusion-second-light-level {
2794       zeroToHundredPercent
2795     }?
2796   & attribute draw:extrusion-first-light-direction { vector3D }?
2797   & attribute draw:extrusion-second-light-direction { vector3D }?
2798   & attribute draw:extrusion-metal { boolean }?
2799   & attribute dr3d:shade-mode {
2800       "flat" | "phong" | "gouraud" | "draft"
2801     }?
2802   & attribute draw:extrusion-rotation-angle {
2803       list { angle, angle }
2804     }?
2805   & attribute draw:extrusion-rotation-center { vector3D }?
2806   & attribute draw:extrusion-shininess { zeroToHundredPercent }?
2807   & attribute draw:extrusion-skew {
2808       list { double, angle }
2809     }?
2810   & attribute draw:extrusion-specularity { zeroToHundredPercent }?
2811   & attribute dr3d:projection { "parallel" | "perspective" }?
2812   & attribute draw:extrusion-viewpoint { point3D }?
2813   & attribute draw:extrusion-origin {
2814       list { extrusionOrigin, extrusionOrigin }
2815     }?
2816   & attribute draw:extrusion-color { boolean }?
2817   & attribute draw:enhanced-path { \string }?
2818   & attribute draw:path-stretchpoint-x { double }?
2819   & attribute draw:path-stretchpoint-y { double }?
2820   & attribute draw:text-areas { \string }?
2821   & attribute draw:glue-points { \string }?
2822   & attribute draw:glue-point-type {
2823       "none" | "segments" | "rectangle"
2824     }?
2825   & attribute draw:glue-point-leaving-directions { \string }?
2826   & attribute draw:text-path { boolean }?
2827   & attribute draw:text-path-mode { "normal" | "path" | "shape" }?
2828   & attribute draw:text-path-scale { "path" | "shape" }?
2829   & attribute draw:text-path-same-letter-heights { boolean }?
2830   & attribute draw:modifiers { \string }?
2831 custom-shape-type = "non-primitive" | \string
2832 point3D =
2833   xsd:string {
2834     pattern =
2835       "\([ ]*-?([0-9]+(\.[0-9]*)?|\.[0-9]+)((cm)|(mm)|(in)|(pt)|(pc))([ ]+-?([0-9]+(\.[0-9]*)?|\.[0-9]+)((cm)|(mm)|(in)|(pt)|(pc))){2}[ ]*\)"
2836   }
2837 extrusionOrigin =
2838   xsd:double { minInclusive = "-0.5" maxInclusive = "0.5" }
2839 draw-equation = element draw:equation { draw-equation-attlist, empty }
2840 draw-equation-attlist =
2841   attribute draw:name { \string }?
2842   & attribute draw:formula { \string }?
2843 draw-handle = element draw:handle { draw-handle-attlist, empty }
2844 draw-handle-attlist =
2845   attribute draw:handle-mirror-vertical { boolean }?
2846   & attribute draw:handle-mirror-horizontal { boolean }?
2847   & attribute draw:handle-switched { boolean }?
2848   & attribute draw:handle-position { \string }
2849   & attribute draw:handle-range-x-minimum { \string }?
2850   & attribute draw:handle-range-x-maximum { \string }?
2851   & attribute draw:handle-range-y-minimum { \string }?
2852   & attribute draw:handle-range-y-maximum { \string }?
2853   & attribute draw:handle-polar { \string }?
2854   & attribute draw:handle-radius-range-minimum { \string }?
2855   & attribute draw:handle-radius-range-maximum { \string }?
2856 presentation-shape-attlist =
2857   attribute presentation:class { presentation-classes }?
2858   & attribute presentation:placeholder { boolean }?
2859   & attribute presentation:user-transformed { boolean }?
2860 presentation-classes =
2861   "title"
2862   | "outline"
2863   | "subtitle"
2864   | "text"
2865   | "graphic"
2866   | "object"
2867   | "chart"
2868   | "table"
2869   | "orgchart"
2870   | "page"
2871   | "notes"
2872   | "handout"
2873   | "header"
2874   | "footer"
2875   | "date-time"
2876   | "page-number"
2877 presentation-animations =
2878   element presentation:animations {
2879     (presentation-animation-elements | presentation-animation-group)*
2880   }
2881 presentation-animation-elements =
2882   presentation-show-shape
2883   | presentation-show-text
2884   | presentation-hide-shape
2885   | presentation-hide-text
2886   | presentation-dim
2887   | presentation-play
2888 presentation-sound =
2889   element presentation:sound {
2890     presentation-sound-attlist,
2891     attribute xlink:type { "simple" },
2892     attribute xlink:href { anyIRI },
2893     attribute xlink:actuate { "onRequest" }?,
2894     attribute xlink:show { "new" | "replace" }?,
2895     empty
2896   }
2897 presentation-sound-attlist =
2898   attribute presentation:play-full { boolean }?
2899   & xml-id?
2900 presentation-show-shape =
2901   element presentation:show-shape {
2902     common-presentation-effect-attlist, presentation-sound?
2903   }
2904 common-presentation-effect-attlist =
2905   attribute draw:shape-id { IDREF }
2906   & attribute presentation:effect { presentationEffects }?
2907   & attribute presentation:direction { presentationEffectDirections }?
2908   & attribute presentation:speed { presentationSpeeds }?
2909   & attribute presentation:delay { duration }?
2910   & attribute presentation:start-scale { percent }?
2911   & attribute presentation:path-id { \string }?
2912 presentationEffects =
2913   "none"
2914   | "fade"
2915   | "move"
2916   | "stripes"
2917   | "open"
2918   | "close"
2919   | "dissolve"
2920   | "wavyline"
2921   | "random"
2922   | "lines"
2923   | "laser"
2924   | "appear"
2925   | "hide"
2926   | "move-short"
2927   | "checkerboard"
2928   | "rotate"
2929   | "stretch"
2930 presentationEffectDirections =
2931   "none"
2932   | "from-left"
2933   | "from-top"
2934   | "from-right"
2935   | "from-bottom"
2936   | "from-center"
2937   | "from-upper-left"
2938   | "from-upper-right"
2939   | "from-lower-left"
2940   | "from-lower-right"
2941   | "to-left"
2942   | "to-top"
2943   | "to-right"
2944   | "to-bottom"
2945   | "to-upper-left"
2946   | "to-upper-right"
2947   | "to-lower-right"
2948   | "to-lower-left"
2949   | "path"
2950   | "spiral-inward-left"
2951   | "spiral-inward-right"
2952   | "spiral-outward-left"
2953   | "spiral-outward-right"
2954   | "vertical"
2955   | "horizontal"
2956   | "to-center"
2957   | "clockwise"
2958   | "counter-clockwise"
2959 presentationSpeeds = "slow" | "medium" | "fast"
2960 presentation-show-text =
2961   element presentation:show-text {
2962     common-presentation-effect-attlist, presentation-sound?
2963   }
2964 presentation-hide-shape =
2965   element presentation:hide-shape {
2966     common-presentation-effect-attlist, presentation-sound?
2967   }
2968 presentation-hide-text =
2969   element presentation:hide-text {
2970     common-presentation-effect-attlist, presentation-sound?
2971   }
2972 presentation-dim =
2973   element presentation:dim {
2974     presentation-dim-attlist, presentation-sound?
2975   }
2976 presentation-dim-attlist =
2977   attribute draw:shape-id { IDREF }
2978   & attribute draw:color { color }
2979 presentation-play =
2980   element presentation:play { presentation-play-attlist, empty }
2981 presentation-play-attlist =
2982   attribute draw:shape-id { IDREF },
2983   attribute presentation:speed { presentationSpeeds }?
2984 presentation-animation-group =
2985   element presentation:animation-group {
2986     presentation-animation-elements*
2987   }
2988 common-anim-attlist =
2989   attribute presentation:node-type {
2990     "default"
2991     | "on-click"
2992     | "with-previous"
2993     | "after-previous"
2994     | "timing-root"
2995     | "main-sequence"
2996     | "interactive-sequence"
2997   }?
2998   & attribute presentation:preset-id { \string }?
2999   & attribute presentation:preset-sub-type { \string }?
3000   & attribute presentation:preset-class {
3001       "custom"
3002       | "entrance"
3003       | "exit"
3004       | "emphasis"
3005       | "motion-path"
3006       | "ole-action"
3007       | "media-call"
3008     }?
3009   & attribute presentation:master-element { IDREF }?
3010   & attribute presentation:group-id { \string }?
3011   & (xml-id,
3012      attribute anim:id { NCName }?)?
3013 presentation-event-listener =
3014   element presentation:event-listener {
3015     presentation-event-listener-attlist, presentation-sound?
3016   }
3017 presentation-event-listener-attlist =
3018   attribute script:event-name { \string }
3019   & attribute presentation:action {
3020       "none"
3021       | "previous-page"
3022       | "next-page"
3023       | "first-page"
3024       | "last-page"
3025       | "hide"
3026       | "stop"
3027       | "execute"
3028       | "show"
3029       | "verb"
3030       | "fade-out"
3031       | "sound"
3032       | "last-visited-page"
3033     }
3034   & attribute presentation:effect { presentationEffects }?
3035   & attribute presentation:direction { presentationEffectDirections }?
3036   & attribute presentation:speed { presentationSpeeds }?
3037   & attribute presentation:start-scale { percent }?
3038   & (attribute xlink:type { "simple" },
3039      attribute xlink:href { anyIRI },
3040      attribute xlink:show { "embed" }?,
3041      attribute xlink:actuate { "onRequest" }?)?
3042   & attribute presentation:verb { nonNegativeInteger }?
3043 presentation-decls = presentation-decl*
3044 presentation-decl =
3045   element presentation:header-decl {
3046     presentation-header-decl-attlist, text
3047   }
3048   | element presentation:footer-decl {
3049       presentation-footer-decl-attlist, text
3050     }
3051   | element presentation:date-time-decl {
3052       presentation-date-time-decl-attlist, text
3053     }
3054 presentation-header-decl-attlist =
3055   attribute presentation:name { \string }
3056 presentation-footer-decl-attlist =
3057   attribute presentation:name { \string }
3058 presentation-date-time-decl-attlist =
3059   attribute presentation:name { \string }
3060   & attribute presentation:source { "fixed" | "current-date" }
3061   & attribute style:data-style-name { styleNameRef }?
3062 presentation-settings =
3063   element presentation:settings {
3064     presentation-settings-attlist, presentation-show*
3065   }?
3066 presentation-settings-attlist =
3067   attribute presentation:start-page { \string }?
3068   & attribute presentation:show { \string }?
3069   & attribute presentation:full-screen { boolean }?
3070   & attribute presentation:endless { boolean }?
3071   & attribute presentation:pause { duration }?
3072   & attribute presentation:show-logo { boolean }?
3073   & attribute presentation:force-manual { boolean }?
3074   & attribute presentation:mouse-visible { boolean }?
3075   & attribute presentation:mouse-as-pen { boolean }?
3076   & attribute presentation:start-with-navigator { boolean }?
3077   & attribute presentation:animations { "enabled" | "disabled" }?
3078   & attribute presentation:transition-on-click {
3079       "enabled" | "disabled"
3080     }?
3081   & attribute presentation:stay-on-top { boolean }?
3082   & attribute presentation:show-end-of-presentation-slide { boolean }?
3083 presentation-show =
3084   element presentation:show { presentation-show-attlist, empty }
3085 presentation-show-attlist =
3086   attribute presentation:name { \string }
3087   & attribute presentation:pages { \string }
3088 chart-chart =
3089   element chart:chart {
3090     chart-chart-attlist,
3091     chart-title?,
3092     chart-subtitle?,
3093     chart-footer?,
3094     chart-legend?,
3095     chart-plot-area,
3096     table-table?
3097   }
3098 chart-chart-attlist =
3099   attribute chart:class { namespacedToken }
3100   & common-draw-size-attlist
3101   & attribute chart:column-mapping { \string }?
3102   & attribute chart:row-mapping { \string }?
3103   & attribute chart:style-name { styleNameRef }?
3104   & (attribute xlink:type { "simple" },
3105      attribute xlink:href { anyIRI })?
3106   & xml-id?
3107 chart-title = element chart:title { chart-title-attlist, text-p? }
3108 chart-title-attlist =
3109   attribute table:cell-range { cellRangeAddressList }?
3110   & common-draw-position-attlist
3111   & attribute chart:style-name { styleNameRef }?
3112 chart-subtitle = element chart:subtitle { chart-title-attlist, text-p? }
3113 chart-footer = element chart:footer { chart-title-attlist, text-p? }
3114 chart-legend = element chart:legend { chart-legend-attlist, text-p? }
3115 chart-legend-attlist =
3116   ((attribute chart:legend-position {
3117       "start" | "end" | "top" | "bottom"
3118     },
3119     attribute chart:legend-align { "start" | "center" | "end" }?)
3120    | attribute chart:legend-position {
3121        "top-start" | "bottom-start" | "top-end" | "bottom-end"
3122      }
3123    | empty)
3124   & common-draw-position-attlist
3125   & (attribute style:legend-expansion { "wide" | "high" | "balanced" }
3126      | (attribute style:legend-expansion { "custom" },
3127         attribute style:legend-expansion-aspect-ratio { double })
3128      | empty)
3129   & attribute chart:style-name { styleNameRef }?
3130 chart-plot-area =
3131   element chart:plot-area {
3132     chart-plot-area-attlist,
3133     dr3d-light*,
3134     chart-axis*,
3135     chart-series*,
3136     chart-stock-gain-marker?,
3137     chart-stock-loss-marker?,
3138     chart-stock-range-line?,
3139     chart-wall?,
3140     chart-floor?
3141   }
3142 chart-plot-area-attlist =
3143   common-draw-position-attlist
3144   & common-draw-size-attlist
3145   & attribute chart:style-name { styleNameRef }?
3146   & attribute table:cell-range-address { cellRangeAddressList }?
3147   & attribute chart:data-source-has-labels {
3148       "none" | "row" | "column" | "both"
3149     }?
3150   & dr3d-scene-attlist
3151   & common-dr3d-transform-attlist
3152   & xml-id?
3153 chart-wall = element chart:wall { chart-wall-attlist, empty }
3154 chart-wall-attlist =
3155   attribute svg:width { length }?
3156   & attribute chart:style-name { styleNameRef }?
3157 chart-floor = element chart:floor { chart-floor-attlist, empty }
3158 chart-floor-attlist =
3159   attribute svg:width { length }?
3160   & attribute chart:style-name { styleNameRef }?
3161 chart-axis =
3162   element chart:axis {
3163     chart-axis-attlist, chart-title?, chart-categories?, chart-grid*
3164   }
3165 chart-axis-attlist =
3166   attribute chart:dimension { chart-dimension }
3167   & attribute chart:name { \string }?
3168   & attribute chart:style-name { styleNameRef }?
3169 chart-dimension = "x" | "y" | "z"
3170 chart-categories =
3171   element chart:categories {
3172     attribute table:cell-range-address { cellRangeAddressList }?
3173   }
3174 chart-grid = element chart:grid { chart-grid-attlist }
3175 chart-grid-attlist =
3176   attribute chart:class { "major" | "minor" }?
3177   & attribute chart:style-name { styleNameRef }?
3178 chart-series =
3179   element chart:series {
3180     chart-series-attlist,
3181     chart-domain*,
3182     chart-mean-value?,
3183     chart-regression-curve*,
3184     chart-error-indicator*,
3185     chart-data-point*,
3186     chart-data-label?
3187   }
3188 chart-series-attlist =
3189   attribute chart:values-cell-range-address { cellRangeAddressList }?
3190   & attribute chart:label-cell-address { cellRangeAddressList }?
3191   & attribute chart:class { namespacedToken }?
3192   & attribute chart:attached-axis { \string }?
3193   & attribute chart:style-name { styleNameRef }?
3194   & xml-id?
3195 chart-domain =
3196   element chart:domain {
3197     attribute table:cell-range-address { cellRangeAddressList }?
3198   }
3199 chart-data-point =
3200   element chart:data-point {
3201     chart-data-point-attlist, chart-data-label?
3202   }
3203 chart-data-point-attlist =
3204   attribute chart:repeated { positiveInteger }?
3205   & attribute chart:style-name { styleNameRef }?
3206   & xml-id?
3207 chart-data-label =
3208   element chart:data-label { chart-data-label-attlist, text-p? }
3209 chart-data-label-attlist =
3210   common-draw-position-attlist
3211   & attribute chart:style-name { styleNameRef }?
3212 chart-mean-value =
3213   element chart:mean-value { chart-mean-value-attlist, empty }
3214 chart-mean-value-attlist = attribute chart:style-name { styleNameRef }?
3215 chart-error-indicator =
3216   element chart:error-indicator { chart-error-indicator-attlist, empty }
3217 chart-error-indicator-attlist =
3218   attribute chart:style-name { styleNameRef }?
3219   & attribute chart:dimension { chart-dimension }
3220 chart-regression-curve =
3221   element chart:regression-curve {
3222     chart-regression-curve-attlist, chart-equation?
3223   }
3224 chart-regression-curve-attlist =
3225   attribute chart:style-name { styleNameRef }?
3226 chart-equation =
3227   element chart:equation { chart-equation-attlist, text-p? }
3228 chart-equation-attlist =
3229   attribute chart:automatic-content { boolean }?
3230   & attribute chart:display-r-square { boolean }?
3231   & attribute chart:display-equation { boolean }?
3232   & common-draw-position-attlist
3233   & attribute chart:style-name { styleNameRef }?
3234 chart-stock-gain-marker =
3235   element chart:stock-gain-marker { common-stock-marker-attlist }
3236 chart-stock-loss-marker =
3237   element chart:stock-loss-marker { common-stock-marker-attlist }
3238 chart-stock-range-line =
3239   element chart:stock-range-line { common-stock-marker-attlist }
3240 common-stock-marker-attlist =
3241   attribute chart:style-name { styleNameRef }?
3242 office-database =
3243   element office:database {
3244     db-data-source,
3245     db-forms?,
3246     db-reports?,
3247     db-queries?,
3248     db-table-presentations?,
3249     db-schema-definition?
3250   }
3251 db-data-source =
3252   element db:data-source {
3253     db-data-source-attlist,
3254     db-connection-data,
3255     db-driver-settings?,
3256     db-application-connection-settings?
3257   }
3258 db-data-source-attlist = empty
3259 db-connection-data =
3260   element db:connection-data {
3261     db-connection-data-attlist,
3262     (db-database-description | db-connection-resource),
3263     db-login?
3264   }
3265 db-connection-data-attlist = empty
3266 db-database-description =
3267   element db:database-description {
3268     db-database-description-attlist,
3269     (db-file-based-database | db-server-database)
3270   }
3271 db-database-description-attlist = empty
3272 db-file-based-database =
3273   element db:file-based-database { db-file-based-database-attlist }
3274 db-file-based-database-attlist =
3275   attribute xlink:type { "simple" }
3276   & attribute xlink:href { anyIRI }
3277   & attribute db:media-type { \string }
3278   & attribute db:extension { \string }?
3279 db-server-database =
3280   element db:server-database { db-server-database-attlist, empty }
3281 db-server-database-attlist =
3282   attribute db:type { namespacedToken }
3283   & (db-host-and-port | db-local-socket-name)
3284   & attribute db:database-name { \string }?
3285 db-host-and-port =
3286   attribute db:hostname { \string },
3287   attribute db:port { positiveInteger }?
3288 db-local-socket-name = attribute db:local-socket { \string }?
3289 db-connection-resource =
3290   element db:connection-resource {
3291     db-connection-resource-attlist, empty
3292   }
3293 db-connection-resource-attlist =
3294   attribute xlink:type { "simple" },
3295   attribute xlink:href { anyIRI },
3296   attribute xlink:show { "none" }?,
3297   attribute xlink:actuate { "onRequest" }?
3298 db-login = element db:login { db-login-attlist, empty }
3299 db-login-attlist =
3300   (attribute db:user-name { \string }
3301    | attribute db:use-system-user { boolean })?
3302   & attribute db:is-password-required { boolean }?
3303   & attribute db:login-timeout { positiveInteger }?
3304 db-driver-settings =
3305   element db:driver-settings {
3306     db-driver-settings-attlist,
3307     db-auto-increment?,
3308     db-delimiter?,
3309     db-character-set?,
3310     db-table-settings?
3311   }
3312 db-driver-settings-attlist =
3313   db-show-deleted
3314   & attribute db:system-driver-settings { \string }?
3315   & attribute db:base-dn { \string }?
3316   & db-is-first-row-header-line
3317   & attribute db:parameter-name-substitution { boolean }?
3318 db-show-deleted = attribute db:show-deleted { boolean }?
3319 db-is-first-row-header-line =
3320   attribute db:is-first-row-header-line { boolean }?
3321 db-auto-increment =
3322   element db:auto-increment { db-auto-increment-attlist, empty }
3323 db-auto-increment-attlist =
3324   attribute db:additional-column-statement { \string }?
3325   & attribute db:row-retrieving-statement { \string }?
3326 db-delimiter = element db:delimiter { db-delimiter-attlist, empty }
3327 db-delimiter-attlist =
3328   attribute db:field { \string }?
3329   & attribute db:string { \string }?
3330   & attribute db:decimal { \string }?
3331   & attribute db:thousand { \string }?
3332 db-character-set =
3333   element db:character-set { db-character-set-attlist, empty }
3334 db-character-set-attlist = attribute db:encoding { textEncoding }?
3335 db-table-settings = element db:table-settings { db-table-setting* }
3336 db-table-setting =
3337   element db:table-setting {
3338     db-table-setting-attlist, db-delimiter?, db-character-set?, empty
3339   }
3340 db-table-setting-attlist = db-is-first-row-header-line, db-show-deleted
3341 db-application-connection-settings =
3342   element db:application-connection-settings {
3343     db-application-connection-settings-attlist,
3344     db-table-filter?,
3345     db-table-type-filter?,
3346     db-data-source-settings?
3347   }
3348 db-application-connection-settings-attlist =
3349   attribute db:is-table-name-length-limited { boolean }?
3350   & attribute db:enable-sql92-check { boolean }?
3351   & attribute db:append-table-alias-name { boolean }?
3352   & attribute db:ignore-driver-privileges { boolean }?
3353   & attribute db:boolean-comparison-mode {
3354       "equal-integer"
3355       | "is-boolean"
3356       | "equal-boolean"
3357       | "equal-use-only-zero"
3358     }?
3359   & attribute db:use-catalog { boolean }?
3360   & attribute db:max-row-count { integer }?
3361   & attribute db:suppress-version-columns { boolean }?
3362 db-table-filter =
3363   element db:table-filter {
3364     db-table-filter-attlist,
3365     db-table-include-filter?,
3366     db-table-exclude-filter?
3367   }
3368 db-table-filter-attlist = empty
3369 db-table-include-filter =
3370   element db:table-include-filter {
3371     db-table-include-filter-attlist, db-table-filter-pattern+
3372   }
3373 db-table-include-filter-attlist = empty
3374 db-table-exclude-filter =
3375   element db:table-exclude-filter {
3376     db-table-exclude-filter-attlist, db-table-filter-pattern+
3377   }
3378 db-table-exclude-filter-attlist = empty
3379 db-table-filter-pattern =
3380   element db:table-filter-pattern {
3381     db-table-filter-pattern-attlist, \string
3382   }
3383 db-table-filter-pattern-attlist = empty
3384 db-table-type-filter =
3385   element db:table-type-filter {
3386     db-table-type-filter-attlist, db-table-type*
3387   }
3388 db-table-type-filter-attlist = empty
3389 db-table-type = element db:table-type { db-table-type-attlist, \string }
3390 db-table-type-attlist = empty
3391 db-data-source-settings =
3392   element db:data-source-settings {
3393     db-data-source-settings-attlist, db-data-source-setting+
3394   }
3395 db-data-source-settings-attlist = empty
3396 db-data-source-setting =
3397   element db:data-source-setting {
3398     db-data-source-setting-attlist, db-data-source-setting-value+
3399   }
3400 db-data-source-setting-attlist =
3401   attribute db:data-source-setting-is-list { boolean }?
3402   & attribute db:data-source-setting-name { \string }
3403   & attribute db:data-source-setting-type {
3404       db-data-source-setting-types
3405     }
3406 db-data-source-setting-types =
3407   "boolean" | "short" | "int" | "long" | "double" | "string"
3408 db-data-source-setting-value =
3409   element db:data-source-setting-value {
3410     db-data-source-setting-value-attlist, \string
3411   }
3412 db-data-source-setting-value-attlist = empty
3413 db-forms =
3414   element db:forms {
3415     db-forms-attlist, (db-component | db-component-collection)*
3416   }
3417 db-forms-attlist = empty
3418 db-reports =
3419   element db:reports {
3420     db-reports-attlist, (db-component | db-component-collection)*
3421   }
3422 db-reports-attlist = empty
3423 db-component-collection =
3424   element db:component-collection {
3425     db-component-collection-attlist,
3426     common-db-object-name,
3427     common-db-object-title,
3428     common-db-object-description,
3429     (db-component | db-component-collection)*
3430   }
3431 db-component-collection-attlist = empty
3432 db-component =
3433   element db:component {
3434     db-component-attlist,
3435     common-db-object-name,
3436     common-db-object-title,
3437     common-db-object-description,
3438     (office-document | math-math)?
3439   }
3440 db-component-attlist =
3441   (attribute xlink:type { "simple" },
3442    attribute xlink:href { anyIRI },
3443    attribute xlink:show { "none" }?,
3444    attribute xlink:actuate { "onRequest" }?)?
3445   & attribute db:as-template { boolean }?
3446 db-queries =
3447   element db:queries {
3448     db-queries-attlist, (db-query | db-query-collection)*
3449   }
3450 db-queries-attlist = empty
3451 db-query-collection =
3452   element db:query-collection {
3453     db-query-collection-attlist,
3454     common-db-object-name,
3455     common-db-object-title,
3456     common-db-object-description,
3457     (db-query | db-query-collection)*
3458   }
3459 db-query-collection-attlist = empty
3460 db-query =
3461   element db:query {
3462     db-query-attlist,
3463     common-db-object-name,
3464     common-db-object-title,
3465     common-db-object-description,
3466     common-db-table-style-name,
3467     db-order-statement?,
3468     db-filter-statement?,
3469     db-columns?,
3470     db-update-table?
3471   }
3472 db-query-attlist =
3473   attribute db:command { \string }
3474   & attribute db:escape-processing { boolean }?
3475 db-order-statement =
3476   element db:order-statement { db-command, db-apply-command, empty }
3477 db-filter-statement =
3478   element db:filter-statement { db-command, db-apply-command, empty }
3479 db-update-table =
3480   element db:update-table { common-db-table-name-attlist }
3481 db-table-presentations =
3482   element db:table-representations {
3483     db-table-presentations-attlist, db-table-presentation*
3484   }
3485 db-table-presentations-attlist = empty
3486 db-table-presentation =
3487   element db:table-representation {
3488     db-table-presentation-attlist,
3489     common-db-table-name-attlist,
3490     common-db-object-title,
3491     common-db-object-description,
3492     common-db-table-style-name,
3493     db-order-statement?,
3494     db-filter-statement?,
3495     db-columns?
3496   }
3497 db-table-presentation-attlist = empty
3498 db-columns = element db:columns { db-columns-attlist, db-column+ }
3499 db-columns-attlist = empty
3500 db-column =
3501   element db:column {
3502     db-column-attlist,
3503     common-db-object-name,
3504     common-db-object-title,
3505     common-db-object-description,
3506     common-db-default-value
3507   }
3508 db-column-attlist =
3509   attribute db:visible { boolean }?
3510   & attribute db:style-name { styleNameRef }?
3511   & attribute db:default-cell-style-name { styleNameRef }?
3512 db-command = attribute db:command { \string }
3513 db-apply-command = attribute db:apply-command { boolean }?
3514 common-db-table-name-attlist =
3515   attribute db:name { \string }
3516   & attribute db:catalog-name { \string }?
3517   & attribute db:schema-name { \string }?
3518 common-db-object-name = attribute db:name { \string }
3519 common-db-object-title = attribute db:title { \string }?
3520 common-db-object-description = attribute db:description { \string }?
3521 common-db-table-style-name =
3522   attribute db:style-name { styleNameRef }?
3523   & attribute db:default-row-style-name { styleNameRef }?
3524 common-db-default-value = common-value-and-type-attlist?
3525 db-schema-definition =
3526   element db:schema-definition {
3527     db-schema-definition-attlist, db-table-definitions
3528   }
3529 db-schema-definition-attlist = empty
3530 db-table-definitions =
3531   element db:table-definitions {
3532     db-table-definitions-attlist, db-table-definition*
3533   }
3534 db-table-definitions-attlist = empty
3535 db-table-definition =
3536   element db:table-definition {
3537     common-db-table-name-attlist,
3538     db-table-definition-attlist,
3539     db-column-definitions,
3540     db-keys?,
3541     db-indices?
3542   }
3543 db-table-definition-attlist = attribute db:type { \string }?
3544 db-column-definitions =
3545   element db:column-definitions {
3546     db-column-definitions-attlist, db-column-definition+
3547   }
3548 db-column-definitions-attlist = empty
3549 db-column-definition =
3550   element db:column-definition {
3551     db-column-definition-attlist, common-db-default-value
3552   }
3553 db-column-definition-attlist =
3554   attribute db:name { \string }
3555   & attribute db:data-type { db-data-types }?
3556   & attribute db:type-name { \string }?
3557   & attribute db:precision { positiveInteger }?
3558   & attribute db:scale { positiveInteger }?
3559   & attribute db:is-nullable { "no-nulls" | "nullable" }?
3560   & attribute db:is-empty-allowed { boolean }?
3561   & attribute db:is-autoincrement { boolean }?
3562 db-data-types =
3563   "bit"
3564   | "boolean"
3565   | "tinyint"
3566   | "smallint"
3567   | "integer"
3568   | "bigint"
3569   | "float"
3570   | "real"
3571   | "double"
3572   | "numeric"
3573   | "decimal"
3574   | "char"
3575   | "varchar"
3576   | "longvarchar"
3577   | "date"
3578   | "time"
3579   | "timestmp"
3580   | "binary"
3581   | "varbinary"
3582   | "longvarbinary"
3583   | "sqlnull"
3584   | "other"
3585   | "object"
3586   | "distinct"
3587   | "struct"
3588   | "array"
3589   | "blob"
3590   | "clob"
3591   | "ref"
3592 db-keys = element db:keys { db-keys-attlist, db-key+ }
3593 db-keys-attlist = empty
3594 db-key = element db:key { db-key-attlist, db-key-columns+ }
3595 db-key-attlist =
3596   attribute db:name { \string }?
3597   & attribute db:type { "primary" | "unique" | "foreign" }
3598   & attribute db:referenced-table-name { \string }?
3599   & attribute db:update-rule {
3600       "cascade" | "restrict" | "set-null" | "no-action" | "set-default"
3601     }?
3602   & attribute db:delete-rule {
3603       "cascade" | "restrict" | "set-null" | "no-action" | "set-default"
3604     }?
3605 db-key-columns =
3606   element db:key-columns { db-key-columns-attlist, db-key-column+ }
3607 db-key-columns-attlist = empty
3608 db-key-column = element db:key-column { db-key-column-attlist, empty }
3609 db-key-column-attlist =
3610   attribute db:name { \string }?
3611   & attribute db:related-column-name { \string }?
3612 db-indices = element db:indices { db-indices-attlist, db-index+ }
3613 db-indices-attlist = empty
3614 db-index = element db:index { db-index-attlist, db-index-columns+ }
3615 db-index-attlist =
3616   attribute db:name { \string }
3617   & attribute db:catalog-name { \string }?
3618   & attribute db:is-unique { boolean }?
3619   & attribute db:is-clustered { boolean }?
3620 db-index-columns = element db:index-columns { db-index-column+ }
3621 db-index-column =
3622   element db:index-column { db-index-column-attlist, empty }
3623 db-index-column-attlist =
3624   attribute db:name { \string }
3625   & attribute db:is-ascending { boolean }?
3626 office-forms =
3627   element office:forms {
3628     office-forms-attlist, (form-form | xforms-model)*
3629   }?
3630 office-forms-attlist =
3631   attribute form:automatic-focus { boolean }?
3632   & attribute form:apply-design-mode { boolean }?
3633 form-form =
3634   element form:form {
3635     common-form-control-attlist,
3636     form-form-attlist,
3637     form-properties?,
3638     office-event-listeners?,
3639     (controls | form-form)*,
3640     form-connection-resource?
3641   }
3642 form-form-attlist =
3643   (attribute xlink:type { "simple" },
3644    attribute xlink:href { anyIRI },
3645    attribute xlink:actuate { "onRequest" }?)?
3646   & attribute office:target-frame { targetFrameName }?
3647   & attribute form:method { "get" | "post" | \string }?
3648   & attribute form:enctype { \string }?
3649   & attribute form:allow-deletes { boolean }?
3650   & attribute form:allow-inserts { boolean }?
3651   & attribute form:allow-updates { boolean }?
3652   & attribute form:apply-filter { boolean }?
3653   & attribute form:command-type { "table" | "query" | "command" }?
3654   & attribute form:command { \string }?
3655   & attribute form:datasource { anyIRI | \string }?
3656   & attribute form:master-fields { \string }?
3657   & attribute form:detail-fields { \string }?
3658   & attribute form:escape-processing { boolean }?
3659   & attribute form:filter { \string }?
3660   & attribute form:ignore-result { boolean }?
3661   & attribute form:navigation-mode { navigation }?
3662   & attribute form:order { \string }?
3663   & attribute form:tab-cycle { tab-cycles }?
3664 navigation = "none" | "current" | "parent"
3665 tab-cycles = "records" | "current" | "page"
3666 form-connection-resource =
3667   element form:connection-resource {
3668     attribute xlink:href { anyIRI },
3669     empty
3670   }
3671 xforms-model = element xforms:model { anyAttListOrElements }
3672 column-controls =
3673   element form:text { form-text-attlist, common-form-control-content }
3674   | element form:textarea {
3675       form-textarea-attlist, common-form-control-content, text-p*
3676     }
3677   | element form:formatted-text {
3678       form-formatted-text-attlist, common-form-control-content
3679     }
3680   | element form:number {
3681       form-number-attlist,
3682       common-numeric-control-attlist,
3683       common-form-control-content,
3684       common-linked-cell,
3685       common-spin-button,
3686       common-repeat,
3687       common-delay-for-repeat
3688     }
3689   | element form:date {
3690       form-date-attlist,
3691       common-numeric-control-attlist,
3692       common-form-control-content,
3693       common-linked-cell,
3694       common-spin-button,
3695       common-repeat,
3696       common-delay-for-repeat
3697     }
3698   | element form:time {
3699       form-time-attlist,
3700       common-numeric-control-attlist,
3701       common-form-control-content,
3702       common-linked-cell,
3703       common-spin-button,
3704       common-repeat,
3705       common-delay-for-repeat
3706     }
3707   | element form:combobox {
3708       form-combobox-attlist, common-form-control-content, form-item*
3709     }
3710   | element form:listbox {
3711       form-listbox-attlist, common-form-control-content, form-option*
3712     }
3713   | element form:checkbox {
3714       form-checkbox-attlist, common-form-control-content
3715     }
3716 controls =
3717   column-controls
3718   | element form:password {
3719       form-password-attlist, common-form-control-content
3720     }
3721   | element form:file { form-file-attlist, common-form-control-content }
3722   | element form:fixed-text {
3723       form-fixed-text-attlist, common-form-control-content
3724     }
3725   | element form:button {
3726       form-button-attlist, common-form-control-content
3727     }
3728   | element form:image {
3729       form-image-attlist, common-form-control-content
3730     }
3731   | element form:radio {
3732       form-radio-attlist, common-form-control-content
3733     }
3734   | element form:frame {
3735       form-frame-attlist, common-form-control-content
3736     }
3737   | element form:image-frame {
3738       form-image-frame-attlist, common-form-control-content
3739     }
3740   | element form:hidden {
3741       form-hidden-attlist, common-form-control-content
3742     }
3743   | element form:grid {
3744       form-grid-attlist, common-form-control-content, form-column*
3745     }
3746   | element form:value-range {
3747       form-value-range-attlist, common-form-control-content
3748     }
3749   | element form:generic-control {
3750       form-generic-control-attlist, common-form-control-content
3751     }
3752 form-text-attlist =
3753   form-control-attlist,
3754   common-current-value-attlist,
3755   common-disabled-attlist,
3756   common-maxlength-attlist,
3757   common-printable-attlist,
3758   common-readonly-attlist,
3759   common-tab-attlist,
3760   common-title-attlist,
3761   common-value-attlist,
3762   common-convert-empty-attlist,
3763   common-data-field-attlist,
3764   common-linked-cell
3765 form-control-attlist =
3766   common-form-control-attlist,
3767   common-control-id-attlist,
3768   xforms-bind-attlist
3769 common-form-control-content = form-properties?, office-event-listeners?
3770 form-textarea-attlist =
3771   form-control-attlist,
3772   common-current-value-attlist,
3773   common-disabled-attlist,
3774   common-maxlength-attlist,
3775   common-printable-attlist,
3776   common-readonly-attlist,
3777   common-tab-attlist,
3778   common-title-attlist,
3779   common-value-attlist,
3780   common-convert-empty-attlist,
3781   common-data-field-attlist,
3782   common-linked-cell
3783 form-password-attlist =
3784   form-control-attlist
3785   & common-disabled-attlist
3786   & common-maxlength-attlist
3787   & common-printable-attlist
3788   & common-tab-attlist
3789   & common-title-attlist
3790   & common-value-attlist
3791   & common-convert-empty-attlist
3792   & common-linked-cell
3793   & attribute form:echo-char { character }?
3794 form-file-attlist =
3795   form-control-attlist,
3796   common-current-value-attlist,
3797   common-disabled-attlist,
3798   common-maxlength-attlist,
3799   common-printable-attlist,
3800   common-readonly-attlist,
3801   common-tab-attlist,
3802   common-title-attlist,
3803   common-value-attlist,
3804   common-linked-cell
3805 form-formatted-text-attlist =
3806   form-control-attlist
3807   & common-current-value-attlist
3808   & common-disabled-attlist
3809   & common-maxlength-attlist
3810   & common-printable-attlist
3811   & common-readonly-attlist
3812   & common-tab-attlist
3813   & common-title-attlist
3814   & common-value-attlist
3815   & common-convert-empty-attlist
3816   & common-data-field-attlist
3817   & common-linked-cell
3818   & common-spin-button
3819   & common-repeat
3820   & common-delay-for-repeat
3821   & attribute form:max-value { \string }?
3822   & attribute form:min-value { \string }?
3823   & attribute form:validation { boolean }?
3824 common-numeric-control-attlist =
3825   form-control-attlist,
3826   common-disabled-attlist,
3827   common-maxlength-attlist,
3828   common-printable-attlist,
3829   common-readonly-attlist,
3830   common-tab-attlist,
3831   common-title-attlist,
3832   common-convert-empty-attlist,
3833   common-data-field-attlist
3834 form-number-attlist =
3835   attribute form:value { double }?
3836   & attribute form:current-value { double }?
3837   & attribute form:min-value { double }?
3838   & attribute form:max-value { double }?
3839 form-date-attlist =
3840   attribute form:value { date }?
3841   & attribute form:current-value { date }?
3842   & attribute form:min-value { date }?
3843   & attribute form:max-value { date }?
3844 form-time-attlist =
3845   attribute form:value { time }?
3846   & attribute form:current-value { time }?
3847   & attribute form:min-value { time }?
3848   & attribute form:max-value { time }?
3849 form-fixed-text-attlist =
3850   form-control-attlist
3851   & for
3852   & common-disabled-attlist
3853   & label
3854   & common-printable-attlist
3855   & common-title-attlist
3856   & attribute form:multi-line { boolean }?
3857 form-combobox-attlist =
3858   form-control-attlist
3859   & common-current-value-attlist
3860   & common-disabled-attlist
3861   & dropdown
3862   & common-maxlength-attlist
3863   & common-printable-attlist
3864   & common-readonly-attlist
3865   & size
3866   & common-tab-attlist
3867   & common-title-attlist
3868   & common-value-attlist
3869   & common-convert-empty-attlist
3870   & common-data-field-attlist
3871   & list-source
3872   & list-source-type
3873   & common-linked-cell
3874   & common-source-cell-range
3875   & attribute form:auto-complete { boolean }?
3876 form-item = element form:item { form-item-attlist, text }
3877 form-item-attlist = label
3878 form-listbox-attlist =
3879   form-control-attlist
3880   & common-disabled-attlist
3881   & dropdown
3882   & common-printable-attlist
3883   & size
3884   & common-tab-attlist
3885   & common-title-attlist
3886   & bound-column
3887   & common-data-field-attlist
3888   & list-source
3889   & list-source-type
3890   & common-linked-cell
3891   & list-linkage-type
3892   & common-source-cell-range
3893   & attribute form:multiple { boolean }?
3894   & attribute form:xforms-list-source { \string }?
3895 list-linkage-type =
3896   attribute form:list-linkage-type {
3897     "selection" | "selection-indices"
3898   }?
3899 form-option = element form:option { form-option-attlist, text }
3900 form-option-attlist =
3901   current-selected, selected, label, common-value-attlist
3902 form-button-attlist =
3903   form-control-attlist
3904   & button-type
3905   & common-disabled-attlist
3906   & label
3907   & image-data
3908   & common-printable-attlist
3909   & common-tab-attlist
3910   & target-frame
3911   & target-location
3912   & common-title-attlist
3913   & common-value-attlist
3914   & common-form-relative-image-position-attlist
3915   & common-repeat
3916   & common-delay-for-repeat
3917   & attribute form:default-button { boolean }?
3918   & attribute form:toggle { boolean }?
3919   & attribute form:focus-on-click { boolean }?
3920   & attribute form:xforms-submission { \string }?
3921 form-image-attlist =
3922   form-control-attlist,
3923   button-type,
3924   common-disabled-attlist,
3925   image-data,
3926   common-printable-attlist,
3927   common-tab-attlist,
3928   target-frame,
3929   target-location,
3930   common-title-attlist,
3931   common-value-attlist
3932 form-checkbox-attlist =
3933   form-control-attlist
3934   & common-disabled-attlist
3935   & label
3936   & common-printable-attlist
3937   & common-tab-attlist
3938   & common-title-attlist
3939   & common-value-attlist
3940   & common-data-field-attlist
3941   & common-form-visual-effect-attlist
3942   & common-form-relative-image-position-attlist
3943   & common-linked-cell
3944   & attribute form:current-state { states }?
3945   & attribute form:is-tristate { boolean }?
3946   & attribute form:state { states }?
3947 states = "unchecked" | "checked" | "unknown"
3948 form-radio-attlist =
3949   form-control-attlist,
3950   current-selected,
3951   common-disabled-attlist,
3952   label,
3953   common-printable-attlist,
3954   selected,
3955   common-tab-attlist,
3956   common-title-attlist,
3957   common-value-attlist,
3958   common-data-field-attlist,
3959   common-form-visual-effect-attlist,
3960   common-form-relative-image-position-attlist,
3961   common-linked-cell
3962 form-frame-attlist =
3963   form-control-attlist,
3964   common-disabled-attlist,
3965   for,
3966   label,
3967   common-printable-attlist,
3968   common-title-attlist
3969 form-image-frame-attlist =
3970   form-control-attlist,
3971   common-disabled-attlist,
3972   image-data,
3973   common-printable-attlist,
3974   common-readonly-attlist,
3975   common-title-attlist,
3976   common-data-field-attlist
3977 form-hidden-attlist = form-control-attlist, common-value-attlist
3978 form-grid-attlist =
3979   form-control-attlist,
3980   common-disabled-attlist,
3981   common-printable-attlist,
3982   common-tab-attlist,
3983   common-title-attlist
3984 form-column =
3985   element form:column { form-column-attlist, column-controls+ }
3986 form-column-attlist =
3987   common-form-control-attlist, label, text-style-name
3988 text-style-name = attribute form:text-style-name { styleNameRef }?
3989 form-value-range-attlist =
3990   form-control-attlist
3991   & common-disabled-attlist
3992   & common-printable-attlist
3993   & common-tab-attlist
3994   & common-title-attlist
3995   & common-value-attlist
3996   & common-linked-cell
3997   & common-repeat
3998   & common-delay-for-repeat
3999   & attribute form:max-value { integer }?
4000   & attribute form:min-value { integer }?
4001   & attribute form:step-size { positiveInteger }?
4002   & attribute form:page-step-size { positiveInteger }?
4003   & attribute form:orientation { "horizontal" | "vertical" }?
4004 form-generic-control-attlist = form-control-attlist
4005 common-form-control-attlist =
4006   attribute form:name { \string }?
4007   & attribute form:control-implementation { namespacedToken }?
4008 xforms-bind-attlist = attribute xforms:bind { \string }?
4009 types = "submit" | "reset" | "push" | "url"
4010 button-type = attribute form:button-type { types }?
4011 common-control-id-attlist =
4012   xml-id,
4013   attribute form:id { NCName }?
4014 current-selected = attribute form:current-selected { boolean }?
4015 common-value-attlist = attribute form:value { \string }?
4016 common-current-value-attlist = attribute form:current-value { \string }?
4017 common-disabled-attlist = attribute form:disabled { boolean }?
4018 dropdown = attribute form:dropdown { boolean }?
4019 for = attribute form:for { \string }?
4020 image-data = attribute form:image-data { anyIRI }?
4021 label = attribute form:label { \string }?
4022 common-maxlength-attlist =
4023   attribute form:max-length { nonNegativeInteger }?
4024 common-printable-attlist = attribute form:printable { boolean }?
4025 common-readonly-attlist = attribute form:readonly { boolean }?
4026 selected = attribute form:selected { boolean }?
4027 size = attribute form:size { nonNegativeInteger }?
4028 common-tab-attlist =
4029   attribute form:tab-index { nonNegativeInteger }?
4030   & attribute form:tab-stop { boolean }?
4031 target-frame = attribute office:target-frame { targetFrameName }?
4032 target-location = attribute xlink:href { anyIRI }?
4033 common-title-attlist = attribute form:title { \string }?
4034 common-form-visual-effect-attlist =
4035   attribute form:visual-effect { "flat" | "3d" }?
4036 common-form-relative-image-position-attlist =
4037   attribute form:image-position { "center" }?
4038   | (attribute form:image-position {
4039        "start" | "end" | "top" | "bottom"
4040      },
4041      attribute form:image-align { "start" | "center" | "end" }?)
4042 bound-column = attribute form:bound-column { \string }?
4043 common-convert-empty-attlist =
4044   attribute form:convert-empty-to-null { boolean }?
4045 common-data-field-attlist = attribute form:data-field { \string }?
4046 list-source = attribute form:list-source { \string }?
4047 list-source-type =
4048   attribute form:list-source-type {
4049     "table"
4050     | "query"
4051     | "sql"
4052     | "sql-pass-through"
4053     | "value-list"
4054     | "table-fields"
4055   }?
4056 common-linked-cell =
4057   attribute form:linked-cell { cellAddress | \string }?
4058 common-source-cell-range =
4059   attribute form:source-cell-range { cellRangeAddress | \string }?
4060 common-spin-button = attribute form:spin-button { boolean }?
4061 common-repeat = attribute form:repeat { boolean }?
4062 common-delay-for-repeat = attribute form:delay-for-repeat { duration }?
4063 form-properties = element form:properties { form-property+ }
4064 form-property =
4065   element form:property {
4066     form-property-name, form-property-value-and-type-attlist
4067   }
4068   | element form:list-property {
4069       form-property-name, form-property-type-and-value-list
4070     }
4071 form-property-name = attribute form:property-name { \string }
4072 form-property-value-and-type-attlist =
4073   common-value-and-type-attlist
4074   | attribute office:value-type { "void" }
4075 form-property-type-and-value-list =
4076   (attribute office:value-type { "float" },
4077    element form:list-value {
4078      attribute office:value { double }
4079    }*)
4080   | (attribute office:value-type { "percentage" },
4081      element form:list-value {
4082        attribute office:value { double }
4083      }*)
4084   | (attribute office:value-type { "currency" },
4085      element form:list-value {
4086        attribute office:value { double },
4087        attribute office:currency { \string }?
4088      }*)
4089   | (attribute office:value-type { "date" },
4090      element form:list-value {
4091        attribute office:date-value { dateOrDateTime }
4092      }*)
4093   | (attribute office:value-type { "time" },
4094      element form:list-value {
4095        attribute office:time-value { duration }
4096      }*)
4097   | (attribute office:value-type { "boolean" },
4098      element form:list-value {
4099        attribute office:boolean-value { boolean }
4100      }*)
4101   | (attribute office:value-type { "string" },
4102      element form:list-value {
4103        attribute office:string-value { \string }
4104      }*)
4105   | attribute office:value-type { "void" }
4106 office-annotation =
4107   element office:annotation {
4108     office-annotation-attlist,
4109     draw-caption-attlist,
4110     common-draw-position-attlist,
4111     common-draw-size-attlist,
4112     common-draw-shape-with-text-and-styles-attlist,
4113     dc-creator?,
4114     dc-date?,
4115     meta-date-string?,
4116     (text-p | text-list)*
4117   }
4118 office-annotation-end =
4119   element office:annotation-end { office-annotation-end-attlist }
4120 office-annotation-attlist =
4121   attribute office:display { boolean }?
4122   & common-office-annotation-name-attlist?
4123 office-annotation-end-attlist = common-office-annotation-name-attlist
4124 common-office-annotation-name-attlist =
4125   attribute office:name { \string }
4126 meta-date-string = element meta:date-string { \string }
4127 common-num-format-prefix-suffix-attlist =
4128   attribute style:num-prefix { \string }?,
4129   attribute style:num-suffix { \string }?
4130 common-num-format-attlist =
4131   attribute style:num-format { "1" | "i" | "I" | \string | empty }
4132   | (attribute style:num-format { "a" | "A" },
4133      style-num-letter-sync-attlist)
4134   | empty
4135 style-num-letter-sync-attlist =
4136   attribute style:num-letter-sync { boolean }?
4137 office-change-info =
4138   element office:change-info { dc-creator, dc-date, text-p* }
4139 office-event-listeners =
4140   element office:event-listeners {
4141     (script-event-listener | presentation-event-listener)*
4142   }
4143 script-event-listener =
4144   element script:event-listener { script-event-listener-attlist, empty }
4145 script-event-listener-attlist =
4146   attribute script:event-name { \string }
4147   & attribute script:language { \string }
4148   & (attribute script:macro-name { \string }
4149      | (attribute xlink:type { "simple" },
4150         attribute xlink:href { anyIRI },
4151         attribute xlink:actuate { "onRequest" }?))
4152 math-math = element math:math { mathMarkup }
4154   dc:description [
4155     "To avoid inclusion of the complete MathML schema, anything is allowed within a math:math top-level element"
4156   ]
4158 mathMarkup =
4159   (attribute * { text }
4160    | text
4161    | element * { mathMarkup })*
4162 text-dde-connection-decl =
4163   element text:dde-connection-decl {
4164     text-dde-connection-decl-attlist, common-dde-connection-decl-attlist
4165   }
4166 text-dde-connection-decl-attlist = attribute office:name { \string }
4167 common-dde-connection-decl-attlist =
4168   attribute office:dde-application { \string }
4169   & attribute office:dde-topic { \string }
4170   & attribute office:dde-item { \string }
4171   & attribute office:automatic-update { boolean }?
4172 table-dde-link =
4173   element table:dde-link { office-dde-source, table-table }
4174 office-dde-source =
4175   element office:dde-source {
4176     office-dde-source-attlist, common-dde-connection-decl-attlist
4177   }
4178 office-dde-source-attlist =
4179   attribute office:name { \string }?
4180   & attribute office:conversion-mode {
4181       "into-default-style-data-style"
4182       | "into-english-number"
4183       | "keep-text"
4184     }?
4185 animation-element =
4186   element anim:animate {
4187     common-anim-target-attlist,
4188     common-anim-named-target-attlist,
4189     common-anim-values-attlist,
4190     common-anim-spline-mode-attlist,
4191     common-spline-anim-value-attlist,
4192     common-timing-attlist,
4193     common-anim-add-accum-attlist
4194   }
4195   | element anim:set {
4196       common-anim-target-attlist,
4197       common-anim-named-target-attlist,
4198       common-anim-set-values-attlist,
4199       common-timing-attlist,
4200       common-anim-add-accum-attlist
4201     }
4202   | element anim:animateMotion {
4203       anim-animate-motion-attlist,
4204       common-anim-target-attlist,
4205       common-anim-named-target-attlist,
4206       common-anim-add-accum-attlist,
4207       common-anim-values-attlist,
4208       common-timing-attlist,
4209       common-spline-anim-value-attlist
4210     }
4211   | element anim:animateColor {
4212       common-anim-target-attlist,
4213       common-anim-named-target-attlist,
4214       common-anim-add-accum-attlist,
4215       common-anim-values-attlist,
4216       common-anim-spline-mode-attlist,
4217       common-spline-anim-value-attlist,
4218       anim-animate-color-attlist,
4219       common-timing-attlist
4220     }
4221   | element anim:animateTransform {
4222       common-anim-target-attlist,
4223       common-anim-named-target-attlist,
4224       common-anim-add-accum-attlist,
4225       common-anim-values-attlist,
4226       anim-animate-transform-attlist,
4227       common-timing-attlist
4228     }
4229   | element anim:transitionFilter {
4230       common-anim-target-attlist,
4231       common-anim-add-accum-attlist,
4232       common-anim-values-attlist,
4233       common-anim-spline-mode-attlist,
4234       anim-transition-filter-attlist,
4235       common-timing-attlist
4236     }
4237   | element anim:par {
4238       common-anim-attlist,
4239       common-timing-attlist,
4240       common-endsync-timing-attlist,
4241       animation-element*
4242     }
4243   | element anim:seq {
4244       common-anim-attlist,
4245       common-endsync-timing-attlist,
4246       common-timing-attlist,
4247       animation-element*
4248     }
4249   | element anim:iterate {
4250       common-anim-attlist,
4251       anim-iterate-attlist,
4252       common-timing-attlist,
4253       common-endsync-timing-attlist,
4254       animation-element*
4255     }
4256   | element anim:audio {
4257       common-anim-attlist,
4258       anim-audio-attlist,
4259       common-basic-timing-attlist
4260     }
4261   | element anim:command {
4262       common-anim-attlist,
4263       anim-command-attlist,
4264       common-begin-end-timing-attlist,
4265       common-anim-target-attlist,
4266       element anim:param {
4267         attribute anim:name { \string },
4268         attribute anim:value { \string }
4269       }*
4270     }
4271 anim-animate-motion-attlist =
4272   attribute svg:path { pathData }?
4273   & attribute svg:origin { \string }?
4274   & attribute smil:calcMode {
4275       "discrete" | "linear" | "paced" | "spline"
4276     }?
4277 anim-animate-color-attlist =
4278   attribute anim:color-interpolation { "rgb" | "hsl" }?
4279   & attribute anim:color-interpolation-direction {
4280       "clockwise" | "counter-clockwise"
4281     }?
4282 anim-animate-transform-attlist =
4283   attribute svg:type {
4284     "translate" | "scale" | "rotate" | "skewX" | "skewY"
4285   }
4286 anim-transition-filter-attlist =
4287   attribute smil:type { \string }
4288   & attribute smil:subtype { \string }?
4289   & attribute smil:direction { "forward" | "reverse" }?
4290   & attribute smil:fadeColor { color }?
4291   & attribute smil:mode { "in" | "out" }?
4292 common-anim-target-attlist =
4293   attribute smil:targetElement { IDREF }?
4294   & attribute anim:sub-item { \string }?
4295 common-anim-named-target-attlist =
4296   attribute smil:attributeName { \string }
4297 common-anim-values-attlist =
4298   attribute smil:values { \string }?
4299   & attribute anim:formula { \string }?
4300   & common-anim-set-values-attlist
4301   & attribute smil:from { \string }?
4302   & attribute smil:by { \string }?
4303 common-anim-spline-mode-attlist =
4304   attribute smil:calcMode {
4305     "discrete" | "linear" | "paced" | "spline"
4306   }?
4307 common-spline-anim-value-attlist =
4308   attribute smil:keyTimes { \string }?
4309   & attribute smil:keySplines { \string }?
4310 common-anim-add-accum-attlist =
4311   attribute smil:accumulate { "none" | "sum" }?
4312   & attribute smil:additive { "replace" | "sum" }?
4313 common-anim-set-values-attlist = attribute smil:to { \string }?
4314 common-begin-end-timing-attlist =
4315   attribute smil:begin { \string }?
4316   & attribute smil:end { \string }?
4317 common-dur-timing-attlist = attribute smil:dur { \string }?
4318 common-endsync-timing-attlist =
4319   attribute smil:endsync { "first" | "last" | "all" | "media" | IDREF }?
4320 common-repeat-timing-attlist =
4321   attribute smil:repeatDur { \string }?,
4322   attribute smil:repeatCount { nonNegativeDecimal | "indefinite" }?
4323 nonNegativeDecimal = xsd:decimal { minInclusive = "0.0" }
4324 common-fill-timing-attlist =
4325   attribute smil:fill {
4326     "remove" | "freeze" | "hold" | "auto" | "default" | "transition"
4327   }?
4328 common-fill-default-attlist =
4329   attribute smil:fillDefault {
4330     "remove" | "freeze" | "hold" | "transition" | "auto" | "inherit"
4331   }?
4332 common-restart-timing-attlist =
4333   attribute smil:restart {
4334     "never" | "always" | "whenNotActive" | "default"
4335   }?
4336 common-restart-default-attlist =
4337   attribute smil:restartDefault {
4338     "never" | "always" | "whenNotActive" | "inherit"
4339   }?
4340 common-time-manip-attlist =
4341   attribute smil:accelerate { zeroToOneDecimal }?
4342   & attribute smil:decelerate { zeroToOneDecimal }?
4343   & attribute smil:autoReverse { boolean }?
4344 zeroToOneDecimal = xsd:decimal { minInclusive = "0" maxInclusive = "1" }
4345 common-basic-timing-attlist =
4346   common-begin-end-timing-attlist,
4347   common-dur-timing-attlist,
4348   common-repeat-timing-attlist,
4349   common-restart-timing-attlist,
4350   common-restart-default-attlist,
4351   common-fill-timing-attlist,
4352   common-fill-default-attlist
4353 common-timing-attlist =
4354   common-basic-timing-attlist, common-time-manip-attlist
4355 anim-iterate-attlist =
4356   common-anim-target-attlist
4357   & attribute anim:iterate-type { \string }?
4358   & attribute anim:iterate-interval { duration }?
4359 anim-audio-attlist =
4360   attribute xlink:href { anyIRI }?
4361   & attribute anim:audio-level { double }?
4362 anim-command-attlist = attribute anim:command { \string }
4363 style-style =
4364   element style:style {
4365     style-style-attlist, style-style-content, style-map*
4366   }
4367 common-in-content-meta-attlist =
4368   attribute xhtml:about { URIorSafeCURIE },
4369   attribute xhtml:property { CURIEs },
4370   common-meta-literal-attlist
4371 common-meta-literal-attlist =
4372   attribute xhtml:datatype { CURIE }?,
4373   attribute xhtml:content { \string }?
4374 xml-id = attribute xml:id { ID }
4375 style-style-attlist =
4376   attribute style:name { styleName }
4377   & attribute style:display-name { \string }?
4378   & attribute style:parent-style-name { styleNameRef }?
4379   & attribute style:next-style-name { styleNameRef }?
4380   & attribute style:list-level { positiveInteger | empty }?
4381   & attribute style:list-style-name { styleName | empty }?
4382   & attribute style:master-page-name { styleNameRef }?
4383   & attribute style:auto-update { boolean }?
4384   & attribute style:data-style-name { styleNameRef }?
4385   & attribute style:percentage-data-style-name { styleNameRef }?
4386   & attribute style:class { \string }?
4387   & attribute style:default-outline-level { positiveInteger | empty }?
4388 style-map = element style:map { style-map-attlist, empty }
4389 style-map-attlist =
4390   attribute style:condition { \string }
4391   & attribute style:apply-style-name { styleNameRef }
4392   & attribute style:base-cell-address { cellAddress }?
4393 style-default-style =
4394   element style:default-style { style-style-content }
4395 style-page-layout =
4396   element style:page-layout {
4397     style-page-layout-attlist, style-page-layout-content
4398   }
4399 style-page-layout-content =
4400   style-page-layout-properties?,
4401   style-header-style?,
4402   style-footer-style?
4403 style-page-layout-attlist =
4404   attribute style:name { styleName }
4405   & attribute style:page-usage {
4406       "all" | "left" | "right" | "mirrored"
4407     }?
4408 style-header-style =
4409   element style:header-style { style-header-footer-properties? }
4410 style-footer-style =
4411   element style:footer-style { style-header-footer-properties? }
4412 style-default-page-layout =
4413   element style:default-page-layout { style-page-layout-content }
4414 style-master-page =
4415   element style:master-page {
4416     style-master-page-attlist,
4417     (style-header, style-header-left?)?,
4418     (style-footer, style-footer-left?)?,
4419     draw-layer-set?,
4420     office-forms?,
4421     shape*,
4422     animation-element?,
4423     presentation-notes?
4424   }
4425 style-master-page-attlist =
4426   attribute style:name { styleName }
4427   & attribute style:display-name { \string }?
4428   & attribute style:page-layout-name { styleNameRef }
4429   & attribute draw:style-name { styleNameRef }?
4430   & attribute style:next-style-name { styleNameRef }?
4431 style-header =
4432   element style:header {
4433     common-style-header-footer-attlist, header-footer-content
4434   }
4435 style-footer =
4436   element style:footer {
4437     common-style-header-footer-attlist, header-footer-content
4438   }
4439 style-header-left =
4440   element style:header-left {
4441     common-style-header-footer-attlist, header-footer-content
4442   }
4443 style-footer-left =
4444   element style:footer-left {
4445     common-style-header-footer-attlist, header-footer-content
4446   }
4447 header-footer-content =
4448   (text-tracked-changes,
4449    text-decls,
4450    (text-h
4451     | text-p
4452     | text-list
4453     | table-table
4454     | text-section
4455     | text-table-of-content
4456     | text-illustration-index
4457     | text-table-index
4458     | text-object-index
4459     | text-user-index
4460     | text-alphabetical-index
4461     | text-bibliography
4462     | text-index-title
4463     | change-marks)*)
4464   | (style-region-left?, style-region-center?, style-region-right?)
4465 common-style-header-footer-attlist =
4466   attribute style:display { boolean }?
4467 style-region-left = element style:region-left { region-content }
4468 style-region-center = element style:region-center { region-content }
4469 style-region-right = element style:region-right { region-content }
4470 region-content = text-p*
4471 presentation-notes =
4472   element presentation:notes {
4473     common-presentation-header-footer-attlist,
4474     presentation-notes-attlist,
4475     office-forms,
4476     shape*
4477   }
4478 presentation-notes-attlist =
4479   attribute style:page-layout-name { styleNameRef }?
4480   & attribute draw:style-name { styleNameRef }?
4481 table-table-template =
4482   element table:table-template {
4483     table-table-template-attlist,
4484     table-first-row?,
4485     table-last-row?,
4486     table-first-column?,
4487     table-last-column?,
4488     table-body,
4489     table-even-rows?,
4490     table-odd-rows?,
4491     table-even-columns?,
4492     table-odd-columns?,
4493     table-background?
4494   }
4495 table-table-template-attlist =
4496   attribute table:name { \string }
4497   & attribute table:first-row-start-column { rowOrCol }
4498   & attribute table:first-row-end-column { rowOrCol }
4499   & attribute table:last-row-start-column { rowOrCol }
4500   & attribute table:last-row-end-column { rowOrCol }
4501 rowOrCol = "row" | "column"
4502 table-first-row =
4503   element table:first-row { common-table-template-attlist, empty }
4504 table-last-row =
4505   element table:last-row { common-table-template-attlist, empty }
4506 table-first-column =
4507   element table:first-column { common-table-template-attlist, empty }
4508 table-last-column =
4509   element table:last-column { common-table-template-attlist, empty }
4510 table-body = element table:body { common-table-template-attlist, empty }
4511 table-even-rows =
4512   element table:even-rows { common-table-template-attlist, empty }
4513 table-odd-rows =
4514   element table:odd-rows { common-table-template-attlist, empty }
4515 table-even-columns =
4516   element table:even-columns { common-table-template-attlist, empty }
4517 table-odd-columns =
4518   element table:odd-columns { common-table-template-attlist, empty }
4519 common-table-template-attlist =
4520   attribute table:style-name { styleNameRef },
4521   attribute table:paragraph-style-name { styleNameRef }?
4522 table-background =
4523   element table:background { table-background-attlist, empty }
4524 table-background-attlist = attribute table:style-name { styleNameRef }
4525 style-font-face =
4526   element style:font-face {
4527     style-font-face-attlist, svg-font-face-src?, svg-definition-src?
4528   }
4529 style-font-face-attlist =
4530   attribute svg:font-family { \string }?
4531   & attribute svg:font-style { fontStyle }?
4532   & attribute svg:font-variant { fontVariant }?
4533   & attribute svg:font-weight { fontWeight }?
4534   & attribute svg:font-stretch {
4535       "normal"
4536       | "ultra-condensed"
4537       | "extra-condensed"
4538       | "condensed"
4539       | "semi-condensed"
4540       | "semi-expanded"
4541       | "expanded"
4542       | "extra-expanded"
4543       | "ultra-expanded"
4544     }?
4545   & attribute svg:font-size { positiveLength }?
4546   & attribute svg:unicode-range { \string }?
4547   & attribute svg:units-per-em { integer }?
4548   & attribute svg:panose-1 { \string }?
4549   & attribute svg:stemv { integer }?
4550   & attribute svg:stemh { integer }?
4551   & attribute svg:slope { integer }?
4552   & attribute svg:cap-height { integer }?
4553   & attribute svg:x-height { integer }?
4554   & attribute svg:accent-height { integer }?
4555   & attribute svg:ascent { integer }?
4556   & attribute svg:descent { integer }?
4557   & attribute svg:widths { \string }?
4558   & attribute svg:bbox { \string }?
4559   & attribute svg:ideographic { integer }?
4560   & attribute svg:alphabetic { integer }?
4561   & attribute svg:mathematical { integer }?
4562   & attribute svg:hanging { integer }?
4563   & attribute svg:v-ideographic { integer }?
4564   & attribute svg:v-alphabetic { integer }?
4565   & attribute svg:v-mathematical { integer }?
4566   & attribute svg:v-hanging { integer }?
4567   & attribute svg:underline-position { integer }?
4568   & attribute svg:underline-thickness { integer }?
4569   & attribute svg:strikethrough-position { integer }?
4570   & attribute svg:strikethrough-thickness { integer }?
4571   & attribute svg:overline-position { integer }?
4572   & attribute svg:overline-thickness { integer }?
4573   & attribute style:name { \string }
4574   & attribute style:font-adornments { \string }?
4575   & attribute style:font-family-generic { fontFamilyGeneric }?
4576   & attribute style:font-pitch { fontPitch }?
4577   & attribute style:font-charset { textEncoding }?
4578 svg-font-face-src =
4579   element svg:font-face-src {
4580     (svg-font-face-uri | svg-font-face-name)+
4581   }
4582 svg-font-face-uri =
4583   element svg:font-face-uri {
4584     common-svg-font-face-xlink-attlist, svg-font-face-format*
4585   }
4586 svg-font-face-format =
4587   element svg:font-face-format {
4588     attribute svg:string { \string }?,
4589     empty
4590   }
4591 svg-font-face-name =
4592   element svg:font-face-name {
4593     attribute svg:name { \string }?,
4594     empty
4595   }
4596 svg-definition-src =
4597   element svg:definition-src {
4598     common-svg-font-face-xlink-attlist, empty
4599   }
4600 common-svg-font-face-xlink-attlist =
4601   attribute xlink:type { "simple" },
4602   attribute xlink:href { anyIRI },
4603   attribute xlink:actuate { "onRequest" }?
4604 number-number-style =
4605   element number:number-style {
4606     common-data-style-attlist,
4607     style-text-properties?,
4608     number-text?,
4609     (any-number, number-text?)?,
4610     style-map*
4611   }
4612 any-number = number-number | number-scientific-number | number-fraction
4613 number-number =
4614   element number:number {
4615     number-number-attlist,
4616     common-decimal-places-attlist,
4617     common-number-attlist,
4618     number-embedded-text*
4619   }
4620 number-number-attlist =
4621   attribute number:decimal-replacement { \string }?
4622   & attribute number:display-factor { double }?
4623 number-embedded-text =
4624   element number:embedded-text { number-embedded-text-attlist, text }
4625 number-embedded-text-attlist = attribute number:position { integer }
4626 number-scientific-number =
4627   element number:scientific-number {
4628     number-scientific-number-attlist,
4629     common-decimal-places-attlist,
4630     common-number-attlist,
4631     empty
4632   }
4633 number-scientific-number-attlist =
4634   attribute number:min-exponent-digits { integer }?
4635 number-fraction =
4636   element number:fraction {
4637     number-fraction-attlist, common-number-attlist, empty
4638   }
4639 number-fraction-attlist =
4640   attribute number:min-numerator-digits { integer }?
4641   & attribute number:min-denominator-digits { integer }?
4642   & attribute number:denominator-value { integer }?
4643 number-currency-style =
4644   element number:currency-style {
4645     common-data-style-attlist,
4646     common-auto-reorder-attlist,
4647     style-text-properties?,
4648     number-text?,
4649     ((number-and-text, currency-symbol-and-text?)
4650      | (currency-symbol-and-text, number-and-text?))?,
4651     style-map*
4652   }
4653 currency-symbol-and-text = number-currency-symbol, number-text?
4654 number-and-text = number-number, number-text?
4655 number-currency-symbol =
4656   element number:currency-symbol {
4657     number-currency-symbol-attlist, text
4658   }
4659 number-currency-symbol-attlist =
4660   attribute number:language { languageCode }?,
4661   attribute number:country { countryCode }?,
4662   attribute number:script { scriptCode }?,
4663   attribute number:rfc-language-tag { language }?
4664 number-percentage-style =
4665   element number:percentage-style {
4666     common-data-style-attlist,
4667     style-text-properties?,
4668     number-text?,
4669     number-and-text?,
4670     style-map*
4671   }
4672 number-date-style =
4673   element number:date-style {
4674     common-data-style-attlist,
4675     common-auto-reorder-attlist,
4676     common-format-source-attlist,
4677     style-text-properties?,
4678     number-text?,
4679     (any-date, number-text?)+,
4680     style-map*
4681   }
4682 any-date =
4683   number-day
4684   | number-month
4685   | number-year
4686   | number-era
4687   | number-day-of-week
4688   | number-week-of-year
4689   | number-quarter
4690   | number-hours
4691   | number-am-pm
4692   | number-minutes
4693   | number-seconds
4694 number-day =
4695   element number:day {
4696     number-day-attlist, common-calendar-attlist, empty
4697   }
4698 number-day-attlist = attribute number:style { "short" | "long" }?
4699 number-month =
4700   element number:month {
4701     number-month-attlist, common-calendar-attlist, empty
4702   }
4703 number-month-attlist =
4704   attribute number:textual { boolean }?
4705   & attribute number:possessive-form { boolean }?
4706   & attribute number:style { "short" | "long" }?
4707 number-year =
4708   element number:year {
4709     number-year-attlist, common-calendar-attlist, empty
4710   }
4711 number-year-attlist = attribute number:style { "short" | "long" }?
4712 number-era =
4713   element number:era {
4714     number-era-attlist, common-calendar-attlist, empty
4715   }
4716 number-era-attlist = attribute number:style { "short" | "long" }?
4717 number-day-of-week =
4718   element number:day-of-week {
4719     number-day-of-week-attlist, common-calendar-attlist, empty
4720   }
4721 number-day-of-week-attlist =
4722   attribute number:style { "short" | "long" }?
4723 number-week-of-year =
4724   element number:week-of-year { common-calendar-attlist, empty }
4725 number-quarter =
4726   element number:quarter {
4727     number-quarter-attlist, common-calendar-attlist, empty
4728   }
4729 number-quarter-attlist = attribute number:style { "short" | "long" }?
4730 number-time-style =
4731   element number:time-style {
4732     number-time-style-attlist,
4733     common-data-style-attlist,
4734     common-format-source-attlist,
4735     style-text-properties?,
4736     number-text?,
4737     (any-time, number-text?)+,
4738     style-map*
4739   }
4740 any-time = number-hours | number-am-pm | number-minutes | number-seconds
4741 number-time-style-attlist =
4742   attribute number:truncate-on-overflow { boolean }?
4743 number-hours = element number:hours { number-hours-attlist, empty }
4744 number-hours-attlist = attribute number:style { "short" | "long" }?
4745 number-minutes =
4746   element number:minutes { number-minutes-attlist, empty }
4747 number-minutes-attlist = attribute number:style { "short" | "long" }?
4748 number-seconds =
4749   element number:seconds { number-seconds-attlist, empty }
4750 number-seconds-attlist =
4751   attribute number:style { "short" | "long" }?
4752   & attribute number:decimal-places { integer }?
4753 number-am-pm = element number:am-pm { empty }
4754 number-boolean-style =
4755   element number:boolean-style {
4756     common-data-style-attlist,
4757     style-text-properties?,
4758     number-text?,
4759     (number-boolean, number-text?)?,
4760     style-map*
4761   }
4762 number-boolean = element number:boolean { empty }
4763 number-text-style =
4764   element number:text-style {
4765     common-data-style-attlist,
4766     style-text-properties?,
4767     number-text?,
4768     (number-text-content, number-text?)*,
4769     style-map*
4770   }
4771 number-text = element number:text { text }
4772 number-text-content = element number:text-content { empty }
4773 common-data-style-attlist =
4774   attribute style:name { styleName }
4775   & attribute style:display-name { \string }?
4776   & attribute number:language { languageCode }?
4777   & attribute number:country { countryCode }?
4778   & attribute number:script { scriptCode }?
4779   & attribute number:rfc-language-tag { language }?
4780   & attribute number:title { \string }?
4781   & attribute style:volatile { boolean }?
4782   & attribute number:transliteration-format { \string }?
4783   & attribute number:transliteration-language { countryCode }?
4784   & attribute number:transliteration-country { countryCode }?
4785   & attribute number:transliteration-style {
4786       "short" | "medium" | "long"
4787     }?
4788 common-auto-reorder-attlist =
4789   attribute number:automatic-order { boolean }?
4790 common-format-source-attlist =
4791   attribute number:format-source { "fixed" | "language" }?
4792 common-decimal-places-attlist =
4793   attribute number:decimal-places { integer }?
4794 common-number-attlist =
4795   attribute number:min-integer-digits { integer }?
4796   & attribute number:grouping { boolean }?
4797 common-calendar-attlist =
4798   attribute number:calendar {
4799     "gregorian"
4800     | "gengou"
4801     | "ROC"
4802     | "hanja_yoil"
4803     | "hanja"
4804     | "hijri"
4805     | "jewish"
4806     | "buddhist"
4807     | \string
4808   }?
4809 style-style-content =
4810   (attribute style:family { "text" },
4811    style-text-properties?)
4812   | (attribute style:family { "paragraph" },
4813      style-paragraph-properties?,
4814      style-text-properties?)
4815   | (attribute style:family { "section" },
4816      style-section-properties?)
4817   | (attribute style:family { "ruby" },
4818      style-ruby-properties?)
4819   | (attribute style:family { "table" },
4820      style-table-properties?)
4821   | (attribute style:family { "table-column" },
4822      style-table-column-properties?)
4823   | (attribute style:family { "table-row" },
4824      style-table-row-properties?)
4825   | (attribute style:family { "table-cell" },
4826      style-table-cell-properties?,
4827      style-paragraph-properties?,
4828      style-text-properties?)
4829   | (attribute style:family { "graphic" | "presentation" },
4830      style-graphic-properties?,
4831      style-paragraph-properties?,
4832      style-text-properties?)
4833   | (attribute style:family { "drawing-page" },
4834      style-drawing-page-properties?)
4835   | (attribute style:family { "chart" },
4836      style-chart-properties?,
4837      style-graphic-properties?,
4838      style-paragraph-properties?,
4839      style-text-properties?)
4840 text-linenumbering-configuration =
4841   element text:linenumbering-configuration {
4842     text-linenumbering-configuration-attlist,
4843     text-linenumbering-separator?
4844   }
4845 text-linenumbering-configuration-attlist =
4846   attribute text:number-lines { boolean }?
4847   & common-num-format-attlist?
4848   & attribute text:style-name { styleNameRef }?
4849   & attribute text:increment { nonNegativeInteger }?
4850   & attribute text:number-position {
4851       "left" | "right" | "inner" | "outer"
4852     }?
4853   & attribute text:offset { nonNegativeLength }?
4854   & attribute text:count-empty-lines { boolean }?
4855   & attribute text:count-in-text-boxes { boolean }?
4856   & attribute text:restart-on-page { boolean }?
4857 text-linenumbering-separator =
4858   element text:linenumbering-separator {
4859     attribute text:increment { nonNegativeInteger }?,
4860     text
4861   }
4862 text-notes-configuration =
4863   element text:notes-configuration { text-notes-configuration-content }
4864 text-notes-configuration-content =
4865   text-note-class
4866   & attribute text:citation-style-name { styleNameRef }?
4867   & attribute text:citation-body-style-name { styleNameRef }?
4868   & attribute text:default-style-name { styleNameRef }?
4869   & attribute text:master-page-name { styleNameRef }?
4870   & attribute text:start-value { nonNegativeInteger }?
4871   & common-num-format-prefix-suffix-attlist
4872   & common-num-format-attlist?
4873   & attribute text:start-numbering-at {
4874       "document" | "chapter" | "page"
4875     }?
4876   & attribute text:footnotes-position {
4877       "text" | "page" | "section" | "document"
4878     }?
4879   & element text:note-continuation-notice-forward { text }?
4880   & element text:note-continuation-notice-backward { text }?
4881 text-bibliography-configuration =
4882   element text:bibliography-configuration {
4883     text-bibliography-configuration-attlist, text-sort-key*
4884   }
4885 text-bibliography-configuration-attlist =
4886   attribute text:prefix { \string }?
4887   & attribute text:suffix { \string }?
4888   & attribute text:numbered-entries { boolean }?
4889   & attribute text:sort-by-position { boolean }?
4890   & attribute fo:language { languageCode }?
4891   & attribute fo:country { countryCode }?
4892   & attribute fo:script { scriptCode }?
4893   & attribute style:rfc-language-tag { language }?
4894   & attribute text:sort-algorithm { \string }?
4895 text-sort-key = element text:sort-key { text-sort-key-attlist, empty }
4896 text-sort-key-attlist =
4897   attribute text:key {
4898     "address"
4899     | "annote"
4900     | "author"
4901     | "bibliography-type"
4902     | "booktitle"
4903     | "chapter"
4904     | "custom1"
4905     | "custom2"
4906     | "custom3"
4907     | "custom4"
4908     | "custom5"
4909     | "edition"
4910     | "editor"
4911     | "howpublished"
4912     | "identifier"
4913     | "institution"
4914     | "isbn"
4915     | "issn"
4916     | "journal"
4917     | "month"
4918     | "note"
4919     | "number"
4920     | "organizations"
4921     | "pages"
4922     | "publisher"
4923     | "report-type"
4924     | "school"
4925     | "series"
4926     | "title"
4927     | "url"
4928     | "volume"
4929     | "year"
4930   },
4931   attribute text:sort-ascending { boolean }?
4932 text-list-style =
4933   element text:list-style {
4934     text-list-style-attr, text-list-style-content*
4935   }
4936 text-list-style-attr =
4937   attribute style:name { styleName }
4938   & attribute style:display-name { \string }?
4939   & attribute text:consecutive-numbering { boolean }?
4940 text-list-style-content =
4941   element text:list-level-style-number {
4942     text-list-level-style-attr,
4943     text-list-level-style-number-attr,
4944     style-list-level-properties?,
4945     style-text-properties?
4946   }
4947   | element text:list-level-style-bullet {
4948       text-list-level-style-attr,
4949       text-list-level-style-bullet-attr,
4950       style-list-level-properties?,
4951       style-text-properties?
4952     }
4953   | element text:list-level-style-image {
4954       text-list-level-style-attr,
4955       text-list-level-style-image-attr,
4956       style-list-level-properties?
4957     }
4958 text-list-level-style-number-attr =
4959   attribute text:style-name { styleNameRef }?
4960   & common-num-format-attlist
4961   & common-num-format-prefix-suffix-attlist
4962   & attribute text:display-levels { positiveInteger }?
4963   & attribute text:start-value { positiveInteger }?
4964 text-list-level-style-bullet-attr =
4965   attribute text:style-name { styleNameRef }?
4966   & attribute text:bullet-char { character }
4967   & common-num-format-prefix-suffix-attlist
4968   & attribute text:bullet-relative-size { percent }?
4969 text-list-level-style-image-attr =
4970   common-draw-data-attlist | office-binary-data
4971 text-list-level-style-attr = attribute text:level { positiveInteger }
4972 text-outline-style =
4973   element text:outline-style {
4974     text-outline-style-attr, text-outline-level-style+
4975   }
4976 text-outline-style-attr = attribute style:name { styleName }
4977 text-outline-level-style =
4978   element text:outline-level-style {
4979     text-outline-level-style-attlist,
4980     style-list-level-properties?,
4981     style-text-properties?
4982   }
4983 text-outline-level-style-attlist =
4984   attribute text:level { positiveInteger }
4985   & attribute text:style-name { styleNameRef }?
4986   & common-num-format-attlist
4987   & common-num-format-prefix-suffix-attlist
4988   & attribute text:display-levels { positiveInteger }?
4989   & attribute text:start-value { positiveInteger }?
4990 style-graphic-properties =
4991   element style:graphic-properties {
4992     style-graphic-properties-content-strict
4993   }
4994 style-graphic-properties-content-strict =
4995   style-graphic-properties-attlist,
4996   style-graphic-fill-properties-attlist,
4997   style-graphic-properties-elements
4998 style-drawing-page-properties =
4999   element style:drawing-page-properties {
5000     style-drawing-page-properties-content-strict
5001   }
5002 style-drawing-page-properties-content-strict =
5003   style-graphic-fill-properties-attlist,
5004   style-drawing-page-properties-attlist,
5005   style-drawing-page-properties-elements
5006 draw-gradient =
5007   element draw:gradient {
5008     common-draw-gradient-attlist, draw-gradient-attlist, empty
5009   }
5010 common-draw-gradient-attlist =
5011   attribute draw:name { styleName }?
5012   & attribute draw:display-name { \string }?
5013   & attribute draw:style { gradient-style }
5014   & attribute draw:cx { percent }?
5015   & attribute draw:cy { percent }?
5016   & attribute draw:angle { angle }?
5017   & attribute draw:border { percent }?
5018 gradient-style =
5019   "linear" | "axial" | "radial" | "ellipsoid" | "square" | "rectangular"
5020 draw-gradient-attlist =
5021   attribute draw:start-color { color }?
5022   & attribute draw:end-color { color }?
5023   & attribute draw:start-intensity { zeroToHundredPercent }?
5024   & attribute draw:end-intensity { zeroToHundredPercent }?
5025 svg-linearGradient =
5026   element svg:linearGradient {
5027     common-svg-gradient-attlist,
5028     attribute svg:x1 { coordinate | percent }?,
5029     attribute svg:y1 { coordinate | percent }?,
5030     attribute svg:x2 { coordinate | percent }?,
5031     attribute svg:y2 { coordinate | percent }?,
5032     svg-stop*
5033   }
5034 svg-radialGradient =
5035   element svg:radialGradient {
5036     common-svg-gradient-attlist,
5037     attribute svg:cx { coordinate | percent }?,
5038     attribute svg:cy { coordinate | percent }?,
5039     attribute svg:r { coordinate | percent }?,
5040     attribute svg:fx { coordinate | percent }?,
5041     attribute svg:fy { coordinate | percent }?,
5042     svg-stop*
5043   }
5044 svg-stop =
5045   element svg:stop {
5046     attribute svg:offset { double | percent },
5047     attribute svg:stop-color { color }?,
5048     attribute svg:stop-opacity { double }?
5049   }
5050 common-svg-gradient-attlist =
5051   attribute svg:gradientUnits { "objectBoundingBox" }?
5052   & attribute svg:gradientTransform { \string }?
5053   & attribute svg:spreadMethod { "pad" | "reflect" | "repeat" }?
5054   & attribute draw:name { styleName }
5055   & attribute draw:display-name { \string }?
5056 draw-hatch = element draw:hatch { draw-hatch-attlist, empty }
5057 draw-hatch-attlist =
5058   attribute draw:name { styleName }
5059   & attribute draw:display-name { \string }?
5060   & attribute draw:style { "single" | "double" | "triple" }
5061   & attribute draw:color { color }?
5062   & attribute draw:distance { length }?
5063   & attribute draw:rotation { angle }?
5064 draw-fill-image =
5065   element draw:fill-image {
5066     draw-fill-image-attlist,
5067     attribute xlink:type { "simple" },
5068     attribute xlink:href { anyIRI },
5069     attribute xlink:show { "embed" }?,
5070     attribute xlink:actuate { "onLoad" }?,
5071     empty
5072   }
5073 draw-fill-image-attlist =
5074   attribute draw:name { styleName }
5075   & attribute draw:display-name { \string }?
5076   & attribute svg:width { length }?
5077   & attribute svg:height { length }?
5078 draw-opacity =
5079   element draw:opacity {
5080     common-draw-gradient-attlist, draw-opacity-attlist, empty
5081   }
5082 draw-opacity-attlist =
5083   attribute draw:start { zeroToHundredPercent }?,
5084   attribute draw:end { zeroToHundredPercent }?
5085 draw-marker =
5086   element draw:marker {
5087     draw-marker-attlist,
5088     common-draw-viewbox-attlist,
5089     common-draw-path-data-attlist,
5090     empty
5091   }
5092 draw-marker-attlist =
5093   attribute draw:name { styleName }
5094   & attribute draw:display-name { \string }?
5095 draw-stroke-dash =
5096   element draw:stroke-dash { draw-stroke-dash-attlist, empty }
5097 draw-stroke-dash-attlist =
5098   attribute draw:name { styleName }
5099   & attribute draw:display-name { \string }?
5100   & attribute draw:style { "rect" | "round" }?
5101   & attribute draw:dots1 { integer }?
5102   & attribute draw:dots1-length { length | percent }?
5103   & attribute draw:dots2 { integer }?
5104   & attribute draw:dots2-length { length | percent }?
5105   & attribute draw:distance { length | percent }?
5106 style-presentation-page-layout =
5107   element style:presentation-page-layout {
5108     attribute style:name { styleName },
5109     attribute style:display-name { \string }?,
5110     presentation-placeholder*
5111   }
5112 presentation-placeholder =
5113   element presentation:placeholder {
5114     attribute presentation:object { presentation-classes },
5115     attribute svg:x { coordinate | percent },
5116     attribute svg:y { coordinate | percent },
5117     attribute svg:width { length | percent },
5118     attribute svg:height { length | percent },
5119     empty
5120   }
5121 style-page-layout-properties =
5122   element style:page-layout-properties {
5123     style-page-layout-properties-content-strict
5124   }
5125 style-page-layout-properties-content-strict =
5126   style-page-layout-properties-attlist,
5127   style-page-layout-properties-elements
5128 style-page-layout-properties-attlist =
5129   attribute fo:page-width { length }?
5130   & attribute fo:page-height { length }?
5131   & common-num-format-attlist?
5132   & common-num-format-prefix-suffix-attlist
5133   & attribute style:paper-tray-name { "default" | \string }?
5134   & attribute style:print-orientation { "portrait" | "landscape" }?
5135   & common-horizontal-margin-attlist
5136   & common-vertical-margin-attlist
5137   & common-margin-attlist
5138   & common-border-attlist
5139   & common-border-line-width-attlist
5140   & common-padding-attlist
5141   & common-shadow-attlist
5142   & common-background-color-attlist
5143   & attribute style:register-truth-ref-style-name { styleNameRef }?
5144   & attribute style:print {
5145       list {
5146         ("headers"
5147          | "grid"
5148          | "annotations"
5149          | "objects"
5150          | "charts"
5151          | "drawings"
5152          | "formulas"
5153          | "zero-values")*
5154       }
5155     }?
5156   & attribute style:print-page-order { "ttb" | "ltr" }?
5157   & attribute style:first-page-number { positiveInteger | "continue" }?
5158   & attribute style:scale-to { percent }?
5159   & attribute style:scale-to-pages { positiveInteger }?
5160   & attribute style:table-centering {
5161       "horizontal" | "vertical" | "both" | "none"
5162     }?
5163   & attribute style:footnote-max-height { length }?
5164   & common-writing-mode-attlist
5165   & attribute style:layout-grid-mode { "none" | "line" | "both" }?
5166   & attribute style:layout-grid-standard-mode { boolean }?
5167   & attribute style:layout-grid-base-height { length }?
5168   & attribute style:layout-grid-ruby-height { length }?
5169   & attribute style:layout-grid-lines { positiveInteger }?
5170   & attribute style:layout-grid-base-width { length }?
5171   & attribute style:layout-grid-color { color }?
5172   & attribute style:layout-grid-ruby-below { boolean }?
5173   & attribute style:layout-grid-print { boolean }?
5174   & attribute style:layout-grid-display { boolean }?
5175   & attribute style:layout-grid-snap-to { boolean }?
5176 style-page-layout-properties-elements =
5177   style-background-image & style-columns & style-footnote-sep
5178 style-footnote-sep =
5179   element style:footnote-sep { style-footnote-sep-attlist, empty }?
5180 style-footnote-sep-attlist =
5181   attribute style:width { length }?,
5182   attribute style:rel-width { percent }?,
5183   attribute style:color { color }?,
5184   attribute style:line-style { lineStyle }?,
5185   attribute style:adjustment { "left" | "center" | "right" }?,
5186   attribute style:distance-before-sep { length }?,
5187   attribute style:distance-after-sep { length }?
5188 style-header-footer-properties =
5189   element style:header-footer-properties {
5190     style-header-footer-properties-content-strict
5191   }
5192 style-header-footer-properties-content-strict =
5193   style-header-footer-properties-attlist,
5194   style-header-footer-properties-elements
5195 style-header-footer-properties-attlist =
5196   attribute svg:height { length }?
5197   & attribute fo:min-height { length }?
5198   & common-horizontal-margin-attlist
5199   & common-vertical-margin-attlist
5200   & common-margin-attlist
5201   & common-border-attlist
5202   & common-border-line-width-attlist
5203   & common-padding-attlist
5204   & common-background-color-attlist
5205   & common-shadow-attlist
5206   & attribute style:dynamic-spacing { boolean }?
5207 style-header-footer-properties-elements = style-background-image
5208 style-text-properties =
5209   element style:text-properties { style-text-properties-content-strict }
5210 style-text-properties-content-strict =
5211   style-text-properties-attlist, style-text-properties-elements
5212 style-text-properties-elements = empty
5213 style-text-properties-attlist =
5214   attribute fo:font-variant { fontVariant }?
5215   & attribute fo:text-transform {
5216       "none" | "lowercase" | "uppercase" | "capitalize"
5217     }?
5218   & attribute fo:color { color }?
5219   & attribute style:use-window-font-color { boolean }?
5220   & attribute style:text-outline { boolean }?
5221   & attribute style:text-line-through-type { lineType }?
5222   & attribute style:text-line-through-style { lineStyle }?
5223   & attribute style:text-line-through-width { lineWidth }?
5224   & attribute style:text-line-through-color { "font-color" | color }?
5225   & attribute style:text-line-through-text { \string }?
5226   & attribute style:text-line-through-text-style { styleNameRef }?
5227   & attribute style:text-position {
5228       list { (percent | "super" | "sub"), percent? }
5229     }?
5230   & attribute style:font-name { \string }?
5231   & attribute style:font-name-asian { \string }?
5232   & attribute style:font-name-complex { \string }?
5233   & attribute fo:font-family { \string }?
5234   & attribute style:font-family-asian { \string }?
5235   & attribute style:font-family-complex { \string }?
5236   & attribute style:font-family-generic { fontFamilyGeneric }?
5237   & attribute style:font-family-generic-asian { fontFamilyGeneric }?
5238   & attribute style:font-family-generic-complex { fontFamilyGeneric }?
5239   & attribute style:font-style-name { \string }?
5240   & attribute style:font-style-name-asian { \string }?
5241   & attribute style:font-style-name-complex { \string }?
5242   & attribute style:font-pitch { fontPitch }?
5243   & attribute style:font-pitch-asian { fontPitch }?
5244   & attribute style:font-pitch-complex { fontPitch }?
5245   & attribute style:font-charset { textEncoding }?
5246   & attribute style:font-charset-asian { textEncoding }?
5247   & attribute style:font-charset-complex { textEncoding }?
5248   & attribute fo:font-size { positiveLength | percent }?
5249   & attribute style:font-size-asian { positiveLength | percent }?
5250   & attribute style:font-size-complex { positiveLength | percent }?
5251   & attribute style:font-size-rel { length }?
5252   & attribute style:font-size-rel-asian { length }?
5253   & attribute style:font-size-rel-complex { length }?
5254   & attribute style:script-type {
5255       "latin" | "asian" | "complex" | "ignore"
5256     }?
5257   & attribute fo:letter-spacing { length | "normal" }?
5258   & attribute fo:language { languageCode }?
5259   & attribute style:language-asian { languageCode }?
5260   & attribute style:language-complex { languageCode }?
5261   & attribute fo:country { countryCode }?
5262   & attribute style:country-asian { countryCode }?
5263   & attribute style:country-complex { countryCode }?
5264   & attribute fo:script { scriptCode }?
5265   & attribute style:script-asian { scriptCode }?
5266   & attribute style:script-complex { scriptCode }?
5267   & attribute style:rfc-language-tag { language }?
5268   & attribute style:rfc-language-tag-asian { language }?
5269   & attribute style:rfc-language-tag-complex { language }?
5270   & attribute fo:font-style { fontStyle }?
5271   & attribute style:font-style-asian { fontStyle }?
5272   & attribute style:font-style-complex { fontStyle }?
5273   & attribute style:font-relief { "none" | "embossed" | "engraved" }?
5274   & attribute fo:text-shadow { shadowType }?
5275   & attribute style:text-underline-type { lineType }?
5276   & attribute style:text-underline-style { lineStyle }?
5277   & attribute style:text-underline-width { lineWidth }?
5278   & attribute style:text-underline-color { "font-color" | color }?
5279   & attribute style:text-overline-type { lineType }?
5280   & attribute style:text-overline-style { lineStyle }?
5281   & attribute style:text-overline-width { lineWidth }?
5282   & attribute style:text-overline-color { "font-color" | color }?
5283   & attribute style:text-overline-mode { lineMode }?
5284   & attribute fo:font-weight { fontWeight }?
5285   & attribute style:font-weight-asian { fontWeight }?
5286   & attribute style:font-weight-complex { fontWeight }?
5287   & attribute style:text-underline-mode { lineMode }?
5288   & attribute style:text-line-through-mode { lineMode }?
5289   & attribute style:letter-kerning { boolean }?
5290   & attribute style:text-blinking { boolean }?
5291   & common-background-color-attlist
5292   & attribute style:text-combine { "none" | "letters" | "lines" }?
5293   & attribute style:text-combine-start-char { character }?
5294   & attribute style:text-combine-end-char { character }?
5295   & attribute style:text-emphasize {
5296       "none"
5297       | list {
5298           ("none" | "accent" | "dot" | "circle" | "disc"),
5299           ("above" | "below")
5300         }
5301     }?
5302   & attribute style:text-scale { percent }?
5303   & attribute style:text-rotation-angle { angle }?
5304   & attribute style:text-rotation-scale { "fixed" | "line-height" }?
5305   & attribute fo:hyphenate { boolean }?
5306   & attribute fo:hyphenation-remain-char-count { positiveInteger }?
5307   & attribute fo:hyphenation-push-char-count { positiveInteger }?
5308   & (attribute text:display { "true" }
5309      | attribute text:display { "none" }
5310      | (attribute text:display { "condition" },
5311         attribute text:condition { "none" })
5312      | empty)
5313 fontVariant = "normal" | "small-caps"
5314 fontFamilyGeneric =
5315   "roman" | "swiss" | "modern" | "decorative" | "script" | "system"
5316 fontPitch = "fixed" | "variable"
5317 textEncoding = xsd:string { pattern = "[A-Za-z][A-Za-z0-9._\-]*" }
5318 fontStyle = "normal" | "italic" | "oblique"
5319 shadowType = "none" | \string
5320 lineType = "none" | "single" | "double"
5321 lineStyle =
5322   "none"
5323   | "solid"
5324   | "dotted"
5325   | "dash"
5326   | "long-dash"
5327   | "dot-dash"
5328   | "dot-dot-dash"
5329   | "wave"
5330 lineWidth =
5331   "auto"
5332   | "normal"
5333   | "bold"
5334   | "thin"
5335   | "medium"
5336   | "thick"
5337   | positiveInteger
5338   | percent
5339   | positiveLength
5340 fontWeight =
5341   "normal"
5342   | "bold"
5343   | "100"
5344   | "200"
5345   | "300"
5346   | "400"
5347   | "500"
5348   | "600"
5349   | "700"
5350   | "800"
5351   | "900"
5352 lineMode = "continuous" | "skip-white-space"
5353 style-paragraph-properties =
5354   element style:paragraph-properties {
5355     style-paragraph-properties-content-strict
5356   }
5357 style-paragraph-properties-content-strict =
5358   style-paragraph-properties-attlist,
5359   style-paragraph-properties-elements
5360 style-paragraph-properties-attlist =
5361   attribute fo:line-height { "normal" | nonNegativeLength | percent }?
5362   & attribute style:line-height-at-least { nonNegativeLength }?
5363   & attribute style:line-spacing { length }?
5364   & attribute style:font-independent-line-spacing { boolean }?
5365   & common-text-align
5366   & attribute fo:text-align-last { "start" | "center" | "justify" }?
5367   & attribute style:justify-single-word { boolean }?
5368   & attribute fo:keep-together { "auto" | "always" }?
5369   & attribute fo:widows { nonNegativeInteger }?
5370   & attribute fo:orphans { nonNegativeInteger }?
5371   & attribute style:tab-stop-distance { nonNegativeLength }?
5372   & attribute fo:hyphenation-keep { "auto" | "page" }?
5373   & attribute fo:hyphenation-ladder-count {
5374       "no-limit" | positiveInteger
5375     }?
5376   & attribute style:register-true { boolean }?
5377   & common-horizontal-margin-attlist
5378   & attribute fo:text-indent { length | percent }?
5379   & attribute style:auto-text-indent { boolean }?
5380   & common-vertical-margin-attlist
5381   & common-margin-attlist
5382   & common-break-attlist
5383   & common-background-color-attlist
5384   & common-border-attlist
5385   & common-border-line-width-attlist
5386   & attribute style:join-border { boolean }?
5387   & common-padding-attlist
5388   & common-shadow-attlist
5389   & common-keep-with-next-attlist
5390   & attribute text:number-lines { boolean }?
5391   & attribute text:line-number { nonNegativeInteger }?
5392   & attribute style:text-autospace { "none" | "ideograph-alpha" }?
5393   & attribute style:punctuation-wrap { "simple" | "hanging" }?
5394   & attribute style:line-break { "normal" | "strict" }?
5395   & attribute style:vertical-align {
5396       "top" | "middle" | "bottom" | "auto" | "baseline"
5397     }?
5398   & common-writing-mode-attlist
5399   & attribute style:writing-mode-automatic { boolean }?
5400   & attribute style:snap-to-layout-grid { boolean }?
5401   & common-page-number-attlist
5402   & common-background-transparency-attlist
5403 common-text-align =
5404   attribute fo:text-align {
5405     "start" | "end" | "left" | "right" | "center" | "justify"
5406   }?
5407 style-paragraph-properties-elements =
5408   style-tab-stops & style-drop-cap & style-background-image
5409 style-tab-stops = element style:tab-stops { style-tab-stop* }?
5410 style-tab-stop =
5411   element style:tab-stop { style-tab-stop-attlist, empty }
5412 style-tab-stop-attlist =
5413   attribute style:position { length }
5414   & (attribute style:type { "left" | "center" | "right" }?
5415      | (attribute style:type { "char" },
5416         style-tab-stop-char-attlist))
5417   & attribute style:leader-type { lineType }?
5418   & attribute style:leader-style { lineStyle }?
5419   & attribute style:leader-width { lineWidth }?
5420   & attribute style:leader-color { "font-color" | color }?
5421   & attribute style:leader-text { character }?
5422   & attribute style:leader-text-style { styleNameRef }?
5423 style-tab-stop-char-attlist = attribute style:char { character }
5424 style-drop-cap =
5425   element style:drop-cap { style-drop-cap-attlist, empty }?
5426 style-drop-cap-attlist =
5427   attribute style:length { "word" | positiveInteger }?
5428   & attribute style:lines { positiveInteger }?
5429   & attribute style:distance { length }?
5430   & attribute style:style-name { styleNameRef }?
5431 common-horizontal-margin-attlist =
5432   attribute fo:margin-left { length | percent }?,
5433   attribute fo:margin-right { length | percent }?
5434 common-vertical-margin-attlist =
5435   attribute fo:margin-top { nonNegativeLength | percent }?,
5436   attribute fo:margin-bottom { nonNegativeLength | percent }?
5437 common-margin-attlist =
5438   attribute fo:margin { nonNegativeLength | percent }?
5439 common-break-attlist =
5440   attribute fo:break-before { "auto" | "column" | "page" }?,
5441   attribute fo:break-after { "auto" | "column" | "page" }?
5442 common-background-color-attlist =
5443   attribute fo:background-color { "transparent" | color }?
5444 style-background-image =
5445   element style:background-image {
5446     style-background-image-attlist,
5447     (common-draw-data-attlist | office-binary-data | empty)
5448   }?
5449 style-background-image-attlist =
5450   attribute style:repeat { "no-repeat" | "repeat" | "stretch" }?
5451   & attribute style:position {
5452       "left"
5453       | "center"
5454       | "right"
5455       | "top"
5456       | "bottom"
5457       | list { horiBackPos, vertBackPos }
5458       | list { vertBackPos, horiBackPos }
5459     }?
5460   & attribute style:filter-name { \string }?
5461   & attribute draw:opacity { zeroToHundredPercent }?
5462 horiBackPos = "left" | "center" | "right"
5463 vertBackPos = "top" | "center" | "bottom"
5464 common-border-attlist =
5465   attribute fo:border { \string }?,
5466   attribute fo:border-top { \string }?,
5467   attribute fo:border-bottom { \string }?,
5468   attribute fo:border-left { \string }?,
5469   attribute fo:border-right { \string }?
5470 common-border-line-width-attlist =
5471   attribute style:border-line-width { borderWidths }?,
5472   attribute style:border-line-width-top { borderWidths }?,
5473   attribute style:border-line-width-bottom { borderWidths }?,
5474   attribute style:border-line-width-left { borderWidths }?,
5475   attribute style:border-line-width-right { borderWidths }?
5476 borderWidths = list { positiveLength, positiveLength, positiveLength }
5477 common-padding-attlist =
5478   attribute fo:padding { nonNegativeLength }?,
5479   attribute fo:padding-top { nonNegativeLength }?,
5480   attribute fo:padding-bottom { nonNegativeLength }?,
5481   attribute fo:padding-left { nonNegativeLength }?,
5482   attribute fo:padding-right { nonNegativeLength }?
5483 common-shadow-attlist = attribute style:shadow { shadowType }?
5484 common-keep-with-next-attlist =
5485   attribute fo:keep-with-next { "auto" | "always" }?
5486 common-writing-mode-attlist =
5487   attribute style:writing-mode {
5488     "lr-tb" | "rl-tb" | "tb-rl" | "tb-lr" | "lr" | "rl" | "tb" | "page"
5489   }?
5490 common-page-number-attlist =
5491   attribute style:page-number { positiveInteger | "auto" }?
5492 common-background-transparency-attlist =
5493   attribute style:background-transparency { zeroToHundredPercent }?
5494 style-ruby-properties =
5495   element style:ruby-properties { style-ruby-properties-content-strict }
5496 style-ruby-properties-content-strict =
5497   style-ruby-properties-attlist, style-ruby-properties-elements
5498 style-ruby-properties-elements = empty
5499 style-ruby-properties-attlist =
5500   attribute style:ruby-position { "above" | "below" }?
5501   & attribute style:ruby-align {
5502       "left"
5503       | "center"
5504       | "right"
5505       | "distribute-letter"
5506       | "distribute-space"
5507     }?
5508 style-section-properties =
5509   element style:section-properties {
5510     style-section-properties-content-strict
5511   }
5512 style-section-properties-content-strict =
5513   style-section-properties-attlist, style-section-properties-elements
5514 style-section-properties-attlist =
5515   common-background-color-attlist
5516   & common-horizontal-margin-attlist
5517   & attribute style:protect { boolean }?
5518   & common-editable-attlist
5519   & attribute text:dont-balance-text-columns { boolean }?
5520   & common-writing-mode-attlist
5521 style-section-properties-elements =
5522   style-background-image & style-columns & text-notes-configuration*
5523 style-columns =
5524   element style:columns {
5525     style-columns-attlist, style-column-sep?, style-column*
5526   }?
5527 style-columns-attlist =
5528   attribute fo:column-count { positiveInteger }
5529   & attribute fo:column-gap { length }?
5530 style-column = element style:column { style-column-attlist }
5531 style-column-attlist =
5532   attribute style:rel-width { relativeLength }
5533   & attribute fo:start-indent { length }?
5534   & attribute fo:end-indent { length }?
5535   & attribute fo:space-before { length }?
5536   & attribute fo:space-after { length }?
5537 style-column-sep = element style:column-sep { style-column-sep-attlist }
5538 style-column-sep-attlist =
5539   attribute style:style {
5540     "none" | "solid" | "dotted" | "dashed" | "dot-dashed"
5541   }?
5542   & attribute style:width { length }
5543   & attribute style:height { zeroToHundredPercent }?
5544   & attribute style:vertical-align { "top" | "middle" | "bottom" }?
5545   & attribute style:color { color }?
5546 style-table-properties =
5547   element style:table-properties {
5548     style-table-properties-content-strict
5549   }
5550 style-table-properties-content-strict =
5551   style-table-properties-attlist, style-table-properties-elements
5552 style-table-properties-attlist =
5553   attribute style:width { positiveLength }?
5554   & attribute style:rel-width { percent }?
5555   & attribute table:align { "left" | "center" | "right" | "margins" }?
5556   & common-horizontal-margin-attlist
5557   & common-vertical-margin-attlist
5558   & common-margin-attlist
5559   & common-page-number-attlist
5560   & common-break-attlist
5561   & common-background-color-attlist
5562   & common-shadow-attlist
5563   & common-keep-with-next-attlist
5564   & attribute style:may-break-between-rows { boolean }?
5565   & attribute table:border-model { "collapsing" | "separating" }?
5566   & common-writing-mode-attlist
5567   & attribute table:display { boolean }?
5568 style-table-properties-elements = style-background-image
5569 style-table-column-properties =
5570   element style:table-column-properties {
5571     style-table-column-properties-content-strict
5572   }
5573 style-table-column-properties-content-strict =
5574   style-table-column-properties-attlist,
5575   style-table-column-properties-elements
5576 style-table-column-properties-elements = empty
5577 style-table-column-properties-attlist =
5578   attribute style:column-width { positiveLength }?
5579   & attribute style:rel-column-width { relativeLength }?
5580   & attribute style:use-optimal-column-width { boolean }?
5581   & common-break-attlist
5582 style-table-row-properties =
5583   element style:table-row-properties {
5584     style-table-row-properties-content-strict
5585   }
5586 style-table-row-properties-content-strict =
5587   style-table-row-properties-attlist,
5588   style-table-row-properties-elements
5589 style-table-row-properties-attlist =
5590   attribute style:row-height { positiveLength }?
5591   & attribute style:min-row-height { nonNegativeLength }?
5592   & attribute style:use-optimal-row-height { boolean }?
5593   & common-background-color-attlist
5594   & common-break-attlist
5595   & attribute fo:keep-together { "auto" | "always" }?
5596 style-table-row-properties-elements = style-background-image
5597 style-table-cell-properties =
5598   element style:table-cell-properties {
5599     style-table-cell-properties-content-strict
5600   }
5601 style-table-cell-properties-content-strict =
5602   style-table-cell-properties-attlist,
5603   style-table-cell-properties-elements
5604 style-table-cell-properties-attlist =
5605   attribute style:vertical-align {
5606     "top" | "middle" | "bottom" | "automatic"
5607   }?
5608   & attribute style:text-align-source { "fix" | "value-type" }?
5609   & common-style-direction-attlist
5610   & attribute style:glyph-orientation-vertical {
5611       "auto" | "0" | "0deg" | "0rad" | "0grad"
5612     }?
5613   & common-writing-mode-attlist
5614   & common-shadow-attlist
5615   & common-background-color-attlist
5616   & common-border-attlist
5617   & attribute style:diagonal-tl-br { \string }?
5618   & attribute style:diagonal-tl-br-widths { borderWidths }?
5619   & attribute style:diagonal-bl-tr { \string }?
5620   & attribute style:diagonal-bl-tr-widths { borderWidths }?
5621   & common-border-line-width-attlist
5622   & common-padding-attlist
5623   & attribute fo:wrap-option { "no-wrap" | "wrap" }?
5624   & common-rotation-angle-attlist
5625   & attribute style:rotation-align {
5626       "none" | "bottom" | "top" | "center"
5627     }?
5628   & attribute style:cell-protect {
5629       "none"
5630       | "hidden-and-protected"
5631       | list { ("protected" | "formula-hidden")+ }
5632     }?
5633   & attribute style:print-content { boolean }?
5634   & attribute style:decimal-places { nonNegativeInteger }?
5635   & attribute style:repeat-content { boolean }?
5636   & attribute style:shrink-to-fit { boolean }?
5637 common-style-direction-attlist =
5638   attribute style:direction { "ltr" | "ttb" }?
5639 style-table-cell-properties-elements = style-background-image
5640 common-rotation-angle-attlist =
5641   attribute style:rotation-angle { angle }?
5642 style-list-level-properties =
5643   element style:list-level-properties {
5644     style-list-level-properties-content-strict
5645   }
5646 style-list-level-properties-content-strict =
5647   style-list-level-properties-attlist,
5648   style-list-level-properties-elements
5649 style-list-level-properties-attlist =
5650   common-text-align
5651   & attribute text:space-before { length }?
5652   & attribute text:min-label-width { nonNegativeLength }?
5653   & attribute text:min-label-distance { nonNegativeLength }?
5654   & attribute style:font-name { \string }?
5655   & attribute fo:width { positiveLength }?
5656   & attribute fo:height { positiveLength }?
5657   & common-vertical-rel-attlist
5658   & common-vertical-pos-attlist
5659   & attribute text:list-level-position-and-space-mode {
5660       "label-width-and-position" | "label-alignment"
5661     }?
5662 style-list-level-properties-elements = style-list-level-label-alignment
5663 style-list-level-label-alignment =
5664   element style:list-level-label-alignment {
5665     style-list-level-label-alignment-attlist, empty
5666   }?
5667 style-list-level-label-alignment-attlist =
5668   attribute text:label-followed-by { "listtab" | "space" | "nothing" }
5669   & attribute text:list-tab-stop-position { length }?
5670   & attribute fo:text-indent { length }?
5671   & attribute fo:margin-left { length }?
5672 style-graphic-properties-attlist =
5673   attribute draw:stroke { "none" | "dash" | "solid" }?
5674   & attribute draw:stroke-dash { styleNameRef }?
5675   & attribute draw:stroke-dash-names { styleNameRefs }?
5676   & attribute svg:stroke-width { length }?
5677   & attribute svg:stroke-color { color }?
5678   & attribute draw:marker-start { styleNameRef }?
5679   & attribute draw:marker-end { styleNameRef }?
5680   & attribute draw:marker-start-width { length }?
5681   & attribute draw:marker-end-width { length }?
5682   & attribute draw:marker-start-center { boolean }?
5683   & attribute draw:marker-end-center { boolean }?
5684   & attribute svg:stroke-opacity {
5685       xsd:double { minInclusive = "0" maxInclusive = "1" }
5686       | zeroToHundredPercent
5687     }?
5688   & attribute draw:stroke-linejoin {
5689       "miter" | "round" | "bevel" | "middle" | "none"
5690     }?
5691   & attribute svg:stroke-linecap { "butt" | "square" | "round" }?
5692   & attribute draw:symbol-color { color }?
5693   & attribute text:animation {
5694       "none" | "scroll" | "alternate" | "slide"
5695     }?
5696   & attribute text:animation-direction {
5697       "left" | "right" | "up" | "down"
5698     }?
5699   & attribute text:animation-start-inside { boolean }?
5700   & attribute text:animation-stop-inside { boolean }?
5701   & attribute text:animation-repeat { nonNegativeInteger }?
5702   & attribute text:animation-delay { duration }?
5703   & attribute text:animation-steps { length }?
5704   & attribute draw:auto-grow-width { boolean }?
5705   & attribute draw:auto-grow-height { boolean }?
5706   & attribute draw:fit-to-size { boolean }?
5707   & attribute draw:fit-to-contour { boolean }?
5708   & attribute draw:textarea-vertical-align {
5709       "top" | "middle" | "bottom" | "justify"
5710     }?
5711   & attribute draw:textarea-horizontal-align {
5712       "left" | "center" | "right" | "justify"
5713     }?
5714   & attribute fo:wrap-option { "no-wrap" | "wrap" }?
5715   & attribute style:shrink-to-fit { boolean }?
5716   & attribute draw:color-mode {
5717       "greyscale" | "mono" | "watermark" | "standard"
5718     }?
5719   & attribute draw:color-inversion { boolean }?
5720   & attribute draw:luminance { zeroToHundredPercent }?
5721   & attribute draw:contrast { percent }?
5722   & attribute draw:gamma { percent }?
5723   & attribute draw:red { signedZeroToHundredPercent }?
5724   & attribute draw:green { signedZeroToHundredPercent }?
5725   & attribute draw:blue { signedZeroToHundredPercent }?
5726   & attribute draw:image-opacity { zeroToHundredPercent }?
5727   & attribute draw:shadow { "visible" | "hidden" }?
5728   & attribute draw:shadow-offset-x { length }?
5729   & attribute draw:shadow-offset-y { length }?
5730   & attribute draw:shadow-color { color }?
5731   & attribute draw:shadow-opacity { zeroToHundredPercent }?
5732   & attribute draw:start-line-spacing-horizontal { distance }?
5733   & attribute draw:start-line-spacing-vertical { distance }?
5734   & attribute draw:end-line-spacing-horizontal { distance }?
5735   & attribute draw:end-line-spacing-vertical { distance }?
5736   & attribute draw:line-distance { distance }?
5737   & attribute draw:guide-overhang { length }?
5738   & attribute draw:guide-distance { distance }?
5739   & attribute draw:start-guide { length }?
5740   & attribute draw:end-guide { length }?
5741   & attribute draw:placing { "below" | "above" }?
5742   & attribute draw:parallel { boolean }?
5743   & attribute draw:measure-align {
5744       "automatic" | "left-outside" | "inside" | "right-outside"
5745     }?
5746   & attribute draw:measure-vertical-align {
5747       "automatic" | "above" | "below" | "center"
5748     }?
5749   & attribute draw:unit {
5750       "automatic"
5751       | "mm"
5752       | "cm"
5753       | "m"
5754       | "km"
5755       | "pt"
5756       | "pc"
5757       | "inch"
5758       | "ft"
5759       | "mi"
5760     }?
5761   & attribute draw:show-unit { boolean }?
5762   & attribute draw:decimal-places { nonNegativeInteger }?
5763   & attribute draw:caption-type {
5764       "straight-line" | "angled-line" | "angled-connector-line"
5765     }?
5766   & attribute draw:caption-angle-type { "fixed" | "free" }?
5767   & attribute draw:caption-angle { angle }?
5768   & attribute draw:caption-gap { distance }?
5769   & attribute draw:caption-escape-direction {
5770       "horizontal" | "vertical" | "auto"
5771     }?
5772   & attribute draw:caption-escape { length | percent }?
5773   & attribute draw:caption-line-length { length }?
5774   & attribute draw:caption-fit-line-length { boolean }?
5775   & attribute dr3d:horizontal-segments { nonNegativeInteger }?
5776   & attribute dr3d:vertical-segments { nonNegativeInteger }?
5777   & attribute dr3d:edge-rounding { percent }?
5778   & attribute dr3d:edge-rounding-mode { "correct" | "attractive" }?
5779   & attribute dr3d:back-scale { percent }?
5780   & attribute dr3d:depth { length }?
5781   & attribute dr3d:backface-culling { "enabled" | "disabled" }?
5782   & attribute dr3d:end-angle { angle }?
5783   & attribute dr3d:close-front { boolean }?
5784   & attribute dr3d:close-back { boolean }?
5785   & attribute dr3d:lighting-mode { "standard" | "double-sided" }?
5786   & attribute dr3d:normals-kind { "object" | "flat" | "sphere" }?
5787   & attribute dr3d:normals-direction { "normal" | "inverse" }?
5788   & attribute dr3d:texture-generation-mode-x {
5789       "object" | "parallel" | "sphere"
5790     }?
5791   & attribute dr3d:texture-generation-mode-y {
5792       "object" | "parallel" | "sphere"
5793     }?
5794   & attribute dr3d:texture-kind { "luminance" | "intensity" | "color" }?
5795   & attribute dr3d:texture-filter { "enabled" | "disabled" }?
5796   & attribute dr3d:texture-mode { "replace" | "modulate" | "blend" }?
5797   & attribute dr3d:ambient-color { color }?
5798   & attribute dr3d:emissive-color { color }?
5799   & attribute dr3d:specular-color { color }?
5800   & attribute dr3d:diffuse-color { color }?
5801   & attribute dr3d:shininess { percent }?
5802   & attribute dr3d:shadow { "visible" | "hidden" }?
5803   & common-draw-rel-size-attlist
5804   & attribute fo:min-width { length | percent }?
5805   & attribute fo:min-height { length | percent }?
5806   & attribute fo:max-height { length | percent }?
5807   & attribute fo:max-width { length | percent }?
5808   & common-horizontal-margin-attlist
5809   & common-vertical-margin-attlist
5810   & common-margin-attlist
5811   & attribute style:print-content { boolean }?
5812   & attribute style:protect {
5813       "none"
5814       | list { ("content" | "position" | "size")+ }
5815     }?
5816   & attribute style:horizontal-pos {
5817       "left"
5818       | "center"
5819       | "right"
5820       | "from-left"
5821       | "inside"
5822       | "outside"
5823       | "from-inside"
5824     }?
5825   & attribute svg:x { coordinate }?
5826   & attribute style:horizontal-rel {
5827       "page"
5828       | "page-content"
5829       | "page-start-margin"
5830       | "page-end-margin"
5831       | "frame"
5832       | "frame-content"
5833       | "frame-start-margin"
5834       | "frame-end-margin"
5835       | "paragraph"
5836       | "paragraph-content"
5837       | "paragraph-start-margin"
5838       | "paragraph-end-margin"
5839       | "char"
5840     }?
5841   & common-vertical-pos-attlist
5842   & common-vertical-rel-attlist
5843   & common-text-anchor-attlist
5844   & common-border-attlist
5845   & common-border-line-width-attlist
5846   & common-padding-attlist
5847   & common-shadow-attlist
5848   & common-background-color-attlist
5849   & common-background-transparency-attlist
5850   & common-editable-attlist
5851   & attribute style:wrap {
5852       "none"
5853       | "left"
5854       | "right"
5855       | "parallel"
5856       | "dynamic"
5857       | "run-through"
5858       | "biggest"
5859     }?
5860   & attribute style:wrap-dynamic-threshold { nonNegativeLength }?
5861   & attribute style:number-wrapped-paragraphs {
5862       "no-limit" | positiveInteger
5863     }?
5864   & attribute style:wrap-contour { boolean }?
5865   & attribute style:wrap-contour-mode { "full" | "outside" }?
5866   & attribute style:run-through { "foreground" | "background" }?
5867   & attribute style:flow-with-text { boolean }?
5868   & attribute style:overflow-behavior {
5869       "clip" | "auto-create-new-frame"
5870     }?
5871   & attribute style:mirror {
5872       "none"
5873       | "vertical"
5874       | horizontal-mirror
5875       | list { "vertical", horizontal-mirror }
5876       | list { horizontal-mirror, "vertical" }
5877     }?
5878   & attribute fo:clip { "auto" | clipShape }?
5879   & attribute draw:wrap-influence-on-position {
5880       "iterative" | "once-concurrent" | "once-successive"
5881     }?
5882   & common-writing-mode-attlist
5883   & attribute draw:frame-display-scrollbar { boolean }?
5884   & attribute draw:frame-display-border { boolean }?
5885   & attribute draw:frame-margin-horizontal { nonNegativePixelLength }?
5886   & attribute draw:frame-margin-vertical { nonNegativePixelLength }?
5887   & attribute draw:visible-area-left { nonNegativeLength }?
5888   & attribute draw:visible-area-top { nonNegativeLength }?
5889   & attribute draw:visible-area-width { positiveLength }?
5890   & attribute draw:visible-area-height { positiveLength }?
5891   & attribute draw:draw-aspect {
5892       "content" | "thumbnail" | "icon" | "print-view"
5893     }?
5894   & attribute draw:ole-draw-aspect { nonNegativeInteger }?
5895 style-graphic-fill-properties-attlist =
5896   attribute draw:fill {
5897     "none" | "solid" | "bitmap" | "gradient" | "hatch"
5898   }?
5899   & attribute draw:fill-color { color }?
5900   & attribute draw:secondary-fill-color { color }?
5901   & attribute draw:fill-gradient-name { styleNameRef }?
5902   & attribute draw:gradient-step-count { nonNegativeInteger }?
5903   & attribute draw:fill-hatch-name { styleNameRef }?
5904   & attribute draw:fill-hatch-solid { boolean }?
5905   & attribute draw:fill-image-name { styleNameRef }?
5906   & attribute style:repeat { "no-repeat" | "repeat" | "stretch" }?
5907   & attribute draw:fill-image-width { length | percent }?
5908   & attribute draw:fill-image-height { length | percent }?
5909   & attribute draw:fill-image-ref-point-x { percent }?
5910   & attribute draw:fill-image-ref-point-y { percent }?
5911   & attribute draw:fill-image-ref-point {
5912       "top-left"
5913       | "top"
5914       | "top-right"
5915       | "left"
5916       | "center"
5917       | "right"
5918       | "bottom-left"
5919       | "bottom"
5920       | "bottom-right"
5921     }?
5922   & attribute draw:tile-repeat-offset {
5923       list { zeroToHundredPercent, ("horizontal" | "vertical") }
5924     }?
5925   & attribute draw:opacity { zeroToHundredPercent }?
5926   & attribute draw:opacity-name { styleNameRef }?
5927   & attribute svg:fill-rule { "nonzero" | "evenodd" }?
5928 style-graphic-properties-elements =
5929   text-list-style? & style-background-image & style-columns
5930 common-vertical-pos-attlist =
5931   attribute style:vertical-pos {
5932     "top" | "middle" | "bottom" | "from-top" | "below"
5933   }?,
5934   attribute svg:y { coordinate }?
5935 common-vertical-rel-attlist =
5936   attribute style:vertical-rel {
5937     "page"
5938     | "page-content"
5939     | "frame"
5940     | "frame-content"
5941     | "paragraph"
5942     | "paragraph-content"
5943     | "char"
5944     | "line"
5945     | "baseline"
5946     | "text"
5947   }?
5948 common-editable-attlist = attribute style:editable { boolean }?
5949 horizontal-mirror =
5950   "horizontal" | "horizontal-on-odd" | "horizontal-on-even"
5951 clipShape =
5952   xsd:string {
5953     pattern =
5954       "rect\([ ]*((-?([0-9]+(\.[0-9]*)?|\.[0-9]+)((cm)|(mm)|(in)|(pt)|(pc)))|(auto))([ ]*,[ ]*((-?([0-9]+(\.[0-9]*)?|\.[0-9]+)((cm)|(mm)|(in)|(pt)|(pc))))|(auto)){3}[ ]*\)"
5955   }
5956 nonNegativePixelLength =
5957   xsd:string { pattern = "([0-9]+(\.[0-9]*)?|\.[0-9]+)(px)" }
5958 style-chart-properties =
5959   element style:chart-properties {
5960     style-chart-properties-content-strict
5961   }
5962 style-chart-properties-content-strict =
5963   style-chart-properties-attlist, style-chart-properties-elements
5964 style-chart-properties-elements = empty
5965 style-chart-properties-attlist =
5966   attribute chart:scale-text { boolean }?
5967   & attribute chart:three-dimensional { boolean }?
5968   & attribute chart:deep { boolean }?
5969   & attribute chart:right-angled-axes { boolean }?
5970   & (attribute chart:symbol-type { "none" }
5971      | attribute chart:symbol-type { "automatic" }
5972      | (attribute chart:symbol-type { "named-symbol" },
5973         attribute chart:symbol-name {
5974           "square"
5975           | "diamond"
5976           | "arrow-down"
5977           | "arrow-up"
5978           | "arrow-right"
5979           | "arrow-left"
5980           | "bow-tie"
5981           | "hourglass"
5982           | "circle"
5983           | "star"
5984           | "x"
5985           | "plus"
5986           | "asterisk"
5987           | "horizontal-bar"
5988           | "vertical-bar"
5989         })
5990      | (attribute chart:symbol-type { "image" },
5991         element chart:symbol-image {
5992           attribute xlink:href { anyIRI }
5993         })
5994      | empty)
5995   & attribute chart:symbol-width { nonNegativeLength }?
5996   & attribute chart:symbol-height { nonNegativeLength }?
5997   & attribute chart:sort-by-x-values { boolean }?
5998   & attribute chart:vertical { boolean }?
5999   & attribute chart:connect-bars { boolean }?
6000   & attribute chart:gap-width { integer }?
6001   & attribute chart:overlap { integer }?
6002   & attribute chart:group-bars-per-axis { boolean }?
6003   & attribute chart:japanese-candle-stick { boolean }?
6004   & attribute chart:interpolation {
6005       "none" | "cubic-spline" | "b-spline"
6006     }?
6007   & attribute chart:spline-order { positiveInteger }?
6008   & attribute chart:spline-resolution { positiveInteger }?
6009   & attribute chart:pie-offset { nonNegativeInteger }?
6010   & attribute chart:angle-offset { angle }?
6011   & attribute chart:hole-size { percent }?
6012   & attribute chart:lines { boolean }?
6013   & attribute chart:solid-type {
6014       "cuboid" | "cylinder" | "cone" | "pyramid"
6015     }?
6016   & attribute chart:stacked { boolean }?
6017   & attribute chart:percentage { boolean }?
6018   & attribute chart:treat-empty-cells {
6019       "use-zero" | "leave-gap" | "ignore"
6020     }?
6021   & attribute chart:link-data-style-to-source { boolean }?
6022   & attribute chart:logarithmic { boolean }?
6023   & attribute chart:maximum { double }?
6024   & attribute chart:minimum { double }?
6025   & attribute chart:origin { double }?
6026   & attribute chart:interval-major { double }?
6027   & attribute chart:interval-minor-divisor { positiveInteger }?
6028   & attribute chart:tick-marks-major-inner { boolean }?
6029   & attribute chart:tick-marks-major-outer { boolean }?
6030   & attribute chart:tick-marks-minor-inner { boolean }?
6031   & attribute chart:tick-marks-minor-outer { boolean }?
6032   & attribute chart:reverse-direction { boolean }?
6033   & attribute chart:display-label { boolean }?
6034   & attribute chart:text-overlap { boolean }?
6035   & attribute text:line-break { boolean }?
6036   & attribute chart:label-arrangement {
6037       "side-by-side" | "stagger-even" | "stagger-odd"
6038     }?
6039   & common-style-direction-attlist
6040   & common-rotation-angle-attlist
6041   & attribute chart:data-label-number {
6042       "none" | "value" | "percentage" | "value-and-percentage"
6043     }?
6044   & attribute chart:data-label-text { boolean }?
6045   & attribute chart:data-label-symbol { boolean }?
6046   & element chart:label-separator { text-p }?
6047   & attribute chart:label-position { labelPositions }?
6048   & attribute chart:label-position-negative { labelPositions }?
6049   & attribute chart:visible { boolean }?
6050   & attribute chart:auto-position { boolean }?
6051   & attribute chart:auto-size { boolean }?
6052   & attribute chart:mean-value { boolean }?
6053   & attribute chart:error-category {
6054       "none"
6055       | "variance"
6056       | "standard-deviation"
6057       | "percentage"
6058       | "error-margin"
6059       | "constant"
6060       | "standard-error"
6061       | "cell-range"
6062     }?
6063   & attribute chart:error-percentage { double }?
6064   & attribute chart:error-margin { double }?
6065   & attribute chart:error-lower-limit { double }?
6066   & attribute chart:error-upper-limit { double }?
6067   & attribute chart:error-upper-indicator { boolean }?
6068   & attribute chart:error-lower-indicator { boolean }?
6069   & attribute chart:error-lower-range { cellRangeAddressList }?
6070   & attribute chart:error-upper-range { cellRangeAddressList }?
6071   & attribute chart:series-source { "columns" | "rows" }?
6072   & attribute chart:regression-type {
6073       "none" | "linear" | "logarithmic" | "exponential" | "power"
6074     }?
6075   & attribute chart:axis-position { "start" | "end" | double }?
6076   & attribute chart:axis-label-position {
6077       "near-axis"
6078       | "near-axis-other-side"
6079       | "outside-start"
6080       | "outside-end"
6081     }?
6082   & attribute chart:tick-mark-position {
6083       "at-labels" | "at-axis" | "at-labels-and-axis"
6084     }?
6085   & attribute chart:include-hidden-cells { boolean }?
6086 labelPositions =
6087   "avoid-overlap"
6088   | "center"
6089   | "top"
6090   | "top-right"
6091   | "right"
6092   | "bottom-right"
6093   | "bottom"
6094   | "bottom-left"
6095   | "left"
6096   | "top-left"
6097   | "inside"
6098   | "outside"
6099   | "near-origin"
6100 style-drawing-page-properties-attlist =
6101   attribute presentation:transition-type {
6102     "manual" | "automatic" | "semi-automatic"
6103   }?
6104   & attribute presentation:transition-style {
6105       "none"
6106       | "fade-from-left"
6107       | "fade-from-top"
6108       | "fade-from-right"
6109       | "fade-from-bottom"
6110       | "fade-from-upperleft"
6111       | "fade-from-upperright"
6112       | "fade-from-lowerleft"
6113       | "fade-from-lowerright"
6114       | "move-from-left"
6115       | "move-from-top"
6116       | "move-from-right"
6117       | "move-from-bottom"
6118       | "move-from-upperleft"
6119       | "move-from-upperright"
6120       | "move-from-lowerleft"
6121       | "move-from-lowerright"
6122       | "uncover-to-left"
6123       | "uncover-to-top"
6124       | "uncover-to-right"
6125       | "uncover-to-bottom"
6126       | "uncover-to-upperleft"
6127       | "uncover-to-upperright"
6128       | "uncover-to-lowerleft"
6129       | "uncover-to-lowerright"
6130       | "fade-to-center"
6131       | "fade-from-center"
6132       | "vertical-stripes"
6133       | "horizontal-stripes"
6134       | "clockwise"
6135       | "counterclockwise"
6136       | "open-vertical"
6137       | "open-horizontal"
6138       | "close-vertical"
6139       | "close-horizontal"
6140       | "wavyline-from-left"
6141       | "wavyline-from-top"
6142       | "wavyline-from-right"
6143       | "wavyline-from-bottom"
6144       | "spiralin-left"
6145       | "spiralin-right"
6146       | "spiralout-left"
6147       | "spiralout-right"
6148       | "roll-from-top"
6149       | "roll-from-left"
6150       | "roll-from-right"
6151       | "roll-from-bottom"
6152       | "stretch-from-left"
6153       | "stretch-from-top"
6154       | "stretch-from-right"
6155       | "stretch-from-bottom"
6156       | "vertical-lines"
6157       | "horizontal-lines"
6158       | "dissolve"
6159       | "random"
6160       | "vertical-checkerboard"
6161       | "horizontal-checkerboard"
6162       | "interlocking-horizontal-left"
6163       | "interlocking-horizontal-right"
6164       | "interlocking-vertical-top"
6165       | "interlocking-vertical-bottom"
6166       | "fly-away"
6167       | "open"
6168       | "close"
6169       | "melt"
6170     }?
6171   & attribute presentation:transition-speed { presentationSpeeds }?
6172   & attribute smil:type { \string }?
6173   & attribute smil:subtype { \string }?
6174   & attribute smil:direction { "forward" | "reverse" }?
6175   & attribute smil:fadeColor { color }?
6176   & attribute presentation:duration { duration }?
6177   & attribute presentation:visibility { "visible" | "hidden" }?
6178   & attribute draw:background-size { "full" | "border" }?
6179   & attribute presentation:background-objects-visible { boolean }?
6180   & attribute presentation:background-visible { boolean }?
6181   & attribute presentation:display-header { boolean }?
6182   & attribute presentation:display-footer { boolean }?
6183   & attribute presentation:display-page-number { boolean }?
6184   & attribute presentation:display-date-time { boolean }?
6185 style-drawing-page-properties-elements = presentation-sound?
6186 \string = xsd:string
6187 date = xsd:date
6188 time = xsd:time
6189 dateTime = xsd:dateTime
6190 duration = xsd:duration
6191 integer = xsd:integer
6192 nonNegativeInteger = xsd:nonNegativeInteger
6193 positiveInteger = xsd:positiveInteger
6194 double = xsd:double
6195 anyURI = xsd:anyURI
6196 base64Binary = xsd:base64Binary
6197 ID = xsd:ID
6198 IDREF = xsd:IDREF
6199 IDREFS = xsd:IDREFS
6200 NCName = xsd:NCName
6201 boolean = "true" | "false"
6202 dateOrDateTime = xsd:date | xsd:dateTime
6203 timeOrDateTime = xsd:time | xsd:dateTime
6204 language = xsd:language
6205 countryCode = xsd:token { pattern = "[A-Za-z0-9]{1,8}" }
6206 languageCode = xsd:token { pattern = "[A-Za-z]{1,8}" }
6207 scriptCode = xsd:token { pattern = "[A-Za-z0-9]{1,8}" }
6208 character = xsd:string { length = "1" }
6209 length =
6210   xsd:string {
6211     pattern =
6212       "-?([0-9]+(\.[0-9]*)?|\.[0-9]+)((cm)|(mm)|(in)|(pt)|(pc)|(px))"
6213   }
6214 nonNegativeLength =
6215   xsd:string {
6216     pattern =
6217       "([0-9]+(\.[0-9]*)?|\.[0-9]+)((cm)|(mm)|(in)|(pt)|(pc)|(px))"
6218   }
6219 positiveLength =
6220   xsd:string {
6221     pattern =
6222       "([0-9]*[1-9][0-9]*(\.[0-9]*)?|0+\.[0-9]*[1-9][0-9]*|\.[0-9]*[1-9][0-9]*)((cm)|(mm)|(in)|(pt)|(pc)|(px))"
6223   }
6224 percent = xsd:string { pattern = "-?([0-9]+(\.[0-9]*)?|\.[0-9]+)%" }
6225 zeroToHundredPercent =
6226   xsd:string {
6227     pattern = "([0-9]?[0-9](\.[0-9]*)?|100(\.0*)?|\.[0-9]+)%"
6228   }
6229 signedZeroToHundredPercent =
6230   xsd:string {
6231     pattern = "-?([0-9]?[0-9](\.[0-9]*)?|100(\.0*)?|\.[0-9]+)%"
6232   }
6233 relativeLength = xsd:string { pattern = "[0-9]+\*" }
6234 coordinate = length
6235 distance = length
6236 color = xsd:string { pattern = "#[0-9a-fA-F]{6}" }
6237 angle = xsd:string
6238 CURIE =
6239   xsd:string { pattern = "(([\i-[:]][\c-[:]]*)?:)?.+" minLength = "1" }
6240 CURIEs = list { CURIE+ }
6241 SafeCURIE =
6242   xsd:string {
6243     pattern = "\[(([\i-[:]][\c-[:]]*)?:)?.+\]"
6244     minLength = "3"
6245   }
6246 URIorSafeCURIE = anyURI | SafeCURIE
6247 styleName = xsd:NCName
6248 styleNameRef = xsd:NCName | empty
6249 styleNameRefs = list { xsd:NCName* }
6250 variableName = xsd:string
6251 targetFrameName = "_self" | "_blank" | "_parent" | "_top" | \string
6252 valueType =
6253   "float"
6254   | "time"
6255   | "date"
6256   | "percentage"
6257   | "currency"
6258   | "boolean"
6259   | "string"
6260 points =
6261   xsd:string { pattern = "-?[0-9]+,-?[0-9]+([ ]+-?[0-9]+,-?[0-9]+)*" }
6262 pathData = xsd:string
6263 vector3D =
6264   xsd:string {
6265     pattern =
6266       "\([ ]*-?([0-9]+(\.[0-9]*)?|\.[0-9]+)([ ]+-?([0-9]+(\.[0-9]*)?|\.[0-9]+)){2}[ ]*\)"
6267   }
6268 namespacedToken = xsd:QName { pattern = "[^:]+:[^:]+" }
6269 anyIRI =
6270   xsd:anyURI
6271   >> dc:description [
6272        "An IRI-reference as defined in [RFC3987]. See ODF 1.2 Part 1 section 18.3."
6273      ]
6274 anyAttListOrElements =
6275   attribute * { text }*,
6276   anyElements
6277 anyElements =
6278   element * {
6279     mixed { anyAttListOrElements }
6280   }*