3 DO NOT ALTER
OR REMOVE COPYRIGHT NOTICES
OR THIS FILE HEADER.
5 Copyright
2008 by Sun Microsystems
, Inc.
7 OpenOffice.org
- a multi
-platform office productivity suite
9 $RCSfile
: office.mod
,v $
13 This file is part of OpenOffice.org.
15 OpenOffice.org is free software
: you can redistribute it and
/or modify
16 it under the terms of the GNU Lesser General Public License version
3
17 only
, as published by the Free Software Foundation.
19 OpenOffice.org is distributed in the hope that it will be useful
,
20 but WITHOUT ANY WARRANTY
; without even the implied warranty of
21 MERCHANTABILITY or FITNESS
FOR A PARTICULAR PURPOSE. See the
22 GNU Lesser General Public License version
3 for more details
23 (a copy is included in the LICENSE file that accompanied this code
).
25 You should have received a copy of the GNU Lesser General Public License
26 version
3 along with OpenOffice.org. If not
, see
27 <http
://www.openoffice.org
/license.html
>
28 for a copy of the LGPLv3 License.
32 <!ELEMENT office
:document ( office
:meta?
,
37 office
:automatic
-styles?
,
38 office
:master
-styles?
,
41 <!ATTLIST office
:document xmlns
:office CDATA #FIXED
"&nOffice;">
42 <!ATTLIST office
:document xmlns
:meta CDATA #FIXED
"&nMeta;">
43 <!ATTLIST office
:document xmlns
:script CDATA #FIXED
"&nScript;">
44 <!ATTLIST office
:document xmlns
:style CDATA #FIXED
"&nStyle;">
45 <!ATTLIST office
:document xmlns
:text CDATA #FIXED
"&nText;">
46 <!ATTLIST office
:document xmlns
:table CDATA #FIXED
"&nTable;">
47 <!ATTLIST office
:document xmlns
:draw CDATA #FIXED
"&nDraw;">
48 <!ATTLIST office
:document xmlns
:chart CDATA #FIXED
"&nChart;">
49 <!ATTLIST office
:document xmlns
:number CDATA #FIXED
"&nNumber;">
50 <!ATTLIST office
:document xmlns
:fo CDATA #FIXED
"&nFO;">
51 <!ATTLIST office
:document xmlns
:xlink CDATA #FIXED
"&nXLink;">
52 <!ATTLIST office
:document xmlns
:svg CDATA #FIXED
"&nSVG;">
53 <!ATTLIST office
:document xmlns
:dc CDATA #FIXED
"&nDC;">
54 <!ATTLIST office
:document xmlns
:dr3d CDATA #FIXED
"&nDr3D;">
55 <!ATTLIST office
:document xmlns
:math CDATA #FIXED
"&nMath;">
56 <!ATTLIST office
:document xmlns
:form CDATA #FIXED
"&nForm;">
57 <!ATTLIST office
:document xmlns
:config CDATA #FIXED
"&nConfig;">
58 <!ATTLIST office
:document xmlns
:presentation CDATA #FIXED
"&nPresentation;">
60 <!ATTLIST office
:document office
:class
63 spreadsheet|chart
) #REQUIRED
>
65 <!ATTLIST office
:document office
:version
%string
; #IMPLIED
>
67 <!-- document
-styles
-->
68 <!ELEMENT office
:document
-styles (
71 office
:automatic
-styles?
,
72 office
:master
-styles?
) >
74 <!ATTLIST office
:document
-styles xmlns
:office CDATA #FIXED
"&nOffice;">
75 <!ATTLIST office
:document
-styles xmlns
:meta CDATA #FIXED
"&nMeta;">
76 <!ATTLIST office
:document
-styles xmlns
:script CDATA #FIXED
"&nScript;">
77 <!ATTLIST office
:document
-styles xmlns
:style CDATA #FIXED
"&nStyle;">
78 <!ATTLIST office
:document
-styles xmlns
:text CDATA #FIXED
"&nText;">
79 <!ATTLIST office
:document
-styles xmlns
:table CDATA #FIXED
"&nTable;">
80 <!ATTLIST office
:document
-styles xmlns
:draw CDATA #FIXED
"&nDraw;">
81 <!ATTLIST office
:document
-styles xmlns
:chart CDATA #FIXED
"&nChart;">
82 <!ATTLIST office
:document
-styles xmlns
:number CDATA #FIXED
"&nNumber;">
83 <!ATTLIST office
:document
-styles xmlns
:fo CDATA #FIXED
"&nFO;">
84 <!ATTLIST office
:document
-styles xmlns
:xlink CDATA #FIXED
"&nXLink;">
85 <!ATTLIST office
:document
-styles xmlns
:svg CDATA #FIXED
"&nSVG;">
86 <!ATTLIST office
:document
-styles xmlns
:dc CDATA #FIXED
"&nDC;">
87 <!ATTLIST office
:document
-styles xmlns
:dr3d CDATA #FIXED
"&nDr3D;">
88 <!ATTLIST office
:document
-styles xmlns
:math CDATA #FIXED
"&nMath;">
89 <!ATTLIST office
:document
-styles xmlns
:form CDATA #FIXED
"&nForm;">
91 <!ATTLIST office
:document
-styles office
:version
%string
; #IMPLIED
>
93 <!-- document
-content
-->
95 <!ELEMENT office
:document
-content (
98 office
:automatic
-styles?
,
101 <!ATTLIST office
:document
-content xmlns
:office CDATA #FIXED
"&nOffice;">
102 <!ATTLIST office
:document
-content xmlns
:meta CDATA #FIXED
"&nMeta;">
103 <!ATTLIST office
:document
-content xmlns
:script CDATA #FIXED
"&nScript;">
104 <!ATTLIST office
:document
-content xmlns
:style CDATA #FIXED
"&nStyle;">
105 <!ATTLIST office
:document
-content xmlns
:text CDATA #FIXED
"&nText;">
106 <!ATTLIST office
:document
-content xmlns
:table CDATA #FIXED
"&nTable;">
107 <!ATTLIST office
:document
-content xmlns
:draw CDATA #FIXED
"&nDraw;">
108 <!ATTLIST office
:document
-content xmlns
:chart CDATA #FIXED
"&nChart;">
109 <!ATTLIST office
:document
-content xmlns
:number CDATA #FIXED
"&nNumber;">
110 <!ATTLIST office
:document
-content xmlns
:fo CDATA #FIXED
"&nFO;">
111 <!ATTLIST office
:document
-content xmlns
:xlink CDATA #FIXED
"&nXLink;">
112 <!ATTLIST office
:document
-content xmlns
:svg CDATA #FIXED
"&nSVG;">
113 <!ATTLIST office
:document
-content xmlns
:dc CDATA #FIXED
"&nDC;">
114 <!ATTLIST office
:document
-content xmlns
:dr3d CDATA #FIXED
"&nDr3D;">
115 <!ATTLIST office
:document
-content xmlns
:math CDATA #FIXED
"&nMath;">
116 <!ATTLIST office
:document
-content xmlns
:form CDATA #FIXED
"&nForm;">
118 <!ATTLIST office
:document
-content office
:class
120 drawing|presentation|
121 spreadsheet|chart
) #REQUIRED
>
123 <!ATTLIST office
:document
-content office
:version
%string
; #IMPLIED
>
125 <!-- document
-content
-->
127 <!ELEMENT office
:document
-meta ( office
:meta?
) >
129 <!ATTLIST office
:document
-meta xmlns
:office CDATA #FIXED
"&nOffice;">
130 <!ATTLIST office
:document
-meta xmlns
:meta CDATA #FIXED
"&nMeta;">
131 <!ATTLIST office
:document
-meta xmlns
:script CDATA #FIXED
"&nScript;">
132 <!ATTLIST office
:document
-meta xmlns
:style CDATA #FIXED
"&nStyle;">
133 <!ATTLIST office
:document
-meta xmlns
:text CDATA #FIXED
"&nText;">
134 <!ATTLIST office
:document
-meta xmlns
:table CDATA #FIXED
"&nTable;">
135 <!ATTLIST office
:document
-meta xmlns
:draw CDATA #FIXED
"&nDraw;">
136 <!ATTLIST office
:document
-meta xmlns
:chart CDATA #FIXED
"&nChart;">
137 <!ATTLIST office
:document
-meta xmlns
:number CDATA #FIXED
"&nNumber;">
138 <!ATTLIST office
:document
-meta xmlns
:fo CDATA #FIXED
"&nFO;">
139 <!ATTLIST office
:document
-meta xmlns
:xlink CDATA #FIXED
"&nXLink;">
140 <!ATTLIST office
:document
-meta xmlns
:svg CDATA #FIXED
"&nSVG;">
141 <!ATTLIST office
:document
-meta xmlns
:dc CDATA #FIXED
"&nDC;">
142 <!ATTLIST office
:document
-meta xmlns
:dr3d CDATA #FIXED
"&nDr3D;">
143 <!ATTLIST office
:document
-meta xmlns
:math CDATA #FIXED
"&nMath;">
144 <!ATTLIST office
:document
-meta xmlns
:form CDATA #FIXED
"&nForm;">
146 <!ATTLIST office
:document
-meta office
:version
%string
; #IMPLIED
>
148 <!ELEMENT office
:document
-settings (office
:settings
) >
149 <!ATTLIST office
:document
-settings xmlns
:office CDATA #FIXED
"&nOffice;">
150 <!ATTLIST office
:document
-settings xmlns
:xlink CDATA #FIXED
"&nXLink;">
151 <!ATTLIST office
:document
-settings xmlns
:config CDATA #FIXED
"&nConfig;">
153 <!ATTLIST office
:document
-settings office
:version
%string
; #IMPLIED
>
155 <!ENTITY
% meta
"(meta:generator?,
159 meta:initial-creator?,
167 meta:editing-cycles?,
168 meta:editing-duration?,
169 meta:hyperlink-behaviour?,
173 meta:document-statistic?)">
174 <!ELEMENT office
:meta
%meta
;>
176 <!ENTITY
% script
"office:script-data*,office:events?">
177 <!ELEMENT office
:script (%script
;)>
179 <!ELEMENT office
:script
-data (script
:libraries*)
>
180 <!ATTLIST office
:script
-data script
:language
%string
; #REQUIRED
>
182 <!ELEMENT office
:font
-decls (style
:font
-decl
)*>
184 <!ENTITY
% styles
"(style:default-style|style:style|text:list-style|
185 number:number-style|number:currency-style|number:percentage-style|
186 number:date-style|number:time-style|number:boolean-style|
188 draw:gradient|draw:hatch|draw:fill-image|draw:marker|draw:stroke-dash|
189 style:presentation-page-layout|draw:transparency)">
191 <!-- Validity constraint
: The elements
193 text
:footnotes
-configuration
,
194 text
:endnotes
-configuration
,
195 text
:bibliography
-configuration and
196 text
:linenumbering
-configuration
197 may appear only once
!
198 Unfortunatetly
, this constraint cannot be easily specified in the DTD.
200 <!ELEMENT office
:styles (%styles
;|text
:outline
-style|
201 text
:footnotes
-configuration|text
:endnotes
-configuration|
202 text
:bibliography
-configuration|text
:linenumbering
-configuration
)*>
204 <!ELEMENT office
:automatic
-styles (%styles
;|style
:page
-master
)*>
206 <!ELEMENT office
:master
-styles (draw
:layer
-set?
,style
:handout
-master?
,style
:master
-page*)
>
209 <!ENTITY
% body
"(office:forms?,(text:tracked-changes|table:tracked-changes)?,%text-decls;,table:calculation-settings?,table:content-validations?,table:label-ranges?,
210 (text:h|text:p|text:ordered-list|
211 text:unordered-list|table:table|draw:page|
212 draw:a|%shape;|text:section|text:table-of-content|
213 text:illustration-index|text:table-index|text:object-index|
214 text:user-index|text:alphabetical-index|text:bibliography|
216 table:named-expressions?,
217 table:database-ranges?,table:data-pilot-tables?,
218 table:consolidation?,
220 presentation:settings?)">
221 <!ELEMENT office
:body
%body
;>
222 <!ATTLIST office
:body table
:structure
-protected
%boolean
; "false"
223 table
:protection
-key CDATA #IMPLIED
>
225 <!ELEMENT office
:events (script
:event|presentation
:event
)*>
227 <!-- DDE source
: for text sections and tables
-->
228 <!ELEMENT office
:dde
-source EMPTY
>
229 <!ATTLIST office
:dde
-source office
:dde
-application CDATA #IMPLIED
>
230 <!ATTLIST office
:dde
-source office
:dde
-topic CDATA #IMPLIED
>
231 <!ATTLIST office
:dde
-source office
:dde
-item CDATA #IMPLIED
>
232 <!ATTLIST office
:dde
-source office
:automatic
-update
%boolean
; "false">
233 <!ATTLIST office
:dde
-source office
:name CDATA #IMPLIED
>
234 <!ATTLIST office
:dde
-source table
:conversion
-mode (into
-default
-style
-data
-style|into
-english
-number|let
-text
) "into-default-style-data-style" >
237 <!-- limitation
: in the current implementation
, only plain text inside of
238 paragraphs is supported
-->
239 <!ELEMENT office
:annotation (text
:p
)*>
240 <!ATTLIST office
:annotation office
:author
%string
; #IMPLIED
>
241 <!ATTLIST office
:annotation office
:create
-date
%date
; #IMPLIED
>
242 <!ATTLIST office
:annotation office
:create
-date
-string
%string
; #IMPLIED
>
243 <!ATTLIST office
:annotation office
:display
%boolean
; "false">
245 <!ELEMENT office
:change
-info (text
:p
)*>
246 <!ATTLIST office
:change
-info office
:chg
-author
%string
; #REQUIRED
>
247 <!ATTLIST office
:change
-info office
:chg
-date
-time
%timeInstance
; #REQUIRED
>
249 <!ELEMENT office
:binary
-data (#PCDATA
)>