소스 검색

Add Jambunathan's odt exporter in contrib/.

This adds these new files:

contrib/lisp/org-lparse.el
contrib/lisp/org-odt.el
contrib/lisp/org-xhtml.el
contrib/odt/BasicODConverter/BasicODConverter-0.8.0.oxt
contrib/odt/BasicODConverter/Filters.bas
contrib/odt/BasicODConverter/Main.bas
contrib/odt/OASIS/OpenDocument-schema-v1.1.rng
contrib/odt/OASIS/OpenDocument-v1.2-cs01-manifest-schema.rng
contrib/odt/OASIS/OpenDocument-v1.2-cs01-schema.rng
contrib/odt/README.org
contrib/odt/etc/schema/od-manifest-schema-v1.2-cs01.rnc
contrib/odt/etc/schema/od-schema-v1.1.rnc
contrib/odt/etc/schema/od-schema-v1.2-cs01.rnc
contrib/odt/etc/schema/schemas.xml
contrib/odt/styles/OrgOdtAutomaticStyles.xml
contrib/odt/styles/OrgOdtStyles.xml

Notes:

contrib/lisp/org-xhtml.el is meant to be merged at some point with
lisp/org-html.el, to avoid code redundancies.

The feature as a whole is meant to move to Org's core when things
are tested and stable enough.

Thanks a lot to Jambunathan for this great contribution and for
his patience!
Bastien Guerry 14 년 전
부모
커밋
63b8ecb4ea

+ 1977 - 0
contrib/lisp/org-lparse.el

@@ -0,0 +1,1977 @@
+;;; org-lparse.el --- Line-oriented exporter for Org-mode
+
+;; Copyright (C) 2010, 2011
+;;   Jambunathan <kjambunathan at gmail dot com>
+
+;; Author: Jambunathan K <kjambunathan at gmail dot com>
+;; Keywords: outlines, hypermedia, calendar, wp
+;; Homepage: http://orgmode.org
+;; Version: 0.8
+
+;; This file is not (yet) part of GNU Emacs.
+;; However, it is distributed under the same license.
+
+;; GNU Emacs is free software: you can redistribute it and/or modify
+;; it under the terms of the GNU General Public License as published by
+;; the Free Software Foundation, either version 3 of the License, or
+;; (at your option) any later version.
+
+;; GNU Emacs is distributed in the hope that it will be useful,
+;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+;; GNU General Public License for more details.
+
+;; You should have received a copy of the GNU General Public License
+;; along with GNU Emacs.  If not, see <http://www.gnu.org/licenses/>.
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;;
+;;; Commentary:
+
+;;; `org-lparse' is the entry point for the generic line-oriented
+;;; exporter.  `org-do-lparse' is the genericized version of the
+;;; original `org-export-as-html' routine.
+
+;;; `org-lparse-native-backends' is a good starting point for
+;;; exploring the generic exporter.
+
+;;; Following new interactive commands are provided by this library.
+;;; `org-lparse', `org-lparse-and-open', `org-lparse-to-buffer'
+;;; `org-replace-region-by', `org-lparse-region'.
+
+;;; Note that the above routines correspond to the following routines
+;;; in the html exporter `org-export-as-html',
+;;; `org-export-as-html-and-open', `org-export-as-html-to-buffer',
+;;; `org-replace-region-by-html' and `org-export-region-as-html'.
+
+;;; The all new interactive command `org-export-convert' can be used
+;;; to convert documents between various formats.  Use this to
+;;; command, for example, to convert odt file to doc or pdf format.
+
+;;; See README.org file that comes with this library for answers to
+;;; FAQs and more information on using this library.
+
+;;; Use M-x `org-odt-unit-test' for test driving the odt exporter
+
+;;; Code:
+
+(require 'org-exp)
+(require 'org-list)
+
+;;;###autoload
+(defun org-lparse-and-open (target-backend native-backend arg)
+  "Export the outline as HTML and immediately open it with a browser.
+If there is an active region, export only the region.
+The prefix ARG specifies how many levels of the outline should become
+headlines.  The default is 3.  Lower levels will become bulleted lists."
+  ;; (interactive "Mbackend: \nP")
+  (interactive
+   (let* ((input (if (featurep 'ido) 'ido-completing-read 'completing-read))
+	  (all-backends (org-lparse-all-backends))
+	  (target-backend
+	   (funcall input "Export to: " all-backends nil t nil))
+	  (native-backend
+	   (or
+	    ;; (and (org-lparse-backend-is-native-p target-backend)
+	    ;; 	    target-backend)
+	    (funcall input "Use Native backend:  "
+		     (cdr (assoc target-backend all-backends)) nil t nil))))
+     (list target-backend native-backend current-prefix-arg)))
+  (let (f (file-or-buf (org-lparse target-backend native-backend
+				   arg 'hidden)))
+    (when file-or-buf
+      (setq f (cond
+	       ((bufferp file-or-buf) buffer-file-name)
+	       ((file-exists-p file-or-buf) file-or-buf)
+	       (t (error "org-lparse-and-open: This shouldn't happen"))))
+      (message "Opening file %s" f)
+      (org-open-file f)
+      (when org-export-kill-product-buffer-when-displayed
+	(kill-buffer (current-buffer))))))
+
+;;;###autoload
+(defun org-lparse-batch (target-backend &optional native-backend)
+  "Call the function `org-lparse'.
+This function can be used in batch processing as:
+emacs   --batch
+        --load=$HOME/lib/emacs/org.el
+        --eval \"(setq org-export-headline-levels 2)\"
+        --visit=MyFile --funcall org-lparse-batch"
+  (setq native-backend (or native-backend target-backend))
+  (org-lparse target-backend native-backend
+	      org-export-headline-levels 'hidden))
+
+;;;###autoload
+(defun org-lparse-to-buffer (backend arg)
+  "Call `org-lparse` with output to a temporary buffer.
+No file is created.  The prefix ARG is passed through to `org-lparse'."
+  (interactive "Mbackend: \nP")
+  (let ((tempbuf (format "*Org %s Export*" (upcase backend))))
+      (org-lparse backend backend arg nil nil tempbuf)
+      (when org-export-show-temporary-export-buffer
+	(switch-to-buffer-other-window tempbuf))))
+
+;;;###autoload
+(defun org-replace-region-by (backend beg end)
+  "Assume the current region has org-mode syntax, and convert it to HTML.
+This can be used in any buffer.  For example, you could write an
+itemized list in org-mode syntax in an HTML buffer and then use this
+command to convert it."
+  (interactive "Mbackend: \nr")
+  (let (reg backend-string buf pop-up-frames)
+    (save-window-excursion
+      (if (org-mode-p)
+	  (setq backend-string (org-lparse-region backend beg end t 'string))
+	(setq reg (buffer-substring beg end)
+	      buf (get-buffer-create "*Org tmp*"))
+	(with-current-buffer buf
+	  (erase-buffer)
+	  (insert reg)
+	  (org-mode)
+	  (setq backend-string (org-lparse-region backend (point-min)
+						  (point-max) t 'string)))
+	(kill-buffer buf)))
+    (delete-region beg end)
+    (insert backend-string)))
+
+;;;###autoload
+(defun org-lparse-region (backend beg end &optional body-only buffer)
+  "Convert region from BEG to END in org-mode buffer to HTML.
+If prefix arg BODY-ONLY is set, omit file header, footer, and table of
+contents, and only produce the region of converted text, useful for
+cut-and-paste operations.
+If BUFFER is a buffer or a string, use/create that buffer as a target
+of the converted HTML.  If BUFFER is the symbol `string', return the
+produced HTML as a string and leave not buffer behind.  For example,
+a Lisp program could call this function in the following way:
+
+  (setq html (org-lparse-region \"html\" beg end t 'string))
+
+When called interactively, the output buffer is selected, and shown
+in a window.  A non-interactive call will only return the buffer."
+  (interactive "Mbackend: \nr\nP")
+  (when (org-called-interactively-p 'any)
+    (setq buffer (format "*Org %s Export*" (upcase backend))))
+  (let ((transient-mark-mode t) (zmacs-regions t)
+	ext-plist rtn)
+    (setq ext-plist (plist-put ext-plist :ignore-subtree-p t))
+    (goto-char end)
+    (set-mark (point)) ;; to activate the region
+    (goto-char beg)
+    (setq rtn (org-lparse backend backend nil nil ext-plist buffer body-only))
+    (if (fboundp 'deactivate-mark) (deactivate-mark))
+    (if (and (org-called-interactively-p 'any) (bufferp rtn))
+	(switch-to-buffer-other-window rtn)
+      rtn)))
+
+(defvar org-lparse-par-open nil)
+
+(defun org-lparse-should-inline-p (filename descp)
+   "Return non-nil if link FILENAME should be inlined.
+The decision to inline the FILENAME link is based on the current
+settings.  DESCP is the boolean of whether there was a link
+description.  See variables `org-export-html-inline-images' and
+`org-export-html-inline-image-extensions'."
+   (let ((inline-images (org-lparse-get 'INLINE-IMAGES))
+	 (inline-image-extensions
+	  (org-lparse-get 'INLINE-IMAGE-EXTENSIONS)))
+        (and (or (eq t inline-images) (and inline-images (not descp)))
+	     (org-file-image-p filename inline-image-extensions))))
+
+(defun org-lparse-format-org-link (line opt-plist)
+  "Return LINE with markup of Org mode links.
+OPT-PLIST is the export options list."
+  (let ((start 0)
+	(current-dir (if buffer-file-name
+			 (file-name-directory buffer-file-name)
+		       default-directory))
+	(link-validate (plist-get opt-plist :link-validation-function))
+	type id-file fnc
+	rpl path attr desc descp desc1 desc2 link
+	org-lparse-link-description-is-image)
+    (while (string-match org-bracket-link-analytic-regexp++ line start)
+      (setq org-lparse-link-description-is-image nil)
+      (setq start (match-beginning 0))
+      (setq path (save-match-data (org-link-unescape
+				   (match-string 3 line))))
+      (setq type (cond
+		  ((match-end 2) (match-string 2 line))
+		  ((save-match-data
+		     (or (file-name-absolute-p path)
+			 (string-match "^\\.\\.?/" path)))
+		   "file")
+		  (t "internal")))
+      (setq path (org-extract-attributes (org-link-unescape path)))
+      (setq attr (get-text-property 0 'org-attributes path))
+      (setq desc1 (if (match-end 5) (match-string 5 line))
+	    desc2 (if (match-end 2) (concat type ":" path) path)
+	    descp (and desc1 (not (equal desc1 desc2)))
+	    desc (or desc1 desc2))
+      ;; Make an image out of the description if that is so wanted
+      (when (and descp (org-file-image-p
+			desc (org-lparse-get 'INLINE-IMAGE-EXTENSIONS)))
+	(setq org-lparse-link-description-is-image t)
+	(save-match-data
+	  (if (string-match "^file:" desc)
+	      (setq desc (substring desc (match-end 0)))))
+	(save-match-data
+	  (setq desc (org-add-props
+			 (org-lparse-format 'INLINE-IMAGE desc)
+			 '(org-protected t)))))
+      (cond
+       ((equal type "internal")
+	(let
+	    ((frag-0
+	      (if (= (string-to-char path) ?#)
+		  (substring path 1)
+		path)))
+	  (setq rpl
+		(org-lparse-format
+		 'ORG-LINK opt-plist "" "" (org-solidify-link-text
+					    (save-match-data
+					      (org-link-unescape frag-0))
+					    nil) desc attr descp))))
+       ((and (equal type "id")
+	     (setq id-file (org-id-find-id-file path)))
+	;; This is an id: link to another file (if it was the same file,
+	;; it would have become an internal link...)
+	(save-match-data
+	  (setq id-file (file-relative-name
+			 id-file
+			 (file-name-directory org-current-export-file)))
+	  (setq rpl
+		(org-lparse-format
+		 'ORG-LINK opt-plist type id-file
+		 (concat (if (org-uuidgen-p path) "ID-") path)
+		 desc attr descp))))
+       ((member type '("http" "https"))
+	;; standard URL, can inline as image
+	(setq rpl
+	      (org-lparse-format
+	       'ORG-LINK opt-plist type path nil desc attr descp)))
+       ((member type '("ftp" "mailto" "news"))
+	;; standard URL, can't inline as image
+	(setq rpl
+	      (org-lparse-format
+	       'ORG-LINK opt-plist type path nil desc attr descp)))
+
+       ((string= type "coderef")
+	(setq rpl
+	      (org-lparse-format
+	       'ORG-LINK opt-plist type "" (format "coderef-%s" path)
+	       (format
+		(org-export-get-coderef-format
+		 path
+		 (and descp desc))
+		(cdr (assoc path org-export-code-refs))) nil descp)))
+
+       ((functionp (setq fnc (nth 2 (assoc type org-link-protocols))))
+	;; The link protocol has a function for format the link
+	(setq rpl
+	      (save-match-data
+		(funcall fnc (org-link-unescape path) desc1 'html))))
+
+       ((string= type "file")
+	;; FILE link
+	(save-match-data
+	  (let*
+	      ((components
+		(if
+		    (string-match "::\\(.*\\)" path)
+		    (list
+		     (replace-match "" t nil path)
+		     (match-string 1 path))
+		  (list path nil)))
+
+	       ;;The proper path, without a fragment
+	       (path-1
+		(first components))
+
+	       ;;The raw fragment
+	       (fragment-0
+		(second components))
+
+	       ;;Check the fragment.  If it can't be used as
+	       ;;target fragment we'll pass nil instead.
+	       (fragment-1
+		(if
+		    (and fragment-0
+			 (not (string-match "^[0-9]*$" fragment-0))
+			 (not (string-match "^\\*" fragment-0))
+			 (not (string-match "^/.*/$" fragment-0)))
+		    (org-solidify-link-text
+		     (org-link-unescape fragment-0))
+		  nil))
+	       (desc-2
+		;;Description minus "file:" and ".org"
+		(if (string-match "^file:" desc)
+		    (let
+			((desc-1 (replace-match "" t t desc)))
+		      (if (string-match "\\.org$" desc-1)
+			  (replace-match "" t t desc-1)
+			desc-1))
+		  desc)))
+
+	    (setq rpl
+		  (if
+		      (and
+		       (functionp link-validate)
+		       (not (funcall link-validate path-1 current-dir)))
+		      desc
+		    (org-lparse-format
+		     'ORG-LINK opt-plist "file" path-1 fragment-1
+		     desc-2 attr descp))))))
+
+       (t
+	;; just publish the path, as default
+	(setq rpl (concat "<i>&lt;" type ":"
+			  (save-match-data (org-link-unescape path))
+			  "&gt;</i>"))))
+      (setq line (replace-match rpl t t line)
+	    start (+ start (length rpl))))
+    line))
+
+(defmacro with-org-lparse-preserve-paragraph-state (&rest body)
+  `(let ((org-lparse-do-open-par org-lparse-par-open))
+     (org-lparse-end-paragraph)
+     ,@body
+     (when org-lparse-do-open-par
+       (org-lparse-begin-paragraph))))
+
+(defvar org-lparse-native-backends
+  '("xhtml" "odt")
+  "List of native backends registered with `org-lparse'.
+All native backends must implement a get routine and a mandatory
+set of callback routines.
+
+The get routine must be named as org-<backend>-get where backend
+is the name of the backend.  The exporter uses `org-lparse-get'
+and retrieves the backend-specific callback by querying for
+ENTITY-CONTROL and ENTITY-FORMAT variables.
+
+For the sake of illustration, the html backend implements
+`org-xhtml-get'.  It returns
+`org-xhtml-entity-control-callbacks-alist' and
+`org-xhtml-entity-format-callbacks-alist' as the values of
+ENTITY-CONTROL and ENTITY-FORMAT settings.")
+
+(defun org-lparse-get-other-backends (native-backend)
+  (org-lparse-backend-get native-backend 'OTHER-BACKENDS))
+
+(defun org-lparse-all-backends ()
+  (let (all-backends)
+    (flet ((add (other native)
+		(let ((val (assoc-string other all-backends t)))
+		  (if val (setcdr val (nconc (list native) (cdr val)))
+		    (push (cons other (list native)) all-backends)))))
+      (loop for backend in org-lparse-native-backends
+	    do (loop for other in (org-lparse-get-other-backends backend)
+		     do (add other backend))))
+    all-backends))
+
+(defun org-lparse-backend-is-native-p (backend)
+  (member backend org-lparse-native-backends))
+
+(defun org-lparse (target-backend native-backend arg
+				  &optional hidden ext-plist
+				  to-buffer body-only pub-dir)
+  "Export the outline to various formats.
+If there is an active region, export only the region. The outline
+is first exported to NATIVE-BACKEND and optionally converted to
+TARGET-BACKEND. See `org-lparse-native-backends' for list of
+known native backends. Each native backend can specify a
+converter and list of target backends it exports to using the
+CONVERT-PROCESS and OTHER-BACKENDS settings of it's get
+method. See `org-xhtml-get' for an illustrative example.
+
+ARG is a prefix argument that specifies how many levels of
+outline should become headlines.  The default is 3.  Lower levels
+will become bulleted lists.
+
+HIDDEN is obsolete and does nothing.
+
+EXT-PLIST is a property list that controls various aspects of
+export. The settings here override org-mode's default settings
+and but are inferior to file-local settings.
+
+TO-BUFFER dumps the exported lines to a buffer or a string
+instead of a file. If TO-BUFFER is the symbol `string' return the
+exported lines as a string.  If TO-BUFFER is non-nil, create a
+buffer with that name and export to that buffer.
+
+BODY-ONLY controls the presence of header and footer lines in
+exported text. If BODY-ONLY is non-nil, don't produce the file
+header and footer, simply return the content of <body>...</body>,
+without even the body tags themselves.
+
+PUB-DIR specifies the publishing directory."
+  (interactive
+   (let* ((input (if (featurep 'ido) 'ido-completing-read 'completing-read))
+	  (all-backends (org-lparse-all-backends))
+	  (target-backend
+	   (funcall input "Export to: " all-backends nil t nil))
+	  (native-backend
+	   (or
+	    ;; (and (org-lparse-backend-is-native-p target-backend)
+	    ;; 	    target-backend)
+	    (funcall input "Use Native backend:  "
+		     (cdr (assoc target-backend all-backends)) nil t nil))))
+     (list target-backend native-backend current-prefix-arg)))
+  (let* ((org-lparse-backend (intern native-backend))
+	 (org-lparse-other-backend (intern target-backend)))
+    (unless (org-lparse-backend-is-native-p native-backend)
+      (error "Don't know how to export natively to backend %s" native-backend))
+    (unless (or (not target-backend)
+		(equal target-backend native-backend)
+		(member target-backend (org-lparse-get 'OTHER-BACKENDS)))
+      (error "Don't know how to export to backend %s %s" target-backend
+	     (format "via %s" native-backend)))
+    (run-hooks 'org-export-first-hook)
+    (org-do-lparse arg hidden ext-plist to-buffer body-only pub-dir)))
+
+(defcustom org-export-convert-process
+  '("soffice" "-norestore" "-invisible" "-headless" "\"macro:///BasicODConverter.Main.Convert(%I,%f,%O)\"")
+  "Command to covert a Org exported format to other formats.
+The variable is an list of the form (PROCESS ARG1 ARG2 ARG3
+...).  Format specifiers used in the ARGs are replaced as below.
+%i input file name in full
+%I input file name as a URL
+%f format of the output file
+%o output file name in full
+%O output file name as a URL
+%d output dir in full
+%D output dir as a URL"
+  :group 'org-export)
+
+(defun org-export-convert (&optional in-file fmt)
+  "Convert file from one format to another using a converter.
+IN-FILE is the file to be converted.  If unspecified, it defaults
+to variable `buffer-file-name'.  FMT is the desired output format.  If the
+backend has registered a CONVERT-METHOD via it's get function
+then that converter is used.  Otherwise
+`org-export-conver-process' is used."
+  (interactive
+   (let* ((input (if (featurep 'ido) 'ido-completing-read 'completing-read))
+	  (in-file (read-file-name "File to be converted: "
+				   nil buffer-file-name t))
+	  (fmt (funcall input "Output format:  "
+			(or (ignore-errors
+			      (org-lparse-get-other-backends
+			       (file-name-extension in-file)))
+			    (org-lparse-all-backends))
+			nil nil nil)))
+     (list in-file fmt)))
+  (require 'browse-url)
+  (let* ((in-file (expand-file-name (or in-file buffer-file-name)))
+	 (fmt (or fmt "doc") )
+	 (out-file (concat (file-name-sans-extension in-file) "." fmt))
+	 (out-dir (file-name-directory in-file))
+	 (backend (when (boundp 'org-lparse-backend) org-lparse-backend))
+	 (convert-process
+	  (or (ignore-errors (org-lparse-backend-get backend 'CONVERT-METHOD))
+	      org-export-convert-process))
+	 program arglist)
+
+    (setq program (and convert-process (consp convert-process)
+		       (car convert-process)))
+    (unless (executable-find program)
+      (error "Unable to locate the converter %s"  program))
+
+    (setq arglist
+	  (mapcar (lambda (arg)
+		    (format-spec arg `((?i . ,in-file)
+				       (?I . ,(browse-url-file-url in-file))
+				       (?f . ,fmt)
+				       (?o . ,out-file)
+				       (?O . ,(browse-url-file-url out-file))
+				       (?d . ,out-dir)
+				       (?D . ,(browse-url-file-url out-dir)))))
+		  (cdr convert-process)))
+    (ignore-errors (delete-file out-file))
+
+    (message "Executing %s %s" program (mapconcat 'identity arglist " "))
+    (apply 'call-process program nil nil nil arglist)
+
+    (cond
+     ((file-exists-p out-file)
+      (message "Exported to %s using %s" out-file program)
+      out-file
+      ;; (set-buffer (find-file-noselect out-file))
+      )
+     (t
+      (message "Export to %s failed" out-file)
+      nil))))
+
+(defvar org-lparse-insert-tag-with-newlines 'both)
+
+;; Following variables are let-bound during `org-lparse'
+(defvar org-lparse-dyn-first-heading-pos)
+(defvar org-lparse-toc)
+(defvar org-lparse-entity-control-callbacks-alist)
+(defvar org-lparse-entity-format-callbacks-alist)
+(defvar org-lparse-backend)
+(defvar org-lparse-body-only)
+(defvar org-lparse-to-buffer)
+(defun org-do-lparse (arg &optional hidden ext-plist
+			  to-buffer body-only pub-dir)
+  "Export the outline to various formats.
+See `org-lparse' for more information. This function is a
+html-agnostic version of the `org-export-as-html' function in 7.5
+version."
+  ;; Make sure we have a file name when we need it.
+  (when (and (not (or to-buffer body-only))
+	     (not buffer-file-name))
+    (if (buffer-base-buffer)
+	(org-set-local 'buffer-file-name
+		       (with-current-buffer (buffer-base-buffer)
+			 buffer-file-name))
+      (error "Need a file name to be able to export")))
+
+  (org-lparse-warn
+   (format "Exporting to %s using org-lparse..."
+	   (upcase (symbol-name
+		    (or org-lparse-backend org-lparse-other-backend)))))
+
+  (setq-default org-todo-line-regexp org-todo-line-regexp)
+  (setq-default org-deadline-line-regexp org-deadline-line-regexp)
+  (setq-default org-done-keywords org-done-keywords)
+  (setq-default org-maybe-keyword-time-regexp org-maybe-keyword-time-regexp)
+  (let* (org-lparse-encode-pending
+	 org-lparse-par-open
+	 org-lparse-outline-text-open
+	 (org-lparse-latex-fragment-fallback ; currently used only by
+					; odt exporter
+	  (or (ignore-errors (org-lparse-get 'LATEX-FRAGMENT-FALLBACK))
+	      (if (and (org-check-external-command "latex" "" t)
+		       (org-check-external-command "dvipng" "" t))
+		  'dvipng
+		'verbatim)))
+	 (org-lparse-insert-tag-with-newlines 'both)
+	 (org-lparse-to-buffer to-buffer)
+	 (org-lparse-body-only body-only)
+	 (org-lparse-entity-control-callbacks-alist
+	  (org-lparse-get 'ENTITY-CONTROL))
+	 (org-lparse-entity-format-callbacks-alist
+	  (org-lparse-get 'ENTITY-FORMAT))
+	 (opt-plist
+	  (org-export-process-option-filters
+	   (org-combine-plists (org-default-export-plist)
+			       ext-plist
+			       (org-infile-export-plist))))
+	 (body-only (or body-only (plist-get opt-plist :body-only)))
+	 valid org-lparse-dyn-first-heading-pos
+	 (odd org-odd-levels-only)
+	 (region-p (org-region-active-p))
+	 (rbeg (and region-p (region-beginning)))
+	 (rend (and region-p (region-end)))
+	 (subtree-p
+	  (if (plist-get opt-plist :ignore-subtree-p)
+	      nil
+	    (when region-p
+	      (save-excursion
+		(goto-char rbeg)
+		(and (org-at-heading-p)
+		     (>= (org-end-of-subtree t t) rend))))))
+	 (level-offset (if subtree-p
+			   (save-excursion
+			     (goto-char rbeg)
+			     (+ (funcall outline-level)
+				(if org-odd-levels-only 1 0)))
+			 0))
+	 (opt-plist (setq org-export-opt-plist
+			  (if subtree-p
+			      (org-export-add-subtree-options opt-plist rbeg)
+			    opt-plist)))
+	 ;; The following two are dynamically scoped into other
+	 ;; routines below.
+	 (org-current-export-dir
+	  (or pub-dir (org-lparse-get 'EXPORT-DIR opt-plist)))
+	 (org-current-export-file buffer-file-name)
+	 (level 0) (line "") (origline "") txt todo
+	 (umax nil)
+	 (umax-toc nil)
+	 (filename (if to-buffer nil
+		     (expand-file-name
+		      (concat
+		       (file-name-sans-extension
+			(or (and subtree-p
+				 (org-entry-get (region-beginning)
+						"EXPORT_FILE_NAME" t))
+			    (file-name-nondirectory buffer-file-name)))
+		       "." (org-lparse-get 'FILE-NAME-EXTENSION opt-plist))
+		      (file-name-as-directory
+		       (or pub-dir (org-lparse-get 'EXPORT-DIR opt-plist))))))
+	 (current-dir (if buffer-file-name
+			  (file-name-directory buffer-file-name)
+			default-directory))
+	 (buffer (if to-buffer
+		     (cond
+		      ((eq to-buffer 'string)
+		       (get-buffer-create (org-lparse-get 'EXPORT-BUFFER-NAME)))
+		      (t (get-buffer-create to-buffer)))
+		   (find-file-noselect
+		    (or (let ((f (org-lparse-get 'INIT-METHOD)))
+			  (and f (functionp f) (funcall f filename)))
+			filename))))
+	 (org-levels-open (make-vector org-level-max nil))
+	 (date (plist-get opt-plist :date))
+	 (date (cond
+		((and date (string-match "%" date))
+		 (format-time-string date))
+		(date date)
+		(t (format-time-string "%Y-%m-%d %T %Z"))))
+	 (dummy (setq opt-plist (plist-put opt-plist :effective-date date)))
+	 (title       (org-xml-encode-org-text-skip-links
+		       (or (and subtree-p (org-export-get-title-from-subtree))
+			   (plist-get opt-plist :title)
+			   (and (not body-only)
+				(not
+				 (plist-get opt-plist :skip-before-1st-heading))
+				(org-export-grab-title-from-buffer))
+			   (and buffer-file-name
+				(file-name-sans-extension
+				 (file-name-nondirectory buffer-file-name)))
+			   "UNTITLED")))
+	 (dummy (setq opt-plist (plist-put opt-plist :title title)))
+	 (html-table-tag (plist-get opt-plist :html-table-tag))
+	 (quote-re0   (concat "^[ \t]*" org-quote-string "\\>"))
+	 (quote-re    (concat "^\\(\\*+\\)\\([ \t]+" org-quote-string "\\>\\)"))
+	 (org-lparse-dyn-current-environment nil)
+	 ;; Get the language-dependent settings
+	 (lang-words (or (assoc (plist-get opt-plist :language)
+				org-export-language-setup)
+			 (assoc "en" org-export-language-setup)))
+	 (dummy (setq opt-plist (plist-put opt-plist :lang-words lang-words)))
+	 (head-count  0) cnt
+	 (start       0)
+	 (coding-system-for-write
+	  (or (ignore-errors (org-lparse-get 'CODING-SYSTEM-FOR-WRITE))
+	      (and (boundp 'buffer-file-coding-system)
+		   buffer-file-coding-system)))
+	 (save-buffer-coding-system
+	  (or (ignore-errors (org-lparse-get 'CODING-SYSTEM-FOR-SAVE))
+	      (and (boundp 'buffer-file-coding-system)
+		   buffer-file-coding-system)))
+	 (region
+	  (buffer-substring
+	   (if region-p (region-beginning) (point-min))
+	   (if region-p (region-end) (point-max))))
+	 (org-export-have-math nil)
+	 (org-export-footnotes-seen nil)
+	 (org-export-footnotes-data (org-footnote-all-labels 'with-defs))
+	 (org-footnote-insert-pos-for-preprocessor 'point-min)
+	 (lines
+	  (org-split-string
+	   (org-export-preprocess-string
+	    region
+	    :emph-multiline t
+	    :for-backend (if (equal org-lparse-backend 'xhtml) ; hack
+			     'html
+			   org-lparse-backend)
+	    :skip-before-1st-heading
+	    (plist-get opt-plist :skip-before-1st-heading)
+	    :drawers (plist-get opt-plist :drawers)
+	    :todo-keywords (plist-get opt-plist :todo-keywords)
+	    :tasks (plist-get opt-plist :tasks)
+	    :tags (plist-get opt-plist :tags)
+	    :priority (plist-get opt-plist :priority)
+	    :footnotes (plist-get opt-plist :footnotes)
+	    :timestamps (plist-get opt-plist :timestamps)
+	    :archived-trees
+	    (plist-get opt-plist :archived-trees)
+	    :select-tags (plist-get opt-plist :select-tags)
+	    :exclude-tags (plist-get opt-plist :exclude-tags)
+	    :add-text
+	    (plist-get opt-plist :text)
+	    :LaTeX-fragments
+	    (plist-get opt-plist :LaTeX-fragments))
+	   "[\r\n]"))
+	 table-open
+	 table-buffer table-orig-buffer
+	 ind
+	 rpl path attr desc descp desc1 desc2 link
+	 snumber fnc
+	 footnotes footref-seen
+	 org-lparse-output-buffer
+	 org-lparse-footnote-definitions
+	 org-lparse-footnote-number
+	 org-lparse-footnote-buffer
+	 org-lparse-toc
+	 href
+	 )
+
+    (let ((inhibit-read-only t))
+      (org-unmodified
+       (remove-text-properties (point-min) (point-max)
+			       '(:org-license-to-kill t))))
+
+    (message "Exporting...")
+    (org-init-section-numbers)
+
+    ;; Switch to the output buffer
+    (setq org-lparse-output-buffer buffer)
+    (set-buffer org-lparse-output-buffer)
+    (let ((inhibit-read-only t)) (erase-buffer))
+    (fundamental-mode)
+    (org-install-letbind)
+
+    (and (fboundp 'set-buffer-file-coding-system)
+	 (set-buffer-file-coding-system coding-system-for-write))
+
+    (let ((case-fold-search nil)
+	  (org-odd-levels-only odd))
+      ;; create local variables for all options, to make sure all called
+      ;; functions get the correct information
+      (mapc (lambda (x)
+	      (set (make-local-variable (nth 2 x))
+		   (plist-get opt-plist (car x))))
+	    org-export-plist-vars)
+      (setq umax (if arg (prefix-numeric-value arg)
+		   org-export-headline-levels))
+      (setq umax-toc (if (integerp org-export-with-toc)
+			 (min org-export-with-toc umax)
+		       umax))
+
+      (when (and org-export-with-toc (not body-only))
+	(setq lines (org-lparse-prepare-toc
+		     lines level-offset opt-plist umax-toc)))
+
+      (unless body-only
+	(org-lparse-begin 'DOCUMENT-CONTENT opt-plist)
+	(org-lparse-begin 'DOCUMENT-BODY opt-plist))
+
+      (setq head-count 0)
+      (org-init-section-numbers)
+
+      (org-lparse-begin-paragraph)
+
+      (while (setq line (pop lines) origline line)
+	(catch 'nextline
+	  (when (and (org-lparse-current-environment-p 'quote)
+		     (string-match "^\\*+ " line))
+	    (org-lparse-end-environment 'quote))
+
+	  (when (org-lparse-current-environment-p 'quote)
+	    (org-lparse-insert 'LINE line)
+	    (throw 'nextline nil))
+
+	  ;; Fixed-width, verbatim lines (examples)
+	  (when (and org-export-with-fixed-width
+		     (string-match "^[ \t]*:\\(\\([ \t]\\|$\\)\\(.*\\)\\)" line))
+	    (when (not (org-lparse-current-environment-p 'fixedwidth))
+	      (org-lparse-begin-environment 'fixedwidth))
+	    (org-lparse-insert 'LINE (match-string 3 line))
+	    (when (or (not lines)
+		      (not (string-match "^[ \t]*:\\(\\([ \t]\\|$\\)\\(.*\\)\\)"
+					 (car lines))))
+	      (org-lparse-end-environment 'fixedwidth))
+	    (throw 'nextline nil))
+
+	  ;; Notes: The baseline version of org-html.el (git commit
+	  ;; 3d802e), while encoutering a *line-long* protected text,
+	  ;; does one of the following two things based on the state
+	  ;; of the export buffer.
+
+	  ;; 1. If a paragraph element has just been opened and
+	  ;;    contains only whitespace as content, insert the
+	  ;;    protected text as part of the previous paragraph.
+
+	  ;; 2. If the paragraph element has already been opened and
+	  ;;    contains some valid content insert the protected text
+	  ;;    as part of the current paragraph.
+
+	  ;; I think --->
+
+	  ;; Scenario 1 mentioned above kicks in when a block of
+	  ;; protected text has to be inserted enbloc. For example,
+	  ;; this happens, when inserting an source or example block
+	  ;; or preformatted content enclosed in #+backend,
+	  ;; #+begin_bakend ... #+end_backend)
+
+	  ;; Scenario 2 mentioned above kicks in when the protected
+	  ;; text is part of a running sentence. For example this
+	  ;; happens in the case of an *multiline* LaTeX equation that
+	  ;; needs to be inserted verbatim.
+
+	  ;; org-html.el in the master branch seems to do some
+	  ;; jugglery by moving paragraphs around. Inorder to make
+	  ;; these changes backend-agnostic introduce a new text
+	  ;; property org-native-text and impose the added semantics
+	  ;; that these protected blocks appear outside of a
+	  ;; conventional paragraph element.
+	  ;;
+	  ;; Extra Note: Check whether org-example and org-native-text
+	  ;; are entirely equivalent.
+
+	  ;; Fixes bug reported by Christian Moe concerning verbatim
+	  ;; LaTeX fragments.
+	  ;; on git commit 533ba3f90250a1f25f494c390d639ea6274f235c
+	  ;; http://repo.or.cz/w/org-mode/org-jambu.git/shortlog/refs/heads/staging
+	  ;; See http://lists.gnu.org/archive/html/emacs-orgmode/2011-03/msg01379.html
+
+	  ;; Native Text
+	  (when (and (get-text-property 0 'org-native-text line)
+		     ;; Make sure it is the entire line that is protected
+		     (not (< (or (next-single-property-change
+				  0 'org-native-text line) 10000)
+			     (length line))))
+	    (let ((ind (get-text-property 0 'original-indentation line)))
+	      (org-lparse-begin-environment 'native)
+	      (org-lparse-insert 'LINE line)
+	      (while (and lines
+			  (or (= (length (car lines)) 0)
+			      (not ind)
+			      (equal ind (get-text-property
+					  0 'original-indentation (car lines))))
+			  (or (= (length (car lines)) 0)
+			      (get-text-property 0 'org-native-text (car lines))))
+		(org-lparse-insert 'LINE (pop lines)))
+	      (org-lparse-end-environment 'native))
+	    (throw 'nextline nil))
+
+	  ;; Protected HTML
+	  (when (and (get-text-property 0 'org-protected line)
+		     ;; Make sure it is the entire line that is protected
+		     (not (< (or (next-single-property-change
+				  0 'org-protected line) 10000)
+			     (length line))))
+	    (let ((ind (get-text-property 0 'original-indentation line)))
+	      (org-lparse-insert 'LINE line)
+	      (while (and lines
+			  (or (= (length (car lines)) 0)
+			      (not ind)
+			      (equal ind (get-text-property
+					  0 'original-indentation (car lines))))
+			  (or (= (length (car lines)) 0)
+			      (get-text-property 0 'org-protected (car lines))))
+		(org-lparse-insert 'LINE (pop lines))))
+	    (throw 'nextline nil))
+
+	  ;; Blockquotes, verse, and center
+	  (when (string-match  "^ORG-\\(.+\\)-\\(START\\|END\\)$" line)
+	    (let* ((style (intern (downcase (match-string 1 line))))
+		   (f (cdr (assoc (match-string 2 line)
+				  '(("START" . org-lparse-begin-environment)
+				    ("END" . org-lparse-end-environment))))))
+	      (when (memq style '(blockquote verse center))
+		(funcall f style)
+		(throw 'nextline nil))))
+
+	  (run-hooks 'org-export-html-after-blockquotes-hook)
+	  (when (org-lparse-current-environment-p 'verse)
+	    (let ((i (org-get-string-indentation line)))
+	      (if (> i 0)
+		  (setq line (concat
+			      (let ((org-lparse-encode-pending t))
+				(org-lparse-format 'SPACES (* 2 i)))
+			      " " (org-trim line))))
+	      (unless (string-match "\\\\\\\\[ \t]*$" line)
+		(setq line (concat line "\\\\")))))
+
+	  ;; make targets to anchors
+	  (setq start 0)
+	  (while (string-match
+		  "<<<?\\([^<>]*\\)>>>?\\((INVISIBLE)\\)?[ \t]*\n?" line start)
+	    (cond
+	     ((get-text-property (match-beginning 1) 'org-protected line)
+	      (setq start (match-end 1)))
+	     ((match-end 2)
+	      (setq line (replace-match
+			  (let ((org-lparse-encode-pending t))
+			    (org-lparse-format
+			     'ANCHOR "" (org-solidify-link-text
+					 (match-string 1 line))))
+			  t t line)))
+	     ((and org-export-with-toc (equal (string-to-char line) ?*))
+	      ;; FIXME: NOT DEPENDENT on TOC?????????????????????
+	      (setq line (replace-match
+			  (let ((org-lparse-encode-pending t))
+			    (org-lparse-format
+			     'FONTIFY (match-string 1 line) "target"))
+			  ;; (concat "@<i>" (match-string 1 line) "@</i> ")
+			  t t line)))
+	     (t
+	      (setq line (replace-match
+			  (concat
+			   (let ((org-lparse-encode-pending t))
+			     (org-lparse-format
+			      'ANCHOR (match-string 1 line)
+			      (org-solidify-link-text (match-string 1 line))
+			      "target")) " ")
+			  t t line)))))
+
+	  (let ((org-lparse-encode-pending t))
+	    (setq line (org-lparse-handle-time-stamps line)))
+
+	  ;; replace "&" by "&amp;", "<" and ">" by "&lt;" and "&gt;"
+	  ;; handle @<..> HTML tags (replace "@&gt;..&lt;" by "<..>")
+	  ;; Also handle sub_superscripts and checkboxes
+	  (or (string-match org-table-hline-regexp line)
+	      (string-match "^[ \t]*\\([+]-\\||[ ]\\)[-+ |]*[+|][ \t]*$" line)
+	      (setq line (org-xml-encode-org-text-skip-links line)))
+
+	  (setq line (org-lparse-format-org-link line opt-plist))
+
+	  ;; TODO items
+	  (if (and (string-match org-todo-line-regexp line)
+		   (match-beginning 2))
+	      (setq line (concat
+			  (substring line 0 (match-beginning 2))
+			  (org-lparse-format 'TODO (match-string 2 line))
+			  (substring line (match-end 2)))))
+
+	  ;; Does this contain a reference to a footnote?
+	  (when org-export-with-footnotes
+	    (setq start 0)
+	    (while (string-match "\\([^* \t].*?\\)[ \t]*\\[\\([0-9]+\\)\\]" line start)
+	      ;; Discard protected matches not clearly identified as
+	      ;; footnote markers.
+	      (if (or (get-text-property (match-beginning 2) 'org-protected line)
+		      (not (get-text-property (match-beginning 2) 'org-footnote line)))
+		  (setq start (match-end 2))
+		(let ((n (match-string 2 line)) refcnt a)
+		  (if (setq a (assoc n footref-seen))
+		      (progn
+			(setcdr a (1+ (cdr a)))
+			(setq refcnt (cdr a)))
+		    (setq refcnt 1)
+		    (push (cons n 1) footref-seen))
+		  (setq line
+			(replace-match
+			 (concat
+			  (or (match-string 1 line) "")
+			  (org-lparse-format
+			   'FOOTNOTE-REFERENCE
+			   n (cdr (assoc n org-lparse-footnote-definitions))
+			   refcnt)
+			  ;; If another footnote is following the
+			  ;; current one, add a separator.
+			  (if (save-match-data
+				(string-match "\\`\\[[0-9]+\\]"
+					      (substring line (match-end 0))))
+			      (ignore-errors
+				(org-lparse-get 'FOOTNOTE-SEPARATOR))
+			    ""))
+			 t t line))))))
+
+	  (cond
+	   ((string-match "^\\(\\*+\\)[ \t]+\\(.*\\)" line)
+	    ;; This is a headline
+	    (setq level (org-tr-level (- (match-end 1) (match-beginning 1)
+					 level-offset))
+		  txt (match-string 2 line))
+	    (if (string-match quote-re0 txt)
+		(setq txt (replace-match "" t t txt)))
+	    (if (<= level (max umax umax-toc))
+		(setq head-count (+ head-count 1)))
+	    (unless org-lparse-dyn-first-heading-pos
+	      (setq org-lparse-dyn-first-heading-pos (point)))
+	    (org-lparse-begin-level level txt umax head-count)
+
+	    ;; QUOTES
+	    (when (string-match quote-re line)
+	      (org-lparse-begin-environment 'quote)))
+
+	   ((and org-export-with-tables
+		 (string-match "^\\([ \t]*\\)\\(|\\|\\+-+\\+\\)" line))
+	    (when (not table-open)
+	      ;; New table starts
+	      (setq table-open t table-buffer nil table-orig-buffer nil))
+
+	    ;; Accumulate lines
+	    (setq table-buffer (cons line table-buffer)
+		  table-orig-buffer (cons origline table-orig-buffer))
+	    (when (or (not lines)
+		      (not (string-match "^\\([ \t]*\\)\\(|\\|\\+-+\\+\\)"
+					 (car lines))))
+	      (setq table-open nil
+		    table-buffer (nreverse table-buffer)
+		    table-orig-buffer (nreverse table-orig-buffer))
+	      (org-lparse-end-paragraph)
+	      (org-lparse-insert 'TABLE table-buffer table-orig-buffer)))
+
+	   ;; Normal lines
+
+	   (t
+	    ;; This line either is list item or end a list.
+	    (when (get-text-property 0 'list-item line)
+	      (setq line (org-lparse-export-list-line
+			  line
+			  (get-text-property 0 'list-item line)
+			  (get-text-property 0 'list-struct line)
+			  (get-text-property 0 'list-prevs line))))
+
+	    ;; Horizontal line
+	    (when (string-match "^[ \t]*-\\{5,\\}[ \t]*$" line)
+	      (with-org-lparse-preserve-paragraph-state
+	       (org-lparse-insert 'HORIZONTAL-LINE))
+	      (throw 'nextline nil))
+
+	    ;; Empty lines start a new paragraph.  If hand-formatted lists
+	    ;; are not fully interpreted, lines starting with "-", "+", "*"
+	    ;; also start a new paragraph.
+	    (when (string-match "^ [-+*]-\\|^[ \t]*$" line)
+	      (when org-lparse-footnote-number
+		(org-lparse-end-footnote-definition org-lparse-footnote-number)
+		(setq org-lparse-footnote-number nil))
+	      (org-lparse-begin-paragraph))
+
+	    ;; Is this the start of a footnote?
+	    (when org-export-with-footnotes
+	      (when (and (boundp 'footnote-section-tag-regexp)
+			 (string-match (concat "^" footnote-section-tag-regexp)
+				       line))
+		;; ignore this line
+		(throw 'nextline nil))
+	      (when (string-match "^[ \t]*\\[\\([0-9]+\\)\\]" line)
+		(org-lparse-end-paragraph)
+		(setq org-lparse-footnote-number (match-string 1 line))
+		(setq line (replace-match "" t t line))
+		(org-lparse-begin-footnote-definition org-lparse-footnote-number)))
+	    ;; Check if the line break needs to be conserved
+	    (cond
+	     ((string-match "\\\\\\\\[ \t]*$" line)
+	      (setq line (replace-match
+			  (org-lparse-format 'LINE-BREAK)
+			  t t line)))
+	     (org-export-preserve-breaks
+	      (setq line (concat line (org-lparse-format 'LINE-BREAK)))))
+
+	    ;; Check if a paragraph should be started
+	    (let ((start 0))
+	      (while (and org-lparse-par-open
+			  (string-match "\\\\par\\>" line start))
+		(error "FIXME")
+		;; Leave a space in the </p> so that the footnote matcher
+		;; does not see this.
+		(if (not (get-text-property (match-beginning 0)
+					    'org-protected line))
+		    (setq line (replace-match "</p ><p >" t t line)))
+		(setq start (match-end 0))))
+
+	    (org-lparse-insert 'LINE line)))))
+
+      ;; Properly close all local lists and other lists
+      (when (org-lparse-current-environment-p 'quote)
+	(org-lparse-end-environment 'quote))
+
+      (org-lparse-end-level 1 umax)
+
+      ;; the </div> to close the last text-... div.
+      (when (and (> umax 0) org-lparse-dyn-first-heading-pos)
+	(org-lparse-end-outline-text-or-outline))
+
+      (org-lparse-end 'DOCUMENT-BODY opt-plist)
+      (unless body-only
+	(org-lparse-end 'DOCUMENT-CONTENT))
+
+      (unless (plist-get opt-plist :buffer-will-be-killed)
+	(set-auto-mode t))
+
+      (org-lparse-end 'EXPORT)
+
+      (goto-char (point-min))
+      (or (org-export-push-to-kill-ring
+	   (upcase (symbol-name org-lparse-backend)))
+	  (message "Exporting... done"))
+
+      (cond
+       ((not to-buffer)
+	(let ((f (org-lparse-get 'SAVE-METHOD)))
+	  (or (and f (functionp f) (funcall f filename opt-plist))
+	      (save-buffer)))
+	(or (when (and (boundp 'org-lparse-other-backend)
+		       org-lparse-other-backend
+		       (not (equal org-lparse-backend org-lparse-other-backend)))
+	      (let ((org-export-convert-process (org-lparse-get 'CONVERT-METHOD)))
+		(when org-export-convert-process
+		  (org-export-convert buffer-file-name
+				      (symbol-name org-lparse-other-backend)))))
+	    (current-buffer)))
+       ((eq to-buffer 'string)
+	(prog1 (buffer-substring (point-min) (point-max))
+	  (kill-buffer (current-buffer))))
+       (t (current-buffer))))))
+
+(defun org-lparse-format-table (lines olines)
+  "Retuns backend-specific code for org-type and table-type
+tables."
+  (if (stringp lines)
+      (setq lines (org-split-string lines "\n")))
+  (if (string-match "^[ \t]*|" (car lines))
+      ;; A normal org table
+      (org-lparse-format-org-table lines nil)
+    ;; Table made by table.el
+    (or (org-lparse-format-table-table-using-table-generate-source
+	 org-lparse-backend olines
+	 (not org-export-prefer-native-exporter-for-tables))
+	;; We are here only when table.el table has NO col or row
+	;; spanning and the user prefers using org's own converter for
+	;; exporting of such simple table.el tables.
+	(org-lparse-format-table-table lines))))
+
+(defun org-lparse-table-get-colalign-info (lines)
+  (let ((forced-aligns (org-find-text-property-in-string
+			'org-forced-aligns (car lines))))
+    (when (and forced-aligns org-table-clean-did-remove-column)
+      (setq forced-aligns
+	    (mapcar (lambda (x) (cons (1- (car x)) (cdr x))) forced-aligns)))
+
+    forced-aligns))
+
+(defvar org-lparse-table-style)
+(defvar org-lparse-table-ncols)
+(defvar org-lparse-table-rownum)
+(defvar org-lparse-table-is-styled)
+(defvar org-lparse-table-begin-marker)
+(defvar org-lparse-table-num-numeric-items-per-column)
+(defvar org-lparse-table-colalign-info)
+(defvar org-lparse-table-colalign-vector)
+
+;; Following variables are defined in org-table.el
+(defvar org-table-number-fraction)
+(defvar org-table-number-regexp)
+
+(defun org-lparse-do-format-org-table (lines &optional splice)
+  "Format a org-type table into backend-specific code.
+LINES is a list of lines.  Optional argument SPLICE means, do not
+insert header and surrounding <table> tags, just format the lines.
+Optional argument NO-CSS means use XHTML attributes instead of CSS
+for formatting.  This is required for the DocBook exporter."
+  (require 'org-table)
+  ;; Get rid of hlines at beginning and end
+  (if (string-match "^[ \t]*|-" (car lines)) (setq lines (cdr lines)))
+  (setq lines (nreverse lines))
+  (if (string-match "^[ \t]*|-" (car lines)) (setq lines (cdr lines)))
+  (setq lines (nreverse lines))
+  (when org-export-table-remove-special-lines
+    ;; Check if the table has a marking column.  If yes remove the
+    ;; column and the special lines
+    (setq lines (org-table-clean-before-export lines)))
+
+  (let* ((caption (org-find-text-property-in-string 'org-caption (car lines)))
+	 (caption (and caption (org-xml-encode-org-text caption)))
+	 (label (org-find-text-property-in-string 'org-label (car lines)))
+	 (org-lparse-table-colalign-info (org-lparse-table-get-colalign-info lines))
+	 (attributes (org-find-text-property-in-string 'org-attributes
+						       (car lines)))
+	 (head (and org-export-highlight-first-table-line
+		    (delq nil (mapcar
+			       (lambda (x) (string-match "^[ \t]*|-" x))
+			       (cdr lines)))))
+	 (org-lparse-table-rownum -1) org-lparse-table-ncols i (cnt 0)
+	 tbopen line fields
+	 org-lparse-table-cur-rowgrp-is-hdr
+	 org-lparse-table-rowgrp-open
+	 org-lparse-table-num-numeric-items-per-column
+	 org-lparse-table-colalign-vector n
+	 org-lparse-table-rowgrp-info
+	 org-lparse-table-begin-marker
+	 (org-lparse-table-style 'org-table)
+	 org-lparse-table-is-styled)
+    (cond
+     (splice
+      (setq org-lparse-table-is-styled nil)
+      (while (setq line (pop lines))
+	(unless (string-match "^[ \t]*|-" line)
+	  (insert
+	   (org-lparse-format-table-row
+	    (org-split-string line "[ \t]*|[ \t]*")) "\n"))))
+     (t
+      (setq org-lparse-table-is-styled t)
+      (org-lparse-begin 'TABLE caption label attributes)
+      (setq org-lparse-table-begin-marker (point))
+      (org-lparse-begin-table-rowgroup head)
+      (while (setq line (pop lines))
+	(cond
+	 ((string-match "^[ \t]*|-" line)
+	  (when lines (org-lparse-begin-table-rowgroup)))
+	 (t
+	  (insert
+	   (org-lparse-format-table-row
+	    (org-split-string line "[ \t]*|[ \t]*")) "\n"))))
+      (org-lparse-end 'TABLE-ROWGROUP)
+      (org-lparse-end-table)))))
+
+(defun org-lparse-format-org-table (lines &optional splice)
+  (with-temp-buffer
+    (org-lparse-do-format-org-table lines splice)
+    (buffer-substring-no-properties (point-min) (point-max))))
+
+(defun org-lparse-do-format-table-table (lines)
+  "Format a table generated by table.el into backend-specific code.
+This conversion does *not* use `table-generate-source' from table.el.
+This has the advantage that Org-mode's HTML conversions can be used.
+But it has the disadvantage, that no cell- or row-spanning is allowed."
+  (let (line field-buffer
+	     (org-lparse-table-cur-rowgrp-is-hdr
+	      org-export-highlight-first-table-line)
+	     (caption nil)
+	     (attributes nil)
+	     (label nil)
+	     (org-lparse-table-style 'table-table)
+	     (org-lparse-table-is-styled nil)
+	     fields org-lparse-table-ncols i (org-lparse-table-rownum -1)
+	     (empty (org-lparse-format 'SPACES 1)))
+    (org-lparse-begin 'TABLE caption label attributes)
+    (while (setq line (pop lines))
+      (cond
+       ((string-match "^[ \t]*\\+-" line)
+	(when field-buffer
+	  (let ((org-export-table-row-tags '("<tr>" . "</tr>"))
+		;; (org-export-html-table-use-header-tags-for-first-column nil)
+		)
+	    (insert (org-lparse-format-table-row field-buffer empty)))
+	  (setq org-lparse-table-cur-rowgrp-is-hdr nil)
+	  (setq field-buffer nil)))
+       (t
+	;; Break the line into fields and store the fields
+	(setq fields (org-split-string line "[ \t]*|[ \t]*"))
+	(if field-buffer
+	    (setq field-buffer (mapcar
+				(lambda (x)
+				  (concat x (org-lparse-format 'LINE-BREAK)
+					  (pop fields)))
+				field-buffer))
+	  (setq field-buffer fields)))))
+    (org-lparse-end-table)))
+
+(defun org-lparse-format-table-table (lines)
+  (with-temp-buffer
+    (org-lparse-do-format-table-table lines)
+    (buffer-substring-no-properties (point-min) (point-max))))
+
+(defun org-lparse-format-table-table-using-table-generate-source (backend
+								 lines
+								 &optional
+								 spanned-only)
+  "Format a table into BACKEND, using `table-generate-source' from table.el.
+Use SPANNED-ONLY to suppress exporting of simple table.el tables.
+
+When SPANNED-ONLY is nil, all table.el tables are exported.  When
+SPANNED-ONLY is non-nil, only tables with either row or column
+spans are exported.
+
+This routine returns the generated source or nil as appropriate.
+
+Refer docstring of `org-export-prefer-native-exporter-for-tables'
+for further information."
+  (require 'table)
+  (with-current-buffer (get-buffer-create " org-tmp1 ")
+    (erase-buffer)
+    (insert (mapconcat 'identity lines "\n"))
+    (goto-char (point-min))
+    (if (not (re-search-forward "|[^+]" nil t))
+	(error "Error processing table"))
+    (table-recognize-table)
+    (when (or (not spanned-only)
+	      (let* ((dim (table-query-dimension))
+		     (c (nth 4 dim)) (r (nth 5 dim)) (cells (nth 6 dim)))
+		(not (= (* c r) cells))))
+      (with-current-buffer (get-buffer-create " org-tmp2 ") (erase-buffer))
+      (cond
+       ((member backend table-source-languages)
+	(table-generate-source backend " org-tmp2 ")
+	(set-buffer " org-tmp2 ")
+	(buffer-substring (point-min) (point-max)))
+       (t
+	;; table.el doesn't support the given backend. Currently this
+	;; happens in case of odt export.  Strip the table from the
+	;; generated document. A better alternative would be to embed
+	;; the table as ascii text in the output document.
+	(org-lparse-warn
+	 (concat
+	  "Found table.el-type table in the source org file. "
+	  (format "table.el doesn't support %s backend. "
+		  (upcase (symbol-name backend)))
+	  "Skipping ahead ..."))
+	"")))))
+
+(defun org-lparse-handle-time-stamps (s)
+  "Format time stamps in string S, or remove them."
+  (catch 'exit
+    (let (r b)
+      (while (string-match org-maybe-keyword-time-regexp s)
+	(or b (setq b (substring s 0 (match-beginning 0))))
+	(setq r (concat
+		 r (substring s 0 (match-beginning 0))
+		 (org-lparse-format
+		  'FONTIFY
+		  (concat
+		   (if (match-end 1)
+		       (org-lparse-format
+			'FONTIFY
+			(match-string 1 s) "timestamp-kwd"))
+		   (org-lparse-format
+		    'FONTIFY
+		    (substring (org-translate-time (match-string 3 s)) 1 -1)
+		    "timestamp"))
+		  "timestamp-wrapper"))
+	      s (substring s (match-end 0))))
+      ;; Line break if line started and ended with time stamp stuff
+      (if (not r)
+	  s
+	(setq r (concat r s))
+	(unless (string-match "\\S-" (concat b s))
+	  (setq r (concat r (org-lparse-format 'LINE-BREAK))))
+	r))))
+
+(defun org-xml-encode-plain-text (s)
+  "Convert plain text characters to HTML equivalent.
+Possible conversions are set in `org-export-html-protect-char-alist'."
+  (let ((cl (org-lparse-get 'PLAIN-TEXT-MAP)) c)
+    (while (setq c (pop cl))
+      (let ((start 0))
+	(while (string-match (car c) s start)
+	  (setq s (replace-match (cdr c) t t s)
+		start (1+ (match-beginning 0))))))
+    s))
+
+(defun org-xml-encode-org-text-skip-links (string)
+  "Prepare STRING for HTML export.  Apply all active conversions.
+If there are links in the string, don't modify these."
+  (let* ((re (concat org-bracket-link-regexp "\\|"
+		     (org-re "[ \t]+\\(:[[:alnum:]_@#%:]+:\\)[ \t]*$")))
+	 m s l res)
+    (while (setq m (string-match re string))
+      (setq s (substring string 0 m)
+	    l (match-string 0 string)
+	    string (substring string (match-end 0)))
+      (push (org-xml-encode-org-text s) res)
+      (push l res))
+    (push (org-xml-encode-org-text string) res)
+    (apply 'concat (nreverse res))))
+
+(defun org-xml-encode-org-text (s)
+  "Apply all active conversions to translate special ASCII to HTML."
+  (setq s (org-xml-encode-plain-text s))
+  (if org-export-html-expand
+      (while (string-match "@&lt;\\([^&]*\\)&gt;" s)
+	(setq s (replace-match "<\\1>" t nil s))))
+  (if org-export-with-emphasize
+      (setq s (org-lparse-apply-char-styles s)))
+  (if org-export-with-special-strings
+      (setq s (org-lparse-convert-special-strings s)))
+  (if org-export-with-sub-superscripts
+      (setq s (org-lparse-apply-sub-superscript-styles s)))
+  (if org-export-with-TeX-macros
+      (let ((start 0) wd rep)
+	(while (setq start (string-match "\\\\\\([a-zA-Z]+[0-9]*\\)\\({}\\)?"
+					 s start))
+	  (if (get-text-property (match-beginning 0) 'org-protected s)
+	      (setq start (match-end 0))
+	    (setq wd (match-string 1 s))
+	    (if (setq rep (org-lparse-format 'ORG-ENTITY wd))
+		(setq s (replace-match rep t t s))
+	      (setq start (+ start (length wd))))))))
+  s)
+
+(defun org-lparse-convert-special-strings (string)
+  "Convert special characters in STRING to HTML."
+  (let ((all (org-lparse-get 'SPECIAL-STRING-REGEXPS))
+	e a re rpl start)
+    (while (setq a (pop all))
+      (setq re (car a) rpl (cdr a) start 0)
+      (while (string-match re string start)
+	(if (get-text-property (match-beginning 0) 'org-protected string)
+	    (setq start (match-end 0))
+	  (setq string (replace-match rpl t nil string)))))
+    string))
+
+(defun org-lparse-apply-sub-superscript-styles (string)
+  "Apply subscript and superscript styles to STRING.
+Use `org-export-with-sub-superscripts' to control application of
+sub and superscript styles."
+  (let (key c (s 0) (requireb (eq org-export-with-sub-superscripts '{})))
+    (while (string-match org-match-substring-regexp string s)
+      (cond
+       ((and requireb (match-end 8)) (setq s (match-end 2)))
+       ((get-text-property  (match-beginning 2) 'org-protected string)
+	(setq s (match-end 2)))
+       (t
+	(setq s (match-end 1)
+	      key (if (string= (match-string 2 string) "_")
+		      'subscript 'superscript)
+	      c (or (match-string 8 string)
+		    (match-string 6 string)
+		    (match-string 5 string))
+	      string (replace-match
+		      (concat (match-string 1 string)
+			      (org-lparse-format 'FONTIFY c key))
+		      t t string)))))
+    (while (string-match "\\\\\\([_^]\\)" string)
+      (setq string (replace-match (match-string 1 string) t t string)))
+    string))
+
+(defvar org-lparse-char-styles
+  `(("*" bold)
+    ("/" emphasis)
+    ("_" underline)
+    ("=" code)
+    ("~" verbatim)
+    ("+" strike))
+  "Map Org emphasis markers to char styles.
+This is an alist where each element is of the
+form (ORG-EMPHASIS-CHAR . CHAR-STYLE).")
+
+(defun org-lparse-apply-char-styles (string)
+  "Apply char styles to STRING.
+The variable `org-lparse-char-styles' controls how the Org
+emphasis markers are interpreted."
+  (let ((s 0) rpl)
+    (while (string-match org-emph-re string s)
+      (if (not (equal
+		(substring string (match-beginning 3) (1+ (match-beginning 3)))
+		(substring string (match-beginning 4) (1+ (match-beginning 4)))))
+	  (setq s (match-beginning 0)
+		rpl
+		(concat
+		 (match-string 1 string)
+		 (org-lparse-format
+		  'FONTIFY (match-string 4 string)
+		  (nth 1 (assoc (match-string 3 string)
+				org-lparse-char-styles)))
+		 (match-string 5 string))
+		string (replace-match rpl t t string)
+		s (+ s (- (length rpl) 2)))
+	(setq s (1+ s))))
+    string))
+
+(defun org-lparse-export-list-line (line pos struct prevs)
+  "Insert list syntax in export buffer.  Return LINE, maybe modified.
+
+POS is the item position or line position the line had before
+modifications to buffer.  STRUCT is the list structure.  PREVS is
+the alist of previous items."
+  (let* ((get-type
+	  (function
+	   ;; Translate type of list containing POS to "d", "o" or
+	   ;; "u".
+	   (lambda (pos struct prevs)
+	     (let ((type (org-list-get-list-type pos struct prevs)))
+	       (cond
+		((eq 'ordered type) "o")
+		((eq 'descriptive type) "d")
+		(t "u"))))))
+	 (get-closings
+	  (function
+	   ;; Return list of all items and sublists ending at POS, in
+	   ;; reverse order.
+	   (lambda (pos)
+	     (let (out)
+	       (catch 'exit
+		 (mapc (lambda (e)
+			 (let ((end (nth 6 e))
+			       (item (car e)))
+			   (cond
+			    ((= end pos) (push item out))
+			    ((>= item pos) (throw 'exit nil)))))
+		       struct))
+	       out)))))
+    ;; First close any previous item, or list, ending at POS.
+    (mapc (lambda (e)
+	    (let* ((lastp (= (org-list-get-last-item e struct prevs) e))
+		   (first-item (org-list-get-list-begin e struct prevs))
+		   (type (funcall get-type first-item struct prevs)))
+	      (org-lparse-end-paragraph)
+	      ;; Ending for every item
+	      (org-lparse-end-list-item type)
+	      ;; We're ending last item of the list: end list.
+	      (when lastp
+		(org-lparse-end 'LIST type)
+		(org-lparse-begin-paragraph))))
+	  (funcall get-closings pos))
+    (cond
+     ;; At an item: insert appropriate tags in export buffer.
+     ((assq pos struct)
+      (string-match
+       (concat "[ \t]*\\(\\S-+[ \t]*\\)"
+	       "\\(?:\\[@\\(?:start:\\)?\\([0-9]+\\|[A-Za-z]\\)\\]\\)?"
+	       "\\(?:\\(\\[[ X-]\\]\\)[ \t]+\\)?"
+	       "\\(?:\\(.*\\)[ \t]+::[ \t]+\\)?"
+	       "\\(.*\\)") line)
+      (let* ((checkbox (match-string 3 line))
+	     (desc-tag (or (match-string 4 line) "???"))
+	     (body (or (match-string 5 line) ""))
+	     (list-beg (org-list-get-list-begin pos struct prevs))
+	     (firstp (= list-beg pos))
+	     ;; Always refer to first item to determine list type, in
+	     ;; case list is ill-formed.
+	     (type (funcall get-type list-beg struct prevs))
+	     (counter (let ((count-tmp (org-list-get-counter pos struct)))
+			(cond
+			 ((not count-tmp) nil)
+			 ((string-match "[A-Za-z]" count-tmp)
+			  (- (string-to-char (upcase count-tmp)) 64))
+			 ((string-match "[0-9]+" count-tmp)
+			  count-tmp)))))
+	(when firstp
+	  (org-lparse-end-paragraph)
+	  (org-lparse-begin 'LIST type))
+
+	(let ((arg (cond ((equal type "d") desc-tag)
+			 ((equal type "o") counter))))
+	  (org-lparse-begin 'LIST-ITEM type arg))
+
+	;; If line had a checkbox, some additional modification is required.
+	(when checkbox
+	  (setq body
+		(concat
+		 (org-lparse-format
+		  'FONTIFY (concat
+			    "["
+			    (cond
+			     ((string-match "X" checkbox) "X")
+			     ((string-match " " checkbox)
+			      (org-lparse-format 'SPACES 1))
+			     (t "-"))
+			    "]")
+		  'code)
+		 " "
+		 body)))
+	;; Return modified line
+	body))
+     ;; At a list ender: go to next line (side-effects only).
+     ((equal "ORG-LIST-END-MARKER" line) (throw 'nextline nil))
+     ;; Not at an item: return line unchanged (side-effects only).
+     (t line))))
+
+(defun org-lparse-bind-local-variables (opt-plist)
+  (mapc (lambda (x)
+	  (set (make-local-variable (nth 2 x))
+	       (plist-get opt-plist (car x))))
+	org-export-plist-vars))
+
+(defvar org-lparse-table-rowgrp-open)
+(defvar org-lparse-table-cur-rowgrp-is-hdr)
+(defvar org-lparse-footnote-number)
+(defvar org-lparse-footnote-definitions)
+(defvar org-lparse-footnote-buffer)
+(defvar org-lparse-output-buffer)
+
+(defcustom org-lparse-debug nil
+  "."
+  :group 'org-lparse
+  :type 'boolean)
+
+(defun org-lparse-begin (entity &rest args)
+  "Begin ENTITY in current buffer. ARGS is entity specific.
+ENTITY can be one of PARAGRAPH, LIST, LIST-ITEM etc.
+
+Use (org-lparse-begin 'LIST \"o\") to begin a list in current
+buffer.
+
+See `org-xhtml-entity-control-callbacks-alist' for more
+information."
+  (when (and (member org-lparse-debug '(t control))
+	     (not (eq entity 'DOCUMENT-CONTENT)))
+    (insert (org-lparse-format 'COMMENT "%s BEGIN %S" entity args)))
+
+  (let ((f (cadr (assoc entity org-lparse-entity-control-callbacks-alist))))
+    (unless f (error "Unknown entity: %s" entity))
+    (apply f args)))
+
+(defun org-lparse-end (entity &rest args)
+  "Close ENTITY in current buffer. ARGS is entity specific.
+ENTITY can be one of PARAGRAPH, LIST, LIST-ITEM
+etc.
+
+Use (org-lparse-end 'LIST \"o\") to close a list in current
+buffer.
+
+See `org-xhtml-entity-control-callbacks-alist' for more
+information."
+  (when (and (member org-lparse-debug '(t control))
+	     (not (eq entity 'DOCUMENT-CONTENT)))
+    (insert (org-lparse-format 'COMMENT "%s END %S" entity args)))
+
+  (let ((f (caddr (assoc entity org-lparse-entity-control-callbacks-alist))))
+    (unless f (error "Unknown entity: %s" entity))
+    (apply f args)))
+
+(defun org-lparse-begin-paragraph (&optional style)
+  "Insert <p>, but first close previous paragraph if any."
+  (org-lparse-end-paragraph)
+  (org-lparse-begin 'PARAGRAPH style)
+  (setq org-lparse-par-open t))
+
+(defun org-lparse-end-paragraph ()
+  "Close paragraph if there is one open."
+  (when org-lparse-par-open
+    (org-lparse-end 'PARAGRAPH)
+    (setq org-lparse-par-open nil)))
+
+(defun org-lparse-end-list-item (&optional type)
+  "Close <li> if necessary."
+  (org-lparse-end-paragraph)
+  (org-lparse-end 'LIST-ITEM (or type "u")))
+
+(defvar org-lparse-dyn-current-environment nil)
+(defun org-lparse-begin-environment (style)
+  (assert (not org-lparse-dyn-current-environment) t)
+  (setq org-lparse-dyn-current-environment style)
+  (org-lparse-begin 'ENVIRONMENT  style))
+
+(defun org-lparse-end-environment (style)
+  (org-lparse-end 'ENVIRONMENT style)
+
+  (assert (eq org-lparse-dyn-current-environment style) t)
+  (setq org-lparse-dyn-current-environment nil))
+
+(defun org-lparse-current-environment-p (style)
+  (eq org-lparse-dyn-current-environment style))
+
+(defun org-lparse-begin-footnote-definition (n)
+  (unless org-lparse-footnote-buffer
+    (setq org-lparse-footnote-buffer
+	  (get-buffer-create "*Org HTML Export Footnotes*")))
+  (set-buffer org-lparse-footnote-buffer)
+  (erase-buffer)
+  (setq org-lparse-insert-tag-with-newlines nil)
+  (org-lparse-begin 'FOOTNOTE-DEFINITION n))
+
+(defun org-lparse-end-footnote-definition (n)
+  (org-lparse-end 'FOOTNOTE-DEFINITION n)
+  (setq org-lparse-insert-tag-with-newlines 'both)
+  (push (cons n (buffer-string)) org-lparse-footnote-definitions)
+  (set-buffer org-lparse-output-buffer))
+
+(defun org-lparse-format (entity &rest args)
+  "Format ENTITY in backend-specific way and return it.
+ARGS is specific to entity being formatted.
+
+Use (org-lparse-format 'HEADING \"text\" 1) to format text as
+level 1 heading.
+
+See `org-xhtml-entity-format-callbacks-alist' for more information."
+  (when (and (member org-lparse-debug '(t format))
+	     (not (equal entity 'COMMENT)))
+    (insert (org-lparse-format 'COMMENT "%s: %S" entity args)))
+  (cond
+   ((consp entity)
+    (let ((text (pop args)))
+      (apply 'org-lparse-format 'TAGS entity text args)))
+   (t
+    (let ((f (cdr (assoc entity org-lparse-entity-format-callbacks-alist))))
+      (unless f (error "Unknown entity: %s" entity))
+      (apply f args)))))
+
+(defun org-lparse-insert (entity &rest args)
+  (insert (apply 'org-lparse-format entity args)))
+
+(defun org-lparse-prepare-toc (lines level-offset opt-plist umax-toc)
+  (let* ((quote-re0 (concat "^[ \t]*" org-quote-string "\\>"))
+	 (org-min-level (org-get-min-level lines level-offset))
+	 (org-last-level org-min-level)
+	 level)
+    (with-temp-buffer
+      (org-lparse-bind-local-variables opt-plist)
+      (erase-buffer)
+      (org-lparse-begin 'TOC (nth 3 (plist-get opt-plist :lang-words)))
+      (setq
+       lines
+       (mapcar
+	#'(lambda (line)
+	    (when (and (string-match org-todo-line-regexp line)
+		       (not (get-text-property 0 'org-protected line))
+		       (<= (setq level (org-tr-level
+					(- (match-end 1) (match-beginning 1)
+					   level-offset)))
+			   umax-toc))
+	      (let ((txt (save-match-data
+			   (org-xml-encode-org-text-skip-links
+			    (org-export-cleanup-toc-line
+			     (match-string 3 line)))))
+		    (todo (and
+			   org-export-mark-todo-in-toc
+			   (or (and (match-beginning 2)
+				    (not (member (match-string 2 line)
+						 org-done-keywords)))
+			       (and (= level umax-toc)
+				    (org-search-todo-below
+				     line lines level)))))
+		    tags)
+		;; Check for targets
+		(while (string-match org-any-target-regexp line)
+		  (setq line
+			(replace-match
+			 (let ((org-lparse-encode-pending t))
+			   (org-lparse-format 'FONTIFY
+					     (match-string 1 line) "target"))
+			 t t line)))
+		(when (string-match
+		       (org-re "[ \t]+:\\([[:alnum:]_@:]+\\):[ \t]*$") txt)
+		  (setq tags (match-string 1 txt)
+			txt (replace-match "" t nil txt)))
+		(when (string-match quote-re0 txt)
+		  (setq txt (replace-match "" t t txt)))
+		(while (string-match "&lt;\\(&lt;\\)+\\|&gt;\\(&gt;\\)+" txt)
+		  (setq txt (replace-match "" t t txt)))
+		(org-lparse-format
+		 'TOC-ITEM
+		 (let* ((snumber (org-section-number level))
+			(href (replace-regexp-in-string
+			       "\\." "-" (format "sec-%s" snumber)))
+			(href
+			 (or
+			  (cdr (assoc
+				href org-export-preferred-target-alist))
+			  href))
+			(href (org-solidify-link-text href)))
+		   (org-lparse-format 'TOC-ENTRY snumber todo txt tags href))
+		 level org-last-level)
+		(setq org-last-level level)))
+	    line)
+	lines))
+      (org-lparse-end 'TOC)
+      (setq org-lparse-toc (buffer-string))))
+  lines)
+
+(defun org-lparse-format-table-row (fields &optional text-for-empty-fields)
+  (unless org-lparse-table-ncols
+    ;; first row of the table
+    (setq org-lparse-table-ncols (length fields))
+    (when org-lparse-table-is-styled
+      (setq org-lparse-table-num-numeric-items-per-column
+	    (make-vector org-lparse-table-ncols 0))
+      (setq org-lparse-table-colalign-vector
+	    (make-vector org-lparse-table-ncols nil))
+      (let ((c -1))
+	(while  (< (incf c) org-lparse-table-ncols)
+	  (let ((cookie (cdr (assoc (1+ c) org-lparse-table-colalign-info))))
+	    (setf (aref org-lparse-table-colalign-vector c)
+		  (cond
+		   ((string= cookie "l") "left")
+		   ((string= cookie "r") "right")
+		   ((string= cookie "c") "center")
+		   (t nil))))))))
+  (incf org-lparse-table-rownum)
+  (let ((i -1))
+    (org-lparse-format
+     'TABLE-ROW
+     (mapconcat
+      (lambda (x)
+	(when (and (string= x "") text-for-empty-fields)
+	  (setq x text-for-empty-fields))
+	(incf i)
+	(and org-lparse-table-is-styled
+	     (< i org-lparse-table-ncols)
+	     (string-match org-table-number-regexp x)
+	     (incf (aref org-lparse-table-num-numeric-items-per-column i)))
+	(org-lparse-format 'TABLE-CELL x org-lparse-table-rownum i))
+      fields "\n"))))
+
+(defun org-lparse-get (what &optional opt-plist)
+  "Query for value of WHAT for the current backend `org-lparse-backend'.
+See also `org-lparse-backend-get'."
+  (if (boundp 'org-lparse-backend)
+      (org-lparse-backend-get (symbol-name org-lparse-backend) what opt-plist)
+    (error "org-lparse-backend is not bound yet")))
+
+(defun org-lparse-backend-get (backend what &optional opt-plist)
+  "Query BACKEND for value of WHAT.
+Dispatch the call to `org-<backend>-user-get'.  If that throws an
+error, dispatch the call to `org-<backend>-get'.  See
+`org-xhtml-get' for all known settings queried for by
+`org-lparse' during the course of export."
+  (assert (stringp backend) t)
+  (unless (org-lparse-backend-is-native-p backend)
+    (error "Unknown native backend %s" backend))
+  (let ((backend-get-method (intern (format "org-%s-get" backend)))
+	(backend-user-get-method (intern (format "org-%s-user-get" backend))))
+    (cond
+     ((functionp backend-get-method)
+      (condition-case nil
+	  (funcall backend-user-get-method what opt-plist)
+	(error (funcall backend-get-method what opt-plist))))
+     (t
+      (error "Native backend %s doesn't define %s" backend backend-get-method)))))
+
+(defun org-lparse-insert-tag (tag &rest args)
+  (when (member org-lparse-insert-tag-with-newlines '(lead both))
+    (insert  "\n"))
+  (insert (apply 'format tag args))
+  (when (member org-lparse-insert-tag-with-newlines '(trail both))
+    (insert  "\n")))
+
+(defun org-lparse-get-targets-from-title (title)
+  (let* ((target (org-get-text-property-any 0 'target title))
+	 (extra-targets (assoc target org-export-target-aliases))
+	 (target (or (cdr (assoc target org-export-preferred-target-alist))
+		     target)))
+    (cons target (remove target extra-targets))))
+
+(defun org-lparse-suffix-from-snumber (snumber)
+  (let* ((snu (replace-regexp-in-string "\\." "-" snumber))
+	 (href (cdr (assoc (concat "sec-" snu)
+			   org-export-preferred-target-alist))))
+    (org-solidify-link-text (or href snu))))
+
+(defun org-lparse-begin-level (level title umax head-count)
+  "Insert a new LEVEL in HTML export.
+When TITLE is nil, just close all open levels."
+  (org-lparse-end-level level umax)
+  (unless title (error "Why is heading nil"))
+  (let* ((targets (org-lparse-get-targets-from-title title))
+	 (target (car targets)) (extra-targets (cdr targets))
+	 (target (and target (org-solidify-link-text target)))
+	 (extra-class (org-get-text-property-any 0 'html-container-class title))
+	 snumber tags level1 class)
+    (when (string-match (org-re "\\(:[[:alnum:]_@#%:]+:\\)[ \t]*$") title)
+      (setq tags (and org-export-with-tags (match-string 1 title)))
+      (setq title (replace-match "" t t title)))
+    (if (> level umax)
+	(progn
+	  (if (aref org-levels-open (1- level))
+	      (org-lparse-end-list-item)
+	    (aset org-levels-open (1- level) t)
+	    (org-lparse-end-paragraph)
+	    (org-lparse-begin 'LIST 'unordered))
+	  (org-lparse-begin
+	   'LIST-ITEM 'unordered target
+	   (org-lparse-format 'HEADLINE title extra-targets tags)))
+      (aset org-levels-open (1- level) t)
+      (setq snumber (org-section-number level))
+      (setq level1 (+ level (or (org-lparse-get 'TOPLEVEL-HLEVEL) 1) -1))
+      (unless (= head-count 1)
+	(org-lparse-end-outline-text-or-outline))
+      (org-lparse-begin-outline-and-outline-text
+       level1 snumber title tags target extra-targets extra-class)
+      (org-lparse-begin-paragraph))))
+
+(defun org-lparse-end-level (level umax)
+  (org-lparse-end-paragraph)
+  (loop for l from org-level-max downto level
+	do (when (aref org-levels-open (1- l))
+	     ;; Terminate one level in HTML export
+	     (if (<= l umax)
+		 (org-lparse-end-outline-text-or-outline)
+	       (org-lparse-end-list-item)
+	       (org-lparse-end 'LIST 'unordered))
+	     (aset org-levels-open (1- l) nil))))
+
+(defvar org-lparse-outline-text-open)
+(defun org-lparse-begin-outline-and-outline-text (level1 snumber title tags
+							target extra-targets
+							extra-class)
+  (org-lparse-begin
+   'OUTLINE level1 snumber title tags target extra-targets extra-class)
+  (org-lparse-begin-outline-text level1 snumber extra-class))
+
+(defun org-lparse-end-outline-text-or-outline ()
+  (cond
+   (org-lparse-outline-text-open
+    (org-lparse-end 'OUTLINE-TEXT)
+    (setq org-lparse-outline-text-open nil))
+   (t (org-lparse-end 'OUTLINE))))
+
+(defun org-lparse-begin-outline-text (level1 snumber extra-class)
+  (assert (not org-lparse-outline-text-open) t)
+  (setq org-lparse-outline-text-open t)
+  (org-lparse-begin 'OUTLINE-TEXT level1 snumber extra-class))
+
+(defun org-lparse-html-list-type-to-canonical-list-type (ltype)
+  (cdr (assoc ltype '(("o" . ordered)
+		      ("u" . unordered)
+		      ("d" . description)))))
+
+(defvar org-lparse-table-rowgrp-info)
+(defun org-lparse-begin-table-rowgroup (&optional is-header-row)
+  (push (cons (1+ org-lparse-table-rownum) :start) org-lparse-table-rowgrp-info)
+  (org-lparse-begin 'TABLE-ROWGROUP is-header-row))
+
+(defun org-lparse-end-table ()
+  (when org-lparse-table-is-styled
+    ;; column groups
+    (unless (car org-table-colgroup-info)
+      (setq org-table-colgroup-info
+	    (cons :start (cdr org-table-colgroup-info))))
+
+    ;; column alignment
+    (let ((c -1))
+      (mapc
+       (lambda (x)
+	 (incf c)
+	 (setf (aref org-lparse-table-colalign-vector c)
+	       (or (aref org-lparse-table-colalign-vector c)
+		   (if (> (/ (float x) (1+ org-lparse-table-rownum))
+			  org-table-number-fraction)
+		       "right" "left"))))
+       org-lparse-table-num-numeric-items-per-column)))
+  (org-lparse-end 'TABLE))
+
+(defvar org-lparse-encode-pending nil)
+
+(defun org-lparse-format-tags (tag text prefix suffix &rest args)
+  (cond
+   ((consp tag)
+    (concat prefix (apply 'format (car tag) args) text suffix
+	    (format (cdr tag))))
+   ((stringp tag)			; singleton tag
+    (concat prefix (apply 'format tag args) text))))
+
+(defun org-xml-fix-class-name (kwd) 	; audit callers of this function
+  "Turn todo keyword into a valid class name.
+Replaces invalid characters with \"_\"."
+  (save-match-data
+    (while (string-match "[^a-zA-Z0-9_]" kwd)
+      (setq kwd (replace-match "_" t t kwd))))
+  kwd)
+
+(defun org-lparse-format-todo (todo)
+  (org-lparse-format 'FONTIFY
+		     (concat
+		      (ignore-errors (org-lparse-get 'TODO-KWD-CLASS-PREFIX))
+		      (org-xml-fix-class-name todo))
+		     (list (if (member todo org-done-keywords) "done" "todo")
+			   todo)))
+
+(defun org-lparse-format-extra-targets (extra-targets)
+  (if (not extra-targets) ""
+      (mapconcat (lambda (x)
+	       (setq x (org-solidify-link-text
+			(if (org-uuidgen-p x) (concat "ID-" x) x)))
+	       (org-lparse-format 'ANCHOR "" x))
+	     extra-targets "")))
+
+(defun org-lparse-format-org-tags (tags)
+  (if (not tags) ""
+    (org-lparse-format
+     'FONTIFY (mapconcat
+	       (lambda (x)
+		 (org-lparse-format
+		  'FONTIFY x
+		  (concat
+		   (ignore-errors (org-lparse-get 'TAG-CLASS-PREFIX))
+		   (org-xml-fix-class-name x))))
+	       (org-split-string tags ":")
+	       (org-lparse-format 'SPACES 1)) "tag")))
+
+(defun org-lparse-format-section-number (&optional snumber level)
+  (and org-export-with-section-numbers
+       (not body-only) snumber level
+       (org-lparse-format 'FONTIFY snumber (format "section-number-%d" level))))
+
+(defun org-lparse-warn (msg)
+  (put-text-property 0 (length msg) 'face 'font-lock-warning-face msg)
+  (message msg)
+  (sleep-for 3))
+
+(defun org-xml-format-href (s)
+  "Make sure the S is valid as a href reference in an XHTML document."
+  (save-match-data
+    (let ((start 0))
+      (while (string-match "&" s start)
+	(setq start (+ (match-beginning 0) 3)
+	      s (replace-match "&amp;" t t s)))))
+  s)
+
+(defun org-xml-format-desc (s)
+  "Make sure the S is valid as a description in a link."
+  (if (and s (not (get-text-property 1 'org-protected s)))
+      (save-match-data
+	(org-xml-encode-org-text s))
+    s))
+
+(provide 'org-lparse)
+
+;;; org-lparse.el ends here

+ 1513 - 0
contrib/lisp/org-odt.el

@@ -0,0 +1,1513 @@
+;;; org-odt.el --- OpenDocumentText export for Org-mode
+
+;; Copyright (C) 2010-2011
+;;   Jambunathan <kjambunathan at gmail dot com>
+
+;; Author: Jambunathan K <kjambunathan at gmail dot com>
+;; Keywords: outlines, hypermedia, calendar, wp
+;; Homepage: http://orgmode.org
+;; Version: 0.8
+
+;; This file is not (yet) part of GNU Emacs.
+;; However, it is distributed under the same license.
+
+;; GNU Emacs is free software: you can redistribute it and/or modify
+;; it under the terms of the GNU General Public License as published by
+;; the Free Software Foundation, either version 3 of the License, or
+;; (at your option) any later version.
+
+;; GNU Emacs is distributed in the hope that it will be useful,
+;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+;; GNU General Public License for more details.
+
+;; You should have received a copy of the GNU General Public License
+;; along with GNU Emacs.  If not, see <http://www.gnu.org/licenses/>.
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;;
+;;; Commentary:
+
+;;; Use M-x `org-odt-unit-test' to test drive the exporter
+
+;;; Code:
+(eval-when-compile (require 'cl))
+(require 'org-lparse)
+
+(defun org-odt-end-export ()
+  ;; remove empty paragraphs
+  (goto-char (point-min))
+  (while (re-search-forward
+	  "<text:p\\( text:style-name=\"Text_20_body\"\\)?>[ \r\n\t]*</text:p>"
+	  nil t)
+    (replace-match ""))
+  (goto-char (point-min))
+
+  ;; Convert whitespace place holders
+  (goto-char (point-min))
+  (let (beg end n)
+    (while (setq beg (next-single-property-change (point) 'org-whitespace))
+      (setq n (get-text-property beg 'org-whitespace)
+	    end (next-single-property-change beg 'org-whitespace))
+      (goto-char beg)
+      (delete-region beg end)
+      (insert (format "<span style=\"visibility:hidden;\">%s</span>"
+		      (make-string n ?x)))))
+
+  ;; Remove empty lines at the beginning of the file.
+  (goto-char (point-min))
+  (when (looking-at "\\s-+\n") (replace-match ""))
+
+  ;; Remove display properties
+  (remove-text-properties (point-min) (point-max) '(display t)))
+
+(defvar org-odt-suppress-xref nil)
+(defconst org-export-odt-special-string-regexps
+  '(("\\\\-" . "&#x00ad;\\1")		; shy
+    ("---\\([^-]\\)" . "&#x2014;\\1")	; mdash
+    ("--\\([^-]\\)" . "&#x2013;\\1")	; ndash
+    ("\\.\\.\\." . "&#x2026;"))		; hellip
+  "Regular expressions for special string conversion.")
+
+(defconst org-odt-lib-dir (file-name-directory load-file-name))
+(defconst org-odt-data-dir
+  (let ((dir1 (expand-file-name ".." org-odt-lib-dir))		   ; git
+	(dir2 (expand-file-name "./contrib/odt" org-odt-lib-dir))) ; elpa
+    (cond
+     ((file-directory-p dir1) dir1)
+     ((file-directory-p dir2) dir2)
+     (t (error "Cannot find factory styles file. Check package dir layout")))))
+
+(defvar org-odt-file-extensions
+  '(("odt" . "OpenDocument Text")
+    ("ott" . "OpenDocument Text Template")
+    ("odm" . "OpenDocument Master Document")
+    ("ods" . "OpenDocument Spreadsheet")
+    ("ots" . "OpenDocument Spreadsheet Template")
+    ("odg" . "OpenDocument Drawing (Graphics)")
+    ("otg" . "OpenDocument Drawing Template")
+    ("odp" . "OpenDocument Presentation")
+    ("otp" . "OpenDocument Presentation Template")
+    ("odi" . "OpenDocument Image")
+    ("odf" . "OpenDocument Formula")
+    ("odc" . "OpenDocument Chart")
+    ("doc" . "Microsoft Text")
+    ("docx" . "Microsoft Text")
+    ("xls" . "Microsoft Spreadsheet")
+    ("xlsx" . "Microsoft Spreadsheet")
+    ("ppt" . "Microsoft Presentation")
+    ("pptx" . "Microsoft Presentation")))
+
+(defvar org-odt-ms-file-extensions
+  '(("doc" . "Microsoft Text")
+    ("docx" . "Microsoft Text")
+    ("xls" . "Microsoft Spreadsheet")
+    ("xlsx" . "Microsoft Spreadsheet")
+    ("ppt" . "Microsoft Presentation")
+    ("pptx" . "Microsoft Presentation")))
+
+;; RelaxNG validation of OpenDocument xml files
+(eval-after-load 'rng-nxml
+  '(setq rng-nxml-auto-validate-flag t))
+
+(eval-after-load 'rng-loc
+  '(add-to-list 'rng-schema-locating-files
+		(expand-file-name "etc/schema/schemas.xml" org-odt-data-dir)))
+
+(mapc
+ (lambda (desc)
+   ;; Let Org open all OpenDocument files using system-registered app
+   (add-to-list 'org-file-apps
+		(cons (concat  "\\." (car desc) "\\'") 'system))
+   ;; Let Emacs open all OpenDocument files in archive mode
+   (add-to-list 'auto-mode-alist
+		(cons (concat  "\\." (car desc) "\\'") 'archive-mode)))
+ org-odt-file-extensions)
+
+(mapc
+ (lambda (desc)
+   ;; Let Org open all Microsoft files using system-registered app
+   (add-to-list 'org-file-apps
+		(cons (concat  "\\." (car desc) "\\'") 'system)))
+ org-odt-ms-file-extensions)
+
+;; register the odt exporter
+(add-to-list 'org-export-backends 'odt)
+
+(defcustom org-export-odt-automatic-styles-file nil
+  "Default style file for use with ODT exporter."
+  :group 'org-export-odt
+  :type 'file)
+
+;; TODO: Make configuration user-friendly.
+(defcustom org-export-odt-styles-file nil
+  "Default style file for use with ODT exporter.
+Valid values are path to an styles.xml file or a path to a valid
+*.odt or a *.ott file or a list of the form (FILE (MEMBER1
+MEMBER2 ...)). In the last case, the specified FILE is unzipped
+and MEMBER1, MEMBER2 etc are copied in to the generated odt
+file. The last form is particularly useful if the styles.xml has
+reference to additional files like header and footer images.
+"
+  :group 'org-export-odt
+  :type 'file)
+(defconst  org-export-odt-tmpdir-prefix "odt-")
+(defconst org-export-odt-bookmark-prefix "OrgXref.")
+(defcustom org-export-odt-use-bookmarks-for-internal-links t
+  "Export Internal links as bookmarks?."
+  :group 'org-export-odt
+  :type 'boolean)
+
+(defcustom org-export-odt-embed-images t
+  "Should the images be copied in to the odt file or just linked?"
+  :group 'org-export-odt
+  :type 'boolean)
+
+(defcustom org-odt-export-inline-images 'maybe
+  "Non-nil means inline images into exported HTML pages.
+This is done using an <img> tag.  When nil, an anchor with href is used to
+link to the image.  If this option is `maybe', then images in links with
+an empty description will be inlined, while images with a description will
+be linked only."
+  :group 'org-odt-export
+  :type '(choice (const :tag "Never" nil)
+		 (const :tag "Always" t)
+		 (const :tag "When there is no description" maybe)))
+
+(defcustom org-odt-export-inline-image-extensions
+  '("png" "jpeg" "jpg" "gif")
+  "Extensions of image files that can be inlined into HTML."
+  :group 'org-odt-export
+  :type '(repeat (string :tag "Extension")))
+
+(defcustom org-export-odt-pixels-per-inch display-pixels-per-inch
+  ""
+  :group 'org-export-odt
+  :type 'float)
+
+(defvar org-export-odt-default-org-styles-alist
+  '((paragraph . ((default . "Text_20_body")
+		  (fixedwidth . "OrgSourceBlock")
+		  (verse . "OrgVerse")
+		  (quote . "Quotations")
+		  (blockquote . "Quotations")
+		  (center . "OrgCenter")
+		  (left . "OrgLeft")
+		  (right . "OrgRight")
+		  (title . "Heading_20_1.title")
+		  (footnote . "Footnote")
+		  (src . "OrgSourceBlock")
+		  (illustration . "Illustration")
+		  (table . "Table")
+		  (definition-term . "Text_20_body_20_bold")
+		  (horizontal-line . "Horizontal_20_Line")))
+    (character . ((bold . "Bold")
+		  (emphasis . "Emphasis")
+		  (code . "OrgCode")
+		  (verbatim . "OrgCode")
+		  (strike . "Strikethrough")
+		  (underline . "Underline")
+		  (subscript . "OrgSubscript")
+		  (superscript . "OrgSuperscript")))
+    (list . ((ordered . "OrgNumberedList")
+	     (unordered . "OrgBulletedList")
+	     (description . "OrgDescriptionList"))))
+  "Default styles for various entities.")
+
+(defvar org-export-odt-org-styles-alist org-export-odt-default-org-styles-alist)
+(defun org-odt-get-style-name-for-entity (category &optional entity)
+  (let ((entity (or entity 'default)))
+    (or
+     (cdr (assoc entity (cdr (assoc category
+				    org-export-odt-org-styles-alist))))
+     (cdr (assoc entity (cdr (assoc category
+				    org-export-odt-default-org-styles-alist))))
+     (error "Cannot determine style name for entity %s of type %s"
+	    entity category))))
+
+;;;###autoload
+(defun org-export-as-odt-and-open (arg)
+  "Export the outline as ODT and immediately open it with a browser.
+If there is an active region, export only the region.
+The prefix ARG specifies how many levels of the outline should become
+headlines.  The default is 3.  Lower levels will become bulleted lists."
+  (interactive "P")
+  (org-lparse-and-open "odt" "odt" arg))
+
+;;;###autoload
+(defun org-export-as-odt-batch ()
+  "Call the function `org-lparse-batch'.
+This function can be used in batch processing as:
+emacs   --batch
+        --load=$HOME/lib/emacs/org.el
+        --eval \"(setq org-export-headline-levels 2)\"
+        --visit=MyFile --funcall org-export-as-odt-batch"
+  (org-lparse-batch "odt"))
+
+;;;###autoload
+(defun org-export-as-odt-to-buffer (arg)
+  "Call `org-lparse-odt` with output to a temporary buffer.
+No file is created.  The prefix ARG is passed through to `org-lparse-to-buffer'."
+  (interactive "P")
+  (org-lparse-to-buffer "odt" arg))
+
+;;;###autoload
+(defun org-replace-region-by-odt (beg end)
+  "Assume the current region has org-mode syntax, and convert it to ODT.
+This can be used in any buffer.  For example, you could write an
+itemized list in org-mode syntax in an ODT buffer and then use this
+command to convert it."
+  (interactive "r")
+  (org-replace-region-by "odt" beg end))
+
+;;;###autoload
+(defun org-export-region-as-odt (beg end &optional body-only buffer)
+  "Convert region from BEG to END in org-mode buffer to ODT.
+If prefix arg BODY-ONLY is set, omit file header, footer, and table of
+contents, and only produce the region of converted text, useful for
+cut-and-paste operations.
+If BUFFER is a buffer or a string, use/create that buffer as a target
+of the converted ODT.  If BUFFER is the symbol `string', return the
+produced ODT as a string and leave not buffer behind.  For example,
+a Lisp program could call this function in the following way:
+
+  (setq odt (org-export-region-as-odt beg end t 'string))
+
+When called interactively, the output buffer is selected, and shown
+in a window.  A non-interactive call will only return the buffer."
+  (interactive "r\nP")
+  (org-lparse-region "odt" beg end body-only buffer))
+
+;;; org-export-as-odt
+;;;###autoload
+(defun org-export-as-odt (arg &optional hidden ext-plist
+			      to-buffer body-only pub-dir)
+  "Export the outline as a OpenDocumentText file.
+If there is an active region, export only the region.  The prefix
+ARG specifies how many levels of the outline should become
+headlines.  The default is 3.  Lower levels will become bulleted
+lists.  HIDDEN is obsolete and does nothing.
+EXT-PLIST is a property list with external parameters overriding
+org-mode's default settings, but still inferior to file-local
+settings.  When TO-BUFFER is non-nil, create a buffer with that
+name and export to that buffer.  If TO-BUFFER is the symbol
+`string', don't leave any buffer behind but just return the
+resulting XML as a string.  When BODY-ONLY is set, don't produce
+the file header and footer, simply return the content of
+<body>...</body>, without even the body tags themselves.  When
+PUB-DIR is set, use this as the publishing directory."
+  (interactive "P")
+  (org-lparse "odt" "odt" arg hidden ext-plist to-buffer body-only pub-dir))
+
+(defvar org-odt-entity-control-callbacks-alist
+  `((EXPORT
+     . (org-odt-begin-export org-odt-end-export))
+    (DOCUMENT-CONTENT
+     . (org-odt-begin-document-content org-odt-end-document-content))
+    (DOCUMENT-BODY
+     . (org-odt-begin-document-body org-odt-end-document-body))
+    (TOC
+     . (org-odt-begin-toc org-odt-end-toc))
+    (ENVIRONMENT
+     . (org-odt-begin-environment org-odt-end-environment))
+    (FOOTNOTE-DEFINITION
+     . (org-odt-begin-footnote-definition org-odt-end-footnote-definition))
+    (TABLE
+     . (org-odt-begin-table org-odt-end-table))
+    (TABLE-ROWGROUP
+     . (org-odt-begin-table-rowgroup org-odt-end-table-rowgroup))
+    (LIST
+     . (org-odt-begin-list org-odt-end-list))
+    (LIST-ITEM
+     . (org-odt-begin-list-item org-odt-end-list-item))
+    (OUTLINE
+     . (org-odt-begin-outline org-odt-end-outline))
+    (OUTLINE-TEXT
+     . (org-odt-begin-outline-text org-odt-end-outline-text))
+    (PARAGRAPH
+     . (org-odt-begin-paragraph org-odt-end-paragraph)))
+  "")
+
+(defvar org-odt-entity-format-callbacks-alist
+  `((EXTRA-TARGETS . org-lparse-format-extra-targets)
+    (ORG-TAGS . org-lparse-format-org-tags)
+    (SECTION-NUMBER . org-lparse-format-section-number)
+    (HEADLINE . org-odt-format-headline)
+    (TOC-ENTRY . org-odt-format-toc-entry)
+    (TOC-ITEM . org-odt-format-toc-item)
+    (TAGS . org-odt-format-tags)
+    (SPACES . org-odt-format-spaces)
+    (TABS . org-odt-format-tabs)
+    (LINE-BREAK . org-odt-format-line-break)
+    (FONTIFY . org-odt-format-fontify)
+    (TODO . org-lparse-format-todo)
+    (LINK . org-odt-format-link)
+    (INLINE-IMAGE . org-odt-format-inline-image)
+    (ORG-LINK . org-odt-format-org-link)
+    (HEADING . org-odt-format-heading)
+    (ANCHOR . org-odt-format-anchor)
+    (TABLE . org-lparse-format-table)
+    (TABLE-ROW . org-odt-format-table-row)
+    (TABLE-CELL . org-odt-format-table-cell)
+    (FOOTNOTES-SECTION . ignore)
+    (FOOTNOTE-REFERENCE . org-odt-format-footnote-reference)
+    (HORIZONTAL-LINE . org-odt-format-horizontal-line)
+    (COMMENT . org-odt-format-comment)
+    (LINE . org-odt-format-line)
+    (ORG-ENTITY . org-odt-format-org-entity))
+  "")
+
+;;;_. callbacks
+;;;_. control callbacks
+;;;_ , document body
+(defun org-odt-begin-office-body ()
+  (insert "
+  <office:body>
+    <office:text>
+      <text:sequence-decls>
+	<text:sequence-decl text:display-outline-level=\"0\" text:name=\"Illustration\"/>
+	<text:sequence-decl text:display-outline-level=\"0\" text:name=\"Table\"/>
+	<text:sequence-decl text:display-outline-level=\"0\" text:name=\"Text\"/>
+	<text:sequence-decl text:display-outline-level=\"0\" text:name=\"Drawing\"/>
+      </text:sequence-decls>"))
+
+;; Following variable is let bound when `org-do-lparse' is in
+;; progress. See org-html.el.
+(defvar org-lparse-toc)
+(defun org-odt-begin-document-body (opt-plist)
+  (org-odt-begin-office-body)
+  (let ((title (plist-get opt-plist :title)))
+    (when title
+      (insert
+       (org-odt-format-stylized-paragraph 'title title))))
+
+  ;; insert toc
+  (when org-lparse-toc
+    (insert "\n" org-lparse-toc "\n")))
+
+(defvar org-lparse-body-only)		; let bound during org-do-lparse
+(defvar org-lparse-to-buffer)		; let bound during org-do-lparse
+(defun org-odt-end-document-body (opt-plist)
+  (unless org-lparse-body-only
+    (org-lparse-insert-tag "</office:text>")
+    (org-lparse-insert-tag "</office:body>")))
+
+(defconst org-odt-document-content-header
+  "<?xml version=\"1.0\" encoding=\"UTF-8\"?>
+<office:document-content
+    xmlns:office=\"urn:oasis:names:tc:opendocument:xmlns:office:1.0\"
+    xmlns:style=\"urn:oasis:names:tc:opendocument:xmlns:style:1.0\"
+    xmlns:text=\"urn:oasis:names:tc:opendocument:xmlns:text:1.0\"
+    xmlns:table=\"urn:oasis:names:tc:opendocument:xmlns:table:1.0\"
+    xmlns:draw=\"urn:oasis:names:tc:opendocument:xmlns:drawing:1.0\"
+    xmlns:fo=\"urn:oasis:names:tc:opendocument:xmlns:xsl-fo-compatible:1.0\"
+    xmlns:xlink=\"http://www.w3.org/1999/xlink\"
+    xmlns:dc=\"http://purl.org/dc/elements/1.1/\"
+    xmlns:meta=\"urn:oasis:names:tc:opendocument:xmlns:meta:1.0\"
+    xmlns:number=\"urn:oasis:names:tc:opendocument:xmlns:datastyle:1.0\"
+    xmlns:svg=\"urn:oasis:names:tc:opendocument:xmlns:svg-compatible:1.0\"
+    xmlns:chart=\"urn:oasis:names:tc:opendocument:xmlns:chart:1.0\"
+    xmlns:dr3d=\"urn:oasis:names:tc:opendocument:xmlns:dr3d:1.0\"
+    xmlns:math=\"http://www.w3.org/1998/Math/MathML\"
+    xmlns:form=\"urn:oasis:names:tc:opendocument:xmlns:form:1.0\"
+    xmlns:script=\"urn:oasis:names:tc:opendocument:xmlns:script:1.0\"
+    xmlns:ooo=\"http://openoffice.org/2004/office\"
+    xmlns:ooow=\"http://openoffice.org/2004/writer\"
+    xmlns:oooc=\"http://openoffice.org/2004/calc\"
+    xmlns:dom=\"http://www.w3.org/2001/xml-events\"
+    xmlns:xforms=\"http://www.w3.org/2002/xforms\"
+    xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\"
+    xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\"
+    xmlns:rpt=\"http://openoffice.org/2005/report\"
+    xmlns:of=\"urn:oasis:names:tc:opendocument:xmlns:of:1.2\"
+    xmlns:xodt=\"http://www.w3.org/1999/xodt\"
+    xmlns:field=\"urn:openoffice:names:experimental:ooo-ms-interop:xmlns:field:1.0\"    office:version=\"1.2\">
+")
+
+(defun org-odt-begin-document-content (opt-plist)
+  ;; document header
+  (insert org-odt-document-content-header)
+
+  ;; automatic styles
+  (insert-file-contents
+   (or org-export-odt-automatic-styles-file
+       (expand-file-name "styles/OrgOdtAutomaticStyles.xml"
+			 org-odt-data-dir)))
+   (goto-char (point-max)))
+
+(defun org-odt-end-document-content ()
+  (org-lparse-insert-tag "</office:document-content>"))
+
+(defun org-odt-begin-outline (level1 snumber title tags
+				     target extra-targets class)
+  (org-lparse-insert
+   'HEADING (org-lparse-format
+	     'HEADLINE title extra-targets tags snumber level1)
+   level1 target))
+
+(defun org-odt-end-outline ()
+  (ignore))
+
+(defun org-odt-begin-outline-text (level1 snumber class)
+  (ignore))
+
+(defun org-odt-end-outline-text ()
+  (ignore))
+
+(defun org-odt-begin-paragraph (&optional style)
+  (org-lparse-insert-tag
+   "<text:p%s>" (org-odt-get-extra-attrs-for-paragraph-style style)))
+
+(defun org-odt-end-paragraph ()
+  (org-lparse-insert-tag "</text:p>"))
+
+(defun org-odt-get-extra-attrs-for-paragraph-style (style)
+  (let (style-name)
+    (setq style-name
+	  (cond
+	   ((stringp style) style)
+	   ((symbolp style) (org-odt-get-style-name-for-entity
+			     'paragraph style))))
+    (unless style-name
+      (error "Don't know how to handle paragraph style %s" style))
+    (format " text:style-name=\"%s\"" style-name)))
+
+(defun org-odt-format-stylized-paragraph (style text)
+  (org-odt-format-tags
+   '("<text:p%s>" . "</text:p>") text
+   (org-odt-get-extra-attrs-for-paragraph-style style)))
+
+(defun org-odt-begin-environment (style)
+  (case style
+    ((blockquote verse center quote)
+     (org-lparse-begin-paragraph style)
+     (list))
+    ((fixedwidth native)
+     (org-lparse-end-paragraph)
+     (list))
+    (t (error "Unknown environment %s" style))))
+
+(defun org-odt-end-environment (style)
+  (case style
+    ((blockquote verse center quote)
+     (org-lparse-end-paragraph)
+     (list))
+    ((fixedwidth native)
+     (org-lparse-begin-paragraph)
+     (list))
+    (t (error "Unknown environment %s" style))))
+
+(defun org-odt-begin-list (ltype &optional arg1)
+  (setq ltype (or (org-lparse-html-list-type-to-canonical-list-type ltype)
+		  ltype))
+  (let* ((style-name (org-odt-get-style-name-for-entity 'list ltype))
+	 (extra (if style-name
+		    (format " text:style-name=\"%s\""  style-name) "")))
+
+    ;; FIXME: Handle arg1 incase of ordered lists.
+    (case ltype
+      ((ordered unordered description)
+       (org-lparse-end-paragraph)
+       (org-lparse-insert-tag "<text:list%s>" extra))
+      (t (error "Unknown list type: %s"  ltype)))))
+
+(defun org-odt-end-list (ltype)
+  (setq ltype (or (org-lparse-html-list-type-to-canonical-list-type ltype)
+		  ltype))
+  (if ltype
+      (org-lparse-insert-tag "</text:list>")
+    (error "Unknown list type: %s" ltype)))
+
+(defun org-odt-begin-list-item (ltype &optional arg headline)
+  (setq ltype (or (org-lparse-html-list-type-to-canonical-list-type ltype)
+		  ltype))
+  (case ltype
+    (ordered
+     (assert (not headline) t)
+     (let* ((counter arg) (extra ""))
+       (org-lparse-insert-tag "<text:list-item>")
+       (org-lparse-begin-paragraph)))
+    (unordered
+     (let* ((id arg) (extra ""))
+       (org-lparse-insert-tag "<text:list-item>")
+       (org-lparse-begin-paragraph)
+       (insert (if headline (org-odt-format-target headline id)
+		 (org-odt-format-bookmark "" id)))))
+    (description
+     (assert (not headline) t)
+     (let ((term (or arg "(no term)")))
+       (insert
+	(org-odt-format-tags
+	 '("<text:list-item>" . "</text:list-item>")
+	 (org-odt-format-stylized-paragraph 'definition-term term)))
+       (org-lparse-begin 'LIST-ITEM 'unordered)
+       (org-lparse-begin 'LIST 'description)
+       (org-lparse-begin 'LIST-ITEM 'unordered)))
+    (t (error "Unknown list type"))))
+
+(defun org-odt-end-list-item (ltype)
+  (setq ltype (or (org-lparse-html-list-type-to-canonical-list-type ltype)
+		  ltype))
+  (case ltype
+    ((ordered unordered)
+     (org-lparse-insert-tag "</text:list-item>"))
+    (description
+     (org-lparse-end-list-item)
+     (org-lparse-end 'LIST 'description)
+     (org-lparse-end-list-item))
+    (t (error "Unknown list type"))))
+
+;; Following variables are let bound when table emission is in
+;; progress. See org-lparse.el.
+(defvar org-lparse-table-begin-marker)
+(defvar org-lparse-table-ncols)
+(defvar org-lparse-table-rowgrp-open)
+(defvar org-lparse-table-rownum)
+(defvar org-lparse-table-cur-rowgrp-is-hdr)
+(defvar org-lparse-table-is-styled)
+(defvar org-lparse-table-rowgrp-info)
+(defvar org-lparse-table-colalign-vector)
+(defun org-odt-begin-table (caption label attributes)
+  (when label
+    (insert
+     (org-odt-format-stylized-paragraph
+      'table (org-odt-format-entity-caption label caption "Table"))))
+
+  (org-lparse-insert-tag
+   "<table:table table:name=\"%s\" table:style-name=\"%s\">"
+   (or label "") "OrgTable")
+  (setq org-lparse-table-begin-marker (point)))
+
+(defun org-odt-end-table ()
+  (goto-char org-lparse-table-begin-marker)
+  (loop for level from 0 below org-lparse-table-ncols
+	do (insert (org-odt-format-tags "<table:table-column/>"  "")))
+
+  ;; fill style attributes for table cells
+  (when org-lparse-table-is-styled
+    (while (re-search-forward "@@\\(table-cell:p\\|table-cell:style-name\\)@@\\([0-9]+\\)@@\\([0-9]+\\)@@" nil t)
+      (let ((spec (match-string 1))
+	    (r (string-to-number (match-string 2)))
+	    (c (string-to-number (match-string 3))))
+	(cond
+	 ((equal spec "table-cell:p")
+	  (let ((style-name (org-odt-get-paragraph-style-for-table-cell r c)))
+	    (replace-match style-name t t)))
+	 ((equal spec "table-cell:style-name")
+	  (let ((style-name (org-odt-get-style-name-for-table-cell r c)))
+	    (replace-match style-name t t)))))))
+
+  (goto-char (point-max))
+  (org-lparse-insert-tag "</table:table>"))
+
+(defun org-odt-begin-table-rowgroup (&optional is-header-row)
+  (when org-lparse-table-rowgrp-open
+    (org-lparse-end 'TABLE-ROWGROUP))
+  (org-lparse-insert-tag (if is-header-row
+			   "<table:table-header-rows>"
+			 "<table:table-rows>"))
+  (setq org-lparse-table-rowgrp-open t)
+  (setq org-lparse-table-cur-rowgrp-is-hdr is-header-row))
+
+(defun org-odt-end-table-rowgroup ()
+  (when org-lparse-table-rowgrp-open
+    (setq org-lparse-table-rowgrp-open nil)
+    (org-lparse-insert-tag
+     (if org-lparse-table-cur-rowgrp-is-hdr
+	 "</table:table-header-rows>" "</table:table-rows>"))))
+
+(defun org-odt-format-table-row (row)
+  (org-odt-format-tags
+   '("<table:table-row>" . "</table:table-row>") row))
+
+(defun org-odt-get-style-name-for-table-cell (r c)
+  (concat
+   "OrgTblCell"
+   (cond
+    ((= r 0) "T")
+    ((eq (cdr (assoc r org-lparse-table-rowgrp-info))  :start) "T")
+    (t ""))
+   (when (= r org-lparse-table-rownum) "B")
+   (cond
+    ((= c 0) "")
+    ((or (memq (nth c org-table-colgroup-info) '(:start :startend))
+	 (memq (nth (1- c) org-table-colgroup-info) '(:end :startend))) "L")
+    (t ""))))
+
+(defun org-odt-get-paragraph-style-for-table-cell (r c)
+  (capitalize (aref org-lparse-table-colalign-vector c)))
+
+(defun org-odt-format-table-cell (data r c)
+  (if (not org-lparse-table-is-styled)
+      (org-odt-format-tags
+       '("<table:table-cell>" . "</table:table-cell>")
+       (org-odt-format-stylized-paragraph
+	(cond
+	 (org-lparse-table-cur-rowgrp-is-hdr "OrgTableHeading")
+	 ((and (= c 0) (org-lparse-get 'TABLE-FIRST-COLUMN-AS-LABELS))
+	  "OrgTableHeading")
+	 (t "OrgTableContents"))
+	data))
+    (let* ((style-name-cookie
+	    (format "@@table-cell:style-name@@%03d@@%03d@@" r c))
+	   (paragraph-style-cookie
+	    (concat
+	     (cond
+	      (org-lparse-table-cur-rowgrp-is-hdr "OrgTableHeading")
+	      ((and (= c 0) (org-lparse-get 'TABLE-FIRST-COLUMN-AS-LABELS))
+	       "OrgTableHeading")
+	      (t "OrgTableContents"))
+	     (format "@@table-cell:p@@%03d@@%03d@@" r c))))
+      (org-odt-format-tags
+       '("<table:table-cell table:style-name=\"%s\">" .
+	 "</table:table-cell>")
+       (org-odt-format-stylized-paragraph paragraph-style-cookie data)
+       style-name-cookie))))
+
+(defun org-odt-begin-footnote-definition (n)
+  (org-lparse-begin-paragraph 'footnote))
+
+(defun org-odt-end-footnote-definition (n)
+  (org-lparse-end-paragraph))
+
+(defun org-odt-begin-toc (lang-specific-heading)
+  (insert
+   (format "
+    <text:table-of-content text:style-name=\"Sect2\" text:protected=\"true\" text:name=\"Table of Contents1\">
+     <text:table-of-content-source text:outline-level=\"10\">
+      <text:index-title-template text:style-name=\"Contents_20_Heading\">%s</text:index-title-template>
+" lang-specific-heading))
+
+  (loop for level from 1 upto 10
+	do (insert (format
+		    "
+      <text:table-of-content-entry-template text:outline-level=\"%d\" text:style-name=\"Contents_20_%d\">
+       <text:index-entry-link-start text:style-name=\"Internet_20_link\"/>
+       <text:index-entry-chapter/>
+       <text:index-entry-text/>
+       <text:index-entry-link-end/>
+      </text:table-of-content-entry-template>
+" level level)))
+
+  (insert  "
+     </text:table-of-content-source>
+
+     <text:index-body>
+      <text:index-title text:style-name=\"Sect1\" text:name=\"Table of Contents1_Head\">
+       <text:p text:style-name=\"Contents_20_Heading\">Table of Contents</text:p>
+      </text:index-title>
+"))
+
+(defun org-odt-end-toc ()
+  (insert "
+     </text:index-body>
+    </text:table-of-content>
+"))
+
+(defun org-odt-format-toc-entry (snumber todo headline tags href)
+  (setq headline (concat
+		  (and org-export-with-section-numbers
+		       (concat snumber ". "))
+		  headline
+		  (and tags
+		    (concat
+		     (org-lparse-format 'SPACES 3)
+		     (org-lparse-format 'FONTIFY tags "tag")))))
+  (when todo
+    (setq headline (org-lparse-format 'FONTIFY headline "todo")))
+
+  (let ((org-odt-suppress-xref t))
+    (org-odt-format-link headline (concat  "#" href))))
+
+(defun org-odt-format-toc-item (toc-entry level org-last-level)
+  (let ((style (format "Contents_20_%d"
+		       (+ level (or (org-lparse-get 'TOPLEVEL-HLEVEL) 1) -1))))
+    (insert "\n" (org-odt-format-stylized-paragraph style toc-entry) "\n")))
+
+;; Following variable is let bound during 'ORG-LINK callback. See
+;; org-html.el
+(defvar org-lparse-link-description-is-image nil)
+(defun org-odt-format-link (desc href &optional attr)
+  (cond
+   ((and (= (string-to-char href) ?#) (not org-odt-suppress-xref))
+    (setq href (concat org-export-odt-bookmark-prefix (substring href 1)))
+    (org-odt-format-tags
+     '("<text:bookmark-ref text:reference-format=\"text\" text:ref-name=\"%s\">" .
+       "</text:bookmark-ref>")
+     desc href))
+   (org-lparse-link-description-is-image
+    (org-odt-format-tags
+     '("<draw:a xlink:type=\"simple\" xlink:href=\"%s\" %s>" . "</draw:a>")
+     desc href (or attr "")))
+   (t
+    (org-odt-format-tags
+     '("<text:a xlink:type=\"simple\" xlink:href=\"%s\" %s>" . "</text:a>")
+     desc href (or attr "")))))
+
+(defun org-odt-format-spaces (n)
+  (org-odt-format-tags "<text:s text:c=\"%d\"/>" "" n))
+
+(defun org-odt-format-tabs (&optional n)
+  (let ((tab "<text:tab/>")
+	(n (or n 1)))
+    (insert tab)))
+
+(defun org-odt-format-line-break ()
+  (org-odt-format-tags "<text:line-break/>" ""))
+
+(defun org-odt-format-horizontal-line ()
+  (org-odt-format-stylized-paragraph 'horizontal-line ""))
+
+(defun org-odt-format-line (line)
+  (case org-lparse-dyn-current-environment
+    (fixedwidth (concat (org-odt-format-source-code-or-example-line
+			 (org-xml-encode-plain-text line)) "\n"))
+    (t (concat line "\n"))))
+
+(defun org-odt-format-comment (fmt &rest args)
+  (let ((comment (apply 'format fmt args)))
+    (format "\n<!-- %s  -->\n" comment)))
+
+(defun org-odt-format-org-entity (wd)
+  ;; FIXME: Seems to work. But is this correct?
+  (let ((s (org-entity-get-representation wd 'utf8)))
+    (and s (format "&#x%x;" (string-to-char s)))))
+
+(defun org-odt-fill-tabs-and-spaces (line)
+  (replace-regexp-in-string
+   "\\([\t]\\|\\([ ]+\\)\\)" (lambda (s)
+	    (cond
+	     ((string= s "\t") (org-odt-format-tabs))
+	     ((> (length s) 1)
+	      (org-odt-format-spaces (length s)))
+	     (t " "))) line))
+
+(defun org-odt-format-source-code-or-example-line (line)
+  (org-odt-format-stylized-paragraph 'src (org-odt-fill-tabs-and-spaces line)))
+
+(defun org-odt-format-example (lines)
+  (mapconcat
+   (lambda (line)
+     (org-odt-format-source-code-or-example-line line))
+   (org-split-string lines "[\r\n]") "\n"))
+
+(defun org-odt-format-source-code-or-example (lines lang caption textareap
+						    cols rows num cont
+						    rpllbl fmt)
+  (org-odt-format-example (org-export-number-lines
+			   (org-xml-encode-plain-text-lines lines)
+			   0 0 num cont rpllbl fmt)))
+
+(defun org-xml-encode-plain-text-lines (rtn)
+  (mapconcat 'org-xml-encode-plain-text (org-split-string rtn "[\r\n]") "\n"))
+
+(defun org-odt-remap-stylenames (style-name)
+  (or
+   (cdr (assoc style-name '(("timestamp-wrapper" . "OrgTimestampWrapper")
+			    ("timestamp" . "OrgTimestamp")
+			    ("timestamp-kwd" . "OrgTimestampKeyword")
+			    ("tag" . "OrgTag")
+			    ("todo" . "OrgTodo")
+			    ("done" . "OrgDone")
+			    ("target" . "OrgTarget"))))
+   style-name))
+
+(defun org-odt-format-fontify (text style &optional id)
+  (let* ((style-name
+	  (cond
+	   ((stringp style)
+	    (org-odt-remap-stylenames style))
+	   ((symbolp style)
+	    (org-odt-get-style-name-for-entity 'character style))
+	   ((listp style)
+	    (assert (< 1 (length style)))
+	    (let ((parent-style (pop style)))
+	      (mapconcat (lambda (s)
+			   ;; (assert (stringp s) t)
+			   (org-odt-remap-stylenames s)) style "")
+	      (org-odt-remap-stylenames parent-style)))
+	   (t (error "Don't how to handle style %s"  style)))))
+    (org-odt-format-tags
+     '("<text:span text:style-name=\"%s\">" . "</text:span>")
+     text style-name)))
+
+(defun org-odt-relocate-relative-path (path dir)
+  (if (file-name-absolute-p path) path
+    (file-relative-name (expand-file-name path dir)
+			(expand-file-name "eyecandy" dir))))
+
+(defun org-odt-format-inline-image (thefile)
+  (let* ((thelink (if (file-name-absolute-p thefile) thefile
+		    (org-xml-format-href
+		     (org-odt-relocate-relative-path
+		      thefile org-current-export-file))))
+	 (href
+	  (org-odt-format-tags
+	   "<draw:image xlink:href=\"%s\" xlink:type=\"simple\" xlink:show=\"embed\" xlink:actuate=\"onLoad\"/>" ""
+	   (if org-export-odt-embed-images
+	       (org-odt-copy-image-file thefile) thelink))))
+    (org-export-odt-format-image thefile href)))
+
+(defun org-odt-format-org-link (opt-plist type-1 path fragment desc attr
+					  descp)
+  "Make an HTML link.
+OPT-PLIST is an options list.
+TYPE is the device-type of the link (THIS://foo.html)
+PATH is the path of the link (http://THIS#locationx)
+FRAGMENT is the fragment part of the link, if any (foo.html#THIS)
+DESC is the link description, if any.
+ATTR is a string of other attributes of the a element.
+MAY-INLINE-P allows inlining it as an image."
+
+  (declare (special org-lparse-par-open))
+  (save-match-data
+    (let* ((may-inline-p
+	    (and (member type-1 '("http" "https" "file"))
+		 (org-lparse-should-inline-p path descp)
+		 (not fragment)))
+	   (type (if (equal type-1 "id") "file" type-1))
+	   (filename path)
+	   (thefile path))
+
+      (cond
+       ;; check for inlined images
+       ((and (member type '("file"))
+	     (not fragment)
+	     (org-file-image-p
+	      filename org-odt-export-inline-image-extensions)
+	     (or (eq t org-odt-export-inline-images)
+		 (and org-odt-export-inline-images (not descp))))
+
+	;; (when (and (string= type "file") (file-name-absolute-p path))
+	;;   (setq thefile (concat "file://" (expand-file-name path))))
+	;; (setq thefile (org-xml-format-href thefile))
+	;; (org-export-html-format-image thefile)
+	(org-odt-format-inline-image thefile))
+       (t
+	(when (string= type "file")
+	  (setq thefile
+		(cond
+		 ((file-name-absolute-p path)
+		  (concat "file://" (expand-file-name path)))
+		 (t (org-odt-relocate-relative-path
+		     thefile org-current-export-file)))))
+
+	(when (and (member type '("" "http" "https" "file" "coderef"))
+		   fragment)
+	  (setq thefile (concat thefile "#" fragment)))
+
+	(setq thefile (org-xml-format-href thefile))
+
+	(when (not (member type '("" "file" "coderef")))
+	  (setq thefile (concat type ":" thefile)))
+
+	(let ((org-odt-suppress-xref (string= type "coderef")))
+	  (org-odt-format-link
+	   (org-xml-format-desc desc) thefile attr)))))))
+
+(defun org-odt-format-heading (text level &optional id)
+  (let* ((text (if id (org-odt-format-target text id) text)))
+    (org-odt-format-tags
+     '("<text:h text:style-name=\"Heading_20_%s\" text:outline-level=\"%s\">" .
+       "</text:h>") text level level)))
+
+(defun org-odt-format-headline (title extra-targets tags
+					    &optional snumber level)
+  (concat
+   (org-lparse-format 'EXTRA-TARGETS extra-targets)
+
+   ;; No need to generate section numbers. They are auto-generated by
+   ;; the application
+
+   ;; (concat (org-lparse-format 'SECTION-NUMBER snumber level) " ")
+   title
+   (and tags (concat (org-lparse-format 'SPACES 3)
+		     (org-lparse-format 'ORG-TAGS tags)))))
+
+(defun org-odt-format-anchor (text name &optional class)
+  (org-odt-format-target text name))
+
+(defun org-odt-format-bookmark (text id)
+  (if id
+      (org-odt-format-tags "<text:bookmark text:name=\"%s\"/>" text id)
+    text))
+
+(defun org-odt-format-target (text id)
+  (let ((name (concat org-export-odt-bookmark-prefix id)))
+    (concat
+     (and id (org-odt-format-tags
+	      "<text:bookmark-start text:name=\"%s\"/>" "" name))
+     (org-odt-format-bookmark text id)
+     (and id (org-odt-format-tags
+	      "<text:bookmark-end text:name=\"%s\"/>" "" name)))))
+
+(defun org-odt-format-footnote (n def)
+  (let ((id (concat  "fn" n))
+	(note-class "footnote")
+	(par-style "Footnote"))
+    (org-odt-format-tags
+     '("<text:note text:id=\"%s\" text:note-class=\"%s\">" .
+       "</text:note>")
+     (concat
+      (org-odt-format-tags
+       '("<text:note-citation>" . "</text:note-citation>")
+       n)
+      (org-odt-format-tags
+       '("<text:note-body>" . "</text:note-body>")
+       def))
+     id note-class)))
+
+(defun org-odt-format-footnote-reference (n def refcnt)
+  (if (= refcnt 1)
+      (org-odt-format-footnote n def)
+    (org-odt-format-footnote-ref n)))
+
+(defun org-odt-format-footnote-ref (n)
+  (let ((note-class "footnote")
+	(ref-format "text")
+	(ref-name (concat "fn" n)))
+    (org-odt-format-tags
+     '("<text:span text:style-name=\"%s\">" . "</text:span>")
+     (org-odt-format-tags
+      '("<text:note-ref text:note-class=\"%s\" text:reference-format=\"%s\" text:ref-name=\"%s\">" . "</text:note-ref>")
+      n note-class ref-format ref-name)
+     "OrgSuperscript")))
+
+(defun org-odt-get-image-name (file-name)
+  (require 'sha1)
+  (file-relative-name
+   (expand-file-name
+    (concat (sha1 file-name) "." (file-name-extension file-name)) "Pictures")))
+
+(defun org-export-odt-format-image (src href
+					;; par-open
+					)
+  "Create image tag with source and attributes."
+  (save-match-data
+
+    (let (embed-as caption attr label attr-plist size width height)
+
+      (cond
+       ((string-match "^ltxpng/" src)
+	;; FIXME: Anyway the latex src can be embedded as an
+	;; annotation
+
+	;; (org-find-text-property-in-string 'org-latex-src src)
+	(setq caption nil attr nil label nil embed-as 'character))
+
+       (t
+	(setq caption (org-find-text-property-in-string 'org-caption src)
+	      caption (and caption (org-xml-format-desc caption))
+	      attr (org-find-text-property-in-string 'org-attributes src)
+	      label (org-find-text-property-in-string 'org-label src)
+	      embed-as 'paragraph)))
+
+      (setq attr-plist (when attr (read  attr)))
+      (setq size (org-odt-image-size-from-file
+		  src (plist-get attr-plist :width)
+		  (plist-get attr-plist :height)
+		  (plist-get attr-plist :scale) nil embed-as))
+
+      (org-export-odt-do-format-image embed-as caption attr label
+				       size href))))
+
+(defun org-export-odt-do-format-image (embed-as caption attr label
+						size href)
+  "Create image tag with source and attributes."
+  (save-match-data
+    (let ((width (car size)) (height (cdr size))
+	  (draw-frame-pair
+	   '("<draw:frame draw:style-name=\"%s\"
+              text:anchor-type=\"%s\"
+              draw:z-index=\"%d\" %s>" . "</draw:frame>")))
+      (cond
+       ((and (not caption) (not label))
+	(let (style-name anchor-type)
+	  (cond
+	   ((eq embed-as 'paragraph)
+	    (setq style-name  "OrgGraphicsParagraph" anchor-type "paragraph"))
+	   ((eq embed-as 'character)
+	    (setq style-name  "OrgGraphicsBaseline" anchor-type "as-char")))
+	  (org-odt-format-tags
+	   draw-frame-pair href style-name anchor-type 0
+	   (org-odt-image-attrs-from-size width height))))
+
+       (t
+	(concat
+	 ;; (when par-open (org-odt-close-par))
+	 (org-odt-format-tags
+	  draw-frame-pair
+	  (org-odt-format-tags
+	   '("<draw:text-box fo:min-height=\"%dcm\">" . "</draw:text-box>")
+	   (org-odt-format-stylized-paragraph
+	    'illustration
+	    (concat
+	     (let ((extra " style:rel-width=\"100%\" style:rel-height=\"scale\""))
+	       (org-odt-format-tags
+		draw-frame-pair href "OrgGraphicsParagraphContent" "paragraph" 2
+		(concat (org-odt-image-attrs-from-size width height) extra)))
+	     (org-odt-format-entity-caption label caption)))
+	   height)
+	  "OrgFrame" "paragraph" 1
+	  (org-odt-image-attrs-from-size width))
+
+	 ;; (when par-open (org-odt-open-par))
+	 ))))))
+
+;; xml files generated on-the-fly
+(defconst org-export-odt-save-list
+  '("META-INF/manifest.xml" "content.xml" "meta.xml" "styles.xml"))
+
+;; xml files that are copied
+(defconst org-export-odt-nosave-list '())
+
+;; xml files that contribute to the final odt file
+(defvar org-export-odt-file-list nil)
+
+(defconst org-export-odt-manifest-lines
+  '(("<?xml version=\"1.0\" encoding=\"UTF-8\"?>"
+     "<manifest:manifest xmlns:manifest=\"urn:oasis:names:tc:opendocument:xmlns:manifest:1.0\" manifest:version=\"1.2\">"
+     "<manifest:file-entry manifest:media-type=\"application/vnd.oasis.opendocument.text\" manifest:version=\"1.2\" manifest:full-path=\"/\"/>"
+     "<manifest:file-entry manifest:media-type=\"text/xml\" manifest:full-path=\"content.xml\"/>"
+     "<manifest:file-entry manifest:media-type=\"text/xml\" manifest:full-path=\"styles.xml\"/>"
+     "<manifest:file-entry manifest:media-type=\"text/xml\" manifest:full-path=\"meta.xml\"/>"
+     "<manifest:file-entry manifest:media-type=\"\" manifest:full-path=\"Pictures/\"/>") . ("</manifest:manifest>")))
+
+(defconst org-export-odt-meta-lines
+  '(("<?xml version=\"1.0\" encoding=\"UTF-8\"?>"
+     "<office:document-meta"
+     "    xmlns:office=\"urn:oasis:names:tc:opendocument:xmlns:office:1.0\""
+     "    xmlns:xlink=\"http://www.w3.org/1999/xlink\""
+     "    xmlns:dc=\"http://purl.org/dc/elements/1.1/\""
+     "    xmlns:meta=\"urn:oasis:names:tc:opendocument:xmlns:meta:1.0\""
+     "    xmlns:ooo=\"http://openoffice.org/2004/office\" "
+     "    office:version=\"1.2\">"
+     "  <office:meta>") . ("  </office:meta>" "</office:document-meta>")))
+
+(defun org-odt-copy-image-file (path &optional target-file)
+  "Returns the internal name of the file"
+  (let* ((image-type (file-name-extension path))
+	 (media-type (format "image/%s" image-type))
+	 (src-file (expand-file-name
+		    path (file-name-directory org-current-export-file)))
+	 (target-file (or target-file (org-odt-get-image-name src-file)))
+	 ;; FIXME
+	 (body-only nil))
+
+    (when (not org-lparse-to-buffer)
+      (message "Embedding %s as %s ..."
+	       (substring-no-properties path) target-file)
+      (copy-file src-file target-file 'overwrite)
+      (org-odt-update-manifest-file media-type target-file)
+      (push target-file org-export-odt-file-list)) target-file))
+
+(defun org-odt-image-attrs-from-size (&optional width height)
+  (concat
+   (when width (format "svg:width=\"%0.2fcm\""  width))
+   " "
+   (when height (format "svg:height=\"%0.2fcm\""  height))))
+
+(defvar org-export-odt-image-size-probe-method
+  '(emacs imagemagick force)
+  "Ordered list of methods by for determining size of an embedded
+  image.")
+
+(defvar org-export-odt-default-image-sizes-alist
+  '(("character" . (5 . 0.4))
+    ("paragraph" . (5 . 5)))
+  "Hardcoded image dimensions one for each of the anchor
+  methods.")
+
+(defun org-odt-do-image-size (probe-method file &optional dpi anchor-type)
+  (setq dpi (or dpi org-export-odt-pixels-per-inch))
+  (setq anchor-type (or anchor-type "paragraph"))
+  (flet ((size-in-cms (size-in-pixels)
+		      (flet ((pixels-to-cms (pixels)
+					    (let* ((cms-per-inch 2.54)
+						   (inches (/ pixels dpi)))
+					      (* cms-per-inch inches))))
+			(and size-in-pixels
+			     (cons (pixels-to-cms (car size-in-pixels))
+				   (pixels-to-cms (cdr size-in-pixels)))))))
+    (case probe-method
+      (emacs
+       (size-in-cms (ignore-errors (image-size (create-image file) 'pixels))))
+      (imagemagick
+       (size-in-cms
+	(let ((dim (shell-command-to-string
+		    (format "identify -format \"%%w:%%h\" \"%s\"" file))))
+	  (when (string-match "\\([0-9]+\\):\\([0-9]+\\)" dim)
+	    (cons (string-to-number (match-string 1 dim))
+		  (string-to-number (match-string 2 dim)))))))
+      (t
+       (cdr (assoc-string anchor-type
+			  org-export-odt-default-image-sizes-alist))))))
+
+(defun org-odt-image-size-from-file (file &optional user-width
+					  user-height scale dpi embed-as)
+  (unless (file-name-absolute-p file)
+    (setq file (expand-file-name
+		file (file-name-directory org-current-export-file))))
+  (let* (size width height)
+    (unless (and user-height user-width)
+      (loop for probe-method in org-export-odt-image-size-probe-method
+	    until size
+	    do (setq size (org-odt-do-image-size
+			   probe-method file dpi embed-as)))
+      (or size (error "Cannot determine Image size. Aborting ..."))
+      (setq width (car size) height (cdr size)))
+    (cond
+     (scale
+      (setq width (* width scale) height (* height scale)))
+     ((and user-height user-width)
+      (setq width user-width height user-height))
+     (user-height
+      (setq width (* user-height (/ width height)) height user-height))
+     (user-width
+      (setq height (* user-width (/ height width)) width user-width))
+     (t (ignore)))
+    (cons width height)))
+
+(defvar org-odt-default-entity "Illustration")
+(defun org-odt-format-entity-caption (label caption &optional default-entity)
+  (if (not label) (or caption "")
+    (let* ((label-components (org-odt-parse-label label))
+	   (entity (car label-components))
+	   (seqno (cdr label-components))
+	   (caption (and caption (concat ": " caption))))
+      (unless seqno
+	(setq seqno label
+	      entity (or default-entity org-odt-default-entity)))
+      (concat
+       entity " "
+       (org-odt-format-tags
+	'("<text:sequence text:ref-name=\"%s\" text:name=\"%s\" text:formula=\"ooow:%s+1\" style:num-format=\"1\">" . "</text:sequence>")
+	seqno label entity entity)
+       caption))))
+
+(defun org-odt-format-tags (tag text &rest args)
+  (let ((prefix (when org-lparse-encode-pending "@"))
+	(suffix (when org-lparse-encode-pending "@")))
+    (apply 'org-lparse-format-tags tag text prefix suffix args)))
+
+(defun org-odt-init-outfile (filename)
+  (let* ((outdir (make-temp-file org-export-odt-tmpdir-prefix t))
+	 (mimetype-file (expand-file-name "mimetype" outdir))
+	 (content-file (expand-file-name "content.xml" outdir))
+	 (manifest-file (expand-file-name "META-INF/manifest.xml" outdir))
+	 (meta-file (expand-file-name "meta.xml" outdir))
+	 (styles-file (expand-file-name "styles.xml" outdir))
+	 (pictures-dir (expand-file-name "Pictures" outdir))
+	 (body-only nil))
+
+    ;; content file
+    (with-current-buffer (find-file-noselect content-file t)
+      (erase-buffer))
+
+    ;; FIXME: How to factor in body-only here
+    (unless body-only
+      ;; manifest file
+      (make-directory (file-name-directory manifest-file))
+      (with-current-buffer (find-file-noselect manifest-file t)
+	(erase-buffer)
+	(insert (mapconcat 'identity (car org-export-odt-manifest-lines) "\n"))
+	(insert "\n")
+	(save-excursion
+	  (insert (mapconcat 'identity (cdr org-export-odt-manifest-lines) "\n"))))
+
+    ;; meta file
+    (with-current-buffer (find-file-noselect meta-file t)
+      (erase-buffer)
+      (insert (mapconcat 'identity (car org-export-odt-meta-lines) "\n"))
+      (insert "\n")
+      (save-excursion
+	(insert (mapconcat 'identity (cdr org-export-odt-meta-lines) "\n"))))
+
+    ;; styles file
+    ;; (copy-file org-export-odt-styles-file styles-file t)
+
+    ;; Pictures dir
+    (make-directory pictures-dir)
+
+    ;; initialize list of files that contribute to the odt file
+    (setq org-export-odt-file-list
+	  (append org-export-odt-save-list org-export-odt-nosave-list)))
+    content-file))
+
+(defconst org-export-odt-mimetype-lines
+  '("application/vnd.oasis.opendocument.text"))
+
+(defconst org-odt-manifest-file-entry-tag
+  "<manifest:file-entry manifest:media-type=\"%s\" manifest:full-path=\"%s\"/>")
+
+(defun org-odt-save-as-outfile (target opt-plist)
+  ;; write meta file
+  (org-odt-update-meta-file opt-plist)
+
+  ;; write styles file
+  (org-odt-copy-styles-file)
+
+  ;; Update styles.xml - take care of outline numbering
+  (with-current-buffer
+      (find-file-noselect (expand-file-name "styles.xml") t)
+    ;; Don't make automatic backup of styles.xml file. This setting
+    ;; prevents the backedup styles.xml file from being zipped in to
+    ;; odt file. This is more of a hackish fix. Better alternative
+    ;; would be to fix the zip command so that the output odt file
+    ;; includes only the needed files and excludes any auto-generated
+    ;; extra files like backups and auto-saves etc etc. Note that
+    ;; currently the zip command zips up the entire temp directory so
+    ;; that any auto-generated files created under the hood ends up in
+    ;; the resulting odt file.
+    (set (make-local-variable 'backup-inhibited) t)
+
+    ;; Import local setting of `org-export-with-section-numbers'
+    (org-lparse-bind-local-variables opt-plist)
+    (org-odt-configure-outline-numbering
+     (if org-export-with-section-numbers org-export-headline-levels 0)))
+
+  (let ((zipdir default-directory))
+    (message "Switching to directory %s" (expand-file-name zipdir))
+
+    ;; save all xml files
+    (mapc (lambda (file)
+	    (with-current-buffer
+		(find-file-noselect (expand-file-name file) t)
+	      ;; prettify output
+	      (indent-region (point-min) (point-max))
+	      (save-buffer)))
+	  org-export-odt-save-list)
+
+    (let* ((target-name (file-name-nondirectory target))
+	   (target-dir (file-name-directory target))
+	   (cmd (format "zip -rmTq %s %s" target-name ".")))
+      (when (file-exists-p target)
+	;; FIXME: If the file is locked this throws a cryptic error
+	(delete-file target))
+
+      (let ((coding-system-for-write 'no-conversion) exitcode)
+	(message "Creating odt file using \"%s\"" cmd)
+	(setq exitcode
+	      (apply 'call-process
+		     "zip"
+		     nil
+		     nil
+		     nil
+		     (append (list "-rmTq") (list target-name "."))))
+
+	(or (zerop exitcode)
+	    (error "Unable to create odt file (%S)" exitcode)))
+
+      ;; move the file from outdir to target-dir
+      (rename-file target-name target-dir)
+
+      ;; kill all xml buffers
+      (mapc (lambda (file)
+	      (kill-buffer
+	       (find-file-noselect (expand-file-name file zipdir) t)))
+	    org-export-odt-save-list)
+
+      (delete-directory zipdir)))
+
+  (message "Created %s" target)
+  (set-buffer (find-file-noselect target t)))
+
+(defun org-odt-update-meta-file (opt-plist)
+  (with-current-buffer
+      (find-file-noselect (expand-file-name "meta.xml") t)
+    (let ((date (or (plist-get opt-plist :effective-date) ""))
+	  (author (or (plist-get opt-plist :author) ""))
+	  (email (plist-get opt-plist :email))
+	  (keywords (plist-get opt-plist :keywords))
+	  (description (plist-get opt-plist :description))
+	  (title (plist-get opt-plist :title)))
+
+      (insert
+       "\n"
+       (org-odt-format-tags '("<dc:creator>" . "</dc:creator>") author)
+       (org-odt-format-tags
+	'("\n<meta:initial-creator>" . "</meta:initial-creator>") author)
+       (org-odt-format-tags '("\n<dc:date>" . "</dc:date>") date)
+       (org-odt-format-tags
+	'("\n<meta:creation-date>" . "</meta:creation-date>") date)
+       (org-odt-format-tags '("\n<meta:generator>" . "</meta:generator>")
+			     (when org-export-creator-info
+			       (format "Org-%s/Emacs-%s"
+				       org-version emacs-version)))
+       (org-odt-format-tags '("\n<meta:keyword>" . "</meta:keyword>") keywords)
+       (org-odt-format-tags '("\n<dc:subject>" . "</dc:subject>") description)
+       (org-odt-format-tags '("\n<dc:title>" . "</dc:title>") title)
+       "\n"))))
+
+(defun org-odt-update-manifest-file (media-type full-path)
+  (with-current-buffer
+      (find-file-noselect (expand-file-name "META-INF/manifest.xml") t)
+    (insert (format org-odt-manifest-file-entry-tag media-type full-path))))
+
+(defun org-odt-finalize-outfile ()
+  (message "org-newodt: Finalizing outfile")
+  (org-odt-delete-empty-paragraphs))
+
+(defun org-odt-delete-empty-paragraphs ()
+  (goto-char (point-min))
+  (let ((open "<text:p[^>]*>")
+	(close "</text:p>"))
+    (while (re-search-forward (format "%s[ \r\n\t]*%s" open close) nil t)
+      (replace-match ""))))
+
+(defun org-odt-get (what &optional opt-plist)
+  (case what
+    (BACKEND 'odt)
+    (EXPORT-DIR (org-export-directory :html opt-plist))
+    (FILE-NAME-EXTENSION "odt")
+    (EXPORT-BUFFER-NAME "*Org ODT Export*")
+    (ENTITY-CONTROL org-odt-entity-control-callbacks-alist)
+    (ENTITY-FORMAT org-odt-entity-format-callbacks-alist)
+    (INIT-METHOD 'org-odt-init-outfile)
+    (FINAL-METHOD 'org-odt-finalize-outfile)
+    (SAVE-METHOD 'org-odt-save-as-outfile)
+    (OTHER-BACKENDS
+     '("bib" "doc" "doc6" "doc95" "html" "xhtml" "latex" "odt" "ott" "pdf" "rtf"
+       "sdw" "sdw3" "sdw4" "stw " "sxw" "mediawiki" "text" "txt" "uot" "vor"
+       "vor3" "vor4" "docbook" "ooxml" "ppt" "odp"))
+    (CONVERT-METHOD org-export-convert-process)
+    (TOPLEVEL-HLEVEL 1)
+    (SPECIAL-STRING-REGEXPS org-export-odt-special-string-regexps)
+    (INLINE-IMAGES 'maybe)
+    (INLINE-IMAGE-EXTENSIONS '("png" "jpeg" "jpg" "gif" "svg"))
+    (PLAIN-TEXT-MAP '(("&" . "&amp;") ("<" . "&lt;") (">" . "&gt;")))
+    (TABLE-FIRST-COLUMN-AS-LABELS nil)
+    (FOOTNOTE-SEPARATOR (org-lparse-format 'FONTIFY "," 'superscript))
+    (t (error "Unknown property: %s"  what))))
+
+(defun org-odt-parse-label (label)
+  (save-match-data
+    (if (not (string-match "\\`[a-zA-Z]+:\\(.+\\)" label))
+	(cons label nil)
+      (cons
+       (capitalize (substring label 0 (1- (match-beginning 1))))
+       (substring label (match-beginning 1))))))
+
+(defvar org-lparse-latex-fragment-fallback) ; set by org-do-lparse
+(defun org-export-odt-preprocess (parameters)
+  "Convert LaTeX fragments to images."
+  (when (and org-current-export-file
+	     (plist-get parameters :LaTeX-fragments))
+    (org-format-latex
+     (concat "ltxpng/" (file-name-sans-extension
+			(file-name-nondirectory
+			 org-current-export-file)))
+     org-current-export-dir nil "Creating LaTeX image %s"
+     nil nil
+     (cond
+      ((eq (plist-get parameters :LaTeX-fragments) 'verbatim) 'verbatim)
+      ;; Investigate MathToWeb for converting TeX equations to MathML
+      ;; See http://lists.gnu.org/archive/html/emacs-orgmode/2011-03/msg01755.html
+      ((or (eq (plist-get parameters :LaTeX-fragments) 'mathjax )
+	   (eq (plist-get parameters :LaTeX-fragments) t        ))
+       (org-lparse-warn
+	(concat
+	 "Use of MathJax is incompatible with ODT exporter. "
+	 (format "Using %S instead."  org-lparse-latex-fragment-fallback)))
+	 org-lparse-latex-fragment-fallback)
+      ((eq (plist-get parameters :LaTeX-fragments) 'dvipng  ) 'dvipng)
+      (t nil))))
+  (goto-char (point-min))
+  (let (label label-components category value pretty-label)
+    (while (re-search-forward "\\\\ref{\\([^{}\n]+\\)}" nil t)
+      (org-if-unprotected-at (match-beginning 1)
+	(setq label (match-string 1)
+	      label-components (org-odt-parse-label label)
+	      category (car label-components)
+	      value (cdr label-components)
+	      pretty-label (if value (concat category " " value) label))
+	(replace-match
+	 (let ((org-lparse-encode-pending t))
+	   (org-odt-format-tags
+	    '("<text:sequence-ref text:reference-format=\"category-and-value\" text:ref-name=\"%s\">"
+	      . "</text:sequence-ref>") pretty-label label)) t t)))))
+
+(declare-function archive-zip-extract "arc-mode.el" (archive name))
+(defun org-odt-zip-extract-one (archive member &optional target)
+  (require 'arc-mode)
+  (let* ((target (or target default-directory))
+	 (archive (expand-file-name archive))
+	 (archive-zip-extract
+	  (list "unzip" "-qq" "-o" "-d" target))
+	 exit-code command-output)
+    (setq command-output
+	  (with-temp-buffer
+	    (setq exit-code (archive-zip-extract archive member))
+	    (buffer-string)))
+    (unless (zerop exit-code)
+      (message command-output)
+      (error "Extraction failed"))))
+
+(defun org-odt-zip-extract (archive members &optional target)
+  (when (atom members) (setq members (list members)))
+  (mapc (lambda (member)
+	  (org-odt-zip-extract-one archive member target))
+	members))
+
+(defun org-odt-copy-styles-file (&optional styles-file)
+  ;; Non-availability of styles.xml is not a critical error. For now
+  ;; throw an error purely for aesthetic reasons.
+  (setq styles-file (or styles-file
+			org-export-odt-styles-file
+			(expand-file-name "styles/OrgOdtStyles.xml"
+					  org-odt-data-dir)
+			(error "org-odt: Missing styles file?")))
+  (cond
+   ((listp styles-file)
+    (let ((archive (nth 0 styles-file))
+	  (members (nth 1 styles-file)))
+      (org-odt-zip-extract archive members)
+      (mapc
+       (lambda (member)
+	 (when (org-file-image-p member)
+	   (let* ((image-type (file-name-extension member))
+		  (media-type (format "image/%s" image-type)))
+	     (org-odt-update-manifest-file media-type member))))
+       members)))
+   ((and (stringp styles-file) (file-exists-p styles-file))
+    (let ((styles-file-type (file-name-extension styles-file)))
+      (cond
+       ((string= styles-file-type "xml")
+	(copy-file styles-file "styles.xml" t))
+       ((member styles-file-type '("odt" "ott"))
+	(org-odt-zip-extract styles-file "styles.xml")))))
+   (t
+    (error (format "Invalid specification of styles.xml file: %S"
+		   org-export-odt-styles-file)))))
+
+(defvar org-export-odt-factory-settings
+  "d4328fb9d1b6cb211d4320ff546829f26700dc5e"
+  "SHA1 hash of OrgOdtStyles.xml.")
+
+(defun org-odt-configure-outline-numbering (level)
+  "Outline numbering is retained only upto LEVEL.
+To disable outline numbering pass a LEVEL of 0."
+  (if (not (string= org-export-odt-factory-settings (sha1 (current-buffer))))
+      (org-lparse-warn
+       "org-odt: Using custom styles file? Consider tweaking styles.xml for better output. To suppress this warning update `org-export-odt-factory-settings'")
+    (goto-char (point-min))
+    (let ((regex
+	   "<text:outline-level-style\\(.*\\)text:level=\"\\(.*\\)\"\\(.*\\)>")
+	  (replacement
+	   "<text:outline-level-style\\1text:level=\"\\2\" style:num-format=\"\">"))
+      (while (re-search-forward regex nil t)
+	(when (> (string-to-number (match-string 1)) level)
+	  (replace-match replacement t nil))))
+    (save-buffer 0)))
+
+;;;###autoload
+(defun org-odt-unit-test (&optional linger)
+  "Automatically visit the Unit Test file and export it."
+  (interactive "P")
+  (with-current-buffer
+      (find-file (expand-file-name "tests/test.org" org-odt-data-dir))
+    (unless linger
+      (call-interactively 'org-export-as-odt-and-open))))
+
+(provide 'org-odt)
+
+;;; org-odt.el ends here

+ 1797 - 0
contrib/lisp/org-xhtml.el

@@ -0,0 +1,1797 @@
+;;; org-html.el --- HTML export for Org-mode (uses org-lparse)
+
+;; Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011
+;;   Free Software Foundation, Inc.
+
+;; Author: Carsten Dominik <carsten at orgmode dot org>
+;; Keywords: outlines, hypermedia, calendar, wp
+;; Homepage: http://orgmode.org
+;; Version: 0.8
+
+;; This file is not (yet) part of GNU Emacs.
+;; However, it is distributed under the same license.
+
+;; GNU Emacs is free software: you can redistribute it and/or modify
+;; it under the terms of the GNU General Public License as published by
+;; the Free Software Foundation, either version 3 of the License, or
+;; (at your option) any later version.
+
+;; GNU Emacs is distributed in the hope that it will be useful,
+;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+;; GNU General Public License for more details.
+
+;; You should have received a copy of the GNU General Public License
+;; along with GNU Emacs.  If not, see <http://www.gnu.org/licenses/>.
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;;
+;;; Commentary:
+
+;;; Code:
+
+(require 'org-exp)
+(require 'format-spec)
+
+(require 'org-lparse)
+
+(eval-when-compile (require 'cl) (require 'table) (require 'browse-url))
+
+(declare-function org-id-find-id-file "org-id" (id))
+(declare-function htmlize-region "ext:htmlize" (beg end))
+
+(defgroup org-export-html nil
+  "Options specific for HTML export of Org-mode files."
+  :tag "Org Export HTML"
+  :group 'org-export)
+
+(defcustom org-export-html-footnotes-section "<div id=\"footnotes\">
+<h2 class=\"footnotes\">%s: </h2>
+<div id=\"text-footnotes\">
+%s
+</div>
+</div>"
+  "Format for the footnotes section.
+Should contain a two instances of %s.  The first will be replaced with the
+language-specific word for \"Footnotes\", the second one will be replaced
+by the footnotes themselves."
+  :group 'org-export-html
+  :type 'string)
+
+(defcustom org-export-html-footnote-format "<sup>%s</sup>"
+  "The format for the footnote reference.
+%s will be replaced by the footnote reference itself."
+  :group 'org-export-html
+  :type 'string)
+
+
+(defcustom org-export-html-footnote-separator "<sup>, </sup>"
+  "Text used to separate footnotes."
+  :group 'org-export-html
+  :type 'string)
+
+(defcustom org-export-html-coding-system nil
+  "Coding system for HTML export, defaults to `buffer-file-coding-system'."
+  :group 'org-export-html
+  :type 'coding-system)
+
+(defcustom org-export-html-extension "html"
+  "The extension for exported HTML files."
+  :group 'org-export-html
+  :type 'string)
+
+(defcustom org-export-html-xml-declaration
+  '(("html" . "<?xml version=\"1.0\" encoding=\"%s\"?>")
+    ("php" . "<?php echo \"<?xml version=\\\"1.0\\\" encoding=\\\"%s\\\" ?>\"; ?>"))
+  "The extension for exported HTML files.
+%s will be replaced with the charset of the exported file.
+This may be a string, or an alist with export extensions
+and corresponding declarations."
+  :group 'org-export-html
+  :type '(choice
+	  (string :tag "Single declaration")
+	  (repeat :tag "Dependent on extension"
+		  (cons (string :tag "Extension")
+			(string :tag "Declaration")))))
+
+(defcustom org-export-html-style-include-scripts t
+  "Non-nil means include the JavaScript snippets in exported HTML files.
+The actual script is defined in `org-export-html-scripts' and should
+not be modified."
+  :group 'org-export-html
+  :type 'boolean)
+
+(defconst org-export-html-scripts
+"<script type=\"text/javascript\">
+<!--/*--><![CDATA[/*><!--*/
+ function CodeHighlightOn(elem, id)
+ {
+   var target = document.getElementById(id);
+   if(null != target) {
+     elem.cacheClassElem = elem.className;
+     elem.cacheClassTarget = target.className;
+     target.className = \"code-highlighted\";
+     elem.className   = \"code-highlighted\";
+   }
+ }
+ function CodeHighlightOff(elem, id)
+ {
+   var target = document.getElementById(id);
+   if(elem.cacheClassElem)
+     elem.className = elem.cacheClassElem;
+   if(elem.cacheClassTarget)
+     target.className = elem.cacheClassTarget;
+ }
+/*]]>*///-->
+</script>"
+"Basic JavaScript that is needed by HTML files produced by Org-mode.")
+
+(defconst org-export-html-style-default
+"<style type=\"text/css\">
+ <!--/*--><![CDATA[/*><!--*/
+  html { font-family: Times, serif; font-size: 12pt; }
+  .title  { text-align: center; }
+  .todo   { color: red; }
+  .done   { color: green; }
+  .tag    { background-color: #add8e6; font-weight:normal }
+  .target { }
+  .timestamp { color: #bebebe; }
+  .timestamp-kwd { color: #5f9ea0; }
+  .right  {margin-left:auto; margin-right:0px;  text-align:right;}
+  .left   {margin-left:0px;  margin-right:auto; text-align:left;}
+  .center {margin-left:auto; margin-right:auto; text-align:center;}
+  p.verse { margin-left: 3% }
+  pre {
+	border: 1pt solid #AEBDCC;
+	background-color: #F3F5F7;
+	padding: 5pt;
+	font-family: courier, monospace;
+        font-size: 90%;
+        overflow:auto;
+  }
+  table { border-collapse: collapse; }
+  td, th { vertical-align: top;  }
+  th.right  { text-align:center;  }
+  th.left   { text-align:center;   }
+  th.center { text-align:center; }
+  td.right  { text-align:right;  }
+  td.left   { text-align:left;   }
+  td.center { text-align:center; }
+  dt { font-weight: bold; }
+  div.figure { padding: 0.5em; }
+  div.figure p { text-align: center; }
+  textarea { overflow-x: auto; }
+  .linenr { font-size:smaller }
+  .code-highlighted {background-color:#ffff00;}
+  .org-info-js_info-navigation { border-style:none; }
+  #org-info-js_console-label { font-size:10px; font-weight:bold;
+                               white-space:nowrap; }
+  .org-info-js_search-highlight {background-color:#ffff00; color:#000000;
+                                 font-weight:bold; }
+  /*]]>*/-->
+</style>"
+  "The default style specification for exported HTML files.
+Please use the variables `org-export-html-style' and
+`org-export-html-style-extra' to add to this style.  If you wish to not
+have the default style included, customize the variable
+`org-export-html-style-include-default'.")
+
+(defcustom org-export-html-style-include-default t
+  "Non-nil means include the default style in exported HTML files.
+The actual style is defined in `org-export-html-style-default' and should
+not be modified.  Use the variables `org-export-html-style' to add
+your own style information."
+  :group 'org-export-html
+  :type 'boolean)
+;;;###autoload
+(put 'org-export-html-style-include-default 'safe-local-variable 'booleanp)
+
+(defcustom org-export-html-style ""
+  "Org-wide style definitions for exported HTML files.
+
+This variable needs to contain the full HTML structure to provide a style,
+including the surrounding HTML tags.  If you set the value of this variable,
+you should consider to include definitions for the following classes:
+ title, todo, done, timestamp, timestamp-kwd, tag, target.
+
+For example, a valid value would be:
+
+   <style type=\"text/css\">
+    <![CDATA[
+       p { font-weight: normal; color: gray; }
+       h1 { color: black; }
+      .title { text-align: center; }
+      .todo, .timestamp-kwd { color: red; }
+      .done { color: green; }
+    ]]>
+   </style>
+
+If you'd like to refer to an external style file, use something like
+
+   <link rel=\"stylesheet\" type=\"text/css\" href=\"mystyles.css\">
+
+As the value of this option simply gets inserted into the HTML <head> header,
+you can \"misuse\" it to add arbitrary text to the header.
+See also the variable `org-export-html-style-extra'."
+  :group 'org-export-html
+  :type 'string)
+;;;###autoload
+(put 'org-export-html-style 'safe-local-variable 'stringp)
+
+(defcustom org-export-html-style-extra ""
+  "Additional style information for HTML export.
+The value of this variable is inserted into the HTML buffer right after
+the value of `org-export-html-style'.  Use this variable for per-file
+settings of style information, and do not forget to surround the style
+settings with <style>...</style> tags."
+  :group 'org-export-html
+  :type 'string)
+;;;###autoload
+(put 'org-export-html-style-extra 'safe-local-variable 'stringp)
+
+(defcustom org-export-html-mathjax-options
+  '((path  "http://orgmode.org/mathjax/MathJax.js")
+    (scale "100")
+    (align "center")
+    (indent "2em")
+    (mathml nil))
+  "Options for MathJax setup.
+
+path        The path where to find MathJax
+scale       Scaling for the HTML-CSS backend, usually between 100 and 133
+align       How to align display math: left, center, or right
+indent      If align is not center, how far from the left/right side?
+mathml      Should a MathML player be used if available?
+            This is faster and reduces bandwidth use, but currently
+            sometimes has lower spacing quality.  Therefore, the default is
+            nil.  When browsers get better, this switch can be flipped.
+
+You can also customize this for each buffer, using something like
+
+#+MATHJAX: scale:\"133\" align:\"right\" mathml:t path:\"/MathJax/\""
+  :group 'org-export-html
+  :type '(list :greedy t
+	      (list :tag "path   (the path from where to load MathJax.js)"
+		    (const :format "       " path) (string))
+	      (list :tag "scale  (scaling for the displayed math)"
+		    (const :format "       " scale) (string))
+	      (list :tag "align  (alignment of displayed equations)"
+		    (const :format "       " align) (string))
+	      (list :tag "indent (indentation with left or right alignment)"
+		    (const :format "       " indent) (string))
+	      (list :tag "mathml (should MathML display be used is possible)"
+		    (const :format "       " mathml) (boolean))))
+
+(defun org-export-html-mathjax-config (template options in-buffer)
+  "Insert the user setup into the matchjax template."
+  (let (name val (yes "   ") (no "// ") x)
+    (mapc
+     (lambda (e)
+       (setq name (car e) val (nth 1 e))
+       (if (string-match (concat "\\<" (symbol-name name) ":") in-buffer)
+	   (setq val (car (read-from-string
+			   (substring in-buffer (match-end 0))))))
+       (if (not (stringp val)) (setq val (format "%s" val)))
+       (if (string-match (concat "%" (upcase (symbol-name name))) template)
+	   (setq template (replace-match val t t template))))
+     options)
+    (setq val (nth 1 (assq 'mathml options)))
+    (if (string-match (concat "\\<mathml:") in-buffer)
+	(setq val (car (read-from-string
+			(substring in-buffer (match-end 0))))))
+    ;; Exchange prefixes depending on mathml setting
+    (if (not val) (setq x yes yes no no x))
+    ;; Replace cookies to turn on or off the config/jax lines
+    (if (string-match ":MMLYES:" template)
+	(setq template (replace-match yes t t template)))
+    (if (string-match ":MMLNO:" template)
+	(setq template (replace-match no t t template)))
+    ;; Return the modified template
+    template))
+
+(defcustom org-export-html-mathjax-template
+  "<script type=\"text/javascript\" src=\"%PATH\">
+<!--/*--><![CDATA[/*><!--*/
+    MathJax.Hub.Config({
+        // Only one of the two following lines, depending on user settings
+        // First allows browser-native MathML display, second forces HTML/CSS
+        :MMLYES: config: [\"MMLorHTML.js\"], jax: [\"input/TeX\"],
+        :MMLNO: jax: [\"input/TeX\", \"output/HTML-CSS\"],
+        extensions: [\"tex2jax.js\",\"TeX/AMSmath.js\",\"TeX/AMSsymbols.js\",
+                     \"TeX/noUndefined.js\"],
+        tex2jax: {
+            inlineMath: [ [\"\\\\(\",\"\\\\)\"] ],
+            displayMath: [ ['$$','$$'], [\"\\\\[\",\"\\\\]\"], [\"\\\\begin{displaymath}\",\"\\\\end{displaymath}\"] ],
+            skipTags: [\"script\",\"noscript\",\"style\",\"textarea\",\"pre\",\"code\"],
+            ignoreClass: \"tex2jax_ignore\",
+            processEscapes: false,
+            processEnvironments: true,
+            preview: \"TeX\"
+        },
+        showProcessingMessages: true,
+        displayAlign: \"%ALIGN\",
+        displayIndent: \"%INDENT\",
+
+        \"HTML-CSS\": {
+             scale: %SCALE,
+             availableFonts: [\"STIX\",\"TeX\"],
+             preferredFont: \"TeX\",
+             webFont: \"TeX\",
+             imageFont: \"TeX\",
+             showMathMenu: true,
+        },
+        MMLorHTML: {
+             prefer: {
+                 MSIE:    \"MML\",
+                 Firefox: \"MML\",
+                 Opera:   \"HTML\",
+                 other:   \"HTML\"
+             }
+        }
+    });
+/*]]>*///-->
+</script>"
+  "The MathJax setup for XHTML files."
+  :group 'org-export-html
+  :type 'string)
+
+(defcustom org-export-html-tag-class-prefix ""
+  "Prefix to class names for TODO keywords.
+Each tag gets a class given by the tag itself, with this prefix.
+The default prefix is empty because it is nice to just use the keyword
+as a class name.  But if you get into conflicts with other, existing
+CSS classes, then this prefix can be very useful."
+  :group 'org-export-html
+  :type 'string)
+
+(defcustom org-export-html-todo-kwd-class-prefix ""
+  "Prefix to class names for TODO keywords.
+Each TODO keyword gets a class given by the keyword itself, with this prefix.
+The default prefix is empty because it is nice to just use the keyword
+as a class name.  But if you get into conflicts with other, existing
+CSS classes, then this prefix can be very useful."
+  :group 'org-export-html
+  :type 'string)
+
+(defcustom org-export-html-preamble t
+  "Non-nil means insert a preamble in HTML export.
+
+When `t', insert a string as defined by one of the formatting
+strings in `org-export-html-preamble-format'.  When set to a
+string, this string overrides `org-export-html-preamble-format'.
+When set to a function, apply this function and insert the
+returned string.  The function takes the property list of export
+options as its only argument.
+
+Setting :html-preamble in publishing projects will take
+precedence over this variable."
+  :group 'org-export-html
+  :type '(choice (const :tag "No preamble" nil)
+		 (const :tag "Default preamble" t)
+		 (string :tag "Custom formatting string")
+		 (function :tag "Function (must return a string)")))
+
+(defcustom org-export-html-preamble-format
+  '(("en" "<h1 class=\"title\">%t</h1>"))
+  "The format for the HTML preamble.
+
+%t stands for the title.
+
+If you need to use a \"%\" character, you need to escape it
+like that: \"%%\"."
+  :group 'org-export-html
+  :type 'string)
+
+(defcustom org-export-html-postamble 'auto
+  "Non-nil means insert a postamble in HTML export.
+
+When `t', insert a string as defined by the formatting string in
+`org-export-html-postamble-format'.  When set to a string, this
+string overrides `org-export-html-postamble-format'.  When set to
+'auto, discard `org-export-html-postamble-format' and honor
+`org-export-author/email/creator-info' variables.  When set to a
+function, apply this function and insert the returned string.
+The function takes the property list of export options as its
+only argument.
+
+Setting :html-postamble in publishing projects will take
+precedence over this variable."
+  :group 'org-export-html
+  :type '(choice (const :tag "No postamble" nil)
+		 (const :tag "Auto preamble" 'auto)
+		 (const :tag "Default formatting string" t)
+		 (string :tag "Custom formatting string")
+		 (function :tag "Function (must return a string)")))
+
+(defcustom org-export-html-postamble-format
+  '(("en" "<p class=\"author\">Author: %a (%e)</p>
+<p class=\"date\">Date: %d</p>
+<p class=\"creator\">Generated by %c</p>
+<p class=\"xhtml-validation\">%v</p>
+"))
+  "The format for the HTML postamble.
+
+%a stands for the author.
+%e stands for the email(s).
+%d stands for the date.
+%c will be replaced by information about Org/Emacs.
+%v will be replaced by `org-export-html-validation-link'.
+
+If you need to use a \"%\" character, you need to escape it
+like that: \"%%\"."
+  :group 'org-export-html
+  :type 'string)
+
+(defcustom org-export-html-home/up-format
+  "<div id=\"org-div-home-and-up\" style=\"text-align:right;font-size:70%%;white-space:nowrap;\">
+ <a accesskey=\"h\" href=\"%s\"> UP </a>
+ |
+ <a accesskey=\"H\" href=\"%s\"> HOME </a>
+</div>"
+  "Snippet used to insert the HOME and UP links.
+This is a format string, the first %s will receive the UP link,
+the second the HOME link.  If both `org-export-html-link-up' and
+`org-export-html-link-home' are empty, the entire snippet will be
+ignored."
+  :group 'org-export-html
+  :type 'string)
+
+(defcustom org-export-html-toplevel-hlevel 2
+  "The <H> level for level 1 headings in HTML export.
+This is also important for the classes that will be wrapped around headlines
+and outline structure.  If this variable is 1, the top-level headlines will
+be <h1>, and the corresponding classes will be outline-1, section-number-1,
+and outline-text-1.  If this is 2, all of these will get a 2 instead.
+The default for this variable is 2, because we use <h1> for formatting the
+document title."
+  :group 'org-export-html
+  :type 'string)
+
+(defcustom org-export-html-link-org-files-as-html t
+  "Non-nil means make file links to `file.org' point to `file.html'.
+When org-mode is exporting an org-mode file to HTML, links to
+non-html files are directly put into a href tag in HTML.
+However, links to other Org-mode files (recognized by the
+extension `.org.) should become links to the corresponding html
+file, assuming that the linked org-mode file will also be
+converted to HTML.
+When nil, the links still point to the plain `.org' file."
+  :group 'org-export-html
+  :type 'boolean)
+
+(defcustom org-export-html-inline-images 'maybe
+  "Non-nil means inline images into exported HTML pages.
+This is done using an <img> tag.  When nil, an anchor with href is used to
+link to the image.  If this option is `maybe', then images in links with
+an empty description will be inlined, while images with a description will
+be linked only."
+  :group 'org-export-html
+  :type '(choice (const :tag "Never" nil)
+		 (const :tag "Always" t)
+		 (const :tag "When there is no description" maybe)))
+
+(defcustom org-export-html-inline-image-extensions
+  '("png" "jpeg" "jpg" "gif" "svg")
+  "Extensions of image files that can be inlined into HTML."
+  :group 'org-export-html
+  :type '(repeat (string :tag "Extension")))
+
+(defcustom org-export-html-table-tag
+  "<table border=\"2\" cellspacing=\"0\" cellpadding=\"6\" rules=\"groups\" frame=\"hsides\">"
+  "The HTML tag that is used to start a table.
+This must be a <table> tag, but you may change the options like
+borders and spacing."
+  :group 'org-export-html
+  :type 'string)
+
+(defcustom org-export-table-header-tags '("<th scope=\"%s\"%s>" . "</th>")
+  "The opening tag for table header fields.
+This is customizable so that alignment options can be specified.
+The first %s will be filled with the scope of the field, either row or col.
+The second %s will be replaced by a style entry to align the field.
+See also the variable `org-export-html-table-use-header-tags-for-first-column'.
+See also the variable `org-export-html-table-align-individual-fields'."
+  :group 'org-export-tables
+  :type '(cons (string :tag "Opening tag") (string :tag "Closing tag")))
+
+(defcustom org-export-table-data-tags '("<td%s>" . "</td>")
+  "The opening tag for table data fields.
+This is customizable so that alignment options can be specified.
+The first %s will be filled with the scope of the field, either row or col.
+The second %s will be replaced by a style entry to align the field.
+See also the variable `org-export-html-table-align-individual-fields'."
+  :group 'org-export-tables
+  :type '(cons (string :tag "Opening tag") (string :tag "Closing tag")))
+
+(defcustom org-export-table-row-tags '("<tr>" . "</tr>")
+  "The opening tag for table data fields.
+This is customizable so that alignment options can be specified.
+Instead of strings, these can be Lisp forms that will be evaluated
+for each row in order to construct the table row tags.  During evaluation,
+the variable `head' will be true when this is a header line, nil when this
+is a body line.  And the variable `nline' will contain the line number,
+starting from 1 in the first header line.  For example
+
+  (setq org-export-table-row-tags
+        (cons '(if head
+                   \"<tr>\"
+                 (if (= (mod nline 2) 1)
+                     \"<tr class=\\\"tr-odd\\\">\"
+                   \"<tr class=\\\"tr-even\\\">\"))
+              \"</tr>\"))
+
+will give even lines the class \"tr-even\" and odd lines the class \"tr-odd\"."
+  :group 'org-export-tables
+  :type '(cons
+	  (choice :tag "Opening tag"
+		  (string :tag "Specify")
+		  (sexp))
+	  (choice :tag "Closing tag"
+		  (string :tag "Specify")
+		  (sexp))))
+
+(defcustom org-export-html-table-align-individual-fields t
+  "Non-nil means attach style attributes for alignment to each table field.
+When nil, alignment will only be specified in the column tags, but this
+is ignored by some browsers (like Firefox, Safari).  Opera does it right
+though."
+  :group 'org-export-tables
+  :type 'boolean)
+
+(defcustom org-export-html-table-use-header-tags-for-first-column nil
+  "Non-nil means format column one in tables with header tags.
+When nil, also column one will use data tags."
+  :group 'org-export-tables
+  :type 'boolean)
+
+(defcustom org-export-html-validation-link
+  "<a href=\"http://validator.w3.org/check?uri=referer\">Validate XHTML 1.0</a>"
+  "Link to HTML validation service."
+  :group 'org-export-html
+  :type 'string)
+
+(defcustom org-export-html-with-timestamp nil
+  "If non-nil, write timestamp into the exported HTML text.
+If non-nil, write `org-export-html-html-helper-timestamp' into the
+exported HTML text.  Otherwise, the buffer will just be saved to
+a file."
+  :group 'org-export-html
+  :type 'boolean)
+
+(defcustom org-export-html-html-helper-timestamp
+  "<br/><br/><hr/><p><!-- hhmts start --> <!-- hhmts end --></p>\n"
+  "The HTML tag used as timestamp delimiter for HTML-helper-mode."
+  :group 'org-export-html
+  :type 'string)
+
+(defcustom org-export-html-protect-char-alist
+  '(("&" . "&amp;")
+    ("<" . "&lt;")
+    (">" . "&gt;"))
+  "Alist of characters to be converted by `org-html-protect'."
+  :type '(repeat (cons (string :tag "Character")
+		       (string :tag "HTML equivalent"))))
+
+(defgroup org-export-htmlize nil
+  "Options for processing examples with htmlize.el."
+  :tag "Org Export Htmlize"
+  :group 'org-export-html)
+
+(defcustom org-export-htmlize-output-type 'inline-css
+  "Output type to be used by htmlize when formatting code snippets.
+Choices are `css', to export the CSS selectors only, or `inline-css', to
+export the CSS attribute values inline in the HTML.  We use as default
+`inline-css', in order to make the resulting HTML self-containing.
+
+However, this will fail when using Emacs in batch mode for export, because
+then no rich font definitions are in place.  It will also not be good if
+people with different Emacs setup contribute HTML files to a website,
+because the fonts will represent the individual setups.  In these cases,
+it is much better to let Org/Htmlize assign classes only, and to use
+a style file to define the look of these classes.
+To get a start for your css file, start Emacs session and make sure that
+all the faces you are interested in are defined, for example by loading files
+in all modes you want.  Then, use the command
+\\[org-export-htmlize-generate-css] to extract class definitions."
+  :group 'org-export-htmlize
+  :type '(choice (const css) (const inline-css)))
+
+(defcustom org-export-htmlize-css-font-prefix "org-"
+  "The prefix for CSS class names for htmlize font specifications."
+  :group 'org-export-htmlize
+  :type 'string)
+
+(defcustom org-export-htmlized-org-css-url nil
+  "URL pointing to a CSS file defining text colors for htmlized Emacs buffers.
+Normally when creating an htmlized version of an Org buffer, htmlize will
+create CSS to define the font colors.  However, this does not work when
+converting in batch mode, and it also can look bad if different people
+with different fontification setup work on the same website.
+When this variable is non-nil, creating an htmlized version of an Org buffer
+using `org-export-as-org' will remove the internal CSS section and replace it
+with a link to this URL."
+  :group 'org-export-htmlize
+  :type '(choice
+	  (const :tag "Keep internal css" nil)
+	  (string :tag "URL or local href")))
+
+;;; Hooks
+
+(defvar org-export-html-after-blockquotes-hook nil
+  "Hook run during HTML export, after blockquote, verse, center are done.")
+
+(defvar org-export-html-final-hook nil
+  "Hook run at the end of HTML export, in the new buffer.")
+
+;;; HTML export
+
+(defun org-export-html-preprocess (parameters)
+  "Convert LaTeX fragments to images."
+  (when (and org-current-export-file
+	     (plist-get parameters :LaTeX-fragments))
+    (org-format-latex
+     (concat "ltxpng/" (file-name-sans-extension
+			(file-name-nondirectory
+			 org-current-export-file)))
+     org-current-export-dir nil "Creating LaTeX image %s"
+     nil nil
+     (cond
+      ((eq (plist-get parameters :LaTeX-fragments) 'verbatim) 'verbatim)
+      ((eq (plist-get parameters :LaTeX-fragments) 'mathjax ) 'mathjax)
+      ((eq (plist-get parameters :LaTeX-fragments) t        ) 'mathjax)
+      ((eq (plist-get parameters :LaTeX-fragments) 'dvipng  ) 'dvipng)
+      (t nil))))
+  (goto-char (point-min))
+  (let (label l1)
+    (while (re-search-forward "\\\\ref{\\([^{}\n]+\\)}" nil t)
+      (org-if-unprotected-at (match-beginning 1)
+	(setq label (match-string 1))
+	(save-match-data
+	  (if (string-match "\\`[a-z]\\{1,10\\}:\\(.+\\)" label)
+	      (setq l1 (substring label (match-beginning 1)))
+	    (setq l1 label)))
+	(replace-match (format "[[#%s][%s]]" label l1) t t)))))
+
+(defvar html-table-tag nil) ; dynamically scoped into this.
+
+(defconst org-html-cvt-link-fn
+   nil
+   "Function to convert link URLs to exportable URLs.
+Takes two arguments, TYPE and PATH.
+Returns exportable url as (TYPE PATH), or nil to signal that it
+didn't handle this case.
+Intended to be locally bound around a call to `org-export-as-html'." )
+
+(defun org-html-cvt-org-as-html (opt-plist type path)
+   "Convert an org filename to an equivalent html filename.
+If TYPE is not file, just return `nil'.
+See variable `org-export-html-link-org-files-as-html'"
+
+   (save-match-data
+      (and
+	 org-export-html-link-org-files-as-html
+	 (string= type "file")
+	 (string-match "\\.org$" path)
+	 (progn
+	    (list
+	       "file"
+	       (concat
+		  (substring path 0 (match-beginning 0))
+		  "."
+		  (plist-get opt-plist :html-extension)))))))
+
+;;; org-xhtml-format-org-link
+(defun org-xhtml-format-org-link (opt-plist type-1 path fragment desc attr
+					   descp)
+  "Make an HTML link.
+OPT-PLIST is an options list.
+TYPE is the device-type of the link (THIS://foo.html)
+PATH is the path of the link (http://THIS#locationx)
+FRAGMENT is the fragment part of the link, if any (foo.html#THIS)
+DESC is the link description, if any.
+ATTR is a string of other attributes of the a element.
+MAY-INLINE-P allows inlining it as an image."
+  (declare (special org-lparse-par-open))
+  (when (string= type-1 "coderef")
+    (setq attr
+	  (format "class=\"coderef\" onmouseover=\"CodeHighlightOn(this, '%s');\" onmouseout=\"CodeHighlightOff(this, '%s');\""
+		  fragment fragment)))
+  (save-match-data
+    (let* ((may-inline-p
+	    (and (member type-1 '("http" "https" "file"))
+		 (org-lparse-should-inline-p path descp)
+		 (not fragment)))
+	   (type (if (equal type-1 "id") "file" type-1))
+	   (filename path)
+	   ;;First pass.  Just sanity stuff.
+	   (components-1
+	    (cond
+	     ((string= type "file")
+	      (list
+	       type
+	       ;;Substitute just if original path was absolute.
+	       ;;(Otherwise path must remain relative)
+	       (if (file-name-absolute-p path)
+		   (concat "file://" (expand-file-name path))
+		 path)))
+	     ((string= type "")
+	      (list nil path))
+	     (t (list type path))))
+
+	   ;;Second pass.  Components converted so they can refer
+	   ;;to a remote site.
+	   (components-2
+	    (or
+	     (and org-html-cvt-link-fn
+		  (apply org-html-cvt-link-fn
+			 opt-plist components-1))
+	     (apply #'org-html-cvt-org-as-html
+		    opt-plist components-1)
+	     components-1))
+	   (type    (first  components-2))
+	   (thefile (second components-2)))
+
+
+      ;;Third pass.  Build final link except for leading type
+      ;;spec.
+      (cond
+       ((or
+	 (not type)
+	 (string= type "http")
+	 (string= type "https")
+	 (string= type "file")
+	 (string= type "coderef"))
+	(if fragment
+	    (setq thefile (concat thefile "#" fragment))))
+
+       (t))
+
+      ;;Final URL-build, for all types.
+      (setq thefile
+	    (let
+		((str (org-xml-format-href thefile)))
+	      (if (and type (not (or (string= "file" type)
+				     (string= "coderef" type))))
+		  (concat type ":" str)
+		str)))
+
+      (if may-inline-p
+	  (org-xhtml-format-image thefile)
+	(org-lparse-format
+	 'LINK (org-xml-format-desc desc) thefile attr)))))
+
+(defun org-xhtml-format-inline-image (desc)
+  ;; FIXME: alt text missing here?
+  (org-xhtml-format-tags "<img src=\"%s\" alt=\"\"/>" "" desc))
+
+(defvar org-lparse-link-description-is-image)
+
+(defun org-xhtml-format-image (src)
+  "Create image tag with source and attributes."
+  (save-match-data
+    (if (string-match "^ltxpng/" src)
+	(format "<img src=\"%s\" alt=\"%s\"/>"
+                src (org-find-text-property-in-string 'org-latex-src src))
+      (let* ((caption (org-find-text-property-in-string 'org-caption src))
+	     (attr (org-find-text-property-in-string 'org-attributes src))
+	     (label (org-find-text-property-in-string 'org-label src))
+	     (caption (and caption (org-xml-encode-org-text caption)))
+	     (img (format "<img src=\"%s\"%s />"
+			  src
+			  (if (string-match "\\<alt=" (or attr ""))
+			      (concat " " attr )
+			    (concat " " attr " alt=\"" src "\""))))
+	     (extra (concat
+		     (and label
+			  (format "id=\"%s\" " (org-solidify-link-text label)))
+		     "class=\"figure\"")))
+	(if caption
+	    (with-temp-buffer
+	      (with-org-lparse-preserve-paragraph-state
+	       (insert
+		(org-lparse-format
+		 '("<div %s>" . "\n</div>")
+		 (concat
+		  (org-lparse-format '("\n<p>" . "</p>") img)
+		  (org-lparse-format '("\n<p>" . "</p>") caption))
+		 extra)))
+	      (buffer-string))
+	  img)))))
+
+(defun org-export-html-get-bibliography ()
+  "Find bibliography, cut it out and return it."
+  (catch 'exit
+    (let (beg end (cnt 1) bib)
+      (save-excursion
+	(goto-char (point-min))
+	(when (re-search-forward "^[ \t]*<div \\(id\\|class\\)=\"bibliography\"" nil t)
+	  (setq beg (match-beginning 0))
+	  (while (re-search-forward "</?div\\>" nil t)
+	    (setq cnt (+ cnt (if (string= (match-string 0) "<div") +1 -1)))
+	    (when (= cnt 0)
+	      (and (looking-at ">") (forward-char 1))
+	      (setq bib (buffer-substring beg (point)))
+	      (delete-region beg (point))
+	    (throw 'exit bib))))
+	nil))))
+
+(defun org-xhtml-format-table (lines olines)
+  (let ((org-xhtml-format-table-no-css nil))
+    (org-lparse-format-table lines olines)))
+
+;; Following variable is defined for native tables i.e., when
+;; `org-lparse-table-is-styled' evals to t.
+(defvar org-xhtml-format-table-no-css)
+(defvar org-table-number-regexp) ; defined in org-table.el
+
+;; FIXME: This function is called from other modules. Use xhtml suffix
+;; to avoid conflict
+(defun org-format-table-xhtml (lines olines &optional no-css)
+  "Find out which HTML converter to use and return the HTML code.
+NO-CSS is passed to the exporter."
+  (let* ((org-lparse-backend 'xhtml)
+	 (org-lparse-entity-control-callbacks-alist
+	  (org-lparse-get 'ENTITY-CONTROL))
+	 (org-lparse-entity-format-callbacks-alist
+	  (org-lparse-get 'ENTITY-FORMAT))
+	 (org-xhtml-format-table-no-css no-css))
+    (org-lparse-format-table lines olines)))
+
+;; FIXME: This function is called from other modules. Use xhtml suffix
+;; to avoid conflict
+(defun org-format-org-table-xhtml (lines &optional splice no-css)
+  ;; This routine might get called outside of org-export-as-html. For
+  ;; example, this could happen as part of org-table-export or as part
+  ;; of org-export-as-docbook. Explicitly bind the parser callback to
+  ;; the html ones for the duration of the call.
+  (let* ((org-lparse-backend 'xhtml)
+	 (org-lparse-entity-control-callbacks-alist
+	  (org-lparse-get 'ENTITY-CONTROL))
+	 (org-lparse-entity-format-callbacks-alist
+	  (org-lparse-get 'ENTITY-FORMAT))
+	 (org-xhtml-format-table-no-css no-css))
+    (org-lparse-format-org-table lines splice)))
+
+(defun org-export-splice-attributes (tag attributes)
+  "Read attributes in string ATTRIBUTES, add and replace in HTML tag TAG."
+  (if (not attributes)
+      tag
+    (let (oldatt newatt)
+      (setq oldatt (org-extract-attributes-from-string tag)
+	    tag (pop oldatt)
+	    newatt (cdr (org-extract-attributes-from-string attributes)))
+      (while newatt
+	(setq oldatt (plist-put oldatt (pop newatt) (pop newatt))))
+      (if (string-match ">" tag)
+	  (setq tag
+		(replace-match (concat (org-attributes-to-string oldatt) ">")
+			       t t tag)))
+      tag)))
+
+;; FIXME: This function is called from other modules. Use xhtml suffix
+;; to avoid conflict
+(defun org-format-table-table-xhtml (lines)
+  (let* ((org-lparse-get 'html)
+	 (org-lparse-entity-control-callbacks-alist
+	  (org-lparse-get 'ENTITY-CONTROL))
+	 (org-lparse-entity-format-callbacks-alist
+	  (org-lparse-get 'ENTITY-FORMAT)))
+    (org-lparse-format-table-table lines)))
+
+(defun org-export-splice-style (style extra)
+  "Splice EXTRA into STYLE, just before \"</style>\"."
+  (if (and (stringp extra)
+	   (string-match "\\S-" extra)
+	   (string-match "</style>" style))
+      (concat (substring style 0 (match-beginning 0))
+	      "\n" extra "\n"
+	      (substring style (match-beginning 0)))
+    style))
+
+(defvar htmlize-buffer-places)  ; from htmlize.el
+(defun org-export-htmlize-region-for-paste (beg end)
+  "Convert the region to HTML, using htmlize.el.
+This is much like `htmlize-region-for-paste', only that it uses
+the settings define in the org-... variables."
+  (let* ((htmlize-output-type org-export-htmlize-output-type)
+	 (htmlize-css-name-prefix org-export-htmlize-css-font-prefix)
+	 (htmlbuf (htmlize-region beg end)))
+    (unwind-protect
+	(with-current-buffer htmlbuf
+	  (buffer-substring (plist-get htmlize-buffer-places 'content-start)
+			    (plist-get htmlize-buffer-places 'content-end)))
+      (kill-buffer htmlbuf))))
+
+;;;###autoload
+(defun org-export-htmlize-generate-css ()
+  "Create the CSS for all font definitions in the current Emacs session.
+Use this to create face definitions in your CSS style file that can then
+be used by code snippets transformed by htmlize.
+This command just produces a buffer that contains class definitions for all
+faces used in the current Emacs session.  You can copy and paste the ones you
+need into your CSS file.
+
+If you then set `org-export-htmlize-output-type' to `css', calls to
+the function `org-export-htmlize-region-for-paste' will produce code
+that uses these same face definitions."
+  (interactive)
+  (require 'htmlize)
+  (and (get-buffer "*html*") (kill-buffer "*html*"))
+  (with-temp-buffer
+    (let ((fl (face-list))
+	  (htmlize-css-name-prefix "org-")
+	  (htmlize-output-type 'css)
+	  f i)
+      (while (setq f (pop fl)
+		   i (and f (face-attribute f :inherit)))
+	(when (and (symbolp f) (or (not i) (not (listp i))))
+	  (insert (org-add-props (copy-sequence "1") nil 'face f))))
+      (htmlize-region (point-min) (point-max))))
+  (switch-to-buffer "*html*")
+  (goto-char (point-min))
+  (if (re-search-forward "<style" nil t)
+      (delete-region (point-min) (match-beginning 0)))
+  (if (re-search-forward "</style>" nil t)
+      (delete-region (1+ (match-end 0)) (point-max)))
+  (beginning-of-line 1)
+  (if (looking-at " +") (replace-match ""))
+  (goto-char (point-min)))
+
+(defvar body-only) ; dynamically scoped into this.
+
+;; Following variable is let bound when `org-do-lparse' is in
+;; progress. See org-lparse.el.
+(defvar org-lparse-toc)
+(defvar org-lparse-footnote-buffer)
+(defvar org-lparse-footnote-definitions)
+(defvar org-lparse-dyn-first-heading-pos)
+
+(defun org-xhtml-end-export ()
+  ;; insert the table of contents
+  (when (and org-export-with-toc (not body-only) org-lparse-toc)
+    (org-xhtml-insert-toc org-lparse-toc))
+
+  ;; remove empty paragraphs
+  (goto-char (point-min))
+  (while (re-search-forward "<p>[ \r\n\t]*</p>" nil t)
+    (replace-match ""))
+
+  ;; Convert whitespace place holders
+  (goto-char (point-min))
+  (let (beg end n)
+    (while (setq beg (next-single-property-change (point) 'org-whitespace))
+      (setq n (get-text-property beg 'org-whitespace)
+	    end (next-single-property-change beg 'org-whitespace))
+      (goto-char beg)
+      (delete-region beg end)
+      (insert (format "<span style=\"visibility:hidden;\">%s</span>"
+		      (make-string n ?x)))))
+
+  ;; Remove empty lines at the beginning of the file.
+  (goto-char (point-min))
+  (when (looking-at "\\s-+\n") (replace-match ""))
+
+  ;; Remove display properties
+  (remove-text-properties (point-min) (point-max) '(display t))
+
+  ;; kill temporary buffers
+  (when org-lparse-footnote-buffer
+    (kill-buffer org-lparse-footnote-buffer))
+
+  ;; Run the hook
+  (run-hooks 'org-export-html-final-hook))
+
+(defun org-xhtml-format-toc-entry (snumber todo headline tags href)
+  (setq headline (concat
+		  (and org-export-with-section-numbers
+		       (concat snumber " "))
+		  headline
+		  (and tags
+		    (concat
+		     (org-lparse-format 'SPACES 3)
+		     (org-lparse-format 'FONTIFY tags "tag")))))
+  (when todo
+    (setq headline (org-lparse-format 'FONTIFY headline "todo")))
+  (org-lparse-format 'LINK headline (concat  "#" href)))
+
+(defun org-xhtml-format-toc-item (toc-entry level org-last-level)
+  (when (> level org-last-level)
+    (let ((cnt (- level org-last-level)))
+      (while (>= (setq cnt (1- cnt)) 0)
+	(org-lparse-begin 'LIST 'unordered)
+	(org-lparse-begin 'LIST-ITEM 'unordered))))
+  (when (< level org-last-level)
+    (let ((cnt (- org-last-level level)))
+      (while (>= (setq cnt (1- cnt)) 0)
+	(org-lparse-end-list-item)
+	(org-lparse-end 'LIST 'unordered))))
+
+  (org-lparse-end-list-item)
+  (org-lparse-begin 'LIST-ITEM 'unordered)
+  (insert toc-entry))
+
+(defun org-xhtml-begin-toc (lang-specific-heading)
+  (org-lparse-insert-tag "<div id=\"table-of-contents\">")
+  (insert
+   (org-lparse-format 'HEADING lang-specific-heading
+		     (or (org-lparse-get 'TOPLEVEL-HLEVEL) 1)))
+  (org-lparse-insert-tag "<div id=\"text-table-of-contents\">")
+  (org-lparse-begin 'LIST 'unordered)
+  (org-lparse-begin 'LIST-ITEM 'unordered))
+
+(defun org-xhtml-end-toc ()
+  (while (> org-last-level (1- org-min-level))
+    (setq org-last-level (1- org-last-level))
+    (org-lparse-end-list-item)
+    (org-lparse-end 'LIST 'unordered))
+  (org-lparse-insert-tag "</div>")
+  (org-lparse-insert-tag "</div>")
+
+  ;; cleanup empty list items in toc
+  (while (re-search-backward "<li>[ \r\n\t]*</li>\n?" (point-min) t)
+    (replace-match "")))
+
+;;;###autoload
+(defun org-export-as-xhtml-and-open (arg)
+  "Export the outline as HTML and immediately open it with a browser.
+If there is an active region, export only the region.
+The prefix ARG specifies how many levels of the outline should become
+headlines.  The default is 3.  Lower levels will become bulleted lists."
+  (interactive "P")
+  (org-lparse-and-open "xhtml" "xhtml" arg))
+
+;;;###autoload
+(defun org-export-as-xhtml-batch ()
+  "Call the function `org-lparse-batch'.
+This function can be used in batch processing as:
+emacs   --batch
+        --load=$HOME/lib/emacs/org.el
+        --eval \"(setq org-export-headline-levels 2)\"
+        --visit=MyFile --funcall org-export-as-html-batch"
+  (org-lparse-batch "xhtml"))
+
+;;;###autoload
+(defun org-export-as-xhtml-to-buffer (arg)
+  "Call `org-lparse-to-buffer` with output to a temporary buffer.
+No file is created.  The prefix ARG is passed through to `org-lparse-to-buffer'."
+  (interactive "P")
+  (org-lparse-to-buffer "xhtml" arg))
+
+;;;###autoload
+(defun org-replace-region-by-xhtml (beg end)
+  "Assume the current region has org-mode syntax, and convert it to HTML.
+This can be used in any buffer.  For example, you could write an
+itemized list in org-mode syntax in an HTML buffer and then use this
+command to convert it."
+  (interactive "r")
+  (org-replace-region-by "xhtml" beg end))
+
+;;;###autoload
+(defun org-export-region-as-xhtml (beg end &optional body-only buffer)
+  "Convert region from BEG to END in `org-mode' buffer to HTML.
+If prefix arg BODY-ONLY is set, omit file header, footer, and table of
+contents, and only produce the region of converted text, useful for
+cut-and-paste operations.
+If BUFFER is a buffer or a string, use/create that buffer as a target
+of the converted HTML.  If BUFFER is the symbol `string', return the
+produced HTML as a string and leave not buffer behind.  For example,
+a Lisp program could call this function in the following way:
+
+  (setq html (org-export-region-as-html beg end t 'string))
+
+When called interactively, the output buffer is selected, and shown
+in a window.  A non-interactive call will only return the buffer."
+  (interactive "r\nP")
+  (org-lparse-region "xhtml" beg end body-only buffer))
+
+;;; org-export-as-xhtml
+;;;###autoload
+(defun org-export-as-xhtml (arg &optional hidden ext-plist
+			       to-buffer body-only pub-dir)
+  "Export the outline as a pretty HTML file.
+Use `org-lparse' internally to perform the actual export. This
+routine merely binds the TARGET-BACKEND and NATIVE-BACKEND args
+of `org-lparse' to \"html\"."
+  (interactive "P")
+  (org-lparse "xhtml" "xhtml" arg hidden ext-plist to-buffer body-only pub-dir))
+
+(defvar org-xhtml-entity-control-callbacks-alist
+  `((EXPORT
+     . (org-xhtml-begin-export org-xhtml-end-export))
+    (DOCUMENT-CONTENT
+     . (org-xhtml-begin-document-content org-xhtml-end-document-content))
+    (DOCUMENT-BODY
+     . (org-xhtml-begin-document-body org-xhtml-end-document-body))
+    (TOC
+     . (org-xhtml-begin-toc org-xhtml-end-toc))
+    (ENVIRONMENT
+     . (org-xhtml-begin-environment org-xhtml-end-environment))
+    (FOOTNOTE-DEFINITION
+     . (org-xhtml-begin-footnote-definition org-xhtml-end-footnote-definition))
+    (TABLE
+     . (org-xhtml-begin-table org-xhtml-end-table))
+    (TABLE-ROWGROUP
+     . (org-xhtml-begin-table-rowgroup org-xhtml-end-table-rowgroup))
+    (LIST
+     . (org-xhtml-begin-list org-xhtml-end-list))
+    (LIST-ITEM
+     . (org-xhtml-begin-list-item org-xhtml-end-list-item))
+    (OUTLINE
+     . (org-xhtml-begin-outline org-xhtml-end-outline))
+    (OUTLINE-TEXT
+     . (org-xhtml-begin-outline-text org-xhtml-end-outline-text))
+    (PARAGRAPH
+     . (org-xhtml-begin-paragraph org-xhtml-end-paragraph)))
+  "Alist of control callbacks registered with the exporter.
+Each element is of the form (ENTITY . (BEGIN-ENTITY-FUNCTION
+END-ENTITY-FUNCTION)).  ENTITY is one of PARAGRAPH, LIST etc as
+seen above.  BEGIN-ENTITY-FUNCTION and END-ENTITY-FUNCTION are
+functions that get called when the exporter needs to begin or end
+an entity in the currently exported file.  The signatures of
+these callbacks are specific to the ENTITY being emitted.  These
+callbacks always get called with exported file as the current
+buffer and need to insert the appropriate tags into the current
+buffer.  For example, `org-xhtml-begin-paragraph' inserts <p> and
+`org-xhtml-end-paragraph' inserts </p> in to the current buffer.
+These callbacks are invoked via `org-lparse-begin' and
+`org-lparse-end'.")
+
+(defvar org-xhtml-entity-format-callbacks-alist
+  `((EXTRA-TARGETS . org-lparse-format-extra-targets)
+    (ORG-TAGS . org-lparse-format-org-tags)
+    (SECTION-NUMBER . org-lparse-format-section-number)
+    (HEADLINE . org-xhtml-format-headline)
+    (TOC-ENTRY . org-xhtml-format-toc-entry)
+    (TOC-ITEM . org-xhtml-format-toc-item)
+    (TAGS . org-xhtml-format-tags)
+    (SPACES . org-xhtml-format-spaces)
+    (TABS . org-xhtml-format-tabs)
+    (LINE-BREAK . org-xhtml-format-line-break)
+    (FONTIFY . org-xhtml-format-fontify)
+    (TODO . org-lparse-format-todo)
+    (ORG-LINK . org-xhtml-format-org-link)
+    (LINK . org-xhtml-format-link)
+    (INLINE-IMAGE . org-xhtml-format-inline-image)
+    (HEADING . org-xhtml-format-heading)
+    (ANCHOR . org-xhtml-format-anchor)
+    (TABLE . org-xhtml-format-table)
+    (TABLE-ROW . org-xhtml-format-table-row)
+    (TABLE-CELL . org-xhtml-format-table-cell)
+    (FOOTNOTES-SECTION . org-xhtml-format-footnotes-section)
+    (FOOTNOTE-REFERENCE . org-xhtml-format-footnote-reference)
+    (HORIZONTAL-LINE . org-xhtml-format-horizontal-line)
+    (LINE . org-xhtml-format-line)
+    (COMMENT . org-xhtml-format-comment)
+    (ORG-ENTITY . org-xhtml-format-org-entity))
+  "Alist of format callbacks registered with the exporter.
+Each element is of the form (ENTITY . ENTITY-FORMAT-FUNCTION).
+ENTITY is one of LINE, HEADING, COMMENT, LINK, TABLE-ROW etc as
+seen above.  ENTITY-FORMAT-FUNCTION is a functions that gets
+called when the exporter needs to format a string in `org-mode'
+buffer in a backend specific way.  The signatures of the
+formatting callback is specific to the ENTITY being passed in.
+These callbacks always need to encode the incoming entity in
+backend specific way and return the same.  These callbacks do not
+make any modifications to the exporter file.  For example,
+`org-xhtml-format-table-row' encloses incoming entity in <tr>
+</tr> tags and returns it.  See also `org-lparse-format'.")
+
+(defun org-xhtml-begin-document-body (opt-plist)
+  (let ((link-up (and (plist-get opt-plist :link-up)
+		      (string-match "\\S-" (plist-get opt-plist :link-up))
+		      (plist-get opt-plist :link-up)))
+	(link-home (and (plist-get opt-plist :link-home)
+			(string-match "\\S-" (plist-get opt-plist :link-home))
+			(plist-get opt-plist :link-home))))
+    (insert "\n<body>")
+    (org-lparse-insert-tag "<div id=\"content\">")
+    (insert  "\n"
+	     (or (and (or link-up link-home)
+		      (format org-export-html-home/up-format
+			      (or link-up link-home)
+			      (or link-home link-up))) "")
+	     "\n"))
+  (org-xhtml-insert-preamble opt-plist))
+
+(defun org-xhtml-end-document-body (opt-plist)
+  (org-xhtml-insert-postamble opt-plist)
+  (unless body-only
+    (org-lparse-insert-tag "</div>")
+    (insert "\n</body>")))
+
+(defun org-xhtml-begin-document-content (opt-plist)
+  (let* ((language (plist-get opt-plist :language))
+	 (charset (or (and coding-system-for-write
+			   (fboundp 'coding-system-get)
+			   (coding-system-get coding-system-for-write
+					      'mime-charset))
+		      "iso-8859-1"))
+	 (style (concat (if (plist-get opt-plist :style-include-default)
+			    org-export-html-style-default)
+			(plist-get opt-plist :style)
+			(plist-get opt-plist :style-extra)
+			"\n"
+			(if (plist-get opt-plist :style-include-scripts)
+			    org-export-html-scripts)))
+	 (mathjax
+	  (if (or (eq (plist-get opt-plist :LaTeX-fragments) 'mathjax)
+		  (and org-export-have-math
+		       (eq (plist-get opt-plist :LaTeX-fragments) t)))
+
+	      (org-export-html-mathjax-config
+	       org-export-html-mathjax-template
+	       org-export-html-mathjax-options
+	       (or (plist-get opt-plist :mathjax) "")) "")))
+    (insert (format
+	     "%s
+<!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML 1.0 Strict//EN\"
+	       \"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd\">
+<html xmlns=\"http://www.w3.org/1999/xhtml\"
+lang=\"%s\" xml:lang=\"%s\">
+<head>
+<title>%s</title>
+<meta http-equiv=\"Content-Type\" content=\"text/html;charset=%s\"/>
+<meta name=\"generator\" content=\"Org-mode\"/>
+<meta name=\"generated\" content=\"%s\"/>
+<meta name=\"author\" content=\"%s\"/>
+<meta name=\"description\" content=\"%s\"/>
+<meta name=\"keywords\" content=\"%s\"/>
+%s
+%s
+</head>
+"
+	     (format
+	      (or (and (stringp org-export-html-xml-declaration)
+		       org-export-html-xml-declaration)
+		  (cdr (assoc (plist-get opt-plist :html-extension)
+			      org-export-html-xml-declaration))
+		  (cdr (assoc "html" org-export-html-xml-declaration))
+
+		  "")
+	      charset)
+	     language language
+	     (plist-get opt-plist :title)
+	     charset
+	     (plist-get opt-plist :effective-date)
+	     (plist-get opt-plist :author)
+	     (plist-get opt-plist :description)
+	     (plist-get opt-plist :keywords)
+	     style
+	     mathjax))))
+
+(defun org-xhtml-end-document-content ()
+  (insert "\n</html>\n"))
+
+(defun org-xhtml-begin-outline (level1 snumber title tags
+				      target extra-targets extra-class)
+  (let* ((class (format "outline-%d" level1))
+	 (class (if extra-class (concat  class " " extra-class) class))
+	 (id (format "outline-container-%s"
+		     (org-lparse-suffix-from-snumber snumber)))
+	 (extra (concat (when id (format " id=\"%s\"" id))
+			(when class (format " class=\"%s\"" class)))))
+    (org-lparse-insert-tag "<div%s>" extra)
+    (insert
+     (org-lparse-format 'HEADING
+		       (org-lparse-format
+			'HEADLINE title extra-targets tags snumber level1)
+		       level1 target))))
+
+(defun org-xhtml-end-outline ()
+  (org-lparse-insert-tag  "</div>"))
+
+(defun org-xhtml-begin-outline-text (level1 snumber extra-class)
+  (let* ((class (format "outline-text-%d" level1))
+	 (class (if extra-class (concat  class " " extra-class) class))
+	 (id (format "text-%s" (org-lparse-suffix-from-snumber snumber)))
+	 (extra (concat (when id (format " id=\"%s\"" id))
+			(when class (format " class=\"%s\"" class)))))
+    (org-lparse-insert-tag "<div%s>" extra)))
+
+(defun org-xhtml-end-outline-text ()
+  (org-lparse-insert-tag "</div>"))
+
+(defun org-xhtml-begin-paragraph (&optional style)
+  (let* ((class (cdr (assoc style '((footnote . "footnote")
+				    (verse . nil)))))
+	 (extra (if class (format " class=\"%s\"" class) "")))
+    (org-lparse-insert-tag "<p%s>" extra)))
+
+(defun org-xhtml-end-paragraph ()
+  (insert "</p>"))
+
+(defun org-xhtml-format-environment (style beg-end)
+  (assert (memq style '(blockquote center verse fixedwidth quote native)) t)
+  (case style
+    (blockquote
+     (case beg-end
+       (BEGIN
+	(org-lparse-end-paragraph)
+	(insert "<blockquote>\n")
+	(org-lparse-begin-paragraph))
+       (END
+	(org-lparse-end-paragraph)
+	(insert "\n</blockquote>\n")
+	(org-lparse-begin-paragraph))))
+    (verse
+     (case beg-end
+       (BEGIN
+	(org-lparse-end-paragraph)
+	(insert "\n<p class=\"verse\">\n")
+	(setq org-lparse-par-open t))
+       (END
+	(insert "</p>\n")
+	(setq org-lparse-par-open nil)
+	(org-lparse-begin-paragraph))))
+    (center
+     (case beg-end
+       (BEGIN
+	(org-lparse-end-paragraph)
+	(insert "\n<div style=\"text-align: center\">")
+	(org-lparse-begin-paragraph))
+       (END
+	(org-lparse-end-paragraph)
+	(insert "\n</div>")
+	(org-lparse-begin-paragraph))))
+    (fixedwidth
+     (case beg-end
+       (BEGIN
+	(org-lparse-end-paragraph)
+	(insert "<pre class=\"example\">\n"))
+       (END
+	(insert "</pre>\n")
+	(org-lparse-begin-paragraph))))
+    (quote
+     (case beg-end
+       (BEGIN
+	(org-lparse-end-paragraph)
+	(insert "<pre>"))
+       (END
+	(insert "</pre>\n")
+	(org-lparse-begin-paragraph))))
+    (native
+     (case beg-end
+       (BEGIN (org-lparse-end-paragraph))
+       (END (org-lparse-begin-paragraph))))
+    (t (error "Unknown environment %s" style))))
+
+(defun org-xhtml-begin-environment (style)
+  (org-xhtml-format-environment style 'BEGIN))
+
+(defun org-xhtml-end-environment (style)
+  (org-xhtml-format-environment style 'END))
+
+(defun org-xhtml-begin-list (ltype &optional arg1)
+  (setq ltype (or (org-lparse-html-list-type-to-canonical-list-type ltype)
+		  ltype))
+
+  (case ltype
+    (ordered (let ((extra (if arg1 (format " start=\"%d\"" arg1) "")))
+	       (org-lparse-insert-tag "<ol%s>" extra)))
+    (unordered (org-lparse-insert-tag "<ul>"))
+    (description (org-lparse-insert-tag "<dl>"))
+    (t (error "Unknown list type: %s"  ltype))))
+
+(defun org-xhtml-end-list (ltype)
+  (setq ltype (or (org-lparse-html-list-type-to-canonical-list-type ltype)
+		  ltype))
+
+  (org-lparse-insert-tag
+     (case ltype
+       (ordered "</ol>")
+       (unordered "</ul>")
+       (description "</dl>")
+       (t (error "Unknown list type: %s" ltype)))))
+
+(defun org-xhtml-begin-list-item (ltype &optional arg headline)
+  (setq ltype (or (org-lparse-html-list-type-to-canonical-list-type ltype)
+		  ltype))
+  (case ltype
+    (ordered
+     (assert (not headline) t)
+     (let* ((counter arg)
+	   (extra (if counter (format " value=\"%s\"" counter) "")))
+       (org-lparse-insert-tag "<li%s>" extra)))
+    (unordered
+     (let* ((id arg)
+	   (extra (if id (format " id=\"%s\"" id) "")))
+       (org-lparse-insert-tag "<li%s>" extra)
+       (when headline
+	 (insert headline (org-lparse-format 'LINE-BREAK) "\n"))))
+    (description
+     (assert (not headline) t)
+     (let* ((desc-tag (or arg "(no term)")))
+       (insert
+	(org-xhtml-format-tags '("<dt>" . "</dt>") desc-tag))
+       (org-lparse-insert-tag "<dd>")))
+    (t (error "Unknown list type"))))
+
+(defun org-xhtml-end-list-item (ltype)
+  (setq ltype (or (org-lparse-html-list-type-to-canonical-list-type ltype)
+		  ltype))
+  (case ltype
+    (ordered (org-lparse-insert-tag "</li>"))
+    (unordered (org-lparse-insert-tag "</li>"))
+    (description (org-lparse-insert-tag "</dd>"))
+    (t (error "Unknown list type"))))
+
+;; Following variables are let bound when table emission is in
+;; progress. See org-lparse.el.
+(defvar org-lparse-table-begin-marker)
+(defvar org-lparse-table-ncols)
+(defvar org-lparse-table-rowgrp-open)
+(defvar org-lparse-table-rownum)
+(defvar org-lparse-table-cur-rowgrp-is-hdr)
+(defvar org-lparse-table-is-styled)
+(defvar org-lparse-table-rowgrp-info)
+(defvar org-lparse-table-colalign-vector)
+(defvar org-lparse-table-num-numeric-items-per-column)
+
+(defun org-xhtml-begin-table-rowgroup (&optional is-header-row)
+  (when org-lparse-table-rowgrp-open
+    (org-lparse-end 'TABLE-ROWGROUP))
+  (org-lparse-insert-tag (if is-header-row "<thead>" "<tbody>"))
+  (setq org-lparse-table-rowgrp-open t)
+  (setq org-lparse-table-cur-rowgrp-is-hdr is-header-row))
+
+(defun org-xhtml-end-table-rowgroup ()
+  (when org-lparse-table-rowgrp-open
+    (setq org-lparse-table-rowgrp-open nil)
+    (org-lparse-insert-tag
+     (if org-lparse-table-cur-rowgrp-is-hdr "</thead>" "</tbody>"))))
+
+(defun org-xhtml-begin-table (caption label attributes)
+  (let ((html-table-tag
+	 (org-export-splice-attributes html-table-tag attributes)))
+    (when label
+      (setq html-table-tag
+	    (org-export-splice-attributes
+	     html-table-tag
+	     (format "id=\"%s\"" (org-solidify-link-text label)))))
+    (org-lparse-insert-tag html-table-tag))
+
+  ;; Since the output of HTML table formatter can also be used in
+  ;; DocBook document, we want to always include the caption to make
+  ;; DocBook XML file valid.
+  (insert (format "<caption>%s</caption>" (or caption "")) "\n"))
+
+(defun org-xhtml-end-table ()
+  (when org-lparse-table-is-styled
+    (goto-char org-lparse-table-begin-marker)
+    (setq org-lparse-table-begin-marker nil)
+
+    (let ((c -1) gr colgropen)
+      (insert
+       (mapconcat
+	(lambda (x)
+	  (incf c)
+	  (setq gr (pop org-table-colgroup-info))
+
+	  (concat
+	   (if (memq gr '(:start :startend))
+	       (prog1
+		   (if colgropen
+		       "</colgroup>\n<colgroup>"
+		     "<colgroup>")
+		 (setq colgropen t))
+	     "")
+
+	   (let* ((align (aref org-lparse-table-colalign-vector c))
+		  (alignspec (if org-xhtml-format-table-no-css
+				 " align=\"%s\"" " class=\"%s\""))
+		  (extra (format alignspec  align)))
+	     (format "<col%s />" extra))
+
+	   (if (memq gr '(:end :startend))
+	       (progn (setq colgropen nil) "</colgroup>")
+	     "")))
+	org-lparse-table-num-numeric-items-per-column ""))
+
+      (if colgropen (insert "</colgroup>")))
+
+    ;; fill style attributes for table cells
+    (while (re-search-forward "@@class\\([0-9]+\\)@@" nil t)
+      (let ((c (string-to-number (match-string 1))))
+	(replace-match
+	 (if org-export-html-table-align-individual-fields
+	     (format (if org-xhtml-format-table-no-css " align=\"%s\""
+		       " class=\"%s\"")
+		     (or (aref org-lparse-table-colalign-vector c) "left")) "")
+	 t t)))
+    (goto-char (point-max)))
+  (org-lparse-insert-tag "</table>\n"))
+
+(defun org-xhtml-format-table-row (row)
+  (org-xhtml-format-tags
+   (cons (eval (car org-export-table-row-tags))
+	 (eval (cdr org-export-table-row-tags))) row))
+
+(defun org-xhtml-format-table-cell (text r c)
+  (let ((cell-style-cookie (or (and org-lparse-table-is-styled
+				    (format "@@class%03d@@" c)) "")))
+    (cond
+     (org-lparse-table-cur-rowgrp-is-hdr
+      (org-xhtml-format-tags
+       org-export-table-header-tags text  "col" cell-style-cookie))
+     ((and (= c 0) org-export-html-table-use-header-tags-for-first-column)
+      (org-xhtml-format-tags
+       org-export-table-header-tags text "row" cell-style-cookie))
+     (t
+      (org-xhtml-format-tags
+       org-export-table-data-tags text cell-style-cookie)))))
+
+(defun org-xhtml-begin-footnote-definition (n)
+  (org-lparse-begin-paragraph 'footnote)
+  (insert
+   (format
+    (format org-export-html-footnote-format
+	    "<a class=\"footnum\" name=\"fn.%s\" href=\"#fnr.%s\">%s</a>")
+    n n n)))
+
+(defun org-xhtml-end-footnote-definition (n)
+  (org-lparse-end-paragraph))
+
+(defun org-xhtml-format-spaces (n)
+  (let ((space (or (and org-lparse-encode-pending "\\nbsp") "&nbsp;")) out)
+    (while (> n 0)
+      (setq out (concat out space))
+      (setq n (1- n))) out))
+
+(defun org-xhtml-format-tabs (&optional n)
+  (ignore))
+
+(defun org-xhtml-format-line-break ()
+  (org-xhtml-format-tags "<br/>" ""))
+
+(defun org-xhtml-format-horizontal-line ()
+  (concat  "\n" "<hr/>" "\n"))
+
+(defun org-xhtml-format-line (line)
+  (case org-lparse-dyn-current-environment
+    ((quote fixedwidth) (concat (org-xml-encode-plain-text line) "\n"))
+    (t (concat line "\n"))))
+
+(defun org-xhtml-format-comment (fmt &rest args)
+  (let ((comment (apply 'format fmt args)))
+    (format "\n<!-- %s  -->\n" comment)))
+
+(defun org-xhtml-format-fontify (text style &optional id)
+  (let (class extra how)
+    (cond
+     ((eq style 'underline)
+      (setq extra " style=\"text-decoration:underline;\"" ))
+     ((setq how (cdr (assoc style
+			    '((bold . ("<b>" . "</b>"))
+			      (emphasis . ("<i>" . "</i>"))
+			      (code . ("<code>" . "</code>"))
+			      (verbatim . ("<code>" . "</code>"))
+			      (strike . ("<del>" . "</del>"))
+			      (subscript . ("<sub>" . "</sub>"))
+			      (superscript . ("<sup>" . "</sup>")))))))
+     ((listp style)
+      (setq class (mapconcat 'identity style " ")))
+     ((stringp style)
+      (setq class style))
+     (t (error "Unknown style %S" style)))
+
+    (setq extra (concat (when class (format " class=\"%s\"" class))
+			(when id (format " id=\"%s\""  id))
+			extra))
+    (org-xhtml-format-tags
+     (or how '("<span%s>" . "</span>")) text extra)))
+
+(defun org-xhtml-format-link (text href &optional extra)
+  (let ((extra (concat (format " href=\"%s\"" href)
+		       (and extra (concat  " " extra)))))
+    (org-xhtml-format-tags '("<a%s>" . "</a>") text extra)))
+
+(defun org-xhtml-format-heading (text level &optional id)
+  (let* ((extra (concat (when id (format " id=\"%s\"" id)))))
+    (concat (format "<h%d%s>" level extra) text (format "</h%d>" level))))
+
+(defun org-xhtml-format-headline (title extra-targets tags
+					    &optional snumber level)
+  (concat
+   (org-lparse-format 'EXTRA-TARGETS extra-targets)
+   (concat (org-lparse-format 'SECTION-NUMBER snumber level) " ")
+   title
+   (and tags (concat (org-lparse-format 'SPACES 3)
+		     (org-lparse-format 'ORG-TAGS tags)))))
+
+(defun org-xhtml-format-anchor (text name &optional class)
+  (let* ((id name)
+	 (extra (concat
+		 (when name (format " name=\"%s\""  name))
+		 (when id (format " id=\"%s\""  id))
+		 (when class (format " class=\"%s\""  class)))))
+    (org-xhtml-format-tags '("<a%s>" . "</a>") text extra)))
+
+(defun org-xhtml-format-footnote-reference (n def refcnt)
+  (let ((extra (if (= refcnt 1) "" (format ".%d"  refcnt))))
+    (format org-export-html-footnote-format
+	    (format
+	     "<a class=\"footref\" name=\"fnr.%s%s\" href=\"#fn.%s\">%s</a>"
+	     n extra n n))))
+
+(defun org-xhtml-format-footnotes-section (section-name definitions)
+  (if (not definitions) ""
+    (format org-export-html-footnotes-section section-name definitions)))
+
+(defun org-xhtml-format-org-entity (wd)
+  (org-entity-get-representation wd 'html))
+
+(defun org-xhtml-format-tags (tag text &rest args)
+  (let ((prefix (when org-lparse-encode-pending "@"))
+	(suffix (when org-lparse-encode-pending "@")))
+    (apply 'org-lparse-format-tags tag text prefix suffix args)))
+
+(defun org-xhtml-get (what &optional opt-plist)
+  (case what
+    (BACKEND 'html)
+    (INIT-METHOD nil)
+    (SAVE-METHOD nil)
+    (CLEANUP-METHOD nil)
+    (OTHER-BACKENDS
+     '("etext" "html" "html10" "mediawiki" "pdf" "sdw" "sdw3" "sdw4"
+       "text" "text10" "odt" "vor" "vor4"))
+    (CONVERT-METHOD org-export-convert-process)
+    (EXPORT-DIR (org-export-directory :html opt-plist))
+    (FILE-NAME-EXTENSION (plist-get opt-plist :html-extension))
+    (EXPORT-BUFFER-NAME "*Org HTML Export*")
+    (ENTITY-CONTROL org-xhtml-entity-control-callbacks-alist)
+    (ENTITY-FORMAT org-xhtml-entity-format-callbacks-alist)
+    (TOPLEVEL-HLEVEL org-export-html-toplevel-hlevel)
+    (SPECIAL-STRING-REGEXPS org-export-html-special-string-regexps)
+    (CODING-SYSTEM-FOR-WRITE org-export-html-coding-system)
+    (CODING-SYSTEM-FOR-SAVE org-export-html-coding-system)
+    (INLINE-IMAGES org-export-html-inline-images)
+    (INLINE-IMAGE-EXTENSIONS org-export-html-inline-image-extensions)
+    (PLAIN-TEXT-MAP org-export-html-protect-char-alist)
+    (TABLE-FIRST-COLUMN-AS-LABELS
+     org-export-html-table-use-header-tags-for-first-column)
+    (TODO-KWD-CLASS-PREFIX org-export-html-todo-kwd-class-prefix)
+    (TAG-CLASS-PREFIX org-export-html-tag-class-prefix)
+    (FOOTNOTE-SEPARATOR org-export-html-footnote-separator)
+    (t (error "Unknown property: %s"  what))))
+
+(defun org-xhtml-get-coding-system-for-write ()
+  (or org-export-html-coding-system
+      (and (boundp 'buffer-file-coding-system) buffer-file-coding-system)))
+
+(defun org-xhtml-get-coding-system-for-save ()
+  (or org-export-html-coding-system
+      (and (boundp 'buffer-file-coding-system) buffer-file-coding-system)))
+
+(defun org-xhtml-insert-toc (toc)
+  ;; locate where toc needs to be inserted
+  (goto-char (point-min))
+  (cond
+   ((or (re-search-forward "<p>\\s-*\\[TABLE-OF-CONTENTS\\]\\s-*</p>" nil t)
+	(re-search-forward "\\[TABLE-OF-CONTENTS\\]" nil t))
+    (goto-char (match-beginning 0))
+    (replace-match "")
+    (insert toc))
+   (org-lparse-dyn-first-heading-pos
+    (goto-char org-lparse-dyn-first-heading-pos)
+    (when (looking-at "\\s-*</p>")
+      (goto-char (match-end 0))
+      (insert "\n"))
+    (insert toc))
+   (t (ignore))))
+
+(defun org-xhtml-insert-preamble (opt-plist)
+  (when (plist-get opt-plist :html-preamble)
+    (let ((html-pre (plist-get opt-plist :html-preamble))
+	  (title (plist-get opt-plist :title))
+	  (date (plist-get opt-plist :effective-date))
+	  (author (plist-get opt-plist :author))
+	  (lang-words (plist-get opt-plist :lang-words))
+	  (email (plist-get opt-plist :email)))
+      (cond ((stringp html-pre)
+	     (insert
+	      (format-spec html-pre `((?t . ,title) (?a . ,author)
+				      (?d . ,date) (?e . ,email)))))
+	    ((functionp html-pre)
+	     (funcall html-pre opt-plist))
+	    (t
+	     (insert
+	      (format-spec
+	       (or (cadr (assoc (nth 0 lang-words)
+				org-export-html-preamble-format))
+		   (cadr (assoc "en" org-export-html-preamble-format)))
+	       `((?t . ,title) (?a . ,author)
+		 (?d . ,date) (?e . ,email)))))))))
+
+(defun org-xhtml-insert-postamble (opt-plist)
+  (when org-lparse-footnote-definitions
+    (insert
+     (org-lparse-format
+      'FOOTNOTES-SECTION (nth 4 (plist-get opt-plist :lang-words))
+      (mapconcat (lambda (x) (cdr x))
+		 (nreverse org-lparse-footnote-definitions) "\n"))))
+  (let ((bib (org-export-html-get-bibliography)))
+    (when bib
+      (insert "\n" bib "\n")))
+
+  ;; export html postamble
+  (unless body-only
+    (let* ((html-post (plist-get opt-plist :html-postamble))
+	   (date (plist-get opt-plist :effective-date))
+	   (author (plist-get opt-plist :author))
+	   (email  (plist-get opt-plist :email))
+	   (lang-words (plist-get opt-plist :lang-words))
+	   (html-validation-link (or org-export-html-validation-link ""))
+	   (email
+	    (mapconcat (lambda(e)
+			 (format "<a href=\"mailto:%s\">%s</a>" e e))
+		       (split-string email ",+ *")
+		       ", "))
+	   (creator-info
+	    (concat "Org version " org-version " with Emacs version "
+		    (number-to-string emacs-major-version))))
+      (when (plist-get opt-plist :html-postamble)
+	(cond ((stringp html-post)
+	       (insert "<div id=\"postamble\">\n")
+	       (insert (format-spec html-post
+				    `((?a . ,author) (?e . ,email)
+				      (?d . ,date)   (?c . ,creator-info)
+				      (?v . ,html-validation-link))))
+	       (insert "</div>"))
+	      ((functionp html-post)
+	       (funcall html-post opt-plist))
+	      ((eq html-post 'auto)
+	       ;; fall back on default postamble
+	       (insert "<div id=\"postamble\">\n")
+	       (when (plist-get opt-plist :time-stamp-file)
+		 (insert "<p class=\"date\">" (nth 2 lang-words) ": " date "</p>\n"))
+	       (when (and (plist-get opt-plist :author-info) author)
+		 (insert "<p class=\"author\">" (nth 1 lang-words) ": " author "</p>\n"))
+	       (when (and (plist-get opt-plist :email-info) email)
+		 (insert "<p class=\"email\">" email "</p>\n"))
+	       (when (plist-get opt-plist :creator-info)
+		 (insert "<p class=\"creator\">"
+			 (concat "Org version " org-version " with Emacs version "
+				 (number-to-string emacs-major-version) "</p>\n")))
+	       (insert html-validation-link "\n</div>"))
+	      (t
+	       (insert "<div id=\"postamble\">\n")
+	       (insert (format-spec
+			(or (cadr (assoc (nth 0 lang-words)
+					 org-export-html-postamble-format))
+			    (cadr (assoc "en" org-export-html-postamble-format)))
+			`((?a . ,author) (?e . ,email)
+			  (?d . ,date)   (?c . ,creator-info)
+			  (?v . ,html-validation-link))))
+	       (insert "</div>"))))))
+
+  (if org-export-html-with-timestamp
+      (insert org-export-html-html-helper-timestamp)))
+
+
+;; There are references to org-html-expand, org-html-protect and
+;; org-html-do-expand outside of org-html.el. For now provide a
+;; migration path. Ultimately these functions have to be removed.
+
+;; (defun org-html-expand (string)
+;;   "A simple wrapper around `org-xml-encode-org-text-skip-links'."
+;;   (org-xml-encode-org-text-skip-links string))
+
+;; (defun org-html-protect (s)
+;;   "A simple wrapper around `org-xml-encode-plain-text'."
+;;   (org-xml-encode-plain-text s))
+
+;; (defun org-html-do-expand (s)
+;;   "A simple wrapper around `org-xml-encode-org-text'."
+;;   (org-xml-encode-org-text s))
+
+;; (defun org-export-html-format-href (s)
+;;   "A simple wrapper around `org-xml-format-href'."
+;;   (org-xml-format-href s))
+
+;; (defun org-export-html-format-desc (s)
+;;   "A simple wrapper around `org-xml-format-desc'."
+;;   (org-xml-format-desc s))
+
+(provide 'org-xhtml)
+
+;; arch-tag: 8109d84d-eb8f-460b-b1a8-f45f3a6c7ea1
+;;; org-html.el ends here

BIN
contrib/odt/BasicODConverter/BasicODConverter-0.8.0.oxt


+ 213 - 0
contrib/odt/BasicODConverter/Filters.bas

@@ -0,0 +1,213 @@
+REM  *****  BASIC  *****
+
+Dim DocTypes
+
+Private DocTypeToFiltersMap As New Collection
+Private WriterExportFilters As New Collection
+Private WriterWebExportFilters As New Collection
+Private CalcExportFilters As New Collection
+Private ImpressExportFilters As New Collection
+Private DrawExportFilters As New Collection
+
+
+Private ExportFiltersInited As Boolean
+
+Sub InitExportFilters
+	If ExportFiltersInited Then
+		Exit Sub
+	End If
+
+ 	DocTypes = Array(_
+			 "com.sun.star.text.TextDocument", _
+			 "com.sun.star.sheet.SpreadsheetDocument", _
+			 "com.sun.star.presentation.PresentationDocument", _
+			 "com.sun.star.drawing.DrawingDocument",_
+			 "com.sun.star.text.WebDocument"_
+			 )
+	With WriterExportFilters
+		.Add Key := "bib"       , Item :=Array("bib"   , "BibTeX"                                                       , "BibTeX_Writer                                 ")
+		.Add Key := "doc"       , Item :=Array("doc"   , "Microsoft Word 97/2000/XP"                                    , "MS Word 97                                    ")
+		.Add Key := "doc6"      , Item :=Array("doc"   , "Microsoft Word 6.0"                                           , "MS WinWord 6.0                                ")
+		.Add Key := "doc95"     , Item :=Array("doc"   , "Microsoft Word 95"                                            , "MS Word 95                                    ")
+		.Add Key := "docbook"   , Item :=Array("xml"   , "DocBook"                                                      , "DocBook File                                  ")
+		.Add Key := "html"      , Item :=Array("html"  , "HTML Document (OpenOffice.org Writer)"                        , "HTML (StarWriter)                             ")
+		.Add Key := "latex"     , Item :=Array("ltx"   , "LaTeX 2e"                                                     , "LaTeX_Writer                                  ")
+		.Add Key := "mediawiki" , Item :=Array("txt"   , "MediaWiki"                                                    , "MediaWiki                                     ")
+		.Add Key := "odt"       , Item :=Array("odt"   , "ODF Text Document"                                            , "writer8                                       ")
+		.Add Key := "ooxml"     , Item :=Array("xml"   , "Microsoft Office Open XML"                                    , "MS Word 2003 XML                              ")
+		.Add Key := "ott"       , Item :=Array("ott"   , "Open Document Text"                                           , "writer8_template                              ")
+		.Add Key := "pdf"       , Item :=Array("pdf"   , "Portable Document Format"                                     , "writer_pdf_Export                             ")
+		.Add Key := "rtf"       , Item :=Array("rtf"   , "Rich Text Format"                                             , "Rich Text Format                              ")
+		.Add Key := "sdw"       , Item :=Array("sdw"   , "StarWriter 5.0"                                               , "StarWriter 5.0                                ")
+		.Add Key := "sdw3"      , Item :=Array("sdw"   , "StarWriter 3.0"                                               , "StarWriter 3.0                                ")
+		.Add Key := "sdw4"      , Item :=Array("sdw"   , "StarWriter 4.0"                                               , "StarWriter 4.0                                ")
+		.Add Key := "stw"       , Item :=Array("stw"   , "Open Office.org 1.0 Text Document Template"                   , "writer_StarOffice_XML_Writer_Template         ")
+		.Add Key := "sxw"       , Item :=Array("sxw"   , "Open Office.org 1.0 Text Document"                            , "StarOffice XML (Writer)                       ")
+		.Add Key := "text"      , Item :=Array("txt"   , "Text Encoded"                                                 , "Text (encoded)                                ")
+		.Add Key := "txt"       , Item :=Array("txt"   , "Text"                                                         , "Text                                          ")
+		.Add Key := "uot"       , Item :=Array("uot"   , "Unified Office Format text"                                   , "UOF text                                      ")
+		.Add Key := "vor"       , Item :=Array("vor"   , "StarWriter 5.0 Template"                                      , "StarWriter 5.0 Vorlage/Template               ")
+		.Add Key := "vor3"      , Item :=Array("vor"   , "StarWriter 3.0 Template"                                      , "StarWriter 3.0 Vorlage/Template               ")
+		.Add Key := "vor4"      , Item :=Array("vor"   , "StarWriter 4.0 Template"                                      , "StarWriter 4.0 Vorlage/Template               ")
+		.Add Key := "xhtml"     , Item :=Array("html"  , "XHTML Document"                                               , "XHTML Writer File                             ")
+	End With
+
+	With DrawExportFilters
+		.Add Key := "bmp"       , Item :=Array("bmp"   , "Windows Bitmap"                                               , "draw_bmp_Export                               ")
+		.Add Key := "emf"       , Item :=Array("emf"   , "Enhanced Metafile"                                            , "draw_emf_Export                               ")
+		.Add Key := "eps"       , Item :=Array("eps"   , "Encapsulated PostScript"                                      , "draw_eps_Export                               ")
+		.Add Key := "gif"       , Item :=Array("gif"   , "Graphics Interchange Format"                                  , "draw_gif_Export                               ")
+		.Add Key := "html"      , Item :=Array("html"  , "HTML Document (OpenOffice.org Draw)"                          , "draw_html_Export                              ")
+		.Add Key := "jpg"       , Item :=Array("jpg"   , "Joint Photographic Experts Group"                             , "draw_jpg_Export                               ")
+		.Add Key := "met"       , Item :=Array("met"   , "OS/2 Metafile"                                                , "draw_met_Export                               ")
+		.Add Key := "odd"       , Item :=Array("odd"   , "OpenDocument Drawing"                                         , "draw8                                         ")
+		.Add Key := "otg"       , Item :=Array("otg"   , "OpenDocument Drawing Template"                                , "draw8_template                                ")
+		.Add Key := "pbm"       , Item :=Array("pbm"   , "Portable Bitmap"                                              , "draw_pbm_Export                               ")
+		.Add Key := "pct"       , Item :=Array("pct"   , "Mac Pict"                                                     , "draw_pct_Export                               ")
+		.Add Key := "pdf"       , Item :=Array("pdf"   , "Portable Document Format"                                     , "draw_pdf_Export                               ")
+		.Add Key := "pgm"       , Item :=Array("pgm"   , "Portable Graymap"                                             , "draw_pgm_Export                               ")
+		.Add Key := "png"       , Item :=Array("png"   , "Portable Network Graphic"                                     , "draw_png_Export                               ")
+		.Add Key := "ppm"       , Item :=Array("ppm"   , "Portable Pixelmap"                                            , "draw_ppm_Export                               ")
+		.Add Key := "ras"       , Item :=Array("ras"   , "Sun Raster Image"                                             , "draw_ras_Export                               ")
+		.Add Key := "std"       , Item :=Array("std"   , "OpenOffice.org 1.0 Drawing Template"                          , "draw_StarOffice_XML_Draw_Template             ")
+		.Add Key := "svg"       , Item :=Array("svg"   , "Scalable Vector Graphics"                                     , "draw_svg_Export                               ")
+		.Add Key := "svm"       , Item :=Array("svm"   , "StarView Metafile"                                            , "draw_svm_Export                               ")
+		.Add Key := "swf"       , Item :=Array("swf"   , "Macromedia Flash (SWF)"                                       , "draw_flash_Export                             ")
+		.Add Key := "sxd"       , Item :=Array("sxd"   , "OpenOffice.org 1.0 Drawing"                                   , "StarOffice XML (Draw)                         ")
+		.Add Key := "sxd3"      , Item :=Array("sxd"   , "StarDraw 3.0"                                                 , "StarDraw 3.0                                  ")
+		.Add Key := "sxd5"      , Item :=Array("sxd"   , "StarDraw 5.0"                                                 , "StarDraw 5.0                                  ")
+		.Add Key := "tiff"      , Item :=Array("tiff"  , "Tagged Image File Format"                                     , "draw_tif_Export                               ")
+		.Add Key := "vor"       , Item :=Array("vor"   , "StarDraw 5.0 Template"                                        , "StarDraw 5.0 Vorlage                          ")
+		.Add Key := "vor3"      , Item :=Array("vor"   , "StarDraw 3.0 Template"                                        , "StarDraw 3.0 Vorlage                          ")
+		.Add Key := "wmf"       , Item :=Array("wmf"   , "Windows Metafile"                                             , "draw_wmf_Export                               ")
+		.Add Key := "xhtml"     , Item :=Array("xhtml" , "XHTML"                                                        , "XHTML Draw File                               ")
+		.Add Key := "xpm"       , Item :=Array("xpm"   , "X PixMap"                                                     , "draw_xpm_Export                               ")
+
+
+	End With
+
+	With ImpressExportFilters
+		.Add Key := "bmp"       , Item :=Array("bmp"   , "Windows Bitmap"                                               , "impress_bmp_Export                            ")
+		.Add Key := "emf"       , Item :=Array("emf"   , "Enhanced Metafile"                                            , "impress_emf_Export                            ")
+		.Add Key := "eps"       , Item :=Array("eps"   , "Encapsulated PostScript"                                      , "impress_eps_Export                            ")
+		.Add Key := "gif"       , Item :=Array("gif"   , "Graphics Interchange Format"                                  , "impress_gif_Export                            ")
+		.Add Key := "html"      , Item :=Array("html"  , "HTML Document (OpenOffice.org Impress)"                       , "impress_html_Export                           ")
+		.Add Key := "jpg"       , Item :=Array("jpg"   , "Joint Photographic Experts Group"                             , "impress_jpg_Export                            ")
+		.Add Key := "met"       , Item :=Array("met"   , "OS/2 Metafile"                                                , "impress_met_Export                            ")
+		.Add Key := "odg"       , Item :=Array("odg"   , "ODF Drawing (Impress)"                                        , "impress8_draw                                 ")
+		.Add Key := "odp"       , Item :=Array("odp"   , "ODF Presentation"                                             , "impress8                                      ")
+		.Add Key := "otp"       , Item :=Array("otp"   , "ODF Presentation Template"                                    , "impress8_template                             ")
+		.Add Key := "pbm"       , Item :=Array("pbm"   , "Portable Bitmap"                                              , "impress_pbm_Export                            ")
+		.Add Key := "pct"       , Item :=Array("pct"   , "Mac Pict"                                                     , "impress_pct_Export                            ")
+		.Add Key := "pdf"       , Item :=Array("pdf"   , "Portable Document Format"                                     , "impress_pdf_Export                            ")
+		.Add Key := "pgm"       , Item :=Array("pgm"   , "Portable Graymap"                                             , "impress_pgm_Export                            ")
+		.Add Key := "png"       , Item :=Array("png"   , "Portable Network Graphic"                                     , "impress_png_Export                            ")
+		.Add Key := "pot"       , Item :=Array("pot"   , "Microsoft PowerPoint 97/2000/XP Template"                     , "MS PowerPoint 97 Vorlage                      ")
+		.Add Key := "ppm"       , Item :=Array("ppm"   , "Portable Pixelmap"                                            , "impress_ppm_Export                            ")
+		.Add Key := "ppt"       , Item :=Array("ppt"   , "Microsoft PowerPoint 97/2000/XP"                              , "MS PowerPoint 97                              ")
+		.Add Key := "pwp"       , Item :=Array("pwp"   , "PlaceWare"                                                    , "placeware_Export                              ")
+		.Add Key := "ras"       , Item :=Array("ras"   , "Sun Raster Image"                                             , "impress_ras_Export                            ")
+		.Add Key := "sda"       , Item :=Array("sda"   , "StarDraw 5.0 (OpenOffice.org Impress)"                        , "StarDraw 5.0 (StarImpress)                    ")
+		.Add Key := "sdd"       , Item :=Array("sdd"   , "StarImpress 5.0"                                              , "StarImpress 5.0                               ")
+		.Add Key := "sdd3"      , Item :=Array("sdd"   , "StarDraw 3.0 (OpenOffice.org Impress)"                        , "StarDraw 3.0 (StarImpress)                    ")
+		.Add Key := "sdd4"      , Item :=Array("sdd"   , "StarImpress 4.0"                                              , "StarImpress 4.0                               ")
+		.Add Key := "sti"       , Item :=Array("sti"   , "OpenOffice.org 1.0 Presentation Template"                     , "impress_StarOffice_XML_Impress_Template       ")
+		.Add Key := "svg"       , Item :=Array("svg"   , "Scalable Vector Graphics"                                     , "impress_svg_Export                            ")
+		.Add Key := "svm"       , Item :=Array("svm"   , "StarView Metafile"                                            , "impress_svm_Export                            ")
+		.Add Key := "swf"       , Item :=Array("swf"   , "Macromedia Flash (SWF)"                                       , "impress_flash_Export                          ")
+		.Add Key := "sxd"       , Item :=Array("sxd"   , "OpenOffice.org 1.0 Drawing (OpenOffice.org Impress)"          , "impress_StarOffice_XML_Draw                   ")
+		.Add Key := "sxi"       , Item :=Array("sxi"   , "OpenOffice.org 1.0 Presentation"                              , "StarOffice XML (Impress)                      ")
+		.Add Key := "tiff"      , Item :=Array("tiff"  , "Tagged Image File Format"                                     , "impress_tif_Export                            ")
+		.Add Key := "uop"       , Item :=Array("uop"   , "Unified Office Format presentation"                           , "UOF presentation                              ")
+		.Add Key := "vor"       , Item :=Array("vor"   , "StarImpress 5.0 Template"                                     , "StarImpress 5.0 Vorlage                       ")
+		.Add Key := "vor3"      , Item :=Array("vor"   , "StarDraw 3.0 Template (OpenOffice.org Impress)"               , "StarDraw 3.0 Vorlage (StarImpress)            ")
+		.Add Key := "vor4"      , Item :=Array("vor"   , "StarImpress 4.0 Template"                                     , "StarImpress 4.0 Vorlage                       ")
+		.Add Key := "vor5"      , Item :=Array("vor"   , "StarDraw 5.0 Template (OpenOffice.org Impress)"               , "StarDraw 5.0 Vorlage (StarImpress)            ")
+		.Add Key := "wmf"       , Item :=Array("wmf"   , "Windows Metafile"                                             , "impress_wmf_Export                            ")
+		.Add Key := "xhtml"     , Item :=Array("xml"   , "XHTML"                                                        , "XHTML Impress File                            ")
+		.Add Key := "xpm"       , Item :=Array("xpm"   , "X PixMap"                                                     , "impress_xpm_Export                            ")
+
+	End With
+
+	With CalcExportFilters
+		.Add Key := "csv"       , Item :=Array("csv"   , "Text CSV"                                                     , "Text - txt - csv (StarCalc)                   ")
+		.Add Key := "dbf"       , Item :=Array("dbf"   , "dBASE"                                                        , "dBase                                         ")
+		.Add Key := "dif"       , Item :=Array("dif"   , "Data Interchange Format"                                      , "DIF                                           ")
+		.Add Key := "html"      , Item :=Array("html"  , "HTML Document (OpenOffice.org Calc)"                          , "HTML (StarCalc)                               ")
+		.Add Key := "ods"       , Item :=Array("ods"   , "ODF Spreadsheet"                                              , "calc8                                         ")
+		.Add Key := "ooxml"     , Item :=Array("xml"   , "Microsoft Excel 2003 XML"                                     , "MS Excel 2003 XML                             ")
+		.Add Key := "ots"       , Item :=Array("ots"   , "ODF Spreadsheet Template"                                     , "calc8_template                                ")
+		.Add Key := "pdf"       , Item :=Array("pdf"   , "Portable Document Format"                                     , "calc_pdf_Export                               ")
+		.Add Key := "sdc"       , Item :=Array("sdc"   , "StarCalc 5.0"                                                 , "StarCalc 5.0                                  ")
+		.Add Key := "sdc3"      , Item :=Array("sdc"   , "StarCalc 3.0"                                                 , "StarCalc 3.0                                  ")
+		.Add Key := "sdc4"      , Item :=Array("sdc"   , "StarCalc 4.0"                                                 , "StarCalc 4.0                                  ")
+		.Add Key := "slk"       , Item :=Array("slk"   , "SYLK"                                                         , "SYLK                                          ")
+		.Add Key := "stc"       , Item :=Array("stc"   , "OpenOffice.org 1.0 Spreadsheet Template"                      , "calc_StarOffice_XML_Calc_Template             ")
+		.Add Key := "sxc"       , Item :=Array("sxc"   , "OpenOffice.org 1.0 Spreadsheet"                               , "StarOffice XML (Calc)                         ")
+		.Add Key := "uos"       , Item :=Array("uos"   , "Unified Office Format spreadsheet"                            , "UOF spreadsheet                               ")
+		.Add Key := "vor"       , Item :=Array("vor"   , "StarCalc 5.0 Template"                                        , "StarCalc 5.0 Vorlage/Template                 ")
+		.Add Key := "vor3"      , Item :=Array("vor"   , "StarCalc 3.0 Template"                                        , "StarCalc 3.0 Vorlage/Template                 ")
+		.Add Key := "vor4"      , Item :=Array("vor"   , "StarCalc 4.0 Template"                                        , "StarCalc 4.0 Vorlage/Template                 ")
+		.Add Key := "xhtml"     , Item :=Array("xhtml" , "XHTML"                                                        , "XHTML Calc File                               ")
+		.Add Key := "xls"       , Item :=Array("xls"   , "Microsoft Excel 97/2000/XP"                                   , "MS Excel 97                                   ")
+		.Add Key := "xls5"      , Item :=Array("xls"   , "Microsoft Excel 5.0"                                          , "MS Excel 5.0/95                               ")
+		.Add Key := "xls95"     , Item :=Array("xls"   , "Microsoft Excel 95"                                           , "MS Excel 95                                   ")
+		.Add Key := "xlt"       , Item :=Array("xlt"   , "Microsoft Excel 97/2000/XP Template"                          , "MS Excel 97 Vorlage/Template                  ")
+		.Add Key := "xlt5"      , Item :=Array("xlt"   , "Microsoft Excel 5.0 Template"                                 , "MS Excel 5.0/95 Vorlage/Template              ")
+		.Add Key := "xlt95"     , Item :=Array("xlt"   , "Microsoft Excel 95 Template"                                  , "MS Excel 95 Vorlage/Template                  ")
+
+	End With
+
+	With WriterWebExportFilters
+		.Add Key := "etext"     , Item :=Array("txt"   , "Text Encoded (OpenOffice.org Writer/Web)"                     , "Text (encoded) (StarWriter/Web)               ")
+		.Add Key := "html"      , Item :=Array("html"  , "HTML Document"                                                , "HTML                                          ")
+		'.Add Key := "html"      , Item :=Array("html"  , "HTML Document Template"                                       , "writerweb8_writer_template                    ")
+		.Add Key := "html10"    , Item :=Array("html"  , "OpenOffice.org 1.0 HTML Template"                             , "writer_web_StarOffice_XML_Writer_Web_Template ")
+		.Add Key := "mediawiki" , Item :=Array("txt"   , "MediaWiki"                                                    , "MediaWiki_Web                                 ")
+		.Add Key := "pdf"       , Item :=Array("pdf"   , "PDF - Portable Document Format"                               , "writer_web_pdf_Export                         ")
+		.Add Key := "sdw"       , Item :=Array("sdw"   , "StarWriter 5.0 (OpenOffice.org Writer/Web)"                   , "StarWriter 5.0 (StarWriter/Web)               ")
+		.Add Key := "sdw3"      , Item :=Array("sdw"   , "StarWriter 3.0 (OpenOffice.org Writer/Web)"                   , "StarWriter 3.0 (StarWriter/Web)               ")
+		.Add Key := "sdw4"      , Item :=Array("sdw"   , "StarWriter 4.0 (OpenOffice.org Writer/Web)"                   , "StarWriter 4.0 (StarWriter/Web)               ")
+		.Add Key := "text"      , Item :=Array("txt"   , "Text (OpenOffice.org Writer/Web)"                             , "Text (StarWriter/Web)                         ")
+		.Add Key := "text10"    , Item :=Array("txt"   , "OpenOffice.org 1.0 Text Document (OpenOffice.org Writer/Web)" , "writer_web_StarOffice_XML_Writer              ")
+		.Add Key := "odt"       , Item :=Array("txt"   , "OpenOffice.org Text (OpenOffice.org Writer/Web)"              , "writerweb8_writer                             ")
+		.Add Key := "vor"       , Item :=Array("vor"   , "StarWriter/Web 5.0 Template"                                  , "StarWriter/Web 5.0 Vorlage/Template           ")
+		.Add Key := "vor4"      , Item :=Array("vor"   , "StarWriter/Web 4.0 Template"                                  , "StarWriter/Web 4.0 Vorlage/Template           ")
+
+	End With
+
+	With DocTypeToFiltersMap
+		.Add Key := "com.sun.star.text.TextDocument", Item := WriterExportFilters
+		.Add Key := "com.sun.star.sheet.SpreadsheetDocument", Item := CalcExportFilters
+		.Add Key := "com.sun.star.presentation.PresentationDocument", Item :=ImpressExportFilters
+		.Add Key := "com.sun.star.drawing.DrawingDocument", Item := DrawExportFilters
+		.Add Key := "com.sun.star.text.WebDocument", Item := WriterWebExportFilters
+	End With
+	ExportFiltersInited = True
+End Sub
+
+Function FilterSaveExtension(filterDescriptor ())
+	FilterSaveExtension = Trim(filterDescriptor(0))
+End Function
+
+Function FilterHandler(filterDescriptor ())
+	FilterHandler = Trim(filterDescriptor(2))
+End Function
+
+Function GetFilter(docType, outputFormat)
+	Dim filters
+
+	On Error Goto MissingFilter
+	filters = DocTypeToFiltersMap(docType)
+	LogMessage "output format is " & outputFormat
+	GetFilter = filters(outputFormat)
+
+Done:
+	Exit Function
+
+MissingFilter:
+	LogMessage("No existing filters for exporting " & docType & " to " & outputFormat)
+	GetFilter = Null
+	Resume Done
+End Function
+

+ 201 - 0
contrib/odt/BasicODConverter/Main.bas

@@ -0,0 +1,201 @@
+REM  *****  BASIC  *****
+
+Dim Interactive As Boolean
+Dim WaitFor
+
+Function Convert(Optional inFileURL, Optional filterSpec, Optional outFileURL)
+	Dim inDoc, inDocType, openParams, closeInDoc, presentationDoc
+
+	' Set Interactivity i.e., LogMessage pops up a message.
+	Interactive = False
+
+	WaitFor = 10
+
+	' Init dependencies
+	BasicLibraries.LoadLibrary("Tools")
+	' BasicLibraries.LoadLibrary("XrayTool")
+
+	' Setup Export filters
+ 	InitExportFilters
+
+	' Export to doc format by default
+ 	If IsMissing(filterSpec) Then
+		If Interactive Then
+			filterSpec = InputBox("Export to: ")
+		Else
+			filterSpec = "doc"
+		End If
+	End If
+	filterSpec = Trim(filterSpec)
+
+	closeInDoc = False
+	If IsMissing(inFileURL) Then
+		' Most likely, the Macro is run interactively. Act on
+		' the current document
+ 		If Not ThisComponent.HasLocation() Then
+			LogMessage("Document doesn't have a location")
+			Goto Failure
+		End If
+
+		inDoc = ThisComponent
+		inFileURL = inDoc.GetLocation()
+		closeInDoc = False
+
+	Else
+		' Load the document
+		On Error Goto Failure
+		openParams = Array(MakePropertyValue("Hidden", True),MakePropertyValue("ReadOnly", True),)
+
+		'openParams = Array()
+		inDoc = StarDesktop.loadComponentFromURL(inFileURL, "_blank", 0, OpenParams())
+		closeInDoc = True
+	End If
+
+	If IsMissing(outFileURL) Then
+		outFileURL = GetURLWithoutExtension(inFileURL)
+	End If
+
+	If ExportDocument(inDoc, filterSpec, outFileURL) Then
+		Goto Success
+	End If
+
+	LogMessage("filterSpec1 is " & filterSpec)
+
+	' Export didn't go through. Maybe didn't find a valid filter.
+
+	' Check whether the request is to convert a Text or a Web
+	' Document to a Presentation Document
+
+	inDocType = GetDocumentType(inDoc)
+	If (inDocType = "com.sun.star.text.TextDocument" Or _
+	    inDocType = "com.sun.star.text.WebDocument") Then
+		LogMessage("Filterspec2 is " & filterSpec)
+		filter = GetFilter("com.sun.star.presentation.PresentationDocument", filterSpec)
+		If IsNull(filter) Then
+			LogMessage("We tried our best. Nothing more to do"
+			Goto Failure
+		Else
+			LogMessage("Trying to create presentation document. Found valid filter for " & filterSpec)
+		End If
+	Else
+		Goto Failure
+	End If
+
+	' Export Outline to Presentation
+	dispatcher = createUnoService("com.sun.star.frame.DispatchHelper")
+	dispatcher.executeDispatch(inDoc.CurrentController.Frame, ".uno:SendOutlineToStarImpress", "", 0, Array())
+
+	' Dispatch event above is aynchronous. Wait for a few seconds for the above event to finish
+	Wait(WaitFor * 1000)
+
+	' After the dispatch, the current component is a presentation
+	' document. Note that it doesn't have a location
+
+	presentationDoc = ThisComponent
+	If IsNull(ExportDocument(presentationDoc, filter, outFileURL)) Then
+		Goto Failure
+	Else
+		presentationDoc.Close(True)
+	End If
+
+Success:
+	LogMessage("Successfully exported to " & outFileURL )
+	Goto Done
+
+Failure:
+	LogMessage("Export failed " & outFileURL )
+	Goto Done
+
+Done:
+	If closeInDoc Then
+		inDoc.Close(True)
+	End If
+End Function
+
+' http://codesnippets.services.openoffice.org/Writer/Writer.MergeDocs.snip
+' http://user.services.openoffice.org/en/forum/viewtopic.php?f=20&t=39983
+' http://user.services.openoffice.org/en/forum/viewtopic.php?f=21&t=23531
+
+' http://wiki.services.openoffice.org/wiki/Documentation/BASIC_Guide/Files_and_Directories_%28Runtime_Library%29
+
+
+Function ExportDocument(inputDoc, filterSpec, outFileURL) As Boolean
+	Dim inputDocType, filter
+	ExportDocument = False
+
+	On Error Goto Failure
+	inputDocType = GetDocumentType(inputDoc)
+
+	If IsArray(filterSpec) Then
+		' Filter is fully specified
+		filter = filterSpec
+	Else
+		' Filter is specified by it's name
+		filter = GetFilter(inputDocType, filterSpec)
+	End If
+
+	If InStr(outFileURL, ".") = 0 Then
+		outFileURL = outFileURL & "." & FilterSaveExtension(filter)
+	End If
+
+	LogMessage("outFileURL is " & outFileURL)
+
+	inputDoc.storeToUrl(outFileURL, Array(MakePropertyValue("FilterName", FilterHandler(filter))))
+
+ 	ExportDocument = True
+	LogMessage("Export to " & outFileURL & " succeeded")
+Done:
+ 	Exit Function
+
+Failure:
+	LogMessage("Export to " & outFileURL & " failed")
+	Resume Done
+End Function
+
+
+Function GetURLWithoutExtension(s As String)
+	Dim pos
+	pos = Instr(s, ".")
+	If pos = 0 Then
+		GetURLWithoutExtension = s
+	Else
+		GetURLWithoutExtension = Left(s, pos - 1)
+	End If
+End Function
+
+Function GetDocumentType(oDoc)
+	For Each docType in DocTypes
+		If (oDoc.supportsService(docType)) Then
+			GetDocumentType = docType
+			Exit Function
+		End If
+	Next docType
+	GetDocumentType = Nothing
+End Function
+
+Function MakePropertyValue(Optional sName As String, Optional sValue) As com.sun.star.beans.PropertyValue
+	Dim oPropertyValue As New com.sun.star.beans.PropertyValue
+
+ 	If Not IsMissing(sName) Then
+		oPropertyValue.Name = sName
+	EndIf
+
+	If Not IsMissing(sValue) Then
+		oPropertyValue.Value = sValue
+	EndIf
+
+	MakePropertyValue() = oPropertyValue
+
+End Function
+
+
+Sub LogMessage(message)
+	If Interactive Then
+		If Err <> 0 Then
+			Print "Error " & Err & ": " & Error$ & " (line : " & Erl & ")"
+		End If
+		Print message
+	End If
+End Sub
+
+

+ 17891 - 0
contrib/odt/OASIS/OpenDocument-schema-v1.1.rng

@@ -0,0 +1,17891 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+    OASIS OpenDocument v1.1
+    OASIS Standard, 1 Feb 2007
+    Relax-NG Schema
+
+    $Id$
+
+    © 2002-2007 OASIS Open
+    © 1999-2007 Sun Microsystems, Inc.
+-->
+
+<grammar
+    xmlns="http://relaxng.org/ns/structure/1.0"
+    xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"
+
+    datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes"
+
+    xmlns:office="urn:oasis:names:tc:opendocument:xmlns:office:1.0"
+    xmlns:meta="urn:oasis:names:tc:opendocument:xmlns:meta:1.0"
+    xmlns:config="urn:oasis:names:tc:opendocument:xmlns:config:1.0"
+    xmlns:text="urn:oasis:names:tc:opendocument:xmlns:text:1.0"
+    xmlns:table="urn:oasis:names:tc:opendocument:xmlns:table:1.0"
+    xmlns:draw="urn:oasis:names:tc:opendocument:xmlns:drawing:1.0"
+    xmlns:presentation="urn:oasis:names:tc:opendocument:xmlns:presentation:1.0"
+    xmlns:dr3d="urn:oasis:names:tc:opendocument:xmlns:dr3d:1.0"
+    xmlns:chart="urn:oasis:names:tc:opendocument:xmlns:chart:1.0"
+    xmlns:form="urn:oasis:names:tc:opendocument:xmlns:form:1.0"
+    xmlns:script="urn:oasis:names:tc:opendocument:xmlns:script:1.0"
+    xmlns:style="urn:oasis:names:tc:opendocument:xmlns:style:1.0"
+    xmlns:number="urn:oasis:names:tc:opendocument:xmlns:datastyle:1.0"
+    xmlns:anim="urn:oasis:names:tc:opendocument:xmlns:animation:1.0"
+
+    xmlns:dc="http://purl.org/dc/elements/1.1/"
+    xmlns:xlink="http://www.w3.org/1999/xlink"
+    xmlns:math="http://www.w3.org/1998/Math/MathML"
+    xmlns:xforms="http://www.w3.org/2002/xforms"
+
+    xmlns:fo="urn:oasis:names:tc:opendocument:xmlns:xsl-fo-compatible:1.0"
+    xmlns:svg="urn:oasis:names:tc:opendocument:xmlns:svg-compatible:1.0"
+    xmlns:smil="urn:oasis:names:tc:opendocument:xmlns:smil-compatible:1.0"
+>
+<define name="office-process-content">
+    <optional>
+        <attribute name="office:process-content" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<start>
+    <choice>
+        <ref name="office-document"/>
+        <ref name="office-document-content"/>
+        <ref name="office-document-styles"/>
+        <ref name="office-document-meta"/>
+        <ref name="office-document-settings"/>
+    </choice>
+</start>
+<define name="office-document">
+    <element name="office:document">
+        <ref name="office-document-attrs"/>
+        <ref name="office-document-common-attrs"/>
+        <ref name="office-meta"/>
+        <ref name="office-settings"/>
+        <ref name="office-scripts"/>
+        <ref name="office-font-face-decls"/>
+        <ref name="office-styles"/>
+        <ref name="office-automatic-styles"/>
+        <ref name="office-master-styles"/>
+        <ref name="office-body"/>
+    </element>
+</define>
+<define name="office-document-content">
+    <element name="office:document-content">
+        <ref name="office-document-common-attrs"/>
+        <ref name="office-scripts"/>
+        <ref name="office-font-face-decls"/>
+        <ref name="office-automatic-styles"/>
+        <ref name="office-body"/>
+    </element>
+</define>
+<define name="office-document-styles">
+    <element name="office:document-styles">
+        <ref name="office-document-common-attrs"/>
+        <ref name="office-font-face-decls"/>
+        <ref name="office-styles"/>
+        <ref name="office-automatic-styles"/>
+        <ref name="office-master-styles"/>
+    </element>
+</define>
+<define name="office-document-meta">
+    <element name="office:document-meta">
+        <ref name="office-document-common-attrs"/>
+        <ref name="office-meta"/>
+    </element>
+</define>
+<define name="office-document-settings">
+    <element name="office:document-settings">
+        <ref name="office-document-common-attrs"/>
+        <ref name="office-settings"/>
+    </element>
+</define>
+<define name="office-document-common-attrs" combine="interleave">
+    <optional>
+        <attribute name="office:version">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="office-document-attrs" combine="interleave">
+    <attribute name="office:mimetype">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="office-meta">
+    <optional>
+        <element name="office:meta">
+            <ref name="office-meta-content"/>
+        </element>
+    </optional>
+</define>
+
+<define name="office-meta-content">
+    <ref name="anyElements"/>
+</define>
+
+<define name="office-meta-content-strict">
+    <zeroOrMore>
+        <ref name="office-meta-data"/>
+    </zeroOrMore>
+</define>
+<define name="office-body">
+    <element name="office:body">
+        <ref name="office-body-content"/>
+    </element>
+</define>
+<define name="office-body-content" combine="choice">
+    <element name="office:text">
+        <ref name="office-text-attlist"/>
+        <ref name="office-text-content-prelude"/>
+        <zeroOrMore>
+            <ref name="office-text-content-main"/>
+        </zeroOrMore>
+        <ref name="office-text-content-epilogue"/>
+    </element>
+</define>
+<define name="office-text-content-prelude">
+    <ref name="office-forms"/>
+    <ref name="text-tracked-changes"/>
+    <ref name="text-decls"/>
+    <ref name="table-decls"/>
+</define>
+<define name="office-text-content-main">
+    <choice>
+        <zeroOrMore>
+            <ref name="text-content"/>
+        </zeroOrMore>
+        <group>
+            <ref name="text-page-sequence"/>
+            <zeroOrMore>
+                <choice>
+                    <ref name="draw-a"/>
+                    <ref name="shape"/>
+                </choice>
+            </zeroOrMore>
+        </group>
+    </choice>
+</define>
+
+<define name="text-content">
+    <choice>
+        <ref name="text-h"/>
+        <ref name="text-p"/>
+        <ref name="text-list"/>
+        <ref name="text-numbered-paragraph"/>
+        <ref name="table-table"/>
+        <ref name="draw-a"/>
+        <ref name="text-section"/>
+        <ref name="text-soft-page-break"/> 
+        <ref name="text-table-of-content"/>
+        <ref name="text-illustration-index"/>
+        <ref name="text-table-index"/>
+        <ref name="text-object-index"/>
+        <ref name="text-user-index"/>
+        <ref name="text-alphabetical-index"/>
+        <ref name="text-bibliography"/>
+        <ref name="shape"/>
+        <ref name="change-marks"/>
+    </choice>
+</define>
+<define name="office-text-content-epilogue">
+    <ref name="table-functions"/>
+</define>
+<define name="office-text-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:global" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="office-text-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:use-soft-page-breaks" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="office-body-content" combine="choice">
+    <element name="office:drawing">
+        <ref name="office-drawing-attlist"/>
+        <ref name="office-drawing-content-prelude"/>
+        <ref name="office-drawing-content-main"/>
+        <ref name="office-drawing-content-epilogue"/>
+    </element>
+</define>
+
+<define name="office-drawing-attlist">
+    <empty/>
+</define>
+<define name="office-drawing-content-prelude">
+    <ref name="text-decls"/>
+    <ref name="table-decls"/>
+</define>
+<define name="office-drawing-content-main">
+    <zeroOrMore>
+        <ref name="draw-page"/>
+    </zeroOrMore>
+</define>
+<define name="office-drawing-content-epilogue">
+    <ref name="table-functions"/>
+</define>
+<define name="office-body-content" combine="choice">
+    <element name="office:presentation">
+        <ref name="office-presentation-attlist"/>
+        <ref name="office-presentation-content-prelude"/>
+        <ref name="office-presentation-content-main"/>
+        <ref name="office-presentation-content-epilogue"/>
+    </element>
+</define>
+
+<define name="office-presentation-attlist">
+    <empty/>
+</define>
+<define name="office-presentation-content-prelude">
+    <ref name="text-decls"/>
+    <ref name="table-decls"/>
+    <ref name="presentation-decls"/>
+</define>
+<define name="office-presentation-content-main">
+    <zeroOrMore>
+        <ref name="draw-page"/>
+    </zeroOrMore>
+</define>
+<define name="office-presentation-content-epilogue">
+    <ref name="presentation-settings"/>
+    <ref name="table-functions"/>
+</define>
+<define name="office-body-content" combine="choice">
+    <element name="office:spreadsheet">
+        <ref name="office-spreadsheet-attlist"/>
+        <ref name="office-spreadsheet-content-prelude"/>
+        <ref name="office-spreadsheet-content-main"/>
+        <ref name="office-spreadsheet-content-epilogue"/>
+    </element>
+</define>
+<define name="office-spreadsheet-content-prelude">
+    <optional>
+        <ref name="table-tracked-changes"/>    
+    </optional>
+    <ref name="text-decls"/>
+    <ref name="table-decls"/>
+</define>
+
+<define name="table-decls">
+    <optional>
+        <ref name="table-calculation-settings"/>    
+    </optional>
+    <optional>
+        <ref name="table-content-validations"/>    
+    </optional>
+    <optional>
+        <ref name="table-label-ranges"/>    
+    </optional>
+</define>
+<define name="office-spreadsheet-content-main">
+    <zeroOrMore>
+        <ref name="table-table"/>
+    </zeroOrMore>
+</define>
+<define name="office-spreadsheet-content-epilogue">
+    <ref name="table-functions"/>    
+</define>
+
+<define name="table-functions">
+    <optional>
+        <ref name="table-named-expressions"/>    
+    </optional>
+    <optional>
+        <ref name="table-database-ranges"/>    
+    </optional>
+    <optional>
+        <ref name="table-data-pilot-tables"/>    
+    </optional>
+    <optional>
+        <ref name="table-consolidation"/>    
+    </optional>
+    <optional>
+        <ref name="table-dde-links"/>    
+    </optional>
+</define>
+<define name="office-body-content" combine="choice">
+    <element name="office:chart">
+        <ref name="office-chart-attlist"/>
+        <ref name="office-chart-content-prelude"/>
+        <ref name="office-chart-content-main"/>
+        <ref name="office-chart-content-epilogue"/>
+    </element>
+</define>
+
+<define name="office-chart-attlist">
+    <empty/>
+</define>
+<define name="office-chart-content-prelude">
+    <ref name="text-decls"/>
+    <ref name="table-decls"/>
+</define>
+<define name="office-chart-content-main">
+    <ref name="chart-chart"/>
+</define>
+<define name="office-chart-content-epilogue">
+    <ref name="table-functions"/>    
+</define>
+<define name="office-body-content" combine="choice">
+    <element name="office:image">
+        <ref name="office-image-attlist"/>
+        <ref name="office-image-content-prelude"/>
+        <ref name="office-image-content-main"/>
+        <ref name="office-image-content-epilogue"/>
+    </element>
+</define>
+
+<define name="office-image-attlist">
+    <empty/>
+</define>
+<define name="office-image-content-prelude">
+    <empty/>
+</define>
+<define name="office-image-content-main">
+    <ref name="draw-frame"/>
+</define>
+<define name="office-image-content-epilogue">
+    <empty/>
+</define>
+<define name="office-settings">
+    <optional>
+        <element name="office:settings">
+            <oneOrMore>
+                <ref name="config-config-item-set"/>
+            </oneOrMore>
+        </element>
+    </optional>
+</define>
+<define name="config-config-item-set">
+    <element name="config:config-item-set">
+        <ref name="config-config-item-set-attlist"/>
+        <ref name="config-items"/>
+    </element>
+</define>
+
+<define name="config-items">
+    <oneOrMore>
+        <choice>
+            <ref name="config-config-item"/>
+            <ref name="config-config-item-set"/>
+            <ref name="config-config-item-map-named"/>
+            <ref name="config-config-item-map-indexed"/>
+        </choice>
+    </oneOrMore>
+</define>
+<define name="config-config-item-set-attlist" combine="interleave">
+    <attribute name="config:name">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="config-config-item">
+    <element name="config:config-item">
+        <ref name="config-config-item-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="config-config-item-attlist" combine="interleave">
+    <attribute name="config:name">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="config-config-item-attlist" combine="interleave">
+    <attribute name="config:type">
+        <choice>
+            <value>boolean</value>
+            <value>short</value>
+            <value>int</value>
+            <value>long</value>
+            <value>double</value>
+            <value>string</value>
+            <value>datetime</value>
+            <value>base64Binary</value>
+        </choice>
+    </attribute>
+</define>
+<define name="config-config-item-map-indexed">
+    <element name="config:config-item-map-indexed">
+        <ref name="config-config-item-map-indexed-attlist"/>
+        <oneOrMore>
+            <ref name="config-config-item-map-entry"/>
+        </oneOrMore>
+    </element>
+</define>
+<define name="config-config-item-map-indexed-attlist" combine="interleave">
+    <attribute name="config:name">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="config-config-item-map-entry">
+    <element name="config:config-item-map-entry">
+        <ref name="config-config-item-map-entry-attlist"/>
+        <ref name="config-items"/>
+    </element>
+</define>
+<define name="config-config-item-map-entry-attlist" combine="interleave">
+    <optional>
+        <attribute name="config:name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="config-config-item-map-named">
+    <element name="config:config-item-map-named">
+        <ref name="config-config-item-map-named-attlist"/>
+        <oneOrMore>
+            <ref name="config-config-item-map-entry"/>
+        </oneOrMore>
+    </element>
+</define>
+<define name="config-config-item-map-named-attlist" combine="interleave">
+    <attribute name="config:name">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="office-scripts">
+    <optional>
+        <element name="office:scripts">
+            <zeroOrMore>
+                <ref name="office-script"/>
+            </zeroOrMore>
+            <optional>
+                <ref name="office-event-listeners"/>
+            </optional>
+        </element>
+    </optional>
+</define>
+<define name="office-script">
+    <element name="office:script">
+        <ref name="office-script-attlist"/>
+        <mixed>
+            <ref name="anyElements"/>
+        </mixed>
+    </element>
+</define>
+<define name="office-script-attlist">
+    <attribute name="script:language">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="office-font-face-decls">
+    <optional>
+        <element name="office:font-face-decls">
+            <zeroOrMore>
+                <ref name="style-font-face"/>
+            </zeroOrMore>
+        </element>
+    </optional>
+</define>
+<define name="office-styles">
+    <optional>
+        <element name="office:styles">
+            <interleave>
+                <ref name="styles"/>
+                <zeroOrMore>
+                    <ref name="style-default-style"/>
+                </zeroOrMore>
+                <optional>
+                    <ref name="text-outline-style"/>
+                </optional>
+                <zeroOrMore>
+                    <ref name="text-notes-configuration"/>
+                </zeroOrMore>
+                <optional>
+                    <ref name="text-bibliography-configuration"/>
+                </optional>
+                <optional>
+                    <ref name="text-linenumbering-configuration"/>
+                </optional>
+                <zeroOrMore>
+                    <ref name="draw-gradient"/>
+                </zeroOrMore>
+                <zeroOrMore>
+                    <ref name="svg-linearGradient"/>
+                </zeroOrMore>
+                <zeroOrMore>
+                    <ref name="svg-radialGradient"/>
+                </zeroOrMore>
+                <zeroOrMore>
+                    <ref name="draw-hatch"/>
+                </zeroOrMore>
+                <zeroOrMore>
+                    <ref name="draw-fill-image"/>
+                </zeroOrMore>
+                <zeroOrMore>
+                    <ref name="draw-marker"/>
+                </zeroOrMore>
+                <zeroOrMore>
+                    <ref name="draw-stroke-dash"/>
+                </zeroOrMore>
+                <zeroOrMore>
+                    <ref name="draw-opacity"/>
+                </zeroOrMore>
+                <zeroOrMore>
+                    <ref name="style-presentation-page-layout"/>
+                </zeroOrMore>
+            </interleave>
+        </element>
+    </optional>
+</define>
+<define name="office-automatic-styles">
+    <optional>
+        <element name="office:automatic-styles">
+            <interleave>
+                <ref name="styles"/>
+                <zeroOrMore>
+                    <ref name="style-page-layout"/>
+                </zeroOrMore>
+            </interleave>
+        </element>
+    </optional>
+</define>
+<define name="office-master-styles">
+    <optional>
+        <element name="office:master-styles">
+            <interleave>
+                <zeroOrMore>
+                    <ref name="style-master-page"/>
+                </zeroOrMore>
+                <optional>
+                    <ref name="style-handout-master"/>
+                </optional>
+                <optional>
+                    <ref name="draw-layer-set"/>
+                </optional>
+            </interleave>
+        </element>
+    </optional>
+</define>
+
+<define name="styles">
+    <interleave>
+        <zeroOrMore>
+            <ref name="style-style"/>
+        </zeroOrMore>
+        <zeroOrMore>
+            <ref name="text-list-style"/>
+        </zeroOrMore>
+        <zeroOrMore>
+            <ref name="number-number-style"/>
+        </zeroOrMore>
+        <zeroOrMore>
+            <ref name="number-currency-style"/>
+        </zeroOrMore>
+        <zeroOrMore>
+            <ref name="number-percentage-style"/>
+        </zeroOrMore>
+        <zeroOrMore>
+            <ref name="number-date-style"/>
+        </zeroOrMore>
+        <zeroOrMore>
+            <ref name="number-time-style"/>
+        </zeroOrMore>
+        <zeroOrMore>
+            <ref name="number-boolean-style"/>
+        </zeroOrMore>
+        <zeroOrMore>
+            <ref name="number-text-style"/>
+        </zeroOrMore>
+    </interleave>
+</define>
+<define name="office-meta-data" combine="choice">
+    <element name="meta:generator">
+        <ref name="string"/>
+    </element>
+</define>
+<define name="office-meta-data" combine="choice">
+    <element name="dc:title">
+        <ref name="string"/>
+    </element>
+</define>
+<define name="office-meta-data" combine="choice">
+    <element name="dc:description">
+        <ref name="string"/>
+    </element>
+</define>
+<define name="office-meta-data" combine="choice">
+    <element name="dc:subject">
+        <ref name="string"/>
+    </element>
+</define>
+<define name="office-meta-data" combine="choice">
+    <element name="meta:keyword">
+        <ref name="string"/>
+    </element>
+</define>
+<define name="office-meta-data" combine="choice">
+    <element name="meta:initial-creator">
+        <ref name="string"/>
+    </element>
+</define>
+<define name="office-meta-data" combine="choice">
+    <ref name="dc-creator"/>
+</define>
+<define name="dc-creator">
+    <element name="dc:creator">
+        <ref name="string"/>
+    </element>
+</define>
+<define name="office-meta-data" combine="choice">
+    <element name="meta:printed-by">
+        <ref name="string"/>
+    </element>
+</define>
+<define name="office-meta-data" combine="choice">
+    <element name="meta:creation-date">
+        <ref name="dateTime"/>
+    </element>
+</define>
+<define name="office-meta-data" combine="choice">
+    <ref name="dc-date"/>
+</define>
+<define name="dc-date">
+    <element name="dc:date">
+        <ref name="dateTime"/>
+    </element>
+</define>
+<define name="office-meta-data" combine="choice">
+    <element name="meta:print-date">
+        <ref name="dateTime"/>
+    </element>
+</define>
+<define name="office-meta-data" combine="choice">
+    <element name="meta:template">
+        <attribute name="xlink:href">
+            <ref name="anyURI"/>
+        </attribute>
+        <optional>
+            <attribute name="xlink:type" a:defaultValue="simple">
+                <value>simple</value>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="xlink:actuate" a:defaultValue="onRequest">
+                <value>onRequest</value>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="xlink:title">
+                <ref name="string"/>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="meta:date">
+                <ref name="dateTime"/>
+            </attribute>
+        </optional>
+    </element>
+</define>
+<define name="office-meta-data" combine="choice">
+    <element name="meta:auto-reload">
+        <optional>
+            <attribute name="xlink:type" a:defaultValue="simple">
+                <value>simple</value>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="xlink:show" a:defaultValue="replace">
+                <value>replace</value>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="xlink:actuate" a:defaultValue="onLoad">
+                <value>onLoad</value>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="xlink:href">
+                <ref name="anyURI"/>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="meta:delay">
+                <ref name="duration"/>
+            </attribute>
+        </optional>
+    </element>
+</define>
+<define name="office-meta-data" combine="choice">
+    <element name="meta:hyperlink-behaviour">
+        <optional>
+            <attribute name="office:target-frame-name">
+                <ref name="targetFrameName"/>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="xlink:show">
+                <choice>
+                    <value>new</value>
+                    <value>replace</value>
+                </choice>
+            </attribute>
+        </optional>
+    </element>
+</define>
+<define name="office-meta-data" combine="choice">
+    <element name="dc:language">
+        <ref name="language"/>
+    </element>
+</define>
+<define name="office-meta-data" combine="choice">
+    <element name="meta:editing-cycles">
+        <ref name="nonNegativeInteger"/>
+    </element>
+</define>
+<define name="office-meta-data" combine="choice">
+    <element name="meta:editing-duration">
+        <ref name="duration"/>
+    </element>
+</define>
+<define name="office-meta-data" combine="choice">
+    <element name="meta:document-statistic">
+        <optional>
+            <attribute name="meta:page-count">
+                <ref name="nonNegativeInteger"/>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="meta:table-count">
+                <ref name="nonNegativeInteger"/>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="meta:draw-count">
+                <ref name="nonNegativeInteger"/>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="meta:image-count">
+                <ref name="nonNegativeInteger"/>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="meta:ole-object-count">
+                <ref name="nonNegativeInteger"/>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="meta:object-count">
+                <ref name="nonNegativeInteger"/>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="meta:paragraph-count">
+                <ref name="nonNegativeInteger"/>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="meta:word-count">
+                <ref name="nonNegativeInteger"/>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="meta:character-count">
+                <ref name="nonNegativeInteger"/>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="frame-count">
+                <ref name="nonNegativeInteger"/>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="sentence-count">
+                <ref name="nonNegativeInteger"/>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="syllable-count">
+                <ref name="nonNegativeInteger"/>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="non-whitespace-character-count">
+                <ref name="nonNegativeInteger"/>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="meta:row-count">
+                <ref name="nonNegativeInteger"/>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="meta:cell-count">
+                <ref name="nonNegativeInteger"/>
+            </attribute>
+        </optional>
+    </element>
+</define>
+<define name="office-meta-data" combine="choice">
+    <element name="meta:user-defined">
+        <attribute name="meta:name">
+            <ref name="string"/>
+        </attribute>
+        <choice>
+            <group>
+                <attribute name="meta:value-type">
+                    <value>float</value>
+                </attribute>
+                <ref name="double"/>
+            </group>
+            <group>
+                <attribute name="meta:value-type">
+                    <value>date</value>
+                </attribute>
+                <ref name="dateOrDateTime"/>
+            </group>
+            <group>
+                <attribute name="meta:value-type">
+                    <value>time</value>
+                </attribute>
+                <ref name="duration"/>
+            </group>
+            <group>
+                <attribute name="meta:value-type">
+                    <value>boolean</value>
+                </attribute>
+                <ref name="boolean"/>
+            </group>
+            <group>
+                <attribute name="meta:value-type">
+                    <value>string</value>
+                </attribute>
+                <ref name="string"/>
+            </group>
+            <text/>
+        </choice>
+    </element>
+</define>
+<define name="text-h">
+    <element name="text:h">
+        <ref name="heading-attrs"/>
+        <ref name="paragraph-attrs"/>
+        <optional>
+            <ref name="text-number"/>
+        </optional>
+        <zeroOrMore>
+            <ref name="paragraph-content"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="heading-attrs" combine="interleave">
+    <attribute name="text:outline-level">
+        <ref name="positiveInteger"/>
+    </attribute>
+</define>
+<define name="heading-attrs" combine="interleave">
+    <optional>
+        <attribute name="text:restart-numbering" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="heading-attrs" combine="interleave">
+    <optional>
+        <attribute name="text:start-value">
+            <ref name="nonNegativeInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="heading-attrs" combine="interleave">
+    <optional>
+        <attribute name="text:is-list-header" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-number">
+    <element name="text:number">
+        <ref name="string"/>
+    </element>
+</define>
+<define name="text-p">
+    <element name="text:p">
+        <ref name="paragraph-attrs"/>
+        <zeroOrMore>
+            <ref name="paragraph-content"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="paragraph-attrs">
+    <optional>
+        <attribute name="text:style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="text:class-names">
+            <ref name="styleNameRefs"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="text:cond-style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="paragraph-attrs" combine="interleave">
+    <optional>
+        <ref name="text-id"/>
+    </optional>
+</define>
+<define name="text-page-sequence">
+    <element name="text:page-sequence">
+        <oneOrMore>
+            <ref name="text-page"/>
+        </oneOrMore>
+    </element>
+</define>
+<define name="text-page">
+    <element name="text:page">
+        <ref name="text-page-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="text-page-attlist">
+    <attribute name="text:master-page-name">
+        <ref name="styleNameRef"/>
+    </attribute>
+</define>
+<define name="text-list">
+    <element name="text:list">
+        <ref name="text-list-attr"/>
+        <optional>
+            <ref name="text-list-header"/>
+        </optional>
+        <zeroOrMore>
+            <ref name="text-list-item"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="text-list-attr" combine="interleave">
+    <optional>
+        <attribute name="text:style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-list-attr" combine="interleave">
+    <optional>
+        <attribute name="text:continue-numbering">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-list-item">
+    <element name="text:list-item">
+        <ref name="text-list-item-attr"/>
+        <ref name="text-list-item-content"/>
+    </element>
+</define>
+<define name="text-list-item-content">
+    <optional>
+        <ref name="text-number"/>
+    </optional>
+    <zeroOrMore>
+        <choice>
+            <ref name="text-p"/>
+            <ref name="text-h"/>
+            <ref name="text-list"/>
+            <ref name="text-soft-page-break"/>
+        </choice>
+    </zeroOrMore>
+</define>
+<define name="text-list-item-attr" combine="interleave">
+    <optional>
+        <attribute name="text:start-value">
+            <ref name="nonNegativeInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-list-header">
+    <element name="text:list-header">
+        <ref name="text-list-item-content"/>
+    </element>
+</define>
+<define name="text-numbered-paragraph">
+    <element name="text:numbered-paragraph">
+        <ref name="text-numbered-paragraph-attr"/>
+        <optional>
+            <ref name="text-number"/>
+        </optional>
+        <choice>
+            <ref name="text-p"/>
+            <ref name="text-h"/>
+        </choice>
+    </element>
+</define>
+<define name="text-numbered-paragraph-attr" combine="interleave">
+    <optional>
+        <attribute name="text:level" a:defaultValue="1">
+            <ref name="positiveInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-numbered-paragraph-attr" combine="interleave">
+    <ref name="text-list-attr"/>
+</define>
+<define name="text-numbered-paragraph-attr" combine="interleave">
+    <ref name="text-list-item-attr"/>
+</define>
+<define name="text-section">
+    <element name="text:section">
+        <ref name="text-section-attr"/>
+        <choice>
+            <ref name="text-section-source"/>
+            <ref name="text-section-source-dde"/>
+            <empty/>
+        </choice>
+        <zeroOrMore>
+            <ref name="text-content"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="text-section-attr" combine="interleave">
+    <ref name="sectionAttr"/>
+</define>
+<define name="sectionAttr" combine="interleave">
+    <optional>
+        <attribute name="text:style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="sectionAttr" combine="interleave">
+    <attribute name="text:name">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="sectionAttr" combine="interleave">
+    <optional>
+        <attribute name="text:protected">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="sectionAttr" combine="interleave">
+    <optional>
+        <attribute name="text:protection-key">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-section-attr" combine="interleave">
+    <choice>
+        <attribute name="text:display">
+            <choice>
+                <value>true</value>
+                <value>none</value>
+            </choice>
+        </attribute>
+        <group>
+            <attribute name="text:display">
+                <value>condition</value>
+            </attribute>
+            <attribute name="text:condition">
+                <ref name="string"/>
+            </attribute>
+        </group>
+        <empty/>
+    </choice>
+</define>
+<define name="text-section-source">
+    <element name="text:section-source">
+        <ref name="text-section-source-attr"/>
+    </element>
+</define>
+<define name="text-section-source-attr" combine="interleave">
+    <optional>
+        <attribute name="xlink:href">
+            <ref name="anyURI"/>
+        </attribute>
+        <optional>
+            <attribute name="xlink:type" a:defaultValue="simple">
+                <value>simple</value>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="xlink:show" a:defaultValue="embed">
+                <value>embed</value>
+            </attribute>
+        </optional>
+    </optional>
+</define>
+<define name="text-section-source-attr" combine="interleave">
+    <optional>
+        <attribute name="text:section-name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-section-source-attr" combine="interleave">
+    <optional>
+        <attribute name="text:filter-name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-section-source-dde">
+    <ref name="office-dde-source"/>
+</define>
+<define name="text-tracked-changes">
+    <optional>
+        <element name="text:tracked-changes">
+            <ref name="text-tracked-changes-attr"/>
+            <zeroOrMore>
+                <ref name="text-changed-region"/>
+            </zeroOrMore>
+        </element>
+    </optional>
+</define>
+<define name="text-tracked-changes-attr" combine="interleave">
+    <optional>
+        <attribute name="text:track-changes" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-changed-region">
+    <element name="text:changed-region">
+        <ref name="text-changed-region-attr"/>
+        <ref name="text-changed-region-content"/>
+    </element>
+</define>
+<define name="text-changed-region-attr" combine="interleave">
+    <attribute name="text:id">
+        <ref name="ID"/>
+    </attribute>
+</define>
+<define name="text-changed-region-content" combine="choice">
+    <element name="text:insertion">
+        <ref name="office-change-info"/>
+    </element>
+</define>
+<define name="text-changed-region-content" combine="choice">
+    <element name="text:deletion">
+        <ref name="office-change-info"/>
+        <zeroOrMore>
+            <ref name="text-content"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="text-changed-region-content" combine="choice">
+    <element name="text:format-change">
+        <ref name="office-change-info"/>
+    </element>
+</define>
+<define name="change-marks">
+    <choice>
+        <element name="text:change">
+            <ref name="change-mark-attr"/>
+        </element>
+        <element name="text:change-start">
+            <ref name="change-mark-attr"/>
+        </element>
+        <element name="text:change-end">
+            <ref name="change-mark-attr"/>
+        </element>
+    </choice>
+</define>
+<define name="change-mark-attr">
+    <attribute name="text:change-id">
+        <ref name="IDREF"/>
+    </attribute>
+</define>
+<define name="text-soft-page-break">
+    <element name="text:soft-page-break">
+        <empty/>
+    </element>
+</define>
+<define name="text-decls">
+    <optional>
+        <element name="text:variable-decls">
+            <zeroOrMore>
+                <ref name="text-variable-decl"/>
+            </zeroOrMore>
+        </element>
+    </optional>
+    <optional>
+        <element name="text:sequence-decls">
+            <zeroOrMore>
+                <ref name="text-sequence-decl"/>
+            </zeroOrMore>
+        </element>
+    </optional>
+    <optional>
+        <element name="text:user-field-decls">
+            <zeroOrMore>
+                <ref name="text-user-field-decl"/>
+            </zeroOrMore>
+        </element>
+    </optional>
+    <optional>
+        <element name="text:dde-connection-decls">
+            <zeroOrMore>
+                <ref name="text-dde-connection-decl"/>
+            </zeroOrMore>
+        </element>
+    </optional>
+    <optional>
+        <ref name="text-alphabetical-index-auto-mark-file"/>
+    </optional>
+</define>
+<define name="paragraph-content" combine="choice">
+    <text/>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:s">
+        <optional>
+            <attribute name="text:c">
+                <ref name="nonNegativeInteger"/>
+            </attribute>
+        </optional>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:tab">
+        <ref name="text-tab-attr"/>
+    </element>
+</define>
+<define name="text-tab-attr">
+    <optional>
+        <attribute name="text:tab-ref">
+            <ref name="nonNegativeInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:line-break">
+        <empty/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <ref name="text-soft-page-break"/>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:span">
+        <optional>
+            <attribute name="text:style-name">
+                <ref name="styleNameRef"/>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="text:class-names">
+                <ref name="styleNameRefs"/>
+            </attribute>
+        </optional>
+        <zeroOrMore>
+            <ref name="paragraph-content"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:a">
+        <ref name="text-a-attlist"/>
+        <optional>
+            <ref name="office-event-listeners"/>
+        </optional>
+        <zeroOrMore>
+            <ref name="paragraph-content"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="text-a-attlist" combine="interleave">
+    <optional>
+        <attribute name="office:name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-a-attlist" combine="interleave">
+    <optional>
+        <attribute name="office:title">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-a-attlist" combine="interleave">
+    <attribute name="xlink:href">
+        <ref name="anyURI"/>
+    </attribute>
+    <optional>
+        <attribute name="xlink:type" a:defaultValue="simple">
+            <value>simple</value>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="xlink:actuate" a:defaultValue="onRequest">
+            <value>onRequest</value>
+        </attribute>
+    </optional>
+</define>
+<define name="text-a-attlist" combine="interleave">
+    <optional>
+        <attribute name="office:target-frame-name">
+            <ref name="targetFrameName"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="xlink:show">
+            <choice>
+                <value>new</value>
+                <value>replace</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="text-a-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="text:visited-style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="paragraph-content" combine="choice">
+    <choice>
+        <element name="text:bookmark">
+            <attribute name="text:name">
+                <ref name="string"/>
+            </attribute>
+        </element>
+        <element name="text:bookmark-start">
+            <attribute name="text:name">
+                <ref name="string"/>
+            </attribute>
+        </element>
+        <element name="text:bookmark-end">
+            <attribute name="text:name">
+                <ref name="string"/>
+            </attribute>
+        </element>
+    </choice>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:reference-mark">
+        <attribute name="text:name">
+            <ref name="string"/>
+        </attribute>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <choice>
+        <element name="text:reference-mark-start">
+            <attribute name="text:name">
+                <ref name="string"/>
+            </attribute>
+        </element>
+        <element name="text:reference-mark-end">
+            <attribute name="text:name">
+                <ref name="string"/>
+            </attribute>
+        </element>
+    </choice>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:note">
+        <ref name="text-note-class"/>
+        <optional>
+            <attribute name="text:id">
+                <ref name="string"/>
+            </attribute>
+        </optional>
+        <element name="text:note-citation">
+            <optional>
+                <attribute name="text:label">
+                    <ref name="string"/>
+                </attribute>
+            </optional>
+            <text/>
+        </element>
+        <element name="text:note-body">
+            <zeroOrMore>
+                <ref name="text-content"/>
+            </zeroOrMore>
+        </element>
+    </element>
+</define>
+<define name="text-note-class">
+    <attribute name="text:note-class">
+        <choice>
+            <value>footnote</value>
+            <value>endnote</value>
+        </choice>
+    </attribute>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:ruby">
+        <optional>
+            <attribute name="text:style-name">
+                <ref name="styleNameRef"/>
+            </attribute>
+        </optional>
+        <element name="text:ruby-base">
+            <ref name="paragraph-content"/>
+        </element>
+        <element name="text:ruby-text">
+            <optional>
+                <attribute name="text:style-name">
+                    <ref name="styleNameRef"/>
+                </attribute>
+            </optional>
+            <text/>
+        </element>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <ref name="office-annotation"/>
+</define>
+<define name="paragraph-content" combine="choice">
+    <ref name="change-marks"/>
+</define>
+<define name="paragraph-content" combine="choice">
+    <choice>
+        <ref name="shape"/>
+        <ref name="draw-a"/>
+    </choice>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:date">
+        <ref name="text-date-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="text-date-attlist" combine="interleave">
+    <interleave>
+        <ref name="common-field-fixed-attlist"/>
+        <ref name="common-field-data-style-name-attlist"/>
+    </interleave>
+</define>
+<define name="text-date-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:date-value">
+            <ref name="dateOrDateTime"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-date-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:date-adjust">
+            <ref name="duration"/>
+        </attribute>
+    </optional>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:time">
+        <ref name="text-time-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="text-time-attlist" combine="interleave">
+    <interleave>
+        <ref name="common-field-fixed-attlist"/>
+        <ref name="common-field-data-style-name-attlist"/>
+    </interleave>
+</define>
+<define name="text-time-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:time-value">
+            <ref name="timeOrDateTime"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-time-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:time-adjust">
+            <ref name="duration"/>
+        </attribute>
+    </optional>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:page-number">
+        <ref name="text-page-number-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="text-page-number-attlist" combine="interleave">
+    <interleave>
+        <ref name="common-field-num-format-attlist"/>
+        <ref name="common-field-fixed-attlist"/>
+    </interleave>
+</define>
+<define name="text-page-number-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:page-adjust">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-page-number-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:select-page">
+            <choice>
+                <value>previous</value>
+                <value>current</value>
+                <value>next</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:page-continuation">
+        <ref name="text-page-continuation-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="text-page-continuation-attlist" combine="interleave">
+    <attribute name="text:select-page">
+        <choice>
+            <value>previous</value>
+            <value>next</value>
+        </choice>
+    </attribute>
+</define>
+<define name="text-page-continuation-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:string-value">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:sender-firstname">
+        <ref name="common-field-fixed-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:sender-lastname">
+        <ref name="common-field-fixed-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:sender-initials">
+        <ref name="common-field-fixed-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:sender-title">
+        <ref name="common-field-fixed-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:sender-position">
+        <ref name="common-field-fixed-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:sender-email">
+        <ref name="common-field-fixed-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:sender-phone-private">
+        <ref name="common-field-fixed-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:sender-fax">
+        <ref name="common-field-fixed-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:sender-company">
+        <ref name="common-field-fixed-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:sender-phone-work">
+        <ref name="common-field-fixed-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:sender-street">
+        <ref name="common-field-fixed-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:sender-city">
+        <ref name="common-field-fixed-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:sender-postal-code">
+        <ref name="common-field-fixed-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:sender-country">
+        <ref name="common-field-fixed-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:sender-state-or-province">
+        <ref name="common-field-fixed-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:author-name">
+        <ref name="common-field-fixed-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:author-initials">
+        <ref name="common-field-fixed-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:chapter">
+        <ref name="text-chapter-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="text-chapter-attlist" combine="interleave">
+    <attribute name="text:display">
+        <choice>
+            <value>name</value>
+            <value>number</value>
+            <value>number-and-name</value>
+            <value>plain-number-and-name</value>
+            <value>plain-number</value>
+        </choice>
+    </attribute>
+</define>
+<define name="text-chapter-attlist" combine="interleave">
+    <attribute name="text:outline-level">
+        <ref name="nonNegativeInteger"/>
+    </attribute>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:file-name">
+        <ref name="text-file-name-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="text-file-name-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:display">
+            <choice>
+                <value>full</value>
+                <value>path</value>
+                <value>name</value>
+                <value>name-and-extension</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="text-file-name-attlist" combine="interleave">
+    <ref name="common-field-fixed-attlist"/>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:template-name">
+        <ref name="text-template-name-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="text-template-name-attlist">
+    <optional>
+        <attribute name="text:display">
+            <choice>
+                <value>full</value>
+                <value>path</value>
+                <value>name</value>
+                <value>name-and-extension</value>
+                <value>area</value>
+                <value>title</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:sheet-name">
+        <text/>
+    </element>
+</define>
+<define name="text-variable-decl">
+    <element name="text:variable-decl">
+        <ref name="common-field-name-attlist"/>
+        <ref name="common-value-type-attlist"/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:variable-set">
+        <interleave>
+            <ref name="common-field-name-attlist"/>
+            <ref name="common-field-formula-attlist"/>
+            <ref name="common-value-and-type-attlist"/>
+            <ref name="common-field-display-value-none-attlist"/>
+            <ref name="common-field-data-style-name-attlist"/>
+        </interleave>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:variable-get">
+        <interleave>
+            <ref name="common-field-name-attlist"/>
+            <ref name="common-field-display-value-formula-attlist"/>
+            <ref name="common-field-data-style-name-attlist"/>
+        </interleave>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:variable-input">
+        <interleave>
+            <ref name="common-field-name-attlist"/>
+            <ref name="common-field-description-attlist"/>
+            <ref name="common-value-type-attlist"/>
+            <ref name="common-field-display-value-none-attlist"/>
+            <ref name="common-field-data-style-name-attlist"/>
+        </interleave>
+        <text/>
+    </element>
+</define>
+<define name="text-user-field-decl">
+    <element name="text:user-field-decl">
+        <ref name="common-field-name-attlist"/>
+        <optional>
+            <ref name="common-field-formula-attlist"/>
+        </optional>
+        <ref name="common-value-and-type-attlist"/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:user-field-get">
+        <interleave>
+            <ref name="common-field-name-attlist"/>
+            <ref name="common-field-display-value-formula-none-attlist"/>
+            <ref name="common-field-data-style-name-attlist"/>
+        </interleave>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:user-field-input">
+        <interleave>
+            <ref name="common-field-name-attlist"/>
+            <ref name="common-field-description-attlist"/>
+            <ref name="common-field-data-style-name-attlist"/>
+        </interleave>
+        <text/>
+    </element>
+</define>
+<define name="text-sequence-decl">
+    <element name="text:sequence-decl">
+        <ref name="text-sequence-decl-attlist"/>
+    </element>
+</define>
+<define name="text-sequence-decl-attlist" combine="interleave">
+    <ref name="common-field-name-attlist"/>
+</define>
+<define name="text-sequence-decl-attlist" combine="interleave">
+    <attribute name="text:display-outline-level">
+        <ref name="nonNegativeInteger"/>
+    </attribute>
+</define>
+<define name="text-sequence-decl-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:separation-character">
+            <ref name="character"/>
+        </attribute>
+    </optional>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:sequence">
+        <interleave>
+            <ref name="common-field-name-attlist"/>
+            <ref name="common-field-formula-attlist"/>
+            <ref name="common-field-num-format-attlist"/>
+            <ref name="text-sequence-ref-name"/>
+        </interleave>
+        <text/>
+    </element>
+</define>
+<define name="text-sequence-ref-name">
+    <optional>
+        <attribute name="text:ref-name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:expression">
+        <interleave>
+            <ref name="common-field-formula-attlist"/>
+            <optional>
+                <ref name="common-value-and-type-attlist"/>
+            </optional>
+            <ref name="common-field-display-value-formula-attlist"/>
+            <ref name="common-field-data-style-name-attlist"/>
+        </interleave>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:text-input">
+        <ref name="common-field-description-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:initial-creator">
+        <ref name="common-field-fixed-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:creation-date">
+        <interleave>
+            <ref name="common-field-fixed-attlist"/>
+            <ref name="common-field-data-style-name-attlist"/>
+            <optional>
+                <attribute name="text:date-value">
+                    <ref name="dateOrDateTime"/>
+                </attribute>
+            </optional>
+        </interleave>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:creation-time">
+        <interleave>
+            <ref name="common-field-fixed-attlist"/>
+            <ref name="common-field-data-style-name-attlist"/>
+            <optional>
+                <attribute name="text:time-value">
+                    <ref name="timeOrDateTime"/>
+                </attribute>
+            </optional>
+        </interleave>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:description">
+        <ref name="common-field-fixed-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:user-defined">
+        <interleave>
+            <ref name="common-field-fixed-attlist"/>
+            <attribute name="text:name">
+                <ref name="string"/>
+            </attribute>
+            <ref name="common-field-data-style-name-attlist"/>
+            <optional>
+                <attribute name="office:value">
+                    <ref name="double"/>
+                </attribute>
+            </optional>
+            <optional>
+                <attribute name="office:date-value">
+                    <ref name="dateOrDateTime"/>
+                </attribute>
+            </optional>
+            <optional>
+                <attribute name="office:time-value">
+                    <ref name="duration"/>
+                </attribute>
+            </optional>
+            <optional>
+                <attribute name="office:boolean-value">
+                    <ref name="boolean"/>
+                </attribute>
+            </optional>
+            <optional>
+                <attribute name="office:string-value">
+                    <ref name="string"/>
+                </attribute>
+            </optional>
+        </interleave>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:print-time">
+        <interleave>
+            <ref name="common-field-fixed-attlist"/>
+            <ref name="common-field-data-style-name-attlist"/>
+            <optional>
+                <attribute name="text:time-value">
+                    <ref name="time"/>
+                </attribute>
+            </optional>
+        </interleave>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:print-date">
+        <interleave>
+            <ref name="common-field-fixed-attlist"/>
+            <ref name="common-field-data-style-name-attlist"/>
+            <optional>
+                <attribute name="text:date-value">
+                    <ref name="date"/>
+                </attribute>
+            </optional>
+        </interleave>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:printed-by">
+        <ref name="common-field-fixed-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:title">
+        <ref name="common-field-fixed-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:subject">
+        <ref name="common-field-fixed-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:keywords">
+        <ref name="common-field-fixed-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:editing-cycles">
+        <ref name="common-field-fixed-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:editing-duration">
+        <interleave>
+            <ref name="common-field-fixed-attlist"/>
+            <ref name="common-field-data-style-name-attlist"/>
+            <optional>
+                <attribute name="text:duration">
+                    <ref name="duration"/>
+                </attribute>
+            </optional>
+        </interleave>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:modification-time">
+        <interleave>
+            <ref name="common-field-fixed-attlist"/>
+            <ref name="common-field-data-style-name-attlist"/>
+            <optional>
+                <attribute name="text:time-value">
+                    <ref name="time"/>
+                </attribute>
+            </optional>
+        </interleave>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:modification-date">
+        <interleave>
+            <ref name="common-field-fixed-attlist"/>
+            <ref name="common-field-data-style-name-attlist"/>
+            <optional>
+                <attribute name="text:date-value">
+                    <ref name="date"/>
+                </attribute>
+            </optional>
+        </interleave>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:creator">
+        <ref name="common-field-fixed-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element>
+        <choice>
+            <name>text:page-count</name>
+            <name>text:paragraph-count</name>
+            <name>text:word-count</name>
+            <name>text:character-count</name>
+            <name>text:table-count</name>
+            <name>text:image-count</name>
+            <name>text:object-count</name>
+        </choice>
+        <ref name="common-field-num-format-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="common-field-database-table">
+    <ref name="common-field-database-table-attlist"/>
+    <ref name="common-field-database-name"/>
+</define>
+<define name="common-field-database-name" combine="choice">
+    <optional>
+        <attribute name="text:database-name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-field-database-name" combine="choice">
+    <ref name="form-connection-resource"/>
+</define>
+<define name="common-field-database-table-attlist" combine="interleave">
+    <attribute name="text:table-name">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="common-field-database-table-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:table-type">
+            <choice>
+                <value>table</value>
+                <value>query</value>
+                <value>command</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:database-display">
+        <ref name="text-database-display-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="text-database-display-attlist" combine="interleave">
+    <ref name="common-field-database-table"/>
+</define>
+<define name="text-database-display-attlist" combine="interleave">
+    <ref name="common-field-data-style-name-attlist"/>
+</define>
+<define name="text-database-display-attlist" combine="interleave">
+    <attribute name="text:column-name">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:database-next">
+        <ref name="text-database-next-attlist"/>
+    </element>
+</define>
+<define name="text-database-next-attlist" combine="interleave">
+    <ref name="common-field-database-table"/>
+</define>
+<define name="text-database-next-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:condition">
+            <ref name="formula"/>
+        </attribute>
+    </optional>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:database-row-select">
+        <ref name="text-database-row-select-attlist"/>
+    </element>
+</define>
+<define name="text-database-row-select-attlist" combine="interleave">
+    <ref name="common-field-database-table"/>
+</define>
+<define name="text-database-row-select-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:condition">
+            <ref name="formula"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-database-row-select-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:row-number">
+            <ref name="nonNegativeInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:database-row-number">
+        <interleave>
+            <ref name="common-field-database-table"/>
+            <ref name="common-field-num-format-attlist"/>
+            <optional>
+                <attribute name="text:value">
+                    <ref name="nonNegativeInteger"/>
+                </attribute>
+            </optional>
+        </interleave>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:database-name">
+        <ref name="common-field-database-table"/>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:page-variable-set">
+        <ref name="text-set-page-variable-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="text-set-page-variable-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:active">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-set-page-variable-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:page-adjust">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:page-variable-get">
+        <ref name="text-get-page-variable-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="text-get-page-variable-attlist" combine="interleave">
+    <ref name="common-field-num-format-attlist"/>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:placeholder">
+        <ref name="text-placeholder-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="text-placeholder-attlist" combine="interleave">
+    <attribute name="text:placeholder-type">
+        <choice>
+            <value>text</value>
+            <value>table</value>
+            <value>text-box</value>
+            <value>image</value>
+            <value>object</value>
+        </choice>
+    </attribute>
+</define>
+<define name="text-placeholder-attlist" combine="interleave">
+    <ref name="common-field-description-attlist"/>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:conditional-text">
+        <ref name="text-conditional-text-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="text-conditional-text-attlist" combine="interleave">
+    <attribute name="text:condition">
+        <ref name="formula"/>
+    </attribute>
+</define>
+<define name="text-conditional-text-attlist" combine="interleave">
+    <attribute name="text:string-value-if-true">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="text-conditional-text-attlist" combine="interleave">
+    <attribute name="text:string-value-if-false">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="text-conditional-text-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:current-value">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:hidden-text">
+        <ref name="text-hidden-text-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="text-hidden-text-attlist" combine="interleave">
+    <attribute name="text:condition">
+        <ref name="formula"/>
+    </attribute>
+</define>
+<define name="text-hidden-text-attlist" combine="interleave">
+    <attribute name="text:string-value">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="text-hidden-text-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:is-hidden">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element>
+        <choice>
+            <name>text:reference-ref</name>
+            <name>text:bookmark-ref</name>
+        </choice>
+        <interleave>
+            <ref name="text-common-ref-content"/>
+            <ref name="text-ref-content"/>
+        </interleave>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:note-ref">
+        <interleave>
+            <ref name="text-common-ref-content"/>
+            <ref name="text-note-ref-content"/>
+            <ref name="text-ref-content"/>
+        </interleave>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:sequence-ref">
+        <interleave>
+            <ref name="text-common-ref-content"/>
+            <ref name="text-sequence-ref-content"/>
+        </interleave>
+    </element>
+</define>
+<define name="text-common-ref-content" combine="interleave">
+    <text/>
+</define>
+<define name="text-common-ref-content" combine="interleave">
+    <optional>
+        <attribute name="text:ref-name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-note-ref-content" combine="interleave">
+    <ref name="text-note-class"/>
+</define>
+<define name="text-ref-content" combine="interleave">
+    <optional>
+        <attribute name="text:reference-format">
+            <choice>
+                <value>page</value>
+                <value>chapter</value>
+                <value>direction</value>
+                <value>text</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="text-sequence-ref-content" combine="interleave">
+    <optional>
+        <attribute name="text:reference-format">
+            <choice>
+                <value>page</value>
+                <value>chapter</value>
+                <value>direction</value>
+                <value>text</value>
+                <value>category-and-value</value>
+                <value>caption</value>
+                <value>value</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:script">
+        <interleave>
+            <choice>
+                <group>
+                    <attribute name="xlink:href">
+                        <ref name="anyURI"/>
+                    </attribute>
+                    <optional>
+                        <attribute name="xlink:type" a:defaultValue="simple">
+                            <value>simple</value>
+                        </attribute>
+                    </optional>
+                </group>    
+                <text/>
+            </choice>
+            <optional>
+                <attribute name="script:language">
+                    <ref name="string"/>
+                </attribute>
+            </optional>
+        </interleave>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:execute-macro">
+        <optional>
+            <attribute name="text:name">
+                <ref name="string"/>
+            </attribute>
+        </optional>
+        <optional>
+            <ref name="office-event-listeners"/>
+        </optional>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:hidden-paragraph">
+        <ref name="text-hidden-paragraph-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="text-hidden-paragraph-attlist" combine="interleave">
+    <attribute name="text:condition">
+        <ref name="formula"/>
+    </attribute>
+</define>
+<define name="text-hidden-paragraph-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:is-hidden">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:dde-connection">
+        <attribute name="text:connection-name">
+            <ref name="string"/>
+        </attribute>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:measure">
+        <attribute name="text:kind">
+            <choice>
+                <value>value</value>
+                <value>unit</value>
+                <value>gap</value>
+            </choice>
+        </attribute>
+        <text/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:table-formula">
+        <interleave>
+            <ref name="common-field-formula-attlist"/>
+            <ref name="common-field-display-value-formula-attlist"/>
+            <ref name="common-field-data-style-name-attlist"/>
+        </interleave>
+        <text/>
+    </element>
+</define>
+<define name="common-value-type-attlist">
+    <attribute name="office:value-type">
+        <ref name="valueType"/>
+    </attribute>
+</define>
+<define name="common-value-and-type-attlist">
+    <choice>
+        <group>
+            <attribute name="office:value-type">
+                <value>float</value>
+            </attribute>
+            <attribute name="office:value">
+                <ref name="double"/>
+            </attribute>
+        </group>
+        <group>
+            <attribute name="office:value-type">
+                <value>percentage</value>
+            </attribute>
+            <attribute name="office:value">
+                <ref name="double"/>
+            </attribute>
+        </group>
+        <group>
+            <attribute name="office:value-type">
+                <value>currency</value>
+            </attribute>
+            <attribute name="office:value">
+                <ref name="double"/>
+            </attribute>
+            <optional>
+                <attribute name="office:currency">
+                    <ref name="string"/>
+                </attribute>
+            </optional>
+        </group>
+        <group>
+            <attribute name="office:value-type">
+                <value>date</value>
+            </attribute>
+            <attribute name="office:date-value">
+                <ref name="dateOrDateTime"/>
+            </attribute>
+        </group>
+        <group>
+            <attribute name="office:value-type">
+                <value>time</value>
+            </attribute>
+            <attribute name="office:time-value">
+                <ref name="duration"/>
+            </attribute>
+        </group>
+        <group>
+            <attribute name="office:value-type">
+                <value>boolean</value>
+            </attribute>
+            <attribute name="office:boolean-value">
+                <ref name="boolean"/>
+            </attribute>
+        </group>
+        <group>
+            <attribute name="office:value-type">
+                <value>string</value>
+            </attribute>
+            <optional>
+                <attribute name="office:string-value">
+                    <ref name="string"/>
+                </attribute>
+            </optional>
+        </group>
+    </choice>
+</define>
+<define name="common-field-fixed-attlist">
+    <optional>
+        <attribute name="text:fixed">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-field-name-attlist">
+    <attribute name="text:name">
+        <ref name="variableName"/>
+    </attribute>
+</define>
+<define name="common-field-description-attlist">
+    <optional>
+        <attribute name="text:description">
+            <text/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-field-display-value-none-attlist">
+    <optional>
+        <attribute name="text:display">
+            <choice>
+                <value>value</value>
+                <value>none</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="common-field-display-value-formula-none-attlist">
+    <optional>
+        <attribute name="text:display">
+            <choice>
+                <value>value</value>
+                <value>formula</value>
+                <value>none</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="common-field-display-value-formula-attlist">
+    <optional>
+        <attribute name="text:display">
+            <choice>
+                <value>value</value>
+                <value>formula</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="common-field-formula-attlist">
+    <optional>
+        <attribute name="text:formula">
+            <ref name="formula"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-field-data-style-name-attlist">
+    <optional>
+        <attribute name="style:data-style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-field-num-format-attlist">
+    <optional>
+        <ref name="common-num-format-attlist"/>
+    </optional>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:toc-mark-start">
+        <ref name="text-toc-mark-start-attrs"/>
+    </element>
+</define>
+<define name="text-toc-mark-start-attrs">
+    <ref name="text-id"/>
+    <ref name="text-outline-level"/>
+</define>
+<define name="text-outline-level">
+    <optional>
+        <attribute name="text:outline-level">
+            <ref name="positiveInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-id">
+    <attribute name="text:id">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:toc-mark-end">
+        <ref name="text-id"/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:toc-mark">
+        <attribute name="text:string-value">
+            <ref name="string"/>
+        </attribute>
+        <ref name="text-outline-level"/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:user-index-mark-start">
+        <ref name="text-id"/>
+        <ref name="text-outline-level"/>
+        <ref name="text-index-name"/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:user-index-mark-end">
+        <ref name="text-id"/>
+        <ref name="text-outline-level"/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:user-index-mark">
+        <attribute name="text:string-value">
+            <ref name="string"/>
+        </attribute>
+        <ref name="text-outline-level"/>
+        <ref name="text-index-name"/>
+    </element>
+</define>
+<define name="text-index-name">
+    <attribute name="text:index-name">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:alphabetical-index-mark-start">
+        <ref name="text-id"/>
+        <ref name="text-alphabetical-index-mark-attrs"/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:alphabetical-index-mark-end">
+        <ref name="text-id"/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:alphabetical-index-mark">
+        <attribute name="text:string-value">
+            <ref name="string"/>
+        </attribute>
+        <ref name="text-alphabetical-index-mark-attrs"/>
+    </element>
+</define>
+<define name="text-alphabetical-index-mark-attrs" combine="interleave">
+    <optional>
+        <attribute name="text:key1">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="text:key2">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-alphabetical-index-mark-attrs" combine="interleave">
+    <optional>
+        <attribute name="text:string-value-phonetic">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="text:key1-phonetic">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="text:key2-phonetic">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-alphabetical-index-mark-attrs" combine="interleave">
+    <optional>
+        <attribute name="text:main-entry" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="text:bibliography-mark">
+        <attribute name="text:bibliography-type">
+            <ref name="text-bibliography-types"/>
+        </attribute>
+        <zeroOrMore>
+            <attribute>
+                <choice>
+                    <name>text:identifier</name>
+                    <name>text:address</name>
+                    <name>text:annote</name>
+                    <name>text:author</name>
+                    <name>text:booktitle</name>
+                    <name>text:chapter</name>
+                    <name>text:edition</name>
+                    <name>text:editor</name>
+                    <name>text:howpublished</name>
+                    <name>text:institution</name>
+                    <name>text:journal</name>
+                    <name>text:month</name>
+                    <name>text:note</name>
+                    <name>text:number</name>
+                    <name>text:organizations</name>
+                    <name>text:pages</name>
+                    <name>text:publisher</name>
+                    <name>text:school</name>
+                    <name>text:series</name>
+                    <name>text:title</name>
+                    <name>text:report-type</name>
+                    <name>text:volume</name>
+                    <name>text:year</name>
+                    <name>text:url</name>
+                    <name>text:custom1</name>
+                    <name>text:custom2</name>
+                    <name>text:custom3</name>
+                    <name>text:custom4</name>
+                    <name>text:custom5</name>
+                    <name>text:isbn</name>
+                    <name>text:issn</name>
+                </choice>
+                <ref name="string"/>
+            </attribute>
+        </zeroOrMore>
+        <text/>
+    </element>
+</define>
+<define name="text-bibliography-types">
+    <choice>
+        <value>article</value>
+        <value>book</value>
+        <value>booklet</value>
+        <value>conference</value>
+        <value>custom1</value>
+        <value>custom2</value>
+        <value>custom3</value>
+        <value>custom4</value>
+        <value>custom5</value>
+        <value>email</value>
+        <value>inbook</value>
+        <value>incollection</value>
+        <value>inproceedings</value>
+        <value>journal</value>
+        <value>manual</value>
+        <value>mastersthesis</value>
+        <value>misc</value>
+        <value>phdthesis</value>
+        <value>proceedings</value>
+        <value>techreport</value>
+        <value>unpublished</value>
+        <value>www</value>
+    </choice>
+</define>
+<define name="text-index-body">
+    <element name="text:index-body">
+        <zeroOrMore>
+            <ref name="index-content-main"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="index-content-main">
+    <choice>
+        <ref name="text-content"/>
+        <ref name="text-index-title"/>
+    </choice>
+</define>
+<define name="text-index-title">
+    <element name="text:index-title">
+        <ref name="sectionAttr"/>
+        <zeroOrMore>
+            <ref name="index-content-main"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="text-table-of-content">
+    <element name="text:table-of-content">
+        <ref name="sectionAttr"/>
+        <ref name="text-table-of-content-source"/>
+        <ref name="text-index-body"/>
+    </element>
+</define>
+<define name="text-table-of-content-source">
+    <element name="text:table-of-content-source">
+        <ref name="text-table-of-content-source-attlist"/>
+        <optional>
+            <ref name="text-index-title-template"/>
+        </optional>
+        <zeroOrMore>
+            <ref name="text-table-of-content-entry-template"/>
+        </zeroOrMore>
+        <zeroOrMore>
+            <ref name="text-index-source-styles"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="text-table-of-content-source-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:outline-level">
+            <choice>
+                <ref name="positiveInteger"/>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="text-table-of-content-source-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:use-outline-level" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-table-of-content-source-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:use-index-marks">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-table-of-content-source-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:use-index-source-styles">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-table-of-content-source-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:index-scope">
+            <choice>
+                <value>document</value>
+                <value>chapter</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="text-table-of-content-source-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:relative-tab-stop-position">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-table-of-content-entry-template">
+    <element name="text:table-of-content-entry-template">
+        <ref name="text-table-of-content-entry-template-attlist"/>
+        <zeroOrMore>
+            <ref name="text-table-of-content-children"/>
+
+        </zeroOrMore>
+    </element>
+</define>
+<define name="text-table-of-content-children">
+    <choice>
+        <ref name="text-index-entry-chapter"/>
+        <ref name="text-index-entry-page-number"/>
+        <ref name="text-index-entry-text"/>
+        <ref name="text-index-entry-span"/>
+        <ref name="text-index-entry-tab-stop"/>
+        <ref name="text-index-entry-link-start"/>
+        <ref name="text-index-entry-link-end"/>
+    </choice>
+</define>
+<define name="text-table-of-content-entry-template-attlist"
+        combine="interleave">
+    <attribute name="text:outline-level">
+        <ref name="positiveInteger"/>
+    </attribute>
+</define>
+<define name="text-table-of-content-entry-template-attlist"
+        combine="interleave">
+    <attribute name="text:style-name">
+        <ref name="styleNameRef"/>
+    </attribute>
+</define>
+<define name="text-illustration-index">
+    <element name="text:illustration-index">
+        <ref name="sectionAttr"/>
+        <ref name="text-illustration-index-source"/>
+        <ref name="text-index-body"/>
+    </element>
+</define>
+<define name="text-illustration-index-source">
+    <element name="text:illustration-index-source">
+        <ref name="text-illustration-index-source-attrs"/>
+        <optional>
+            <ref name="text-index-title-template"/>
+        </optional>
+        <optional>
+            <ref name="text-illustration-index-entry-template"/>
+        </optional>
+    </element>
+</define>
+<define name="text-illustration-index-source-attrs" combine="interleave">
+    <ref name="text-index-scope-attr"/>
+</define>
+<define name="text-index-scope-attr">
+    <optional>
+        <attribute name="text:index-scope" a:defaultValue="document">
+            <choice>
+                <value>document</value>
+                <value>chapter</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="text-illustration-index-source-attrs" combine="interleave">
+    <ref name="text-relative-tab-stop-position-attr"/>
+</define>
+<define name="text-relative-tab-stop-position-attr">
+    <optional>
+        <attribute name="text:relative-tab-stop-position"
+                   a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-illustration-index-source-attrs" combine="interleave">
+    <optional>
+        <attribute name="text:use-caption" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-illustration-index-source-attrs" combine="interleave">
+    <optional>
+        <attribute name="text:caption-sequence-name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-illustration-index-source-attrs" combine="interleave">
+    <optional>
+        <attribute name="text:caption-sequence-format">
+            <choice>
+                <value>text</value>
+                <value>category-and-value</value>
+                <value>caption</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="text-illustration-index-entry-template">
+    <element name="text:illustration-index-entry-template">
+        <ref name="text-illustration-index-entry-content"/>
+    </element>
+</define>
+<define name="text-illustration-index-entry-content">
+    <ref name="text-illustration-index-entry-template-attrs"/>
+    <zeroOrMore>
+        <choice>
+            <ref name="text-index-entry-page-number"/>
+            <ref name="text-index-entry-text"/>
+            <ref name="text-index-entry-span"/>
+            <ref name="text-index-entry-tab-stop"/>
+        </choice>
+    </zeroOrMore>
+</define>
+<define name="text-illustration-index-entry-template-attrs">
+    <attribute name="text:style-name">
+        <ref name="styleNameRef"/>
+    </attribute>
+</define>
+<define name="text-table-index">
+    <element name="text:table-index">
+        <ref name="sectionAttr"/>
+        <ref name="text-table-index-source"/>
+        <ref name="text-index-body"/>
+    </element>
+</define>
+<define name="text-table-index-source">
+    <element name="text:table-index-source">
+        <ref name="text-illustration-index-source-attrs"/>
+        <optional>
+            <ref name="text-index-title-template"/>
+        </optional>
+        <optional>
+            <ref name="text-table-index-entry-template"/>
+        </optional>
+    </element>
+</define>
+<define name="text-table-index-entry-template">
+    <element name="text:table-index-entry-template">
+        <ref name="text-illustration-index-entry-content"/>
+    </element>
+</define>
+<define name="text-object-index">
+    <element name="text:object-index">
+        <ref name="sectionAttr"/>
+        <ref name="text-object-index-source"/>
+        <ref name="text-index-body"/>
+    </element>
+</define>
+<define name="text-object-index-source">
+    <element name="text:object-index-source">
+        <ref name="text-object-index-source-attrs"/>
+        <optional>
+            <ref name="text-index-title-template"/>
+        </optional>
+        <optional>
+            <ref name="text-object-index-entry-template"/>
+        </optional>
+    </element>
+</define>
+<define name="text-object-index-source-attrs" combine="interleave">
+    <ref name="text-index-scope-attr"/>
+</define>
+<define name="text-object-index-source-attrs" combine="interleave">
+    <ref name="text-relative-tab-stop-position-attr"/>
+</define>
+<define name="text-object-index-source-attrs" combine="interleave">
+    <optional>
+        <attribute name="text:use-spreadsheet-objects" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-object-index-source-attrs" combine="interleave">
+    <optional>
+        <attribute name="text:use-math-objects" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-object-index-source-attrs" combine="interleave">
+    <optional>
+        <attribute name="text:use-draw-objects" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-object-index-source-attrs" combine="interleave">
+    <optional>
+        <attribute name="text:use-chart-objects" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-object-index-source-attrs" combine="interleave">
+    <optional>
+        <attribute name="text:use-other-objects" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-object-index-entry-template">
+    <element name="text:object-index-entry-template">
+        <ref name="text-illustration-index-entry-content"/>
+    </element>
+</define>
+<define name="text-user-index">
+    <element name="text:user-index">
+        <ref name="sectionAttr"/>
+        <ref name="text-user-index-source"/>
+        <ref name="text-index-body"/>
+    </element>
+</define>
+<define name="text-user-index-source">
+    <element name="text:user-index-source">
+        <ref name="text-user-index-source-attr"/>
+        <optional>
+            <ref name="text-index-title-template"/>
+        </optional>
+        <zeroOrMore>
+            <ref name="text-user-index-entry-template"/>
+        </zeroOrMore>
+        <zeroOrMore>
+            <ref name="text-index-source-styles"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="text-user-index-source-attr" combine="interleave">
+    <ref name="text-index-scope-attr"/>
+    <ref name="text-relative-tab-stop-position-attr"/>
+    <attribute name="text:index-name">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="text-user-index-source-attr" combine="interleave">
+    <optional>
+        <attribute name="text:use-index-marks" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="text:use-graphics" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="text:use-tables" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="text:use-floating-frames"
+                     a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="text:use-objects" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-user-index-source-attr" combine="interleave">
+    <optional>
+        <attribute name="text:copy-outline-levels"
+                     a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-user-index-entry-template">
+    <element name="text:user-index-entry-template">
+        <ref name="text-user-index-entry-template-attrs"/>
+        <zeroOrMore>
+            <choice>
+                <ref name="text-index-entry-chapter"/>
+                <ref name="text-index-entry-page-number"/>
+                <ref name="text-index-entry-text"/>
+                <ref name="text-index-entry-span"/>
+                <ref name="text-index-entry-tab-stop"/>
+            </choice>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="text-user-index-entry-template-attrs" combine="interleave">
+    <attribute name="text:outline-level">
+        <ref name="positiveInteger"/>
+    </attribute>
+</define>
+<define name="text-user-index-entry-template-attrs" combine="interleave">
+    <attribute name="text:style-name">
+        <ref name="styleNameRef"/>
+    </attribute>
+</define>
+<define name="text-alphabetical-index">
+    <element name="text:alphabetical-index">
+        <ref name="sectionAttr"/>
+        <ref name="text-alphabetical-index-source"/>
+        <ref name="text-index-body"/>
+    </element>
+</define>
+<define name="text-alphabetical-index-source">
+    <element name="text:alphabetical-index-source">
+        <ref name="text-alphabetical-index-source-attrs"/>
+        <optional>
+            <ref name="text-index-title-template"/>
+        </optional>
+        <zeroOrMore>
+            <ref name="text-alphabetical-index-entry-template"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="text-alphabetical-index-source-attrs" combine="interleave">
+    <ref name="text-index-scope-attr"/>
+    <ref name="text-relative-tab-stop-position-attr"/>
+</define>
+<define name="text-alphabetical-index-source-attrs" combine="interleave">
+    <optional>
+        <attribute name="text:ignore-case" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-alphabetical-index-source-attrs" combine="interleave">
+    <optional>
+        <attribute name="text:main-entry-style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-alphabetical-index-source-attrs" combine="interleave">
+    <optional>
+        <attribute name="text:alphabetical-separators" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-alphabetical-index-source-attrs" combine="interleave">
+    <optional>
+        <attribute name="text:combine-entries" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="text:combine-entries-with-dash"
+                   a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="text:combine-entries-with-pp" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-alphabetical-index-source-attrs" combine="interleave">
+    <optional>
+        <attribute name="text:use-keys-as-entries" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-alphabetical-index-source-attrs" combine="interleave">
+    <optional>
+        <attribute name="text:capitalize-entries" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-alphabetical-index-source-attrs" combine="interleave">
+    <optional>
+        <attribute name="text:comma-separated" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-alphabetical-index-source-attrs" combine="interleave">
+    <optional>
+        <attribute name="fo:language">
+            <ref name="languageCode"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-alphabetical-index-source-attrs" combine="interleave">
+    <optional>
+        <attribute name="fo:country">
+            <ref name="countryCode"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-alphabetical-index-source-attrs" combine="interleave">
+    <optional>
+        <attribute name="text:sort-algorithm">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-alphabetical-index-auto-mark-file">
+    <element name="text:alphabetical-index-auto-mark-file">
+        <attribute name="xlink:href">
+            <ref name="anyURI"/>
+        </attribute>
+        <optional>
+            <attribute name="xlink:type" a:defaultValue="simple">
+                <value>simple</value>
+            </attribute>
+        </optional>
+    </element>
+</define>
+<define name="text-alphabetical-index-entry-template">
+    <element name="text:alphabetical-index-entry-template">
+        <ref name="text-alphabetical-index-entry-template-attrs"/>
+        <zeroOrMore>
+            <choice>
+                <ref name="text-index-entry-chapter"/>
+                <ref name="text-index-entry-page-number"/>
+                <ref name="text-index-entry-text"/>
+                <ref name="text-index-entry-span"/>
+                <ref name="text-index-entry-tab-stop"/>
+            </choice>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="text-alphabetical-index-entry-template-attrs"
+        combine="interleave">
+    <attribute name="text:outline-level">
+        <choice>
+            <value>1</value>
+            <value>2</value>
+            <value>3</value>
+            <value>separator</value>
+        </choice>
+    </attribute>
+</define>
+<define name="text-alphabetical-index-entry-template-attrs"
+        combine="interleave">
+    <attribute name="text:style-name">
+        <ref name="styleNameRef"/>
+    </attribute>
+</define>
+<define name="text-bibliography">
+    <element name="text:bibliography">
+        <ref name="sectionAttr"/>
+        <ref name="text-bibliography-source"/>
+        <ref name="text-index-body"/>
+    </element>
+</define>
+<define name="text-bibliography-source">
+    <element name="text:bibliography-source">
+        <optional>
+            <ref name="text-index-title-template"/>
+        </optional>
+        <zeroOrMore>
+            <ref name="text-bibliography-entry-template"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="text-bibliography-entry-template">
+    <element name="text:bibliography-entry-template">
+        <ref name="text-bibliography-entry-template-attrs"/>
+        <zeroOrMore>
+            <choice>
+                <ref name="text-index-entry-span"/>
+                <ref name="text-index-entry-tab-stop"/>
+                <ref name="text-index-entry-bibliography"/>
+            </choice>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="text-bibliography-entry-template-attrs" combine="interleave">
+    <attribute name="text:bibliography-type">
+        <ref name="text-bibliography-types"/>
+    </attribute>
+</define>
+<define name="text-bibliography-entry-template-attrs" combine="interleave">
+    <attribute name="text:style-name">
+        <ref name="styleNameRef"/>
+    </attribute>
+</define>
+<define name="text-index-source-styles">
+    <element name="text:index-source-styles">
+        <attribute name="text:outline-level">
+            <ref name="positiveInteger"/>
+        </attribute>
+        <zeroOrMore>
+            <ref name="text-index-source-style"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="text-index-source-style">
+    <element name="text:index-source-style">
+        <attribute name="text:style-name">
+            <ref name="styleName"/>
+        </attribute>
+        <empty/>
+    </element>
+</define>
+<define name="text-index-title-template">
+    <element name="text:index-title-template">
+        <optional>
+            <attribute name="text:style-name">
+                <ref name="styleNameRef"/>
+            </attribute>
+        </optional>
+        <text/>
+    </element>
+</define>
+<define name="text-index-entry-chapter">
+    <element name="text:index-entry-chapter">
+        <optional>
+            <attribute name="text:style-name">
+                <ref name="styleNameRef"/>
+            </attribute>
+        </optional>
+        <ref name="text-index-entry-chapter-attrs"/>
+    </element>
+</define>
+<define name="text-index-entry-chapter-attrs">
+    <optional>
+        <attribute name="text:display" a:defaultValue="number">
+            <choice>
+                <value>name</value>
+                <value>number</value>
+                <value>number-and-name</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="text-index-entry-text">
+    <element name="text:index-entry-text">
+        <optional>
+            <attribute name="text:style-name">
+                <ref name="styleNameRef"/>
+            </attribute>
+        </optional>
+    </element>
+</define>
+<define name="text-index-entry-page-number">
+    <element name="text:index-entry-page-number">
+        <optional>
+            <attribute name="text:style-name">
+                <ref name="styleNameRef"/>
+            </attribute>
+        </optional>
+    </element>
+</define>
+<define name="text-index-entry-span">
+    <element name="text:index-entry-span">
+        <optional>
+            <attribute name="text:style-name">
+                <ref name="styleNameRef"/>
+            </attribute>
+        </optional>
+        <text/>
+    </element>
+</define>
+<define name="text-index-entry-bibliography">
+    <element name="text:index-entry-bibliography">
+        <ref name="text-index-entry-bibliography-attrs"/>
+    </element>
+</define>
+<define name="text-index-entry-bibliography-attrs" combine="interleave">
+    <optional>
+        <attribute name="text:style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-index-entry-bibliography-attrs" combine="interleave">
+    <attribute name="text:bibliography-data-field">
+        <choice>
+            <value>address</value>
+            <value>annote</value>
+            <value>author</value>
+            <value>bibliography-type</value>
+            <value>booktitle</value>
+            <value>chapter</value>
+            <value>custom1</value>
+            <value>custom2</value>
+            <value>custom3</value>
+            <value>custom4</value>
+            <value>custom5</value>
+            <value>edition</value>
+            <value>editor</value>
+            <value>howpublished</value>
+            <value>identifier</value>
+            <value>institution</value>
+            <value>isbn</value>
+            <value>issn</value>
+            <value>journal</value>
+            <value>month</value>
+            <value>note</value>
+            <value>number</value>
+            <value>organizations</value>
+            <value>pages</value>
+            <value>publisher</value>
+            <value>report-type</value>
+            <value>school</value>
+            <value>series</value>
+            <value>title</value>
+            <value>url</value>
+            <value>volume</value>
+            <value>year</value>
+        </choice>
+    </attribute>
+</define>
+<define name="text-index-entry-tab-stop">
+    <element name="text:index-entry-tab-stop">
+        <optional>
+            <attribute name="text:style-name">
+                <ref name="styleNameRef"/>
+            </attribute>
+        </optional>
+        <ref name="text-index-entry-tab-stop-attrs"/>
+    </element>
+</define>
+<define name="text-index-entry-tab-stop-attrs" combine="interleave">
+    <optional>
+        <attribute name="style:leader-char">
+            <ref name="character"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-index-entry-tab-stop-attrs" combine="interleave">
+    <choice>
+        <attribute name="style:type">
+            <value>right</value>
+        </attribute>
+        <group>
+            <attribute name="style:type">
+                <value>left</value>
+            </attribute>
+            <attribute name="style:position">
+                <ref name="length"/>
+            </attribute>
+        </group>
+    </choice>
+</define>
+<define name="text-index-entry-link-start">
+    <element name="text:index-entry-link-start">
+        <optional>
+            <attribute name="text:style-name">
+                <ref name="styleNameRef"/>
+            </attribute>
+        </optional>
+    </element>
+</define>
+<define name="text-index-entry-link-end">
+    <element name="text:index-entry-link-end">
+        <optional>
+            <attribute name="text:style-name">
+                <ref name="styleNameRef"/>
+            </attribute>
+        </optional>
+    </element>
+</define>
+<define name="table-table">
+    <element name="table:table">
+        <ref name="table-table-attlist"/>
+        <optional>
+            <ref name="table-table-source"/>
+        </optional>
+        <optional>
+            <ref name="office-dde-source"/>
+        </optional>
+        <optional>
+            <ref name="table-scenario"/>
+        </optional>
+        <optional>
+            <ref name="office-forms"/>
+        </optional>
+        <optional>
+            <ref name="table-shapes"/>
+        </optional>
+        <ref name="table-columns-and-groups"/>
+        <ref name="table-rows-and-groups"/>
+    </element>
+</define>
+<define name="table-columns-and-groups">
+    <oneOrMore>
+        <choice>
+            <ref name="table-table-column-group"/>
+            <ref name="table-columns-no-group"/>
+        </choice>
+    </oneOrMore>
+</define>
+
+<define name="table-columns-no-group">
+    <choice>
+        <group>
+            <ref name="table-columns"/>
+            <optional>
+                <ref name="table-table-header-columns"/>
+                <optional>
+                    <ref name="table-columns"/>
+                </optional>
+            </optional>
+        </group>
+        <group>
+            <ref name="table-table-header-columns"/>
+            <optional>
+                <ref name="table-columns"/>
+            </optional>
+        </group>
+    </choice>
+</define>
+
+<define name="table-columns">
+    <choice>
+        <ref name="table-table-columns"/>
+        <oneOrMore>
+                <ref name="table-table-column"/>
+        </oneOrMore>
+    </choice>
+</define>
+
+<define name="table-rows-and-groups">
+    <oneOrMore>
+        <choice>
+            <ref name="table-table-row-group"/>
+            <ref name="table-rows-no-group"/>
+        </choice>
+    </oneOrMore>
+</define>
+
+<define name="table-rows-no-group">
+    <choice>
+        <group>
+            <ref name="table-rows"/>
+            <optional>
+                <ref name="table-table-header-rows"/>
+                <optional>
+                    <ref name="table-rows"/>
+                </optional>
+            </optional>
+        </group>
+        <group>
+            <ref name="table-table-header-rows"/>
+            <optional>
+                <ref name="table-rows"/>
+            </optional>
+        </group>
+    </choice>
+</define>
+
+<define name="table-rows">
+    <choice>
+        <ref name="table-table-rows"/>
+        <oneOrMore>
+            <optional>
+                <ref name="text-soft-page-break"/>
+            </optional>
+            <ref name="table-table-row"/>
+        </oneOrMore>
+    </choice>
+</define>
+<define name="table-table-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-table-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-table-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:protected" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="table:protection-key">
+            <text/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-table-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:print" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-table-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:print-ranges">
+            <ref name="cellRangeAddressList"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-table-row">
+    <element name="table:table-row">
+        <ref name="table-table-row-attlist"/>
+        <oneOrMore>
+            <choice>
+                <ref name="table-table-cell"/>
+                <ref name="table-covered-table-cell"/>
+            </choice>
+        </oneOrMore>
+    </element>
+</define>
+<define name="table-table-row-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:number-rows-repeated" a:defaultValue="1">
+            <ref name="positiveInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-table-row-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-table-row-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:default-cell-style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-table-row-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:visibility" a:defaultValue="visible">
+            <ref name="table-visibility-value"/>
+        </attribute>
+    </optional>
+</define>
+
+<define name="table-visibility-value">
+    <choice>
+        <value>visible</value>
+        <value>collapse</value>
+        <value>filter</value>
+    </choice>
+</define>
+<define name="table-table-cell">
+    <element name="table:table-cell">
+        <ref name="table-table-cell-attlist"/>
+        <ref name="table-table-cell-attlist-extra"/>
+        <ref name="table-table-cell-content"/>
+    </element>
+</define>
+
+<define name="table-covered-table-cell">
+    <element name="table:covered-table-cell">
+        <ref name="table-table-cell-attlist"/>
+        <ref name="table-table-cell-content"/>
+    </element>
+</define>
+
+<define name="table-table-cell-content">
+    <optional>
+        <ref name="table-cell-range-source"/>
+    </optional>
+    <optional>
+        <ref name="office-annotation"/>
+    </optional>
+    <optional>
+        <ref name="table-detective"/>
+    </optional>
+    <zeroOrMore>
+        <ref name="text-content"/>
+    </zeroOrMore>
+</define>
+<define name="table-table-cell-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:number-columns-repeated" a:defaultValue="1">
+            <ref name="positiveInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-table-cell-attlist-extra" combine="interleave">
+    <optional>
+        <attribute name="table:number-columns-spanned" a:defaultValue="1">
+            <ref name="positiveInteger"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="table:number-rows-spanned" a:defaultValue="1">
+            <ref name="positiveInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-table-cell-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-table-cell-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:content-validation-name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-table-cell-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:formula">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-table-cell-attlist-extra" combine="interleave">
+    <optional>
+        <attribute name="table:number-matrix-columns-spanned">
+            <ref name="positiveInteger"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="table:number-matrix-rows-spanned">
+            <ref name="positiveInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-table-cell-attlist" combine="interleave">
+    <optional>
+        <ref name="common-value-and-type-attlist"/>
+    </optional>
+</define>
+<define name="table-table-cell-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:protect" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-table-column">
+    <element name="table:table-column">
+        <ref name="table-table-column-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="table-table-column-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:number-columns-repeated" a:defaultValue="1">
+            <ref name="positiveInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-table-column-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-table-column-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:visibility" a:defaultValue="visible">
+            <ref name="table-visibility-value"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-table-column-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:default-cell-style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-table-header-columns">
+    <element name="table:table-header-columns">
+        <oneOrMore>
+            <ref name="table-table-column"/>
+        </oneOrMore>
+    </element>
+</define>
+
+<define name="table-table-columns">
+    <element name="table:table-columns">
+        <oneOrMore>
+            <ref name="table-table-column"/>
+        </oneOrMore>
+    </element>
+</define>
+<define name="table-table-column-group">
+    <element name="table:table-column-group">
+        <ref name="table-table-column-group-attlist"/>
+        <ref name="table-columns-and-groups"/>
+    </element>
+</define>
+<define name="table-table-column-group-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:display" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-table-header-rows">
+    <element name="table:table-header-rows">
+        <oneOrMore>
+            <optional>
+                <ref name="text-soft-page-break"/>
+            </optional>
+            <ref name="table-table-row"/>
+        </oneOrMore>
+    </element>
+</define>
+
+<define name="table-table-rows">
+    <element name="table:table-rows">
+        <oneOrMore>
+            <optional>
+                <ref name="text-soft-page-break"/>
+            </optional>
+            <ref name="table-table-row"/>
+        </oneOrMore>
+    </element>
+</define>
+<define name="table-table-row-group">
+    <element name="table:table-row-group">
+        <ref name="table-table-row-group-attlist"/>
+        <ref name="table-rows-and-groups"/>
+    </element>
+</define>
+<define name="table-table-row-group-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:display" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-table-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:is-sub-table" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="cellAddress">
+    <data type="string">
+        <param name="pattern">($?([^\. ']+|'([^']|'')+'))?\.$?[A-Z]+$?[0-9]+</param>
+
+    </data>
+</define>
+<define name="cellRangeAddress">
+    <data type="string">
+        <param name="pattern">($?([^\. ']+|'([^']|'')+'))?\.$?[A-Z]+$?[0-9]+(:($?([^\. ']+|'([^']|'')+'))?\.$?[A-Z]+$?[0-9]+)?</param>
+
+    </data>
+</define>
+<define name="cellRangeAddressList">
+    <!-- Value is a space separated list of "cellRangeAddress" patterns -->
+    <data type="string"/> 
+</define>
+<define name="table-table-source">
+    <element name="table:table-source">
+        <ref name="table-table-source-attlist"/>
+        <ref name="table-linked-source-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="table-table-source-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:mode" a:defaultValue="copy-all">
+            <choice>
+                <value>copy-all</value>
+                <value>copy-results-only</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="table-table-source-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:table-name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-linked-source-attlist" combine="interleave">
+    <optional>
+        <attribute name="xlink:type" a:defaultValue="simple">
+            <value>simple</value>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="xlink:actuate" a:defaultValue="onRequest">
+            <value>onRequest</value>
+        </attribute>
+    </optional>
+    <attribute name="xlink:href">
+        <ref name="anyURI"/>
+    </attribute>
+</define>
+<define name="table-linked-source-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:filter-name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-linked-source-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:filter-options">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-linked-source-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:refresh-delay">
+            <ref name="duration"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-scenario">
+    <element name="table:scenario">
+        <ref name="table-scenario-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="table-scenario-attlist" combine="interleave">
+    <attribute name="table:scenario-ranges">
+        <ref name="cellRangeAddressList"/>
+    </attribute>
+</define>
+<define name="table-scenario-attlist" combine="interleave">
+    <attribute name="table:is-active">
+        <ref name="boolean"/>
+    </attribute>
+</define>
+<define name="table-scenario-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:display-border" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-scenario-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:border-color">
+            <ref name="color"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-scenario-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:copy-back" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-scenario-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:copy-styles" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-scenario-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:copy-formulas" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-scenario-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:comment">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-scenario-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:protected">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-shapes">
+    <element name="table:shapes">
+        <oneOrMore>
+            <ref name="shape"/>
+        </oneOrMore>
+    </element>
+</define>
+<define name="table-cell-range-source">
+    <element name="table:cell-range-source">
+        <ref name="table-table-cell-range-source-attlist"/>
+        <ref name="table-linked-source-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="table-table-cell-range-source-attlist" combine="interleave">
+    <attribute name="table:name">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="table-table-cell-range-source-attlist" combine="interleave">
+    <attribute name="table:last-column-spanned">
+        <ref name="positiveInteger"/>
+    </attribute>
+    <attribute name="table:last-row-spanned">
+        <ref name="positiveInteger"/>
+    </attribute>
+</define>
+<define name="table-detective">
+    <element name="table:detective">
+        <zeroOrMore>
+            <ref name="table-highlighted-range"/>
+        </zeroOrMore>
+        <zeroOrMore>
+            <ref name="table-operation"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="table-operation">
+    <element name="table:operation">
+        <ref name="table-operation-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="table-operation-attlist" combine="interleave">
+    <attribute name="table:name">
+        <choice>
+            <value>trace-dependents</value>
+            <value>remove-dependents</value>
+            <value>trace-precedents</value>
+            <value>remove-precedents</value>
+            <value>trace-errors</value>
+        </choice>
+    </attribute>
+</define>
+<define name="table-operation-attlist" combine="interleave">
+    <attribute name="table:index">
+        <ref name="nonNegativeInteger"/>
+    </attribute>
+</define>
+<define name="table-highlighted-range">
+    <element name="table:highlighted-range">
+        <choice>
+            <group>
+                <ref name="table-highlighted-range-attlist"/>
+            </group>
+            <group>
+                <ref name="table-highlighted-range-attlist-invalid"/>
+            </group>
+        </choice>
+        <empty/>
+    </element>
+</define>
+<define name="table-highlighted-range-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:cell-range-address">
+            <ref name="cellRangeAddress"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-highlighted-range-attlist" combine="interleave">
+    <attribute name="table:direction">
+        <choice>
+            <value>from-another-table</value>
+            <value>to-another-table</value>
+            <value>from-same-table</value>
+        </choice>
+    </attribute>
+</define>
+<define name="table-highlighted-range-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:contains-error" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-highlighted-range-attlist-invalid" combine="interleave">
+    <attribute name="table:marked-invalid">
+        <ref name="boolean"/>
+    </attribute>
+</define>
+<define name="office-spreadsheet-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:structure-protected" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="table:protection-key">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-calculation-settings">
+    <element name="table:calculation-settings">
+        <ref name="table-calculation-setting-attlist"/>
+        <optional>
+            <ref name="table-null-date"/>
+        </optional>
+        <optional>
+            <ref name="table-iteration"/>
+        </optional>
+    </element>
+</define>
+<define name="table-calculation-setting-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:case-sensitive" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-calculation-setting-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:precision-as-shown" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-calculation-setting-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:search-criteria-must-apply-to-whole-cell"
+                     a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-calculation-setting-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:automatic-find-labels" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-calculation-setting-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:use-regular-expressions"
+                     a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-calculation-setting-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:null-year" a:defaultValue="1930">
+            <ref name="positiveInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-null-date">
+    <element name="table:null-date">
+        <optional>
+            <attribute name="table:value-type" a:defaultValue="date">
+                <ref name="valueType"/>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="table:date-value"
+                         a:defaultValue="1899-12-30">
+                <ref name="date"/>
+            </attribute>
+        </optional>
+        <empty/>
+    </element>
+</define>
+<define name="table-iteration">
+    <element name="table:iteration">
+        <optional>
+            <attribute name="table:status" a:defaultValue="disable">
+                <choice>
+                    <value>enable</value>
+                    <value>disable</value>
+                </choice>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="table:steps" a:defaultValue="100">
+                <ref name="positiveInteger"/>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="table:maximum-difference"
+                         a:defaultValue="0.001">
+                <ref name="double"/>
+            </attribute>
+        </optional>
+        <empty/>
+    </element>
+</define>
+<define name="table-content-validations">
+    <element name="table:content-validations">
+        <oneOrMore>
+            <ref name="table-content-validation"/>
+        </oneOrMore>
+    </element>
+</define>
+
+<define name="table-content-validation">
+    <element name="table:content-validation">
+        <ref name="table-validation-attlist"/>
+        <optional>
+            <ref name="table-help-message"/>
+        </optional>
+        <optional>
+            <choice>
+                <ref name="table-error-message"/>
+                <group>
+                    <ref name="table-error-macro"/>
+                    <optional>
+                        <ref name="office-event-listeners"/>
+                    </optional>
+                </group>
+            </choice>
+        </optional>
+    </element>
+</define>
+<define name="table-validation-attlist" combine="interleave">
+    <attribute name="table:name">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="table-validation-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:condition">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-validation-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:base-cell-address">
+            <ref name="cellAddress"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-validation-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:allow-empty-cell" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-validation-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:display-list" a:defaultValue="unsorted">
+            <choice>
+                <value>none</value>
+                <value>unsorted</value>
+                <value>sort-ascending</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="table-help-message">
+    <element name="table:help-message">
+        <optional>
+            <attribute name="table:title">
+                <ref name="string"/>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="table:display" a:defaultValue="false">
+                <ref name="boolean"/>
+            </attribute>
+        </optional>
+        <zeroOrMore>
+            <ref name="text-p"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="table-error-message">
+    <element name="table:error-message">
+        <optional>
+            <attribute name="table:title">
+                <ref name="string"/>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="table:display" a:defaultValue="false">
+                <ref name="boolean"/>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="table:message-type" a:defaultValue="stop">
+                <choice>
+                    <value>stop</value>
+                    <value>warning</value>
+                    <value>information</value>
+                </choice>
+            </attribute>
+        </optional>
+        <zeroOrMore>
+            <ref name="text-p"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="table-error-macro">
+    <element name="table:error-macro">
+        <optional>
+            <attribute name="table:execute" a:defaultValue="true">
+                <ref name="boolean"/>
+            </attribute>
+        </optional>
+    </element>
+</define>
+<define name="table-label-ranges">
+    <element name="table:label-ranges">
+        <zeroOrMore>
+            <ref name="table-label-range"/>
+        </zeroOrMore>
+    </element>
+</define>
+
+<define name="table-label-range">
+    <element name="table:label-range">
+        <ref name="table-label-range-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="table-label-range-attlist" combine="interleave">
+    <attribute name="table:label-cell-range-address">
+        <ref name="cellRangeAddress"/>
+    </attribute>
+</define>
+<define name="table-label-range-attlist" combine="interleave">
+    <attribute name="table:data-cell-range-address">
+        <ref name="cellRangeAddress"/>
+    </attribute>
+</define>
+<define name="table-label-range-attlist" combine="interleave">
+    <attribute name="table:orientation">
+        <choice>
+            <value>column</value>
+            <value>row</value>
+        </choice>
+    </attribute>
+</define>
+<define name="table-named-expressions">
+    <element name="table:named-expressions">
+        <zeroOrMore>
+            <choice>
+                <ref name="table-named-range"/>
+                <ref name="table-named-expression"/>
+            </choice>
+        </zeroOrMore>
+    </element>
+</define>
+
+<define name="table-named-range">
+    <element name="table:named-range">
+        <ref name="table-named-range-attlist"/>
+        <empty/>
+    </element>
+</define>
+
+<define name="table-named-range-attlist" combine="interleave">
+    <attribute name="table:name">
+        <ref name="string"/>
+    </attribute>
+    <attribute name="table:cell-range-address">
+        <ref name="cellRangeAddress"/>
+    </attribute>
+    <optional>
+        <attribute name="table:base-cell-address">
+            <ref name="cellAddress"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="table:range-usable-as" a:defaultValue="none">
+            <choice>
+                <value>none</value>
+                <list>
+                    <oneOrMore>
+                        <choice>
+                            <value>print-range</value>
+                            <value>filter</value>
+                            <value>repeat-row</value>
+                            <value>repeat-column</value>
+                        </choice>
+                    </oneOrMore>
+                </list>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="table-named-expression">
+    <element name="table:named-expression">
+        <ref name="table-named-expression-attlist"/>
+        <empty/>
+    </element>
+</define>
+
+<define name="table-named-expression-attlist" combine="interleave">
+    <attribute name="table:name">
+        <ref name="string"/>
+    </attribute>
+    <attribute name="table:expression">
+        <ref name="string"/>
+    </attribute>
+    <optional>
+        <attribute name="table:base-cell-address">
+            <ref name="cellAddress"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-database-ranges">
+    <element name="table:database-ranges">
+        <zeroOrMore>
+            <ref name="table-database-range"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="table-database-range">
+    <element name="table:database-range">
+        <ref name="table-database-range-attlist"/>
+        <optional>
+            <choice>
+                <ref name="table-database-source-sql"/>
+                <ref name="table-database-source-table"/>
+                <ref name="table-database-source-query"/>
+            </choice>
+        </optional>
+        <optional>
+            <ref name="table-filter"/>
+        </optional>
+        <optional>
+            <ref name="table-sort"/>
+        </optional>
+        <optional>
+            <ref name="table-subtotal-rules"/>
+        </optional>
+    </element>
+</define>
+<define name="table-database-range-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-database-range-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:is-selection" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-database-range-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:on-update-keep-styles" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-database-range-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:on-update-keep-size" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-database-range-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:has-persistent-data" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-database-range-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:orientation" a:defaultValue="row">
+            <choice>
+                <value>column</value>
+                <value>row</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="table-database-range-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:contains-header" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-database-range-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:display-filter-buttons"
+                   a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-database-range-attlist" combine="interleave">
+    <attribute name="table:target-range-address">
+        <ref name="cellRangeAddress"/>
+    </attribute>
+</define>
+<define name="table-database-range-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:refresh-delay">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-database-source-sql">
+    <element name="table:database-source-sql">
+        <ref name="table-database-source-sql-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="table-database-source-sql-attlist" combine="interleave">
+    <attribute name="table:database-name">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="table-database-source-sql-attlist" combine="interleave">
+    <attribute name="table:sql-statement">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="table-database-source-sql-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:parse-sql-statement" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-database-source-query">
+    <element name="table:database-source-table">
+        <ref name="table-database-source-table-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="table-database-source-table-attlist" combine="interleave">
+    <attribute name="table:database-name">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="table-database-source-table-attlist" combine="interleave">
+    <attribute name="table:database-table-name">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="table-database-source-table">
+    <element name="table:database-source-query">
+        <ref name="table-database-source-query-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="table-database-source-query-attlist" combine="interleave">
+    <attribute name="table:database-name">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="table-database-source-query-attlist" combine="interleave">
+    <attribute name="table:query-name">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="table-sort">
+    <element name="table:sort">
+        <ref name="table-sort-attlist"/>
+        <oneOrMore>
+            <ref name="table-sort-by"/>
+        </oneOrMore>
+    </element>
+</define>
+<define name="table-sort-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:bind-styles-to-content" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-sort-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:target-range-address">
+            <ref name="cellRangeAddress"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-sort-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:case-sensitive" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-sort-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:language">
+            <ref name="languageCode"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-sort-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:country">
+            <ref name="countryCode"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-sort-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:algorithm">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-sort-by">
+    <element name="table:sort-by">
+        <ref name="table-sort-by-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="table-sort-by-attlist" combine="interleave">
+    <attribute name="table:field-number">
+        <ref name="nonNegativeInteger"/>
+    </attribute>
+</define>
+<define name="table-sort-by-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:data-type" a:defaultValue="automatic">
+            <choice>
+                <value>text</value>
+                <value>number</value>
+                <value>automatic</value>
+                <ref name="string"/>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="table-sort-by-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:order" a:defaultValue="ascending">
+            <choice>
+                <value>ascending</value>
+                <value>descending</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="table-subtotal-rules">
+    <element name="table:subtotal-rules">
+        <ref name="table-subtotal-rules-attlist"/>
+        <optional>
+            <ref name="table-sort-groups"/>
+        </optional>
+        <zeroOrMore>
+            <ref name="table-subtotal-rule"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="table-subtotal-rules-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:bind-styles-to-content" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-subtotal-rules-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:case-sensitive" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-subtotal-rules-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:page-breaks-on-group-change"
+                   a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-sort-groups">
+    <element name="table:sort-groups">
+        <ref name="table-sort-groups-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="table-sort-groups-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:data-type" a:defaultValue="automatic">
+            <choice>
+                <value>text</value>
+                <value>number</value>
+                <value>automatic</value>
+                <ref name="string"/>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="table-sort-groups-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:order" a:defaultValue="ascending">
+            <choice>
+                <value>ascending</value>
+                <value>descending</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="table-subtotal-rule">
+    <element name="table:subtotal-rule">
+        <ref name="table-subtotal-rule-attlist"/>
+        <zeroOrMore>
+            <ref name="table-subtotal-field"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="table-subtotal-rule-attlist" combine="interleave">
+    <attribute name="table:group-by-field-number">
+        <ref name="nonNegativeInteger"/>
+    </attribute>
+</define>
+<define name="table-subtotal-field">
+    <element name="table:subtotal-field">
+        <ref name="table-subtotal-field-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="table-subtotal-field-attlist" combine="interleave">
+    <attribute name="table:field-number">
+        <ref name="nonNegativeInteger"/>
+    </attribute>
+</define>
+<define name="table-subtotal-field-attlist" combine="interleave">
+    <attribute name="table:function">
+        <choice>
+            <value>auto</value>
+            <value>average</value>
+            <value>count</value>
+            <value>countnums</value>
+            <value>max</value>
+            <value>min</value>
+            <value>product</value>
+            <value>stdev</value>
+            <value>stdevp</value>
+            <value>sum</value>
+            <value>var</value>
+            <value>varp</value>
+            <ref name="string"/>
+        </choice>
+    </attribute>
+</define>
+<define name="table-filter">
+    <element name="table:filter">
+        <ref name="table-filter-attlist"/>
+        <choice>
+            <ref name="table-filter-condition"/>
+            <ref name="table-filter-and"/>
+            <ref name="table-filter-or"/>
+        </choice>
+    </element>
+</define>
+<define name="table-filter-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:target-range-address">
+            <ref name="cellRangeAddress"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-filter-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:condition-source" a:defaultValue="self">
+            <choice>
+                <value>self</value>
+                <value>cell-range</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="table-filter-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:condition-source-range-address">
+            <ref name="cellRangeAddress"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-filter-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:display-duplicates" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-filter-and">
+    <element name="table:filter-and">
+        <oneOrMore>
+            <choice>
+                <ref name="table-filter-or"/>
+                <ref name="table-filter-condition"/>
+            </choice>
+        </oneOrMore>
+    </element>
+</define>
+<define name="table-filter-or">
+    <element name="table:filter-or">
+        <oneOrMore>
+            <choice>
+                <ref name="table-filter-and"/>
+                <ref name="table-filter-condition"/>
+            </choice>
+        </oneOrMore>
+    </element>
+</define>
+<define name="table-filter-condition">
+    <element name="table:filter-condition">
+        <ref name="table-filter-condition-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="table-filter-condition-attlist" combine="interleave">
+    <attribute name="table:field-number">    
+        <ref name="nonNegativeInteger"/>
+    </attribute>
+</define>
+<define name="table-filter-condition-attlist" combine="interleave">
+    <attribute name="table:value">    
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="table-filter-condition-attlist" combine="interleave">
+    <attribute name="table:operator">    
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="table-filter-condition-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:case-sensitive" a:defaultValue="false">    
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-filter-condition-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:data-type" a:defaultValue="text">
+            <choice>
+                <value>text</value>
+                <value>number</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="table-data-pilot-tables">
+    <element name="table:data-pilot-tables">
+        <zeroOrMore>
+            <ref name="table-data-pilot-table"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="table-data-pilot-table">
+    <element name="table:data-pilot-table">
+        <ref name="table-data-pilot-table-attlist"/>
+        <optional>
+            <choice>
+                <ref name="table-database-source-sql"/>
+                <ref name="table-database-source-table"/>
+                <ref name="table-database-source-query"/>
+                <ref name="table-source-service"/>
+                <ref name="table-source-cell-range"/>
+            </choice>
+        </optional>
+        <oneOrMore>
+            <ref name="table-data-pilot-field"/>
+        </oneOrMore>
+    </element>
+</define>
+<define name="table-data-pilot-table-attlist" combine="interleave">
+    <attribute name="table:name">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="table-data-pilot-table-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:application-data">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-data-pilot-table-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:grand-total" a:defaultValue="both">
+            <choice>
+                <value>none</value>
+                <value>row</value>
+                <value>column</value>
+                <value>both</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="table-data-pilot-table-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:ignore-empty-rows" a:defaultValue="false">    
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-data-pilot-table-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:identify-categories" a:defaultValue="false">    
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-data-pilot-table-attlist" combine="interleave">
+    <attribute name="table:target-range-address">    
+        <ref name="cellRangeAddress"/>
+    </attribute>
+</define>
+<define name="table-data-pilot-table-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:buttons">    
+            <ref name="cellRangeAddressList"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-data-pilot-table-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:show-filter-button" a:defaultValue="true">    
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-data-pilot-table-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:drill-down-on-double-click"
+                   a:defaultValue="true">    
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-source-cell-range">
+    <element name="table:source-cell-range">
+        <ref name="table-source-cell-range-attlist"/>
+        <optional>
+            <ref name="table-filter"/>
+        </optional>
+    </element>
+</define>
+<define name="table-source-cell-range-attlist" combine="interleave">
+    <attribute name="table:cell-range-address">    
+        <ref name="cellRangeAddress"/>
+    </attribute>
+</define>
+<define name="table-source-service">
+    <element name="table:source-service">
+        <ref name="table-source-service-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="table-source-service-attlist" combine="interleave">
+    <attribute name="table:name">    
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="table-source-service-attlist" combine="interleave">
+    <attribute name="table:source-name">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="table-source-service-attlist" combine="interleave">
+    <attribute name="table:object-name">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="table-source-service-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:user-name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-source-service-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:password">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-data-pilot-field">
+    <element name="table:data-pilot-field">
+        <ref name="table-data-pilot-field-attlist"/>
+        <optional>
+            <ref name="table-data-pilot-level"/>
+        </optional>
+        <optional>
+            <ref name="table-data-pilot-field-reference"/>
+        </optional>
+        <optional>
+            <ref name="table-data-pilot-groups"/>
+        </optional>
+    </element>
+</define>
+<define name="table-data-pilot-field-attlist" combine="interleave">
+    <attribute name="table:source-field-name">    
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="table-data-pilot-field-attlist" combine="interleave">
+    <choice>
+        <attribute name="table:orientation">    
+            <choice>
+                <value>row</value>
+                <value>column</value>
+                <value>data</value>
+                <value>hidden</value>
+            </choice>
+        </attribute>
+        <group>
+            <attribute name="table:orientation">
+                <value>page</value>
+            </attribute>
+            <attribute name="table:selected-page">
+                <ref name="string"/>
+            </attribute>
+        </group>
+    </choice>
+</define>
+<define name="table-data-pilot-field-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:is-data-layout-field" a:defaultValue="false">    
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-data-pilot-field-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:function">
+            <choice>
+                <value>auto</value>
+                <value>average</value>
+                <value>count</value>
+                <value>countnums</value>
+                <value>max</value>
+                <value>min</value>
+                <value>product</value>
+                <value>stdev</value>
+                <value>stdevp</value>
+                <value>sum</value>
+                <value>var</value>
+                <value>varp</value>
+                <ref name="string"/>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="table-data-pilot-field-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:used-hierarchy" a:defaultValue="-1">    
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-data-pilot-level">
+    <element name="table:data-pilot-level">
+        <ref name="table-data-pilot-level-attlist"/>
+        <optional>
+            <ref name="table-data-pilot-subtotals"/>
+        </optional>
+        <optional>
+            <ref name="table-data-pilot-members"/>
+        </optional>
+        <optional>
+            <ref name="table-data-pilot-display-info"/>
+        </optional>
+        <optional>
+            <ref name="table-data-pilot-sort-info"/>
+        </optional>
+        <optional>
+            <ref name="table-data-pilot-layout-info"/>
+        </optional>
+    </element>
+</define>
+<define name="table-data-pilot-level-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:show-empty">    
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-data-pilot-subtotals">
+    <element name="table:data-pilot-subtotals">
+        <zeroOrMore>
+            <ref name="table-data-pilot-subtotal"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="table-data-pilot-subtotal">
+    <element name="table:data-pilot-subtotal">
+        <ref name="table-data-pilot-subtotal-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="table-data-pilot-subtotal-attlist" combine="interleave">
+    <attribute name="table:function">
+        <choice>
+            <value>auto</value>
+            <value>average</value>
+            <value>count</value>
+            <value>countnums</value>
+            <value>max</value>
+            <value>min</value>
+            <value>product</value>
+            <value>stdev</value>
+            <value>stdevp</value>
+            <value>sum</value>
+            <value>var</value>
+            <value>varp</value>
+            <ref name="string"/>
+        </choice>
+    </attribute>
+</define>
+<define name="table-data-pilot-members">
+    <element name="table:data-pilot-members">
+        <zeroOrMore>
+            <ref name="table-data-pilot-member"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="table-data-pilot-member">
+    <element name="table:data-pilot-member">
+        <ref name="table-data-pilot-member-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="table-data-pilot-member-attlist" combine="interleave">
+    <attribute name="table:name">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="table-data-pilot-member-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:display">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-data-pilot-member-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:show-details">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-data-pilot-display-info">
+    <element name="table:data-pilot-display-info">
+        <ref name="table-data-pilot-display-info-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="table-data-pilot-display-info-attlist" combine="interleave">
+    <attribute name="table:enabled">
+        <ref name="boolean"/>
+    </attribute>
+</define>
+<define name="table-data-pilot-display-info-attlist" combine="interleave">
+    <attribute name="table:data-field">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="table-data-pilot-display-info-attlist" combine="interleave">
+    <attribute name="table:member-count">
+        <ref name="nonNegativeInteger"/>
+    </attribute>
+</define>
+<define name="table-data-pilot-display-info-attlist" combine="interleave">
+    <attribute name="table:display-member-mode">
+        <choice>
+            <value>from-top</value>
+            <value>from-bottom</value>
+        </choice>
+    </attribute>
+</define>
+<define name="table-data-pilot-sort-info">
+    <element name="table:data-pilot-sort-info">
+        <ref name="table-data-pilot-sort-info-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="table-data-pilot-sort-info-attlist" combine="interleave">
+    <choice>
+        <group>
+            <attribute name="table:sort-mode">
+                <value>data</value>
+            </attribute>
+            <attribute name="table:data-field">
+                <ref name="string"/>
+            </attribute>
+        </group>
+        <attribute name="table:sort-mode">
+            <choice>
+                <value>none</value>
+                <value>manual</value>
+                <value>name</value>
+            </choice>
+        </attribute>
+    </choice>
+</define>
+<define name="table-data-pilot-sort-info-attlist" combine="interleave">
+    <attribute name="table:order">
+        <choice>
+            <value>ascending</value>
+            <value>descending</value>
+        </choice>
+    </attribute>
+</define>
+<define name="table-data-pilot-layout-info">
+    <element name="table:data-pilot-layout-info">
+        <ref name="table-data-pilot-layout-info-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="table-data-pilot-layout-info-attlist" combine="interleave">
+    <attribute name="table:layout-mode">
+        <choice>
+            <value>tabular-layout</value>
+            <value>outline-subtotals-top</value>
+            <value>outline-subtotals-bottom</value>
+        </choice>
+    </attribute>
+</define>
+<define name="table-data-pilot-layout-info-attlist" combine="interleave">
+    <attribute name="table:add-empty-lines">
+        <ref name="boolean"/>
+    </attribute>
+</define>
+<define name="table-data-pilot-field-reference">
+    <element name="table:data-pilot-field-reference">
+        <ref name="table-data-pilot-field-reference-attlist"/>
+    </element>
+</define>
+<define name="table-data-pilot-field-reference-attlist" combine="interleave">
+    <attribute name="table:field-name">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="table-data-pilot-field-reference-attlist" combine="interleave">
+    <choice>
+        <group>
+            <attribute name="table:member-type">
+                <value>named</value>
+            </attribute>
+            <attribute name="table:member-name">
+                <ref name="string"/>
+            </attribute>
+        </group>
+        <attribute name="table:member-type">
+            <choice>
+                <value>previous</value>
+                <value>next</value>
+            </choice>
+        </attribute>
+    </choice>
+</define>
+<define name="table-data-pilot-field-reference-attlist" combine="interleave">
+    <attribute name="table:type">
+        <choice>
+            <value>none</value>
+            <value>member-difference</value>
+            <value>member-percentage</value>
+            <value>member-percentage-difference</value>
+            <value>running-total</value>
+            <value>row-percentage</value>
+            <value>column-percentage</value>
+            <value>total-percentage</value>
+            <value>index</value>
+        </choice>
+    </attribute>
+</define>
+<define name="table-data-pilot-groups">
+    <element name="table:data-pilot-groups">
+        <ref name="table-data-pilot-groups-attlist"/>
+        <oneOrMore>
+            <ref name="table-data-pilot-group"/>
+        </oneOrMore>
+    </element>
+</define>
+<define name="table-data-pilot-groups-attlist" combine="interleave">
+    <attribute name="table:source-field-name">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="table-data-pilot-groups-attlist" combine="interleave">
+    <choice>
+        <attribute name="table:date-start">
+            <choice>
+                <ref name="dateOrDateTime"/>
+                <value>auto</value>
+            </choice>
+        </attribute>
+        <attribute name="table:start">
+            <choice>
+                <ref name="double"/>
+                <value>auto</value>
+            </choice>
+        </attribute>
+    </choice>
+</define>
+<define name="table-data-pilot-groups-attlist" combine="interleave">
+    <choice>
+        <attribute name="table:date-end">
+            <choice>
+                <ref name="dateOrDateTime"/>
+                <value>auto</value>
+            </choice>
+        </attribute>
+        <attribute name="table:end">
+            <choice>
+                <ref name="double"/>
+                <value>auto</value>
+            </choice>
+        </attribute>
+    </choice>
+</define>
+<define name="table-data-pilot-groups-attlist" combine="interleave">
+    <attribute name="table:step">
+        <ref name="double"/>
+    </attribute>
+</define>
+<define name="table-data-pilot-groups-attlist" combine="interleave">
+    <attribute name="table:grouped-by">
+        <choice>
+            <value>seconds</value>
+            <value>minutes</value>
+            <value>hours</value>
+            <value>days</value>
+            <value>months</value>
+            <value>quarters</value>
+            <value>years</value>
+        </choice>
+    </attribute>
+</define>
+<define name="table-data-pilot-group">
+    <element name="table:data-pilot-group">
+        <ref name="table-data-pilot-group-attlist"/>
+        <oneOrMore>
+            <ref name="table-data-pilot-group-member"/>
+        </oneOrMore>
+    </element>
+</define>
+<define name="table-data-pilot-group-attlist" combine="interleave">
+    <attribute name="table:name">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="table-data-pilot-group-member">
+    <element name="table:data-pilot-group-member">
+        <ref name="table-data-pilot-group-member-attlist"/>
+    </element>
+</define>
+<define name="table-data-pilot-group-member-attlist" combine="interleave">
+    <attribute name="table:name">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="table-consolidation">
+    <element name="table:consolidation">
+        <ref name="table-consolidation-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="table-consolidation-attlist" combine="interleave">
+    <attribute name="table:function">    
+        <choice>
+            <value>auto</value>
+            <value>average</value>
+            <value>count</value>
+            <value>countnums</value>
+            <value>max</value>
+            <value>min</value>
+            <value>product</value>
+            <value>stdev</value>
+            <value>stdevp</value>
+            <value>sum</value>
+            <value>var</value>
+            <value>varp</value>
+            <ref name="string"/>
+        </choice>
+    </attribute>
+</define>
+<define name="table-consolidation-attlist" combine="interleave">
+    <attribute name="table:source-cell-range-addresses">    
+        <ref name="cellRangeAddressList"/>
+    </attribute>
+</define>
+<define name="table-consolidation-attlist" combine="interleave">
+    <attribute name="table:target-cell-address">    
+        <ref name="cellAddress"/>
+    </attribute>
+</define>
+<define name="table-consolidation-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:use-labels" a:defaultValue="none">
+            <choice>
+                <value>none</value>
+                <value>row</value>
+                <value>column</value>
+                <value>both</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="table-consolidation-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:link-to-source-data" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-dde-links">
+    <element name="table:dde-links">
+        <oneOrMore>
+            <ref name="table-dde-link"/>
+        </oneOrMore>
+    </element>
+</define>
+<define name="table-tracked-changes">
+    <element name="table:tracked-changes">
+        <ref name="table-tracked-changes-attlist"/>
+        <zeroOrMore>
+            <choice>
+                <ref name="table-cell-content-change"/>
+                <ref name="table-insertion"/>
+                <ref name="table-deletion"/>
+                <ref name="table-movement"/>
+            </choice>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="table-tracked-changes-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:track-changes" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-insertion">
+    <element name="table:insertion">
+        <ref name="table-insertion-attlist"/>
+        <ref name="common-table-change-attlist"/>
+        <ref name="office-change-info"/>
+        <optional>
+            <ref name="table-dependencies"/>
+        </optional>
+        <optional>
+            <ref name="table-deletions"/>
+        </optional>
+    </element>
+</define>
+<define name="table-insertion-attlist" combine="interleave">
+    <attribute name="table:type">
+        <choice>
+            <value>row</value>
+            <value>column</value>
+            <value>table</value>
+        </choice>
+    </attribute>
+</define>
+<define name="table-insertion-attlist" combine="interleave">
+    <attribute name="table:position">
+        <ref name="integer"/>
+    </attribute>
+</define>
+<define name="table-insertion-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:count" a:defaultValue="1">
+            <ref name="positiveInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-insertion-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:table">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-dependencies">
+    <element name="table:dependencies">
+        <oneOrMore>
+            <ref name="table-dependency"/>
+        </oneOrMore>
+    </element>
+</define>
+<define name="table-dependency">
+    <element name="table:dependency">
+        <attribute name="table:id">
+            <ref name="string"/>
+        </attribute>
+        <empty/>
+    </element>
+</define>
+<define name="table-deletions">
+    <element name="table:deletions">
+        <oneOrMore>
+            <choice>
+                <ref name="table-cell-content-deletion"/>
+                <ref name="table-change-deletion"/>
+            </choice>
+        </oneOrMore>
+    </element>
+</define>
+<define name="table-cell-content-deletion">
+    <element name="table:cell-content-deletion">
+        <optional>
+            <attribute name="table:id">
+                <ref name="string"/>
+            </attribute>
+        </optional>
+        <optional>
+            <ref name="table-cell-address"/>
+        </optional>
+        <optional>
+            <ref name="table-change-track-table-cell"/>
+        </optional>
+    </element>
+</define>
+<define name="table-change-deletion">
+    <element name="table:change-deletion">
+        <optional>
+            <attribute name="table:id">
+                <ref name="string"/>
+            </attribute>
+        </optional>
+        <empty/>
+    </element>
+</define>
+<define name="table-deletion">
+    <element name="table:deletion">
+        <ref name="table-deletion-attlist"/>
+        <ref name="common-table-change-attlist"/>
+        <ref name="office-change-info"/>
+        <optional>
+            <ref name="table-dependencies"/>
+        </optional>
+        <optional>
+            <ref name="table-deletions"/>
+        </optional>
+        <optional>
+            <ref name="table-cut-offs"/>
+        </optional>
+    </element>
+</define>
+<define name="table-deletion-attlist" combine="interleave">
+    <attribute name="table:type">
+        <choice>
+            <value>row</value>
+            <value>column</value>
+            <value>table</value>
+        </choice>
+    </attribute>
+</define>
+<define name="table-deletion-attlist" combine="interleave">
+    <attribute name="table:position">
+        <ref name="integer"/>
+    </attribute>
+</define>
+<define name="table-deletion-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:table">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-deletion-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:multi-deletion-spanned">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-cut-offs">
+    <element name="table:cut-offs">
+        <choice>
+            <oneOrMore>
+                <ref name="table-movement-cut-off"/>
+            </oneOrMore>
+            <group>
+                <ref name="table-insertion-cut-off"/>
+                <zeroOrMore>
+                    <ref name="table-movement-cut-off"/>
+                </zeroOrMore>
+            </group>
+        </choice>
+    </element>
+</define>
+<define name="table-insertion-cut-off">
+    <element name="table:insertion-cut-off">
+        <ref name="table-insertion-cut-off-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="table-insertion-cut-off-attlist" combine="interleave">
+    <attribute name="table:id">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="table-insertion-cut-off-attlist" combine="interleave">
+    <attribute name="table:position">
+        <ref name="integer"/>
+    </attribute>
+</define>
+<define name="table-movement-cut-off">
+    <element name="table:movement-cut-off">
+        <ref name="table-movement-cut-off-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="table-movement-cut-off-attlist" combine="interleave">
+    <choice>
+        <attribute name="table:position">
+            <ref name="integer"/>
+        </attribute>
+        <group>
+            <attribute name="table:start-position">
+                <ref name="integer"/>
+            </attribute>
+            <attribute name="table:end-position">
+                <ref name="integer"/>
+            </attribute>
+        </group>
+    </choice>
+</define>
+<define name="table-movement">
+    <element name="table:movement">
+        <ref name="common-table-change-attlist"/>
+        <ref name="table-source-range-address"/>
+        <ref name="table-target-range-address"/>
+        <ref name="office-change-info"/>
+        <optional>
+            <ref name="table-dependencies"/>
+        </optional>
+        <optional>
+            <ref name="table-deletions"/>
+        </optional>
+    </element>
+</define>
+<define name="table-source-range-address">
+    <element name="table:source-range-address">
+        <ref name="common-table-range-attlist"/>
+        <empty/>
+    </element>
+</define>
+
+<define name="table-target-range-address">
+    <element name="table:target-range-address">
+        <ref name="common-table-range-attlist"/>
+        <empty/>
+    </element>
+</define>
+
+
+<define name="common-table-range-attlist" combine="interleave">
+    <choice>
+        <group>
+            <ref name="common-table-cell-address-attlist"/>
+        </group>
+        <group>
+            <ref name="common-table-cell-range-address-attlist"/>
+        </group>
+    </choice>
+</define>
+<define name="common-table-cell-address-attlist" combine="interleave">
+    <attribute name="table:column">
+        <ref name="integer"/>
+    </attribute>
+    <attribute name="table:row">
+        <ref name="integer"/>
+    </attribute>
+    <attribute name="table:table">
+        <ref name="integer"/>
+    </attribute>
+</define>
+<define name="common-table-cell-range-address-attlist" combine="interleave">
+    <attribute name="table:start-column">
+        <ref name="integer"/>
+    </attribute>
+    <attribute name="table:start-row">
+        <ref name="integer"/>
+    </attribute>
+    <attribute name="table:start-table">
+        <ref name="integer"/>
+    </attribute>
+    <attribute name="table:end-column">
+        <ref name="integer"/>
+    </attribute>
+    <attribute name="table:end-row">
+        <ref name="integer"/>
+    </attribute>
+    <attribute name="table:end-table">
+        <ref name="integer"/>
+    </attribute>
+</define>
+<define name="table-change-track-table-cell" combine="interleave">
+    <element name="table:change-track-table-cell">
+        <ref name="table-change-track-table-cell-attlist"/>
+        <zeroOrMore>
+            <ref name="text-p"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="table-change-track-table-cell-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:cell-address">
+            <ref name="cellAddress"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-change-track-table-cell-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:matrix-covered" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-change-track-table-cell-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:formula">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="table:number-matrix-columns-spanned">
+            <ref name="positiveInteger"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="table:number-matrix-rows-spanned">
+            <ref name="positiveInteger"/>
+        </attribute>
+    </optional>
+    <optional>
+        <ref name="common-value-and-type-attlist"/>
+    </optional>
+</define>
+<define name="table-cell-content-change">
+    <element name="table:cell-content-change">
+        <ref name="common-table-change-attlist"/>
+        <ref name="table-cell-address"/>
+        <ref name="office-change-info"/>
+        <optional>
+            <ref name="table-dependencies"/>
+        </optional>
+        <optional>
+            <ref name="table-deletions"/>
+        </optional>
+        <ref name="table-previous"/>
+    </element>
+</define>
+<define name="table-cell-address">
+    <element name="table:cell-address">
+        <ref name="common-table-cell-address-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="table-previous">
+    <element name="table:previous">
+        <optional>
+            <attribute name="table:id">
+                <ref name="string"/>
+            </attribute>
+        </optional>
+        <ref name="table-change-track-table-cell"/>
+    </element>
+</define>
+<define name="common-table-change-attlist" combine="interleave">
+    <attribute name="table:id">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="common-table-change-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:acceptance-state" a:defaultValue="pending">
+            <choice>
+                <value>accepted</value>
+                <value>rejected</value>
+                <value>pending</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="common-table-change-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:rejecting-change-id">
+            <ref name="string"/> 
+        </attribute>
+    </optional>
+</define>
+<define name="style-handout-master">
+    <element name="style:handout-master">
+        <ref name="common-presentation-header-footer-attlist"/>
+        <ref name="style-handout-master-attlist"/>
+        <zeroOrMore>
+            <ref name="shape"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="style-handout-master-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:presentation-page-layout-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-handout-master-attlist" combine="interleave">
+    <attribute name="style:page-layout-name">
+        <ref name="styleNameRef"/>
+    </attribute>
+</define>
+<define name="style-handout-master-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-layer-set">
+    <element name="draw:layer-set">
+        <zeroOrMore>
+            <ref name="draw-layer"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="draw-layer">
+    <element name="draw:layer">
+        <ref name="draw-layer-attlist"/>
+        <optional>
+            <ref name="svg-title"/>
+        </optional>
+        <optional>
+            <ref name="svg-desc"/>
+        </optional>
+    </element>
+</define>
+<define name="draw-layer-attlist" combine="interleave">
+    <attribute name="draw:name">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="draw-layer-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:protected" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-layer-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:display" a:defaultValue="always">
+            <choice>
+                <value>always</value>
+                <value>screen</value>
+                <value>printer</value>
+                <value>none</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-page">
+    <element name="draw:page">
+        <ref name="common-presentation-header-footer-attlist"/>
+        <ref name="draw-page-attlist"/>
+        <optional>
+            <ref name="office-forms"/>
+        </optional>
+        <zeroOrMore>
+            <ref name="shape"/>
+        </zeroOrMore>
+        <optional>
+            <choice>
+                <ref name="presentation-animations"/>
+                <ref name="animation-element"/>
+            </choice>
+        </optional>
+        <optional>
+            <ref name="presentation-notes"/>
+        </optional>
+    </element>
+</define>
+<define name="draw-page-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-page-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-page-attlist" combine="interleave">
+    <attribute name="draw:master-page-name">
+        <ref name="styleNameRef"/>
+    </attribute>
+</define>
+<define name="draw-page-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:presentation-page-layout-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-presentation-header-footer-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:use-header-name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-presentation-header-footer-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:use-footer-name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-presentation-header-footer-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:use-date-time-name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-page-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:id">
+            <ref name="ID"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-page-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:nav-order">
+            <ref name="IDREFS"/>
+        </attribute>
+    </optional>
+</define>
+<define name="shape">
+    <choice>
+        <ref name="draw-rect"/>
+        <ref name="draw-line"/>
+        <ref name="draw-polyline"/>
+        <ref name="draw-polygon"/>
+        <ref name="draw-regular-polygon"/>
+        <ref name="draw-path"/>
+        <ref name="draw-circle"/>
+        <ref name="draw-ellipse"/>
+        <ref name="draw-g"/>
+        <ref name="draw-page-thumbnail"/>
+        <ref name="draw-frame"/>
+        <ref name="draw-measure"/>
+        <ref name="draw-caption"/>
+        <ref name="draw-connector"/>
+        <ref name="draw-control"/>
+        <ref name="dr3d-scene"/>
+        <ref name="draw-custom-shape"/>
+    </choice>
+</define>
+<define name="draw-rect">
+    <element name="draw:rect">
+        <ref name="draw-rect-attlist"/>
+        <ref name="common-draw-position-attlist"/>
+        <ref name="common-draw-size-attlist"/>
+        <ref name="common-draw-shape-with-text-and-styles-attlist"/>
+        <ref name="common-draw-caption-id-attlist"/>
+        <optional>
+            <ref name="svg-title"/>
+        </optional>
+        <optional>
+            <ref name="svg-desc"/>
+        </optional>
+        <optional>
+            <ref name="office-event-listeners"/>
+        </optional>
+        <zeroOrMore>
+            <ref name="draw-glue-point"/>
+        </zeroOrMore>
+        <ref name="draw-text"/>
+    </element>
+</define>
+<define name="draw-rect-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:corner-radius">
+            <ref name="nonNegativeLength"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-line">
+    <element name="draw:line">
+        <ref name="draw-line-attlist"/>
+        <ref name="common-draw-shape-with-text-and-styles-attlist"/>
+        <ref name="common-draw-caption-id-attlist"/>
+        <optional>
+            <ref name="svg-title"/>
+        </optional>
+        <optional>
+            <ref name="svg-desc"/>
+        </optional>
+        <optional>
+            <ref name="office-event-listeners"/>
+        </optional>
+        <zeroOrMore>
+            <ref name="draw-glue-point"/>
+        </zeroOrMore>
+        <ref name="draw-text"/>
+    </element>
+</define>
+<define name="draw-line-attlist" combine="interleave">
+    <attribute name="svg:x1">
+        <ref name="coordinate"/>
+    </attribute>
+    <attribute name="svg:y1">
+        <ref name="coordinate"/>
+    </attribute>
+</define>
+<define name="draw-line-attlist" combine="interleave">
+    <attribute name="svg:x2">
+        <ref name="coordinate"/>
+    </attribute>
+    <attribute name="svg:y2">
+        <ref name="coordinate"/>
+    </attribute>
+</define>
+<define name="draw-polyline">
+    <element name="draw:polyline">
+        <ref name="common-draw-points-attlist"/>
+        <ref name="common-draw-position-attlist"/>
+        <ref name="common-draw-size-attlist"/>
+        <ref name="common-draw-viewbox-attlist"/>
+        <ref name="common-draw-shape-with-text-and-styles-attlist"/>
+        <ref name="common-draw-caption-id-attlist"/>
+        <optional>
+            <ref name="svg-title"/>
+        </optional>
+        <optional>
+            <ref name="svg-desc"/>
+        </optional>
+        <optional>
+            <ref name="office-event-listeners"/>
+        </optional>
+        <zeroOrMore>
+            <ref name="draw-glue-point"/>
+        </zeroOrMore>
+        <ref name="draw-text"/>
+    </element>
+</define>
+<define name="common-draw-points-attlist">
+    <attribute name="draw:points">
+        <ref name="points"/>
+    </attribute>
+</define>
+<define name="draw-polygon">
+    <element name="draw:polygon">
+        <ref name="common-draw-points-attlist"/>
+        <ref name="common-draw-position-attlist"/>
+        <ref name="common-draw-size-attlist"/>
+        <ref name="common-draw-viewbox-attlist"/>
+        <ref name="common-draw-shape-with-text-and-styles-attlist"/>
+        <ref name="common-draw-caption-id-attlist"/>
+        <optional>
+            <ref name="svg-title"/>
+        </optional>
+        <optional>
+            <ref name="svg-desc"/>
+        </optional>
+        <optional>
+            <ref name="office-event-listeners"/>
+        </optional>
+        <zeroOrMore>
+            <ref name="draw-glue-point"/>
+        </zeroOrMore>
+        <ref name="draw-text"/>
+    </element>
+</define>
+<define name="draw-regular-polygon">
+    <element name="draw:regular-polygon">
+        <ref name="draw-regular-polygon-attlist"/>
+        <ref name="common-draw-position-attlist"/>
+        <ref name="common-draw-size-attlist"/>
+        <ref name="common-draw-shape-with-text-and-styles-attlist"/>
+        <ref name="common-draw-caption-id-attlist"/>
+        <optional>
+            <ref name="svg-title"/>
+        </optional>
+        <optional>
+            <ref name="svg-desc"/>
+        </optional>
+        <optional>
+            <ref name="office-event-listeners"/>
+        </optional>
+        <zeroOrMore>
+            <ref name="draw-glue-point"/>
+        </zeroOrMore>
+        <ref name="draw-text"/>
+    </element>
+</define>
+<define name="draw-regular-polygon-attlist" combine="interleave">
+    <choice>
+        <attribute name="draw:concave">
+            <value>false</value>
+        </attribute>
+        <group>
+            <attribute name="draw:concave">
+                <value>true</value>
+            </attribute>
+            <ref name="draw-regular-polygon-sharpness-attlist"/>
+        </group>
+    </choice>
+</define>
+<define name="draw-regular-polygon-attlist" combine="interleave">
+    <attribute name="draw:corners">
+        <ref name="positiveInteger"/>
+    </attribute>
+</define>
+<define name="draw-regular-polygon-sharpness-attlist">
+    <attribute name="draw:sharpness">
+        <ref name="percent"/>
+    </attribute>
+</define>
+<define name="draw-path">
+    <element name="draw:path">
+        <ref name="common-draw-path-data-attlist"/>
+        <ref name="common-draw-position-attlist"/>
+        <ref name="common-draw-size-attlist"/>
+        <ref name="common-draw-viewbox-attlist"/>
+        <ref name="common-draw-shape-with-text-and-styles-attlist"/>
+        <ref name="common-draw-caption-id-attlist"/>
+        <optional>
+            <ref name="svg-title"/>
+        </optional>
+        <optional>
+            <ref name="svg-desc"/>
+        </optional>
+        <optional>
+            <ref name="office-event-listeners"/>
+        </optional>
+        <zeroOrMore>
+            <ref name="draw-glue-point"/>
+        </zeroOrMore>
+        <ref name="draw-text"/>
+    </element>
+</define>
+<define name="common-draw-path-data-attlist">
+    <attribute name="svg:d">
+        <ref name="pathData"/>
+    </attribute>
+</define>
+<define name="draw-circle">
+    <element name="draw:circle">
+        <ref name="draw-circle-attlist"/>
+        <ref name="common-draw-circle-ellipse-attlist"/>
+        <ref name="common-draw-position-attlist"/>
+        <ref name="common-draw-size-attlist"/>
+        <ref name="common-draw-shape-with-text-and-styles-attlist"/>
+        <ref name="common-draw-caption-id-attlist"/>
+        <optional>
+            <ref name="svg-title"/>
+        </optional>
+        <optional>
+            <ref name="svg-desc"/>
+        </optional>
+        <optional>
+            <ref name="office-event-listeners"/>
+        </optional>
+        <zeroOrMore>
+            <ref name="draw-glue-point"/>
+        </zeroOrMore>
+        <ref name="draw-text"/>
+    </element>
+</define>
+<define name="common-draw-circle-ellipse-attlist" combine="interleave">
+    <optional>
+        <attribute name="svg:cx">
+            <ref name="coordinate"/>
+        </attribute>
+        <attribute name="svg:cy">
+            <ref name="coordinate"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-circle-attlist" combine="interleave">
+    <optional>
+        <attribute name="svg:r">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-draw-circle-ellipse-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:kind" a:defaultValue="full">
+            <choice>
+                <value>full</value>
+                <value>section</value>
+                <value>cut</value>
+                <value>arc</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="common-draw-circle-ellipse-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:start-angle">
+            <ref name="double"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-draw-circle-ellipse-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:end-angle">
+            <ref name="double"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-ellipse">
+    <element name="draw:ellipse">
+        <ref name="common-draw-circle-ellipse-attlist"/>
+        <ref name="draw-ellipse-attlist"/>
+        <ref name="common-draw-position-attlist"/>
+        <ref name="common-draw-size-attlist"/>
+        <ref name="common-draw-shape-with-text-and-styles-attlist"/>
+        <ref name="common-draw-caption-id-attlist"/>
+        <optional>
+            <ref name="svg-title"/>
+        </optional>
+        <optional>
+            <ref name="svg-desc"/>
+        </optional>
+        <optional>
+            <ref name="office-event-listeners"/>
+        </optional>
+        <zeroOrMore>
+            <ref name="draw-glue-point"/>
+        </zeroOrMore>
+        <ref name="draw-text"/>
+    </element>
+</define>
+<define name="draw-ellipse-attlist" combine="interleave">
+    <optional>
+        <attribute name="svg:rx">
+            <ref name="length"/>
+        </attribute>
+        <attribute name="svg:ry">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-connector">
+    <element name="draw:connector">
+        <ref name="draw-connector-attlist"/>
+        <ref name="common-draw-shape-with-text-and-styles-attlist"/>
+        <ref name="common-draw-caption-id-attlist"/>
+        <optional>
+            <ref name="svg-title"/>
+        </optional>
+        <optional>
+            <ref name="svg-desc"/>
+        </optional>
+        <optional>
+            <ref name="office-event-listeners"/>
+        </optional>
+        <zeroOrMore>
+            <ref name="draw-glue-point"/>
+        </zeroOrMore>
+        <ref name="draw-text"/>
+    </element>
+</define>
+<define name="draw-connector-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:type" a:defaultValue="standard">
+            <choice>
+                <value>standard</value>
+                <value>lines</value>
+                <value>line</value>
+                <value>curve</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-connector-attlist" combine="interleave">
+    <optional>
+        <attribute name="svg:x1">
+            <ref name="coordinate"/>
+        </attribute>
+        <attribute name="svg:y1">
+            <ref name="coordinate"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-connector-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:start-shape">
+            <ref name="IDREF"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-connector-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:start-glue-point">
+            <ref name="nonNegativeInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-connector-attlist" combine="interleave">
+    <optional>
+        <attribute name="svg:x2">
+            <ref name="coordinate"/>
+        </attribute>
+        <attribute name="svg:y2">
+            <ref name="coordinate"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-connector-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:end-shape">
+            <ref name="IDREF"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-connector-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:end-glue-point">
+            <ref name="nonNegativeInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-connector-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:line-skew">
+            <list>
+                <ref name="length"/>
+                <optional>
+                    <ref name="length"/>
+                    <optional>
+                        <ref name="length"/>
+                    </optional>
+                </optional>
+            </list>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-caption">
+    <element name="draw:caption">
+        <ref name="draw-caption-attlist"/>
+        <ref name="common-draw-position-attlist"/>
+        <ref name="common-draw-size-attlist"/>
+        <ref name="common-draw-shape-with-text-and-styles-attlist"/>
+        <ref name="common-draw-caption-id-attlist"/>
+        <optional>
+            <ref name="svg-title"/>
+        </optional>
+        <optional>
+            <ref name="svg-desc"/>
+        </optional>
+        <optional>
+            <ref name="office-event-listeners"/>
+        </optional>
+        <zeroOrMore>
+            <ref name="draw-glue-point"/>
+        </zeroOrMore>
+        <ref name="draw-text"/>
+    </element>
+</define>
+<define name="draw-caption-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:caption-point-x">
+            <ref name="coordinate"/>
+        </attribute>
+        <attribute name="draw:caption-point-y">
+            <ref name="coordinate"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-caption-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:corner-radius">
+            <ref name="nonNegativeLength"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-measure">
+    <element name="draw:measure">
+        <ref name="draw-measure-attlist"/>
+        <ref name="common-draw-shape-with-text-and-styles-attlist"/>
+        <ref name="common-draw-caption-id-attlist"/>
+        <optional>
+            <ref name="svg-title"/>
+        </optional>
+        <optional>
+            <ref name="svg-desc"/>
+        </optional>
+        <optional>
+            <ref name="office-event-listeners"/>
+        </optional>
+        <zeroOrMore>
+            <ref name="draw-glue-point"/>
+        </zeroOrMore>
+        <ref name="draw-text"/>
+    </element>
+</define>
+<define name="draw-measure-attlist" combine="interleave">
+    <attribute name="svg:x1">
+        <ref name="coordinate"/>
+    </attribute>
+    <attribute name="svg:y1">
+        <ref name="coordinate"/>
+    </attribute>
+</define>
+<define name="draw-measure-attlist" combine="interleave">
+    <attribute name="svg:x2">
+        <ref name="coordinate"/>
+    </attribute>
+    <attribute name="svg:y2">
+        <ref name="coordinate"/>
+    </attribute>
+</define>
+<define name="draw-control">
+    <element name="draw:control">
+        <ref name="draw-control-attlist"/>
+        <ref name="common-draw-position-attlist"/>
+        <ref name="common-draw-size-attlist"/>
+        <ref name="common-draw-shape-with-text-and-styles-attlist"/>    
+        <ref name="common-draw-caption-id-attlist"/>
+        <optional>
+            <ref name="svg-title"/>
+        </optional>
+        <optional>
+            <ref name="svg-desc"/>
+        </optional>
+        <zeroOrMore>
+            <ref name="draw-glue-point"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="draw-control-attlist" combine="interleave">
+    <attribute name="draw:control">
+        <ref name="IDREF"/>
+    </attribute>
+</define>
+<define name="draw-page-thumbnail">
+    <element name="draw:page-thumbnail">
+        <ref name="draw-page-thumbnail-attlist"/>
+        <ref name="common-draw-position-attlist"/>
+        <ref name="common-draw-size-attlist"/>
+        <ref name="presentation-shape-attlist"/>
+        <ref name="common-draw-shape-with-styles-attlist"/>
+        <ref name="common-draw-caption-id-attlist"/>
+        <optional>
+            <ref name="svg-title"/>
+        </optional>
+        <optional>
+            <ref name="svg-desc"/>
+        </optional>
+    </element>
+</define>
+<define name="draw-page-thumbnail-attlist">
+    <optional>
+        <attribute name="draw:page-number">
+            <ref name="positiveInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-g">
+    <element name="draw:g">
+        <ref name="draw-g-attlist"/>
+        <ref name="common-draw-z-index-attlist"/>
+        <ref name="common-draw-name-attlist"/>
+        <ref name="common-draw-id-attlist"/>
+        <ref name="common-draw-style-name-attlist"/>
+        <ref name="common-text-spreadsheet-shape-attlist"/>
+        <ref name="common-draw-caption-id-attlist"/>
+        <optional>
+            <ref name="svg-title"/>
+        </optional>
+        <optional>
+            <ref name="svg-desc"/>
+        </optional>
+        <optional>
+            <ref name="office-event-listeners"/>
+        </optional>
+        <zeroOrMore>
+            <ref name="draw-glue-point"/>
+        </zeroOrMore>
+        <zeroOrMore>
+            <ref name="shape"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="draw-g-attlist" combine="interleave">
+    <optional>
+        <attribute name="svg:y">
+            <ref name="coordinate"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-draw-name-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-draw-caption-id-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:caption-id">
+            <ref name="IDREF"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-draw-position-attlist">
+    <optional>
+        <attribute name="svg:x">
+            <ref name="coordinate"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="svg:y">
+            <ref name="coordinate"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-draw-size-attlist">
+    <optional>
+        <attribute name="svg:width">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="svg:height">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-draw-transform-attlist">
+    <optional>
+        <attribute name="draw:transform">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-draw-viewbox-attlist">
+    <attribute name="svg:viewBox">
+        <list>
+            <ref name="integer"/>
+            <ref name="integer"/>
+            <ref name="integer"/>
+            <ref name="integer"/>
+        </list>
+    </attribute>
+</define>
+<define name="common-draw-style-name-attlist">
+    <choice>
+        <group>
+            <optional>
+                <attribute name="draw:style-name">
+                    <ref name="styleNameRef"/>
+                </attribute>
+            </optional>
+            <optional>
+                <attribute name="draw:class-names">
+                    <ref name="styleNameRefs"/>
+                </attribute>
+            </optional>
+        </group>
+        <group>
+            <optional>
+                <attribute name="presentation:style-name">
+                    <ref name="styleNameRef"/>
+                </attribute>
+            </optional>
+            <optional>
+                <attribute name="presentation:class-names">
+                    <ref name="styleNameRefs"/>
+                </attribute>
+            </optional>
+        </group>
+    </choice>
+</define>
+<define name="common-draw-text-style-name-attlist">
+    <optional>
+        <attribute name="draw:text-style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-draw-layer-name-attlist">
+    <optional>
+        <attribute name="draw:layer">
+            <data type="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-draw-id-attlist">
+    <optional>
+        <attribute name="draw:id">
+            <ref name="ID"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-draw-z-index-attlist">
+    <optional>
+        <attribute name="draw:z-index">
+            <ref name="nonNegativeInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-text-spreadsheet-shape-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:end-cell-address">
+            <ref name="cellAddress"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="table:end-x">
+            <ref name="coordinate"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="table:end-y">
+            <ref name="coordinate"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-text-spreadsheet-shape-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:table-background">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-text-spreadsheet-shape-attlist" combine="interleave">
+    <ref name="common-text-anchor-attlist"/>
+</define>
+
+<define name="common-text-anchor-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:anchor-type">
+            <choice>
+                <value>page</value>
+                <value>frame</value>
+                <value>paragraph</value>
+                <value>char</value>
+                <value>as-char</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="common-text-anchor-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:anchor-page-number">
+            <ref name="positiveInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-text">
+    <zeroOrMore>
+        <choice>
+            <ref name="text-p"/>
+            <ref name="text-list"/>
+        </choice>
+    </zeroOrMore>
+</define>
+<define name="common-draw-shape-with-styles-attlist">
+    <ref name="common-draw-z-index-attlist"/>
+    <ref name="common-draw-id-attlist"/>
+    <ref name="common-draw-layer-name-attlist"/>
+    <ref name="common-draw-style-name-attlist"/>
+    <ref name="common-draw-transform-attlist"/>
+    <ref name="common-draw-name-attlist"/>
+    <ref name="common-text-spreadsheet-shape-attlist"/>
+</define>
+<define name="common-draw-shape-with-text-and-styles-attlist">
+    <ref name="common-draw-shape-with-styles-attlist"/>
+    <ref name="common-draw-text-style-name-attlist"/>
+</define>
+<define name="draw-glue-point">
+    <element name="draw:glue-point">
+        <ref name="draw-glue-point-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="draw-glue-point-attlist" combine="interleave">
+    <attribute name="draw:id">
+        <ref name="nonNegativeInteger"/>
+    </attribute>
+</define>
+<define name="draw-glue-point-attlist" combine="interleave">
+    <attribute name="svg:x">
+        <choice>
+            <ref name="distance"/> 
+            <ref name="percent"/>
+        </choice>
+    </attribute>
+    <attribute name="svg:y">
+        <choice>
+            <ref name="distance"/> 
+            <ref name="percent"/>
+        </choice>
+    </attribute>
+</define>
+<define name="draw-glue-point-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:align">
+            <choice>
+                <value>top-left</value>
+                <value>top</value>
+                <value>top-right</value>
+                <value>left</value>
+                <value>center</value>
+                <value>right</value>
+                <value>bottom-left</value>
+                <value>bottom-right</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-glue-points-attlist" combine="interleave">
+    <attribute name="draw:escape-direction">
+        <choice>
+            <value>auto</value>
+            <value>left</value>
+            <value>right</value>
+            <value>up</value>
+            <value>down</value>
+            <value>horizontal</value>
+            <value>vertical</value>
+        </choice>
+    </attribute>
+</define>
+<define name="svg-title">
+    <element name="svg:title">
+        <text/>
+    </element>
+</define>
+<define name="svg-desc">
+    <element name="svg:desc">
+        <text/>
+    </element>
+</define>
+<define name="draw-frame">
+    <element name="draw:frame">
+        <ref name="common-draw-shape-with-text-and-styles-attlist"/>
+        <ref name="common-draw-position-attlist"/>
+        <ref name="common-draw-rel-size-attlist"/>
+        <ref name="common-draw-caption-id-attlist"/>
+        <ref name="presentation-shape-attlist"/>
+        <ref name="draw-frame-attlist"/>
+        <zeroOrMore>
+            <choice>
+                <ref name="draw-text-box"/>
+                <ref name="draw-image"/>
+                <ref name="draw-object"/>
+                <ref name="draw-object-ole"/>
+                <ref name="draw-applet"/>
+                <ref name="draw-floating-frame"/>
+                <ref name="draw-plugin"/>
+            </choice>
+        </zeroOrMore>
+        <optional>
+            <ref name="office-event-listeners"/>
+        </optional>
+        <zeroOrMore>
+            <ref name="draw-glue-point"/>
+        </zeroOrMore>
+        <optional>
+            <ref name="draw-image-map"/>
+        </optional>
+        <optional>
+            <ref name="svg-title"/>
+        </optional>
+        <optional>
+            <ref name="svg-desc"/>
+        </optional>
+        <optional>
+            <choice>
+                <ref name="draw-contour-polygon"/>
+                <ref name="draw-contour-path"/>
+            </choice>
+        </optional>
+    </element>
+</define>
+<define name="common-draw-rel-size-attlist">
+    <ref name="common-draw-size-attlist"/>
+    <optional>
+        <attribute name="style:rel-width">
+            <choice>
+                <ref name="percent"/>
+                <value>scale</value>
+                <value>scale-min</value>
+            </choice>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:rel-height">
+            <choice>
+                <ref name="percent"/>
+                <value>scale</value>
+                <value>scale-min</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-frame-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:copy-of">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-text-box">
+    <element name="draw:text-box">
+        <ref name="draw-text-box-attlist"/>
+        <zeroOrMore>
+            <ref name="text-content"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="draw-text-box-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:chain-next-name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-text-box-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:corner-radius">
+            <ref name="nonNegativeLength"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-text-box-attlist" combine="interleave">
+    <optional>
+        <attribute name="fo:min-height">
+            <choice>
+                <ref name="length"/>
+                <ref name="percent"/>
+            </choice>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="fo:min-width">
+            <choice>
+                <ref name="length"/>
+                <ref name="percent"/>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-text-box-attlist" combine="interleave">
+    <optional>
+        <attribute name="fo:max-height">
+            <choice>
+                <ref name="length"/>
+                <ref name="percent"/>
+            </choice>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="fo:max-width">
+            <choice>
+                <ref name="length"/>
+                <ref name="percent"/>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-text-box-attlist" combine="interleave">
+    <optional>
+        <ref name="text-id"/>
+    </optional>
+</define>
+<define name="draw-image">
+    <element name="draw:image">
+        <ref name="draw-image-attlist"/>
+        <choice>
+            <ref name="common-draw-data-attlist"/>
+            <ref name="office-binary-data"/>
+        </choice>
+        <ref name="draw-text"/>
+    </element>
+</define>
+<define name="common-draw-data-attlist" combine="interleave">
+    <group>
+        <attribute name="xlink:href">
+            <ref name="anyURI"/>
+        </attribute>
+        <optional>
+            <attribute name="xlink:type" a:defaultValue="simple">
+                <choice>
+                    <value>simple</value>
+                </choice>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="xlink:show" a:defaultValue="embed">
+                <choice>
+                    <value>embed</value>
+                </choice>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="xlink:actuate" a:defaultValue="onLoad">
+                <choice>
+                    <value>onLoad</value>
+                </choice>
+            </attribute>
+        </optional>
+    </group>
+</define>
+
+<define name="office-binary-data">
+    <element name="office:binary-data">
+        <ref name="base64Binary"/>
+    </element>
+</define>
+<define name="draw-image-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:filter-name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-object">
+    <element name="draw:object">
+        <ref name="draw-object-attlist"/>
+        <choice>
+            <ref name="common-draw-data-attlist"/>
+            <ref name="office-document"/>
+            <ref name="math-math"/>
+        </choice>
+    </element>
+</define>
+
+<define name="draw-object-ole">
+    <element name="draw:object-ole">
+        <ref name="draw-object-ole-attlist"/>
+        <choice>
+            <ref name="common-draw-data-attlist"/>
+            <ref name="office-binary-data"/>
+        </choice>
+    </element>
+</define>
+<define name="draw-object-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:notify-on-update-of-ranges">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-object-ole-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:class-id"/>
+    </optional>
+</define>
+<define name="draw-applet">
+    <element name="draw:applet">
+        <ref name="draw-applet-attlist"/>
+        <optional>
+            <ref name="common-draw-data-attlist"/>
+        </optional>
+        <zeroOrMore>
+            <ref name="draw-param"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="draw-applet-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:code"/>
+    </optional>
+</define>
+<define name="draw-applet-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:object"/>
+    </optional>
+</define>
+<define name="draw-applet-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:archive"/>
+    </optional>
+</define>
+<define name="draw-applet-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:may-script" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-plugin">
+    <element name="draw:plugin">
+        <ref name="draw-plugin-attlist"/>
+        <ref name="common-draw-data-attlist"/>
+        <zeroOrMore>
+            <ref name="draw-param"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="draw-plugin-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:mime-type"/>
+    </optional>
+</define>
+<define name="draw-param">
+    <element name="draw:param">
+        <ref name="draw-param-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="draw-param-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:name"/>
+    </optional>
+</define>
+<define name="draw-param-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:value"/>
+    </optional>
+</define>
+<define name="draw-floating-frame">
+    <element name="draw:floating-frame">
+        <ref name="draw-floating-frame-attlist"/>
+        <ref name="common-draw-data-attlist"/>
+    </element>
+</define>
+<define name="draw-floating-frame-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:frame-name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-contour-polygon">
+    <element name="draw:contour-polygon">
+        <ref name="common-contour-attlist"/>
+        <ref name="common-draw-size-attlist"/>
+        <ref name="common-draw-viewbox-attlist"/>
+        <ref name="common-draw-points-attlist"/>
+        <empty/>
+    </element>
+</define>
+
+<define name="draw-contour-path">
+    <element name="draw:contour-path">
+        <ref name="common-contour-attlist"/>
+        <ref name="common-draw-size-attlist"/>
+        <ref name="common-draw-viewbox-attlist"/>
+        <ref name="common-draw-path-data-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="common-contour-attlist" combine="interleave">
+    <attribute name="draw:recreate-on-edit">
+        <ref name="boolean"/>
+    </attribute>
+</define>
+<define name="draw-a">
+    <element name="draw:a">
+        <ref name="draw-a-attlist"/>
+        <ref name="draw-frame"/>
+    </element>
+</define>
+<define name="draw-a-attlist" combine="interleave">
+    <attribute name="xlink:href">
+        <ref name="anyURI"/>
+    </attribute>
+    <optional>
+        <attribute name="xlink:type" a:defaultValue="simple">
+            <value>simple</value>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="xlink:actuate" a:defaultValue="onRequest">
+            <choice>
+                <value>onRequest</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-a-attlist" combine="interleave">
+    <optional>
+        <attribute name="office:target-frame-name">
+            <ref name="targetFrameName"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="xlink:show">
+            <choice>
+                <value>new</value>
+                <value>replace</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-a-attlist" combine="interleave">
+    <optional>
+        <attribute name="office:name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-a-attlist" combine="interleave">
+    <optional>
+        <attribute name="office:title">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-a-attlist" combine="interleave">
+    <optional>
+        <attribute name="office:server-map" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-image-map">
+    <element name="draw:image-map">
+        <zeroOrMore>
+            <choice>
+                <ref name="draw-area-rectangle"/>
+                <ref name="draw-area-circle"/>
+                <ref name="draw-area-polygon"/>
+            </choice>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="draw-area-rectangle">
+    <element name="draw:area-rectangle">
+        <ref name="common-draw-area-attlist"/>
+        <attribute name="svg:x">
+            <ref name="coordinate"/>
+        </attribute>
+        <attribute name="svg:y">
+            <ref name="coordinate"/>
+        </attribute>
+        <attribute name="svg:width">
+            <ref name="length"/>
+        </attribute>
+        <attribute name="svg:height">
+            <ref name="length"/>
+        </attribute>
+        <optional>
+            <ref name="svg-title"/>
+        </optional>
+        <optional>
+            <ref name="svg-desc"/>
+        </optional>
+        <optional>
+            <ref name="office-event-listeners"/>
+        </optional>
+    </element>
+</define>
+<define name="draw-area-circle">
+    <element name="draw:area-circle">
+        <ref name="common-draw-area-attlist"/>
+        <attribute name="svg:cx">
+            <ref name="coordinate"/>
+        </attribute>
+        <attribute name="svg:cy">
+            <ref name="coordinate"/>
+        </attribute>
+        <attribute name="svg:r">
+            <ref name="length"/>
+        </attribute>
+        <optional>
+            <ref name="svg-title"/>
+        </optional>
+        <optional>
+            <ref name="svg-desc"/>
+        </optional>
+        <optional>
+            <ref name="office-event-listeners"/>
+        </optional>
+    </element>
+</define>
+<define name="draw-area-polygon">
+    <element name="draw:area-polygon">
+        <ref name="common-draw-area-attlist"/>
+        <attribute name="svg:x">
+            <ref name="coordinate"/>
+        </attribute>
+        <attribute name="svg:y">
+            <ref name="coordinate"/>
+        </attribute>
+        <attribute name="svg:width">
+            <ref name="length"/>
+        </attribute>
+        <attribute name="svg:height">
+            <ref name="length"/>
+        </attribute>
+        <ref name="common-draw-viewbox-attlist"/>
+        <ref name="common-draw-points-attlist"/>
+        <optional>
+            <ref name="svg-title"/>
+        </optional>
+        <optional>
+            <ref name="svg-desc"/>
+        </optional>
+        <optional>
+            <ref name="office-event-listeners"/>
+        </optional>
+    </element>
+</define>
+<define name="common-draw-area-attlist" combine="interleave">
+    <optional>
+        <attribute name="xlink:href">
+            <ref name="anyURI"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="xlink:type" a:defaultValue="simple">
+            <choice>
+                <value>simple</value>
+            </choice>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="office:target-frame-name">
+            <ref name="targetFrameName"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="xlink:show">
+            <choice>
+                <value>new</value>
+                <value>replace</value>
+            </choice>
+            </attribute>
+    </optional>
+</define>
+<define name="common-draw-area-attlist" combine="interleave">
+    <optional>
+        <attribute name="office:name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-draw-area-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:nohref">
+            <choice>
+                <value>nohref</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="dr3d-scene">
+    <element name="dr3d:scene">
+        <ref name="dr3d-scene-attlist"/>
+        <ref name="common-draw-position-attlist"/>
+        <ref name="common-draw-size-attlist"/>
+        <ref name="common-draw-style-name-attlist"/>
+        <ref name="common-draw-z-index-attlist"/>
+        <ref name="common-draw-id-attlist"/>
+        <ref name="common-draw-layer-name-attlist"/>
+        <ref name="common-text-spreadsheet-shape-attlist"/>
+        <ref name="common-dr3d-transform-attlist"/>
+        <ref name="common-draw-caption-id-attlist"/>
+        <optional>
+            <ref name="svg-title"/>
+        </optional>
+        <optional>
+            <ref name="svg-desc"/>
+        </optional>
+        <zeroOrMore>
+            <ref name="dr3d-light"/>
+        </zeroOrMore>
+        <zeroOrMore>
+            <ref name="shapes3d"/>
+        </zeroOrMore>
+    </element>
+</define>
+
+<define name="shapes3d">
+    <choice>
+        <ref name="dr3d-scene"/>
+        <ref name="dr3d-extrude"/>
+        <ref name="dr3d-sphere"/>
+        <ref name="dr3d-rotate"/>
+        <ref name="dr3d-cube"/>
+    </choice>
+</define>
+<define name="dr3d-scene-attlist" combine="interleave">
+    <optional>
+        <attribute name="dr3d:vrp">
+            <ref name="vector3D"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="dr3d:vpn">
+            <ref name="vector3D"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="dr3d:vup">
+            <ref name="vector3D"/>
+        </attribute>
+    </optional>
+</define>
+<define name="dr3d-scene-attlist" combine="interleave">
+    <optional>
+        <attribute name="dr3d:projection">
+            <choice>
+                <value>parallel</value>
+                <value>perspective</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="dr3d-scene-attlist" combine="interleave">
+    <optional>
+        <attribute name="dr3d:distance">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+</define>
+<define name="dr3d-scene-attlist" combine="interleave">
+    <optional>
+        <attribute name="dr3d:focal-length">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+</define>
+<define name="dr3d-scene-attlist" combine="interleave">
+    <optional>
+        <attribute name="dr3d:shadow-slant">
+            <ref name="nonNegativeInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="dr3d-scene-attlist" combine="interleave">
+    <optional>
+        <attribute name="dr3d:shade-mode">
+            <choice>
+                <value>flat</value>
+                <value>phong</value>
+                <value>gouraud</value>
+                <value>draft</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="dr3d-scene-attlist" combine="interleave">
+    <optional>
+        <attribute name="dr3d:ambient-color">
+            <ref name="color"/>
+        </attribute>
+    </optional>
+</define>
+<define name="dr3d-scene-attlist" combine="interleave">
+    <optional>
+        <attribute name="dr3d:lighting-mode">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-dr3d-transform-attlist">
+    <optional>
+        <attribute name="dr3d:transform"/>
+    </optional>
+</define>
+<define name="dr3d-light">
+    <element name="dr3d:light">
+        <ref name="dr3d-light-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="dr3d-light-attlist" combine="interleave">
+    <optional>
+        <attribute name="dr3d:diffuse-color">
+            <ref name="color"/>
+        </attribute>
+    </optional>
+</define>
+<define name="dr3d-light-attlist" combine="interleave">
+    <attribute name="dr3d:direction">
+        <ref name="vector3D"/>
+    </attribute>
+</define>
+<define name="dr3d-light-attlist" combine="interleave">
+    <optional>
+        <attribute name="dr3d:enabled">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="dr3d-light-attlist" combine="interleave">
+    <optional>
+        <attribute name="dr3d:specular">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="dr3d-cube">
+    <element name="dr3d:cube">
+        <ref name="dr3d-cube-attlist"/>
+        <ref name="common-draw-z-index-attlist"/>
+        <ref name="common-draw-id-attlist"/>
+        <ref name="common-draw-layer-name-attlist"/>
+        <ref name="common-draw-style-name-attlist"/>
+        <ref name="common-dr3d-transform-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="dr3d-cube-attlist" combine="interleave">
+    <optional>
+        <attribute name="dr3d:min-edge">
+            <ref name="vector3D"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="dr3d:max-edge">
+            <ref name="vector3D"/>
+        </attribute>
+    </optional>
+</define>
+<define name="dr3d-sphere">
+    <element name="dr3d:sphere">
+        <ref name="dr3d-sphere-attlist"/>
+        <ref name="common-draw-z-index-attlist"/>
+        <ref name="common-draw-id-attlist"/>
+        <ref name="common-draw-layer-name-attlist"/>
+        <ref name="common-draw-style-name-attlist"/>
+        <ref name="common-dr3d-transform-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="dr3d-sphere-attlist" combine="interleave">
+    <optional>
+        <attribute name="dr3d:center">
+            <ref name="vector3D"/>
+        </attribute>
+    </optional>
+</define>
+<define name="dr3d-sphere-attlist" combine="interleave">
+    <optional>
+        <attribute name="dr3d:size">
+            <ref name="vector3D"/>
+        </attribute>
+    </optional>
+</define>
+<define name="dr3d-extrude">
+    <element name="dr3d:extrude">
+        <ref name="common-draw-path-data-attlist"/>
+        <ref name="common-draw-viewbox-attlist"/>
+        <ref name="common-draw-id-attlist"/>
+        <ref name="common-draw-z-index-attlist"/>
+        <ref name="common-draw-layer-name-attlist"/>
+        <ref name="common-draw-style-name-attlist"/>
+        <ref name="common-dr3d-transform-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="dr3d-rotate">
+    <element name="dr3d:rotate">
+        <ref name="common-draw-viewbox-attlist"/>
+        <ref name="common-draw-path-data-attlist"/>
+        <ref name="common-draw-z-index-attlist"/>
+        <ref name="common-draw-id-attlist"/>
+        <ref name="common-draw-layer-name-attlist"/>
+        <ref name="common-draw-style-name-attlist"/>
+        <ref name="common-dr3d-transform-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="draw-custom-shape">
+    <element name="draw:custom-shape">
+        <ref name="draw-custom-shape-attlist"/>
+        <ref name="common-draw-position-attlist"/>
+        <ref name="common-draw-size-attlist"/>
+        <ref name="common-draw-shape-with-text-and-styles-attlist"/>
+        <ref name="common-draw-caption-id-attlist"/>
+        <optional>
+            <ref name="svg-title"/>
+        </optional>
+        <optional>
+            <ref name="svg-desc"/>
+        </optional>
+        <optional>
+            <ref name="office-event-listeners"/>
+        </optional>
+        <zeroOrMore>
+            <ref name="draw-glue-point"/>
+        </zeroOrMore>
+        <ref name="draw-text"/>
+        <optional>
+            <ref name="draw-enhanced-geometry"/>
+        </optional>
+    </element>
+</define>
+<define name="draw-custom-shape-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:engine">
+            <ref name="namespacedToken"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-custom-shape-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:data">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry">
+    <element name="draw:enhanced-geometry">
+        <ref name="draw-enhanced-geometry-attlist"/>
+        <zeroOrMore>
+            <ref name="draw-equation"/>
+        </zeroOrMore>
+        <zeroOrMore>
+            <ref name="draw-handle"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:type" a:defaultValue="non-primitive">
+            <ref name="custom-shape-type"/>
+        </attribute>
+    </optional>
+</define>
+
+<define name="custom-shape-type">
+    <choice>
+        <value>non-primitive</value>
+        <ref name="string"/>
+    </choice>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="svg:viewBox">
+            <list>
+                <ref name="integer"/>
+                <ref name="integer"/>
+                <ref name="integer"/>
+                <ref name="integer"/>
+            </list>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:mirror-vertical" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="draw:mirror-horizontal" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:text-rotate-angle" a:defaultValue="0">
+            <ref name="double"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:extrusion-allowed" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:text-path-allowed" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:concentric-gradient-fill-allowed"
+                    a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:extrusion" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:extrusion-brightness" a:defaultValue="33%">
+            <ref name="percent"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:extrusion-depth" a:defaultValue="36pt 0">
+            <list>
+                <ref name="length"/>
+                <ref name="double"/>
+            </list>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:extrusion-diffusion" a:defaultValue="0%">
+            <ref name="percent"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:extrusion-number-of-line-segments"
+                   a:defaultValue="30">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:extrusion-light-face" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:extrusion-first-light-harsh"
+                   a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:extrusion-second-light-harsh"
+                   a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:extrusion-first-light-level"
+                   a:defaultValue="66%">
+            <ref name="percent"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:extrusion-second-light-level"
+                   a:defaultValue="66%">
+            <ref name="percent"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:extrusion-first-light-direction"
+                   a:defaultValue="(5 0 1)">
+            <ref name="vector3D"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:extrusion-second-light-direction"
+                   a:defaultValue="(-5 0 1)">
+            <ref name="vector3D"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:extrusion-metal" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="dr3d:shade-mode" a:defaultValue="flat">
+            <choice>
+                <value>flat</value>
+                <value>phong</value>
+                <value>gouraud</value>
+                <value>draft</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:extrusion-rotation-angle" a:defaultValue="0 0">
+            <list>
+                <ref name="double"/>
+                <ref name="double"/>
+            </list>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:extrusion-rotation-center">
+            <ref name="vector3D"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:extrusion-shininess" a:defaultValue="50%">
+            <ref name="percent"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:extrusion-skew" a:defaultValue="50 45">
+            <list>
+                <ref name="double"/>
+                <ref name="double"/>
+            </list>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:extrusion-specularity" a:defaultValue="0%">
+            <ref name="percent"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="dr3d:projection" a:defaultValue="parallel">
+            <choice>
+                <value>parallel</value>
+                <value>perspective</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:extrusion-viewpoint" 
+                   a:defaultValue="3.5cm -3.5cm 25cm">
+            <ref name="point3D"/>
+        </attribute>
+    </optional>
+</define>
+
+<define name="point3D">
+    <data type="string"/>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:extrusion-origin" a:defaultValue="0.5 -0.5">
+            <list>
+                <ref name="double"/>
+                <ref name="double"/>
+            </list>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:extrusion-color" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:enhanced-path">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:path-stretchpoint-x" a:defaultValue="0">
+            <ref name="double"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="draw:path-stretchpoint-y" a:defaultValue="0">
+            <ref name="double"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:text-areas">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:glue-points">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:glue-point-type" a:defaultValue="none">
+            <choice>
+                <value>none</value>
+                <value>segments</value>
+                <value>rectangle</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:glue-point-leaving-directions"/>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:text-path" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:text-path-mode" a:defaultValue="normal">
+            <choice>
+                <value>normal</value>
+                <value>path</value>
+                <value>shape</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:text-path-scale" a:defaultValue="path">
+            <choice>
+                <value>path</value>
+                <value>shape</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:text-path-same-letter-heights"
+                   a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-enhanced-geometry-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:modifiers">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-equation">
+    <element name="draw:equation">
+        <ref name="draw-equation-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="draw-equation-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-equation-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:formula">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-handle">
+    <element name="draw:handle">
+        <ref name="draw-handle-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="draw-handle-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:handle-mirror-vertical" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-handle-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:handle-mirror-horizontal" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-handle-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:handle-switched" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-handle-attlist" combine="interleave">
+    <attribute name="draw:handle-position">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="draw-handle-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:handle-range-x-minimum">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-handle-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:handle-range-x-maximum">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-handle-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:handle-range-y-minimum">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-handle-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:handle-range-y-maximum">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-handle-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:handle-polar">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-handle-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:handle-radius-range-minimum">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-handle-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:handle-radius-range-maximum">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="presentation-shape-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:class">
+            <ref name="presentation-classes"/>
+        </attribute>
+    </optional>
+</define>
+<define name="presentation-classes">
+    <choice>
+        <value>title</value>
+        <value>outline</value>
+        <value>subtitle</value>
+        <value>text</value>
+        <value>graphic</value>
+        <value>object</value>
+        <value>chart</value>
+        <value>table</value>
+        <value>orgchart</value>
+        <value>page</value>
+        <value>notes</value>
+        <value>handout</value>
+        <value>header</value>
+        <value>footer</value>
+        <value>date-time</value>
+        <value>page-number</value>
+    </choice>
+</define>
+<define name="presentation-shape-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:placeholder">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="presentation-shape-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:user-transformed">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="presentation-animations">
+    <element name="presentation:animations">
+        <zeroOrMore>
+            <choice>
+                <ref name="presentation-animation-elements"/>
+                <ref name="presentation-animation-group"/>
+            </choice>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="presentation-animation-elements">
+    <choice>
+        <ref name="presentation-show-shape"/>
+        <ref name="presentation-show-text"/>
+        <ref name="presentation-hide-shape"/>
+        <ref name="presentation-hide-text"/>
+        <ref name="presentation-dim"/>
+        <ref name="presentation-play"/>
+    </choice>
+</define>
+<define name="presentation-sound">
+    <element name="presentation:sound">
+        <ref name="presentation-sound-attlist"/>
+        <attribute name="xlink:href">
+            <ref name="anyURI"/>
+        </attribute>
+        <optional>
+            <attribute name="xlink:type" a:defaultValue="simple">
+                <choice>
+                    <value>simple</value>
+                </choice>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="xlink:actuate" a:defaultValue="onRequest">
+                <choice>
+                    <value>onRequest</value>
+                </choice>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="xlink:show">
+                <choice>
+                    <value>new</value>
+                    <value>replace</value>
+                </choice>
+            </attribute>
+        </optional>
+        <empty/>
+    </element>
+</define>
+<define name="presentation-sound-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:play-full">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="presentation-show-shape">
+    <element name="presentation:show-shape">
+        <ref name="common-presentation-effect-attlist"/>
+        <optional>
+            <ref name="presentation-sound"/>
+        </optional>
+    </element>
+</define>
+<define name="common-presentation-effect-attlist" combine="interleave">
+    <attribute name="draw:shape-id">
+        <ref name="IDREF"/>
+    </attribute>
+</define>
+<define name="common-presentation-effect-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:effect" a:defaultValue="none">
+            <ref name="presentationEffects"/>
+        </attribute>
+    </optional>
+</define>
+<define name="presentationEffects">
+    <choice>
+        <value>none</value>
+        <value>fade</value>
+        <value>move</value>
+        <value>stripes</value>
+        <value>open</value>
+        <value>close</value>
+        <value>dissolve</value>
+        <value>wavyline</value>
+        <value>random</value>
+        <value>lines</value>
+        <value>laser</value>
+        <value>appear</value>
+        <value>hide</value>
+        <value>move-short</value>
+        <value>checkerboard</value>
+        <value>rotate</value>
+        <value>stretch</value>
+    </choice>
+</define>
+<define name="common-presentation-effect-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:direction" a:defaultValue="none">
+            <ref name="presentationEffectDirections"/>
+        </attribute>
+    </optional>
+</define>
+<define name="presentationEffectDirections">
+    <choice>
+        <value>none</value>
+        <value>from-left</value>
+        <value>from-top</value>
+        <value>from-right</value>
+        <value>from-bottom</value>
+        <value>from-center</value>
+        <value>from-upper-left</value>
+        <value>from-upper-right</value>
+        <value>from-lower-left</value>
+        <value>from-lower-right</value>
+        <value>to-left</value>
+        <value>to-top</value>
+        <value>to-right</value>
+        <value>to-bottom</value>
+        <value>to-upper-left</value>
+        <value>to-upper-right</value>
+        <value>to-lower-right</value>
+        <value>to-lower-left</value>
+        <value>path</value>
+        <value>spiral-inward-left</value>
+        <value>spiral-inward-right</value>
+        <value>spiral-outward-left</value>
+        <value>spiral-outward-right</value>
+        <value>vertical</value>
+        <value>horizontal</value>
+        <value>to-center</value>
+        <value>clockwise</value>
+        <value>counter-clockwise</value>
+    </choice>
+</define>
+<define name="common-presentation-effect-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:speed" a:defaultValue="medium">
+            <ref name="presentationSpeeds"/>
+        </attribute>
+    </optional>
+</define>
+<define name="presentationSpeeds">
+    <choice>
+        <value>slow</value>
+        <value>medium</value>
+        <value>fast</value>
+    </choice>
+</define>
+<define name="common-presentation-effect-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:delay">
+            <ref name="duration"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-presentation-effect-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:start-scale" a:defaultValue="100%">
+            <ref name="percent"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-presentation-effect-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:path-id"/>
+    </optional>
+</define>
+<define name="presentation-show-text">
+    <element name="presentation:show-text">
+        <ref name="common-presentation-effect-attlist"/>
+        <optional>
+            <ref name="presentation-sound"/>
+        </optional>
+    </element>
+</define>
+<define name="presentation-hide-shape">
+    <element name="presentation:hide-shape">
+        <ref name="common-presentation-effect-attlist"/>
+        <optional>
+            <ref name="presentation-sound"/>
+        </optional>
+    </element>
+</define>
+<define name="presentation-hide-text">
+    <element name="presentation:hide-text">
+        <ref name="common-presentation-effect-attlist"/>
+        <optional>
+            <ref name="presentation-sound"/>
+        </optional>
+    </element>
+</define>
+<define name="presentation-dim">
+    <element name="presentation:dim">
+        <ref name="presentation-dim-attlist"/>
+        <optional>
+            <ref name="presentation-sound"/>
+        </optional>
+    </element>
+</define>
+<define name="presentation-dim-attlist" combine="interleave">
+    <attribute name="draw:shape-id">
+        <ref name="IDREF"/>
+    </attribute>
+</define>
+<define name="presentation-dim-attlist" combine="interleave">
+    <attribute name="draw:color">
+        <ref name="color"/>
+    </attribute>
+</define>
+<define name="presentation-play">
+    <element name="presentation:play">
+        <ref name="presentation-play-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="presentation-play-attlist" combine="interleave">
+    <attribute name="draw:shape-id">
+        <ref name="IDREF"/>
+    </attribute>
+    <optional>
+        <attribute name="presentation:speed" a:defaultValue="medium">
+            <ref name="presentationSpeeds"/>
+        </attribute>
+    </optional>
+</define>
+<define name="presentation-animation-group">
+    <element name="presentation:animation-group">
+        <zeroOrMore>
+            <ref name="presentation-animation-elements"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="common-anim-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:node-type" a:defaultValue="default">
+            <choice>
+                <value>default</value>
+                <value>on-click</value>
+                <value>with-previous</value>
+                <value>after-previous</value>
+                <value>timing-root</value>
+                <value>main-sequence</value>
+                <value>interactive-sequence</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="common-anim-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:preset-id">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-anim-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:preset-sub-type">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-anim-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:preset-class" a:defaultValue="custom">
+            <choice>
+                <value>custom</value>
+                <value>entrance</value>
+                <value>exit</value>
+                <value>emphasis</value>
+                <value>motion-path</value>
+                <value>ole-action</value>
+                <value>media-call</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="common-anim-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:master-element">
+            <ref name="IDREF"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-anim-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:group-id">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="presentation-event-listener">
+    <element name="presentation:event-listener">
+        <ref name="presentation-event-listener-attlist"/>
+        <optional>
+            <ref name="presentation-sound"/>
+        </optional>
+    </element>
+</define>
+<define name="presentation-event-listener-attlist" combine="interleave">
+    <attribute name="script:event-name">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="presentation-event-listener-attlist" combine="interleave">
+    <attribute name="presentation:action">
+        <choice>
+            <value>none</value>
+            <value>previous-page</value>
+            <value>next-page</value>
+            <value>first-page</value>
+            <value>last-page</value>
+            <value>hide</value>
+            <value>stop</value>
+            <value>execute</value>
+            <value>show</value>
+            <value>verb</value>
+            <value>fade-out</value>
+            <value>sound</value>
+        </choice>
+    </attribute>
+</define>
+<define name="presentation-event-listener-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:effect" a:defaultValue="none">
+            <ref name="presentationEffects"/>
+        </attribute>
+    </optional>
+</define>
+<define name="presentation-event-listener-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:direction" a:defaultValue="none">
+            <ref name="presentationEffectDirections"/>
+        </attribute>
+    </optional>
+</define>
+<define name="presentation-event-listener-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:speed" a:defaultValue="medium">
+            <ref name="presentationSpeeds"/>
+        </attribute>
+    </optional>
+</define>
+<define name="presentation-event-listener-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:start-scale" a:defaultValue="100%">
+            <ref name="percent"/>
+        </attribute>
+    </optional>
+</define>
+<define name="presentation-event-listener-attlist" combine="interleave">
+    <optional>
+        <attribute name="xlink:href">
+            <ref name="anyURI"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="xlink:type" a:defaultValue="simple">
+            <choice>
+                <value>simple</value>
+            </choice>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="xlink:show" a:defaultValue="embed">
+            <choice>
+                <value>embed</value>
+            </choice>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="xlink:actuate" a:defaultValue="onRequest">
+            <choice>
+                <value>onRequest</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="presentation-event-listener-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:verb">
+            <ref name="nonNegativeInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="presentation:header">
+        <empty/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="presentation:footer">
+        <empty/>
+    </element>
+</define>
+<define name="paragraph-content" combine="choice">
+    <element name="presentation:date-time">
+        <empty/>
+    </element>
+</define>
+<define name="presentation-decls">
+    <zeroOrMore>
+        <ref name="presentation-decl"/>
+    </zeroOrMore>
+</define>
+<define name="presentation-decl" combine="choice">
+    <element name="presentation:header-decl">
+        <ref name="presentation-header-decl-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="presentation-header-decl-attlist" combine="interleave">
+    <attribute name="presentation:name">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="presentation-decl" combine="choice">
+    <element name="presentation:footer-decl">
+        <ref name="presentation-footer-decl-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="presentation-footer-decl-attlist" combine="interleave">
+    <attribute name="presentation:name">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="presentation-decl" combine="choice">
+    <element name="presentation:date-time-decl">
+        <ref name="presentation-date-time-decl-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="presentation-date-time-decl-attlist" combine="interleave">
+    <attribute name="presentation:name">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="presentation-date-time-decl-attlist" combine="interleave">
+    <attribute name="presentation:source">
+        <choice>
+            <value>fixed</value>
+            <value>current-date</value>
+        </choice>
+    </attribute>
+</define>
+<define name="presentation-date-time-decl-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:data-style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="presentation-settings">
+    <optional>
+        <element name="presentation:settings">
+            <ref name="presentation-settings-attlist"/>
+            <zeroOrMore>
+                <ref name="presentation-show"/>
+            </zeroOrMore>
+        </element>
+    </optional>
+</define>
+<define name="presentation-settings-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:start-page">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="presentation-settings-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:show">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="presentation-settings-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:full-screen" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="presentation-settings-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:endless" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="presentation-settings-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:pause">
+            <ref name="duration"/>
+        </attribute>
+    </optional>
+</define>
+<define name="presentation-settings-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:show-logo" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="presentation-settings-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:force-manual" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="presentation-settings-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:mouse-visible" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="presentation-settings-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:mouse-as-pen" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="presentation-settings-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:start-with-navigator"
+                   a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="presentation-settings-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:animations" a:defaultValue="enabled">
+            <choice>
+                <value>enabled</value>
+                <value>disabled</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="presentation-settings-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:transition-on-click"
+                   a:defaultValue="enabled">
+            <choice>
+                <value>enabled</value>
+                <value>disabled</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="presentation-settings-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:stay-on-top" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="presentation-settings-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:show-end-of-presentation-slide"
+                   a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="presentation-show">
+    <element name="presentation:show">
+        <ref name="presentation-show-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="presentation-show-attlist" combine="interleave">
+    <attribute name="presentation:name">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="presentation-show-attlist" combine="interleave">
+    <attribute name="presentation:pages"/>
+</define>
+<define name="chart-chart">
+    <element name="chart:chart">
+        <ref name="chart-chart-attlist"/>
+        <optional>
+            <ref name="chart-title"/>
+        </optional>
+        <optional>
+            <ref name="chart-subtitle"/>
+        </optional>
+        <optional>
+            <ref name="chart-footer"/>
+        </optional>
+        <optional>
+            <ref name="chart-legend"/>
+        </optional>
+        <ref name="chart-plot-area"/>
+        <optional>
+            <ref name="table-table"/>
+        </optional>
+    </element>
+</define>
+<define name="chart-chart-attlist" combine="interleave">
+    <attribute name="chart:class">
+        <ref name="namespacedToken"/>
+    </attribute>
+</define>
+<define name="chart-chart-attlist" combine="interleave">
+    <ref name="common-draw-size-attlist"/>
+</define>
+<define name="chart-chart-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:column-mapping">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="chart-chart-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:row-mapping">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="chart-chart-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="chart-title">
+    <element name="chart:title">
+        <ref name="chart-title-attlist"/>
+        <optional>
+            <ref name="text-p"/>
+        </optional>
+    </element>
+</define>
+<define name="chart-title-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:cell-range">
+            <ref name="cellAddress"/>
+        </attribute>
+    </optional>
+</define>
+<define name="chart-title-attlist" combine="interleave">
+    <ref name="common-draw-position-attlist"/>
+</define>
+<define name="chart-title-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="chart-subtitle">
+    <element name="chart:subtitle">
+        <ref name="chart-title-attlist"/>
+        <optional>
+            <ref name="text-p"/>
+        </optional>
+    </element>
+</define>
+<define name="chart-footer">
+    <element name="chart:footer">
+        <ref name="chart-title-attlist"/>
+        <optional>
+            <ref name="text-p"/>
+        </optional>
+    </element>
+</define>
+<define name="chart-legend">
+    <element name="chart:legend">
+        <ref name="chart-legend-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="chart-legend-attlist" combine="interleave">
+    <choice>
+        <group>
+            <attribute name="chart:legend-position">
+                <choice>
+                    <value>start</value>
+                    <value>end</value>
+                    <value>top</value>
+                    <value>bottom</value>
+                </choice>
+            </attribute>
+            <optional>
+                <attribute name="chart:legend-align">
+                    <choice>
+                        <value>start</value>
+                        <value>center</value>
+                        <value>end</value>
+                    </choice>
+                </attribute>
+            </optional>
+        </group>
+        <attribute name="chart:legend-position">
+            <choice>
+                <value>top-start</value>
+                <value>bottom-start</value>
+                <value>top-end</value>
+                <value>bottom-end</value>
+            </choice>
+        </attribute>
+        <empty/>
+    </choice>
+</define>
+<define name="chart-legend-attlist" combine="interleave">
+    <ref name="common-draw-position-attlist"/>
+</define>
+<define name="chart-legend-attlist" combine="interleave">
+    <choice>
+        <attribute name="style:legend-expansion">
+            <choice>
+                <value>wide</value>
+                <value>high</value>
+                <value>balanced</value>
+            </choice>
+        </attribute>
+        <group>
+            <attribute name="style:legend-expansion">
+                <value>custom</value>
+            </attribute>
+            <attribute name="style:legend-expansion-aspect-ratio">
+                <ref name="double"/>
+            </attribute>
+        </group>
+        <empty/>
+    </choice>
+</define>
+<define name="chart-legend-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="chart-plot-area">
+    <element name="chart:plot-area">
+        <ref name="chart-plot-area-attlist"/>
+        <zeroOrMore>
+            <ref name="dr3d-light"/>
+        </zeroOrMore>
+        <zeroOrMore>
+            <ref name="chart-axis"/>
+        </zeroOrMore>
+        <zeroOrMore>
+            <ref name="chart-series"/>
+        </zeroOrMore>
+        <optional>
+            <ref name="chart-stock-gain-marker"/>
+        </optional>
+        <optional>
+            <ref name="chart-stock-loss-marker"/>
+        </optional>
+        <optional>
+            <ref name="chart-stock-range-line"/>
+        </optional>
+        <optional>
+            <ref name="chart-wall"/>
+        </optional>
+        <optional>
+            <ref name="chart-floor"/>
+        </optional>
+    </element>
+</define>
+<define name="chart-plot-area-attlist" combine="interleave">
+    <ref name="common-draw-position-attlist"/>
+    <ref name="common-draw-size-attlist"/>
+</define>
+<define name="chart-plot-area-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="chart-plot-area-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:cell-range-address">
+            <ref name="cellRangeAddress"/>
+        </attribute>
+    </optional>
+</define>
+<define name="chart-plot-area-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:data-source-has-labels" a:defaultValue="none">
+            <choice>
+                <value>none</value>
+                <value>row</value>
+                <value>column</value>
+                <value>both</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="chart-plot-area-attlist" combine="interleave">
+    <ref name="dr3d-scene-attlist"/>
+    <ref name="common-dr3d-transform-attlist"/>
+</define>
+<define name="chart-wall">
+    <element name="chart:wall">
+        <ref name="chart-wall-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="chart-wall-attlist" combine="interleave">
+    <optional>
+        <attribute name="svg:width">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+</define>
+<define name="chart-wall-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="chart-floor">
+    <element name="chart:floor">
+        <ref name="chart-floor-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="chart-floor-attlist" combine="interleave">
+    <optional>
+        <attribute name="svg:width">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+</define>
+<define name="chart-floor-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="chart-axis">
+    <element name="chart:axis">
+        <ref name="chart-axis-attlist"/>
+        <optional>
+            <ref name="chart-title"/>
+        </optional>
+        <optional>
+            <ref name="chart-categories"/>
+        </optional>
+        <zeroOrMore>
+            <ref name="chart-grid"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="chart-axis-attlist" combine="interleave">
+    <attribute name="chart:dimension">
+        <choice>
+            <value>x</value>
+            <value>y</value>
+            <value>z</value>
+        </choice>
+    </attribute>
+</define>
+<define name="chart-axis-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="chart-axis-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="chart-grid">
+    <element name="chart:grid">
+        <ref name="chart-grid-attlist"/>
+    </element>
+</define>
+<define name="chart-grid-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:class" a:defaultValue="major">
+            <choice>
+                <value>major</value>
+                <value>minor</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="chart-grid-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="chart-series">
+    <element name="chart:series">
+        <ref name="chart-series-attlist"/>
+        <zeroOrMore>
+            <ref name="chart-domain"/>
+        </zeroOrMore>
+        <optional>
+            <ref name="chart-mean-value"/>
+        </optional>
+        <optional>
+            <ref name="chart-regression-curve"/>
+        </optional>
+        <optional>
+            <ref name="chart-error-indicator"/>
+        </optional>
+        <zeroOrMore>
+            <ref name="chart-data-point"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="chart-series-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:values-cell-range-address">
+            <ref name="cellRangeAddress"/>
+        </attribute>
+    </optional>
+</define>
+<define name="chart-series-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:label-cell-address">
+            <ref name="cellAddress"/>
+        </attribute>
+    </optional>
+</define>
+<define name="chart-series-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:class">
+            <ref name="namespacedToken"/>
+        </attribute>
+    </optional>
+</define>
+<define name="chart-series-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:attached-axis">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="chart-series-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="chart-domain">
+    <element name="chart:domain">
+    <optional>
+        <attribute name="table:cell-range-address">
+            <ref name="cellRangeAddress"/>
+        </attribute>
+    </optional>
+    </element>
+</define>
+<define name="chart-categories">
+    <element name="chart:categories">
+    <optional>
+        <attribute name="table:cell-range-address">
+            <ref name="cellRangeAddress"/>
+        </attribute>
+    </optional>
+    </element>
+</define>
+<define name="chart-data-point">
+    <element name="chart:data-point">
+        <ref name="chart-data-point-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="chart-data-point-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:repeated">
+            <ref name="nonNegativeInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="chart-data-point-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+
+<define name="chart-mean-value">
+    <element name="chart:mean-value">
+        <ref name="chart-mean-value-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="chart-mean-value-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="chart-error-indicator">
+    <element name="chart:error-indicator">
+        <ref name="chart-error-indicator-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="chart-error-indicator-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="chart-regression-curve">
+    <element name="chart:regression-curve">
+        <ref name="chart-regression-curve-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="chart-regression-curve-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="chart-stock-gain-marker">
+    <element name="chart:stock-gain-marker">
+        <ref name="common-stock-marker-attlist"/>
+    </element>
+</define>
+<define name="chart-stock-loss-marker">
+    <element name="chart:stock-loss-marker">
+        <ref name="common-stock-marker-attlist"/>
+    </element>
+</define>
+<define name="chart-stock-range-line">
+    <element name="chart:stock-range-line">
+        <ref name="common-stock-marker-attlist"/>
+    </element>
+</define>
+<define name="common-stock-marker-attlist">
+    <optional>
+        <attribute name="chart:style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="office-forms">
+    <optional>
+        <element name="office:forms">
+            <ref name="office-forms-attlist"/>
+            <zeroOrMore>
+                <choice>
+                    <ref name="form-form"/>
+                    <ref name="xforms-model"/>
+                </choice>
+            </zeroOrMore>
+        </element>
+    </optional>
+</define>
+<define name="office-forms-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:automatic-focus" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="office-forms-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:apply-design-mode" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-form">
+    <element name="form:form">
+        <ref name="common-form-control-attlist"/>
+        <ref name="form-form-attlist"/>
+        <optional>
+            <ref name="form-properties"/>
+        </optional>
+        <optional>
+            <ref name="office-event-listeners"/>
+        </optional>
+        <zeroOrMore>
+            <choice>
+                <ref name="controls"/>
+                <ref name="form-form"/>
+            </choice>
+        </zeroOrMore>
+        <optional>
+            <ref name="form-connection-resource"/>
+        </optional>
+    </element>
+</define>
+<define name="form-form-attlist" combine="interleave">
+    <optional>
+        <attribute name="xlink:href">
+            <ref name="anyURI"/>
+        </attribute>
+        <optional>
+            <attribute name="xlink:type" a:defaultValue="simple">
+                <value>simple</value>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="xlink:actuate" a:defaultValue="onRequest">
+                <value>onRequest</value>
+            </attribute>
+        </optional>
+    </optional>
+</define>
+<define name="form-form-attlist" combine="interleave">
+    <optional>
+        <attribute name="office:target-frame" a:defaultValue="_blank">
+            <ref name="targetFrameName"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-form-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:method" a:defaultValue="get">
+            <choice>
+                <value>get</value>
+                <value>post</value>
+                <ref name="string"/>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="form-form-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:enctype" 
+                    a:defaultValue="application/x-www-form-urlencoded">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-form-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:allow-deletes" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-form-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:allow-inserts" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-form-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:allow-updates" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-form-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:apply-filter" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-form-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:command-type" a:defaultValue="command">
+            <choice>
+                <value>table</value>
+                <value>query</value>
+                <value>command</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="form-form-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:command"/>
+    </optional>
+</define>
+<define name="form-form-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:datasource">
+            <choice>
+                <ref name="anyURI"/>
+                <ref name="string"/>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="form-form-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:master-fields">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-form-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:detail-fields">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-form-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:escape-processing" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-form-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:filter">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-form-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:ignore-result" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-form-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:navigation-mode">
+            <ref name="navigation"/>
+        </attribute>
+    </optional>
+</define>
+
+<define name="navigation">
+    <choice>
+        <value>none</value>
+        <value>current</value>
+        <value>parent</value>
+    </choice>
+</define>
+<define name="form-form-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:order">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-form-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:tab-cycle">
+            <ref name="tab-cycles"/>
+        </attribute>
+    </optional>
+</define>
+<define name="tab-cycles">
+    <choice>
+        <value>records</value>
+        <value>current</value>
+        <value>page</value>
+    </choice>
+</define>
+<define name="form-connection-resource">
+    <element name="form:connection-resource">
+        <attribute name="xlink:href">
+            <ref name="anyURI"/>
+        </attribute>
+        <empty/>
+    </element>
+</define>
+<define name="xforms-model">
+    <element name="xforms:model">
+        <ref name="anyAttListOrElements"/>
+    </element>
+</define>
+<define name="column-controls" combine="choice">
+    <element name="form:text">
+        <ref name="form-text-attlist"/>
+        <ref name="common-form-control-content"/>
+    </element>
+</define>
+<define name="controls" combine="choice">
+    <ref name="column-controls"/>
+</define>
+<define name="form-text-attlist">
+    <ref name="form-control-attlist"/>
+    <ref name="common-current-value-attlist"/>
+    <ref name="common-disabled-attlist"/>
+    <ref name="common-maxlength-attlist"/>
+    <ref name="common-printable-attlist"/>
+    <ref name="common-readonly-attlist"/>
+    <ref name="common-tab-attlist"/>
+    <ref name="common-title-attlist"/>
+    <ref name="common-value-attlist"/>
+    <ref name="common-convert-empty-attlist"/>
+    <ref name="common-data-field-attlist"/>
+</define>
+<define name="form-control-attlist">
+    <ref name="common-form-control-attlist"/>
+    <ref name="common-control-id-attlist"/>
+    <ref name="xforms-bind-attlist"/>
+</define>
+<define name="common-form-control-content">
+    <optional>
+        <ref name="form-properties"/>
+    </optional>
+    <optional>
+        <ref name="office-event-listeners"/>
+    </optional>
+</define>
+<define name="column-controls" combine="choice">
+    <element name="form:textarea">
+        <ref name="form-textarea-attlist"/>
+        <ref name="common-form-control-content"/>
+        <zeroOrMore>
+            <ref name="text-p"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="form-textarea-attlist">
+    <ref name="form-control-attlist"/>
+    <ref name="common-current-value-attlist"/>
+    <ref name="common-disabled-attlist"/>
+    <ref name="common-maxlength-attlist"/>
+    <ref name="common-printable-attlist"/>
+    <ref name="common-readonly-attlist"/>
+    <ref name="common-tab-attlist"/>
+    <ref name="common-title-attlist"/>
+    <ref name="common-value-attlist"/>
+    <ref name="common-convert-empty-attlist"/>
+    <ref name="common-data-field-attlist"/>
+</define>
+<define name="controls" combine="choice">
+    <element name="form:password">
+        <ref name="form-password-attlist"/>
+        <ref name="common-form-control-content"/>
+    </element>
+</define>
+<define name="form-password-attlist" combine="interleave">
+    <ref name="form-control-attlist"/>
+    <ref name="common-disabled-attlist"/>
+    <ref name="common-maxlength-attlist"/>
+    <ref name="common-printable-attlist"/>
+    <ref name="common-tab-attlist"/>
+    <ref name="common-title-attlist"/>
+    <ref name="common-value-attlist"/>
+    <ref name="common-convert-empty-attlist"/>
+</define>
+<define name="form-password-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:echo-char" a:defaultValue="*">
+            <ref name="character"/>
+        </attribute>
+    </optional>
+</define>
+<define name="controls" combine="choice">
+    <element name="form:file">
+        <ref name="form-file-attlist"/>
+        <ref name="common-form-control-content"/>
+    </element>
+</define>
+<define name="form-file-attlist" combine="interleave">
+    <ref name="form-control-attlist"/>
+    <ref name="common-current-value-attlist"/>
+    <ref name="common-disabled-attlist"/>
+    <ref name="common-maxlength-attlist"/>
+    <ref name="common-printable-attlist"/>
+    <ref name="common-readonly-attlist"/>
+    <ref name="common-tab-attlist"/>
+    <ref name="common-title-attlist"/>
+    <ref name="common-value-attlist"/>
+</define>
+<define name="column-controls" combine="choice">
+    <element name="form:formatted-text">
+        <ref name="form-formatted-text-attlist"/>
+        <ref name="common-form-control-content"/>
+    </element>
+</define>
+<define name="form-formatted-text-attlist" combine="interleave">
+    <ref name="form-control-attlist"/>
+    <ref name="common-current-value-attlist"/>
+    <ref name="common-disabled-attlist"/>
+    <ref name="common-maxlength-attlist"/>
+    <ref name="common-printable-attlist"/>
+    <ref name="common-readonly-attlist"/>
+    <ref name="common-tab-attlist"/>
+    <ref name="common-title-attlist"/>
+    <ref name="common-value-attlist"/>
+    <ref name="common-convert-empty-attlist"/>
+    <ref name="common-data-field-attlist"/>
+</define>
+<define name="form-formatted-text-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:max-value">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-formatted-text-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:min-value">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-formatted-text-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:validation" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="column-controls" combine="choice">
+    <element name="form:number">
+        <ref name="form-number-attlist"/>
+        <ref name="common-numeric-control-attlist"/>
+        <ref name="common-form-control-content"/>
+    </element>
+</define>
+<define name="common-numeric-control-attlist">
+    <ref name="form-control-attlist"/>
+    <ref name="common-disabled-attlist"/>
+    <ref name="common-maxlength-attlist"/>
+    <ref name="common-printable-attlist"/>
+    <ref name="common-readonly-attlist"/>
+    <ref name="common-tab-attlist"/>
+    <ref name="common-title-attlist"/>
+    <ref name="common-convert-empty-attlist"/>
+    <ref name="common-data-field-attlist"/>
+</define>
+<define name="form-number-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:value">
+            <ref name="double"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-number-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:current-value">
+            <ref name="double"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-number-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:min-value">
+            <ref name="double"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-number-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:max-value">
+            <ref name="double"/>
+        </attribute>
+    </optional>
+</define>
+<define name="column-controls" combine="choice">
+    <element name="form:date">
+        <ref name="form-date-attlist"/>
+        <ref name="common-numeric-control-attlist"/>
+        <ref name="common-form-control-content"/>
+    </element>
+</define>
+<define name="controls" combine="choice">
+    <element name="form:time">
+        <ref name="form-time-attlist"/>
+        <ref name="common-numeric-control-attlist"/>
+        <ref name="common-form-control-content"/>
+    </element>
+</define>
+<define name="form-date-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:value">
+            <ref name="date"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-time-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:value">
+            <ref name="time"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-date-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:current-value">
+            <ref name="date"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-time-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:current-value">
+            <ref name="time"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-date-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:min-value">
+            <ref name="date"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-time-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:min-value">
+            <ref name="time"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-date-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:max-value">
+            <ref name="date"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-time-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:max-value">
+            <ref name="time"/>
+        </attribute>
+    </optional>
+</define>
+<define name="controls" combine="choice">
+    <element name="form:fixed-text">
+        <ref name="form-fixed-text-attlist"/>
+        <ref name="common-form-control-content"/>
+    </element>
+</define>
+<define name="form-fixed-text-attlist" combine="interleave">
+    <ref name="form-control-attlist"/>
+    <ref name="for"/>
+    <ref name="common-disabled-attlist"/>
+    <ref name="label"/>
+    <ref name="common-printable-attlist"/>
+    <ref name="common-title-attlist"/>
+</define>
+<define name="form-fixed-text-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:multi-line" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="column-controls" combine="choice">
+    <element name="form:combobox">
+        <ref name="form-combobox-attlist"/>
+        <ref name="common-form-control-content"/>
+        <zeroOrMore>
+            <ref name="form-item"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="form-combobox-attlist" combine="interleave">
+    <ref name="form-control-attlist"/>
+    <ref name="common-current-value-attlist"/>
+    <ref name="common-disabled-attlist"/>
+    <ref name="dropdown"/>
+    <ref name="common-maxlength-attlist"/>
+    <ref name="common-printable-attlist"/>
+    <ref name="common-readonly-attlist"/>
+    <ref name="size"/>
+    <ref name="common-tab-attlist"/>
+    <ref name="common-title-attlist"/>
+    <ref name="common-value-attlist"/>
+    <ref name="common-convert-empty-attlist"/>
+    <ref name="common-data-field-attlist"/>
+    <ref name="list-source"/>
+    <ref name="list-source-type"/>
+</define>
+<define name="form-combobox-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:auto-complete">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-item">
+    <element name="form:item">
+        <ref name="form-item-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="form-item-attlist" combine="interleave">
+    <ref name="label"/>
+</define>
+<define name="column-controls" combine="choice">
+    <element name="form:listbox">
+        <ref name="form-listbox-attlist"/>
+        <ref name="common-form-control-content"/>
+        <zeroOrMore>
+            <ref name="form-option"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="form-listbox-attlist" combine="interleave">
+    <ref name="form-control-attlist"/>
+    <ref name="common-disabled-attlist"/>
+    <ref name="dropdown"/>
+    <ref name="common-printable-attlist"/>
+    <ref name="size"/>
+    <ref name="common-tab-attlist"/>
+    <ref name="common-title-attlist"/>
+    <ref name="bound-column"/>
+    <ref name="common-data-field-attlist"/>
+    <ref name="list-source"/>
+    <ref name="list-source-type"/>
+</define>
+<define name="form-listbox-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:multiple" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-listbox-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:xforms-list-source">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-option">
+    <element name="form:option">
+        <ref name="form-option-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="form-option-attlist" combine="interleave">
+    <ref name="current-selected"/>
+    <ref name="selected"/>
+    <ref name="label"/>
+    <ref name="common-value-attlist"/>
+</define>
+<define name="controls" combine="choice">
+    <element name="form:button">
+        <ref name="form-button-attlist"/>
+        <ref name="common-form-control-content"/>
+    </element>
+</define>
+<define name="form-button-attlist" combine="interleave">
+    <ref name="form-control-attlist"/>
+    <ref name="button-type"/>
+    <ref name="common-disabled-attlist"/>
+    <ref name="label"/>
+    <ref name="image-data"/>
+    <ref name="common-printable-attlist"/>
+    <ref name="common-tab-attlist"/>
+    <ref name="target-frame"/>
+    <ref name="target-location"/>
+    <ref name="common-title-attlist"/>
+    <ref name="common-value-attlist"/>
+    <ref name="common-form-relative-image-position-attlist"/>
+</define>
+<define name="form-button-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:default-button" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-button-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:toggle" a:default-value="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-button-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:focus-on-click">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-button-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:xforms-submission">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="controls" combine="choice">
+    <element name="form:image">
+        <ref name="form-image-attlist"/>
+        <ref name="common-form-control-content"/>
+    </element>
+</define>
+<define name="form-image-attlist" combine="interleave">
+    <ref name="form-control-attlist"/>
+    <ref name="button-type"/>
+    <ref name="common-disabled-attlist"/>
+    <ref name="image-data"/>
+    <ref name="common-printable-attlist"/>
+    <ref name="common-tab-attlist"/>
+    <ref name="target-frame"/>
+    <ref name="target-location"/>
+    <ref name="common-title-attlist"/>
+    <ref name="common-value-attlist"/>
+</define>
+<define name="column-controls" combine="choice">
+    <element name="form:checkbox">
+        <ref name="form-checkbox-attlist"/>
+        <ref name="common-form-control-content"/>
+    </element>
+</define>
+<define name="form-checkbox-attlist" combine="interleave">
+    <ref name="form-control-attlist"/>
+    <ref name="common-disabled-attlist"/>
+    <ref name="label"/>
+    <ref name="common-printable-attlist"/>
+    <ref name="common-tab-attlist"/>
+    <ref name="common-title-attlist"/>
+    <ref name="common-value-attlist"/>
+    <ref name="common-data-field-attlist"/>
+    <ref name="common-form-visual-effect-attlist"/>
+    <ref name="common-form-relative-image-position-attlist"/>
+</define>
+<define name="states">
+    <choice>
+        <value>unchecked</value>
+        <value>checked</value>
+        <value>unknown</value>
+    </choice>
+</define>
+<define name="form-checkbox-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:current-state">
+            <ref name="states"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-checkbox-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:is-tristate" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-checkbox-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:state" a:defaultValue="unchecked">
+            <ref name="states"/>
+        </attribute>
+    </optional>
+</define>
+<define name="controls" combine="choice">
+    <element name="form:radio">
+        <ref name="form-radio-attlist"/>
+        <ref name="common-form-control-content"/>
+    </element>
+</define>
+<define name="form-radio-attlist" combine="interleave">
+    <ref name="form-control-attlist"/>
+    <ref name="current-selected"/>
+    <ref name="common-disabled-attlist"/>
+    <ref name="label"/>
+    <ref name="common-printable-attlist"/>
+    <ref name="selected"/>
+    <ref name="common-tab-attlist"/>
+    <ref name="common-title-attlist"/>
+    <ref name="common-value-attlist"/>
+    <ref name="common-data-field-attlist"/>
+    <ref name="common-form-visual-effect-attlist"/>
+    <ref name="common-form-relative-image-position-attlist"/>
+</define>
+<define name="controls" combine="choice">
+    <element name="form:frame">
+        <ref name="form-frame-attlist"/>
+        <ref name="common-form-control-content"/>
+    </element>
+</define>
+<define name="form-frame-attlist" combine="interleave">
+    <ref name="form-control-attlist"/>
+    <ref name="common-disabled-attlist"/>
+    <ref name="for"/>
+    <ref name="label"/>
+    <ref name="common-printable-attlist"/>
+    <ref name="common-title-attlist"/>
+</define>
+<define name="controls" combine="choice">
+    <element name="form:image-frame">
+        <ref name="form-image-frame-attlist"/>
+        <ref name="common-form-control-content"/>
+    </element>
+</define>
+<define name="form-image-frame-attlist" combine="interleave">
+    <ref name="form-control-attlist"/>
+    <ref name="common-disabled-attlist"/>
+    <ref name="image-data"/>
+    <ref name="common-printable-attlist"/>
+    <ref name="common-readonly-attlist"/>
+    <ref name="common-title-attlist"/>
+    <ref name="common-data-field-attlist"/>
+</define>
+<define name="controls" combine="choice">
+    <element name="form:hidden">
+        <ref name="form-hidden-attlist"/>
+        <ref name="common-form-control-content"/>
+    </element>
+</define>
+<define name="form-hidden-attlist" combine="interleave">
+    <ref name="form-control-attlist"/>
+    <ref name="common-value-attlist"/>
+</define>
+<define name="controls" combine="choice">
+    <element name="form:grid">
+        <ref name="form-grid-attlist"/>
+        <ref name="common-form-control-content"/>
+        <zeroOrMore>
+            <ref name="form-column"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="form-grid-attlist" combine="interleave">
+    <ref name="form-control-attlist"/>
+    <ref name="common-disabled-attlist"/>
+    <ref name="common-printable-attlist"/>
+    <ref name="common-tab-attlist"/>
+    <ref name="common-title-attlist"/>
+</define>
+<define name="form-column">
+    <element name="form:column">
+        <ref name="form-column-attlist"/>
+        <oneOrMore>
+            <ref name="column-controls"/>
+        </oneOrMore>
+    </element>
+</define>
+<define name="form-column-attlist" combine="interleave">
+    <ref name="common-form-control-attlist"/>
+    <ref name="label"/>
+    <ref name="text-style-name"/>
+</define>
+<define name="text-style-name">
+    <optional>
+        <attribute name="form:text-style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="controls" combine="choice">
+    <element name="form:value-range">
+        <ref name="form-value-range-attlist"/>
+        <ref name="common-form-control-content"/>
+    </element>
+</define>
+<define name="form-value-range-attlist" combine="interleave">
+    <ref name="form-control-attlist"/>
+    <ref name="common-disabled-attlist"/>
+    <ref name="common-printable-attlist"/>
+    <ref name="common-tab-attlist"/>
+    <ref name="common-title-attlist"/>
+    <ref name="common-value-attlist"/>
+</define>
+<define name="form-value-range-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:max-value">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-value-range-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:min-value">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-value-range-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:step-size" a:defaultName="1">
+            <ref name="positiveInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-value-range-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:page-step-size">
+            <ref name="positiveInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-value-range-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:delay-for-repeat">
+            <ref name="duration"/>
+        </attribute>
+    </optional>
+</define>
+<define name="form-value-range-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:orientation">
+            <choice>
+                <value>horizontal</value>
+                <value>vertical</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="controls" combine="choice">
+    <element name="form:generic-control">
+        <ref name="form-generic-control-attlist"/>
+        <ref name="common-form-control-content"/>
+    </element>
+</define>
+<define name="form-generic-control-attlist" combine="interleave">
+    <ref name="form-control-attlist"/>
+</define>
+<define name="common-form-control-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-form-control-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:control-implementation">
+            <ref name="namespacedToken"/>
+        </attribute>
+    </optional>
+</define>
+<define name="xforms-bind-attlist">
+    <optional>
+        <attribute name="xforms:bind">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="types">
+    <choice>
+        <value>submit</value>
+        <value>reset</value>
+        <value>push</value>
+        <value>url</value>
+    </choice>
+</define>
+<define name="button-type">
+    <optional>
+        <attribute name="form:button-type" a:defaultValue="push">
+            <ref name="types"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-control-id-attlist">
+    <attribute name="form:id">
+        <ref name="ID"/>
+    </attribute>
+</define>
+<define name="current-selected">
+    <optional>
+        <attribute name="form:current-selected" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-value-attlist">
+    <optional>
+        <attribute name="form:value">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-current-value-attlist">
+    <optional>
+        <attribute name="form:current-value">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-disabled-attlist">
+    <optional>
+        <attribute name="form:disabled" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="dropdown">
+    <optional>
+        <attribute name="form:dropdown" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="for">
+    <optional>
+        <attribute name="form:for">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="image-data">
+    <optional>
+        <attribute name="form:image-data">
+            <ref name="anyURI"/>
+        </attribute>
+    </optional>
+</define>
+<define name="label">
+    <optional>
+        <attribute name="form:label">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-maxlength-attlist">
+    <optional>
+        <attribute name="form:max-length">
+            <ref name="nonNegativeInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-printable-attlist">
+    <optional>
+        <attribute name="form:printable" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-readonly-attlist">
+    <optional>
+        <attribute name="form:readonly" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="selected">
+    <optional>
+        <attribute name="form:selected" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="size">
+    <optional>
+        <attribute name="form:size">
+            <ref name="nonNegativeInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-tab-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:tab-index" a:defaultValue="0">
+            <ref name="nonNegativeInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-tab-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:tab-stop" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="target-frame">
+    <optional>
+        <attribute name="office:target-frame" a:defaultValue="_blank">
+            <ref name="targetFrameName"/>
+        </attribute>
+    </optional>
+</define>
+<define name="target-location">
+    <optional>
+        <attribute name="xlink:href">
+            <ref name="anyURI"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-title-attlist">
+    <optional>
+        <attribute name="form:title"/>
+    </optional>
+</define>
+<define name="common-form-visual-effect-attlist" combine="interleave">
+    <optional>
+        <attribute name="form:visual-effect">
+            <choice>
+                <value>flat</value>
+                <value>3d</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="common-form-relative-image-position-attlist"
+        combine="interleave">
+    <choice>
+        <optional>
+            <attribute name="form:image-position" a:defaultValue="center">
+                <value>center</value>
+            </attribute>
+        </optional>
+        <group>
+            <attribute name="form:image-position">
+                <choice>
+                    <value>start</value>
+                    <value>end</value>
+                    <value>top</value>
+                    <value>bottom</value>
+                </choice>
+            </attribute>
+            <optional>
+                <attribute name="form:image-align" a:defaultValue="center">
+                    <choice>
+                        <value>start</value>
+                        <value>center</value>
+                        <value>end</value>
+                    </choice>
+                </attribute>
+            </optional>
+        </group>
+    </choice>
+</define>
+<define name="bound-column">
+    <optional>
+        <attribute name="form:bound-column">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-convert-empty-attlist">
+    <optional>
+        <attribute name="form:convert-empty-to-null" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-data-field-attlist">
+    <optional>
+        <attribute name="form:data-field">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="list-source">
+    <optional>
+        <attribute name="form:list-source">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="list-source-type">
+    <optional>
+        <attribute name="form:list-source-type">
+            <choice>
+                <value>table</value>
+                <value>query</value>
+                <value>sql</value>
+                <value>sql-pass-through</value>
+                <value>value-list</value>
+                <value>table-fields</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="form-properties">
+    <element name="form:properties">
+        <oneOrMore>
+            <ref name="form-property"/>
+        </oneOrMore>
+    </element>
+</define>
+<define name="form-property" combine="choice">
+    <element name="form:property">
+        <ref name="form-property-name"/>
+        <ref name="form-property-value-and-type-attlist"/>
+    </element>
+</define>
+<define name="form-property-name" combine="interleave">
+    <attribute name="form:property-name">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="form-property-value-and-type-attlist" combine="interleave">
+    <choice>
+        <ref name="common-value-and-type-attlist"/>
+        <attribute name="office:value-type">
+            <value>void</value>
+        </attribute>
+    </choice>
+</define>
+<define name="form-property" combine="choice">
+    <element name="form:list-property">
+        <ref name="form-property-name"/>
+        <ref name="form-property-type-and-value-list"/>
+    </element>
+</define>
+<define name="form-property-type-and-value-list">
+    <choice>
+        <group>
+            <attribute name="office:value-type">
+                <value>float</value>
+            </attribute>
+            <zeroOrMore>
+                <element name="form:list-value">
+                    <attribute name="office:value">
+                        <ref name="double"/>
+                    </attribute>
+                </element>
+            </zeroOrMore>
+        </group>
+        <group>
+            <attribute name="office:value-type">
+                <value>percentage</value>
+            </attribute>
+            <zeroOrMore>
+                <element name="form:list-value">
+                    <attribute name="office:value">
+                        <ref name="double"/>
+                    </attribute>
+                </element>
+            </zeroOrMore>
+        </group>
+        <group>
+            <attribute name="office:value-type">
+                <value>currency</value>
+            </attribute>
+            <zeroOrMore>
+                <element name="form:list-value">
+                    <attribute name="office:value">
+                        <ref name="double"/>
+                    </attribute>
+                    <optional>
+                        <attribute name="office:currency">
+                            <ref name="string"/>
+                        </attribute>
+                    </optional>
+                </element>
+            </zeroOrMore>
+        </group>
+        <group>
+            <attribute name="office:value-type">
+                <value>date</value>
+            </attribute>
+            <zeroOrMore>
+                <element name="form:list-value">
+                    <attribute name="office:date-value">
+                        <ref name="dateOrDateTime"/>
+                    </attribute>
+                </element>
+            </zeroOrMore>
+        </group>
+        <group>
+            <attribute name="office:value-type">
+                <value>time</value>
+            </attribute>
+            <zeroOrMore>
+                <element name="form:list-value">
+                    <attribute name="office:time-value">
+                        <ref name="duration"/>
+                    </attribute>
+                </element>
+            </zeroOrMore>
+        </group>
+        <group>
+            <attribute name="office:value-type">
+                <value>boolean</value>
+            </attribute>
+            <zeroOrMore>
+                <element name="form:list-value">
+                    <attribute name="office:boolean-value">
+                        <ref name="boolean"/>
+                    </attribute>
+                </element>
+            </zeroOrMore>
+        </group>
+        <group>
+            <attribute name="office:value-type">
+                <value>string</value>
+            </attribute>
+            <zeroOrMore>
+                <element name="form:list-value">
+                    <attribute name="office:string-value">
+                        <ref name="string"/>
+                    </attribute>
+                </element>
+            </zeroOrMore>
+        </group>
+        <attribute name="office:value-type">
+            <value>void</value>
+        </attribute>
+    </choice>
+</define>
+<define name="office-annotation">
+    <element name="office:annotation">
+        <ref name="office-annotation-attlist"/>
+        <ref name="draw-caption-attlist"/>
+        <ref name="common-draw-position-attlist"/>
+        <ref name="common-draw-size-attlist"/>
+        <ref name="common-draw-shape-with-text-and-styles-attlist"/>
+        <optional>
+            <ref name="dc-creator"/>
+        </optional>
+        <optional>
+            <ref name="dc-date"/>
+        </optional>
+        <optional>
+            <ref name="meta-date-string"/>
+        </optional>
+        <zeroOrMore>
+            <choice>
+                <ref name="text-p"/>
+                <ref name="text-list"/>
+            </choice>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="office-annotation-attlist" combine="interleave">
+    <optional>
+        <attribute name="office:display">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="meta-date-string">
+    <element name="meta:date-string">
+        <ref name="string"/>
+    </element>
+</define>
+<define name="common-num-format-prefix-suffix-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:num-prefix">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:num-suffix">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-num-format-attlist" combine="interleave">
+    <choice>
+        <attribute name="style:num-format">
+            <choice>
+                <value>1</value>
+                <value>i</value>
+                <value>I</value>
+                <ref name="string"/>
+                <empty/>
+            </choice>
+        </attribute>
+        <group>
+            <attribute name="style:num-format">
+                <choice>
+                    <value>a</value>
+                    <value>A</value>
+                </choice>
+            </attribute>
+            <ref name="style-num-letter-sync-attlist"/>
+        </group>
+        <empty/>
+    </choice>
+</define>
+<define name="style-num-letter-sync-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:num-letter-sync">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="office-change-info">
+    <element name="office:change-info">
+        <ref name="dc-creator"/>
+        <ref name="dc-date"/>
+        <zeroOrMore>
+            <ref name="text-p"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="office-event-listeners">
+    <element name="office:event-listeners">
+        <zeroOrMore>
+            <choice>
+                <ref name="script-event-listener"/>
+                <ref name="presentation-event-listener"/>
+            </choice>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="script-event-listener" combine="interleave">
+    <element name="script:event-listener">
+        <ref name="script-event-listener-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="script-event-listener-attlist" combine="interleave">
+    <attribute name="script:event-name">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="script-event-listener-attlist" combine="interleave">
+    <attribute name="script:language">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="script-event-listener-attlist" combine="interleave">
+    <choice>
+        <attribute name="script:macro-name">
+            <ref name="string"/>
+        </attribute>
+        <group>
+            <attribute name="xlink:href">
+                <ref name="anyURI"/>
+            </attribute>
+            <optional>
+                <attribute name="xlink:type" a:defaultValue="simple">
+                    <value>simple</value>
+                </attribute>
+            </optional>
+            <optional>
+                <attribute name="xlink:actuate" a:defaultValue="onRequest">
+                    <value>onRequest</value>
+                </attribute>
+            </optional>
+        </group>
+    </choice>
+</define>
+<define name="math-math">
+    <element name="math:math">
+        <ref name="mathMarkup"/>
+    </element>
+</define>
+
+<!-- To avoid inclusion of the complete MathML schema, anything -->
+<!-- is allowed within a math:math top-level element            -->
+<define name="mathMarkup">
+    <zeroOrMore>
+        <choice>
+            <attribute>
+                <anyName/>
+            </attribute>
+            <text/>
+            <element>
+                <anyName/>
+                <ref name="mathMarkup"/>
+            </element>
+        </choice>
+    </zeroOrMore>
+</define>
+<define name="text-dde-connection-decl">
+    <element name="text:dde-connection-decl">
+        <ref name="text-dde-connection-decl-attlist"/>
+        <ref name="common-dde-connection-decl-attlist"/>
+    </element>
+</define>
+<define name="text-dde-connection-decl-attlist" combine="interleave">
+    <attribute name="office:name">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="common-dde-connection-decl-attlist" combine="interleave">
+    <attribute name="office:dde-application">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="common-dde-connection-decl-attlist" combine="interleave">
+    <attribute name="office:dde-topic">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="common-dde-connection-decl-attlist" combine="interleave">
+    <attribute name="office:dde-item">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="common-dde-connection-decl-attlist" combine="interleave">
+    <optional>
+        <attribute name="office:automatic-update" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-dde-link">
+    <element name="table:dde-link">
+        <ref name="office-dde-source"/>
+        <ref name="table-table"/>
+    </element>
+</define>
+<define name="office-dde-source">
+    <element name="office:dde-source">
+        <ref name="office-dde-source-attlist"/>
+        <ref name="common-dde-connection-decl-attlist"/>
+    </element>
+</define>
+<define name="office-dde-source-attlist" combine="interleave">
+    <optional>
+        <attribute name="office:name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="office-dde-source-attlist" combine="interleave">
+    <optional>
+        <attribute name="office:conversion-mode" 
+                    a:defaultValue="into-default-style-data-style">
+            <choice>
+                <value>into-default-style-data-style</value>
+                <value>into-english-number</value>
+                <value>keep-text</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="animation-element" combine="choice">
+    <element name="anim:animate">
+        <ref name="common-anim-target-attlist"/>
+        <ref name="common-anim-named-target-attlist"/>
+        <ref name="common-anim-values-attlist"/>
+        <ref name="common-anim-spline-mode-attlist"/>
+        <ref name="common-spline-anim-value-attlist"/>
+        <ref name="common-timing-attlist"/>
+        <ref name="common-anim-add-accum-attlist"/>
+    </element>
+</define>
+<define name="animation-element" combine="choice">
+    <element name="anim:set">
+        <ref name="common-anim-target-attlist"/>
+        <ref name="common-anim-named-target-attlist"/>
+        <ref name="common-anim-set-values-attlist"/>
+        <ref name="common-timing-attlist"/>
+        <ref name="common-anim-add-accum-attlist"/>
+    </element>
+</define>
+<define name="animation-element" combine="choice">
+    <element name="anim:animateMotion">
+        <ref name="anim-animate-motion-attlist"/>
+        <ref name="common-anim-target-attlist"/>
+        <ref name="common-anim-named-target-attlist"/>
+        <ref name="common-anim-add-accum-attlist"/>
+        <ref name="common-anim-values-attlist"/>
+        <ref name="common-timing-attlist"/>
+        <ref name="common-spline-anim-value-attlist"/>
+    </element>
+</define>
+<define name="anim-animate-motion-attlist" combine="interleave">
+    <optional>
+        <attribute name="svg:path">
+            <ref name="pathData"/>
+        </attribute>
+    </optional>
+</define>
+<define name="anim-animate-motion-attlist" combine="interleave">
+    <optional>
+        <attribute name="svg:origin">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="anim-animate-motion-attlist" combine="interleave">
+    <optional>
+        <attribute name="smil:calcMode" a:defaultValue="paced">   
+            <choice>
+                <value>discrete</value>
+                <value>linear</value>
+                <value>paced</value>
+                <value>spline</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="animation-element" combine="choice">
+    <element name="anim:animateColor">
+        <ref name="common-anim-target-attlist"/>
+        <ref name="common-anim-named-target-attlist"/>
+        <ref name="common-anim-add-accum-attlist"/>
+        <ref name="common-anim-values-attlist"/>
+        <ref name="common-anim-spline-mode-attlist"/>
+        <ref name="common-spline-anim-value-attlist"/>
+        <ref name="anim-animate-color-attlist"/>
+        <ref name="common-timing-attlist"/>
+    </element>
+</define>
+<define name="anim-animate-color-attlist" combine="interleave">
+    <optional>
+        <attribute name="anim:color-interpolation" a:defaultValue="rgb">
+            <choice>
+                <value>rgb</value>
+                <value>hsl</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="anim-animate-color-attlist" combine="interleave">
+    <optional>
+        <attribute name="anim:color-interpolation-direction"     
+                                   a:defaultValue="clockwise">
+            <choice>
+                <value>clockwise</value>
+                <value>counter-clockwise</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="animation-element" combine="choice">
+    <element name="anim:animateTransform">
+        <ref name="common-anim-target-attlist"/>
+        <ref name="common-anim-named-target-attlist"/>
+        <ref name="common-anim-add-accum-attlist"/>
+        <ref name="common-anim-values-attlist"/>
+        <ref name="anim-animate-transform-attlist"/>
+        <ref name="common-timing-attlist"/>
+    </element>
+</define>
+<define name="anim-animate-transform-attlist" combine="interleave">
+    <attribute name="svg:type">
+        <choice>
+            <value>translate</value>
+            <value>scale</value>
+            <value>rotate</value>
+            <value>skewX</value>
+            <value>skewY</value> 
+        </choice>
+    </attribute>
+</define>
+<define name="animation-element" combine="choice">
+    <element name="anim:transitionFilter">
+        <ref name="common-anim-target-attlist"/>
+        <ref name="common-anim-add-accum-attlist"/>
+        <ref name="common-anim-values-attlist"/>
+        <ref name="common-anim-spline-mode-attlist "/>
+        <ref name="anim-transition-filter-attlist"/>
+        <ref name="common-timing-attlist"/>
+    </element>
+</define>
+<define name="anim-transition-filter-attlist" combine="interleave">
+    <attribute name="smil:type">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="anim-transition-filter-attlist" combine="interleave">
+    <optional>
+        <attribute name="smil:subtype">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="anim-transition-filter-attlist" combine="interleave">
+    <optional>
+        <attribute name="smil:direction" a:defaultValue="forward">
+            <choice>
+                <value>forward</value>
+                <value>reverse</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="anim-transition-filter-attlist" combine="interleave">
+    <optional>
+        <attribute name="smil:fadeColor">
+            <choice>
+                <value>forward</value>
+                <value>reverse</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="anim-transition-filter-attlist" combine="interleave">
+    <optional>
+        <attribute name="smil:mode" a:defaultValue="in">
+            <choice>
+                <value>in</value>
+                <value>out</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="common-anim-attlist" combine="interleave">
+    <optional>
+        <attribute name="anim:id">
+            <ref name="ID"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-anim-target-attlist" combine="interleave">
+    <optional>
+        <attribute name="smil:targetElement">
+            <ref name="IDREF"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-anim-named-target-attlist" combine="interleave">
+    <attribute name="smil:attributeName">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="common-anim-target-attlist" combine="interleave">
+    <optional>
+        <attribute name="anim:sub-item">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-anim-values-attlist" combine="interleave">
+    <optional>
+        <attribute name="smil:values">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-anim-spline-mode-attlist" combine="interleave">
+    <optional>
+        <attribute name="smil:calcMode" a:defaultValue="discrete">   
+            <choice>
+                <value>discrete</value>
+                <value>linear</value>
+                <value>paced</value>
+                <value>spline</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="common-spline-anim-value-attlist" combine="interleave">
+    <optional>
+        <attribute name="smil:keyTimes">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-spline-anim-value-attlist" combine="interleave">
+    <optional>
+        <attribute name="smil:keySplines">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-anim-add-accum-attlist" combine="interleave">
+    <optional>
+        <attribute name="smil:accumulate">
+            <choice>
+                <value>none</value>
+                <value>sum</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="common-anim-add-accum-attlist" combine="interleave">
+    <optional>
+        <attribute name="smil:additive">
+            <choice>
+                <value>replace</value>
+                <value>sum</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="common-anim-values-attlist" combine="interleave">
+    <optional>
+        <attribute name="anim:formula">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-anim-set-values-attlist" combine="interleave">
+    <optional>
+        <attribute name="smil:to">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+
+<define name="common-anim-values-attlist" combine="interleave">
+    <ref name="common-anim-set-values-attlist"/>
+    <optional>
+        <attribute name="smil:from">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="smil:by">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-begin-end-timing-attlist" combine="interleave">
+    <optional>
+        <attribute name="smil:begin">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-begin-end-timing-attlist" combine="interleave">
+    <optional>
+        <attribute name="smil:end">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-dur-timing-attlist" combine="interleave">
+    <optional>
+        <attribute name="smil:dur">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-endsync-timing-attlist" combine="interleave">
+    <optional>
+        <attribute name="smil:endsync">
+            <choice>
+                <value>first</value>
+                <value>last</value>
+                <value>all</value>
+                <value>media</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="common-repeat-timing-attlist" combine="interleave">
+    <optional>
+        <attribute name="smil:repeatDur">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="smil:repeatCount">
+            <choice>
+                <ref name="nonNegativeInteger"/>
+                <value>indefinite</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="common-fill-timing-attlist" combine="interleave">
+    <optional>
+        <attribute name="smil:fill">
+            <choice>
+                <value>remove</value>
+                <value>freeze</value>
+                <value>hold</value>
+                <value>auto</value>
+                <value>default</value>
+                <value>transition</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="common-fill-default-attlist" combine="interleave">
+    <optional>
+        <attribute name="smil:fillDefault">
+            <choice>
+                <value>remove</value>
+                <value>freeze</value>
+                <value>hold</value>
+                <value>transition</value>
+                <value>auto</value>
+                <value>inherit</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="common-restart-timing-attlist" combine="interleave">
+    <optional>
+        <attribute name="smil:restart" a:defaultValue="default">
+            <choice>
+                <value>never</value>
+                <value>always</value>
+                <value>whenNotActive</value>
+                <value>default</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="common-restart-default-attlist" combine="interleave">
+    <optional>
+        <attribute name="smil:restartDefault" a:defaultValue="inherit">
+            <choice>
+                <value>never</value>
+                <value>always</value>
+                <value>whenNotActive</value>
+                <value>inherit</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="common-time-manip-attlist" combine="interleave">
+    <optional>    
+        <attribute name="smil:accelerate" a:defaultValue="0.0">
+            <ref name="double"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-time-manip-attlist" combine="interleave">
+    <optional>
+        <attribute name="smil:decelerate" a:defaultValue="0.0">
+            <ref name="double"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-time-manip-attlist" combine="interleave">
+    <optional>
+        <attribute name="smil:autoReverse" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="animation-element" combine="choice">
+    <element name="anim:par">
+        <ref name="common-anim-attlist"/>
+        <ref name="common-timing-attlist"/>
+        <ref name="common-endsync-timing-attlist"/>
+        <zeroOrMore>
+            <ref name="animation-element"/>
+        </zeroOrMore>
+    </element>
+</define>
+
+<define name="common-basic-timing-attlist" combine="interleave">
+   <ref name="common-begin-end-timing-attlist"/>
+   <ref name="common-dur-timing-attlist"/>
+   <ref name="common-repeat-timing-attlist"/>
+</define>
+
+<define name="common-timing-attlist" combine="interleave">
+   <ref name="common-basic-timing-attlist"/>
+   <ref name="common-restart-timing-attlist"/>
+   <ref name="common-restart-default-attlist"/>
+   <ref name="common-fill-timing-attlist"/>
+   <ref name="common-fill-default-attlist"/>
+   <ref name="common-time-manip-attlist"/>
+</define>
+<define name="animation-element" combine="choice">
+    <element name="anim:seq">
+        <ref name="common-anim-attlist"/>
+        <ref name="common-endsync-timing-attlist"/>
+        <ref name="common-timing-attlist"/>
+        <zeroOrMore>
+            <ref name="animation-element"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="animation-element" combine="choice">
+    <element name="anim:iterate">
+        <ref name="common-anim-attlist"/>
+        <ref name="anim-iterate-attlist"/>
+        <ref name="common-timing-attlist"/>
+        <ref name="common-endsync-timing-attlist"/>
+        <zeroOrMore>
+            <ref name="animation-element"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="anim-iterate-attlist" combine="interleave">
+    <ref name="common-anim-target-attlist"/>
+</define>
+<define name="anim-iterate-attlist" combine="interleave">
+    <optional>
+        <attribute name="anim:iterate-type">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="anim-iterate-attlist" combine="interleave">
+    <optional>
+        <attribute name="anim:iterate-interval">
+            <ref name="duration"/>
+        </attribute>
+    </optional>
+</define>
+<define name="animation-element" combine="choice">
+    <element name="anim:audio">
+        <ref name="common-anim-attlist"/>
+        <ref name="anim-audio-attlist"/>
+        <ref name="common-basic-timing-attlist"/>
+    </element>
+</define>
+<define name="anim-audio-attlist" combine="interleave">
+    <optional>
+        <attribute name="xlink:href">
+            <ref name="anyURI"/>
+        </attribute>
+    </optional>
+</define>
+<define name="anim-audio-attlist" combine="interleave">
+    <optional>
+        <attribute name="anim:audio-level">
+            <ref name="double"/>
+        </attribute>
+    </optional>
+</define>
+<define name="animation-element" combine="choice">
+    <element name="anim:command">
+        <ref name="common-anim-attlist"/>
+        <ref name="anim-command-attlist"/>
+        <ref name="common-begin-end-timing-attlist"/>
+        <ref name="common-anim-target-attlist"/>
+        <zeroOrMore>
+            <element name="anim:param">
+                <attribute name="anim:name"/>
+                <attribute name="anim:value"/>
+            </element>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="anim-command-attlist" combine="interleave">
+    <attribute name="anim:command">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="style-style">
+    <element name="style:style">
+        <ref name="style-style-attlist"/>
+        <ref name="style-style-content"/>
+        <zeroOrMore>
+            <ref name="style-map"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="style-style-attlist" combine="interleave">
+    <attribute name="style:name">
+        <ref name="styleName"/>
+    </attribute>
+</define>
+<define name="style-style-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:display-name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-style-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:parent-style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-style-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:next-style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-style-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:list-style-name">
+            <choice>
+                <ref name="styleName"/>
+                <empty/>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-style-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:master-page-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-style-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:auto-update" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-style-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:data-style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-style-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:class">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-style-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:default-outline-level">
+            <ref name="positiveInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-map">
+    <element name="style:map">
+        <ref name="style-map-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="style-map-attlist" combine="interleave">
+    <attribute name="style:condition">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="style-map-attlist" combine="interleave">
+    <attribute name="style:apply-style-name">
+        <ref name="styleNameRef"/>
+    </attribute>
+</define>
+<define name="style-map-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:base-cell-address">
+            <ref name="cellAddress"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-default-style">
+    <element name="style:default-style">
+        <ref name="style-style-content"/>
+    </element>
+</define>
+<define name="style-page-layout">
+    <element name="style:page-layout">
+        <ref name="style-page-layout-attlist"/>
+        <optional>
+            <ref name="style-page-layout-properties"/>
+        </optional>
+        <optional>
+            <ref name="style-header-style"/>
+        </optional>
+        <optional>
+            <ref name="style-footer-style"/>
+        </optional>
+    </element>
+</define>
+<define name="style-page-layout-attlist" combine="interleave">
+    <attribute name="style:name">
+        <ref name="styleName"/>
+    </attribute>
+</define>
+<define name="style-page-layout-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:page-usage" a:defaultValue="all">
+            <choice>
+                <value>all</value>
+                <value>left</value>
+                <value>right</value>
+                <value>mirrored</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-header-style">
+    <element name="style:header-style">
+        <optional>
+            <ref name="style-header-footer-properties"/>
+        </optional>
+    </element>
+</define>
+<define name="style-footer-style">
+    <element name="style:footer-style">
+        <optional>
+            <ref name="style-header-footer-properties"/>
+        </optional>
+    </element>
+</define>
+<define name="style-master-page">
+    <element name="style:master-page">
+        <ref name="style-master-page-attlist"/>
+        <optional>
+            <ref name="style-header"/>
+            <optional>
+                <ref name="style-header-left"/>
+            </optional>
+        </optional>
+        <optional>
+            <ref name="style-footer"/>
+            <optional>
+                <ref name="style-footer-left"/>
+            </optional>
+        </optional>
+        <optional>
+            <ref name="office-forms"/>
+        </optional>
+        <zeroOrMore>
+            <ref name="style-style"/>
+        </zeroOrMore>
+        <zeroOrMore>
+            <ref name="shape"/>
+        </zeroOrMore>
+        <optional>
+            <ref name="presentation-notes"/>
+        </optional>
+    </element>
+</define>
+<define name="style-master-page-attlist" combine="interleave">
+    <attribute name="style:name">
+        <ref name="styleName"/>
+    </attribute>
+</define>
+<define name="style-master-page-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:display-name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-master-page-attlist" combine="interleave">
+    <attribute name="style:page-layout-name">
+        <ref name="styleNameRef"/>
+    </attribute>
+</define>
+<define name="style-master-page-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-master-page-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:next-style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-header">
+    <element name="style:header">
+        <ref name="common-style-header-footer-attlist"/>
+        <ref name="header-footer-content"/>
+    </element>
+</define>
+<define name="style-footer">
+    <element name="style:footer">
+        <ref name="common-style-header-footer-attlist"/>
+        <ref name="header-footer-content"/>
+    </element>
+</define>
+<define name="style-header-left">
+    <element name="style:header-left">
+        <ref name="common-style-header-footer-attlist"/>
+        <ref name="header-footer-content"/>
+    </element>
+</define>
+<define name="style-footer-left">
+    <element name="style:footer-left">
+        <ref name="common-style-header-footer-attlist"/>
+        <ref name="header-footer-content"/>
+    </element>
+</define>
+<define name="header-footer-content">
+    <choice>
+        <group>
+            <ref name="text-tracked-changes"/>
+            <ref name="text-decls"/>
+            <zeroOrMore>
+                <choice>
+                    <ref name="text-h"/>
+                    <ref name="text-p"/>
+                    <ref name="text-list"/>
+                    <ref name="table-table"/>
+                    <ref name="text-section"/>
+                    <ref name="text-table-of-content"/>
+                    <ref name="text-illustration-index"/>
+                    <ref name="text-table-index"/>
+                    <ref name="text-object-index"/>
+                    <ref name="text-user-index"/>
+                    <ref name="text-alphabetical-index"/>
+                    <ref name="text-bibliography"/>
+                    <ref name="text-index-title"/>
+                    <ref name="change-marks"/>
+                </choice>
+            </zeroOrMore>
+        </group>
+        <group>
+            <optional>
+                <ref name="style-region-left"/>
+            </optional>
+            <optional>
+                <ref name="style-region-center"/>
+            </optional>
+            <optional>
+                <ref name="style-region-right"/>
+            </optional>
+        </group>
+    </choice>
+</define>
+<define name="common-style-header-footer-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:display" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-region-left">
+    <element name="style:region-left">
+        <ref name="region-content"/>
+    </element>
+</define>
+<define name="style-region-center">
+    <element name="style:region-center">
+        <ref name="region-content"/>
+    </element>
+</define>
+<define name="style-region-right">
+    <element name="style:region-right">
+        <ref name="region-content"/>
+    </element>
+</define>
+
+<define name="region-content">
+    <zeroOrMore>
+        <ref name="text-p"/>
+    </zeroOrMore>
+</define>
+<define name="presentation-notes">
+    <element name="presentation:notes">
+        <ref name="common-presentation-header-footer-attlist"/>
+        <ref name="presentation-notes-attlist"/>
+        <ref name="office-forms"/>
+        <zeroOrMore>
+            <ref name="shape"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="presentation-notes-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:page-layout-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="presentation-notes-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="table-table-template">
+    <element name="table:table-template">
+        <ref name="table-table-template-attlist"/>
+        <optional>
+            <ref name="table-first-row"/>
+        </optional>
+        <optional>
+            <ref name="table-last-row"/>
+        </optional>
+        <optional>
+            <ref name="table-first-column"/>
+        </optional>
+        <optional>
+            <ref name="table-last-column"/>
+        </optional>
+        <choice>
+            <ref name="table-body"/>
+            <group>
+                <ref name="table-even-rows"/>
+                <ref name="table-odd-rows"/>
+            </group>
+            <group>
+                <ref name="table-even-columns"/>
+                <ref name="table-odd-columns"/>
+            </group>
+        </choice>
+    </element>
+</define>
+<define name="table-table-template-attlist" combine="interleave">
+    <attribute name="text:name">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="table-table-template-attlist" combine="interleave">
+    <attribute name="text:first-row-start-column">
+        <ref name="rowOrCol"/>
+    </attribute>
+</define>
+
+<define name="table-table-template-attlist" combine="interleave">
+    <attribute name="text:first-row-end-column">
+        <ref name="rowOrCol"/>
+    </attribute>
+</define>
+
+<define name="table-table-template-attlist" combine="interleave">
+    <attribute name="text:last-row-start-column">
+        <ref name="rowOrCol"/>
+    </attribute>
+</define>
+
+<define name="table-table-template-attlist" combine="interleave">
+    <attribute name="text:last-row-end-column">
+        <ref name="rowOrCol"/>
+    </attribute>
+</define>
+
+<define name="rowOrCol">
+    <choice>
+        <value>row</value>
+        <value>column</value>
+    </choice>
+</define>
+<define name="table-first-row">
+    <element name="table:first-row">
+        <ref name="common-table-template-attlist"/>
+        <empty/>
+    </element>
+</define>
+
+<define name="table-last-row">
+    <element name="table:last-row">
+        <ref name="common-table-template-attlist"/>
+        <empty/>
+    </element>
+</define>
+
+<define name="table-first-column">
+    <element name="table:first-column">
+        <ref name="common-table-template-attlist"/>
+        <empty/>
+    </element>
+</define>
+
+<define name="table-last-column">
+    <element name="table:last-column">
+        <ref name="common-table-template-attlist"/>
+        <empty/>
+    </element>
+</define>
+
+<define name="table-body">
+    <element name="table:body">
+        <ref name="common-table-template-attlist"/>
+        <empty/>
+    </element>
+</define>
+
+<define name="table-even-rows">
+    <element name="table:even-rows">
+        <ref name="common-table-template-attlist"/>
+        <empty/>
+    </element>
+</define>
+
+<define name="table-odd-rows">
+    <element name="table:odd-rows">
+        <ref name="common-table-template-attlist"/>
+        <empty/>
+    </element>
+</define>
+
+<define name="table-even-columns">
+    <element name="table:even-columns">
+        <ref name="common-table-template-attlist"/>
+        <empty/>
+    </element>
+</define>
+
+<define name="table-odd-columns">
+    <element name="table:odd-columns">
+        <ref name="common-table-template-attlist"/>
+        <empty/>
+    </element>
+</define>
+
+<define name="common-table-template-attlist" combine="interleave">
+    <attribute name="text:style-name">
+        <ref name="styleNameRef"/>
+    </attribute>
+    <attribute name="text:paragraph-style-name">
+        <optional>
+            <ref name="styleNameRef"/>
+        </optional>
+    </attribute>
+</define>
+<define name="style-font-face">
+    <element name="style:font-face">
+        <ref name="style-font-face-attlist"/>
+        <optional>
+            <ref name="svg-font-face-src"/>
+        </optional>
+        <optional>
+            <ref name="svg-definition-src"/>
+        </optional>
+    </element>
+</define>
+<define name="style-font-face-attlist" combine="interleave">
+    <optional>
+        <attribute name="svg:font-family">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="svg:font-style">
+            <ref name="fontStyle"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="svg:font-variant">
+            <ref name="fontVariant"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="svg:font-weight">
+            <ref name="fontWeight"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="svg:font-stretch">
+            <choice>
+                <value>normal</value>
+                <value>ultra-condensed</value>
+                <value>extra-condensed</value>
+                <value>condensed</value>
+                <value>semi-condensed</value>
+                <value>semi-expanded</value>
+                <value>expanded</value>
+                <value>extra-expanded</value>
+                <value>ultra-expanded</value>
+            </choice>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="svg:font-size">
+            <ref name="positiveLength"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="svg:unicode-range"/>
+    </optional>
+    <optional>
+        <attribute name="svg:units-per-em">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="svg:panose-1"/>
+    </optional>
+    <optional>
+        <attribute name="svg:stemv">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="svg:stemh">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="svg:slope">
+            <ref name="integer"/>
+        </attribute>
+        </optional>
+    <optional>
+        <attribute name="svg:cap-height">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="svg:x-height">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="svg:accent-height">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="svg:ascent">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="svg:descent">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="svg:widths"/>
+    </optional>
+    <optional>
+        <attribute name="svg:bbox"/>
+    </optional>
+    <optional>
+        <attribute name="svg:ideographic">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="svg:alphabetic">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="svg:mathematical">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="svg:hanging">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="svg:v-ideographic">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="svg:v-alphabetic">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="svg:v-mathematical">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="svg:v-hanging">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="svg:underline-position">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="svg:underline-thickness">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="svg:strikethrough-position">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="svg:strikethrough-thickness">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="svg:overline-position">
+            <ref name="integer"/>
+        </attribute>
+        </optional>
+    <optional>
+        <attribute name="svg:overline-thickness">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+</define>
+
+<define name="svg-font-face-src">
+    <element name="svg:font-face-src">
+        <oneOrMore>
+            <choice>
+                <ref name="svg-font-face-uri"/>
+                <ref name="svg-font-face-name"/>
+            </choice>
+        </oneOrMore>
+    </element>
+</define>
+
+<define name="svg-font-face-uri">
+    <element name="svg:font-face-uri">
+        <ref name="common-svg-font-face-xlink-attlist"/>
+        <zeroOrMore>
+            <ref name="svg-font-face-format"/>
+        </zeroOrMore>
+    </element>
+</define>
+
+<define name="svg-font-face-format">
+    <element name="svg:font-face-format">
+        <optional>
+            <attribute name="svg:string"/>
+        </optional>
+        <empty/>
+    </element>
+</define>
+<define name="svg-font-face-name">
+    <element name="svg:font-face-name">
+        <optional>
+            <attribute name="svg:name"/>
+        </optional>
+        <empty/>
+    </element>
+</define>
+
+<define name="svg-definition-src">
+    <element name="svg:definition-src">
+        <ref name="common-svg-font-face-xlink-attlist"/>
+    <empty/>
+    </element>
+</define>
+
+<define name="common-svg-font-face-xlink-attlist" combine="interleave">
+    <attribute name="xlink:href">
+        <ref name="anyURI"/>
+    </attribute>
+    <optional>
+        <attribute name="xlink:type" a:defaultValue="simple">
+            <value>simple</value>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="xlink:actuate" a:defaultValue="onRequest">
+            <value>onRequest</value>
+        </attribute>
+    </optional>
+</define>
+<define name="style-font-face-attlist" combine="interleave">
+    <attribute name="style:name">
+        <ref name="string"/>
+    </attribute>
+</define>
+<define name="style-font-face-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:font-adornments">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-font-face-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:font-family-generic">
+            <ref name="fontFamilyGeneric"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-font-face-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:font-pitch">
+            <ref name="fontPitch"/>
+        </attribute>
+    </optional>
+</define>
+
+<define name="style-font-face-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:font-charset">
+            <ref name="textEncoding"/>
+        </attribute>
+    </optional>
+</define>
+<define name="number-number-style">
+    <element name="number:number-style">
+        <ref name="common-data-style-attlist"/>
+        <optional>
+            <ref name="style-text-properties"/>
+        </optional>
+        <optional>
+            <ref name="number-text"/>
+        </optional>
+        <optional>
+            <ref name="any-number"/>
+            <optional>
+                <ref name="number-text"/>
+            </optional>
+        </optional>
+        <zeroOrMore>
+            <ref name="style-map"/>
+        </zeroOrMore>
+    </element>
+</define>
+
+<define name="any-number">
+    <choice>
+        <ref name="number-number"/>
+        <ref name="number-scientific-number"/>
+        <ref name="number-fraction"/>
+    </choice>
+</define>
+<define name="number-number">
+    <element name="number:number">
+        <ref name="number-number-attlist"/>
+        <ref name="common-decimal-places-attlist"/>
+        <ref name="common-number-attlist"/>
+        <zeroOrMore>
+            <ref name="number-embedded-text"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="number-number-attlist" combine="interleave">
+    <optional>
+        <attribute name="number:decimal-replacement"/>
+    </optional>
+</define>
+<define name="number-number-attlist" combine="interleave">
+    <optional>
+        <attribute name="number:display-factor" a:defaultValue="1">
+            <ref name="double"/>
+        </attribute>
+    </optional>
+</define>
+<define name="number-embedded-text">
+    <element name="number:embedded-text">
+        <ref name="number-embedded-text-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="number-embedded-text-attlist" combine="interleave">
+    <attribute name="number:position">
+        <ref name="integer"/>
+    </attribute>
+</define>
+<define name="number-scientific-number">
+    <element name="number:scientific-number">
+        <ref name="number-scientific-number-attlist"/>
+        <ref name="common-decimal-places-attlist"/>
+        <ref name="common-number-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="number-scientific-number-attlist" combine="interleave">
+    <optional>
+        <attribute name="number:min-exponent-digits">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+</define>
+<define name="number-fraction">
+    <element name="number:fraction">
+        <ref name="number-fraction-attlist"/>
+        <ref name="common-number-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="number-fraction-attlist" combine="interleave">
+    <optional>
+        <attribute name="number:min-numerator-digits">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+</define>
+<define name="number-fraction-attlist" combine="interleave">
+    <optional>
+        <attribute name="number:min-denominator-digits">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+</define>
+<define name="number-fraction-attlist" combine="interleave">
+    <optional>
+        <attribute name="number:denominator-value">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+</define>
+<define name="number-currency-style">
+    <element name="number:currency-style">
+        <ref name="common-data-style-attlist"/>
+        <ref name="common-auto-reorder-attlist"/>
+        <optional>
+            <ref name="style-text-properties"/>
+        </optional>
+        <optional>
+            <ref name="number-text"/>
+        </optional>
+        <optional>
+            <choice>
+                <group>
+                    <ref name="number-and-text"/>
+                    <optional>
+                        <ref name="currency-symbol-and-text"/>
+                    </optional>
+                </group>
+                <group>
+                    <ref name="currency-symbol-and-text"/>
+                    <optional>
+                        <ref name="number-and-text"/>
+                    </optional>
+                </group>
+            </choice>
+        </optional>
+        <zeroOrMore>
+            <ref name="style-map"/>
+        </zeroOrMore>
+    </element>
+</define>
+
+<define name="currency-symbol-and-text">
+    <ref name="number-currency-symbol"/>
+    <optional>
+        <ref name="number-text"/>
+    </optional>
+</define>
+<define name="number-and-text">
+    <ref name="number-number"/>
+    <optional>
+        <ref name="number-text"/>
+    </optional>
+</define>
+<define name="number-currency-symbol">
+    <element name="number:currency-symbol">
+        <ref name="number-currency-symbol-attlist"/>
+        <text/>
+    </element>
+</define>
+<define name="number-currency-symbol-attlist" combine="interleave">
+    <optional>
+        <attribute name="number:language">
+            <ref name="languageCode"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="number:country">
+            <ref name="countryCode"/>
+        </attribute>
+    </optional>
+</define>
+<define name="number-percentage-style">
+    <element name="number:percentage-style">
+        <ref name="common-data-style-attlist"/>
+        <optional>
+            <ref name="style-text-properties"/>
+        </optional>
+        <optional>
+            <ref name="number-text"/>
+        </optional>
+        <optional>
+            <ref name="number-and-text"/>
+        </optional>
+        <zeroOrMore>
+            <ref name="style-map"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="number-date-style">
+    <element name="number:date-style">
+        <ref name="common-data-style-attlist"/>
+        <ref name="common-auto-reorder-attlist"/>
+        <ref name="common-format-source-attlist"/>
+        <optional>
+            <ref name="style-text-properties"/>
+        </optional>
+        <!-- This DTD does not reflect the fact that some elements must not -->
+        <!-- occur more than once. -->
+        <optional>
+            <ref name="number-text"/>
+        </optional>
+        <oneOrMore>
+            <ref name="any-date"/>
+            <optional>
+                <ref name="number-text"/>
+            </optional>
+        </oneOrMore>
+        <zeroOrMore>
+            <ref name="style-map"/>
+        </zeroOrMore>
+    </element>
+</define>
+
+<define name="any-date">
+    <choice>
+        <ref name="number-day"/>
+        <ref name="number-month"/>
+        <ref name="number-year"/>
+        <ref name="number-era"/>
+        <ref name="number-day-of-week"/>
+        <ref name="number-week-of-year"/>
+        <ref name="number-quarter"/>
+        <ref name="number-hours"/>
+        <ref name="number-am-pm"/>
+        <ref name="number-minutes"/>
+        <ref name="number-seconds"/>
+    </choice>
+</define>
+<define name="number-day">
+    <element name="number:day">
+        <ref name="number-day-attlist"/>
+        <ref name="common-calendar-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="number-day-attlist" combine="interleave">
+    <optional>
+        <attribute name="number:style" a:defaultValue="short">
+            <choice>
+                <value>short</value>
+                <value>long</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="number-month">
+    <element name="number:month">
+        <ref name="number-month-attlist"/>
+        <ref name="common-calendar-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="number-month-attlist" combine="interleave">
+    <optional>
+        <attribute name="number:textual" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="number-month-attlist" combine="interleave">
+    <optional>
+        <attribute name="number:possessive-form" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="number-month-attlist" combine="interleave">
+    <optional>
+        <attribute name="number:style" a:defaultValue="short">
+            <choice>
+                <value>short</value>
+                <value>long</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="number-year">
+    <element name="number:year">
+        <ref name="number-year-attlist"/>
+        <ref name="common-calendar-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="number-year-attlist" combine="interleave">
+    <optional>
+        <attribute name="number:style" a:defaultValue="short">
+            <choice>
+                <value>short</value>
+                <value>long</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="number-era">
+    <element name="number:era">
+        <ref name="number-era-attlist"/>
+        <ref name="common-calendar-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="number-era-attlist" combine="interleave">
+    <optional>
+        <attribute name="number:style" a:defaultValue="short">
+            <choice>
+                <value>short</value>
+                <value>long</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="number-day-of-week">
+    <element name="number:day-of-week">
+        <ref name="number-day-of-week-attlist"/>
+        <ref name="common-calendar-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="number-day-of-week-attlist" combine="interleave">
+    <optional>
+        <attribute name="number:style" a:defaultValue="short">
+            <choice>
+                <value>short</value>
+                <value>long</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="number-week-of-year">
+    <element name="number:week-of-year">
+        <ref name="common-calendar-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="number-quarter">
+    <element name="number:quarter">
+        <ref name="number-quarter-attlist"/>
+        <ref name="common-calendar-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="number-quarter-attlist" combine="interleave">
+    <optional>
+        <attribute name="number:style" a:defaultValue="short">
+            <choice>
+                <value>short</value>
+                <value>long</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="number-time-style">
+    <element name="number:time-style">
+        <ref name="number-time-style-attlist"/>
+        <ref name="common-data-style-attlist"/>
+        <ref name="common-format-source-attlist"/>
+        <optional>
+            <ref name="style-text-properties"/>
+        </optional>
+        <!-- This DTD does not reflect the fact that some elements must not -->
+        <!-- occur more than once. -->
+        <optional>
+            <ref name="number-text"/>
+        </optional>
+        <oneOrMore>
+            <ref name="any-time"/>
+            <optional>
+                <ref name="number-text"/>
+            </optional>
+        </oneOrMore>
+        <zeroOrMore>
+            <ref name="style-map"/>
+        </zeroOrMore>
+    </element>
+</define>
+
+<define name="any-time">
+    <choice>
+        <ref name="number-hours"/>
+        <ref name="number-am-pm"/>
+        <ref name="number-minutes"/>
+        <ref name="number-seconds"/>
+    </choice>
+</define>
+<define name="number-time-style-attlist" combine="interleave">
+    <optional>
+        <attribute name="number:truncate-on-overflow" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="number-hours">
+    <element name="number:hours">
+        <ref name="number-hours-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="number-hours-attlist" combine="interleave">
+    <optional>
+        <attribute name="number:style" a:defaultValue="short">
+            <choice>
+                <value>short</value>
+                <value>long</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="number-minutes">
+    <element name="number:minutes">
+        <ref name="number-minutes-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="number-minutes-attlist" combine="interleave">
+    <optional>
+        <attribute name="number:style" a:defaultValue="short">
+            <choice>
+                <value>short</value>
+                <value>long</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="number-seconds">
+    <element name="number:seconds">
+        <ref name="number-seconds-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="number-seconds-attlist" combine="interleave">
+    <optional>
+        <attribute name="number:style" a:defaultValue="short">
+            <choice>
+                <value>short</value>
+                <value>long</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="number-seconds-attlist" combine="interleave">
+    <optional>
+        <attribute name="number:decimal-places" a:defaultValue="0">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+</define>
+<define name="number-am-pm">
+    <element name="number:am-pm">
+        <empty/>
+    </element>
+</define>
+<define name="number-boolean-style">
+    <element name="number:boolean-style">
+        <ref name="common-data-style-attlist"/>
+        <optional>
+            <ref name="style-text-properties"/>
+        </optional>
+        <optional>
+            <ref name="number-text"/>
+        </optional>
+        <optional>
+            <ref name="number-boolean"/>
+            <optional>
+                <ref name="number-text"/>
+            </optional>
+        </optional>
+        <zeroOrMore>
+            <ref name="style-map"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="number-boolean">
+    <element name="number:boolean">
+        <empty/>
+    </element>
+</define>
+<define name="number-text-style">
+    <element name="number:text-style">
+        <ref name="common-data-style-attlist"/>
+        <optional>
+            <ref name="style-text-properties"/>
+        </optional>
+        <optional>
+            <ref name="number-text"/>
+        </optional>
+        <zeroOrMore>
+            <ref name="number-text-content"/>
+            <optional>
+                <ref name="number-text"/>
+            </optional>
+        </zeroOrMore>
+        <zeroOrMore>
+            <ref name="style-map"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="number-text">
+    <element name="number:text">
+        <text/>
+    </element>
+</define>
+<define name="number-text-content">
+    <element name="number:text-content">
+        <empty/>
+    </element>
+</define>
+<define name="common-data-style-attlist" combine="interleave">
+    <attribute name="style:name">
+        <ref name="styleName"/>
+    </attribute>
+</define>
+<define name="style-data-style-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:display-name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-data-style-attlist" combine="interleave">
+    <optional>
+        <attribute name="number:language">
+            <ref name="languageCode"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-data-style-attlist" combine="interleave">
+    <optional>
+        <attribute name="number:country">
+            <ref name="countryCode"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-data-style-attlist" combine="interleave">
+    <optional>
+        <attribute name="number:title"/>
+    </optional>
+</define>
+<define name="common-data-style-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:volatile">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-auto-reorder-attlist" combine="interleave">
+    <optional>
+        <attribute name="number:automatic-order" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-format-source-attlist">
+    <optional>
+        <attribute name="number:format-source" a:defaultValue="fixed">
+            <choice>
+                <value>fixed</value>
+                <value>language</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="common-data-style-attlist" combine="interleave">
+    <optional>
+        <attribute name="number:transliteration-format" a:defaultValue="1">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-data-style-attlist" combine="interleave">
+    <optional>
+        <attribute name="number:transliteration-language">
+            <ref name="countryCode"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-data-style-attlist" combine="interleave">
+    <optional>
+        <attribute name="number:transliteration-country">
+            <ref name="countryCode"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-data-style-attlist" combine="interleave">
+    <optional>
+        <attribute name="number:transliteration-style" a:defaultValue="short">
+            <choice>
+                <value>short</value>
+                <value>medium</value>
+                <value>long</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="common-decimal-places-attlist">
+    <optional>
+        <attribute name="number:decimal-places">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-number-attlist" combine="interleave">
+    <optional>
+        <attribute name="number:min-integer-digits">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-number-attlist" combine="interleave">
+    <optional>
+        <attribute name="number:grouping" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-calendar-attlist" combine="interleave">
+    <optional>
+        <attribute name="number:calendar">
+            <choice>
+                <value>gregorian</value>
+                <value>gengou</value>
+                <value>ROC</value>
+                <value>hanja_yoil</value>
+                <value>hanja</value>
+                <value>hijri</value>
+                <value>jewish</value>
+                <value>buddhist</value>
+                <ref name="string"/>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-style-content" combine="choice">
+    <group>
+        <attribute name="style:family">
+            <value>text</value>
+        </attribute>
+        <optional>
+            <ref name="style-text-properties"/>
+        </optional>
+    </group>
+</define>
+<define name="style-style-content" combine="choice">
+    <group>
+        <attribute name="style:family">
+            <value>paragraph</value>
+        </attribute>
+        <optional>
+            <ref name="style-paragraph-properties"/>
+        </optional>
+        <optional>
+            <ref name="style-text-properties"/>
+        </optional>
+    </group>
+</define>
+<define name="style-style-content" combine="choice">
+    <group>
+        <attribute name="style:family">
+            <value>section</value>
+        </attribute>
+        <optional>
+            <ref name="style-section-properties"/>
+        </optional>
+    </group>
+</define>
+<define name="style-style-content" combine="choice">
+    <group>
+        <attribute name="style:family">
+            <value>ruby</value>
+        </attribute>
+        <optional>
+            <ref name="style-ruby-properties"/>
+        </optional>
+    </group>
+</define>
+<define name="text-linenumbering-configuration">
+    <element name="text:linenumbering-configuration">
+        <ref name="text-linenumbering-configuration-attlist"/>
+        <optional>
+            <ref name="text-linenumbering-separator"/>
+        </optional>
+    </element>
+</define>
+<define name="text-linenumbering-configuration-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:number-lines" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-linenumbering-configuration-attlist" combine="interleave">
+    <optional>
+        <ref name="common-num-format-attlist"/>
+    </optional>
+</define>
+<define name="text-linenumbering-configuration-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-linenumbering-configuration-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:increment">
+            <ref name="nonNegativeInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-linenumbering-configuration-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:number-position" a:defaultValue="left">
+            <choice>
+                <value>left</value>
+                <value>right</value>
+                <value>inner</value>
+                <value>outer</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="text-linenumbering-configuration-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:offset">
+            <ref name="nonNegativeLength"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-linenumbering-configuration-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:count-empty-lines" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-linenumbering-configuration-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:count-in-text-boxes" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-linenumbering-configuration-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:restart-on-page" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-linenumbering-separator">
+    <element name="text:linenumbering-separator">
+        <optional>
+            <attribute name="text:increment">
+                <ref name="nonNegativeInteger"/>
+            </attribute>
+        </optional>
+        <text/>
+    </element>
+</define>
+<define name="text-notes-configuration">
+    <element name="text:notes-configuration">
+        <ref name="text-notes-configuration-content"/>
+    </element>
+</define>
+<define name="text-notes-configuration-content" combine="interleave">
+    <ref name="text-note-class"/>
+</define>
+<define name="text-notes-configuration-content" combine="interleave">
+    <optional>
+        <attribute name="text:citation-style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-notes-configuration-content" combine="interleave">
+    <optional>
+        <attribute name="text:citation-body-style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-notes-configuration-content" combine="interleave">
+    <optional>
+        <attribute name="text:default-style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-notes-configuration-content" combine="interleave">
+    <optional>
+        <attribute name="text:master-page-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-notes-configuration-content" combine="interleave">
+    <optional>
+        <attribute name="text:start-value">
+            <ref name="nonNegativeInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-notes-configuration-content" combine="interleave">
+    <ref name="common-num-format-prefix-suffix-attlist"/>
+    <optional>
+        <ref name="common-num-format-attlist"/>
+    </optional>
+</define>
+<define name="text-notes-configuration-content" combine="interleave">
+    <optional>
+        <attribute name="text:start-numbering-at">
+            <choice>
+                <value>document</value>
+                <value>chapter</value>
+                <value>page</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="text-notes-configuration-content" combine="interleave">
+    <optional>
+        <attribute name="text:footnotes-position">
+            <choice>
+                <value>text</value>
+                <value>page</value>
+                <value>section</value>
+                <value>document</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="text-notes-configuration-content" combine="interleave">
+    <optional>
+        <element name="text:note-continuation-notice-forward">
+            <text/>
+        </element>
+    </optional>
+</define>
+<define name="text-notes-configuration-content" combine="interleave">
+    <optional>
+        <element name="text:note-continuation-notice-backward">
+            <text/>
+        </element>
+    </optional>
+</define>
+<define name="text-bibliography-configuration">
+    <element name="text:bibliography-configuration">
+        <ref name="text-bibliography-configuration-attlist"/>
+        <zeroOrMore>
+            <ref name="text-sort-key"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="text-bibliography-configuration-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:prefix">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="text:suffix">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-bibliography-configuration-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:numbered-entries" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-bibliography-configuration-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:sort-by-position" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="fo:language">
+            <ref name="languageCode"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="fo:country">
+            <ref name="countryCode"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="text:sort-algorithm">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-sort-key">
+    <element name="text:sort-key">
+        <ref name="text-sort-key-attlist"/>
+        <empty/>
+    </element>
+</define>
+
+<define name="text-sort-key-attlist" combine="interleave">
+    <attribute name="text:key">
+        <choice>
+            <value>address</value>
+            <value>annote</value>
+            <value>author</value>
+            <value>bibliography-type</value>
+            <value>booktitle</value>
+            <value>chapter</value>
+            <value>custom1</value>
+            <value>custom2</value>
+            <value>custom3</value>
+            <value>custom4</value>
+            <value>custom5</value>
+            <value>edition</value>
+            <value>editor</value>
+            <value>howpublished</value>
+            <value>identifier</value>
+            <value>institution</value>
+            <value>isbn</value>
+            <value>issn</value>
+            <value>journal</value>
+            <value>month</value>
+            <value>note</value>
+            <value>number</value>
+            <value>organizations</value>
+            <value>pages</value>
+            <value>publisher</value>
+            <value>report-type</value>
+            <value>school</value>
+            <value>series</value>
+            <value>title</value>
+            <value>url</value>
+            <value>volume</value>
+            <value>year</value>
+        </choice>
+    </attribute>
+    <optional>
+        <attribute name="text:sort-ascending" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-list-style">
+    <element name="text:list-style">
+        <ref name="text-list-style-attr"/>
+        <zeroOrMore>
+            <ref name="text-list-style-content"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="text-list-style-attr" combine="interleave">
+    <attribute name="style:name">
+        <ref name="styleName"/>
+    </attribute>
+</define>
+<define name="text-list-style-attr" combine="interleave">
+    <optional>
+        <attribute name="style:display-name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-list-style-attr" combine="interleave">
+    <optional>
+        <attribute name="text:consecutive-numbering" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-list-level-style-attr">
+    <attribute name="text:level">
+        <ref name="positiveInteger"/>
+    </attribute>
+</define>
+<define name="text-list-style-content" combine="choice">
+    <element name="text:list-level-style-number">
+        <ref name="text-list-level-style-attr"/>
+        <ref name="text-list-level-style-number-attr"/>
+        <optional>
+            <ref name="style-list-level-properties"/>
+        </optional>
+        <optional>
+            <ref name="style-text-properties"/>
+        </optional>
+    </element>
+</define>
+<define name="text-list-level-style-number-attr" combine="interleave">
+    <optional>
+        <attribute name="text:style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-list-level-style-number-attr" combine="interleave">
+    <ref name="common-num-format-attlist"/>
+    <ref name="common-num-format-prefix-suffix-attlist"/>
+</define>
+<define name="text-list-level-style-number-attr" combine="interleave">
+    <optional>
+        <attribute name="text:display-levels" a:defaultValue="1">
+            <ref name="positiveInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-list-level-style-number-attr" combine="interleave">
+    <optional>
+        <attribute name="text:start-value" a:defaultValue="1">
+            <ref name="positiveInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-list-style-content" combine="choice">
+    <element name="text:list-level-style-bullet">
+        <ref name="text-list-level-style-attr"/>
+        <ref name="text-list-level-style-bullet-attr"/>
+        <optional>
+            <ref name="style-list-level-properties"/>
+        </optional>
+        <optional>
+            <ref name="style-text-properties"/>
+        </optional>
+    </element>
+</define>
+<define name="text-list-level-style-bullet-attr" combine="interleave">
+    <optional>
+        <attribute name="text:style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-list-level-style-bullet-attr" combine="interleave">
+    <attribute name="text:bullet-char">
+        <ref name="character"/>
+    </attribute>
+</define>
+<define name="text-list-level-style-bullet-attr" combine="interleave">
+    <ref name="common-num-format-prefix-suffix-attlist"/>
+</define>
+<define name="text-list-level-style-bullet-attr" combine="interleave">
+    <optional>
+        <attribute name="text:bullet-relative-size">
+            <ref name="percent"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-list-style-content" combine="choice">
+    <element name="text:list-level-style-image">
+        <ref name="text-list-level-style-attr"/>
+        <ref name="text-list-level-style-image-attr"/>
+        <optional>
+            <ref name="style-list-level-properties"/>
+        </optional>
+    </element>
+</define>
+<define name="text-list-level-style-image-attr" combine="interleave">
+    <choice>
+        <ref name="common-draw-data-attlist"/>
+        <ref name="office-binary-data"/>
+    </choice>
+</define>
+<define name="text-outline-style">
+    <element name="text:outline-style">
+        <oneOrMore>
+            <ref name="text-outline-level-style"/>
+        </oneOrMore>
+    </element>
+</define>
+<define name="text-outline-level-style">
+    <element name="text:outline-level-style">
+        <ref name="text-outline-level-style-attlist"/>
+        <optional>
+            <ref name="style-list-level-properties"/>
+        </optional>
+        <optional>
+            <ref name="style-text-properties"/>
+        </optional>
+    </element>
+</define>
+<define name="text-outline-level-style-attlist" combine="interleave">
+    <attribute name="text:level">
+        <ref name="positiveInteger"/>
+    </attribute>
+</define>
+<define name="text-outline-level-style-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-outline-level-style-attlist" combine="interleave">
+    <ref name="common-num-format-attlist"/>
+    <ref name="common-num-format-prefix-suffix-attlist"/>
+</define>
+<define name="text-outline-level-style-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:display-levels" a:defaultValue="1">
+            <ref name="positiveInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="text-outline-level-style-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:start-value" a:defaultValue="1">
+            <ref name="positiveInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-style-content" combine="choice">
+    <group>
+        <attribute name="style:family">
+            <value>table</value>
+        </attribute>
+        <optional>
+            <ref name="style-table-properties"/>
+        </optional>
+    </group>
+</define>
+<define name="style-style-content" combine="choice">
+    <group>
+        <attribute name="style:family">
+            <value>table-column</value>
+        </attribute>
+        <optional>
+            <ref name="style-table-column-properties"/>
+        </optional>
+    </group>
+</define>
+<define name="style-style-content" combine="choice">
+    <group>
+        <attribute name="style:family">
+            <value>table-row</value>
+        </attribute>
+        <optional>
+            <ref name="style-table-row-properties"/>
+        </optional>
+    </group>
+</define>
+<define name="style-style-content" combine="choice">
+    <group>
+        <attribute name="style:family">
+            <value>table-cell</value>
+        </attribute>
+        <optional>
+            <ref name="style-table-cell-properties"/>
+        </optional>
+        <optional>
+            <ref name="style-paragraph-properties"/>
+        </optional>
+        <optional>
+            <ref name="style-text-properties"/>
+        </optional>
+    </group>
+</define>
+<define name="style-style-content" combine="choice">
+    <group>
+        <attribute name="style:family">
+            <choice>
+                <value>graphic</value>
+                <value>presentation</value>
+            </choice>
+        </attribute>
+        <optional>
+            <ref name="style-graphic-properties"/>
+        </optional>
+        <optional>
+            <ref name="style-paragraph-properties"/>
+        </optional>
+        <optional>
+            <ref name="style-text-properties"/>
+        </optional>
+    </group>
+</define>
+
+<define name="style-graphic-properties">
+    <element name="style:graphic-properties">
+        <ref name="style-graphic-properties-content"/>
+    </element>
+</define>
+
+<define name="style-graphic-properties-content">
+    <ref name="style-properties-content"/>
+</define>
+
+<define name="style-graphic-properties-content-strict">
+    <ref name="style-graphic-properties-attlist"/>
+    <ref name="style-graphic-fill-properties-attlist"/>
+    <ref name="style-graphic-properties-elements"/>
+</define>
+
+<define name=" style-graphic-properties-elements">
+    <empty/>
+</define>
+<define name="style-style-content" combine="choice">
+    <group>
+        <attribute name="style:family">
+            <value>drawing-page</value>
+        </attribute>
+        <optional>
+            <ref name="style-drawing-page-properties"/>
+        </optional>
+    </group>
+</define>
+
+<define name="style-drawing-page-properties">
+    <element name="style:drawing-page-properties">
+        <ref name="style-drawing-page-properties-content"/>
+    </element>
+</define>
+
+<define name="style-drawing-page-properties-content">
+    <ref name="style-properties-content"/>
+</define>
+
+<define name="style-drawing-page-properties-content-strict">
+    <ref name="style-graphic-fill-properties-attlist"/>
+    <ref name="style-drawing-page-properties-attlist"/>
+    <ref name="style-drawing-page-properties-elements"/>
+</define>
+<define name="draw-gradient">
+    <element name="draw:gradient">
+        <ref name="common-draw-gradient-attlist"/>
+        <ref name="draw-gradient-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="common-draw-gradient-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:name">
+            <ref name="styleName"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-draw-gradient-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:display-name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-draw-gradient-attlist" combine="interleave">
+    <attribute name="draw:style">
+        <ref name="gradient-style"/>
+    </attribute>
+</define>
+<define name="gradient-style">
+    <choice>
+        <value>linear</value>
+        <value>axial</value>
+        <value>radial</value>
+        <value>ellipsoid</value>
+        <value>square</value>
+        <value>rectangular</value>
+    </choice>
+</define>
+<define name="common-draw-gradient-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:cx">
+            <ref name="percent"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="draw:cy">
+            <ref name="percent"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-gradient-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:start-color">
+            <ref name="color"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="draw:end-color">
+            <ref name="color"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-gradient-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:start-intensity">
+            <ref name="percent"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="draw:end-intensity">
+            <ref name="percent"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-draw-gradient-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:angle">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+</define>
+<define name="common-draw-gradient-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:border">
+            <ref name="percent"/>
+        </attribute>
+    </optional>
+</define>
+<define name="svg-linearGradient">
+    <element name="svg:linearGradient">
+        <ref name="common-svg-gradient-attlist"/>
+        <optional>
+            <attribute name="svg:x1" a:defaultValue="0%">
+                <choice>
+                    <ref name="coordinate"/>
+                    <ref name="percent"/>
+                </choice>                
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="svg:y1" a:defaultValue="0%">
+                <choice>
+                    <ref name="coordinate"/>
+                    <ref name="percent"/>
+                </choice>                
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="svg:x2" a:defaultValue="100%">
+                <choice>
+                    <ref name="coordinate"/>
+                    <ref name="percent"/>
+                </choice>                
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="svg:y2" a:defaultValue="100%">
+                <choice>
+                    <ref name="coordinate"/>
+                    <ref name="percent"/>
+                </choice>                
+            </attribute>
+        </optional>
+        <zeroOrMore>
+            <ref name="svg-stop"/>
+        </zeroOrMore>
+    </element>
+</define>
+
+<define name="svg-radialGradient">
+    <element name="svg:radialGradient">
+        <ref name="common-svg-gradient-attlist"/>
+        <optional>
+            <attribute name="svg:cx" a:defaultValue="50%">
+                <choice>
+                    <ref name="coordinate"/>
+                    <ref name="percent"/>
+                </choice>                
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="svg:cy" a:defaultValue="50%">
+                <choice>
+                    <ref name="coordinate"/>
+                    <ref name="percent"/>
+                </choice>                
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="svg:r" a:defaultValue="50%">
+                <choice>
+                    <ref name="coordinate"/>
+                    <ref name="percent"/>
+                </choice>                
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="svg:fx">
+                <choice>
+                    <ref name="coordinate"/>
+                    <ref name="percent"/>
+                </choice>                
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="svg:fy">
+                <choice>
+                    <ref name="coordinate"/>
+                    <ref name="percent"/>
+                </choice>                
+            </attribute>
+        </optional>
+        <zeroOrMore>
+            <ref name="svg-stop"/>
+        </zeroOrMore>
+    </element>
+</define>
+
+<define name="svg-stop">
+    <element name="svg:stop">
+        <attribute name="svg:offset">
+            <choice>
+                <ref name="double"/>
+                <ref name="percent"/>
+            </choice>
+        </attribute>
+        <optional>
+            <attribute name="svg:stop-color">
+                <ref name="color"/>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="svg:stop-opacity">
+                <ref name="double"/>
+            </attribute>
+        </optional>
+    </element>
+</define>
+
+<define name="common-svg-gradient-attlist" combine="interleave">
+    <optional>
+        <attribute name="svg:gradientUnits" a:defaultValue="objectBoundingBox">
+            <value>objectBoundingBox</value>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="svg:gradientTransform">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="svg:spreadMethod" a:defaultValue="pad">
+            <choice>
+                <value>pad</value>
+                <value>reflect</value>
+                <value>repeat</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="common-svg-gradient-attlist" combine="interleave">
+    <attribute name="draw:name">
+        <ref name="styleName"/>
+    </attribute>
+</define>
+<define name="common-svg-gradient-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:display-name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-hatch">
+    <element name="draw:hatch">
+        <ref name="draw-hatch-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="draw-hatch-attlist" combine="interleave">
+    <attribute name="draw:name">
+        <ref name="styleName"/>
+    </attribute>
+</define>
+<define name="draw-hatch-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:display-name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-hatch-attlist" combine="interleave">
+    <attribute name="draw:style">
+        <choice>
+            <value>single</value>
+            <value>double</value>
+            <value>triple</value>
+        </choice>
+    </attribute>
+</define>
+<define name="draw-hatch-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:color">
+            <ref name="color"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-hatch-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:distance">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-hatch-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:rotation">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-fill-image">
+    <element name="draw:fill-image">
+        <ref name="draw-fill-image-attlist"/>
+        <attribute name="xlink:href">
+            <ref name="anyURI"/>
+        </attribute>
+        <optional>
+            <attribute name="xlink:type" a:defaultValue="simple">
+                <choice>
+                    <value>simple</value>
+                </choice>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="xlink:show" a:defaultValue="embed">
+                <choice>
+                    <value>embed</value>
+                </choice>
+            </attribute>
+        </optional>
+        <optional>
+            <attribute name="xlink:actuate" a:defaultValue="onLoad">
+                <choice>
+                    <value>onLoad</value>
+                </choice>
+            </attribute>
+        </optional>
+        <empty/>
+    </element>
+</define>
+<define name="draw-fill-image-attlist" combine="interleave">
+    <attribute name="draw:name">
+        <ref name="styleName"/>
+    </attribute>
+</define>
+<define name="draw-fill-image-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:display-name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-fill-image-attlist" combine="interleave">
+    <optional>
+        <attribute name="svg:width">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="svg:height">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-opacity">
+    <element name="draw:opacity">
+        <ref name="common-draw-gradient-attlist"/>
+        <ref name="draw-opacity-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="draw-opacity-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:start">
+            <ref name="percent"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="draw:end">
+            <ref name="percent"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-marker">
+    <element name="draw:marker">
+        <ref name="draw-marker-attlist"/>
+        <ref name="common-draw-viewbox-attlist"/>
+        <ref name="common-draw-path-data-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="draw-marker-attlist" combine="interleave">
+    <attribute name="draw:name">
+        <ref name="styleName"/>
+    </attribute>
+</define>
+<define name="draw-marker-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:display-name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-stroke-dash">
+    <element name="draw:stroke-dash">
+        <ref name="draw-stroke-dash-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="draw-stroke-dash-attlist" combine="interleave">
+    <attribute name="draw:name">
+        <ref name="styleName"/>
+    </attribute>
+</define>
+<define name="draw-stroke-dash-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:display-name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-stroke-dash-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:style">
+            <choice>
+                <value>rect</value>
+                <value>round</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-stroke-dash-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:dots1">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="draw:dots1-length">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="draw:dots2">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="draw:dots2-length">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+</define>
+<define name="draw-stroke-dash-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:distance">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-presentation-page-layout">
+    <element name="style:presentation-page-layout">
+        <attribute name="style:name">
+            <ref name="styleName"/>
+        </attribute>
+        <optional>
+            <attribute name="style:display-name">
+                <ref name="string"/>
+            </attribute>
+        </optional>
+        <zeroOrMore>
+            <ref name="presentation-placeholder"/>
+        </zeroOrMore>
+    </element>
+</define>
+<define name="presentation-placeholder">
+    <element name="presentation:placeholder">
+        <attribute name="presentation:object">
+            <ref name="presentation-classes"/>
+        </attribute>
+        <attribute name="svg:x">
+            <choice>
+                <ref name="coordinate"/>
+                <ref name="percent"/>
+            </choice>
+        </attribute>
+        <attribute name="svg:y">
+            <choice>
+                <ref name="coordinate"/>
+                <ref name="percent"/>
+            </choice>
+        </attribute>
+        <attribute name="svg:width">
+            <choice>
+                <ref name="length"/>
+                <ref name="percent"/>
+            </choice>
+        </attribute>
+        <attribute name="svg:height">
+            <choice>
+                <ref name="length"/>
+                <ref name="percent"/>
+            </choice>
+        </attribute>
+        <empty/>
+    </element>
+</define>
+<define name="style-style-content" combine="choice">
+    <group>
+        <attribute name="style:family">
+            <value>chart</value>
+        </attribute>
+        <optional>
+            <ref name="style-chart-properties"/>
+        </optional>
+        <optional>
+            <ref name="style-graphic-properties"/>
+        </optional>
+        <optional>
+            <ref name="style-paragraph-properties"/>
+        </optional>
+        <optional>
+            <ref name="style-text-properties"/>
+        </optional>
+    </group>
+</define>
+<define name="style-properties-content">
+    <ref name="anyAttListOrElements"/>
+</define>
+<define name="style-page-layout-properties">
+    <element name="style:page-layout-properties">
+        <ref name="style-page-layout-properties-content"/>
+    </element>
+</define>
+
+<define name="style-page-layout-properties-content">
+    <ref name="style-properties-content"/>
+</define>
+
+<define name="style-page-layout-properties-content-strict">
+    <ref name="style-page-layout-properties-attlist"/>
+    <ref name="style-page-layout-properties-elements"/>
+</define>
+<define name="style-page-layout-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="fo:page-width">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="fo:page-height">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-page-layout-properties-attlist" combine="interleave">
+    <optional>
+        <ref name="common-num-format-attlist"/>
+    </optional>
+    <ref name="common-num-format-prefix-suffix-attlist"/>
+</define>
+<define name="style-page-layout-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:paper-tray-name">
+            <choice>
+                <value>default</value>
+                <ref name="string"/>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-page-layout-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:print-orientation">
+            <choice>
+                <value>portrait</value>
+                <value>landscape</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-page-layout-properties-attlist" combine="interleave">
+    <ref name="common-horizontal-margin-attlist"/>
+    <ref name="common-vertical-margin-attlist"/>
+    <ref name="common-margin-attlist"/>
+</define>
+<define name="style-page-layout-properties-attlist" combine="interleave">
+    <ref name="common-border-attlist"/>
+</define>
+<define name="style-page-layout-properties-attlist" combine="interleave">
+    <ref name="common-border-line-width-attlist"/>
+</define>
+<define name="style-page-layout-properties-attlist" combine="interleave">
+    <ref name="common-padding-attlist"/>
+</define>
+<define name="style-page-layout-properties-attlist" combine="interleave">
+    <ref name="common-shadow-attlist"/>
+</define>
+<define name="style-page-layout-properties-attlist" combine="interleave">
+    <ref name="common-background-color-attlist"/>
+</define>
+<define name="style-page-layout-properties-elements" combine="interleave">
+    <ref name="style-background-image"/>
+</define>
+<define name="style-page-layout-properties-elements" combine="interleave">
+    <ref name="style-columns"/>
+</define>
+<define name="style-page-layout-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:register-truth-ref-style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-page-layout-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:print">
+            <list>
+                <zeroOrMore>
+                    <choice>
+                        <value>headers</value>
+                        <value>grid</value>
+                        <value>annotations</value>
+                        <value>objects</value>
+                        <value>charts</value>
+                        <value>drawings</value>
+                        <value>formulas</value>
+                        <value>zero-values</value>
+                    </choice>
+                </zeroOrMore>
+            </list>
+        </attribute>
+    </optional>
+</define>
+<define name="style-page-layout-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:print-page-order">
+            <choice>
+                <value>ttb</value>
+                <value>ltr</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-page-layout-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:first-page-number">
+            <choice>
+                <ref name="positiveInteger"/>
+                <value>continue</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-page-layout-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:scale-to">
+            <ref name="percent"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:scale-to-pages">
+            <ref name="positiveInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-page-layout-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:table-centering">
+            <choice>
+                <value>horizontal</value>
+                <value>vertical</value>
+                <value>both</value>
+                <value>none</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-page-layout-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:footnote-max-height">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-page-layout-properties-attlist" combine="interleave">
+    <ref name="common-writing-mode-attlist"/>
+</define>
+<define name="style-page-layout-properties-elements" combine="interleave">
+    <ref name="style-footnote-sep"/>
+</define>
+
+<define name="style-footnote-sep">
+    <optional>
+        <element name="style:footnote-sep">
+            <ref name="style-footnote-sep-attlist"/>
+            <empty/>
+        </element>
+    </optional>
+</define>
+<define name="style-footnote-sep-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:width">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:rel-width">
+            <ref name="percent"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:color">
+            <ref name="color"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:line-style">
+            <ref name="lineStyle"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:adjustment" a:defaultValue="left">
+            <choice>
+                <value>left</value>
+                <value>center</value>
+                <value>right</value>
+            </choice>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:distance-before-sep">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:distance-after-sep">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-page-layout-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:layout-grid-mode">
+            <choice>
+                <value>none</value>
+                <value>line</value>
+                <value>both</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-page-layout-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:layout-grid-base-height">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-page-layout-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:layout-grid-ruby-height">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-page-layout-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:layout-grid-lines">
+            <ref name="positiveInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-page-layout-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:layout-grid-color">
+            <ref name="color"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-page-layout-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:layout-grid-ruby-below">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-page-layout-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:layout-grid-print">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-page-layout-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:layout-grid-display">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-header-footer-properties">
+    <element name="style:header-footer-properties">
+        <ref name="style-header-footer-properties-content"/>
+    </element>
+</define>
+
+<define name="style-header-footer-properties-content">
+    <ref name="style-properties-content"/>
+</define>
+
+<define name="style-header-footer-properties-content-strict">
+        <ref name="style-header-footer-properties-attlist"/>
+        <ref name="style-header-footer-properties-elements"/>
+</define>
+<define name="style-header-footer-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="svg:height">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="fo:min-height">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-header-footer-properties-attlist" combine="interleave">
+    <ref name="common-horizontal-margin-attlist"/>
+    <ref name="common-vertical-margin-attlist"/>
+    <ref name="common-margin-attlist"/>
+</define>
+<define name="style-header-footer-properties-attlist" combine="interleave">
+    <ref name="common-border-attlist"/>
+</define>
+<define name="style-header-footer-properties-attlist" combine="interleave">
+    <ref name="common-border-line-width-attlist"/>
+</define>
+<define name="style-header-footer-properties-attlist" combine="interleave">
+    <ref name="common-padding-attlist"/>
+</define>
+<define name="style-header-footer-properties-attlist" combine="interleave">
+    <ref name="common-background-color-attlist"/>
+</define>
+<define name="style-header-footer-properties-elements" combine="interleave">
+    <ref name="style-background-image"/>
+</define>
+<define name="style-header-footer-properties-attlist" combine="interleave">
+    <ref name="common-shadow-attlist"/>
+</define>
+<define name="style-header-footer-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:dynamic-spacing">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-text-properties">
+    <element name="style:text-properties">
+        <ref name="style-text-properties-content"/>
+    </element>
+</define>
+
+<define name="style-text-properties-content">
+    <ref name="style-properties-content"/>
+</define>
+
+<define name="style-text-properties-content-strict">
+    <ref name="style-text-properties-attlist"/>
+    <ref name="style-text-properties-elements"/>
+</define>
+
+<define name="style-text-properties-elements">
+    <empty/>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="fo:font-variant">
+            <ref name="fontVariant"/>
+        </attribute>
+    </optional>
+</define>
+
+<define name="fontVariant">
+    <choice>
+        <value>normal</value>
+        <value>small-caps</value>
+    </choice>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="fo:text-transform">
+            <choice>
+                <value>none</value>
+                <value>lowercase</value>
+                <value>uppercase</value>
+                <value>capitalize</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+            <attribute name="fo:color">
+            <ref name="color"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:use-window-font-color">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:text-outline">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:text-line-through-type">
+            <ref name="lineType"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:text-line-through-style">
+            <ref name="lineStyle"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:text-line-through-width">
+            <ref name="lineWidth"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:text-line-through-color">
+            <choice>
+                <value>font-color</value>
+                <ref name="color"/>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:text-line-through-text">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:text-line-through-text-style">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:text-position">
+            <list>
+                <choice>
+                    <ref name="percent"/>
+                    <value>super</value>
+                    <value>sub</value>
+                </choice>
+                <optional>
+                    <ref name="percent"/>
+                </optional>
+            </list>
+        </attribute>
+    </optional>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:font-name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:font-name-asian">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:font-name-complex">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="fo:font-family">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:font-family-asian">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:font-family-complex">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:font-family-generic">
+            <ref name="fontFamilyGeneric"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:font-family-generic-asian">
+            <ref name="fontFamilyGeneric"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:font-family-generic-complex">
+            <ref name="fontFamilyGeneric"/>
+        </attribute>
+    </optional>
+</define>
+
+<define name="fontFamilyGeneric">
+    <choice>
+        <value>roman</value>
+        <value>swiss</value>
+        <value>modern</value>
+        <value>decorative</value>
+        <value>script</value>
+        <value>system</value>
+    </choice>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:font-style-name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:font-style-name-asian">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:font-style-name-complex">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:font-pitch">
+            <ref name="fontPitch"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:font-pitch-asian">
+            <ref name="fontPitch"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:font-pitch-complex">
+            <ref name="fontPitch"/>
+        </attribute>
+    </optional>
+</define>
+
+<define name="fontPitch">
+    <choice>
+        <value>fixed</value>
+        <value>variable</value>
+    </choice>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:font-charset">
+            <ref name="textEncoding"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:font-charset-asian">
+            <ref name="textEncoding"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:font-charset-complex">
+            <ref name="textEncoding"/>
+        </attribute>
+    </optional>
+</define>
+
+<define name="textEncoding">
+    <data type="string">
+        <param name="pattern">[A-Za-z][A-Za-z0-9._\-]*</param>
+    </data>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="fo:font-size">
+            <choice>
+                <ref name="positiveLength"/>
+                <ref name="percent"/>
+            </choice>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:font-size-asian">
+            <choice>
+                <ref name="positiveLength"/>
+                <ref name="percent"/>
+            </choice>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:font-size-complex">
+            <choice>
+                <ref name="positiveLength"/>
+                <ref name="percent"/>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:font-size-rel">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:font-size-rel-asian">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:font-size-rel-complex">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:script-type">
+            <choice>
+                <value>latin</value>
+                <value>asian</value>
+                <value>complex</value>
+                <value>ignore</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="fo:letter-spacing">
+            <choice>
+                <ref name="length"/>
+                <value>normal</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="fo:language">
+            <ref name="languageCode"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:language-asian">
+            <ref name="languageCode"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:language-complex">
+            <ref name="languageCode"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="fo:country">
+            <ref name="countryCode"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:country-asian">
+            <ref name="countryCode"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:country-complex">
+            <ref name="countryCode"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="fo:font-style">
+            <ref name="fontStyle"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:font-style-asian">
+            <ref name="fontStyle"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:font-style-complex">
+            <ref name="fontStyle"/>
+        </attribute>
+    </optional>
+</define>
+
+<define name="fontStyle">
+    <choice>
+        <value>normal</value>
+        <value>italic</value>
+        <value>oblique</value>
+    </choice>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:font-relief">
+            <choice>
+            <value>none</value>
+                <value>embossed</value>
+                <value>engraved</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="fo:text-shadow">
+            <ref name="shadowType"/>
+        </attribute>
+    </optional>
+</define>
+
+<define name="shadowType">
+    <choice>
+        <value>none</value>
+        <!-- The following string must match an XSL shadow decl -->
+        <ref name="string"/>
+    </choice>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:text-underline-type">
+            <ref name="lineType"/>
+        </attribute>
+    </optional>
+</define>
+
+<define name="lineType">
+    <choice>
+        <value>none</value>
+        <value>single</value>
+        <value>double</value>
+    </choice>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:text-underline-style">
+            <ref name="lineStyle"/>
+        </attribute>
+    </optional>
+</define>
+
+<define name="lineStyle">
+    <choice>
+        <value>none</value>
+        <value>solid</value>
+        <value>dotted</value>
+        <value>dash</value>
+        <value>long-dash</value>
+        <value>dot-dash</value>
+        <value>dot-dot-dash</value>
+        <value>wave</value>
+    </choice>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:text-underline-width">
+            <ref name="lineWidth"/>
+        </attribute>
+    </optional>
+</define>
+
+<define name="lineWidth">
+    <choice>
+        <value>auto</value>
+        <value>normal</value>
+        <value>bold</value>
+        <value>thin</value>
+        <value>dash</value>
+        <value>medium</value>
+        <value>thick</value>
+        <ref name="positiveInteger"/>
+        <ref name="percent"/>
+        <ref name="positiveLength"/>
+    </choice>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:text-underline-color">
+            <choice>
+                <value>font-color</value>
+                <ref name="color"/>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="fo:font-weight">
+            <ref name="fontWeight"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:font-weight-asian">
+            <ref name="fontWeight"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:font-weight-complex">
+            <ref name="fontWeight"/>
+        </attribute>
+    </optional>
+</define>
+
+<define name="fontWeight">
+    <choice>
+        <value>normal</value>
+        <value>bold</value>
+        <value>100</value>
+        <value>200</value>
+        <value>300</value>
+        <value>400</value>
+        <value>500</value>
+        <value>600</value>
+        <value>700</value>
+        <value>800</value>
+        <value>900</value>
+    </choice>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:text-underline-mode">
+            <ref name="lineMode"/>
+        </attribute>
+    </optional>
+</define>
+
+<define name="lineMode">
+    <choice>
+        <value>continuous</value>
+        <value>skip-white-space</value>
+    </choice>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:text-line-through-mode">
+            <ref name="lineMode"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:letter-kerning">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:text-blinking">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <ref name="common-background-color-attlist"/>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:text-combine">
+            <choice>
+                <value>none</value>
+                <value>letters</value>
+                <value>lines</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:text-combine-start-char">
+            <ref name="character"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:text-combine-end-char">
+            <ref name="character"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:text-emphasize">
+            <choice>
+                <value>none</value>
+                <list>
+                    <choice>
+                        <value>none</value>
+                        <value>accent</value>
+                        <value>dot</value>
+                        <value>circle</value>
+                        <value>disc</value>
+                    </choice>
+                    <choice>
+                        <value>above</value>
+                        <value>below</value>
+                    </choice>
+                </list>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:text-scale">
+            <ref name="percent"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:text-rotation-angle">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:text-rotation-scale">
+            <choice>
+                <value>fixed</value>
+                <value>line-height</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="fo:hyphenate">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="fo:hyphenation-remain-char-count">
+            <ref name="positiveInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="fo:hyphenation-push-char-count">
+            <ref name="positiveInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-text-properties-attlist" combine="interleave">
+    <choice>
+        <attribute name="text:display">
+            <value>true</value>
+        </attribute>
+        <attribute name="text:display">
+            <value>none</value>
+        </attribute>
+        <group>
+            <attribute name="text:display">
+                <value>condition</value>
+            </attribute>
+            <attribute name="text:condition">
+                <value>none</value>
+            </attribute>
+        </group>
+        <empty/>
+    </choice>
+</define>
+<define name="style-paragraph-properties">
+    <element name="style:paragraph-properties">
+        <ref name="style-paragraph-properties-content"/>
+    </element>
+</define>
+
+<define name="style-paragraph-properties-content">
+    <ref name="style-properties-content"/>
+</define>
+
+<define name="style-paragraph-properties-content-strict">
+    <ref name="style-paragraph-properties-attlist"/>
+    <ref name="style-paragraph-properties-elements"/>
+</define>
+<define name="style-paragraph-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="fo:line-height">
+            <choice>
+                <value>normal</value>
+                <ref name="nonNegativeLength"/>
+                <ref name="percent"/>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-paragraph-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:line-height-at-least">
+            <ref name="nonNegativeLength"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-paragraph-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:line-spacing">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-paragraph-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:font-independent-line-spacing">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-paragraph-properties-attlist" combine="interleave">
+    <ref name="common-text-align"/>
+</define>
+
+<define name="common-text-align">
+    <optional>
+        <attribute name="fo:text-align">
+            <choice>
+                <value>start</value>
+                <value>end</value>
+                <value>left</value>
+                <value>right</value>
+                <value>center</value>
+                <value>justify</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-paragraph-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="fo:text-align-last">
+            <choice>
+                <value>start</value>
+                <value>center</value>
+                <value>justify</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-paragraph-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:justify-single-word">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-paragraph-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="fo:keep-together">
+            <choice>
+                <value>auto</value>
+                <value>always</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-paragraph-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="fo:widows">
+            <ref name="nonNegativeInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-paragraph-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="fo:orphans">
+            <ref name="nonNegativeInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-paragraph-properties-elements" combine="interleave">
+    <ref name="style-tab-stops"/>
+</define>
+
+<define name="style-tab-stops">
+    <optional>
+        <element name="style:tab-stops">
+            <zeroOrMore>
+                <ref name="style-tab-stop"/>
+            </zeroOrMore>
+        </element>
+    </optional>
+</define>
+
+<define name="style-tab-stop">
+    <element name="style:tab-stop">
+        <ref name="style-tab-stop-attlist"/>
+        <empty/>
+    </element>
+</define>
+<define name="style-tab-stop-attlist" combine="interleave">
+    <attribute name="style:position">
+        <ref name="nonNegativeLength"/>
+    </attribute>
+</define>
+<define name="style-tab-stop-attlist" combine="interleave">
+    <choice>
+        <optional>
+            <attribute name="style:type" a:defaultValue="left">
+                <choice>
+                    <value>left</value>
+                    <value>center</value>
+                    <value>right</value>
+                </choice>
+            </attribute>
+        </optional>
+        <group>
+            <attribute name="style:type">
+                <value>char</value>
+            </attribute>
+            <ref name="style-tab-stop-char-attlist"/>
+        </group>
+    </choice>
+</define>
+<define name="style-tab-stop-char-attlist" combine="interleave">
+    <attribute name="style:char">
+        <ref name="character"/>
+    </attribute>
+</define>
+<define name="style-tab-stop-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:leader-type">
+            <ref name="lineType"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-tab-stop-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:leader-style">
+            <ref name="lineStyle"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-tab-stop-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:leader-width">
+            <ref name="lineWidth"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-tab-stop-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:leader-color">
+            <choice>
+                <value>font-color</value>
+                <ref name="color"/>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-tab-stop-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:leader-text" a:defaultValue=" ">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-tab-stop-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:leader-text-style">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-paragraph-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:tab-stop-distance">
+            <ref name="nonNegativeLength"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-paragraph-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="fo:hyphenation-keep">
+            <choice>
+                <value>auto</value>
+                <value>page</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-paragraph-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="fo:hyphenation-ladder-count">
+            <choice>
+                <value>no-limit</value>
+                <ref name="positiveInteger"/>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-paragraph-properties-elements" combine="interleave">
+    <ref name="style-drop-cap"/>
+</define>
+
+<define name="style-drop-cap">
+    <optional>
+        <element name="style:drop-cap">
+            <ref name="style-drop-cap-attlist"/>
+            <empty/>
+        </element>
+    </optional>
+</define>
+<define name="style-drop-cap-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:length" a:defaultValue="1">
+            <choice>
+                <value>word</value>
+                <ref name="positiveInteger"/>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-drop-cap-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:lines" a:defaultValue="1">
+            <ref name="positiveInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-drop-cap-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:distance" a:defaultValue="0cm">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-drop-cap-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:style-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-paragraph-properties-attlist" combine="interleave">
+        <optional>
+            <attribute name="style:register-true">
+                <ref name="boolean"/>
+            </attribute>
+        </optional>
+    </define>
+<define name="style-paragraph-properties-attlist" combine="interleave">
+    <ref name="common-horizontal-margin-attlist"/>
+</define>
+
+<define name="common-horizontal-margin-attlist">
+    <optional>
+        <attribute name="fo:margin-left">
+            <choice>
+                <ref name="length"/>
+                <ref name="percent"/>
+            </choice>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="fo:margin-right">
+            <choice>
+                <ref name="length"/>
+                <ref name="percent"/>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-paragraph-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="fo:text-indent">
+            <choice>
+                <ref name="length"/>
+                <ref name="percent"/>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-paragraph-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:auto-text-indent">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-paragraph-properties-attlist" combine="interleave">
+    <ref name="common-vertical-margin-attlist"/>
+</define>
+
+<define name="common-vertical-margin-attlist">
+    <optional>
+        <attribute name="fo:margin-top">
+            <choice>
+                <ref name="nonNegativeLength"/>
+                <ref name="percent"/>
+            </choice>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="fo:margin-bottom">
+            <choice>
+                <ref name="nonNegativeLength"/>
+                <ref name="percent"/>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-paragraph-properties-attlist" combine="interleave">
+    <ref name="common-margin-attlist"/>
+</define>
+
+<define name="common-margin-attlist">
+    <optional>
+        <attribute name="fo:margin">
+            <choice>
+                <ref name="nonNegativeLength"/>
+                <ref name="percent"/>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-paragraph-properties-attlist" combine="interleave">
+    <ref name="common-break-attlist"/>
+</define>
+
+<define name="common-break-attlist">
+    <optional>
+        <attribute name="fo:break-before">
+            <choice>
+                <value>auto</value>
+                <value>column</value>
+                <value>page</value>
+            </choice>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="fo:break-after">
+            <choice>
+                <value>auto</value>
+                <value>column</value>
+                <value>page</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-paragraph-properties-attlist" combine="interleave">
+    <ref name="common-background-color-attlist"/>
+</define>
+
+<define name="common-background-color-attlist">
+    <optional>
+        <attribute name="fo:background-color">
+            <choice>
+                <value>transparent</value>
+                <ref name="color"/>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-paragraph-properties-elements" combine="interleave">
+    <ref name="style-background-image"/>
+</define>
+
+<define name="style-background-image">
+    <optional>
+        <element name="style:background-image">
+            <ref name="style-background-image-attlist"/>
+            <choice>
+                <ref name="common-draw-data-attlist"/>
+                <ref name="office-binary-data"/>
+                <empty/>
+            </choice>
+        </element>
+    </optional>
+</define>
+<define name="style-background-image-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:repeat" a:defaultValue="repeat">
+            <choice>
+                <value>no-repeat</value>
+                <value>repeat</value>
+                <value>stretch</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-background-image-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:position" a:defaultValue="center">
+            <choice>
+                <value>left</value>
+                <value>center</value>
+                <value>right</value>
+                <value>top</value>
+                <value>bottom</value>
+                <list>
+                    <ref name="horiBackPos"/>
+                    <ref name="vertBackPos"/>
+                </list>
+                <list>
+                    <ref name="vertBackPos"/>
+                    <ref name="horiBackPos"/>
+                </list>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+
+<define name="horiBackPos">
+    <choice>
+        <value>left</value>
+        <value>center</value>
+        <value>right</value>
+    </choice>
+</define>
+<define name="vertBackPos">
+    <choice>
+        <value>top</value>
+        <value>center</value>
+        <value>bottom</value>
+    </choice>
+</define>
+<define name="style-background-image-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:filter-name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-background-image-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:opacity">
+            <ref name="percent"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-paragraph-properties-attlist" combine="interleave">
+    <ref name="common-border-attlist"/>
+</define>
+
+<define name="common-border-attlist">
+    <optional>
+        <attribute name="fo:border">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="fo:border-top">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="fo:border-bottom">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="fo:border-left">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="fo:border-right">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-paragraph-properties-attlist" combine="interleave">
+    <ref name="common-border-line-width-attlist"/>
+</define>
+
+<define name="common-border-line-width-attlist">
+    <optional>
+        <attribute name="style:border-line-width">
+            <ref name="borderWidths"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:border-line-width-top">
+            <ref name="borderWidths"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:border-line-width-bottom">
+            <ref name="borderWidths"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:border-line-width-left">
+            <ref name="borderWidths"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:border-line-width-right">
+            <ref name="borderWidths"/>
+        </attribute>
+    </optional>
+</define>
+
+<define name="borderWidths">
+    <list>
+        <ref name="positiveLength"/>
+        <ref name="positiveLength"/>
+        <ref name="positiveLength"/>
+    </list>
+</define>
+<define name="style-paragraph-properties-attlist" combine="interleave">
+    <ref name="common-padding-attlist"/>
+</define>
+
+<define name="common-padding-attlist">
+    <optional>
+        <attribute name="fo:padding">
+            <ref name="nonNegativeLength"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="fo:padding-top">
+            <ref name="nonNegativeLength"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="fo:padding-bottom">
+            <ref name="nonNegativeLength"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="fo:padding-left">
+            <ref name="nonNegativeLength"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="fo:padding-right">
+            <ref name="nonNegativeLength"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-paragraph-properties-attlist" combine="interleave">
+    <ref name="common-shadow-attlist"/>
+</define>
+
+<define name="common-shadow-attlist">
+    <optional>
+        <attribute name="style:shadow">
+            <ref name="shadowType"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-paragraph-properties-attlist" combine="interleave">
+    <ref name="common-keep-with-next-attlist"/>
+</define>
+
+<define name="common-keep-with-next-attlist">
+    <optional>
+        <attribute name="fo:keep-with-next">
+            <choice>
+                <value>auto</value>
+                <value>always</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-paragraph-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:number-lines" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-paragraph-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:line-number">
+            <ref name="nonNegativeInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-paragraph-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:text-autospace">
+            <choice>
+                <value>none</value>
+                <value>ideograph-alpha</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-paragraph-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:punctuation-wrap">
+            <choice>
+                <value>simple</value>
+                <value>hanging</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-paragraph-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:line-break">
+            <choice>
+                <value>normal</value>
+                <value>strict</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-paragraph-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:vertical-align" a:defaultValue="auto">
+            <choice>
+                <value>top</value>
+                <value>middle</value>
+                <value>bottom</value>
+                <value>auto</value>
+                <value>baseline</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-paragraph-properties-attlist" combine="interleave">
+    <ref name="common-writing-mode-attlist"/>
+</define>
+
+<define name="common-writing-mode-attlist">
+    <optional>
+        <attribute name="style:writing-mode">
+            <choice>
+                <value>lr-tb</value>
+                <value>rl-tb</value>
+                <value>tb-rl</value>
+                <value>tb-lr</value>
+                <value>lr</value>
+                <value>rl</value>
+                <value>tb</value>
+                <value>page</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-paragraph-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:writing-mode-automatic">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-paragraph-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:snap-to-layout-grid">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-paragraph-properties-attlist" combine="interleave">
+    <ref name="common-page-number-attlist"/>
+</define>
+
+<define name="common-page-number-attlist">
+    <optional>
+        <attribute name="style:page-number">
+            <choice>                <ref name="positiveInteger"/>                <value>auto</value>            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-paragraph-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:background-transparency">
+            <ref name="percent"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-ruby-properties">
+    <element name="style:ruby-properties">
+        <ref name="style-ruby-properties-content"/>
+    </element>
+</define>
+
+<define name="style-ruby-properties-content">
+    <ref name="style-properties-content"/>
+</define>
+
+<define name="style-ruby-properties-content-strict">
+    <ref name="style-ruby-properties-attlist"/>
+    <ref name="style-ruby-properties-elements"/>
+</define>
+
+<define name="style-ruby-properties-elements">
+    <empty/>
+</define>
+<define name="style-ruby-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:ruby-position">
+            <choice>
+                <value>above</value>
+                <value>below</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-ruby-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:ruby-align">
+            <choice>
+                <value>left</value>
+                <value>center</value>
+                <value>right</value>
+                <value>distribute-letter</value>
+                <value>distribute-space</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-section-properties">
+    <element name="style:section-properties">
+        <ref name="style-section-properties-content"/>
+    </element>
+</define>
+
+<define name="style-section-properties-content">
+    <ref name="style-properties-content"/>
+</define>
+
+<define name="style-section-properties-content-strict">
+    <ref name="style-section-properties-attlist"/>
+    <ref name="style-section-properties-elements"/>
+</define>
+<define name="style-section-properties-attlist" combine="interleave">
+    <ref name="common-background-color-attlist"/>
+</define>
+<define name="style-section-properties-elements" combine="interleave">
+    <ref name="style-background-image"/>
+</define>
+<define name="style-section-properties-attlist" combine="interleave">
+    <ref name="common-horizontal-margin-attlist"/>
+</define>
+<define name="style-section-properties-elements" combine="interleave">
+    <ref name="style-columns"/>
+</define>
+
+<define name="style-columns">
+    <optional>
+        <element name="style:columns">
+            <ref name="style-columns-attlist"/>
+            <optional>
+                <ref name="style-column-sep"/>
+            </optional>
+            <zeroOrMore>
+                <ref name="style-column"/>
+            </zeroOrMore>
+        </element>
+    </optional>
+</define>
+<define name="style-columns-attlist" combine="interleave">
+    <attribute name="fo:column-count">
+        <ref name="positiveInteger"/>
+    </attribute>
+</define>
+<define name="style-columns-attlist" combine="interleave">
+    <optional>
+        <attribute name="fo:column-gap">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-column">
+    <element name="style:column">
+        <ref name="style-column-attlist"/>
+    </element>
+</define>
+<define name="style-column-attlist" combine="interleave">
+    <attribute name="style:rel-width">
+        <ref name="relativeLength"/>
+    </attribute>
+</define>
+<define name="style-column-attlist" combine="interleave">
+    <optional>
+        <attribute name="fo:start-indent" a:defaultValue="0cm">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-column-attlist" combine="interleave">
+    <optional>
+        <attribute name="fo:end-indent" a:defaultValue="0cm">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-column-attlist" combine="interleave">
+    <optional>
+        <attribute name="fo:space-before" a:defaultValue="0cm">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-column-attlist" combine="interleave">
+    <optional>
+        <attribute name="fo:space-after" a:defaultValue="0cm">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-column-sep">
+    <element name="style:column-sep">
+        <ref name="style-column-sep-attlist"/>
+    </element>
+</define>
+<define name="style-column-sep-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:style" a:defaultValue="solid">
+            <choice>
+                <value>none</value>
+                <value>solid</value>
+                <value>dotted</value>
+                <value>dashed</value>
+                <value>dot-dashed</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-column-sep-attlist" combine="interleave">
+    <attribute name="style:width">
+        <ref name="length"/>
+    </attribute>
+</define>
+<define name="style-column-sep-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:height" a:defaultValue="100%">
+            <ref name="percent"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-column-sep-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:vertical-align" a:defaultValue="top">
+            <choice>
+                <value>top</value>
+                <value>middle</value>
+                <value>bottom</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-column-sep-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:color" a:defaultValue="#000000">
+            <ref name="color"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-section-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:protect" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-section-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:dont-balance-text-columns">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-section-properties-attlist" combine="interleave">
+    <ref name="common-writing-mode-attlist"/>
+</define>
+<define name="style-section-properties-elements" combine="interleave">
+    <zeroOrMore>
+        <ref name="text-notes-configuration"/>
+    </zeroOrMore>
+</define>
+<define name="style-table-properties">
+    <element name="style:table-properties">
+        <ref name="style-table-properties-content"/>
+    </element>
+</define>
+
+<define name="style-table-properties-content">
+    <ref name="style-properties-content"/>
+</define>
+
+<define name="style-table-properties-content-strict">
+    <ref name="style-table-properties-attlist"/>
+    <ref name="style-table-properties-elements"/>
+</define>
+<define name="style-table-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:width">
+            <ref name="positiveLength"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:rel-width">
+            <ref name="percent"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-table-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:align">
+            <choice>
+                <value>left</value>
+                <value>center</value>
+                <value>right</value>
+                <value>margins</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-table-properties-attlist" combine="interleave">
+    <ref name="common-horizontal-margin-attlist"/>
+</define>
+<define name="style-table-properties-attlist" combine="interleave">
+    <ref name="common-vertical-margin-attlist"/>
+</define>
+<define name="style-table-properties-attlist" combine="interleave">
+    <ref name="common-margin-attlist"/>
+</define>
+<define name="style-table-properties-attlist" combine="interleave">
+    <ref name="common-page-number-attlist"/>
+</define>
+<define name="style-table-properties-attlist" combine="interleave">
+    <ref name="common-break-attlist"/>
+</define>
+<define name="style-table-properties-attlist" combine="interleave">
+    <ref name="common-background-color-attlist"/>
+</define>
+<define name="style-table-properties-elements" combine="interleave">
+    <ref name="style-background-image"/>
+</define>
+<define name="style-table-properties-attlist" combine="interleave">
+    <ref name="common-shadow-attlist"/>
+</define>
+<define name="style-table-properties-attlist" combine="interleave">
+    <ref name="common-keep-with-next-attlist"/>
+</define>
+<define name="style-table-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:may-break-between-rows">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-table-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:border-model">
+            <choice>
+                <value>collapsing</value>
+                <value>separating</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-table-properties-attlist" combine="interleave">
+    <ref name="common-writing-mode-attlist"/>
+</define>
+<define name="style-table-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="table:display">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-table-column-properties">
+    <element name="style:table-column-properties">
+        <ref name="style-table-column-properties-content"/>
+    </element>
+</define>
+
+<define name="style-table-column-properties-content">
+    <ref name="style-properties-content"/>
+</define>
+
+<define name="style-table-column-properties-content-strict">
+    <ref name="style-table-column-properties-attlist"/>
+    <ref name="style-table-column-properties-elements"/>
+</define>
+
+<define name="style-table-column-properties-elements">
+    <empty/>
+</define>
+<define name="style-table-column-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:column-width">
+            <ref name="positiveLength"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:rel-column-width">
+            <ref name="relativeLength"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-table-column-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:use-optimal-column-width">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-table-column-properties-attlist" combine="interleave">
+    <ref name="common-break-attlist"/>
+</define>
+<define name="style-table-row-properties">
+    <element name="style:table-row-properties">
+        <ref name="style-table-row-properties-content"/>
+    </element>
+</define>
+
+<define name="style-table-row-properties-content">
+    <ref name="style-properties-content"/>
+</define>
+
+<define name="style-table-row-properties-content-strict">
+    <ref name="style-table-row-properties-attlist"/>
+    <ref name="style-table-row-properties-elements"/>
+</define>
+<define name="style-table-row-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:row-height">
+            <ref name="positiveLength"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:min-row-height">
+            <ref name="nonNegativeLength"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-table-row-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:use-optimal-row-height">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-table-row-properties-attlist" combine="interleave">
+    <ref name="common-background-color-attlist"/>
+</define>
+<define name="style-table-row-properties-elements" combine="interleave">
+    <ref name="style-background-image"/>
+</define>
+<define name="style-table-row-properties-attlist" combine="interleave">
+    <ref name="common-break-attlist"/>
+</define>
+<define name="style-table-row-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="fo:keep-together">
+            <choice>
+                <value>auto</value>
+                <value>always</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-table-cell-properties">
+    <element name="style:table-cell-properties">
+        <ref name="style-table-cell-properties-content"/>
+    </element>
+</define>
+
+<define name="style-table-cell-properties-content">
+    <ref name="style-properties-content"/>
+</define>
+
+<define name="style-table-cell-properties-content-strict">
+    <ref name="style-table-cell-properties-attlist"/>
+    <ref name="style-table-cell-properties-elements"/>
+</define>
+<define name="style-table-cell-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:vertical-align">
+            <choice>
+                <value>top</value>
+                <value>middle</value>
+                <value>bottom</value>
+                <value>automatic</value>
+            </choice>
+            </attribute>
+    </optional>
+</define>
+<define name="style-table-cell-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:text-align-source">
+            <choice>
+                <value>fix</value>
+                <value>value-type</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-table-cell-properties-attlist" combine="interleave">
+    <ref name="common-style-direction-attlist"/>
+</define>
+
+<define name="common-style-direction-attlist">
+    <optional>
+        <attribute name="style:direction">
+            <choice>
+                <value>ltr</value>
+                <value>ttb</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-table-cell-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:glyph-orientation-vertical">
+            <choice>
+                <value>auto</value>
+                <value>0</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-table-cell-properties-attlist" combine="interleave">
+    <ref name="common-shadow-attlist"/>
+</define>
+<define name="style-table-cell-properties-attlist" combine="interleave">
+    <ref name="common-background-color-attlist"/>
+</define>
+<define name="style-table-cell-properties-elements" combine="interleave">
+    <ref name="style-background-image"/>
+</define>
+<define name="style-table-cell-properties-attlist" combine="interleave">
+    <ref name="common-border-attlist"/>
+</define>
+<define name="style-table-cell-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:diagonal-tl-br">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:diagonal-tl-br-widths">
+            <ref name="borderWidths"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:diagonal-bl-tr">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="style:diagonal-bl-tr-widths">
+            <ref name="borderWidths"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-table-cell-properties-attlist" combine="interleave">
+    <ref name="common-border-line-width-attlist"/>
+</define>
+<define name="style-table-cell-properties-attlist" combine="interleave">
+    <ref name="common-padding-attlist"/>
+</define>
+<define name="style-table-cell-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="fo:wrap-option">
+            <choice>
+                <value>no-wrap</value>
+                <value>wrap</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-table-cell-properties-attlist" combine="interleave">
+    <ref name="common-rotation-angle-attlist"/>
+</define>
+
+<define name="common-rotation-angle-attlist">
+    <optional>
+        <attribute name="style:rotation-angle">
+            <ref name="nonNegativeInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-table-cell-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:rotation-align">
+            <choice>
+                <value>none</value>
+                <value>bottom</value>
+                <value>top</value>
+                <value>center</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-table-cell-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:cell-protect">
+            <choice>
+                <value>none</value>
+                <value>hidden-and-protected</value>
+                <list>
+                    <oneOrMore>
+                        <choice>
+                            <value>protected</value>
+                            <value>formula-hidden</value>
+                        </choice>
+                    </oneOrMore>
+                </list>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-table-cell-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:print-content">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-table-cell-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:decimal-places">
+            <ref name="nonNegativeInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-table-cell-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:repeat-content">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-table-cell-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:shrink-to-fit">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-list-level-properties">
+    <element name="style:list-level-properties">
+        <ref name="style-list-level-properties-content"/>
+    </element>
+</define>
+
+<define name="style-list-level-properties-content">
+    <ref name="style-properties-content"/>
+</define>
+
+<define name="style-list-level-properties-content-strict">
+    <ref name="style-list-level-properties-attlist"/>
+    <ref name="style-list-level-properties-elements"/>
+</define>
+
+<define name="style-list-level-properties-elements">
+    <empty/>
+</define>
+<define name="style-list-level-properties-attlist" combine="interleave">
+    <ref name="common-text-align"/>
+</define>
+<define name="style-list-level-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:space-before">
+            <ref name="nonNegativeLength"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-list-level-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:min-label-width">
+            <ref name="nonNegativeLength"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-list-level-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:min-label-distance">
+            <ref name="nonNegativeLength"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-list-level-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:font-name">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-list-level-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="fo:width">
+            <ref name="positiveLength"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="fo:height">
+            <ref name="positiveLength"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-list-level-properties-attlist" combine="interleave">
+    <ref name="common-vertical-rel-attlist"/>
+    <ref name="common-vertical-pos-attlist"/>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:stroke">
+            <choice>
+                <value>none</value>
+                <value>dash</value>
+                <value>solid</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:stroke-dash">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:stroke-dash-names">
+            <ref name="styleNameRefs"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="svg:stroke-width">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="svg:stroke-color">
+            <ref name="color"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:marker-start">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:marker-end">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:marker-start-width">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:marker-end-width">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:marker-start-center">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:marker-end-center">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="svg:stroke-opacity">
+            <choice>
+                <data type="double">
+                    <param name="minInclusive">0</param>
+                    <param name="maxInclusive">1</param>
+                </data>
+                <ref name="percent"/>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:stroke-linejoin">
+            <choice>
+                <value>miter</value>
+                <value>round</value>
+                <value>bevel</value>
+                <value>middle</value>
+                <value>none</value>
+                <value>inherit</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-fill-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:fill">
+            <choice>
+                <value>none</value>
+                <value>solid</value>
+                <value>bitmap</value>
+                <value>gradient</value>
+                <value>hatch</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-fill-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:fill-color">
+            <ref name="color"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-fill-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:secondary-fill-color">
+            <ref name="color"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-fill-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:fill-gradient-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-fill-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:gradient-step-count">
+            <ref name="nonNegativeInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-fill-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:fill-hatch-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-fill-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:fill-hatch-solid">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-fill-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:fill-image-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-fill-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:repeat">
+            <choice>
+                <value>no-repeat</value>
+                <value>repeat</value>
+                <value>stretch</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-fill-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:fill-image-width">
+            <choice>
+                <ref name="length"/>
+                <ref name="percent"/>
+            </choice>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="draw:fill-image-height">
+            <choice>
+                <ref name="length"/>
+                <ref name="percent"/>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-fill-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:fill-image-ref-point-x">
+            <ref name="percent"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="draw:fill-image-ref-point-y">
+            <ref name="percent"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="draw:fill-image-ref-point">
+            <choice>
+                <value>top-left</value>
+                <value>top</value>
+                <value>top-right</value>
+                <value>left</value>
+                <value>center</value>
+                <value>right</value>
+                <value>bottom-left</value>
+                <value>bottom</value>
+                <value>bottom-right</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-fill-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:tile-repeat-offset"/>
+    </optional>
+</define>
+<define name="style-graphic-fill-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:opacity">
+            <ref name="percent"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-fill-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:opacity-name">
+            <ref name="styleNameRef"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-fill-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="svg:fill-rule">
+            <choice>
+                <value>nonzero</value>
+                <value>evenodd</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:symbol-color">
+            <ref name="color"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:animation">
+            <choice>
+                <value>none</value>
+                <value>scroll</value>
+                <value>alternate</value>
+                <value>slide</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:animation-direction">
+            <choice>
+                <value>left</value>
+                <value>right</value>
+                <value>up</value>
+                <value>down</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:animation-start-inside">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:animation-stop-inside">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:animation-repeat">
+            <ref name="nonNegativeInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:animation-delay">
+            <ref name="duration"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="text:animation-steps">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:auto-grow-width">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="draw:auto-grow-height">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:fit-to-size">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:fit-to-contour">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:textarea-vertical-align">
+            <choice>
+                <value>top</value>
+                <value>middle</value>
+                <value>bottom</value>
+                <value>justify</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:textarea-horizontal-align">
+            <choice>
+                <value>left</value>
+                <value>center</value>
+                <value>right</value>
+                <value>justify</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="fo:wrap-option">
+            <choice>
+                <value>no-wrap</value>
+                <value>wrap</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-elements" combine="interleave">
+    <optional>
+        <ref name="text-list-style"/>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:color-mode">
+            <choice>
+                <value>greyscale</value>
+                <value>mono</value>
+                <value>watermark</value>
+                <value>standard</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:color-inversion">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:luminance">
+            <ref name="percent"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:contrast">
+            <ref name="percent"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:gamma">
+            <ref name="percent"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:red">
+            <ref name="percent"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:green">
+            <ref name="percent"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:blue">
+            <ref name="percent"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:image-opacity">
+            <ref name="percent"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:shadow">
+            <choice>
+                <value>visible</value>
+                <value>hidden</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:shadow-offset-x">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="draw:shadow-offset-y">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:shadow-color">
+            <ref name="color"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:shadow-opacity">
+            <ref name="percent"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:start-line-spacing-horizontal">
+            <ref name="distance"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="draw:start-line-spacing-vertical">
+            <ref name="distance"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:end-line-spacing-horizontal">
+            <ref name="distance"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="draw:end-line-spacing-vertical">
+            <ref name="distance"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:line-distance">
+            <ref name="distance"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:guide-overhang">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:guide-distance">
+            <ref name="distance"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:start-guide">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:end-guide">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:placing">
+            <choice>
+                <value>below</value>
+                <value>above</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:parallel">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:measure-align">
+            <choice>
+                <value>automatic</value>
+                <value>left-outside</value>
+                <value>inside</value>
+                <value>right-outside</value>
+            </choice>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="draw:measure-vertical-align">
+            <choice>
+                <value>automatic</value>
+                <value>above</value>
+                <value>below</value>
+                <value>center</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:unit">
+            <choice>
+                <value>automatic</value>
+                <value>mm</value>
+                <value>cm</value>
+                <value>m</value>
+                <value>km</value>
+                <value>pt</value>
+                <value>pc</value>
+                <value>inch</value>
+                <value>ft</value>
+                <value>mi</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:show-unit">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:decimal-places">
+            <ref name="nonNegativeInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:caption-type">
+            <choice>
+                <value>straight-line</value>
+                <value>angled-line</value>
+                <value>angled-connector-line</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:caption-angle-type">
+            <choice>
+                <value>fixed</value>
+                <value>free</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:caption-angle">
+            <ref name="nonNegativeInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:caption-gap">
+            <ref name="distance"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:caption-escape-direction">
+            <choice>
+                <value>horizontal</value>
+                <value>vertical</value>
+                <value>auto</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:caption-escape">
+            <choice>
+                <ref name="length"/>
+                <ref name="percent"/>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:caption-line-length">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:caption-fit-line-length">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="dr3d:horizontal-segments">
+            <ref name="nonNegativeInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="dr3d:vertical-segments">
+            <ref name="nonNegativeInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="dr3d:edge-rounding">
+            <ref name="percent"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="dr3d:edge-rounding-mode">
+            <choice>
+                <value>correct</value>
+                <value>attractive</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="dr3d:back-scale">
+            <ref name="percent"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="dr3d:depth">
+            <ref name="length"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="dr3d:backface-culling">
+            <choice>
+                <value>enabled</value>
+                <value>disabled</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="dr3d:end-angle">
+            <ref name="nonNegativeInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="dr3d:close-front">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="dr3d:close-back">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="dr3d:lighting-mode">
+            <choice>
+                <value>standard</value>
+                <value>double-sided</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="dr3d:normals-kind">
+            <choice>
+                <value>object</value>
+                <value>flat</value>
+                <value>sphere</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="dr3d:normals-direction">
+            <choice>
+                <value>normal</value>
+                <value>inverse</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="dr3d:texture-generation-mode-x">
+            <choice>
+                <value>object</value>
+                <value>parallel</value>
+                <value>sphere</value>
+            </choice>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="dr3d:texture-generation-mode-y">
+            <choice>
+                <value>object</value>
+                <value>parallel</value>
+                <value>sphere</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="dr3d:texture-kind">
+            <choice>
+                <value>luminance</value>
+                <value>intensity</value>
+                <value>color</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="dr3d:texture-filter">
+            <choice>
+                <value>enabled</value>
+                <value>disabled</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="dr3d:texture-mode">
+            <choice>
+                <value>replace</value>
+                <value>modulate</value>
+                <value>blend</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="dr3d:ambient-color">
+            <ref name="color"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="dr3d:emissive-color">
+            <ref name="color"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="dr3d:specular-color">
+            <ref name="color"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="dr3d:diffuse-color">
+            <ref name="color"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="dr3d:shininess">
+            <ref name="percent"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="dr3d:shadow">
+            <choice>
+                <value>visible</value>
+                <value>hidden</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <ref name="common-draw-rel-size-attlist"/>
+    <optional>
+        <attribute name="fo:min-width">
+            <choice>
+                <ref name="length"/>
+                <ref name="percent"/>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="fo:min-height">
+            <choice>
+                <ref name="length"/>
+                <ref name="percent"/>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="fo:max-height">
+            <choice>
+                <ref name="length"/>
+                <ref name="percent"/>
+            </choice>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="fo:max-width">
+            <choice>
+                <ref name="length"/>
+                <ref name="percent"/>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <ref name="common-horizontal-margin-attlist"/>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <ref name="common-vertical-margin-attlist"/>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <ref name="common-margin-attlist"/>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:print-content">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:protect">
+            <choice>
+                <value>none</value>
+                <list>
+                    <oneOrMore>
+                        <choice>
+                            <value>content</value>
+                            <value>position</value>
+                            <value>size</value>
+                        </choice>
+                    </oneOrMore>
+                </list>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:horizontal-pos">
+            <choice>
+                <value>left</value>
+                <value>center</value>
+                <value>right</value>
+                <value>from-left</value>
+                <value>inside</value>
+                <value>outside</value>
+                <value>from-inside</value>
+            </choice>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="svg:x">
+            <ref name="coordinate"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:horizontal-rel">
+            <choice>
+                    <value>page</value>
+                <value>page-content</value>
+                <value>page-start-margin</value>
+                <value>page-end-margin</value>
+                <value>frame</value>
+                <value>frame-content</value>
+                <value>frame-start-margin</value>
+                <value>frame-end-margin</value>
+                <value>paragraph</value>
+                <value>paragraph-content</value>
+                <value>paragraph-start-margin</value>
+                <value>paragraph-end-margin</value>
+                <value>char</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <ref name="common-vertical-pos-attlist"/>
+</define>
+
+<define name="common-vertical-pos-attlist">
+    <optional>
+        <attribute name="style:vertical-pos">
+            <choice>
+                <value>top</value>
+                <value>middle</value>
+                <value>bottom</value>
+                <value>from-top</value>
+                <value>below</value>
+            </choice>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="svg:y">
+            <ref name="coordinate"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <ref name="common-vertical-rel-attlist"/>
+</define>
+
+<define name="common-vertical-rel-attlist">
+    <optional>
+        <attribute name="style:vertical-rel">
+            <choice>
+                <value>page</value>
+                <value>page-content</value>
+                <value>frame</value>
+                <value>frame-content</value>
+                <value>paragraph</value>
+                <value>paragraph-content</value>
+                <value>char</value>
+                <value>line</value>
+                <value>baseline</value>
+                <value>text</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <ref name="common-text-anchor-attlist"/>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <ref name="common-border-attlist"/>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <ref name="common-border-line-width-attlist"/>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <ref name="common-padding-attlist"/>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <ref name="common-shadow-attlist"/>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <ref name="common-background-color-attlist"/>
+</define>
+<define name="style-graphic-properties-elements" combine="interleave">
+    <ref name="style-background-image"/>
+</define>
+<define name="style-graphic-properties-elements" combine="interleave">
+    <ref name="style-columns"/>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:editable">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:wrap">
+            <choice>
+                <value>none</value>
+                <value>left</value>
+                <value>right</value>
+                <value>parallel</value>
+                <value>dynamic</value>
+                <value>run-through</value>
+                <value>biggest</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:wrap-dynamic-threshold">
+            <ref name="nonNegativeLength"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:number-wrapped-paragraphs">
+            <choice>
+                <value>no-limit</value>
+                <ref name="positiveInteger"/>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:wrap-contour">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:wrap-contour-mode">
+            <choice>
+                <value>full</value>
+                <value>outside</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:run-through">
+            <choice>
+                <value>foreground</value>
+                <value>background</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:flow-with-text">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:overflow-behavior">
+            <choice>
+                <value>clip</value>
+                <value>auto-create-new-frame</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="style:mirror">
+            <choice>
+                <value>none</value>
+                <value>vertical</value>
+                <ref name="horizontal-mirror"/>
+                <list>
+                    <value>vertical</value>
+                    <ref name="horizontal-mirror"/>
+                </list>
+                <list>
+                    <ref name="horizontal-mirror"/>
+                    <value>vertical</value>
+                </list>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+
+<define name="horizontal-mirror">
+    <choice>
+        <value>horizontal</value>
+        <value>horizontal-on-odd</value>
+        <value>horizontal-on-even</value>
+    </choice>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="fo:clip">
+            <!-- The attribute value must match the one XSL's clip -->
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:wrap-influence-on-position"
+                    a:defaultValue="iterative">
+            <choice>
+                <value>iterative</value>
+                <value>once-concurrent</value>
+                <value>once-successive</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <ref name="common-writing-mode-attlist"/>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:frame-display-scrollbar">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:frame-display-border">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:frame-margin-horizontal">
+            <ref name="nonNegativePixelLength"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="draw:frame-margin-vertical">
+            <ref name="nonNegativePixelLength"/>
+        </attribute>
+    </optional>
+</define>
+
+<define name="nonNegativePixelLength">
+    <data type="string">
+        <param name="pattern">([0-9]+(\.[0-9]*)?|\.[0-9]+)(px)</param>
+    </data>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:visible-area-left">
+            <ref name="nonNegativeLength"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="draw:visible-area-top">
+            <ref name="nonNegativeLength"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="draw:visible-area-width">
+            <ref name="positiveLength"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="draw:visible-area-height">
+            <ref name="positiveLength"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-graphic-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="draw:ole-draw-aspect">
+            <ref name="nonNegativeInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-chart-properties">
+    <element name="style:chart-properties">
+        <ref name="style-chart-properties-content"/>
+    </element>
+</define>
+
+<define name="style-chart-properties-content">
+    <ref name="style-properties-content"/>
+</define>
+
+<define name="style-chart-properties-content-strict">
+    <ref name="style-chart-properties-attlist"/>
+    <ref name="style-chart-properties-elements"/>
+</define>
+
+<define name="style-chart-properties-elements">
+    <empty/>
+</define>
+<define name="style-chart-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:scale-text" a:defaultValue="true">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-chart-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:three-dimensional">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-chart-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:deep">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-chart-properties-attlist" combine="interleave">
+    <choice>
+        <attribute name="chart:symbol-type">
+            <value>none</value>
+        </attribute>
+        <attribute name="chart:symbol-type">
+            <value>automatic</value>
+        </attribute>
+        <group>
+            <attribute name="chart:symbol-type">
+                <value>named-symbol</value>
+            </attribute>
+            <attribute name="chart:symbol-name">
+                <choice>
+                    <value>square</value>
+                    <value>diamond</value>
+                    <value>arrow-down</value>
+                    <value>arrow-up</value>
+                    <value>arrow-right</value>
+                    <value>arrow-left</value>
+                    <value>bow-tie</value>
+                    <value>hourglass</value>
+                    <value>circle</value>
+                    <value>star</value>
+                    <value>x</value>
+                    <value>plus</value>
+                    <value>asterisk</value>
+                    <value>horizontal-bar</value>
+                    <value>vertical-bar</value>
+                </choice>
+            </attribute>
+        </group>
+        <group>
+            <attribute name="chart:symbol-type">
+                <value>image</value>
+            </attribute>
+            <element name="chart:symbol-image">
+                <attribute name="xlink:href">
+                    <ref name="anyURI"/>
+                </attribute>
+            </element>
+        </group>
+        <empty/>
+    </choice>
+</define>
+<define name="style-chart-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:symbol-width">
+            <ref name="nonNegativeLength"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="chart:symbol-height">
+            <ref name="nonNegativeLength"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-chart-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:vertical" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-chart-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:connect-bars" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-chart-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:gap-width">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="chart:overlap">
+            <ref name="integer"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-chart-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:japanese-candle-stick"
+                    a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-chart-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:interpolation" a:defaultValue="none">
+            <choice>
+                <value>none</value>
+                <value>cubic-spline</value>
+                <value>b-spline</value>
+            </choice>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="chart:spline-order" a:defaultValue="2">
+            <ref name="positiveInteger"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="chart:spline-resolution" a:defaultValue="20">
+            <ref name="positiveInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-chart-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:pie-offset" a:defaultValue="0">
+            <ref name="nonNegativeInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-chart-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:lines" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-chart-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:solid-type" a:defaultValue="cuboid">
+            <choice>
+                <value>cuboid</value>
+                <value>cylinder</value>
+                <value>cone</value>
+                <value>pyramid</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-chart-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:stacked" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="chart:percentage" a:defaultValue="false">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-chart-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:link-data-style-to-source">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-chart-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:visible">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-chart-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:logarithmic">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-chart-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:maximum">
+            <ref name="double"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="chart:minimum">
+            <ref name="double"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="chart:origin">
+            <ref name="double"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="chart:interval-major">
+            <ref name="double"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="chart:interval-minor-divisor">
+            <ref name="positiveInteger"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-chart-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:tick-marks-major-inner">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="chart:tick-marks-major-outer">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="chart:tick-marks-minor-inner">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="chart:tick-marks-minor-outer">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-chart-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:display-label">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="chart:text-overlap">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="text:line-break">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="chart:label-arrangement"
+                   a:defaultValue="side-by-side">
+            <choice>
+                <value>side-by-side</value>
+                <value>stagger-even</value>
+                <value>stagger-odd</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-chart-properties-attlist" combine="interleave">
+    <ref name="common-style-direction-attlist"/>
+</define>
+<define name="style-chart-properties-attlist" combine="interleave">
+    <ref name="common-rotation-angle-attlist"/>
+</define>
+<define name="style-chart-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:data-label-number">
+            <choice>
+                <value>none</value>
+                <value>value</value>
+                <value>percentage</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-chart-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:data-label-text">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-chart-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:data-label-symbol">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-chart-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:mean-value">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-chart-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:error-category" a:defaultValue="none">
+            <choice>
+                <value>none</value>
+                <value>variance</value>
+                <value>standard-deviation</value>
+                <value>percentage</value>
+                <value>error-margin</value>
+                <value>constant</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-chart-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:error-percentage">
+            <ref name="double"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-chart-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:error-margin">
+            <ref name="double"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-chart-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:error-lower-limit">
+            <ref name="double"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="chart:error-upper-limit">
+            <ref name="double"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-chart-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:error-upper-indicator">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+    <optional>
+        <attribute name="chart:error-lower-indicator">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-chart-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:series-source" a:defaultValue="columns">
+            <choice>
+                <value>columns</value>
+                <value>rows</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-chart-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="chart:regression-type" a:defaultValue="none">
+            <choice>
+                <value>none</value>
+                <value>linear</value>
+                <value>logarithmic</value>
+                <value>exponential</value>
+                <value>power</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-drawing-page-properties-attlist"
+        combine="interleave">
+    <optional>
+        <attribute name="presentation:transition-type">
+            <choice>
+                <value>manual</value>
+                <value>automatic</value>
+                <value>semi-automatic</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-drawing-page-properties-attlist"
+         combine="interleave">
+    <optional>
+        <attribute name="presentation:transition-style">
+            <choice>
+                <value>none</value>
+                <value>fade-from-left</value>
+                <value>fade-from-top</value>
+                <value>fade-from-right</value>
+                <value>fade-from-bottom</value>
+                <value>fade-from-upperleft</value>
+                <value>fade-from-upperright</value>
+                <value>fade-from-lowerleft</value>
+                <value>fade-from-lowerright</value>
+                <value>move-from-left</value>
+                <value>move-from-top</value>
+                <value>move-from-right</value>
+                <value>move-from-bottom</value>
+                <value>move-from-upperleft</value>
+                <value>move-from-upperright</value>
+                <value>move-from-lowerleft</value>
+                <value>move-from-lowerright</value>
+                <value>uncover-to-left</value>
+                <value>uncover-to-top</value>
+                <value>uncover-to-right</value>    
+                <value>uncover-to-bottom</value>
+                <value>uncover-to-upperleft</value>
+                <value>uncover-to-upperright</value>
+                <value>uncover-to-lowerleft</value>
+                <value>uncover-to-lowerright</value>
+                <value>fade-to-center</value>
+                <value>fade-from-center</value>
+                <value>vertical-stripes</value>
+                <value>horizontal-stripes</value>
+                <value>clockwise</value>
+                <value>counterclockwise</value>
+                <value>open-vertical</value>
+                <value>open-horizontal</value>
+                <value>close-vertical</value>
+                <value>close-horizontal</value>
+                <value>wavyline-from-left</value>
+                <value>wavyline-from-top</value>
+                <value>wavyline-from-right</value>
+                <value>wavyline-from-bottom</value>
+                <value>spiralin-left</value>
+                <value>spiralin-right</value>
+                <value>spiralout-left</value>
+                <value>spiralout-right</value>
+                <value>roll-from-top</value>
+                <value>roll-from-left</value>
+                <value>roll-from-right</value>
+                <value>roll-from-bottom</value>
+                <value>stretch-from-left</value>
+                <value>stretch-from-top</value>
+                <value>stretch-from-right</value>
+                <value>stretch-from-bottom</value>
+
+                <value>vertical-lines</value>
+                <value>horizontal-lines</value>
+                <value>dissolve</value>
+                <value>random</value>
+                <value>vertical-checkerboard</value>
+                <value>horizontal-checkerboard</value>
+                <value>interlocking-horizontal-left</value>
+                <value>interlocking-horizontal-right</value>
+                <value>interlocking-vertical-top</value>
+                <value>interlocking-vertical-bottom</value>
+                <value>fly-away</value>
+                <value>open</value>
+                <value>close</value>
+                <value>melt</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-drawing-page-properties-attlist"
+        combine="interleave">
+    <optional>
+        <attribute name="presentation:transition-speed">
+            <ref name="presentationSpeeds"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-drawing-page-properties-attlist " combine="interleave">
+    <optional>
+        <attribute name="smil:type">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-drawing-page-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="smil:subtype">
+            <ref name="string"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-drawing-page-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="smil:direction" a:defaultValue="forward">
+            <choice>
+                <value>forward</value>
+                <value>reverse</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-drawing-page-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="smil:fadeColor">
+            <ref name="color"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-drawing-page-properties-attlist"
+        combine="interleave">
+    <optional>
+        <attribute name="presentation:duration">
+            <ref name="duration"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-drawing-page-properties-attlist"
+         combine="interleave">
+    <optional>
+        <attribute name="presentation:visibility">
+            <choice>
+                <value>visible</value>
+                <value>hidden</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-drawing-page-properties-elements"
+         combine="interleave">
+    <optional>
+        <ref name="presentation-sound"/>
+    </optional>
+</define>
+<define name="style-drawing-page-properties-attlist"
+         combine="interleave">
+    <optional>
+        <attribute name="draw:background-size">
+            <choice>
+                <value>full</value>
+                <value>border</value>
+            </choice>
+        </attribute>
+    </optional>
+</define>
+<define name="style-drawing-page-properties-attlist"
+         combine="interleave">
+    <optional>
+        <attribute name="presentation:background-objects-visible">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-drawing-page-properties-attlist"
+         combine="interleave">
+    <optional>
+        <attribute name="presentation:background-visible">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-drawing-page-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:display-header">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-drawing-page-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:display-footer">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-drawing-page-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:display-page-number">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="style-drawing-page-properties-attlist" combine="interleave">
+    <optional>
+        <attribute name="presentation:display-date-time">
+            <ref name="boolean"/>
+        </attribute>
+    </optional>
+</define>
+<define name="string">
+    <data type="string"/>
+</define>
+<define name="date">
+    <data type="date"/>
+</define>
+<define name="time">
+    <data type="time"/>
+</define>
+<define name="dateTime">
+    <data type="dateTime"/>
+</define>
+<define name="duration">
+    <data type="duration"/>
+</define>
+<define name="integer">
+    <data type="integer"/>
+</define>
+<define name="nonNegativeInteger">
+    <data type="nonNegativeInteger"/>
+</define>
+<define name="positiveInteger">
+    <data type="positiveInteger"/>
+</define>
+<define name="double">
+    <data type="double"/>
+</define>
+<define name="anyURI">
+    <data type="anyURI"/>
+</define>
+<define name="base64Binary">
+    <data type="base64Binary"/>
+</define>
+<define name="ID">
+    <data type="ID"/>
+</define>
+<define name="IDREF">
+    <data type="IDREF"/>
+</define>
+<define name="IDREFS">
+    <data type="IDREFS"/>
+</define>
+<define name="boolean">
+    <choice>
+        <value>true</value>
+        <value>false</value>
+    </choice>
+</define>
+<define name="dateOrDateTime">
+    <choice>
+        <data type="date"/>
+        <data type="dateTime"/>
+    </choice>
+</define>
+<define name="timeOrDateTime">
+    <choice>
+        <data type="time"/>
+        <data type="dateTime"/>
+    </choice>
+</define>
+<define name="language">
+    <data type="language"/>
+</define>
+<define name="countryCode">
+    <data type="token">
+        <param name="pattern">[A-Za-z0-9]{1,8}</param>
+    </data>
+</define>
+<define name="languageCode">
+    <data type="token">
+        <param name="pattern">[A-Za-z]{1,8}</param>
+    </data>
+</define>
+<define name="character">
+    <data type="string">
+        <param name="length">1</param>
+    </data>
+</define>
+<define name="length">
+    <data type="string">
+        <param name="pattern">-?([0-9]+(\.[0-9]*)?|\.[0-9]+)((cm)|(mm)|(in)|(pt)|(pc)|(px))</param>
+
+    </data>
+</define>
+<define name="nonNegativeLength">
+    <data type="string">
+        <param name="pattern">([0-9]+(\.[0-9]*)?|\.[0-9]+)((cm)|(mm)|(in)|(pt)|(pc)|(px))</param>
+
+    </data>
+</define>
+<define name="positiveLength">
+    <data type="string">
+        <param name="pattern">([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))</param>
+
+    </data>
+</define>
+<define name="percent">
+    <data type="string">
+        <param name="pattern">-?([0-9]+(\.[0-9]*)?|\.[0-9]+)%</param>
+    </data>
+</define>
+<define name="relativeLength">
+    <data type="string">
+        <param name="pattern">[0-9]+\*</param>
+    </data>
+</define>
+<define name="coordinate">
+    <ref name="length"/>
+</define>
+<define name="distance">
+    <ref name="length"/>
+</define>
+<define name="color">
+    <data type="string">
+        <param name="pattern">#[0-9a-fA-F]{6}</param>
+    </data>
+</define>
+<define name="styleName">
+    <data type="NCName"/>
+</define>
+<define name="styleNameRef">
+    <choice>
+        <data type="NCName"/>
+        <empty/>
+    </choice>
+</define>
+<define name="styleNameRefs">
+    <list>
+        <zeroOrMore>
+            <data type="NCName"/>
+        </zeroOrMore>
+    </list>
+</define>
+<define name="variableName">
+    <data type="string"/>
+</define>
+<define name="formula">
+    <!-- A formula should start with a namespace prefix, -->
+    <!-- but has no restrictions-->
+    <data type="string"/>
+</define>
+
+<define name="targetFrameName">
+    <choice>
+        <value>_self</value>
+        <value>_blank</value>
+        <value>_parent</value>
+        <value>_top</value>
+        <ref name="string"/>
+    </choice>
+</define>
+
+<define name="valueType">
+    <choice>
+        <value>float</value>
+        <value>time</value>
+        <value>date</value>
+        <value>percentage</value>
+        <value>currency</value>
+        <value>boolean</value>
+        <value>string</value>
+    </choice>
+</define>
+
+<define name="points">
+    <data type="string">
+        <param name="pattern">-?[0-9]+,-?[0-9]+([ ]+-?[0-9]+,-?[0-9]+)*</param>
+    </data>
+</define>
+<define name="pathData">
+    <data type="string"/>
+</define>
+
+<define name="vector3D">
+    <data type="string">
+        <param name="pattern">\([ ]*-?([0-9]+(\.[0-9]*)?|\.[0-9]+)([ ]+-?([0-9]+(\.[0-9]*)?|\.[0-9]+)){2}[ ]*\)</param>
+
+    </data>
+</define>
+
+<define name="namespacedToken">
+    <data type="string">
+        <param name="pattern">[0-9a-zA-Z_]+:[0-9a-zA-Z._\-]+</param>
+    </data>
+</define>
+<define name="anyAttListOrElements">
+    <zeroOrMore>
+        <attribute>
+            <anyName/>
+            <text/>
+        </attribute>
+    </zeroOrMore>
+    <ref name="anyElements"/>
+</define>
+<define name="anyElements">
+    <zeroOrMore>
+        <element>
+            <anyName/>
+            <mixed>
+                <ref name="anyAttListOrElements"/>
+            </mixed>
+        </element>
+    </zeroOrMore>
+</define>
+</grammar>

+ 224 - 0
contrib/odt/OASIS/OpenDocument-v1.2-cs01-manifest-schema.rng

@@ -0,0 +1,224 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+        Open Document Format for Office Applications (OpenDocument) Version 1.2
+        Committee Specification (CS) 01, 17 March 2011
+	Manifest Relax-NG Schema
+
+        Copyright (c) OASIS Open 2002-2011. All Rights Reserved.
+
+	All capitalized terms in the following text have the meanings assigned to them
+   	in the OASIS Intellectual Property Rights Policy (the "OASIS IPR Policy"). The
+	full Policy may be found at the OASIS website.
+
+	This document and translations of it may be copied and furnished to others, and
+	derivative works that comment on or otherwise explain it or assist in its
+	implementation may be prepared, copied, published, and distributed, in whole or
+	in part, without restriction of any kind, provided that the above copyright
+	notice and this section are included on all such copies and derivative works.
+	However, this document itself may not be modified in any way, including by
+	removing the copyright notice or references to OASIS, except as needed for the
+	purpose of developing any document or deliverable produced by an OASIS
+	Technical Committee (in which case the rules applicable to copyrights, as set
+	forth in the OASIS IPR Policy, must be followed) or as required to translate it
+	into languages other than English.
+
+	The limited permissions granted above are perpetual and will not be revoked by
+	OASIS or its successors or assigns.
+
+	This document and the information contained herein is provided on an "AS IS"
+	basis and OASIS DISCLAIMS ALL WARRANTIES, EXPRESS OR IMPLIED, INCLUDING BUT NOT
+	LIMITED TO ANY WARRANTY THAT THE USE OF THE INFORMATION HEREIN WILL NOT
+	INFRINGE ANY OWNERSHIP RIGHTS OR ANY IMPLIED WARRANTIES OF MERCHANTABILITY OR
+	FITNESS FOR A PARTICULAR PURPOSE. 
+-->
+<grammar 
+	xmlns="http://relaxng.org/ns/structure/1.0"
+
+	datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes"
+
+	xmlns:manifest="urn:oasis:names:tc:opendocument:xmlns:manifest:1.0"
+>
+<start>
+	<choice>
+		<ref name="manifest"/>
+	</choice>
+</start>
+<define name="manifest">
+	<element name="manifest:manifest">
+		<ref name="manifest-attlist"/>
+		<oneOrMore>
+			<ref name="file-entry"/>
+		</oneOrMore>
+	</element>
+</define>
+<define name="manifest-attlist">
+	<attribute name="manifest:version">
+		<value>1.2</value>
+	</attribute>
+</define>
+<define name="file-entry">
+	<element name="manifest:file-entry">
+		<ref name="file-entry-attlist"/>
+		<optional>
+			<ref name="encryption-data"/>
+		</optional>
+	</element>
+</define>
+<define name="file-entry-attlist">
+  <interleave>
+	<attribute name="manifest:full-path">
+		<ref name="string"/>
+	</attribute>
+	<optional>
+		<attribute name="manifest:size">
+			<ref name="nonNegativeInteger"/>
+		</attribute>
+	</optional>
+	<attribute name="manifest:media-type">
+		<ref name="string"/>
+	</attribute>
+	<optional>
+		<attribute name="manifest:preferred-view-mode">
+			<choice>
+				<value>edit</value>
+				<value>presentation-slide-show</value>
+				<value>read-only</value>
+				<ref name="namespacedToken"/> 
+			</choice> 
+		</attribute> 
+	</optional> 
+	<optional>
+		<attribute name="manifest:version">
+			<ref name="string"/>
+		</attribute>
+	</optional>
+  </interleave>
+</define>
+
+<define name="encryption-data">
+	<element name="manifest:encryption-data">
+		<ref name="encryption-data-attlist"/>
+		<ref name="algorithm"/>
+		<optional>
+			<ref name="start-key-generation"/>
+		</optional>
+		<ref name="key-derivation"/>
+	</element>
+</define>
+<define name="encryption-data-attlist">
+  <interleave>
+	<attribute name="manifest:checksum-type">
+		<choice>
+			<value>SHA1/1K</value>
+			<ref name="anyURI"/>
+		</choice>
+	</attribute>
+	<attribute name="manifest:checksum">
+		<ref name="base64Binary"/>
+	</attribute>
+  </interleave>
+</define>
+<define name="algorithm">
+	<element name="manifest:algorithm">
+		<ref name="algorithm-attlist"/>
+		<ref name="anyElements"/>
+	</element>
+</define>
+<define name="algorithm-attlist">
+  <interleave>
+	<attribute name="manifest:algorithm-name">
+		<choice>
+			<value>Blowfish CFB</value>
+			<ref name="anyURI"/>
+		</choice>
+	</attribute>
+	<attribute name="manifest:initialisation-vector">
+		<ref name="base64Binary"/>
+	</attribute>
+  </interleave>
+</define>
+<define name="anyAttListOrElements">
+	<zeroOrMore>
+		<attribute>
+			<anyName/>
+			<text/>
+		</attribute>
+	</zeroOrMore>
+	<ref name="anyElements"/>
+</define>
+<define name="anyElements">
+	<zeroOrMore>
+		<element>
+			<anyName/>
+			<mixed>
+				<ref name="anyAttListOrElements"/>
+			</mixed>
+		</element>
+	</zeroOrMore>
+</define>
+<define name="key-derivation">
+	<element name="manifest:key-derivation">
+		<ref name="key-derivation-attlist"/>
+		<empty/>
+	</element>
+</define>
+<define name="key-derivation-attlist">
+  <interleave>
+	<attribute name="manifest:key-derivation-name">
+		<choice>
+			<value>PBKDF2</value>
+			<ref name="anyURI"/>
+		</choice>
+	</attribute>
+	<attribute name="manifest:salt">
+		<ref name="base64Binary"/>
+	</attribute>
+	<attribute name="manifest:iteration-count">
+			<ref name="nonNegativeInteger"/>
+		</attribute>
+	<optional>
+		<attribute name="manifest:key-size">
+			<ref name="nonNegativeInteger"/>
+		</attribute>
+	</optional>
+  </interleave>
+</define>
+<define name="start-key-generation">
+	<element name="manifest:start-key-generation">
+		<ref name="start-key-generation-attlist"/>
+		<empty/>
+	</element>
+</define>
+<define name="start-key-generation-attlist">
+  <interleave>
+	<attribute name="manifest:start-key-generation-name">
+		<choice>
+			<value>SHA1</value>
+			<ref name="anyURI"/>
+		</choice>
+	</attribute>
+	<optional>
+		<attribute name="manifest:key-size">
+			<ref name="nonNegativeInteger"/>
+		</attribute>
+	</optional>
+  </interleave>
+</define>
+<define name="base64Binary">
+	<data type="base64Binary"/>
+</define>
+<define name="namespacedToken">
+	<data type="QName">
+		<param name="pattern">[^:]+:[^:]+</param>
+	</data>
+</define>
+<define name="nonNegativeInteger">
+	<data type="nonNegativeInteger"/>
+</define>
+<define name="string">
+	<data type="string"/>
+</define>
+<define name="anyURI">
+	<data type="anyURI"/>
+</define>
+</grammar>

+ 18127 - 0
contrib/odt/OASIS/OpenDocument-v1.2-cs01-schema.rng

@@ -0,0 +1,18127 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+        Open Document Format for Office Applications (OpenDocument) Version 1.2
+        Committee Specification (CS) 01, 17 March 2011
+	Relax-NG Schema
+
+        Copyright (c) OASIS Open 2002-2011. All Rights Reserved.
+
+	All capitalized terms in the following text have the meanings assigned to them
+	in the OASIS Intellectual Property Rights Policy (the "OASIS IPR Policy"). The
+	full Policy may be found at the OASIS website.
+
+	This document and translations of it may be copied and furnished to others, and
+	derivative works that comment on or otherwise explain it or assist in its
+	implementation may be prepared, copied, published, and distributed, in whole or
+	in part, without restriction of any kind, provided that the above copyright
+	notice and this section are included on all such copies and derivative works.
+	However, this document itself may not be modified in any way, including by
+	removing the copyright notice or references to OASIS, except as needed for the
+	purpose of developing any document or deliverable produced by an OASIS
+	Technical Committee (in which case the rules applicable to copyrights, as set
+	forth in the OASIS IPR Policy, must be followed) or as required to translate it
+	into languages other than English.
+
+	The limited permissions granted above are perpetual and will not be revoked by
+	OASIS or its successors or assigns.
+
+	This document and the information contained herein is provided on an "AS IS"
+	basis and OASIS DISCLAIMS ALL WARRANTIES, EXPRESS OR IMPLIED, INCLUDING BUT NOT
+	LIMITED TO ANY WARRANTY THAT THE USE OF THE INFORMATION HEREIN WILL NOT
+	INFRINGE ANY OWNERSHIP RIGHTS OR ANY IMPLIED WARRANTIES OF MERCHANTABILITY OR
+	FITNESS FOR A PARTICULAR PURPOSE. 
+-->
+<grammar
+	xmlns="http://relaxng.org/ns/structure/1.0"
+
+	datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes"
+
+	xmlns:office="urn:oasis:names:tc:opendocument:xmlns:office:1.0"
+	xmlns:meta="urn:oasis:names:tc:opendocument:xmlns:meta:1.0"
+	xmlns:config="urn:oasis:names:tc:opendocument:xmlns:config:1.0"
+	xmlns:text="urn:oasis:names:tc:opendocument:xmlns:text:1.0"
+	xmlns:table="urn:oasis:names:tc:opendocument:xmlns:table:1.0"
+	xmlns:draw="urn:oasis:names:tc:opendocument:xmlns:drawing:1.0"
+	xmlns:presentation="urn:oasis:names:tc:opendocument:xmlns:presentation:1.0"
+	xmlns:dr3d="urn:oasis:names:tc:opendocument:xmlns:dr3d:1.0"
+	xmlns:chart="urn:oasis:names:tc:opendocument:xmlns:chart:1.0"
+	xmlns:form="urn:oasis:names:tc:opendocument:xmlns:form:1.0"
+	xmlns:db="urn:oasis:names:tc:opendocument:xmlns:database:1.0"
+	xmlns:script="urn:oasis:names:tc:opendocument:xmlns:script:1.0"
+	xmlns:style="urn:oasis:names:tc:opendocument:xmlns:style:1.0"
+	xmlns:number="urn:oasis:names:tc:opendocument:xmlns:datastyle:1.0"
+	xmlns:anim="urn:oasis:names:tc:opendocument:xmlns:animation:1.0"
+
+	xmlns:dc="http://purl.org/dc/elements/1.1/"
+	xmlns:xlink="http://www.w3.org/1999/xlink"
+	xmlns:math="http://www.w3.org/1998/Math/MathML"
+	xmlns:xforms="http://www.w3.org/2002/xforms"
+	xmlns:grddl="http://www.w3.org/2003/g/data-view#"
+	xmlns:xhtml="http://www.w3.org/1999/xhtml"
+
+	xmlns:fo="urn:oasis:names:tc:opendocument:xmlns:xsl-fo-compatible:1.0"
+	xmlns:svg="urn:oasis:names:tc:opendocument:xmlns:svg-compatible:1.0"
+	xmlns:smil="urn:oasis:names:tc:opendocument:xmlns:smil-compatible:1.0"
+>
+	<define name="office-process-content">
+		<optional>
+			<attribute name="office:process-content">
+				<ref name="boolean"/>
+			</attribute>
+		</optional>
+	</define>
+	<start>
+		<choice>
+			<ref name="office-document"/>
+			<ref name="office-document-content"/>
+			<ref name="office-document-styles"/>
+			<ref name="office-document-meta"/>
+			<ref name="office-document-settings"/>
+		</choice>
+	</start>
+	<define name="office-document">
+		<element name="office:document">
+			<ref name="office-document-attrs"/>
+			<ref name="office-document-common-attrs"/>
+			<ref name="office-meta"/>
+			<ref name="office-settings"/>
+			<ref name="office-scripts"/>
+			<ref name="office-font-face-decls"/>
+			<ref name="office-styles"/>
+			<ref name="office-automatic-styles"/>
+			<ref name="office-master-styles"/>
+			<ref name="office-body"/>
+		</element>
+	</define>
+	<define name="office-document-content">
+		<element name="office:document-content">
+			<ref name="office-document-common-attrs"/>
+			<ref name="office-scripts"/>
+			<ref name="office-font-face-decls"/>
+			<ref name="office-automatic-styles"/>
+			<ref name="office-body"/>
+		</element>
+	</define>
+	<define name="office-document-styles">
+		<element name="office:document-styles">
+			<ref name="office-document-common-attrs"/>
+			<ref name="office-font-face-decls"/>
+			<ref name="office-styles"/>
+			<ref name="office-automatic-styles"/>
+			<ref name="office-master-styles"/>
+		</element>
+	</define>
+	<define name="office-document-meta">
+		<element name="office:document-meta">
+			<ref name="office-document-common-attrs"/>
+			<ref name="office-meta"/>
+		</element>
+	</define>
+	<define name="office-document-settings">
+		<element name="office:document-settings">
+			<ref name="office-document-common-attrs"/>
+			<ref name="office-settings"/>
+		</element>
+	</define>
+	<define name="office-document-common-attrs">
+		<interleave>
+			<attribute name="office:version">
+				<value>1.2</value>
+			</attribute>
+			<optional>
+				<attribute name="grddl:transformation">
+					<list>
+						<zeroOrMore>
+							<ref name="anyIRI"/>
+						</zeroOrMore>
+					</list>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="office-document-attrs">
+		<attribute name="office:mimetype">
+			<ref name="string"/>
+		</attribute>
+	</define>
+	<define name="office-meta">
+		<optional>
+			<element name="office:meta">
+				<ref name="office-meta-content-strict"/>
+			</element>
+		</optional>
+	</define>
+	<define name="office-meta-content-strict">
+		<zeroOrMore>
+			<ref name="office-meta-data"/>
+		</zeroOrMore>
+	</define>
+	<define name="office-body">
+		<element name="office:body">
+			<ref name="office-body-content"/>
+		</element>
+	</define>
+	<define name="office-body-content">
+		<choice>
+			<element name="office:text">
+				<ref name="office-text-attlist"/>
+				<ref name="office-text-content-prelude"/>
+				<ref name="office-text-content-main"/>
+				<ref name="office-text-content-epilogue"/>
+			</element>
+			<element name="office:drawing">
+				<ref name="office-drawing-attlist"/>
+				<ref name="office-drawing-content-prelude"/>
+				<ref name="office-drawing-content-main"/>
+				<ref name="office-drawing-content-epilogue"/>
+			</element>
+			<element name="office:presentation">
+				<ref name="office-presentation-attlist"/>
+				<ref name="office-presentation-content-prelude"/>
+				<ref name="office-presentation-content-main"/>
+				<ref name="office-presentation-content-epilogue"/>
+			</element>
+			<element name="office:spreadsheet">
+				<ref name="office-spreadsheet-attlist"/>
+				<ref name="office-spreadsheet-content-prelude"/>
+				<ref name="office-spreadsheet-content-main"/>
+				<ref name="office-spreadsheet-content-epilogue"/>
+			</element>
+			<element name="office:chart">
+				<ref name="office-chart-attlist"/>
+				<ref name="office-chart-content-prelude"/>
+				<ref name="office-chart-content-main"/>
+				<ref name="office-chart-content-epilogue"/>
+			</element>
+			<element name="office:image">
+				<ref name="office-image-attlist"/>
+				<ref name="office-image-content-prelude"/>
+				<ref name="office-image-content-main"/>
+				<ref name="office-image-content-epilogue"/>
+			</element>
+			<ref name="office-database"/>
+		</choice>
+	</define>
+	<define name="office-text-content-prelude">
+		<ref name="office-forms"/>
+		<ref name="text-tracked-changes"/>
+		<ref name="text-decls"/>
+		<ref name="table-decls"/>
+	</define>
+	<define name="office-text-content-main">
+		<choice>
+			<zeroOrMore>
+				<ref name="text-content"/>
+			</zeroOrMore>
+			<group>
+				<ref name="text-page-sequence"/>
+				<zeroOrMore>
+					<choice>
+						<ref name="shape"/>
+					</choice>
+				</zeroOrMore>
+			</group>
+		</choice>
+	</define>
+	<define name="text-content">
+		<choice>
+			<ref name="text-h"/>
+			<ref name="text-p"/>
+			<ref name="text-list"/>
+			<ref name="text-numbered-paragraph"/>
+			<ref name="table-table"/>
+			<ref name="text-section"/>
+			<ref name="text-soft-page-break"/>
+			<ref name="text-table-of-content"/>
+			<ref name="text-illustration-index"/>
+			<ref name="text-table-index"/>
+			<ref name="text-object-index"/>
+			<ref name="text-user-index"/>
+			<ref name="text-alphabetical-index"/>
+			<ref name="text-bibliography"/>
+			<ref name="shape"/>
+			<ref name="change-marks"/>
+		</choice>
+	</define>
+	<define name="office-text-content-epilogue">
+		<ref name="table-functions"/>
+	</define>
+	<define name="office-text-attlist">
+		<interleave>
+			<optional>
+				<attribute name="text:global">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:use-soft-page-breaks">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="office-drawing-attlist">
+		<empty/>
+	</define>
+	<define name="office-drawing-content-prelude">
+		<ref name="text-decls"/>
+		<ref name="table-decls"/>
+	</define>
+	<define name="office-drawing-content-main">
+		<zeroOrMore>
+			<ref name="draw-page"/>
+		</zeroOrMore>
+	</define>
+	<define name="office-drawing-content-epilogue">
+		<ref name="table-functions"/>
+	</define>
+	<define name="office-presentation-attlist">
+		<empty/>
+	</define>
+	<define name="office-presentation-content-prelude">
+		<ref name="text-decls"/>
+		<ref name="table-decls"/>
+		<ref name="presentation-decls"/>
+	</define>
+	<define name="office-presentation-content-main">
+		<zeroOrMore>
+			<ref name="draw-page"/>
+		</zeroOrMore>
+	</define>
+	<define name="office-presentation-content-epilogue">
+		<ref name="presentation-settings"/>
+		<ref name="table-functions"/>
+	</define>
+	<define name="office-spreadsheet-content-prelude">
+		<optional>
+			<ref name="table-tracked-changes"/>
+		</optional>
+		<ref name="text-decls"/>
+		<ref name="table-decls"/>
+	</define>
+	<define name="table-decls">
+		<optional>
+			<ref name="table-calculation-settings"/>
+		</optional>
+		<optional>
+			<ref name="table-content-validations"/>
+		</optional>
+		<optional>
+			<ref name="table-label-ranges"/>
+		</optional>
+	</define>
+	<define name="office-spreadsheet-content-main">
+		<zeroOrMore>
+			<ref name="table-table"/>
+		</zeroOrMore>
+	</define>
+	<define name="office-spreadsheet-content-epilogue">
+		<ref name="table-functions"/>
+	</define>
+	<define name="table-functions">
+		<optional>
+			<ref name="table-named-expressions"/>
+		</optional>
+		<optional>
+			<ref name="table-database-ranges"/>
+		</optional>
+		<optional>
+			<ref name="table-data-pilot-tables"/>
+		</optional>
+		<optional>
+			<ref name="table-consolidation"/>
+		</optional>
+		<optional>
+			<ref name="table-dde-links"/>
+		</optional>
+	</define>
+	<define name="office-chart-attlist">
+		<empty/>
+	</define>
+	<define name="office-chart-content-prelude">
+		<ref name="text-decls"/>
+		<ref name="table-decls"/>
+	</define>
+	<define name="office-chart-content-main">
+		<ref name="chart-chart"/>
+	</define>
+	<define name="office-chart-content-epilogue">
+		<ref name="table-functions"/>
+	</define>
+	<define name="office-image-attlist">
+		<empty/>
+	</define>
+	<define name="office-image-content-prelude">
+		<empty/>
+	</define>
+	<define name="office-image-content-main">
+		<ref name="draw-frame"/>
+	</define>
+	<define name="office-image-content-epilogue">
+		<empty/>
+	</define>
+	<define name="office-settings">
+		<optional>
+			<element name="office:settings">
+				<oneOrMore>
+					<ref name="config-config-item-set"/>
+				</oneOrMore>
+			</element>
+		</optional>
+	</define>
+	<define name="config-config-item-set">
+		<element name="config:config-item-set">
+			<ref name="config-config-item-set-attlist"/>
+			<ref name="config-items"/>
+		</element>
+	</define>
+	<define name="config-items">
+		<oneOrMore>
+			<choice>
+				<ref name="config-config-item"/>
+				<ref name="config-config-item-set"/>
+				<ref name="config-config-item-map-named"/>
+				<ref name="config-config-item-map-indexed"/>
+			</choice>
+		</oneOrMore>
+	</define>
+	<define name="config-config-item-set-attlist">
+		<attribute name="config:name">
+			<ref name="string"/>
+		</attribute>
+	</define>
+	<define name="config-config-item">
+		<element name="config:config-item">
+			<ref name="config-config-item-attlist"/>
+			<text/>
+		</element>
+	</define>
+	<define name="config-config-item-attlist">
+		<interleave>
+			<attribute name="config:name">
+				<ref name="string"/>
+			</attribute>
+			<attribute name="config:type">
+				<choice>
+					<value>boolean</value>
+					<value>short</value>
+					<value>int</value>
+					<value>long</value>
+					<value>double</value>
+					<value>string</value>
+					<value>datetime</value>
+					<value>base64Binary</value>
+				</choice>
+			</attribute>
+		</interleave>
+	</define>
+	<define name="config-config-item-map-indexed">
+		<element name="config:config-item-map-indexed">
+			<ref name="config-config-item-map-indexed-attlist"/>
+			<oneOrMore>
+				<ref name="config-config-item-map-entry"/>
+			</oneOrMore>
+		</element>
+	</define>
+	<define name="config-config-item-map-indexed-attlist">
+		<attribute name="config:name">
+			<ref name="string"/>
+		</attribute>
+	</define>
+	<define name="config-config-item-map-entry">
+		<element name="config:config-item-map-entry">
+			<ref name="config-config-item-map-entry-attlist"/>
+			<ref name="config-items"/>
+		</element>
+	</define>
+	<define name="config-config-item-map-entry-attlist">
+		<optional>
+			<attribute name="config:name">
+				<ref name="string"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="config-config-item-map-named">
+		<element name="config:config-item-map-named">
+			<ref name="config-config-item-map-named-attlist"/>
+			<oneOrMore>
+				<ref name="config-config-item-map-entry"/>
+			</oneOrMore>
+		</element>
+	</define>
+	<define name="config-config-item-map-named-attlist">
+		<attribute name="config:name">
+			<ref name="string"/>
+		</attribute>
+	</define>
+	<define name="office-scripts">
+		<optional>
+			<element name="office:scripts">
+				<zeroOrMore>
+					<ref name="office-script"/>
+				</zeroOrMore>
+				<optional>
+					<ref name="office-event-listeners"/>
+				</optional>
+			</element>
+		</optional>
+	</define>
+	<define name="office-script">
+		<element name="office:script">
+			<ref name="office-script-attlist"/>
+			<mixed>
+				<ref name="anyElements"/>
+			</mixed>
+		</element>
+	</define>
+	<define name="office-script-attlist">
+		<attribute name="script:language">
+			<ref name="string"/>
+		</attribute>
+	</define>
+	<define name="office-font-face-decls">
+		<optional>
+			<element name="office:font-face-decls">
+				<zeroOrMore>
+					<ref name="style-font-face"/>
+				</zeroOrMore>
+			</element>
+		</optional>
+	</define>
+	<define name="office-styles">
+		<optional>
+			<element name="office:styles">
+				<interleave>
+					<ref name="styles"/>
+					<zeroOrMore>
+						<ref name="style-default-style"/>
+					</zeroOrMore>
+					<optional>
+						<ref name="style-default-page-layout"/>
+					</optional>
+					<optional>
+						<ref name="text-outline-style"/>
+					</optional>
+					<zeroOrMore>
+						<ref name="text-notes-configuration"/>
+					</zeroOrMore>
+					<optional>
+						<ref name="text-bibliography-configuration"/>
+					</optional>
+					<optional>
+						<ref name="text-linenumbering-configuration"/>
+					</optional>
+					<zeroOrMore>
+						<ref name="draw-gradient"/>
+					</zeroOrMore>
+					<zeroOrMore>
+						<ref name="svg-linearGradient"/>
+					</zeroOrMore>
+					<zeroOrMore>
+						<ref name="svg-radialGradient"/>
+					</zeroOrMore>
+					<zeroOrMore>
+						<ref name="draw-hatch"/>
+					</zeroOrMore>
+					<zeroOrMore>
+						<ref name="draw-fill-image"/>
+					</zeroOrMore>
+					<zeroOrMore>
+						<ref name="draw-marker"/>
+					</zeroOrMore>
+					<zeroOrMore>
+						<ref name="draw-stroke-dash"/>
+					</zeroOrMore>
+					<zeroOrMore>
+						<ref name="draw-opacity"/>
+					</zeroOrMore>
+					<zeroOrMore>
+						<ref name="style-presentation-page-layout"/>
+					</zeroOrMore>
+					<zeroOrMore>
+						<ref name="table-table-template"/>
+					</zeroOrMore>
+				</interleave>
+			</element>
+		</optional>
+	</define>
+	<define name="office-automatic-styles">
+		<optional>
+			<element name="office:automatic-styles">
+				<interleave>
+					<ref name="styles"/>
+					<zeroOrMore>
+						<ref name="style-page-layout"/>
+					</zeroOrMore>
+				</interleave>
+			</element>
+		</optional>
+	</define>
+	<define name="office-master-styles">
+		<optional>
+			<element name="office:master-styles">
+				<interleave>
+					<zeroOrMore>
+						<ref name="style-master-page"/>
+					</zeroOrMore>
+					<optional>
+						<ref name="style-handout-master"/>
+					</optional>
+					<optional>
+						<ref name="draw-layer-set"/>
+					</optional>
+				</interleave>
+			</element>
+		</optional>
+	</define>
+	<define name="styles">
+		<interleave>
+			<zeroOrMore>
+				<ref name="style-style"/>
+			</zeroOrMore>
+			<zeroOrMore>
+				<ref name="text-list-style"/>
+			</zeroOrMore>
+			<zeroOrMore>
+				<ref name="number-number-style"/>
+			</zeroOrMore>
+			<zeroOrMore>
+				<ref name="number-currency-style"/>
+			</zeroOrMore>
+			<zeroOrMore>
+				<ref name="number-percentage-style"/>
+			</zeroOrMore>
+			<zeroOrMore>
+				<ref name="number-date-style"/>
+			</zeroOrMore>
+			<zeroOrMore>
+				<ref name="number-time-style"/>
+			</zeroOrMore>
+			<zeroOrMore>
+				<ref name="number-boolean-style"/>
+			</zeroOrMore>
+			<zeroOrMore>
+				<ref name="number-text-style"/>
+			</zeroOrMore>
+		</interleave>
+	</define>
+	<define name="office-meta-data">
+		<choice>
+			<element name="meta:generator">
+				<ref name="string"/>
+			</element>
+			<element name="dc:title">
+				<ref name="string"/>
+			</element>
+			<element name="dc:description">
+				<ref name="string"/>
+			</element>
+			<element name="dc:subject">
+				<ref name="string"/>
+			</element>
+			<element name="meta:keyword">
+				<ref name="string"/>
+			</element>
+			<element name="meta:initial-creator">
+				<ref name="string"/>
+			</element>
+			<ref name="dc-creator"/>
+			<element name="meta:printed-by">
+				<ref name="string"/>
+			</element>
+			<element name="meta:creation-date">
+				<ref name="dateTime"/>
+			</element>
+			<ref name="dc-date"/>
+			<element name="meta:print-date">
+				<ref name="dateTime"/>
+			</element>
+			<element name="meta:template">
+				<attribute name="xlink:type">
+					<value>simple</value>
+				</attribute>
+				<attribute name="xlink:href">
+					<ref name="anyIRI"/>
+				</attribute>
+				<optional>
+					<attribute name="xlink:actuate">
+						<value>onRequest</value>
+					</attribute>
+				</optional>
+				<optional>
+					<attribute name="xlink:title">
+						<ref name="string"/>
+					</attribute>
+				</optional>
+				<optional>
+					<attribute name="meta:date">
+						<ref name="dateTime"/>
+					</attribute>
+				</optional>
+			</element>
+			<element name="meta:auto-reload">
+				<optional>
+					<attribute name="xlink:type">
+						<value>simple</value>
+					</attribute>
+					<attribute name="xlink:href">
+						<ref name="anyIRI"/>
+					</attribute>
+					<optional>
+						<attribute name="xlink:show">
+							<value>replace</value>
+						</attribute>
+					</optional>
+					<optional>
+						<attribute name="xlink:actuate">
+							<value>onLoad</value>
+						</attribute>
+					</optional>
+				</optional>
+				<optional>
+					<attribute name="meta:delay">
+						<ref name="duration"/>
+					</attribute>
+				</optional>
+			</element>
+			<element name="meta:hyperlink-behaviour">
+				<optional>
+					<attribute name="office:target-frame-name">
+						<ref name="targetFrameName"/>
+					</attribute>
+				</optional>
+				<optional>
+					<attribute name="xlink:show">
+						<choice>
+							<value>new</value>
+							<value>replace</value>
+						</choice>
+					</attribute>
+				</optional>
+			</element>
+			<element name="dc:language">
+				<ref name="language"/>
+			</element>
+			<element name="meta:editing-cycles">
+				<ref name="nonNegativeInteger"/>
+			</element>
+			<element name="meta:editing-duration">
+				<ref name="duration"/>
+			</element>
+			<element name="meta:document-statistic">
+				<optional>
+					<attribute name="meta:page-count">
+						<ref name="nonNegativeInteger"/>
+					</attribute>
+				</optional>
+				<optional>
+					<attribute name="meta:table-count">
+						<ref name="nonNegativeInteger"/>
+					</attribute>
+				</optional>
+				<optional>
+					<attribute name="meta:draw-count">
+						<ref name="nonNegativeInteger"/>
+					</attribute>
+				</optional>
+				<optional>
+					<attribute name="meta:image-count">
+						<ref name="nonNegativeInteger"/>
+					</attribute>
+				</optional>
+				<optional>
+					<attribute name="meta:ole-object-count">
+						<ref name="nonNegativeInteger"/>
+					</attribute>
+				</optional>
+				<optional>
+					<attribute name="meta:object-count">
+						<ref name="nonNegativeInteger"/>
+					</attribute>
+				</optional>
+				<optional>
+					<attribute name="meta:paragraph-count">
+						<ref name="nonNegativeInteger"/>
+					</attribute>
+				</optional>
+				<optional>
+					<attribute name="meta:word-count">
+						<ref name="nonNegativeInteger"/>
+					</attribute>
+				</optional>
+				<optional>
+					<attribute name="meta:character-count">
+						<ref name="nonNegativeInteger"/>
+					</attribute>
+				</optional>
+				<optional>
+					<attribute name="meta:frame-count">
+						<ref name="nonNegativeInteger"/>
+					</attribute>
+				</optional>
+				<optional>
+					<attribute name="meta:sentence-count">
+						<ref name="nonNegativeInteger"/>
+					</attribute>
+				</optional>
+				<optional>
+					<attribute name="meta:syllable-count">
+						<ref name="nonNegativeInteger"/>
+					</attribute>
+				</optional>
+				<optional>
+					<attribute name="meta:non-whitespace-character-count">
+						<ref name="nonNegativeInteger"/>
+					</attribute>
+				</optional>
+				<optional>
+					<attribute name="meta:row-count">
+						<ref name="nonNegativeInteger"/>
+					</attribute>
+				</optional>
+				<optional>
+					<attribute name="meta:cell-count">
+						<ref name="nonNegativeInteger"/>
+					</attribute>
+				</optional>
+			</element>
+			<element name="meta:user-defined">
+				<attribute name="meta:name">
+					<ref name="string"/>
+				</attribute>
+				<choice>
+					<group>
+						<attribute name="meta:value-type">
+							<value>float</value>
+						</attribute>
+						<ref name="double"/>
+					</group>
+					<group>
+						<attribute name="meta:value-type">
+							<value>date</value>
+						</attribute>
+						<ref name="dateOrDateTime"/>
+					</group>
+					<group>
+						<attribute name="meta:value-type">
+							<value>time</value>
+						</attribute>
+						<ref name="duration"/>
+					</group>
+					<group>
+						<attribute name="meta:value-type">
+							<value>boolean</value>
+						</attribute>
+						<ref name="boolean"/>
+					</group>
+					<group>
+						<attribute name="meta:value-type">
+							<value>string</value>
+						</attribute>
+						<ref name="string"/>
+					</group>
+					<text/>
+				</choice>
+			</element>
+		</choice>
+	</define>
+	<define name="dc-creator">
+		<element name="dc:creator">
+			<ref name="string"/>
+		</element>
+	</define>
+	<define name="dc-date">
+		<element name="dc:date">
+			<ref name="dateTime"/>
+		</element>
+	</define>
+	<define name="text-h">
+		<element name="text:h">
+			<ref name="heading-attrs"/>
+			<ref name="paragraph-attrs"/>
+			<optional>
+				<ref name="text-number"/>
+			</optional>
+			<zeroOrMore>
+				<ref name="paragraph-content-or-hyperlink"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="heading-attrs">
+		<interleave>
+			<attribute name="text:outline-level">
+				<ref name="positiveInteger"/>
+			</attribute>
+			<optional>
+				<attribute name="text:restart-numbering">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:start-value">
+					<ref name="nonNegativeInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:is-list-header">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="text-number">
+		<element name="text:number">
+			<ref name="string"/>
+		</element>
+	</define>
+	<define name="text-p">
+		<element name="text:p">
+			<ref name="paragraph-attrs"/>
+			<zeroOrMore>
+				<ref name="paragraph-content-or-hyperlink"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="paragraph-attrs">
+		<interleave>
+			<optional>
+				<attribute name="text:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:class-names">
+					<ref name="styleNameRefs"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:cond-style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<group>
+					<ref name="xml-id"/>
+					<optional>
+						<attribute name="text:id">
+							<ref name="NCName"/>
+						</attribute>
+					</optional>
+				</group>
+			</optional>
+			<optional>
+				<ref name="common-in-content-meta-attlist"/>
+			</optional>
+		</interleave>
+	</define>
+	<define name="text-page-sequence">
+		<element name="text:page-sequence">
+			<oneOrMore>
+				<ref name="text-page"/>
+			</oneOrMore>
+		</element>
+	</define>
+	<define name="text-page">
+		<element name="text:page">
+			<ref name="text-page-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="text-page-attlist">
+		<attribute name="text:master-page-name">
+			<ref name="styleNameRef"/>
+		</attribute>
+	</define>
+	<define name="text-list">
+		<element name="text:list">
+			<ref name="text-list-attr"/>
+			<optional>
+				<ref name="text-list-header"/>
+			</optional>
+			<zeroOrMore>
+				<ref name="text-list-item"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="text-list-attr">
+		<interleave>
+			<optional>
+				<attribute name="text:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:continue-numbering">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:continue-list">
+					<ref name="IDREF"/>
+				</attribute>
+			</optional>
+			<optional>
+				<ref name="xml-id"/>
+			</optional>
+		</interleave>
+	</define>
+	<define name="text-list-item">
+		<element name="text:list-item">
+			<ref name="text-list-item-attr"/>
+			<ref name="text-list-item-content"/>
+		</element>
+	</define>
+	<define name="text-list-item-content">
+		<optional>
+			<ref name="text-number"/>
+		</optional>
+		<zeroOrMore>
+			<choice>
+				<ref name="text-p"/>
+				<ref name="text-h"/>
+				<ref name="text-list"/>
+				<ref name="text-soft-page-break"/>
+			</choice>
+		</zeroOrMore>
+	</define>
+	<define name="text-list-item-attr">
+		<interleave>
+			<optional>
+				<attribute name="text:start-value">
+					<ref name="nonNegativeInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:style-override">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<ref name="xml-id"/>
+			</optional>
+		</interleave>
+	</define>
+	<define name="text-list-header">
+		<element name="text:list-header">
+			<ref name="text-list-header-attr"/>
+			<ref name="text-list-item-content"/>
+		</element>
+	</define>
+	<define name="text-list-header-attr">
+		<optional>
+			<ref name="xml-id"/>
+		</optional>
+	</define>
+	<define name="text-numbered-paragraph">
+		<element name="text:numbered-paragraph">
+			<ref name="text-numbered-paragraph-attr"/>
+			<optional>
+				<ref name="text-number"/>
+			</optional>
+			<choice>
+				<ref name="text-p"/>
+				<ref name="text-h"/>
+			</choice>
+		</element>
+	</define>
+	<define name="text-numbered-paragraph-attr">
+		<interleave>
+			<attribute name="text:list-id">
+				<ref name="NCName"/>
+			</attribute>
+			<optional>
+				<attribute name="text:level">
+					<ref name="positiveInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+				<attribute name="text:continue-numbering">
+					<ref name="boolean"/>
+				</attribute>
+				<attribute name="text:start-value">
+					<ref name="nonNegativeInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<ref name="xml-id"/>
+			</optional>
+		</interleave>
+	</define>
+	<define name="text-section">
+		<element name="text:section">
+			<ref name="text-section-attlist"/>
+			<choice>
+				<ref name="text-section-source"/>
+				<ref name="text-section-source-dde"/>
+				<empty/>
+			</choice>
+			<zeroOrMore>
+				<ref name="text-content"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="text-section-attlist">
+		<interleave>
+			<ref name="common-section-attlist"/>
+			<choice>
+				<attribute name="text:display">
+					<choice>
+						<value>true</value>
+						<value>none</value>
+					</choice>
+				</attribute>
+				<group>
+					<attribute name="text:display">
+						<value>condition</value>
+					</attribute>
+					<attribute name="text:condition">
+						<ref name="string"/>
+					</attribute>
+				</group>
+				<empty/>
+			</choice>
+		</interleave>
+	</define>
+	<define name="common-section-attlist">
+		<interleave>
+			<optional>
+				<attribute name="text:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<attribute name="text:name">
+				<ref name="string"/>
+			</attribute>
+			<optional>
+				<attribute name="text:protected">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:protection-key">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:protection-key-digest-algorithm">
+					<ref name="anyIRI"/>
+				</attribute>
+			</optional>
+			<optional>
+				<ref name="xml-id"/>
+			</optional>
+		</interleave>
+	</define>
+	<define name="text-section-source">
+		<element name="text:section-source">
+			<ref name="text-section-source-attr"/>
+		</element>
+	</define>
+	<define name="text-section-source-attr">
+		<interleave>
+			<optional>
+				<attribute name="xlink:type">
+					<value>simple</value>
+				</attribute>
+				<attribute name="xlink:href">
+					<ref name="anyIRI"/>
+				</attribute>
+				<optional>
+					<attribute name="xlink:show">
+						<value>embed</value>
+					</attribute>
+				</optional>
+			</optional>
+			<optional>
+				<attribute name="text:section-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:filter-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="text-section-source-dde">
+		<ref name="office-dde-source"/>
+	</define>
+	<define name="text-tracked-changes">
+		<optional>
+			<element name="text:tracked-changes">
+				<ref name="text-tracked-changes-attr"/>
+				<zeroOrMore>
+					<ref name="text-changed-region"/>
+				</zeroOrMore>
+			</element>
+		</optional>
+	</define>
+	<define name="text-tracked-changes-attr">
+		<optional>
+			<attribute name="text:track-changes">
+				<ref name="boolean"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="text-changed-region">
+		<element name="text:changed-region">
+			<ref name="text-changed-region-attr"/>
+			<ref name="text-changed-region-content"/>
+		</element>
+	</define>
+	<define name="text-changed-region-attr">
+		<group>
+			<ref name="xml-id"/>
+			<optional>
+				<attribute name="text:id">
+					<ref name="NCName"/>
+				</attribute>
+			</optional>
+		</group>
+	</define>
+	<define name="text-changed-region-content">
+		<choice>
+			<element name="text:insertion">
+				<ref name="office-change-info"/>
+			</element>
+			<element name="text:deletion">
+				<ref name="office-change-info"/>
+				<zeroOrMore>
+					<ref name="text-content"/>
+				</zeroOrMore>
+			</element>
+			<element name="text:format-change">
+				<ref name="office-change-info"/>
+			</element>
+		</choice>
+	</define>
+	<define name="change-marks">
+		<choice>
+			<element name="text:change">
+				<ref name="change-mark-attr"/>
+			</element>
+			<element name="text:change-start">
+				<ref name="change-mark-attr"/>
+			</element>
+			<element name="text:change-end">
+				<ref name="change-mark-attr"/>
+			</element>
+		</choice>
+	</define>
+	<define name="change-mark-attr">
+		<attribute name="text:change-id">
+			<ref name="IDREF"/>
+		</attribute>
+	</define>
+	<define name="text-soft-page-break">
+		<element name="text:soft-page-break">
+			<empty/>
+		</element>
+	</define>
+	<define name="text-decls">
+		<optional>
+			<element name="text:variable-decls">
+				<zeroOrMore>
+					<ref name="text-variable-decl"/>
+				</zeroOrMore>
+			</element>
+		</optional>
+		<optional>
+			<element name="text:sequence-decls">
+				<zeroOrMore>
+					<ref name="text-sequence-decl"/>
+				</zeroOrMore>
+			</element>
+		</optional>
+		<optional>
+			<element name="text:user-field-decls">
+				<zeroOrMore>
+					<ref name="text-user-field-decl"/>
+				</zeroOrMore>
+			</element>
+		</optional>
+		<optional>
+			<element name="text:dde-connection-decls">
+				<zeroOrMore>
+					<ref name="text-dde-connection-decl"/>
+				</zeroOrMore>
+			</element>
+		</optional>
+		<optional>
+			<ref name="text-alphabetical-index-auto-mark-file"/>
+		</optional>
+	</define>
+	<define name="paragraph-content-or-hyperlink">
+		<choice>
+			<ref name="paragraph-content"/>
+			<ref name="text-a"/>
+		</choice>
+	</define>
+	<define name="paragraph-content">
+		<choice>
+			<text/>
+			<element name="text:s">
+				<optional>
+					<attribute name="text:c">
+						<ref name="nonNegativeInteger"/>
+					</attribute>
+				</optional>
+			</element>
+			<element name="text:tab">
+				<ref name="text-tab-attr"/>
+			</element>
+			<element name="text:line-break">
+				<empty/>
+			</element>
+			<ref name="text-soft-page-break"/>
+			<element name="text:span">
+				<optional>
+					<attribute name="text:style-name">
+						<ref name="styleNameRef"/>
+					</attribute>
+				</optional>
+				<optional>
+					<attribute name="text:class-names">
+						<ref name="styleNameRefs"/>
+					</attribute>
+				</optional>
+				<zeroOrMore>
+					<ref name="paragraph-content-or-hyperlink"/>
+				</zeroOrMore>
+			</element>
+			<element name="text:meta">
+				<ref name="text-meta-attlist"/>
+				<zeroOrMore>
+					<ref name="paragraph-content-or-hyperlink"/>
+				</zeroOrMore>
+			</element>
+			<choice>
+				<ref name="text-bookmark"/>
+				<ref name="text-bookmark-start"/>
+				<ref name="text-bookmark-end"/>
+			</choice>
+			<element name="text:reference-mark">
+				<attribute name="text:name">
+					<ref name="string"/>
+				</attribute>
+			</element>
+			<choice>
+				<element name="text:reference-mark-start">
+					<attribute name="text:name">
+						<ref name="string"/>
+					</attribute>
+				</element>
+				<element name="text:reference-mark-end">
+					<attribute name="text:name">
+						<ref name="string"/>
+					</attribute>
+				</element>
+			</choice>
+			<element name="text:note">
+				<ref name="text-note-class"/>
+				<optional>
+					<attribute name="text:id">
+						<ref name="string"/>
+					</attribute>
+				</optional>
+				<element name="text:note-citation">
+					<optional>
+						<attribute name="text:label">
+							<ref name="string"/>
+						</attribute>
+					</optional>
+					<text/>
+				</element>
+				<element name="text:note-body">
+					<zeroOrMore>
+						<ref name="text-content"/>
+					</zeroOrMore>
+				</element>
+			</element>
+			<element name="text:ruby">
+				<optional>
+					<attribute name="text:style-name">
+						<ref name="styleNameRef"/>
+					</attribute>
+				</optional>
+				<element name="text:ruby-base">
+					<zeroOrMore>
+						<ref name="paragraph-content-or-hyperlink"/>
+					</zeroOrMore>
+				</element>
+				<element name="text:ruby-text">
+					<optional>
+						<attribute name="text:style-name">
+							<ref name="styleNameRef"/>
+						</attribute>
+					</optional>
+					<text/>
+				</element>
+			</element>
+			<choice>
+				<ref name="office-annotation"/>
+				<ref name="office-annotation-end"/>
+			</choice>
+			<ref name="change-marks"/>
+			<ref name="shape"/>
+			<element name="text:date">
+				<ref name="text-date-attlist"/>
+				<text/>
+			</element>
+			<element name="text:time">
+				<ref name="text-time-attlist"/>
+				<text/>
+			</element>
+			<element name="text:page-number">
+				<ref name="text-page-number-attlist"/>
+				<text/>
+			</element>
+			<element name="text:page-continuation">
+				<ref name="text-page-continuation-attlist"/>
+				<text/>
+			</element>
+			<element name="text:sender-firstname">
+				<ref name="common-field-fixed-attlist"/>
+				<text/>
+			</element>
+			<element name="text:sender-lastname">
+				<ref name="common-field-fixed-attlist"/>
+				<text/>
+			</element>
+			<element name="text:sender-initials">
+				<ref name="common-field-fixed-attlist"/>
+				<text/>
+			</element>
+			<element name="text:sender-title">
+				<ref name="common-field-fixed-attlist"/>
+				<text/>
+			</element>
+			<element name="text:sender-position">
+				<ref name="common-field-fixed-attlist"/>
+				<text/>
+			</element>
+			<element name="text:sender-email">
+				<ref name="common-field-fixed-attlist"/>
+				<text/>
+			</element>
+			<element name="text:sender-phone-private">
+				<ref name="common-field-fixed-attlist"/>
+				<text/>
+			</element>
+			<element name="text:sender-fax">
+				<ref name="common-field-fixed-attlist"/>
+				<text/>
+			</element>
+			<element name="text:sender-company">
+				<ref name="common-field-fixed-attlist"/>
+				<text/>
+			</element>
+			<element name="text:sender-phone-work">
+				<ref name="common-field-fixed-attlist"/>
+				<text/>
+			</element>
+			<element name="text:sender-street">
+				<ref name="common-field-fixed-attlist"/>
+				<text/>
+			</element>
+			<element name="text:sender-city">
+				<ref name="common-field-fixed-attlist"/>
+				<text/>
+			</element>
+			<element name="text:sender-postal-code">
+				<ref name="common-field-fixed-attlist"/>
+				<text/>
+			</element>
+			<element name="text:sender-country">
+				<ref name="common-field-fixed-attlist"/>
+				<text/>
+			</element>
+			<element name="text:sender-state-or-province">
+				<ref name="common-field-fixed-attlist"/>
+				<text/>
+			</element>
+			<element name="text:author-name">
+				<ref name="common-field-fixed-attlist"/>
+				<text/>
+			</element>
+			<element name="text:author-initials">
+				<ref name="common-field-fixed-attlist"/>
+				<text/>
+			</element>
+			<element name="text:chapter">
+				<ref name="text-chapter-attlist"/>
+				<text/>
+			</element>
+			<element name="text:file-name">
+				<ref name="text-file-name-attlist"/>
+				<text/>
+			</element>
+			<element name="text:template-name">
+				<ref name="text-template-name-attlist"/>
+				<text/>
+			</element>
+			<element name="text:sheet-name">
+				<text/>
+			</element>
+			<element name="text:variable-set">
+				<interleave>
+					<ref name="common-field-name-attlist"/>
+					<ref name="common-field-formula-attlist"/>
+					<ref name="common-value-and-type-attlist"/>
+					<ref name="common-field-display-value-none-attlist"/>
+					<ref name="common-field-data-style-name-attlist"/>
+				</interleave>
+				<text/>
+			</element>
+			<element name="text:variable-get">
+				<interleave>
+					<ref name="common-field-name-attlist"/>
+					<ref name="common-field-display-value-formula-attlist"/>
+					<ref name="common-field-data-style-name-attlist"/>
+				</interleave>
+				<text/>
+			</element>
+			<element name="text:variable-input">
+				<interleave>
+					<ref name="common-field-name-attlist"/>
+					<ref name="common-field-description-attlist"/>
+					<ref name="common-value-type-attlist"/>
+					<ref name="common-field-display-value-none-attlist"/>
+					<ref name="common-field-data-style-name-attlist"/>
+				</interleave>
+				<text/>
+			</element>
+			<element name="text:user-field-get">
+				<interleave>
+					<ref name="common-field-name-attlist"/>
+					<ref name="common-field-display-value-formula-none-attlist"/>
+					<ref name="common-field-data-style-name-attlist"/>
+				</interleave>
+				<text/>
+			</element>
+			<element name="text:user-field-input">
+				<interleave>
+					<ref name="common-field-name-attlist"/>
+					<ref name="common-field-description-attlist"/>
+					<ref name="common-field-data-style-name-attlist"/>
+				</interleave>
+				<text/>
+			</element>
+			<element name="text:sequence">
+				<interleave>
+					<ref name="common-field-name-attlist"/>
+					<ref name="common-field-formula-attlist"/>
+					<ref name="common-field-num-format-attlist"/>
+					<ref name="text-sequence-ref-name"/>
+				</interleave>
+				<text/>
+			</element>
+			<element name="text:expression">
+				<interleave>
+					<ref name="common-field-formula-attlist"/>
+					<optional>
+						<ref name="common-value-and-type-attlist"/>
+					</optional>
+					<ref name="common-field-display-value-formula-attlist"/>
+					<ref name="common-field-data-style-name-attlist"/>
+				</interleave>
+				<text/>
+			</element>
+			<element name="text:text-input">
+				<ref name="common-field-description-attlist"/>
+				<text/>
+			</element>
+			<element name="text:initial-creator">
+				<ref name="common-field-fixed-attlist"/>
+				<text/>
+			</element>
+			<element name="text:creation-date">
+				<interleave>
+					<ref name="common-field-fixed-attlist"/>
+					<ref name="common-field-data-style-name-attlist"/>
+					<optional>
+						<attribute name="text:date-value">
+							<ref name="dateOrDateTime"/>
+						</attribute>
+					</optional>
+				</interleave>
+				<text/>
+			</element>
+			<element name="text:creation-time">
+				<interleave>
+					<ref name="common-field-fixed-attlist"/>
+					<ref name="common-field-data-style-name-attlist"/>
+					<optional>
+						<attribute name="text:time-value">
+							<ref name="timeOrDateTime"/>
+						</attribute>
+					</optional>
+				</interleave>
+				<text/>
+			</element>
+			<element name="text:description">
+				<ref name="common-field-fixed-attlist"/>
+				<text/>
+			</element>
+			<element name="text:user-defined">
+				<interleave>
+					<ref name="common-field-fixed-attlist"/>
+					<attribute name="text:name">
+						<ref name="string"/>
+					</attribute>
+					<ref name="common-field-data-style-name-attlist"/>
+					<optional>
+						<attribute name="office:value">
+							<ref name="double"/>
+						</attribute>
+					</optional>
+					<optional>
+						<attribute name="office:date-value">
+							<ref name="dateOrDateTime"/>
+						</attribute>
+					</optional>
+					<optional>
+						<attribute name="office:time-value">
+							<ref name="duration"/>
+						</attribute>
+					</optional>
+					<optional>
+						<attribute name="office:boolean-value">
+							<ref name="boolean"/>
+						</attribute>
+					</optional>
+					<optional>
+						<attribute name="office:string-value">
+							<ref name="string"/>
+						</attribute>
+					</optional>
+				</interleave>
+				<text/>
+			</element>
+			<element name="text:print-time">
+				<interleave>
+					<ref name="common-field-fixed-attlist"/>
+					<ref name="common-field-data-style-name-attlist"/>
+					<optional>
+						<attribute name="text:time-value">
+							<ref name="time"/>
+						</attribute>
+					</optional>
+				</interleave>
+				<text/>
+			</element>
+			<element name="text:print-date">
+				<interleave>
+					<ref name="common-field-fixed-attlist"/>
+					<ref name="common-field-data-style-name-attlist"/>
+					<optional>
+						<attribute name="text:date-value">
+							<ref name="date"/>
+						</attribute>
+					</optional>
+				</interleave>
+				<text/>
+			</element>
+			<element name="text:printed-by">
+				<ref name="common-field-fixed-attlist"/>
+				<text/>
+			</element>
+			<element name="text:title">
+				<ref name="common-field-fixed-attlist"/>
+				<text/>
+			</element>
+			<element name="text:subject">
+				<ref name="common-field-fixed-attlist"/>
+				<text/>
+			</element>
+			<element name="text:keywords">
+				<ref name="common-field-fixed-attlist"/>
+				<text/>
+			</element>
+			<element name="text:editing-cycles">
+				<ref name="common-field-fixed-attlist"/>
+				<text/>
+			</element>
+			<element name="text:editing-duration">
+				<interleave>
+					<ref name="common-field-fixed-attlist"/>
+					<ref name="common-field-data-style-name-attlist"/>
+					<optional>
+						<attribute name="text:duration">
+							<ref name="duration"/>
+						</attribute>
+					</optional>
+				</interleave>
+				<text/>
+			</element>
+			<element name="text:modification-time">
+				<interleave>
+					<ref name="common-field-fixed-attlist"/>
+					<ref name="common-field-data-style-name-attlist"/>
+					<optional>
+						<attribute name="text:time-value">
+							<ref name="time"/>
+						</attribute>
+					</optional>
+				</interleave>
+				<text/>
+			</element>
+			<element name="text:modification-date">
+				<interleave>
+					<ref name="common-field-fixed-attlist"/>
+					<ref name="common-field-data-style-name-attlist"/>
+					<optional>
+						<attribute name="text:date-value">
+							<ref name="date"/>
+						</attribute>
+					</optional>
+				</interleave>
+				<text/>
+			</element>
+			<element name="text:creator">
+				<ref name="common-field-fixed-attlist"/>
+				<text/>
+			</element>
+			<element>
+				<choice>
+					<name>text:page-count</name>
+					<name>text:paragraph-count</name>
+					<name>text:word-count</name>
+					<name>text:character-count</name>
+					<name>text:table-count</name>
+					<name>text:image-count</name>
+					<name>text:object-count</name>
+				</choice>
+				<ref name="common-field-num-format-attlist"/>
+				<text/>
+			</element>
+			<element name="text:database-display">
+				<ref name="text-database-display-attlist"/>
+				<text/>
+			</element>
+			<element name="text:database-next">
+				<ref name="text-database-next-attlist"/>
+			</element>
+			<element name="text:database-row-select">
+				<ref name="text-database-row-select-attlist"/>
+			</element>
+			<element name="text:database-row-number">
+				<interleave>
+					<ref name="common-field-database-table"/>
+					<ref name="common-field-num-format-attlist"/>
+					<optional>
+						<attribute name="text:value">
+							<ref name="nonNegativeInteger"/>
+						</attribute>
+					</optional>
+				</interleave>
+				<text/>
+			</element>
+			<element name="text:database-name">
+				<ref name="common-field-database-table"/>
+				<text/>
+			</element>
+			<element name="text:page-variable-set">
+				<ref name="text-set-page-variable-attlist"/>
+				<text/>
+			</element>
+			<element name="text:page-variable-get">
+				<ref name="text-get-page-variable-attlist"/>
+				<text/>
+			</element>
+			<element name="text:placeholder">
+				<ref name="text-placeholder-attlist"/>
+				<text/>
+			</element>
+			<element name="text:conditional-text">
+				<ref name="text-conditional-text-attlist"/>
+				<text/>
+			</element>
+			<element name="text:hidden-text">
+				<ref name="text-hidden-text-attlist"/>
+				<text/>
+			</element>
+			<element>
+				<choice>
+					<name>text:reference-ref</name>
+					<name>text:bookmark-ref</name>
+				</choice>
+				<interleave>
+					<ref name="text-common-ref-content"/>
+					<ref name="text-bookmark-ref-content"/>
+				</interleave>
+			</element>
+			<element name="text:note-ref">
+				<interleave>
+					<ref name="text-common-ref-content"/>
+					<ref name="text-note-ref-content"/>
+				</interleave>
+			</element>
+			<element name="text:sequence-ref">
+				<interleave>
+					<ref name="text-common-ref-content"/>
+					<ref name="text-sequence-ref-content"/>
+				</interleave>
+			</element>
+			<element name="text:script">
+				<interleave>
+					<choice>
+						<group>
+							<attribute name="xlink:type">
+								<value>simple</value>
+							</attribute>
+							<attribute name="xlink:href">
+								<ref name="anyIRI"/>
+							</attribute>
+						</group>
+						<text/>
+					</choice>
+					<optional>
+						<attribute name="script:language">
+							<ref name="string"/>
+						</attribute>
+					</optional>
+				</interleave>
+			</element>
+			<element name="text:execute-macro">
+				<optional>
+					<attribute name="text:name">
+						<ref name="string"/>
+					</attribute>
+				</optional>
+				<optional>
+					<ref name="office-event-listeners"/>
+				</optional>
+				<text/>
+			</element>
+			<element name="text:hidden-paragraph">
+				<ref name="text-hidden-paragraph-attlist"/>
+				<text/>
+			</element>
+			<element name="text:dde-connection">
+				<attribute name="text:connection-name">
+					<ref name="string"/>
+				</attribute>
+				<text/>
+			</element>
+			<element name="text:measure">
+				<attribute name="text:kind">
+					<choice>
+						<value>value</value>
+						<value>unit</value>
+						<value>gap</value>
+					</choice>
+				</attribute>
+				<text/>
+			</element>
+			<element name="text:table-formula">
+				<interleave>
+					<ref name="common-field-formula-attlist"/>
+					<ref name="common-field-display-value-formula-attlist"/>
+					<ref name="common-field-data-style-name-attlist"/>
+				</interleave>
+				<text/>
+			</element>
+			<element name="text:meta-field">
+				<ref name="text-meta-field-attlist"/>
+				<zeroOrMore>
+					<ref name="paragraph-content-or-hyperlink"/>
+				</zeroOrMore>
+			</element>
+			<element name="text:toc-mark-start">
+				<ref name="text-toc-mark-start-attrs"/>
+			</element>
+			<element name="text:toc-mark-end">
+				<ref name="text-id"/>
+			</element>
+			<element name="text:toc-mark">
+				<attribute name="text:string-value">
+					<ref name="string"/>
+				</attribute>
+				<ref name="text-outline-level"/>
+			</element>
+			<element name="text:user-index-mark-start">
+				<ref name="text-id"/>
+				<ref name="text-outline-level"/>
+				<ref name="text-index-name"/>
+			</element>
+			<element name="text:user-index-mark-end">
+				<ref name="text-id"/>
+			</element>
+			<element name="text:user-index-mark">
+				<attribute name="text:string-value">
+					<ref name="string"/>
+				</attribute>
+				<ref name="text-outline-level"/>
+				<ref name="text-index-name"/>
+			</element>
+			<element name="text:alphabetical-index-mark-start">
+				<ref name="text-id"/>
+				<ref name="text-alphabetical-index-mark-attrs"/>
+			</element>
+			<element name="text:alphabetical-index-mark-end">
+				<ref name="text-id"/>
+			</element>
+			<element name="text:alphabetical-index-mark">
+				<attribute name="text:string-value">
+					<ref name="string"/>
+				</attribute>
+				<ref name="text-alphabetical-index-mark-attrs"/>
+			</element>
+			<element name="text:bibliography-mark">
+				<attribute name="text:bibliography-type">
+					<ref name="text-bibliography-types"/>
+				</attribute>
+				<zeroOrMore>
+					<attribute>
+						<choice>
+							<name>text:identifier</name>
+							<name>text:address</name>
+							<name>text:annote</name>
+							<name>text:author</name>
+							<name>text:booktitle</name>
+							<name>text:chapter</name>
+							<name>text:edition</name>
+							<name>text:editor</name>
+							<name>text:howpublished</name>
+							<name>text:institution</name>
+							<name>text:journal</name>
+							<name>text:month</name>
+							<name>text:note</name>
+							<name>text:number</name>
+							<name>text:organizations</name>
+							<name>text:pages</name>
+							<name>text:publisher</name>
+							<name>text:school</name>
+							<name>text:series</name>
+							<name>text:title</name>
+							<name>text:report-type</name>
+							<name>text:volume</name>
+							<name>text:year</name>
+							<name>text:url</name>
+							<name>text:custom1</name>
+							<name>text:custom2</name>
+							<name>text:custom3</name>
+							<name>text:custom4</name>
+							<name>text:custom5</name>
+							<name>text:isbn</name>
+							<name>text:issn</name>
+						</choice>
+						<ref name="string"/>
+					</attribute>
+				</zeroOrMore>
+				<text/>
+			</element>
+			<element name="presentation:header">
+				<empty/>
+			</element>
+			<element name="presentation:footer">
+				<empty/>
+			</element>
+			<element name="presentation:date-time">
+				<empty/>
+			</element>
+		</choice>
+	</define>
+	<define name="text-tab-attr">
+		<optional>
+			<attribute name="text:tab-ref">
+				<ref name="nonNegativeInteger"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="text-a">
+		<element name="text:a">
+			<ref name="text-a-attlist"/>
+			<optional>
+				<ref name="office-event-listeners"/>
+			</optional>
+			<zeroOrMore>
+				<ref name="paragraph-content"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="text-a-attlist">
+		<interleave>
+			<optional>
+				<attribute name="office:name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="office:title">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<attribute name="xlink:type">
+				<value>simple</value>
+			</attribute>
+			<attribute name="xlink:href">
+				<ref name="anyIRI"/>
+			</attribute>
+			<optional>
+				<attribute name="xlink:actuate">
+					<value>onRequest</value>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="office:target-frame-name">
+					<ref name="targetFrameName"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="xlink:show">
+					<choice>
+						<value>new</value>
+						<value>replace</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:visited-style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="text-meta-attlist">
+		<interleave>
+			<optional>
+				<ref name="common-in-content-meta-attlist"/>
+			</optional>
+			<optional>
+				<ref name="xml-id"/>
+			</optional>
+		</interleave>
+	</define>
+	<define name="text-bookmark">
+		<element name="text:bookmark">
+			<ref name="text-bookmark-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="text-bookmark-start">
+		<element name="text:bookmark-start">
+			<ref name="text-bookmark-start-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="text-bookmark-end">
+		<element name="text:bookmark-end">
+			<ref name="text-bookmark-end-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="text-bookmark-attlist">
+		<interleave>
+			<attribute name="text:name">
+				<ref name="string"/>
+			</attribute>
+			<optional>
+				<ref name="xml-id"/>
+			</optional>
+		</interleave>
+	</define>
+	<define name="text-bookmark-start-attlist">
+		<interleave>
+			<attribute name="text:name">
+				<ref name="string"/>
+			</attribute>
+			<optional>
+				<ref name="xml-id"/>
+			</optional>
+			<optional>
+				<ref name="common-in-content-meta-attlist"/>
+			</optional>
+		</interleave>
+	</define>
+	<define name="text-bookmark-end-attlist">
+		<attribute name="text:name">
+			<ref name="string"/>
+		</attribute>
+	</define>
+	<define name="text-note-class">
+		<attribute name="text:note-class">
+			<choice>
+				<value>footnote</value>
+				<value>endnote</value>
+			</choice>
+		</attribute>
+	</define>
+	<define name="text-date-attlist">
+		<interleave>
+			<interleave>
+				<ref name="common-field-fixed-attlist"/>
+				<ref name="common-field-data-style-name-attlist"/>
+			</interleave>
+			<optional>
+				<attribute name="text:date-value">
+					<ref name="dateOrDateTime"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:date-adjust">
+					<ref name="duration"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="text-time-attlist">
+		<interleave>
+			<interleave>
+				<ref name="common-field-fixed-attlist"/>
+				<ref name="common-field-data-style-name-attlist"/>
+			</interleave>
+			<optional>
+				<attribute name="text:time-value">
+					<ref name="timeOrDateTime"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:time-adjust">
+					<ref name="duration"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="text-page-number-attlist">
+		<interleave>
+			<interleave>
+				<ref name="common-field-num-format-attlist"/>
+				<ref name="common-field-fixed-attlist"/>
+			</interleave>
+			<optional>
+				<attribute name="text:page-adjust">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:select-page">
+					<choice>
+						<value>previous</value>
+						<value>current</value>
+						<value>next</value>
+					</choice>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="text-page-continuation-attlist">
+		<interleave>
+			<attribute name="text:select-page">
+				<choice>
+					<value>previous</value>
+					<value>next</value>
+				</choice>
+			</attribute>
+			<optional>
+				<attribute name="text:string-value">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="text-chapter-attlist">
+		<interleave>
+			<attribute name="text:display">
+				<choice>
+					<value>name</value>
+					<value>number</value>
+					<value>number-and-name</value>
+					<value>plain-number-and-name</value>
+					<value>plain-number</value>
+				</choice>
+			</attribute>
+			<attribute name="text:outline-level">
+				<ref name="nonNegativeInteger"/>
+			</attribute>
+		</interleave>
+	</define>
+	<define name="text-file-name-attlist">
+		<interleave>
+			<optional>
+				<attribute name="text:display">
+					<choice>
+						<value>full</value>
+						<value>path</value>
+						<value>name</value>
+						<value>name-and-extension</value>
+					</choice>
+				</attribute>
+			</optional>
+			<ref name="common-field-fixed-attlist"/>
+		</interleave>
+	</define>
+	<define name="text-template-name-attlist">
+		<optional>
+			<attribute name="text:display">
+				<choice>
+					<value>full</value>
+					<value>path</value>
+					<value>name</value>
+					<value>name-and-extension</value>
+					<value>area</value>
+					<value>title</value>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="text-variable-decl">
+		<element name="text:variable-decl">
+			<ref name="common-field-name-attlist"/>
+			<ref name="common-value-type-attlist"/>
+		</element>
+	</define>
+	<define name="text-user-field-decl">
+		<element name="text:user-field-decl">
+			<ref name="common-field-name-attlist"/>
+			<optional>
+				<ref name="common-field-formula-attlist"/>
+			</optional>
+			<ref name="common-value-and-type-attlist"/>
+		</element>
+	</define>
+	<define name="text-sequence-decl">
+		<element name="text:sequence-decl">
+			<ref name="text-sequence-decl-attlist"/>
+		</element>
+	</define>
+	<define name="text-sequence-decl-attlist">
+		<interleave>
+			<ref name="common-field-name-attlist"/>
+			<attribute name="text:display-outline-level">
+				<ref name="nonNegativeInteger"/>
+			</attribute>
+			<optional>
+				<attribute name="text:separation-character">
+					<ref name="character"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="text-sequence-ref-name">
+		<optional>
+			<attribute name="text:ref-name">
+				<ref name="string"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-field-database-table">
+		<ref name="common-field-database-table-attlist"/>
+		<ref name="common-field-database-name"/>
+	</define>
+	<define name="common-field-database-name">
+		<choice>
+			<optional>
+				<attribute name="text:database-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<ref name="form-connection-resource"/>
+		</choice>
+	</define>
+	<define name="common-field-database-table-attlist">
+		<interleave>
+			<attribute name="text:table-name">
+				<ref name="string"/>
+			</attribute>
+			<optional>
+				<attribute name="text:table-type">
+					<choice>
+						<value>table</value>
+						<value>query</value>
+						<value>command</value>
+					</choice>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="text-database-display-attlist">
+		<interleave>
+			<ref name="common-field-database-table"/>
+			<ref name="common-field-data-style-name-attlist"/>
+			<attribute name="text:column-name">
+				<ref name="string"/>
+			</attribute>
+		</interleave>
+	</define>
+	<define name="text-database-next-attlist">
+		<interleave>
+			<ref name="common-field-database-table"/>
+			<optional>
+				<attribute name="text:condition">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="text-database-row-select-attlist">
+		<interleave>
+			<ref name="common-field-database-table"/>
+			<optional>
+				<attribute name="text:condition">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:row-number">
+					<ref name="nonNegativeInteger"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="text-set-page-variable-attlist">
+		<interleave>
+			<optional>
+				<attribute name="text:active">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:page-adjust">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="text-get-page-variable-attlist">
+		<ref name="common-field-num-format-attlist"/>
+	</define>
+	<define name="text-placeholder-attlist">
+		<interleave>
+			<attribute name="text:placeholder-type">
+				<choice>
+					<value>text</value>
+					<value>table</value>
+					<value>text-box</value>
+					<value>image</value>
+					<value>object</value>
+				</choice>
+			</attribute>
+			<ref name="common-field-description-attlist"/>
+		</interleave>
+	</define>
+	<define name="text-conditional-text-attlist">
+		<interleave>
+			<attribute name="text:condition">
+				<ref name="string"/>
+			</attribute>
+			<attribute name="text:string-value-if-true">
+				<ref name="string"/>
+			</attribute>
+			<attribute name="text:string-value-if-false">
+				<ref name="string"/>
+			</attribute>
+			<optional>
+				<attribute name="text:current-value">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="text-hidden-text-attlist">
+		<interleave>
+			<attribute name="text:condition">
+				<ref name="string"/>
+			</attribute>
+			<attribute name="text:string-value">
+				<ref name="string"/>
+			</attribute>
+			<optional>
+				<attribute name="text:is-hidden">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="text-common-ref-content">
+		<interleave>
+			<text/>
+			<optional>
+				<attribute name="text:ref-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="text-bookmark-ref-content">
+		<optional>
+			<attribute name="text:reference-format">
+				<choice>
+					<ref name="common-ref-format-values"/>
+					<value>number-no-superior</value>
+					<value>number-all-superior</value>
+					<value>number</value>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="text-note-ref-content">
+		<interleave>
+			<optional>
+				<attribute name="text:reference-format">
+					<choice>
+						<ref name="common-ref-format-values"/>
+					</choice>
+				</attribute>
+			</optional>
+			<ref name="text-note-class"/>
+		</interleave>
+	</define>
+	<define name="text-sequence-ref-content">
+		<optional>
+			<attribute name="text:reference-format">
+				<choice>
+					<ref name="common-ref-format-values"/>
+					<value>category-and-value</value>
+					<value>caption</value>
+					<value>value</value>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-ref-format-values">
+		<choice>
+			<value>page</value>
+			<value>chapter</value>
+			<value>direction</value>
+			<value>text</value>
+		</choice>
+	</define>
+	<define name="text-hidden-paragraph-attlist">
+		<interleave>
+			<attribute name="text:condition">
+				<ref name="string"/>
+			</attribute>
+			<optional>
+				<attribute name="text:is-hidden">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="text-meta-field-attlist">
+		<interleave>
+			<ref name="xml-id"/>
+			<ref name="common-field-data-style-name-attlist"/>
+		</interleave>
+	</define>
+	<define name="common-value-type-attlist">
+		<attribute name="office:value-type">
+			<ref name="valueType"/>
+		</attribute>
+	</define>
+	<define name="common-value-and-type-attlist">
+		<choice>
+			<group>
+				<attribute name="office:value-type">
+					<value>float</value>
+				</attribute>
+				<attribute name="office:value">
+					<ref name="double"/>
+				</attribute>
+			</group>
+			<group>
+				<attribute name="office:value-type">
+					<value>percentage</value>
+				</attribute>
+				<attribute name="office:value">
+					<ref name="double"/>
+				</attribute>
+			</group>
+			<group>
+				<attribute name="office:value-type">
+					<value>currency</value>
+				</attribute>
+				<attribute name="office:value">
+					<ref name="double"/>
+				</attribute>
+				<optional>
+					<attribute name="office:currency">
+						<ref name="string"/>
+					</attribute>
+				</optional>
+			</group>
+			<group>
+				<attribute name="office:value-type">
+					<value>date</value>
+				</attribute>
+				<attribute name="office:date-value">
+					<ref name="dateOrDateTime"/>
+				</attribute>
+			</group>
+			<group>
+				<attribute name="office:value-type">
+					<value>time</value>
+				</attribute>
+				<attribute name="office:time-value">
+					<ref name="duration"/>
+				</attribute>
+			</group>
+			<group>
+				<attribute name="office:value-type">
+					<value>boolean</value>
+				</attribute>
+				<attribute name="office:boolean-value">
+					<ref name="boolean"/>
+				</attribute>
+			</group>
+			<group>
+				<attribute name="office:value-type">
+					<value>string</value>
+				</attribute>
+				<optional>
+					<attribute name="office:string-value">
+						<ref name="string"/>
+					</attribute>
+				</optional>
+			</group>
+		</choice>
+	</define>
+	<define name="common-field-fixed-attlist">
+		<optional>
+			<attribute name="text:fixed">
+				<ref name="boolean"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-field-name-attlist">
+		<attribute name="text:name">
+			<ref name="variableName"/>
+		</attribute>
+	</define>
+	<define name="common-field-description-attlist">
+		<optional>
+			<attribute name="text:description">
+				<ref name="string"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-field-display-value-none-attlist">
+		<optional>
+			<attribute name="text:display">
+				<choice>
+					<value>value</value>
+					<value>none</value>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-field-display-value-formula-none-attlist">
+		<optional>
+			<attribute name="text:display">
+				<choice>
+					<value>value</value>
+					<value>formula</value>
+					<value>none</value>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-field-display-value-formula-attlist">
+		<optional>
+			<attribute name="text:display">
+				<choice>
+					<value>value</value>
+					<value>formula</value>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-field-formula-attlist">
+		<optional>
+			<attribute name="text:formula">
+				<ref name="string"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-field-data-style-name-attlist">
+		<optional>
+			<attribute name="style:data-style-name">
+				<ref name="styleNameRef"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-field-num-format-attlist">
+		<optional>
+			<ref name="common-num-format-attlist"/>
+		</optional>
+	</define>
+	<define name="text-toc-mark-start-attrs">
+		<ref name="text-id"/>
+		<ref name="text-outline-level"/>
+	</define>
+	<define name="text-outline-level">
+		<optional>
+			<attribute name="text:outline-level">
+				<ref name="positiveInteger"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="text-id">
+		<attribute name="text:id">
+			<ref name="string"/>
+		</attribute>
+	</define>
+	<define name="text-index-name">
+		<attribute name="text:index-name">
+			<ref name="string"/>
+		</attribute>
+	</define>
+	<define name="text-alphabetical-index-mark-attrs">
+		<interleave>
+			<optional>
+				<attribute name="text:key1">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:key2">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:string-value-phonetic">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:key1-phonetic">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:key2-phonetic">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:main-entry">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="text-bibliography-types">
+		<choice>
+			<value>article</value>
+			<value>book</value>
+			<value>booklet</value>
+			<value>conference</value>
+			<value>custom1</value>
+			<value>custom2</value>
+			<value>custom3</value>
+			<value>custom4</value>
+			<value>custom5</value>
+			<value>email</value>
+			<value>inbook</value>
+			<value>incollection</value>
+			<value>inproceedings</value>
+			<value>journal</value>
+			<value>manual</value>
+			<value>mastersthesis</value>
+			<value>misc</value>
+			<value>phdthesis</value>
+			<value>proceedings</value>
+			<value>techreport</value>
+			<value>unpublished</value>
+			<value>www</value>
+		</choice>
+	</define>
+	<define name="text-index-body">
+		<element name="text:index-body">
+			<zeroOrMore>
+				<ref name="index-content-main"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="index-content-main">
+		<choice>
+			<ref name="text-content"/>
+			<ref name="text-index-title"/>
+		</choice>
+	</define>
+	<define name="text-index-title">
+		<element name="text:index-title">
+			<ref name="common-section-attlist"/>
+			<zeroOrMore>
+				<ref name="index-content-main"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="text-table-of-content">
+		<element name="text:table-of-content">
+			<ref name="common-section-attlist"/>
+			<ref name="text-table-of-content-source"/>
+			<ref name="text-index-body"/>
+		</element>
+	</define>
+	<define name="text-table-of-content-source">
+		<element name="text:table-of-content-source">
+			<ref name="text-table-of-content-source-attlist"/>
+			<optional>
+				<ref name="text-index-title-template"/>
+			</optional>
+			<zeroOrMore>
+				<ref name="text-table-of-content-entry-template"/>
+			</zeroOrMore>
+			<zeroOrMore>
+				<ref name="text-index-source-styles"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="text-table-of-content-source-attlist">
+		<interleave>
+			<optional>
+				<attribute name="text:outline-level">
+					<ref name="positiveInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:use-outline-level">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:use-index-marks">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:use-index-source-styles">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:index-scope">
+					<choice>
+						<value>document</value>
+						<value>chapter</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:relative-tab-stop-position">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="text-table-of-content-entry-template">
+		<element name="text:table-of-content-entry-template">
+			<ref name="text-table-of-content-entry-template-attlist"/>
+			<zeroOrMore>
+				<ref name="text-table-of-content-children"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="text-table-of-content-children">
+		<choice>
+			<ref name="text-index-entry-chapter"/>
+			<ref name="text-index-entry-page-number"/>
+			<ref name="text-index-entry-text"/>
+			<ref name="text-index-entry-span"/>
+			<ref name="text-index-entry-tab-stop"/>
+			<ref name="text-index-entry-link-start"/>
+			<ref name="text-index-entry-link-end"/>
+		</choice>
+	</define>
+	<define name="text-table-of-content-entry-template-attlist">
+		<interleave>
+			<attribute name="text:outline-level">
+				<ref name="positiveInteger"/>
+			</attribute>
+			<attribute name="text:style-name">
+				<ref name="styleNameRef"/>
+			</attribute>
+		</interleave>
+	</define>
+	<define name="text-illustration-index">
+		<element name="text:illustration-index">
+			<ref name="common-section-attlist"/>
+			<ref name="text-illustration-index-source"/>
+			<ref name="text-index-body"/>
+		</element>
+	</define>
+	<define name="text-illustration-index-source">
+		<element name="text:illustration-index-source">
+			<ref name="text-illustration-index-source-attrs"/>
+			<optional>
+				<ref name="text-index-title-template"/>
+			</optional>
+			<optional>
+				<ref name="text-illustration-index-entry-template"/>
+			</optional>
+		</element>
+	</define>
+	<define name="text-illustration-index-source-attrs">
+		<interleave>
+			<ref name="text-index-scope-attr"/>
+			<ref name="text-relative-tab-stop-position-attr"/>
+			<optional>
+				<attribute name="text:use-caption">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:caption-sequence-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:caption-sequence-format">
+					<choice>
+						<value>text</value>
+						<value>category-and-value</value>
+						<value>caption</value>
+					</choice>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="text-index-scope-attr">
+		<optional>
+			<attribute name="text:index-scope">
+				<choice>
+					<value>document</value>
+					<value>chapter</value>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="text-relative-tab-stop-position-attr">
+		<optional>
+			<attribute name="text:relative-tab-stop-position">
+				<ref name="boolean"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="text-illustration-index-entry-template">
+		<element name="text:illustration-index-entry-template">
+			<ref name="text-illustration-index-entry-content"/>
+		</element>
+	</define>
+	<define name="text-illustration-index-entry-content">
+		<ref name="text-illustration-index-entry-template-attrs"/>
+		<zeroOrMore>
+			<choice>
+				<ref name="text-index-entry-chapter"/>
+				<ref name="text-index-entry-page-number"/>
+				<ref name="text-index-entry-text"/>
+				<ref name="text-index-entry-span"/>
+				<ref name="text-index-entry-tab-stop"/>
+			</choice>
+		</zeroOrMore>
+	</define>
+	<define name="text-illustration-index-entry-template-attrs">
+		<attribute name="text:style-name">
+			<ref name="styleNameRef"/>
+		</attribute>
+	</define>
+	<define name="text-table-index">
+		<element name="text:table-index">
+			<ref name="common-section-attlist"/>
+			<ref name="text-table-index-source"/>
+			<ref name="text-index-body"/>
+		</element>
+	</define>
+	<define name="text-table-index-source">
+		<element name="text:table-index-source">
+			<ref name="text-illustration-index-source-attrs"/>
+			<optional>
+				<ref name="text-index-title-template"/>
+			</optional>
+			<optional>
+				<ref name="text-table-index-entry-template"/>
+			</optional>
+		</element>
+	</define>
+	<define name="text-table-index-entry-template">
+		<element name="text:table-index-entry-template">
+			<ref name="text-illustration-index-entry-content"/>
+		</element>
+	</define>
+	<define name="text-object-index">
+		<element name="text:object-index">
+			<ref name="common-section-attlist"/>
+			<ref name="text-object-index-source"/>
+			<ref name="text-index-body"/>
+		</element>
+	</define>
+	<define name="text-object-index-source">
+		<element name="text:object-index-source">
+			<ref name="text-object-index-source-attrs"/>
+			<optional>
+				<ref name="text-index-title-template"/>
+			</optional>
+			<optional>
+				<ref name="text-object-index-entry-template"/>
+			</optional>
+		</element>
+	</define>
+	<define name="text-object-index-source-attrs">
+		<interleave>
+			<ref name="text-index-scope-attr"/>
+			<ref name="text-relative-tab-stop-position-attr"/>
+			<optional>
+				<attribute name="text:use-spreadsheet-objects">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:use-math-objects">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:use-draw-objects">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:use-chart-objects">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:use-other-objects">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="text-object-index-entry-template">
+		<element name="text:object-index-entry-template">
+			<ref name="text-illustration-index-entry-content"/>
+		</element>
+	</define>
+	<define name="text-user-index">
+		<element name="text:user-index">
+			<ref name="common-section-attlist"/>
+			<ref name="text-user-index-source"/>
+			<ref name="text-index-body"/>
+		</element>
+	</define>
+	<define name="text-user-index-source">
+		<element name="text:user-index-source">
+			<ref name="text-user-index-source-attr"/>
+			<optional>
+				<ref name="text-index-title-template"/>
+			</optional>
+			<zeroOrMore>
+				<ref name="text-user-index-entry-template"/>
+			</zeroOrMore>
+			<zeroOrMore>
+				<ref name="text-index-source-styles"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="text-user-index-source-attr">
+		<interleave>
+			<ref name="text-index-scope-attr"/>
+			<ref name="text-relative-tab-stop-position-attr"/>
+			<optional>
+				<attribute name="text:use-index-marks">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:use-index-source-styles">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:use-graphics">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:use-tables">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:use-floating-frames">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:use-objects">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:copy-outline-levels">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<attribute name="text:index-name">
+				<ref name="string"/>
+			</attribute>
+		</interleave>
+	</define>
+	<define name="text-user-index-entry-template">
+		<element name="text:user-index-entry-template">
+			<ref name="text-user-index-entry-template-attrs"/>
+			<zeroOrMore>
+				<choice>
+					<ref name="text-index-entry-chapter"/>
+					<ref name="text-index-entry-page-number"/>
+					<ref name="text-index-entry-text"/>
+					<ref name="text-index-entry-span"/>
+					<ref name="text-index-entry-tab-stop"/>
+				</choice>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="text-user-index-entry-template-attrs">
+		<interleave>
+			<attribute name="text:outline-level">
+				<ref name="positiveInteger"/>
+			</attribute>
+			<attribute name="text:style-name">
+				<ref name="styleNameRef"/>
+			</attribute>
+		</interleave>
+	</define>
+	<define name="text-alphabetical-index">
+		<element name="text:alphabetical-index">
+			<ref name="common-section-attlist"/>
+			<ref name="text-alphabetical-index-source"/>
+			<ref name="text-index-body"/>
+		</element>
+	</define>
+	<define name="text-alphabetical-index-source">
+		<element name="text:alphabetical-index-source">
+			<ref name="text-alphabetical-index-source-attrs"/>
+			<optional>
+				<ref name="text-index-title-template"/>
+			</optional>
+			<zeroOrMore>
+				<ref name="text-alphabetical-index-entry-template"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="text-alphabetical-index-source-attrs">
+		<interleave>
+			<ref name="text-index-scope-attr"/>
+			<ref name="text-relative-tab-stop-position-attr"/>
+			<optional>
+				<attribute name="text:ignore-case">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:main-entry-style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:alphabetical-separators">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:combine-entries">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:combine-entries-with-dash">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:combine-entries-with-pp">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:use-keys-as-entries">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:capitalize-entries">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:comma-separated">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:language">
+					<ref name="languageCode"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:country">
+					<ref name="countryCode"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:script">
+					<ref name="scriptCode"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:rfc-language-tag">
+					<ref name="language"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:sort-algorithm">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="text-alphabetical-index-auto-mark-file">
+		<element name="text:alphabetical-index-auto-mark-file">
+			<attribute name="xlink:type">
+				<value>simple</value>
+			</attribute>
+			<attribute name="xlink:href">
+				<ref name="anyIRI"/>
+			</attribute>
+		</element>
+	</define>
+	<define name="text-alphabetical-index-entry-template">
+		<element name="text:alphabetical-index-entry-template">
+			<ref name="text-alphabetical-index-entry-template-attrs"/>
+			<zeroOrMore>
+				<choice>
+					<ref name="text-index-entry-chapter"/>
+					<ref name="text-index-entry-page-number"/>
+					<ref name="text-index-entry-text"/>
+					<ref name="text-index-entry-span"/>
+					<ref name="text-index-entry-tab-stop"/>
+				</choice>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="text-alphabetical-index-entry-template-attrs">
+		<interleave>
+			<attribute name="text:outline-level">
+				<choice>
+					<value>1</value>
+					<value>2</value>
+					<value>3</value>
+					<value>separator</value>
+				</choice>
+			</attribute>
+			<attribute name="text:style-name">
+				<ref name="styleNameRef"/>
+			</attribute>
+		</interleave>
+	</define>
+	<define name="text-bibliography">
+		<element name="text:bibliography">
+			<ref name="common-section-attlist"/>
+			<ref name="text-bibliography-source"/>
+			<ref name="text-index-body"/>
+		</element>
+	</define>
+	<define name="text-bibliography-source">
+		<element name="text:bibliography-source">
+			<optional>
+				<ref name="text-index-title-template"/>
+			</optional>
+			<zeroOrMore>
+				<ref name="text-bibliography-entry-template"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="text-bibliography-entry-template">
+		<element name="text:bibliography-entry-template">
+			<ref name="text-bibliography-entry-template-attrs"/>
+			<zeroOrMore>
+				<choice>
+					<ref name="text-index-entry-span"/>
+					<ref name="text-index-entry-tab-stop"/>
+					<ref name="text-index-entry-bibliography"/>
+				</choice>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="text-bibliography-entry-template-attrs">
+		<interleave>
+			<attribute name="text:bibliography-type">
+				<ref name="text-bibliography-types"/>
+			</attribute>
+			<attribute name="text:style-name">
+				<ref name="styleNameRef"/>
+			</attribute>
+		</interleave>
+	</define>
+	<define name="text-index-source-styles">
+		<element name="text:index-source-styles">
+			<attribute name="text:outline-level">
+				<ref name="positiveInteger"/>
+			</attribute>
+			<zeroOrMore>
+				<ref name="text-index-source-style"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="text-index-source-style">
+		<element name="text:index-source-style">
+			<attribute name="text:style-name">
+				<ref name="styleName"/>
+			</attribute>
+			<empty/>
+		</element>
+	</define>
+	<define name="text-index-title-template">
+		<element name="text:index-title-template">
+			<optional>
+				<attribute name="text:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<text/>
+		</element>
+	</define>
+	<define name="text-index-entry-chapter">
+		<element name="text:index-entry-chapter">
+			<optional>
+				<attribute name="text:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<ref name="text-index-entry-chapter-attrs"/>
+		</element>
+	</define>
+	<define name="text-index-entry-chapter-attrs">
+		<interleave>
+			<optional>
+				<attribute name="text:display">
+					<choice>
+						<value>name</value>
+						<value>number</value>
+						<value>number-and-name</value>
+						<value>plain-number</value>
+						<value>plain-number-and-name</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:outline-level">
+					<ref name="positiveInteger"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="text-index-entry-text">
+		<element name="text:index-entry-text">
+			<optional>
+				<attribute name="text:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+		</element>
+	</define>
+	<define name="text-index-entry-page-number">
+		<element name="text:index-entry-page-number">
+			<optional>
+				<attribute name="text:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+		</element>
+	</define>
+	<define name="text-index-entry-span">
+		<element name="text:index-entry-span">
+			<optional>
+				<attribute name="text:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<text/>
+		</element>
+	</define>
+	<define name="text-index-entry-bibliography">
+		<element name="text:index-entry-bibliography">
+			<ref name="text-index-entry-bibliography-attrs"/>
+		</element>
+	</define>
+	<define name="text-index-entry-bibliography-attrs">
+		<interleave>
+			<optional>
+				<attribute name="text:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<attribute name="text:bibliography-data-field">
+				<choice>
+					<value>address</value>
+					<value>annote</value>
+					<value>author</value>
+					<value>bibliography-type</value>
+					<value>booktitle</value>
+					<value>chapter</value>
+					<value>custom1</value>
+					<value>custom2</value>
+					<value>custom3</value>
+					<value>custom4</value>
+					<value>custom5</value>
+					<value>edition</value>
+					<value>editor</value>
+					<value>howpublished</value>
+					<value>identifier</value>
+					<value>institution</value>
+					<value>isbn</value>
+					<value>issn</value>
+					<value>journal</value>
+					<value>month</value>
+					<value>note</value>
+					<value>number</value>
+					<value>organizations</value>
+					<value>pages</value>
+					<value>publisher</value>
+					<value>report-type</value>
+					<value>school</value>
+					<value>series</value>
+					<value>title</value>
+					<value>url</value>
+					<value>volume</value>
+					<value>year</value>
+				</choice>
+			</attribute>
+		</interleave>
+	</define>
+	<define name="text-index-entry-tab-stop">
+		<element name="text:index-entry-tab-stop">
+			<optional>
+				<attribute name="text:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<ref name="text-index-entry-tab-stop-attrs"/>
+		</element>
+	</define>
+	<define name="text-index-entry-tab-stop-attrs">
+		<interleave>
+			<optional>
+				<attribute name="style:leader-char">
+					<ref name="character"/>
+				</attribute>
+			</optional>
+			<choice>
+				<attribute name="style:type">
+					<value>right</value>
+				</attribute>
+				<group>
+					<attribute name="style:type">
+						<value>left</value>
+					</attribute>
+					<attribute name="style:position">
+						<ref name="length"/>
+					</attribute>
+				</group>
+			</choice>
+		</interleave>
+	</define>
+	<define name="text-index-entry-link-start">
+		<element name="text:index-entry-link-start">
+			<optional>
+				<attribute name="text:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+		</element>
+	</define>
+	<define name="text-index-entry-link-end">
+		<element name="text:index-entry-link-end">
+			<optional>
+				<attribute name="text:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+		</element>
+	</define>
+	<define name="table-table">
+		<element name="table:table">
+			<ref name="table-table-attlist"/>
+			<optional>
+				<ref name="table-title"/>
+			</optional>
+			<optional>
+				<ref name="table-desc"/>
+			</optional>
+			<optional>
+				<ref name="table-table-source"/>
+			</optional>
+			<optional>
+				<ref name="office-dde-source"/>
+			</optional>
+			<optional>
+				<ref name="table-scenario"/>
+			</optional>
+			<optional>
+				<ref name="office-forms"/>
+			</optional>
+			<optional>
+				<ref name="table-shapes"/>
+			</optional>
+			<ref name="table-columns-and-groups"/>
+			<ref name="table-rows-and-groups"/>
+			<optional>
+				<ref name="table-named-expressions"/>
+			</optional>
+		</element>
+	</define>
+	<define name="table-columns-and-groups">
+		<oneOrMore>
+			<choice>
+				<ref name="table-table-column-group"/>
+				<ref name="table-columns-no-group"/>
+			</choice>
+		</oneOrMore>
+	</define>
+	<define name="table-columns-no-group">
+		<choice>
+			<group>
+				<ref name="table-columns"/>
+				<optional>
+					<ref name="table-table-header-columns"/>
+					<optional>
+						<ref name="table-columns"/>
+					</optional>
+				</optional>
+			</group>
+			<group>
+				<ref name="table-table-header-columns"/>
+				<optional>
+					<ref name="table-columns"/>
+				</optional>
+			</group>
+		</choice>
+	</define>
+	<define name="table-columns">
+		<choice>
+			<ref name="table-table-columns"/>
+			<oneOrMore>
+				<ref name="table-table-column"/>
+			</oneOrMore>
+		</choice>
+	</define>
+	<define name="table-rows-and-groups">
+		<oneOrMore>
+			<choice>
+				<ref name="table-table-row-group"/>
+				<ref name="table-rows-no-group"/>
+			</choice>
+		</oneOrMore>
+	</define>
+	<define name="table-rows-no-group">
+		<choice>
+			<group>
+				<ref name="table-rows"/>
+				<optional>
+					<ref name="table-table-header-rows"/>
+					<optional>
+						<ref name="table-rows"/>
+					</optional>
+				</optional>
+			</group>
+			<group>
+				<ref name="table-table-header-rows"/>
+				<optional>
+					<ref name="table-rows"/>
+				</optional>
+			</group>
+		</choice>
+	</define>
+	<define name="table-rows">
+		<choice>
+			<ref name="table-table-rows"/>
+			<oneOrMore>
+				<optional>
+					<ref name="text-soft-page-break"/>
+				</optional>
+				<ref name="table-table-row"/>
+			</oneOrMore>
+		</choice>
+	</define>
+	<define name="table-table-attlist">
+		<interleave>
+			<optional>
+				<attribute name="table:name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:template-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:use-first-row-styles">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:use-last-row-styles">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:use-first-column-styles">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:use-last-column-styles">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:use-banding-rows-styles">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:use-banding-columns-styles">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:protected">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:protection-key">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:protection-key-digest-algorithm">
+					<ref name="anyIRI"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:print">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:print-ranges">
+					<ref name="cellRangeAddressList"/>
+				</attribute>
+			</optional>
+			<optional>
+				<ref name="xml-id"/>
+			</optional>
+			<optional>
+				<attribute name="table:is-sub-table">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="table-title">
+		<element name="table:title">
+			<text/>
+		</element>
+	</define>
+	<define name="table-desc">
+		<element name="table:desc">
+			<text/>
+		</element>
+	</define>
+	<define name="table-table-row">
+		<element name="table:table-row">
+			<ref name="table-table-row-attlist"/>
+			<oneOrMore>
+				<choice>
+					<ref name="table-table-cell"/>
+					<ref name="table-covered-table-cell"/>
+				</choice>
+			</oneOrMore>
+		</element>
+	</define>
+	<define name="table-table-row-attlist">
+		<interleave>
+			<optional>
+				<attribute name="table:number-rows-repeated">
+					<ref name="positiveInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:default-cell-style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:visibility">
+					<ref name="table-visibility-value"/>
+				</attribute>
+			</optional>
+			<optional>
+				<ref name="xml-id"/>
+			</optional>
+		</interleave>
+	</define>
+	<define name="table-visibility-value">
+		<choice>
+			<value>visible</value>
+			<value>collapse</value>
+			<value>filter</value>
+		</choice>
+	</define>
+	<define name="table-table-cell">
+		<element name="table:table-cell">
+			<ref name="table-table-cell-attlist"/>
+			<ref name="table-table-cell-attlist-extra"/>
+			<ref name="table-table-cell-content"/>
+		</element>
+	</define>
+	<define name="table-covered-table-cell">
+		<element name="table:covered-table-cell">
+			<ref name="table-table-cell-attlist"/>
+			<ref name="table-table-cell-content"/>
+		</element>
+	</define>
+	<define name="table-table-cell-content">
+		<optional>
+			<ref name="table-cell-range-source"/>
+		</optional>
+		<optional>
+			<ref name="office-annotation"/>
+		</optional>
+		<optional>
+			<ref name="table-detective"/>
+		</optional>
+		<zeroOrMore>
+			<ref name="text-content"/>
+		</zeroOrMore>
+	</define>
+	<define name="table-table-cell-attlist">
+		<interleave>
+			<optional>
+				<attribute name="table:number-columns-repeated">
+					<ref name="positiveInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:content-validation-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:formula">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<ref name="common-value-and-type-attlist"/>
+			</optional>
+			<optional>
+				<attribute name="table:protect">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:protected">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<ref name="xml-id"/>
+			</optional>
+			<optional>
+				<ref name="common-in-content-meta-attlist"/>
+			</optional>
+		</interleave>
+	</define>
+	<define name="table-table-cell-attlist-extra">
+		<interleave>
+			<optional>
+				<attribute name="table:number-columns-spanned">
+					<ref name="positiveInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:number-rows-spanned">
+					<ref name="positiveInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:number-matrix-columns-spanned">
+					<ref name="positiveInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:number-matrix-rows-spanned">
+					<ref name="positiveInteger"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="table-table-column">
+		<element name="table:table-column">
+			<ref name="table-table-column-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-table-column-attlist">
+		<interleave>
+			<optional>
+				<attribute name="table:number-columns-repeated">
+					<ref name="positiveInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:visibility">
+					<ref name="table-visibility-value"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:default-cell-style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<ref name="xml-id"/>
+			</optional>
+		</interleave>
+	</define>
+	<define name="table-table-header-columns">
+		<element name="table:table-header-columns">
+			<oneOrMore>
+				<ref name="table-table-column"/>
+			</oneOrMore>
+		</element>
+	</define>
+	<define name="table-table-columns">
+		<element name="table:table-columns">
+			<oneOrMore>
+				<ref name="table-table-column"/>
+			</oneOrMore>
+		</element>
+	</define>
+	<define name="table-table-column-group">
+		<element name="table:table-column-group">
+			<ref name="table-table-column-group-attlist"/>
+			<ref name="table-columns-and-groups"/>
+		</element>
+	</define>
+	<define name="table-table-column-group-attlist">
+		<optional>
+			<attribute name="table:display">
+				<ref name="boolean"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="table-table-header-rows">
+		<element name="table:table-header-rows">
+			<oneOrMore>
+				<optional>
+					<ref name="text-soft-page-break"/>
+				</optional>
+				<ref name="table-table-row"/>
+			</oneOrMore>
+		</element>
+	</define>
+	<define name="table-table-rows">
+		<element name="table:table-rows">
+			<oneOrMore>
+				<optional>
+					<ref name="text-soft-page-break"/>
+				</optional>
+				<ref name="table-table-row"/>
+			</oneOrMore>
+		</element>
+	</define>
+	<define name="table-table-row-group">
+		<element name="table:table-row-group">
+			<ref name="table-table-row-group-attlist"/>
+			<ref name="table-rows-and-groups"/>
+		</element>
+	</define>
+	<define name="table-table-row-group-attlist">
+		<optional>
+			<attribute name="table:display">
+				<ref name="boolean"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="cellAddress">
+		<data type="string">
+			<param name="pattern">($?([^\. ']+|'([^']|'')+'))?\.$?[A-Z]+$?[0-9]+</param>
+		</data>
+	</define>
+	<define name="cellRangeAddress">
+		<choice>
+			<data type="string">
+				<param name="pattern">($?([^\. ']+|'([^']|'')+'))?\.$?[A-Z]+$?[0-9]+(:($?([^\. ']+|'([^']|'')+'))?\.$?[A-Z]+$?[0-9]+)?</param>
+			</data>
+			<data type="string">
+				<param name="pattern">($?([^\. ']+|'([^']|'')+'))?\.$?[0-9]+:($?([^\. ']+|'([^']|'')+'))?\.$?[0-9]+</param>
+			</data>
+			<data type="string">
+				<param name="pattern">($?([^\. ']+|'([^']|'')+'))?\.$?[A-Z]+:($?([^\. ']+|'([^']|'')+'))?\.$?[A-Z]+</param>
+			</data>
+		</choice>
+	</define>
+	<define name="cellRangeAddressList">
+		<data type="string"/>
+		<dc:description>Value is a space separated list of "cellRangeAddress" patterns</dc:description>
+	</define>
+	<define name="table-table-source">
+		<element name="table:table-source">
+			<ref name="table-table-source-attlist"/>
+			<ref name="table-linked-source-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-table-source-attlist">
+		<interleave>
+			<optional>
+				<attribute name="table:mode">
+					<choice>
+						<value>copy-all</value>
+						<value>copy-results-only</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:table-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="table-linked-source-attlist">
+		<interleave>
+			<attribute name="xlink:type">
+				<value>simple</value>
+			</attribute>
+			<attribute name="xlink:href">
+				<ref name="anyIRI"/>
+			</attribute>
+			<optional>
+				<attribute name="xlink:actuate">
+					<value>onRequest</value>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:filter-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:filter-options">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:refresh-delay">
+					<ref name="duration"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="table-scenario">
+		<element name="table:scenario">
+			<ref name="table-scenario-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-scenario-attlist">
+		<interleave>
+			<attribute name="table:scenario-ranges">
+				<ref name="cellRangeAddressList"/>
+			</attribute>
+			<attribute name="table:is-active">
+				<ref name="boolean"/>
+			</attribute>
+			<optional>
+				<attribute name="table:display-border">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:border-color">
+					<ref name="color"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:copy-back">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:copy-styles">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:copy-formulas">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:comment">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:protected">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="table-shapes">
+		<element name="table:shapes">
+			<oneOrMore>
+				<ref name="shape"/>
+			</oneOrMore>
+		</element>
+	</define>
+	<define name="table-cell-range-source">
+		<element name="table:cell-range-source">
+			<ref name="table-table-cell-range-source-attlist"/>
+			<ref name="table-linked-source-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-table-cell-range-source-attlist">
+		<interleave>
+			<attribute name="table:name">
+				<ref name="string"/>
+			</attribute>
+			<attribute name="table:last-column-spanned">
+				<ref name="positiveInteger"/>
+			</attribute>
+			<attribute name="table:last-row-spanned">
+				<ref name="positiveInteger"/>
+			</attribute>
+		</interleave>
+	</define>
+	<define name="table-detective">
+		<element name="table:detective">
+			<zeroOrMore>
+				<ref name="table-highlighted-range"/>
+			</zeroOrMore>
+			<zeroOrMore>
+				<ref name="table-operation"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="table-operation">
+		<element name="table:operation">
+			<ref name="table-operation-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-operation-attlist">
+		<interleave>
+			<attribute name="table:name">
+				<choice>
+					<value>trace-dependents</value>
+					<value>remove-dependents</value>
+					<value>trace-precedents</value>
+					<value>remove-precedents</value>
+					<value>trace-errors</value>
+				</choice>
+			</attribute>
+			<attribute name="table:index">
+				<ref name="nonNegativeInteger"/>
+			</attribute>
+		</interleave>
+	</define>
+	<define name="table-highlighted-range">
+		<element name="table:highlighted-range">
+			<choice>
+				<group>
+					<ref name="table-highlighted-range-attlist"/>
+				</group>
+				<group>
+					<ref name="table-highlighted-range-attlist-invalid"/>
+				</group>
+			</choice>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-highlighted-range-attlist">
+		<interleave>
+			<optional>
+				<attribute name="table:cell-range-address">
+					<ref name="cellRangeAddress"/>
+				</attribute>
+			</optional>
+			<attribute name="table:direction">
+				<choice>
+					<value>from-another-table</value>
+					<value>to-another-table</value>
+					<value>from-same-table</value>
+				</choice>
+			</attribute>
+			<optional>
+				<attribute name="table:contains-error">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="table-highlighted-range-attlist-invalid">
+		<attribute name="table:marked-invalid">
+			<ref name="boolean"/>
+		</attribute>
+	</define>
+	<define name="office-spreadsheet-attlist">
+		<optional>
+			<attribute name="table:structure-protected">
+				<ref name="boolean"/>
+			</attribute>
+		</optional>
+		<optional>
+			<attribute name="table:protection-key">
+				<ref name="string"/>
+			</attribute>
+		</optional>
+		<optional>
+			<attribute name="table:protection-key-digest-algorithm">
+				<ref name="anyIRI"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="table-calculation-settings">
+		<element name="table:calculation-settings">
+			<ref name="table-calculation-setting-attlist"/>
+			<optional>
+				<ref name="table-null-date"/>
+			</optional>
+			<optional>
+				<ref name="table-iteration"/>
+			</optional>
+		</element>
+	</define>
+	<define name="table-calculation-setting-attlist">
+		<interleave>
+			<optional>
+				<attribute name="table:case-sensitive">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:precision-as-shown">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:search-criteria-must-apply-to-whole-cell">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:automatic-find-labels">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:use-regular-expressions">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:use-wildcards">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:null-year">
+					<ref name="positiveInteger"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="table-null-date">
+		<element name="table:null-date">
+			<optional>
+				<attribute name="table:value-type">
+					<value>date</value>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:date-value">
+					<ref name="date"/>
+				</attribute>
+			</optional>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-iteration">
+		<element name="table:iteration">
+			<optional>
+				<attribute name="table:status">
+					<choice>
+						<value>enable</value>
+						<value>disable</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:steps">
+					<ref name="positiveInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:maximum-difference">
+					<ref name="double"/>
+				</attribute>
+			</optional>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-content-validations">
+		<element name="table:content-validations">
+			<oneOrMore>
+				<ref name="table-content-validation"/>
+			</oneOrMore>
+		</element>
+	</define>
+	<define name="table-content-validation">
+		<element name="table:content-validation">
+			<ref name="table-validation-attlist"/>
+			<optional>
+				<ref name="table-help-message"/>
+			</optional>
+			<optional>
+				<choice>
+					<ref name="table-error-message"/>
+					<group>
+						<ref name="table-error-macro"/>
+						<ref name="office-event-listeners"/>
+					</group>
+				</choice>
+			</optional>
+		</element>
+	</define>
+	<define name="table-validation-attlist">
+		<interleave>
+			<attribute name="table:name">
+				<ref name="string"/>
+			</attribute>
+			<optional>
+				<attribute name="table:condition">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:base-cell-address">
+					<ref name="cellAddress"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:allow-empty-cell">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:display-list">
+					<choice>
+						<value>none</value>
+						<value>unsorted</value>
+						<value>sort-ascending</value>
+					</choice>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="table-help-message">
+		<element name="table:help-message">
+			<optional>
+				<attribute name="table:title">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:display">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<zeroOrMore>
+				<ref name="text-p"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="table-error-message">
+		<element name="table:error-message">
+			<optional>
+				<attribute name="table:title">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:display">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:message-type">
+					<choice>
+						<value>stop</value>
+						<value>warning</value>
+						<value>information</value>
+					</choice>
+				</attribute>
+			</optional>
+			<zeroOrMore>
+				<ref name="text-p"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="table-error-macro">
+		<element name="table:error-macro">
+			<optional>
+				<attribute name="table:execute">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</element>
+	</define>
+	<define name="table-label-ranges">
+		<element name="table:label-ranges">
+			<zeroOrMore>
+				<ref name="table-label-range"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="table-label-range">
+		<element name="table:label-range">
+			<ref name="table-label-range-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-label-range-attlist">
+		<interleave>
+			<attribute name="table:label-cell-range-address">
+				<ref name="cellRangeAddress"/>
+			</attribute>
+			<attribute name="table:data-cell-range-address">
+				<ref name="cellRangeAddress"/>
+			</attribute>
+			<attribute name="table:orientation">
+				<choice>
+					<value>column</value>
+					<value>row</value>
+				</choice>
+			</attribute>
+		</interleave>
+	</define>
+	<define name="table-named-expressions">
+		<element name="table:named-expressions">
+			<zeroOrMore>
+				<choice>
+					<ref name="table-named-range"/>
+					<ref name="table-named-expression"/>
+				</choice>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="table-named-range">
+		<element name="table:named-range">
+			<ref name="table-named-range-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-named-range-attlist">
+		<attribute name="table:name">
+			<ref name="string"/>
+		</attribute>
+		<attribute name="table:cell-range-address">
+			<ref name="cellRangeAddress"/>
+		</attribute>
+		<optional>
+			<attribute name="table:base-cell-address">
+				<ref name="cellAddress"/>
+			</attribute>
+		</optional>
+		<optional>
+			<attribute name="table:range-usable-as">
+				<choice>
+					<value>none</value>
+					<list>
+						<oneOrMore>
+							<choice>
+								<value>print-range</value>
+								<value>filter</value>
+								<value>repeat-row</value>
+								<value>repeat-column</value>
+							</choice>
+						</oneOrMore>
+					</list>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="table-named-expression">
+		<element name="table:named-expression">
+			<ref name="table-named-expression-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-named-expression-attlist">
+		<attribute name="table:name">
+			<ref name="string"/>
+		</attribute>
+		<attribute name="table:expression">
+			<ref name="string"/>
+		</attribute>
+		<optional>
+			<attribute name="table:base-cell-address">
+				<ref name="cellAddress"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="table-database-ranges">
+		<element name="table:database-ranges">
+			<zeroOrMore>
+				<ref name="table-database-range"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="table-database-range">
+		<element name="table:database-range">
+			<ref name="table-database-range-attlist"/>
+			<optional>
+				<choice>
+					<ref name="table-database-source-sql"/>
+					<ref name="table-database-source-table"/>
+					<ref name="table-database-source-query"/>
+				</choice>
+			</optional>
+			<optional>
+				<ref name="table-filter"/>
+			</optional>
+			<optional>
+				<ref name="table-sort"/>
+			</optional>
+			<optional>
+				<ref name="table-subtotal-rules"/>
+			</optional>
+		</element>
+	</define>
+	<define name="table-database-range-attlist">
+		<interleave>
+			<optional>
+				<attribute name="table:name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:is-selection">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:on-update-keep-styles">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:on-update-keep-size">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:has-persistent-data">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:orientation">
+					<choice>
+						<value>column</value>
+						<value>row</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:contains-header">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:display-filter-buttons">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<attribute name="table:target-range-address">
+				<ref name="cellRangeAddress"/>
+			</attribute>
+			<optional>
+				<attribute name="table:refresh-delay">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="table-database-source-sql">
+		<element name="table:database-source-sql">
+			<ref name="table-database-source-sql-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-database-source-sql-attlist">
+		<interleave>
+			<attribute name="table:database-name">
+				<ref name="string"/>
+			</attribute>
+			<attribute name="table:sql-statement">
+				<ref name="string"/>
+			</attribute>
+			<optional>
+				<attribute name="table:parse-sql-statement">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="table-database-source-query">
+		<element name="table:database-source-table">
+			<ref name="table-database-source-table-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-database-source-table-attlist">
+		<interleave>
+			<attribute name="table:database-name">
+				<ref name="string"/>
+			</attribute>
+			<attribute name="table:database-table-name">
+				<ref name="string"/>
+			</attribute>
+		</interleave>
+	</define>
+	<define name="table-database-source-table">
+		<element name="table:database-source-query">
+			<ref name="table-database-source-query-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-database-source-query-attlist">
+		<interleave>
+			<attribute name="table:database-name">
+				<ref name="string"/>
+			</attribute>
+			<attribute name="table:query-name">
+				<ref name="string"/>
+			</attribute>
+		</interleave>
+	</define>
+	<define name="table-sort">
+		<element name="table:sort">
+			<ref name="table-sort-attlist"/>
+			<oneOrMore>
+				<ref name="table-sort-by"/>
+			</oneOrMore>
+		</element>
+	</define>
+	<define name="table-sort-attlist">
+		<interleave>
+			<optional>
+				<attribute name="table:bind-styles-to-content">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:target-range-address">
+					<ref name="cellRangeAddress"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:case-sensitive">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:language">
+					<ref name="languageCode"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:country">
+					<ref name="countryCode"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:script">
+					<ref name="scriptCode"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:rfc-language-tag">
+					<ref name="language"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:algorithm">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:embedded-number-behavior">
+					<choice>
+						<value>alpha-numeric</value>
+						<value>integer</value>
+						<value>double</value>
+					</choice>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="table-sort-by">
+		<element name="table:sort-by">
+			<ref name="table-sort-by-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-sort-by-attlist">
+		<interleave>
+			<attribute name="table:field-number">
+				<ref name="nonNegativeInteger"/>
+			</attribute>
+			<optional>
+				<attribute name="table:data-type">
+					<choice>
+						<value>text</value>
+						<value>number</value>
+						<value>automatic</value>
+						<ref name="string"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:order">
+					<choice>
+						<value>ascending</value>
+						<value>descending</value>
+					</choice>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="table-subtotal-rules">
+		<element name="table:subtotal-rules">
+			<ref name="table-subtotal-rules-attlist"/>
+			<optional>
+				<ref name="table-sort-groups"/>
+			</optional>
+			<zeroOrMore>
+				<ref name="table-subtotal-rule"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="table-subtotal-rules-attlist">
+		<interleave>
+			<optional>
+				<attribute name="table:bind-styles-to-content">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:case-sensitive">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:page-breaks-on-group-change">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="table-sort-groups">
+		<element name="table:sort-groups">
+			<ref name="table-sort-groups-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-sort-groups-attlist">
+		<interleave>
+			<optional>
+				<attribute name="table:data-type">
+					<choice>
+						<value>text</value>
+						<value>number</value>
+						<value>automatic</value>
+						<ref name="string"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:order">
+					<choice>
+						<value>ascending</value>
+						<value>descending</value>
+					</choice>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="table-subtotal-rule">
+		<element name="table:subtotal-rule">
+			<ref name="table-subtotal-rule-attlist"/>
+			<zeroOrMore>
+				<ref name="table-subtotal-field"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="table-subtotal-rule-attlist">
+		<attribute name="table:group-by-field-number">
+			<ref name="nonNegativeInteger"/>
+		</attribute>
+	</define>
+	<define name="table-subtotal-field">
+		<element name="table:subtotal-field">
+			<ref name="table-subtotal-field-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-subtotal-field-attlist">
+		<interleave>
+			<attribute name="table:field-number">
+				<ref name="nonNegativeInteger"/>
+			</attribute>
+			<attribute name="table:function">
+				<choice>
+					<value>average</value>
+					<value>count</value>
+					<value>countnums</value>
+					<value>max</value>
+					<value>min</value>
+					<value>product</value>
+					<value>stdev</value>
+					<value>stdevp</value>
+					<value>sum</value>
+					<value>var</value>
+					<value>varp</value>
+					<ref name="string"/>
+				</choice>
+			</attribute>
+		</interleave>
+	</define>
+	<define name="table-filter">
+		<element name="table:filter">
+			<ref name="table-filter-attlist"/>
+			<choice>
+				<ref name="table-filter-condition"/>
+				<ref name="table-filter-and"/>
+				<ref name="table-filter-or"/>
+			</choice>
+		</element>
+	</define>
+	<define name="table-filter-attlist">
+		<interleave>
+			<optional>
+				<attribute name="table:target-range-address">
+					<ref name="cellRangeAddress"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:condition-source">
+					<choice>
+						<value>self</value>
+						<value>cell-range</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:condition-source-range-address">
+					<ref name="cellRangeAddress"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:display-duplicates">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="table-filter-and">
+		<element name="table:filter-and">
+			<oneOrMore>
+				<choice>
+					<ref name="table-filter-or"/>
+					<ref name="table-filter-condition"/>
+				</choice>
+			</oneOrMore>
+		</element>
+	</define>
+	<define name="table-filter-or">
+		<element name="table:filter-or">
+			<oneOrMore>
+				<choice>
+					<ref name="table-filter-and"/>
+					<ref name="table-filter-condition"/>
+				</choice>
+			</oneOrMore>
+		</element>
+	</define>
+	<define name="table-filter-condition">
+		<element name="table:filter-condition">
+			<ref name="table-filter-condition-attlist"/>
+			<zeroOrMore>
+				<ref name="table-filter-set-item"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="table-filter-condition-attlist">
+		<interleave>
+			<attribute name="table:field-number">
+				<ref name="nonNegativeInteger"/>
+			</attribute>
+			<attribute name="table:value">
+				<choice>
+					<ref name="string"/>
+					<ref name="double"/>
+				</choice>
+			</attribute>
+			<attribute name="table:operator">
+				<ref name="string"/>
+			</attribute>
+			<optional>
+				<attribute name="table:case-sensitive">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:data-type">
+					<choice>
+						<value>text</value>
+						<value>number</value>
+					</choice>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="table-filter-set-item">
+		<element name="table:filter-set-item">
+			<attribute name="table:value">
+				<ref name="string"/>
+			</attribute>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-data-pilot-tables">
+		<element name="table:data-pilot-tables">
+			<zeroOrMore>
+				<ref name="table-data-pilot-table"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="table-data-pilot-table">
+		<element name="table:data-pilot-table">
+			<ref name="table-data-pilot-table-attlist"/>
+			<optional>
+				<choice>
+					<ref name="table-database-source-sql"/>
+					<ref name="table-database-source-table"/>
+					<ref name="table-database-source-query"/>
+					<ref name="table-source-service"/>
+					<ref name="table-source-cell-range"/>
+				</choice>
+			</optional>
+			<oneOrMore>
+				<ref name="table-data-pilot-field"/>
+			</oneOrMore>
+		</element>
+	</define>
+	<define name="table-data-pilot-table-attlist">
+		<interleave>
+			<attribute name="table:name">
+				<ref name="string"/>
+			</attribute>
+			<optional>
+				<attribute name="table:application-data">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:grand-total">
+					<choice>
+						<value>none</value>
+						<value>row</value>
+						<value>column</value>
+						<value>both</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:ignore-empty-rows">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:identify-categories">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<attribute name="table:target-range-address">
+				<ref name="cellRangeAddress"/>
+			</attribute>
+			<optional>
+				<attribute name="table:buttons">
+					<ref name="cellRangeAddressList"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:show-filter-button">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:drill-down-on-double-click">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="table-source-cell-range">
+		<element name="table:source-cell-range">
+			<ref name="table-source-cell-range-attlist"/>
+			<optional>
+				<ref name="table-filter"/>
+			</optional>
+		</element>
+	</define>
+	<define name="table-source-cell-range-attlist">
+		<attribute name="table:cell-range-address">
+			<ref name="cellRangeAddress"/>
+		</attribute>
+	</define>
+	<define name="table-source-service">
+		<element name="table:source-service">
+			<ref name="table-source-service-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-source-service-attlist">
+		<interleave>
+			<attribute name="table:name">
+				<ref name="string"/>
+			</attribute>
+			<attribute name="table:source-name">
+				<ref name="string"/>
+			</attribute>
+			<attribute name="table:object-name">
+				<ref name="string"/>
+			</attribute>
+			<optional>
+				<attribute name="table:user-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:password">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="table-data-pilot-field">
+		<element name="table:data-pilot-field">
+			<ref name="table-data-pilot-field-attlist"/>
+			<optional>
+				<ref name="table-data-pilot-level"/>
+			</optional>
+			<optional>
+				<ref name="table-data-pilot-field-reference"/>
+			</optional>
+			<optional>
+				<ref name="table-data-pilot-groups"/>
+			</optional>
+		</element>
+	</define>
+	<define name="table-data-pilot-field-attlist">
+		<interleave>
+			<attribute name="table:source-field-name">
+				<ref name="string"/>
+			</attribute>
+			<choice>
+				<attribute name="table:orientation">
+					<choice>
+						<value>row</value>
+						<value>column</value>
+						<value>data</value>
+						<value>hidden</value>
+					</choice>
+				</attribute>
+				<group>
+					<attribute name="table:orientation">
+						<value>page</value>
+					</attribute>
+					<attribute name="table:selected-page">
+						<ref name="string"/>
+					</attribute>
+				</group>
+			</choice>
+			<optional>
+				<attribute name="table:is-data-layout-field">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:function">
+					<choice>
+						<value>auto</value>
+						<value>average</value>
+						<value>count</value>
+						<value>countnums</value>
+						<value>max</value>
+						<value>min</value>
+						<value>product</value>
+						<value>stdev</value>
+						<value>stdevp</value>
+						<value>sum</value>
+						<value>var</value>
+						<value>varp</value>
+						<ref name="string"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:used-hierarchy">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="table-data-pilot-level">
+		<element name="table:data-pilot-level">
+			<ref name="table-data-pilot-level-attlist"/>
+			<optional>
+				<ref name="table-data-pilot-subtotals"/>
+			</optional>
+			<optional>
+				<ref name="table-data-pilot-members"/>
+			</optional>
+			<optional>
+				<ref name="table-data-pilot-display-info"/>
+			</optional>
+			<optional>
+				<ref name="table-data-pilot-sort-info"/>
+			</optional>
+			<optional>
+				<ref name="table-data-pilot-layout-info"/>
+			</optional>
+		</element>
+	</define>
+	<define name="table-data-pilot-level-attlist">
+		<optional>
+			<attribute name="table:show-empty">
+				<ref name="boolean"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="table-data-pilot-subtotals">
+		<element name="table:data-pilot-subtotals">
+			<zeroOrMore>
+				<ref name="table-data-pilot-subtotal"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="table-data-pilot-subtotal">
+		<element name="table:data-pilot-subtotal">
+			<ref name="table-data-pilot-subtotal-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-data-pilot-subtotal-attlist">
+		<attribute name="table:function">
+			<choice>
+				<value>auto</value>
+				<value>average</value>
+				<value>count</value>
+				<value>countnums</value>
+				<value>max</value>
+				<value>min</value>
+				<value>product</value>
+				<value>stdev</value>
+				<value>stdevp</value>
+				<value>sum</value>
+				<value>var</value>
+				<value>varp</value>
+				<ref name="string"/>
+			</choice>
+		</attribute>
+	</define>
+	<define name="table-data-pilot-members">
+		<element name="table:data-pilot-members">
+			<zeroOrMore>
+				<ref name="table-data-pilot-member"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="table-data-pilot-member">
+		<element name="table:data-pilot-member">
+			<ref name="table-data-pilot-member-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-data-pilot-member-attlist">
+		<interleave>
+			<attribute name="table:name">
+				<ref name="string"/>
+			</attribute>
+			<optional>
+				<attribute name="table:display">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:show-details">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="table-data-pilot-display-info">
+		<element name="table:data-pilot-display-info">
+			<ref name="table-data-pilot-display-info-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-data-pilot-display-info-attlist">
+		<interleave>
+			<attribute name="table:enabled">
+				<ref name="boolean"/>
+			</attribute>
+			<attribute name="table:data-field">
+				<ref name="string"/>
+			</attribute>
+			<attribute name="table:member-count">
+				<ref name="nonNegativeInteger"/>
+			</attribute>
+			<attribute name="table:display-member-mode">
+				<choice>
+					<value>from-top</value>
+					<value>from-bottom</value>
+				</choice>
+			</attribute>
+		</interleave>
+	</define>
+	<define name="table-data-pilot-sort-info">
+		<element name="table:data-pilot-sort-info">
+			<ref name="table-data-pilot-sort-info-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-data-pilot-sort-info-attlist">
+		<interleave>
+			<choice>
+				<group>
+					<attribute name="table:sort-mode">
+						<value>data</value>
+					</attribute>
+					<attribute name="table:data-field">
+						<ref name="string"/>
+					</attribute>
+				</group>
+				<attribute name="table:sort-mode">
+					<choice>
+						<value>none</value>
+						<value>manual</value>
+						<value>name</value>
+					</choice>
+				</attribute>
+			</choice>
+			<attribute name="table:order">
+				<choice>
+					<value>ascending</value>
+					<value>descending</value>
+				</choice>
+			</attribute>
+		</interleave>
+	</define>
+	<define name="table-data-pilot-layout-info">
+		<element name="table:data-pilot-layout-info">
+			<ref name="table-data-pilot-layout-info-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-data-pilot-layout-info-attlist">
+		<interleave>
+			<attribute name="table:layout-mode">
+				<choice>
+					<value>tabular-layout</value>
+					<value>outline-subtotals-top</value>
+					<value>outline-subtotals-bottom</value>
+				</choice>
+			</attribute>
+			<attribute name="table:add-empty-lines">
+				<ref name="boolean"/>
+			</attribute>
+		</interleave>
+	</define>
+	<define name="table-data-pilot-field-reference">
+		<element name="table:data-pilot-field-reference">
+			<ref name="table-data-pilot-field-reference-attlist"/>
+		</element>
+	</define>
+	<define name="table-data-pilot-field-reference-attlist">
+		<interleave>
+			<attribute name="table:field-name">
+				<ref name="string"/>
+			</attribute>
+			<choice>
+				<group>
+					<attribute name="table:member-type">
+						<value>named</value>
+					</attribute>
+					<attribute name="table:member-name">
+						<ref name="string"/>
+					</attribute>
+				</group>
+				<attribute name="table:member-type">
+					<choice>
+						<value>previous</value>
+						<value>next</value>
+					</choice>
+				</attribute>
+			</choice>
+			<attribute name="table:type">
+				<choice>
+					<value>none</value>
+					<value>member-difference</value>
+					<value>member-percentage</value>
+					<value>member-percentage-difference</value>
+					<value>running-total</value>
+					<value>row-percentage</value>
+					<value>column-percentage</value>
+					<value>total-percentage</value>
+					<value>index</value>
+				</choice>
+			</attribute>
+		</interleave>
+	</define>
+	<define name="table-data-pilot-groups">
+		<element name="table:data-pilot-groups">
+			<ref name="table-data-pilot-groups-attlist"/>
+			<oneOrMore>
+				<ref name="table-data-pilot-group"/>
+			</oneOrMore>
+		</element>
+	</define>
+	<define name="table-data-pilot-groups-attlist">
+		<interleave>
+			<attribute name="table:source-field-name">
+				<ref name="string"/>
+			</attribute>
+			<choice>
+				<attribute name="table:date-start">
+					<choice>
+						<ref name="dateOrDateTime"/>
+						<value>auto</value>
+					</choice>
+				</attribute>
+				<attribute name="table:start">
+					<choice>
+						<ref name="double"/>
+						<value>auto</value>
+					</choice>
+				</attribute>
+			</choice>
+			<choice>
+				<attribute name="table:date-end">
+					<choice>
+						<ref name="dateOrDateTime"/>
+						<value>auto</value>
+					</choice>
+				</attribute>
+				<attribute name="table:end">
+					<choice>
+						<ref name="double"/>
+						<value>auto</value>
+					</choice>
+				</attribute>
+			</choice>
+			<attribute name="table:step">
+				<ref name="double"/>
+			</attribute>
+			<attribute name="table:grouped-by">
+				<choice>
+					<value>seconds</value>
+					<value>minutes</value>
+					<value>hours</value>
+					<value>days</value>
+					<value>months</value>
+					<value>quarters</value>
+					<value>years</value>
+				</choice>
+			</attribute>
+		</interleave>
+	</define>
+	<define name="table-data-pilot-group">
+		<element name="table:data-pilot-group">
+			<ref name="table-data-pilot-group-attlist"/>
+			<oneOrMore>
+				<ref name="table-data-pilot-group-member"/>
+			</oneOrMore>
+		</element>
+	</define>
+	<define name="table-data-pilot-group-attlist">
+		<attribute name="table:name">
+			<ref name="string"/>
+		</attribute>
+	</define>
+	<define name="table-data-pilot-group-member">
+		<element name="table:data-pilot-group-member">
+			<ref name="table-data-pilot-group-member-attlist"/>
+		</element>
+	</define>
+	<define name="table-data-pilot-group-member-attlist">
+		<attribute name="table:name">
+			<ref name="string"/>
+		</attribute>
+	</define>
+	<define name="table-consolidation">
+		<element name="table:consolidation">
+			<ref name="table-consolidation-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-consolidation-attlist">
+		<interleave>
+			<attribute name="table:function">
+				<choice>
+					<value>average</value>
+					<value>count</value>
+					<value>countnums</value>
+					<value>max</value>
+					<value>min</value>
+					<value>product</value>
+					<value>stdev</value>
+					<value>stdevp</value>
+					<value>sum</value>
+					<value>var</value>
+					<value>varp</value>
+					<ref name="string"/>
+				</choice>
+			</attribute>
+			<attribute name="table:source-cell-range-addresses">
+				<ref name="cellRangeAddressList"/>
+			</attribute>
+			<attribute name="table:target-cell-address">
+				<ref name="cellAddress"/>
+			</attribute>
+			<optional>
+				<attribute name="table:use-labels">
+					<choice>
+						<value>none</value>
+						<value>row</value>
+						<value>column</value>
+						<value>both</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:link-to-source-data">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="table-dde-links">
+		<element name="table:dde-links">
+			<oneOrMore>
+				<ref name="table-dde-link"/>
+			</oneOrMore>
+		</element>
+	</define>
+	<define name="table-tracked-changes">
+		<element name="table:tracked-changes">
+			<ref name="table-tracked-changes-attlist"/>
+			<zeroOrMore>
+				<choice>
+					<ref name="table-cell-content-change"/>
+					<ref name="table-insertion"/>
+					<ref name="table-deletion"/>
+					<ref name="table-movement"/>
+				</choice>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="table-tracked-changes-attlist">
+		<optional>
+			<attribute name="table:track-changes">
+				<ref name="boolean"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="table-insertion">
+		<element name="table:insertion">
+			<ref name="table-insertion-attlist"/>
+			<ref name="common-table-change-attlist"/>
+			<ref name="office-change-info"/>
+			<optional>
+				<ref name="table-dependencies"/>
+			</optional>
+			<optional>
+				<ref name="table-deletions"/>
+			</optional>
+		</element>
+	</define>
+	<define name="table-insertion-attlist">
+		<interleave>
+			<attribute name="table:type">
+				<choice>
+					<value>row</value>
+					<value>column</value>
+					<value>table</value>
+				</choice>
+			</attribute>
+			<attribute name="table:position">
+				<ref name="integer"/>
+			</attribute>
+			<optional>
+				<attribute name="table:count">
+					<ref name="positiveInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:table">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="table-dependencies">
+		<element name="table:dependencies">
+			<oneOrMore>
+				<ref name="table-dependency"/>
+			</oneOrMore>
+		</element>
+	</define>
+	<define name="table-dependency">
+		<element name="table:dependency">
+			<attribute name="table:id">
+				<ref name="string"/>
+			</attribute>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-deletions">
+		<element name="table:deletions">
+			<oneOrMore>
+				<choice>
+					<ref name="table-cell-content-deletion"/>
+					<ref name="table-change-deletion"/>
+				</choice>
+			</oneOrMore>
+		</element>
+	</define>
+	<define name="table-cell-content-deletion">
+		<element name="table:cell-content-deletion">
+			<optional>
+				<attribute name="table:id">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<ref name="table-cell-address"/>
+			</optional>
+			<optional>
+				<ref name="table-change-track-table-cell"/>
+			</optional>
+		</element>
+	</define>
+	<define name="table-change-deletion">
+		<element name="table:change-deletion">
+			<optional>
+				<attribute name="table:id">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-deletion">
+		<element name="table:deletion">
+			<ref name="table-deletion-attlist"/>
+			<ref name="common-table-change-attlist"/>
+			<ref name="office-change-info"/>
+			<optional>
+				<ref name="table-dependencies"/>
+			</optional>
+			<optional>
+				<ref name="table-deletions"/>
+			</optional>
+			<optional>
+				<ref name="table-cut-offs"/>
+			</optional>
+		</element>
+	</define>
+	<define name="table-deletion-attlist">
+		<interleave>
+			<attribute name="table:type">
+				<choice>
+					<value>row</value>
+					<value>column</value>
+					<value>table</value>
+				</choice>
+			</attribute>
+			<attribute name="table:position">
+				<ref name="integer"/>
+			</attribute>
+			<optional>
+				<attribute name="table:table">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:multi-deletion-spanned">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="table-cut-offs">
+		<element name="table:cut-offs">
+			<choice>
+				<oneOrMore>
+					<ref name="table-movement-cut-off"/>
+				</oneOrMore>
+				<group>
+					<ref name="table-insertion-cut-off"/>
+					<zeroOrMore>
+						<ref name="table-movement-cut-off"/>
+					</zeroOrMore>
+				</group>
+			</choice>
+		</element>
+	</define>
+	<define name="table-insertion-cut-off">
+		<element name="table:insertion-cut-off">
+			<ref name="table-insertion-cut-off-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-insertion-cut-off-attlist">
+		<interleave>
+			<attribute name="table:id">
+				<ref name="string"/>
+			</attribute>
+			<attribute name="table:position">
+				<ref name="integer"/>
+			</attribute>
+		</interleave>
+	</define>
+	<define name="table-movement-cut-off">
+		<element name="table:movement-cut-off">
+			<ref name="table-movement-cut-off-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-movement-cut-off-attlist">
+		<choice>
+			<attribute name="table:position">
+				<ref name="integer"/>
+			</attribute>
+			<group>
+				<attribute name="table:start-position">
+					<ref name="integer"/>
+				</attribute>
+				<attribute name="table:end-position">
+					<ref name="integer"/>
+				</attribute>
+			</group>
+		</choice>
+	</define>
+	<define name="table-movement">
+		<element name="table:movement">
+			<ref name="common-table-change-attlist"/>
+			<ref name="table-source-range-address"/>
+			<ref name="table-target-range-address"/>
+			<ref name="office-change-info"/>
+			<optional>
+				<ref name="table-dependencies"/>
+			</optional>
+			<optional>
+				<ref name="table-deletions"/>
+			</optional>
+		</element>
+	</define>
+	<define name="table-source-range-address">
+		<element name="table:source-range-address">
+			<ref name="common-table-range-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-target-range-address">
+		<element name="table:target-range-address">
+			<ref name="common-table-range-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="common-table-range-attlist">
+		<choice>
+			<group>
+				<ref name="common-table-cell-address-attlist"/>
+			</group>
+			<group>
+				<ref name="common-table-cell-range-address-attlist"/>
+			</group>
+		</choice>
+	</define>
+	<define name="common-table-cell-address-attlist">
+		<attribute name="table:column">
+			<ref name="integer"/>
+		</attribute>
+		<attribute name="table:row">
+			<ref name="integer"/>
+		</attribute>
+		<attribute name="table:table">
+			<ref name="integer"/>
+		</attribute>
+	</define>
+	<define name="common-table-cell-range-address-attlist">
+		<attribute name="table:start-column">
+			<ref name="integer"/>
+		</attribute>
+		<attribute name="table:start-row">
+			<ref name="integer"/>
+		</attribute>
+		<attribute name="table:start-table">
+			<ref name="integer"/>
+		</attribute>
+		<attribute name="table:end-column">
+			<ref name="integer"/>
+		</attribute>
+		<attribute name="table:end-row">
+			<ref name="integer"/>
+		</attribute>
+		<attribute name="table:end-table">
+			<ref name="integer"/>
+		</attribute>
+	</define>
+	<define name="table-change-track-table-cell">
+		<element name="table:change-track-table-cell">
+			<ref name="table-change-track-table-cell-attlist"/>
+			<zeroOrMore>
+				<ref name="text-p"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="table-change-track-table-cell-attlist">
+		<interleave>
+			<optional>
+				<attribute name="table:cell-address">
+					<ref name="cellAddress"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:matrix-covered">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:formula">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:number-matrix-columns-spanned">
+					<ref name="positiveInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:number-matrix-rows-spanned">
+					<ref name="positiveInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<ref name="common-value-and-type-attlist"/>
+			</optional>
+		</interleave>
+	</define>
+	<define name="table-cell-content-change">
+		<element name="table:cell-content-change">
+			<ref name="common-table-change-attlist"/>
+			<ref name="table-cell-address"/>
+			<ref name="office-change-info"/>
+			<optional>
+				<ref name="table-dependencies"/>
+			</optional>
+			<optional>
+				<ref name="table-deletions"/>
+			</optional>
+			<ref name="table-previous"/>
+		</element>
+	</define>
+	<define name="table-cell-address">
+		<element name="table:cell-address">
+			<ref name="common-table-cell-address-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-previous">
+		<element name="table:previous">
+			<optional>
+				<attribute name="table:id">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<ref name="table-change-track-table-cell"/>
+		</element>
+	</define>
+	<define name="common-table-change-attlist">
+		<interleave>
+			<attribute name="table:id">
+				<ref name="string"/>
+			</attribute>
+			<optional>
+				<attribute name="table:acceptance-state">
+					<choice>
+						<value>accepted</value>
+						<value>rejected</value>
+						<value>pending</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:rejecting-change-id">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="style-handout-master">
+		<element name="style:handout-master">
+			<ref name="common-presentation-header-footer-attlist"/>
+			<ref name="style-handout-master-attlist"/>
+			<zeroOrMore>
+				<ref name="shape"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="style-handout-master-attlist">
+		<interleave>
+			<optional>
+				<attribute name="presentation:presentation-page-layout-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<attribute name="style:page-layout-name">
+				<ref name="styleNameRef"/>
+			</attribute>
+			<optional>
+				<attribute name="draw:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="draw-layer-set">
+		<element name="draw:layer-set">
+			<zeroOrMore>
+				<ref name="draw-layer"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="draw-layer">
+		<element name="draw:layer">
+			<ref name="draw-layer-attlist"/>
+			<optional>
+				<ref name="svg-title"/>
+			</optional>
+			<optional>
+				<ref name="svg-desc"/>
+			</optional>
+		</element>
+	</define>
+	<define name="draw-layer-attlist">
+		<interleave>
+			<attribute name="draw:name">
+				<ref name="string"/>
+			</attribute>
+			<optional>
+				<attribute name="draw:protected">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:display">
+					<choice>
+						<value>always</value>
+						<value>screen</value>
+						<value>printer</value>
+						<value>none</value>
+					</choice>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="draw-page">
+		<element name="draw:page">
+			<ref name="common-presentation-header-footer-attlist"/>
+			<ref name="draw-page-attlist"/>
+			<optional>
+				<ref name="svg-title"/>
+			</optional>
+			<optional>
+				<ref name="svg-desc"/>
+			</optional>
+			<optional>
+				<ref name="draw-layer-set"/>
+			</optional>
+			<optional>
+				<ref name="office-forms"/>
+			</optional>
+			<zeroOrMore>
+				<ref name="shape"/>
+			</zeroOrMore>
+			<optional>
+				<choice>
+					<ref name="presentation-animations"/>
+					<ref name="animation-element"/>
+				</choice>
+			</optional>
+			<optional>
+				<ref name="presentation-notes"/>
+			</optional>
+		</element>
+	</define>
+	<define name="draw-page-attlist">
+		<interleave>
+			<optional>
+				<attribute name="draw:name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<attribute name="draw:master-page-name">
+				<ref name="styleNameRef"/>
+			</attribute>
+			<optional>
+				<attribute name="presentation:presentation-page-layout-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<group>
+					<ref name="xml-id"/>
+					<optional>
+						<attribute name="draw:id">
+							<ref name="NCName"/>
+						</attribute>
+					</optional>
+				</group>
+			</optional>
+			<optional>
+				<attribute name="draw:nav-order">
+					<ref name="IDREFS"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="common-presentation-header-footer-attlist">
+		<interleave>
+			<optional>
+				<attribute name="presentation:use-header-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:use-footer-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:use-date-time-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="shape">
+		<choice>
+			<ref name="shape-instance"/>
+			<ref name="draw-a"/>
+		</choice>
+	</define>
+	<define name="shape-instance">
+		<choice>
+			<ref name="draw-rect"/>
+			<ref name="draw-line"/>
+			<ref name="draw-polyline"/>
+			<ref name="draw-polygon"/>
+			<ref name="draw-regular-polygon"/>
+			<ref name="draw-path"/>
+			<ref name="draw-circle"/>
+			<ref name="draw-ellipse"/>
+			<ref name="draw-g"/>
+			<ref name="draw-page-thumbnail"/>
+			<ref name="draw-frame"/>
+			<ref name="draw-measure"/>
+			<ref name="draw-caption"/>
+			<ref name="draw-connector"/>
+			<ref name="draw-control"/>
+			<ref name="dr3d-scene"/>
+			<ref name="draw-custom-shape"/>
+		</choice>
+	</define>
+	<define name="draw-rect">
+		<element name="draw:rect">
+			<ref name="draw-rect-attlist"/>
+			<ref name="common-draw-position-attlist"/>
+			<ref name="common-draw-size-attlist"/>
+			<ref name="common-draw-shape-with-text-and-styles-attlist"/>
+			<ref name="common-draw-caption-id-attlist"/>
+			<optional>
+				<ref name="svg-title"/>
+			</optional>
+			<optional>
+				<ref name="svg-desc"/>
+			</optional>
+			<optional>
+				<ref name="office-event-listeners"/>
+			</optional>
+			<zeroOrMore>
+				<ref name="draw-glue-point"/>
+			</zeroOrMore>
+			<ref name="draw-text"/>
+		</element>
+	</define>
+	<define name="draw-rect-attlist">
+		<choice>
+			<optional>
+				<attribute name="draw:corner-radius">
+					<ref name="nonNegativeLength"/>
+				</attribute>
+			</optional>
+			<group>
+				<optional>
+					<attribute name="svg:rx">
+						<ref name="nonNegativeLength"/>
+					</attribute>
+				</optional>
+				<optional>
+					<attribute name="svg:ry">
+						<ref name="nonNegativeLength"/>
+					</attribute>
+				</optional>
+			</group>
+		</choice>
+	</define>
+	<define name="draw-line">
+		<element name="draw:line">
+			<ref name="draw-line-attlist"/>
+			<ref name="common-draw-shape-with-text-and-styles-attlist"/>
+			<ref name="common-draw-caption-id-attlist"/>
+			<optional>
+				<ref name="svg-title"/>
+			</optional>
+			<optional>
+				<ref name="svg-desc"/>
+			</optional>
+			<optional>
+				<ref name="office-event-listeners"/>
+			</optional>
+			<zeroOrMore>
+				<ref name="draw-glue-point"/>
+			</zeroOrMore>
+			<ref name="draw-text"/>
+		</element>
+	</define>
+	<define name="draw-line-attlist">
+		<interleave>
+			<attribute name="svg:x1">
+				<ref name="coordinate"/>
+			</attribute>
+			<attribute name="svg:y1">
+				<ref name="coordinate"/>
+			</attribute>
+			<attribute name="svg:x2">
+				<ref name="coordinate"/>
+			</attribute>
+			<attribute name="svg:y2">
+				<ref name="coordinate"/>
+			</attribute>
+		</interleave>
+	</define>
+	<define name="draw-polyline">
+		<element name="draw:polyline">
+			<ref name="common-draw-points-attlist"/>
+			<ref name="common-draw-position-attlist"/>
+			<ref name="common-draw-size-attlist"/>
+			<ref name="common-draw-viewbox-attlist"/>
+			<ref name="common-draw-shape-with-text-and-styles-attlist"/>
+			<ref name="common-draw-caption-id-attlist"/>
+			<optional>
+				<ref name="svg-title"/>
+			</optional>
+			<optional>
+				<ref name="svg-desc"/>
+			</optional>
+			<optional>
+				<ref name="office-event-listeners"/>
+			</optional>
+			<zeroOrMore>
+				<ref name="draw-glue-point"/>
+			</zeroOrMore>
+			<ref name="draw-text"/>
+		</element>
+	</define>
+	<define name="common-draw-points-attlist">
+		<attribute name="draw:points">
+			<ref name="points"/>
+		</attribute>
+	</define>
+	<define name="draw-polygon">
+		<element name="draw:polygon">
+			<ref name="common-draw-points-attlist"/>
+			<ref name="common-draw-position-attlist"/>
+			<ref name="common-draw-size-attlist"/>
+			<ref name="common-draw-viewbox-attlist"/>
+			<ref name="common-draw-shape-with-text-and-styles-attlist"/>
+			<ref name="common-draw-caption-id-attlist"/>
+			<optional>
+				<ref name="svg-title"/>
+			</optional>
+			<optional>
+				<ref name="svg-desc"/>
+			</optional>
+			<optional>
+				<ref name="office-event-listeners"/>
+			</optional>
+			<zeroOrMore>
+				<ref name="draw-glue-point"/>
+			</zeroOrMore>
+			<ref name="draw-text"/>
+		</element>
+	</define>
+	<define name="draw-regular-polygon">
+		<element name="draw:regular-polygon">
+			<ref name="draw-regular-polygon-attlist"/>
+			<ref name="common-draw-position-attlist"/>
+			<ref name="common-draw-size-attlist"/>
+			<ref name="common-draw-shape-with-text-and-styles-attlist"/>
+			<ref name="common-draw-caption-id-attlist"/>
+			<optional>
+				<ref name="svg-title"/>
+			</optional>
+			<optional>
+				<ref name="svg-desc"/>
+			</optional>
+			<optional>
+				<ref name="office-event-listeners"/>
+			</optional>
+			<zeroOrMore>
+				<ref name="draw-glue-point"/>
+			</zeroOrMore>
+			<ref name="draw-text"/>
+		</element>
+	</define>
+	<define name="draw-regular-polygon-attlist">
+		<interleave>
+			<choice>
+				<attribute name="draw:concave">
+					<value>false</value>
+				</attribute>
+				<group>
+					<attribute name="draw:concave">
+						<value>true</value>
+					</attribute>
+					<ref name="draw-regular-polygon-sharpness-attlist"/>
+				</group>
+			</choice>
+			<attribute name="draw:corners">
+				<ref name="positiveInteger"/>
+			</attribute>
+		</interleave>
+	</define>
+	<define name="draw-regular-polygon-sharpness-attlist">
+		<attribute name="draw:sharpness">
+			<ref name="percent"/>
+		</attribute>
+	</define>
+	<define name="draw-path">
+		<element name="draw:path">
+			<ref name="common-draw-path-data-attlist"/>
+			<ref name="common-draw-position-attlist"/>
+			<ref name="common-draw-size-attlist"/>
+			<ref name="common-draw-viewbox-attlist"/>
+			<ref name="common-draw-shape-with-text-and-styles-attlist"/>
+			<ref name="common-draw-caption-id-attlist"/>
+			<optional>
+				<ref name="svg-title"/>
+			</optional>
+			<optional>
+				<ref name="svg-desc"/>
+			</optional>
+			<optional>
+				<ref name="office-event-listeners"/>
+			</optional>
+			<zeroOrMore>
+				<ref name="draw-glue-point"/>
+			</zeroOrMore>
+			<ref name="draw-text"/>
+		</element>
+	</define>
+	<define name="common-draw-path-data-attlist">
+		<attribute name="svg:d">
+			<ref name="pathData"/>
+		</attribute>
+	</define>
+	<define name="draw-circle">
+		<element name="draw:circle">
+			<choice>
+				<group>
+					<ref name="draw-circle-attlist"/>
+					<ref name="common-draw-circle-ellipse-pos-attlist"/>
+				</group>
+				<group>
+					<ref name="common-draw-position-attlist"/>
+					<ref name="common-draw-size-attlist"/>
+				</group>
+			</choice>
+			<ref name="common-draw-circle-ellipse-attlist"/>
+			<ref name="common-draw-shape-with-text-and-styles-attlist"/>
+			<ref name="common-draw-caption-id-attlist"/>
+			<optional>
+				<ref name="svg-title"/>
+			</optional>
+			<optional>
+				<ref name="svg-desc"/>
+			</optional>
+			<optional>
+				<ref name="office-event-listeners"/>
+			</optional>
+			<zeroOrMore>
+				<ref name="draw-glue-point"/>
+			</zeroOrMore>
+			<ref name="draw-text"/>
+		</element>
+	</define>
+	<define name="common-draw-circle-ellipse-pos-attlist">
+		<attribute name="svg:cx">
+			<ref name="coordinate"/>
+		</attribute>
+		<attribute name="svg:cy">
+			<ref name="coordinate"/>
+		</attribute>
+	</define>
+	<define name="draw-circle-attlist">
+		<attribute name="svg:r">
+			<ref name="length"/>
+		</attribute>
+	</define>
+	<define name="common-draw-circle-ellipse-attlist">
+		<interleave>
+			<optional>
+				<attribute name="draw:kind">
+					<choice>
+						<value>full</value>
+						<value>section</value>
+						<value>cut</value>
+						<value>arc</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:start-angle">
+					<ref name="angle"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:end-angle">
+					<ref name="angle"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="draw-ellipse">
+		<element name="draw:ellipse">
+			<choice>
+				<group>
+					<ref name="draw-ellipse-attlist"/>
+					<ref name="common-draw-circle-ellipse-pos-attlist"/>
+				</group>
+				<group>
+					<ref name="common-draw-position-attlist"/>
+					<ref name="common-draw-size-attlist"/>
+				</group>
+			</choice>
+			<ref name="common-draw-circle-ellipse-attlist"/>
+			<ref name="common-draw-shape-with-text-and-styles-attlist"/>
+			<ref name="common-draw-caption-id-attlist"/>
+			<optional>
+				<ref name="svg-title"/>
+			</optional>
+			<optional>
+				<ref name="svg-desc"/>
+			</optional>
+			<optional>
+				<ref name="office-event-listeners"/>
+			</optional>
+			<zeroOrMore>
+				<ref name="draw-glue-point"/>
+			</zeroOrMore>
+			<ref name="draw-text"/>
+		</element>
+	</define>
+	<define name="draw-ellipse-attlist">
+		<attribute name="svg:rx">
+			<ref name="length"/>
+		</attribute>
+		<attribute name="svg:ry">
+			<ref name="length"/>
+		</attribute>
+	</define>
+	<define name="draw-connector">
+		<element name="draw:connector">
+			<ref name="draw-connector-attlist"/>
+			<ref name="common-draw-shape-with-text-and-styles-attlist"/>
+			<ref name="common-draw-caption-id-attlist"/>
+			<ref name="common-draw-viewbox-attlist"/>
+			<optional>
+				<ref name="svg-title"/>
+			</optional>
+			<optional>
+				<ref name="svg-desc"/>
+			</optional>
+			<optional>
+				<ref name="office-event-listeners"/>
+			</optional>
+			<zeroOrMore>
+				<ref name="draw-glue-point"/>
+			</zeroOrMore>
+			<ref name="draw-text"/>
+		</element>
+	</define>
+	<define name="draw-connector-attlist">
+		<interleave>
+			<optional>
+				<attribute name="draw:type">
+					<choice>
+						<value>standard</value>
+						<value>lines</value>
+						<value>line</value>
+						<value>curve</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:x1">
+					<ref name="coordinate"/>
+				</attribute>
+				<attribute name="svg:y1">
+					<ref name="coordinate"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:start-shape">
+					<ref name="IDREF"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:start-glue-point">
+					<ref name="nonNegativeInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:x2">
+					<ref name="coordinate"/>
+				</attribute>
+				<attribute name="svg:y2">
+					<ref name="coordinate"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:end-shape">
+					<ref name="IDREF"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:end-glue-point">
+					<ref name="nonNegativeInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:line-skew">
+					<list>
+						<ref name="length"/>
+						<optional>
+							<ref name="length"/>
+							<optional>
+								<ref name="length"/>
+							</optional>
+						</optional>
+					</list>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:d">
+					<ref name="pathData"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="draw-caption">
+		<element name="draw:caption">
+			<ref name="draw-caption-attlist"/>
+			<ref name="common-draw-position-attlist"/>
+			<ref name="common-draw-size-attlist"/>
+			<ref name="common-draw-shape-with-text-and-styles-attlist"/>
+			<ref name="common-draw-caption-id-attlist"/>
+			<optional>
+				<ref name="svg-title"/>
+			</optional>
+			<optional>
+				<ref name="svg-desc"/>
+			</optional>
+			<optional>
+				<ref name="office-event-listeners"/>
+			</optional>
+			<zeroOrMore>
+				<ref name="draw-glue-point"/>
+			</zeroOrMore>
+			<ref name="draw-text"/>
+		</element>
+	</define>
+	<define name="draw-caption-attlist">
+		<interleave>
+			<optional>
+				<attribute name="draw:caption-point-x">
+					<ref name="coordinate"/>
+				</attribute>
+				<attribute name="draw:caption-point-y">
+					<ref name="coordinate"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:corner-radius">
+					<ref name="nonNegativeLength"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="draw-measure">
+		<element name="draw:measure">
+			<ref name="draw-measure-attlist"/>
+			<ref name="common-draw-shape-with-text-and-styles-attlist"/>
+			<ref name="common-draw-caption-id-attlist"/>
+			<optional>
+				<ref name="svg-title"/>
+			</optional>
+			<optional>
+				<ref name="svg-desc"/>
+			</optional>
+			<optional>
+				<ref name="office-event-listeners"/>
+			</optional>
+			<zeroOrMore>
+				<ref name="draw-glue-point"/>
+			</zeroOrMore>
+			<ref name="draw-text"/>
+		</element>
+	</define>
+	<define name="draw-measure-attlist">
+		<interleave>
+			<attribute name="svg:x1">
+				<ref name="coordinate"/>
+			</attribute>
+			<attribute name="svg:y1">
+				<ref name="coordinate"/>
+			</attribute>
+			<attribute name="svg:x2">
+				<ref name="coordinate"/>
+			</attribute>
+			<attribute name="svg:y2">
+				<ref name="coordinate"/>
+			</attribute>
+		</interleave>
+	</define>
+	<define name="draw-control">
+		<element name="draw:control">
+			<ref name="draw-control-attlist"/>
+			<ref name="common-draw-position-attlist"/>
+			<ref name="common-draw-size-attlist"/>
+			<ref name="common-draw-shape-with-text-and-styles-attlist"/>
+			<ref name="common-draw-caption-id-attlist"/>
+			<optional>
+				<ref name="svg-title"/>
+			</optional>
+			<optional>
+				<ref name="svg-desc"/>
+			</optional>
+			<zeroOrMore>
+				<ref name="draw-glue-point"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="draw-control-attlist">
+		<attribute name="draw:control">
+			<ref name="IDREF"/>
+		</attribute>
+	</define>
+	<define name="draw-page-thumbnail">
+		<element name="draw:page-thumbnail">
+			<ref name="draw-page-thumbnail-attlist"/>
+			<ref name="common-draw-position-attlist"/>
+			<ref name="common-draw-size-attlist"/>
+			<ref name="presentation-shape-attlist"/>
+			<ref name="common-draw-shape-with-styles-attlist"/>
+			<ref name="common-draw-caption-id-attlist"/>
+			<optional>
+				<ref name="svg-title"/>
+			</optional>
+			<optional>
+				<ref name="svg-desc"/>
+			</optional>
+		</element>
+	</define>
+	<define name="draw-page-thumbnail-attlist">
+		<optional>
+			<attribute name="draw:page-number">
+				<ref name="positiveInteger"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="draw-g">
+		<element name="draw:g">
+			<ref name="draw-g-attlist"/>
+			<ref name="common-draw-z-index-attlist"/>
+			<ref name="common-draw-name-attlist"/>
+			<ref name="common-draw-id-attlist"/>
+			<ref name="common-draw-style-name-attlist"/>
+			<ref name="common-text-spreadsheet-shape-attlist"/>
+			<ref name="common-draw-caption-id-attlist"/>
+			<optional>
+				<ref name="svg-title"/>
+			</optional>
+			<optional>
+				<ref name="svg-desc"/>
+			</optional>
+			<optional>
+				<ref name="office-event-listeners"/>
+			</optional>
+			<zeroOrMore>
+				<ref name="draw-glue-point"/>
+			</zeroOrMore>
+			<zeroOrMore>
+				<ref name="shape"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="draw-g-attlist">
+		<optional>
+			<attribute name="svg:y">
+				<ref name="coordinate"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-draw-name-attlist">
+		<optional>
+			<attribute name="draw:name">
+				<ref name="string"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-draw-caption-id-attlist">
+		<optional>
+			<attribute name="draw:caption-id">
+				<ref name="IDREF"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-draw-position-attlist">
+		<optional>
+			<attribute name="svg:x">
+				<ref name="coordinate"/>
+			</attribute>
+		</optional>
+		<optional>
+			<attribute name="svg:y">
+				<ref name="coordinate"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-draw-size-attlist">
+		<optional>
+			<attribute name="svg:width">
+				<ref name="length"/>
+			</attribute>
+		</optional>
+		<optional>
+			<attribute name="svg:height">
+				<ref name="length"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-draw-transform-attlist">
+		<optional>
+			<attribute name="draw:transform">
+				<ref name="string"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-draw-viewbox-attlist">
+		<attribute name="svg:viewBox">
+			<list>
+				<ref name="integer"/>
+				<ref name="integer"/>
+				<ref name="integer"/>
+				<ref name="integer"/>
+			</list>
+		</attribute>
+	</define>
+	<define name="common-draw-style-name-attlist">
+		<choice>
+			<group>
+				<optional>
+					<attribute name="draw:style-name">
+						<ref name="styleNameRef"/>
+					</attribute>
+				</optional>
+				<optional>
+					<attribute name="draw:class-names">
+						<ref name="styleNameRefs"/>
+					</attribute>
+				</optional>
+			</group>
+			<group>
+				<optional>
+					<attribute name="presentation:style-name">
+						<ref name="styleNameRef"/>
+					</attribute>
+				</optional>
+				<optional>
+					<attribute name="presentation:class-names">
+						<ref name="styleNameRefs"/>
+					</attribute>
+				</optional>
+			</group>
+		</choice>
+	</define>
+	<define name="common-draw-text-style-name-attlist">
+		<optional>
+			<attribute name="draw:text-style-name">
+				<ref name="styleNameRef"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-draw-layer-name-attlist">
+		<optional>
+			<attribute name="draw:layer">
+				<ref name="string"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-draw-id-attlist">
+		<optional>
+			<group>
+				<ref name="xml-id"/>
+				<optional>
+					<attribute name="draw:id">
+						<ref name="NCName"/>
+					</attribute>
+				</optional>
+			</group>
+		</optional>
+	</define>
+	<define name="common-draw-z-index-attlist">
+		<optional>
+			<attribute name="draw:z-index">
+				<ref name="nonNegativeInteger"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-text-spreadsheet-shape-attlist">
+		<interleave>
+			<optional>
+				<attribute name="table:end-cell-address">
+					<ref name="cellAddress"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:end-x">
+					<ref name="coordinate"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:end-y">
+					<ref name="coordinate"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:table-background">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<ref name="common-text-anchor-attlist"/>
+		</interleave>
+	</define>
+	<define name="common-text-anchor-attlist">
+		<interleave>
+			<optional>
+				<attribute name="text:anchor-type">
+					<choice>
+						<value>page</value>
+						<value>frame</value>
+						<value>paragraph</value>
+						<value>char</value>
+						<value>as-char</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:anchor-page-number">
+					<ref name="positiveInteger"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="draw-text">
+		<zeroOrMore>
+			<choice>
+				<ref name="text-p"/>
+				<ref name="text-list"/>
+			</choice>
+		</zeroOrMore>
+	</define>
+	<define name="common-draw-shape-with-styles-attlist">
+		<ref name="common-draw-z-index-attlist"/>
+		<ref name="common-draw-id-attlist"/>
+		<ref name="common-draw-layer-name-attlist"/>
+		<ref name="common-draw-style-name-attlist"/>
+		<ref name="common-draw-transform-attlist"/>
+		<ref name="common-draw-name-attlist"/>
+		<ref name="common-text-spreadsheet-shape-attlist"/>
+	</define>
+	<define name="common-draw-shape-with-text-and-styles-attlist">
+		<ref name="common-draw-shape-with-styles-attlist"/>
+		<ref name="common-draw-text-style-name-attlist"/>
+	</define>
+	<define name="draw-glue-point">
+		<element name="draw:glue-point">
+			<ref name="draw-glue-point-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="draw-glue-point-attlist">
+		<interleave>
+			<attribute name="draw:id">
+				<ref name="nonNegativeInteger"/>
+			</attribute>
+			<attribute name="svg:x">
+				<choice>
+					<ref name="distance"/>
+					<ref name="percent"/>
+				</choice>
+			</attribute>
+			<attribute name="svg:y">
+				<choice>
+					<ref name="distance"/>
+					<ref name="percent"/>
+				</choice>
+			</attribute>
+			<optional>
+				<attribute name="draw:align">
+					<choice>
+						<value>top-left</value>
+						<value>top</value>
+						<value>top-right</value>
+						<value>left</value>
+						<value>center</value>
+						<value>right</value>
+						<value>bottom-left</value>
+						<value>bottom-right</value>
+					</choice>
+				</attribute>
+			</optional>
+			<attribute name="draw:escape-direction">
+				<choice>
+					<value>auto</value>
+					<value>left</value>
+					<value>right</value>
+					<value>up</value>
+					<value>down</value>
+					<value>horizontal</value>
+					<value>vertical</value>
+				</choice>
+			</attribute>
+		</interleave>
+	</define>
+	<define name="svg-title">
+		<element name="svg:title">
+			<text/>
+		</element>
+	</define>
+	<define name="svg-desc">
+		<element name="svg:desc">
+			<text/>
+		</element>
+	</define>
+	<define name="draw-frame">
+		<element name="draw:frame">
+			<ref name="common-draw-shape-with-text-and-styles-attlist"/>
+			<ref name="common-draw-position-attlist"/>
+			<ref name="common-draw-rel-size-attlist"/>
+			<ref name="common-draw-caption-id-attlist"/>
+			<ref name="presentation-shape-attlist"/>
+			<ref name="draw-frame-attlist"/>
+			<zeroOrMore>
+				<choice>
+					<ref name="draw-text-box"/>
+					<ref name="draw-image"/>
+					<ref name="draw-object"/>
+					<ref name="draw-object-ole"/>
+					<ref name="draw-applet"/>
+					<ref name="draw-floating-frame"/>
+					<ref name="draw-plugin"/>
+					<ref name="table-table"/>
+				</choice>
+			</zeroOrMore>
+			<optional>
+				<ref name="office-event-listeners"/>
+			</optional>
+			<zeroOrMore>
+				<ref name="draw-glue-point"/>
+			</zeroOrMore>
+			<optional>
+				<ref name="draw-image-map"/>
+			</optional>
+			<optional>
+				<ref name="svg-title"/>
+			</optional>
+			<optional>
+				<ref name="svg-desc"/>
+			</optional>
+			<optional>
+				<choice>
+					<ref name="draw-contour-polygon"/>
+					<ref name="draw-contour-path"/>
+				</choice>
+			</optional>
+		</element>
+	</define>
+	<define name="common-draw-rel-size-attlist">
+		<ref name="common-draw-size-attlist"/>
+		<optional>
+			<attribute name="style:rel-width">
+				<choice>
+					<ref name="percent"/>
+					<value>scale</value>
+					<value>scale-min</value>
+				</choice>
+			</attribute>
+		</optional>
+		<optional>
+			<attribute name="style:rel-height">
+				<choice>
+					<ref name="percent"/>
+					<value>scale</value>
+					<value>scale-min</value>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="draw-frame-attlist">
+		<optional>
+			<attribute name="draw:copy-of">
+				<ref name="string"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="draw-text-box">
+		<element name="draw:text-box">
+			<ref name="draw-text-box-attlist"/>
+			<zeroOrMore>
+				<ref name="text-content"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="draw-text-box-attlist">
+		<interleave>
+			<optional>
+				<attribute name="draw:chain-next-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:corner-radius">
+					<ref name="nonNegativeLength"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:min-height">
+					<choice>
+						<ref name="length"/>
+						<ref name="percent"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:min-width">
+					<choice>
+						<ref name="length"/>
+						<ref name="percent"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:max-height">
+					<choice>
+						<ref name="length"/>
+						<ref name="percent"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:max-width">
+					<choice>
+						<ref name="length"/>
+						<ref name="percent"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<group>
+					<ref name="xml-id"/>
+					<optional>
+						<attribute name="text:id">
+							<ref name="NCName"/>
+						</attribute>
+					</optional>
+				</group>
+			</optional>
+		</interleave>
+	</define>
+	<define name="draw-image">
+		<element name="draw:image">
+			<ref name="draw-image-attlist"/>
+			<choice>
+				<ref name="common-draw-data-attlist"/>
+				<ref name="office-binary-data"/>
+			</choice>
+			<ref name="draw-text"/>
+		</element>
+	</define>
+	<define name="common-draw-data-attlist">
+		<group>
+			<attribute name="xlink:type">
+				<value>simple</value>
+			</attribute>
+			<attribute name="xlink:href">
+				<ref name="anyIRI"/>
+			</attribute>
+			<optional>
+				<attribute name="xlink:show">
+					<value>embed</value>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="xlink:actuate">
+					<value>onLoad</value>
+				</attribute>
+			</optional>
+		</group>
+	</define>
+	<define name="office-binary-data">
+		<element name="office:binary-data">
+			<ref name="base64Binary"/>
+		</element>
+	</define>
+	<define name="draw-image-attlist">
+		<interleave>
+			<optional>
+				<attribute name="draw:filter-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<ref name="xml-id"/>
+			</optional>
+		</interleave>
+	</define>
+	<define name="draw-object">
+		<element name="draw:object">
+			<ref name="draw-object-attlist"/>
+			<choice>
+				<ref name="common-draw-data-attlist"/>
+				<ref name="office-document"/>
+				<ref name="math-math"/>
+			</choice>
+		</element>
+	</define>
+	<define name="draw-object-ole">
+		<element name="draw:object-ole">
+			<ref name="draw-object-ole-attlist"/>
+			<choice>
+				<ref name="common-draw-data-attlist"/>
+				<ref name="office-binary-data"/>
+			</choice>
+		</element>
+	</define>
+	<define name="draw-object-attlist">
+		<interleave>
+			<optional>
+				<attribute name="draw:notify-on-update-of-ranges">
+					<choice>
+						<ref name="cellRangeAddressList"/>
+						<ref name="string"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<ref name="xml-id"/>
+			</optional>
+		</interleave>
+	</define>
+	<define name="draw-object-ole-attlist">
+		<interleave>
+			<optional>
+				<attribute name="draw:class-id">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<ref name="xml-id"/>
+			</optional>
+		</interleave>
+	</define>
+	<define name="draw-applet">
+		<element name="draw:applet">
+			<ref name="draw-applet-attlist"/>
+			<optional>
+				<ref name="common-draw-data-attlist"/>
+			</optional>
+			<zeroOrMore>
+				<ref name="draw-param"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="draw-applet-attlist">
+		<interleave>
+			<optional>
+				<attribute name="draw:code">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:object">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:archive">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:may-script">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<ref name="xml-id"/>
+			</optional>
+		</interleave>
+	</define>
+	<define name="draw-plugin">
+		<element name="draw:plugin">
+			<ref name="draw-plugin-attlist"/>
+			<ref name="common-draw-data-attlist"/>
+			<zeroOrMore>
+				<ref name="draw-param"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="draw-plugin-attlist">
+		<interleave>
+			<optional>
+				<attribute name="draw:mime-type">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<ref name="xml-id"/>
+			</optional>
+		</interleave>
+	</define>
+	<define name="draw-param">
+		<element name="draw:param">
+			<ref name="draw-param-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="draw-param-attlist">
+		<interleave>
+			<optional>
+				<attribute name="draw:name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:value">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="draw-floating-frame">
+		<element name="draw:floating-frame">
+			<ref name="draw-floating-frame-attlist"/>
+			<ref name="common-draw-data-attlist"/>
+		</element>
+	</define>
+	<define name="draw-floating-frame-attlist">
+		<interleave>
+			<optional>
+				<attribute name="draw:frame-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<ref name="xml-id"/>
+			</optional>
+		</interleave>
+	</define>
+	<define name="draw-contour-polygon">
+		<element name="draw:contour-polygon">
+			<ref name="common-contour-attlist"/>
+			<ref name="common-draw-size-attlist"/>
+			<ref name="common-draw-viewbox-attlist"/>
+			<ref name="common-draw-points-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="draw-contour-path">
+		<element name="draw:contour-path">
+			<ref name="common-contour-attlist"/>
+			<ref name="common-draw-size-attlist"/>
+			<ref name="common-draw-viewbox-attlist"/>
+			<ref name="common-draw-path-data-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="common-contour-attlist">
+		<attribute name="draw:recreate-on-edit">
+			<ref name="boolean"/>
+		</attribute>
+	</define>
+	<define name="draw-a">
+		<element name="draw:a">
+			<ref name="draw-a-attlist"/>
+			<ref name="shape-instance"/>
+		</element>
+	</define>
+	<define name="draw-a-attlist">
+		<interleave>
+			<attribute name="xlink:type">
+				<value>simple</value>
+			</attribute>
+			<attribute name="xlink:href">
+				<ref name="anyIRI"/>
+			</attribute>
+			<optional>
+				<attribute name="xlink:actuate">
+					<value>onRequest</value>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="office:target-frame-name">
+					<ref name="targetFrameName"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="xlink:show">
+					<choice>
+						<value>new</value>
+						<value>replace</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="office:name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="office:title">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="office:server-map">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<ref name="xml-id"/>
+			</optional>
+		</interleave>
+	</define>
+	<define name="draw-image-map">
+		<element name="draw:image-map">
+			<zeroOrMore>
+				<choice>
+					<ref name="draw-area-rectangle"/>
+					<ref name="draw-area-circle"/>
+					<ref name="draw-area-polygon"/>
+				</choice>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="draw-area-rectangle">
+		<element name="draw:area-rectangle">
+			<ref name="common-draw-area-attlist"/>
+			<attribute name="svg:x">
+				<ref name="coordinate"/>
+			</attribute>
+			<attribute name="svg:y">
+				<ref name="coordinate"/>
+			</attribute>
+			<attribute name="svg:width">
+				<ref name="length"/>
+			</attribute>
+			<attribute name="svg:height">
+				<ref name="length"/>
+			</attribute>
+			<optional>
+				<ref name="svg-title"/>
+			</optional>
+			<optional>
+				<ref name="svg-desc"/>
+			</optional>
+			<optional>
+				<ref name="office-event-listeners"/>
+			</optional>
+		</element>
+	</define>
+	<define name="draw-area-circle">
+		<element name="draw:area-circle">
+			<ref name="common-draw-area-attlist"/>
+			<attribute name="svg:cx">
+				<ref name="coordinate"/>
+			</attribute>
+			<attribute name="svg:cy">
+				<ref name="coordinate"/>
+			</attribute>
+			<attribute name="svg:r">
+				<ref name="length"/>
+			</attribute>
+			<optional>
+				<ref name="svg-title"/>
+			</optional>
+			<optional>
+				<ref name="svg-desc"/>
+			</optional>
+			<optional>
+				<ref name="office-event-listeners"/>
+			</optional>
+		</element>
+	</define>
+	<define name="draw-area-polygon">
+		<element name="draw:area-polygon">
+			<ref name="common-draw-area-attlist"/>
+			<attribute name="svg:x">
+				<ref name="coordinate"/>
+			</attribute>
+			<attribute name="svg:y">
+				<ref name="coordinate"/>
+			</attribute>
+			<attribute name="svg:width">
+				<ref name="length"/>
+			</attribute>
+			<attribute name="svg:height">
+				<ref name="length"/>
+			</attribute>
+			<ref name="common-draw-viewbox-attlist"/>
+			<ref name="common-draw-points-attlist"/>
+			<optional>
+				<ref name="svg-title"/>
+			</optional>
+			<optional>
+				<ref name="svg-desc"/>
+			</optional>
+			<optional>
+				<ref name="office-event-listeners"/>
+			</optional>
+		</element>
+	</define>
+	<define name="common-draw-area-attlist">
+		<interleave>
+			<optional>
+				<attribute name="xlink:type">
+					<value>simple</value>
+				</attribute>
+				<attribute name="xlink:href">
+					<ref name="anyIRI"/>
+				</attribute>
+				<optional>
+					<attribute name="office:target-frame-name">
+						<ref name="targetFrameName"/>
+					</attribute>
+				</optional>
+				<optional>
+					<attribute name="xlink:show">
+						<choice>
+							<value>new</value>
+							<value>replace</value>
+						</choice>
+					</attribute>
+				</optional>
+			</optional>
+			<optional>
+				<attribute name="office:name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:nohref">
+					<value>nohref</value>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="dr3d-scene">
+		<element name="dr3d:scene">
+			<ref name="dr3d-scene-attlist"/>
+			<ref name="common-draw-position-attlist"/>
+			<ref name="common-draw-size-attlist"/>
+			<ref name="common-draw-style-name-attlist"/>
+			<ref name="common-draw-z-index-attlist"/>
+			<ref name="common-draw-id-attlist"/>
+			<ref name="common-draw-layer-name-attlist"/>
+			<ref name="common-text-spreadsheet-shape-attlist"/>
+			<ref name="common-dr3d-transform-attlist"/>
+			<ref name="common-draw-caption-id-attlist"/>
+			<optional>
+				<ref name="svg-title"/>
+			</optional>
+			<optional>
+				<ref name="svg-desc"/>
+			</optional>
+			<zeroOrMore>
+				<ref name="dr3d-light"/>
+			</zeroOrMore>
+			<zeroOrMore>
+				<ref name="shapes3d"/>
+			</zeroOrMore>
+			<zeroOrMore>
+				<ref name="draw-glue-point"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="shapes3d">
+		<choice>
+			<ref name="dr3d-scene"/>
+			<ref name="dr3d-extrude"/>
+			<ref name="dr3d-sphere"/>
+			<ref name="dr3d-rotate"/>
+			<ref name="dr3d-cube"/>
+		</choice>
+	</define>
+	<define name="dr3d-scene-attlist">
+		<interleave>
+			<optional>
+				<attribute name="dr3d:vrp">
+					<ref name="vector3D"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="dr3d:vpn">
+					<ref name="vector3D"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="dr3d:vup">
+					<ref name="vector3D"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="dr3d:projection">
+					<choice>
+						<value>parallel</value>
+						<value>perspective</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="dr3d:distance">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="dr3d:focal-length">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="dr3d:shadow-slant">
+					<ref name="angle"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="dr3d:shade-mode">
+					<choice>
+						<value>flat</value>
+						<value>phong</value>
+						<value>gouraud</value>
+						<value>draft</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="dr3d:ambient-color">
+					<ref name="color"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="dr3d:lighting-mode">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="common-dr3d-transform-attlist">
+		<optional>
+			<attribute name="dr3d:transform">
+				<ref name="string"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="dr3d-light">
+		<element name="dr3d:light">
+			<ref name="dr3d-light-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="dr3d-light-attlist">
+		<interleave>
+			<optional>
+				<attribute name="dr3d:diffuse-color">
+					<ref name="color"/>
+				</attribute>
+			</optional>
+			<attribute name="dr3d:direction">
+				<ref name="vector3D"/>
+			</attribute>
+			<optional>
+				<attribute name="dr3d:enabled">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="dr3d:specular">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="dr3d-cube">
+		<element name="dr3d:cube">
+			<ref name="dr3d-cube-attlist"/>
+			<ref name="common-draw-z-index-attlist"/>
+			<ref name="common-draw-id-attlist"/>
+			<ref name="common-draw-layer-name-attlist"/>
+			<ref name="common-draw-style-name-attlist"/>
+			<ref name="common-dr3d-transform-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="dr3d-cube-attlist">
+		<optional>
+			<attribute name="dr3d:min-edge">
+				<ref name="vector3D"/>
+			</attribute>
+		</optional>
+		<optional>
+			<attribute name="dr3d:max-edge">
+				<ref name="vector3D"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="dr3d-sphere">
+		<element name="dr3d:sphere">
+			<ref name="dr3d-sphere-attlist"/>
+			<ref name="common-draw-z-index-attlist"/>
+			<ref name="common-draw-id-attlist"/>
+			<ref name="common-draw-layer-name-attlist"/>
+			<ref name="common-draw-style-name-attlist"/>
+			<ref name="common-dr3d-transform-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="dr3d-sphere-attlist">
+		<interleave>
+			<optional>
+				<attribute name="dr3d:center">
+					<ref name="vector3D"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="dr3d:size">
+					<ref name="vector3D"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="dr3d-extrude">
+		<element name="dr3d:extrude">
+			<ref name="common-draw-path-data-attlist"/>
+			<ref name="common-draw-viewbox-attlist"/>
+			<ref name="common-draw-id-attlist"/>
+			<ref name="common-draw-z-index-attlist"/>
+			<ref name="common-draw-layer-name-attlist"/>
+			<ref name="common-draw-style-name-attlist"/>
+			<ref name="common-dr3d-transform-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="dr3d-rotate">
+		<element name="dr3d:rotate">
+			<ref name="common-draw-viewbox-attlist"/>
+			<ref name="common-draw-path-data-attlist"/>
+			<ref name="common-draw-z-index-attlist"/>
+			<ref name="common-draw-id-attlist"/>
+			<ref name="common-draw-layer-name-attlist"/>
+			<ref name="common-draw-style-name-attlist"/>
+			<ref name="common-dr3d-transform-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="draw-custom-shape">
+		<element name="draw:custom-shape">
+			<ref name="draw-custom-shape-attlist"/>
+			<ref name="common-draw-position-attlist"/>
+			<ref name="common-draw-size-attlist"/>
+			<ref name="common-draw-shape-with-text-and-styles-attlist"/>
+			<ref name="common-draw-caption-id-attlist"/>
+			<optional>
+				<ref name="svg-title"/>
+			</optional>
+			<optional>
+				<ref name="svg-desc"/>
+			</optional>
+			<optional>
+				<ref name="office-event-listeners"/>
+			</optional>
+			<zeroOrMore>
+				<ref name="draw-glue-point"/>
+			</zeroOrMore>
+			<ref name="draw-text"/>
+			<optional>
+				<ref name="draw-enhanced-geometry"/>
+			</optional>
+		</element>
+	</define>
+	<define name="draw-custom-shape-attlist">
+		<interleave>
+			<optional>
+				<attribute name="draw:engine">
+					<ref name="namespacedToken"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:data">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="draw-enhanced-geometry">
+		<element name="draw:enhanced-geometry">
+			<ref name="draw-enhanced-geometry-attlist"/>
+			<zeroOrMore>
+				<ref name="draw-equation"/>
+			</zeroOrMore>
+			<zeroOrMore>
+				<ref name="draw-handle"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="draw-enhanced-geometry-attlist">
+		<interleave>
+			<optional>
+				<attribute name="draw:type">
+					<ref name="custom-shape-type"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:viewBox">
+					<list>
+						<ref name="integer"/>
+						<ref name="integer"/>
+						<ref name="integer"/>
+						<ref name="integer"/>
+					</list>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:mirror-vertical">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:mirror-horizontal">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:text-rotate-angle">
+					<ref name="angle"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:extrusion-allowed">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:text-path-allowed">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:concentric-gradient-fill-allowed">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:extrusion">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:extrusion-brightness">
+					<ref name="zeroToHundredPercent"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:extrusion-depth">
+					<list>
+						<ref name="length"/>
+						<ref name="double"/>
+					</list>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:extrusion-diffusion">
+					<ref name="percent"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:extrusion-number-of-line-segments">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:extrusion-light-face">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:extrusion-first-light-harsh">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:extrusion-second-light-harsh">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:extrusion-first-light-level">
+					<ref name="zeroToHundredPercent"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:extrusion-second-light-level">
+					<ref name="zeroToHundredPercent"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:extrusion-first-light-direction">
+					<ref name="vector3D"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:extrusion-second-light-direction">
+					<ref name="vector3D"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:extrusion-metal">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="dr3d:shade-mode">
+					<choice>
+						<value>flat</value>
+						<value>phong</value>
+						<value>gouraud</value>
+						<value>draft</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:extrusion-rotation-angle">
+					<list>
+						<ref name="angle"/>
+						<ref name="angle"/>
+					</list>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:extrusion-rotation-center">
+					<ref name="vector3D"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:extrusion-shininess">
+					<ref name="zeroToHundredPercent"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:extrusion-skew">
+					<list>
+						<ref name="double"/>
+						<ref name="angle"/>
+					</list>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:extrusion-specularity">
+					<ref name="zeroToHundredPercent"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="dr3d:projection">
+					<choice>
+						<value>parallel</value>
+						<value>perspective</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:extrusion-viewpoint">
+					<ref name="point3D"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:extrusion-origin">
+					<list>
+						<ref name="extrusionOrigin"/>
+						<ref name="extrusionOrigin"/>
+					</list>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:extrusion-color">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:enhanced-path">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:path-stretchpoint-x">
+					<ref name="double"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:path-stretchpoint-y">
+					<ref name="double"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:text-areas">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:glue-points">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:glue-point-type">
+					<choice>
+						<value>none</value>
+						<value>segments</value>
+						<value>rectangle</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:glue-point-leaving-directions">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:text-path">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:text-path-mode">
+					<choice>
+						<value>normal</value>
+						<value>path</value>
+						<value>shape</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:text-path-scale">
+					<choice>
+						<value>path</value>
+						<value>shape</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:text-path-same-letter-heights">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:modifiers">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="custom-shape-type">
+		<choice>
+			<value>non-primitive</value>
+			<ref name="string"/>
+		</choice>
+	</define>
+	<define name="point3D">
+		<data type="string">
+			<param name="pattern">\([ ]*-?([0-9]+(\.[0-9]*)?|\.[0-9]+)((cm)|(mm)|(in)|(pt)|(pc))([ ]+-?([0-9]+(\.[0-9]*)?|\.[0-9]+)((cm)|(mm)|(in)|(pt)|(pc))){2}[ ]*\)</param>
+		</data>
+	</define>
+	<define name="extrusionOrigin">
+		<data type="double">
+			<param name="minInclusive">-0.5</param>
+			<param name="maxInclusive">0.5</param>
+		</data>
+	</define>
+	<define name="draw-equation">
+		<element name="draw:equation">
+			<ref name="draw-equation-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="draw-equation-attlist">
+		<interleave>
+			<optional>
+				<attribute name="draw:name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:formula">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="draw-handle">
+		<element name="draw:handle">
+			<ref name="draw-handle-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="draw-handle-attlist">
+		<interleave>
+			<optional>
+				<attribute name="draw:handle-mirror-vertical">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:handle-mirror-horizontal">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:handle-switched">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<attribute name="draw:handle-position">
+				<ref name="string"/>
+			</attribute>
+			<optional>
+				<attribute name="draw:handle-range-x-minimum">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:handle-range-x-maximum">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:handle-range-y-minimum">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:handle-range-y-maximum">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:handle-polar">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:handle-radius-range-minimum">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:handle-radius-range-maximum">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="presentation-shape-attlist">
+		<interleave>
+			<optional>
+				<attribute name="presentation:class">
+					<ref name="presentation-classes"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:placeholder">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:user-transformed">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="presentation-classes">
+		<choice>
+			<value>title</value>
+			<value>outline</value>
+			<value>subtitle</value>
+			<value>text</value>
+			<value>graphic</value>
+			<value>object</value>
+			<value>chart</value>
+			<value>table</value>
+			<value>orgchart</value>
+			<value>page</value>
+			<value>notes</value>
+			<value>handout</value>
+			<value>header</value>
+			<value>footer</value>
+			<value>date-time</value>
+			<value>page-number</value>
+		</choice>
+	</define>
+	<define name="presentation-animations">
+		<element name="presentation:animations">
+			<zeroOrMore>
+				<choice>
+					<ref name="presentation-animation-elements"/>
+					<ref name="presentation-animation-group"/>
+				</choice>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="presentation-animation-elements">
+		<choice>
+			<ref name="presentation-show-shape"/>
+			<ref name="presentation-show-text"/>
+			<ref name="presentation-hide-shape"/>
+			<ref name="presentation-hide-text"/>
+			<ref name="presentation-dim"/>
+			<ref name="presentation-play"/>
+		</choice>
+	</define>
+	<define name="presentation-sound">
+		<element name="presentation:sound">
+			<ref name="presentation-sound-attlist"/>
+			<attribute name="xlink:type">
+				<value>simple</value>
+			</attribute>
+			<attribute name="xlink:href">
+				<ref name="anyIRI"/>
+			</attribute>
+			<optional>
+				<attribute name="xlink:actuate">
+					<value>onRequest</value>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="xlink:show">
+					<choice>
+						<value>new</value>
+						<value>replace</value>
+					</choice>
+				</attribute>
+			</optional>
+			<empty/>
+		</element>
+	</define>
+	<define name="presentation-sound-attlist">
+		<interleave>
+			<optional>
+				<attribute name="presentation:play-full">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<ref name="xml-id"/>
+			</optional>
+		</interleave>
+	</define>
+	<define name="presentation-show-shape">
+		<element name="presentation:show-shape">
+			<ref name="common-presentation-effect-attlist"/>
+			<optional>
+				<ref name="presentation-sound"/>
+			</optional>
+		</element>
+	</define>
+	<define name="common-presentation-effect-attlist">
+		<interleave>
+			<attribute name="draw:shape-id">
+				<ref name="IDREF"/>
+			</attribute>
+			<optional>
+				<attribute name="presentation:effect">
+					<ref name="presentationEffects"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:direction">
+					<ref name="presentationEffectDirections"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:speed">
+					<ref name="presentationSpeeds"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:delay">
+					<ref name="duration"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:start-scale">
+					<ref name="percent"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:path-id">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="presentationEffects">
+		<choice>
+			<value>none</value>
+			<value>fade</value>
+			<value>move</value>
+			<value>stripes</value>
+			<value>open</value>
+			<value>close</value>
+			<value>dissolve</value>
+			<value>wavyline</value>
+			<value>random</value>
+			<value>lines</value>
+			<value>laser</value>
+			<value>appear</value>
+			<value>hide</value>
+			<value>move-short</value>
+			<value>checkerboard</value>
+			<value>rotate</value>
+			<value>stretch</value>
+		</choice>
+	</define>
+	<define name="presentationEffectDirections">
+		<choice>
+			<value>none</value>
+			<value>from-left</value>
+			<value>from-top</value>
+			<value>from-right</value>
+			<value>from-bottom</value>
+			<value>from-center</value>
+			<value>from-upper-left</value>
+			<value>from-upper-right</value>
+			<value>from-lower-left</value>
+			<value>from-lower-right</value>
+			<value>to-left</value>
+			<value>to-top</value>
+			<value>to-right</value>
+			<value>to-bottom</value>
+			<value>to-upper-left</value>
+			<value>to-upper-right</value>
+			<value>to-lower-right</value>
+			<value>to-lower-left</value>
+			<value>path</value>
+			<value>spiral-inward-left</value>
+			<value>spiral-inward-right</value>
+			<value>spiral-outward-left</value>
+			<value>spiral-outward-right</value>
+			<value>vertical</value>
+			<value>horizontal</value>
+			<value>to-center</value>
+			<value>clockwise</value>
+			<value>counter-clockwise</value>
+		</choice>
+	</define>
+	<define name="presentationSpeeds">
+		<choice>
+			<value>slow</value>
+			<value>medium</value>
+			<value>fast</value>
+		</choice>
+	</define>
+	<define name="presentation-show-text">
+		<element name="presentation:show-text">
+			<ref name="common-presentation-effect-attlist"/>
+			<optional>
+				<ref name="presentation-sound"/>
+			</optional>
+		</element>
+	</define>
+	<define name="presentation-hide-shape">
+		<element name="presentation:hide-shape">
+			<ref name="common-presentation-effect-attlist"/>
+			<optional>
+				<ref name="presentation-sound"/>
+			</optional>
+		</element>
+	</define>
+	<define name="presentation-hide-text">
+		<element name="presentation:hide-text">
+			<ref name="common-presentation-effect-attlist"/>
+			<optional>
+				<ref name="presentation-sound"/>
+			</optional>
+		</element>
+	</define>
+	<define name="presentation-dim">
+		<element name="presentation:dim">
+			<ref name="presentation-dim-attlist"/>
+			<optional>
+				<ref name="presentation-sound"/>
+			</optional>
+		</element>
+	</define>
+	<define name="presentation-dim-attlist">
+		<interleave>
+			<attribute name="draw:shape-id">
+				<ref name="IDREF"/>
+			</attribute>
+			<attribute name="draw:color">
+				<ref name="color"/>
+			</attribute>
+		</interleave>
+	</define>
+	<define name="presentation-play">
+		<element name="presentation:play">
+			<ref name="presentation-play-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="presentation-play-attlist">
+		<attribute name="draw:shape-id">
+			<ref name="IDREF"/>
+		</attribute>
+		<optional>
+			<attribute name="presentation:speed">
+				<ref name="presentationSpeeds"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="presentation-animation-group">
+		<element name="presentation:animation-group">
+			<zeroOrMore>
+				<ref name="presentation-animation-elements"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="common-anim-attlist">
+		<interleave>
+			<optional>
+				<attribute name="presentation:node-type">
+					<choice>
+						<value>default</value>
+						<value>on-click</value>
+						<value>with-previous</value>
+						<value>after-previous</value>
+						<value>timing-root</value>
+						<value>main-sequence</value>
+						<value>interactive-sequence</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:preset-id">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:preset-sub-type">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:preset-class">
+					<choice>
+						<value>custom</value>
+						<value>entrance</value>
+						<value>exit</value>
+						<value>emphasis</value>
+						<value>motion-path</value>
+						<value>ole-action</value>
+						<value>media-call</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:master-element">
+					<ref name="IDREF"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:group-id">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<group>
+					<ref name="xml-id"/>
+					<optional>
+						<attribute name="anim:id">
+							<ref name="NCName"/>
+						</attribute>
+					</optional>
+				</group>
+			</optional>
+		</interleave>
+	</define>
+	<define name="presentation-event-listener">
+		<element name="presentation:event-listener">
+			<ref name="presentation-event-listener-attlist"/>
+			<optional>
+				<ref name="presentation-sound"/>
+			</optional>
+		</element>
+	</define>
+	<define name="presentation-event-listener-attlist">
+		<interleave>
+			<attribute name="script:event-name">
+				<ref name="string"/>
+			</attribute>
+			<attribute name="presentation:action">
+				<choice>
+					<value>none</value>
+					<value>previous-page</value>
+					<value>next-page</value>
+					<value>first-page</value>
+					<value>last-page</value>
+					<value>hide</value>
+					<value>stop</value>
+					<value>execute</value>
+					<value>show</value>
+					<value>verb</value>
+					<value>fade-out</value>
+					<value>sound</value>
+					<value>last-visited-page</value>
+				</choice>
+			</attribute>
+			<optional>
+				<attribute name="presentation:effect">
+					<ref name="presentationEffects"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:direction">
+					<ref name="presentationEffectDirections"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:speed">
+					<ref name="presentationSpeeds"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:start-scale">
+					<ref name="percent"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="xlink:type">
+					<value>simple</value>
+				</attribute>
+				<attribute name="xlink:href">
+					<ref name="anyIRI"/>
+				</attribute>
+				<optional>
+					<attribute name="xlink:show">
+						<value>embed</value>
+					</attribute>
+				</optional>
+				<optional>
+					<attribute name="xlink:actuate">
+						<value>onRequest</value>
+					</attribute>
+				</optional>
+			</optional>
+			<optional>
+				<attribute name="presentation:verb">
+					<ref name="nonNegativeInteger"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="presentation-decls">
+		<zeroOrMore>
+			<ref name="presentation-decl"/>
+		</zeroOrMore>
+	</define>
+	<define name="presentation-decl">
+		<choice>
+			<element name="presentation:header-decl">
+				<ref name="presentation-header-decl-attlist"/>
+				<text/>
+			</element>
+			<element name="presentation:footer-decl">
+				<ref name="presentation-footer-decl-attlist"/>
+				<text/>
+			</element>
+			<element name="presentation:date-time-decl">
+				<ref name="presentation-date-time-decl-attlist"/>
+				<text/>
+			</element>
+		</choice>
+	</define>
+	<define name="presentation-header-decl-attlist">
+		<attribute name="presentation:name">
+			<ref name="string"/>
+		</attribute>
+	</define>
+	<define name="presentation-footer-decl-attlist">
+		<attribute name="presentation:name">
+			<ref name="string"/>
+		</attribute>
+	</define>
+	<define name="presentation-date-time-decl-attlist">
+		<interleave>
+			<attribute name="presentation:name">
+				<ref name="string"/>
+			</attribute>
+			<attribute name="presentation:source">
+				<choice>
+					<value>fixed</value>
+					<value>current-date</value>
+				</choice>
+			</attribute>
+			<optional>
+				<attribute name="style:data-style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="presentation-settings">
+		<optional>
+			<element name="presentation:settings">
+				<ref name="presentation-settings-attlist"/>
+				<zeroOrMore>
+					<ref name="presentation-show"/>
+				</zeroOrMore>
+			</element>
+		</optional>
+	</define>
+	<define name="presentation-settings-attlist">
+		<interleave>
+			<optional>
+				<attribute name="presentation:start-page">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:show">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:full-screen">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:endless">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:pause">
+					<ref name="duration"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:show-logo">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:force-manual">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:mouse-visible">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:mouse-as-pen">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:start-with-navigator">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:animations">
+					<choice>
+						<value>enabled</value>
+						<value>disabled</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:transition-on-click">
+					<choice>
+						<value>enabled</value>
+						<value>disabled</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:stay-on-top">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:show-end-of-presentation-slide">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="presentation-show">
+		<element name="presentation:show">
+			<ref name="presentation-show-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="presentation-show-attlist">
+		<interleave>
+			<attribute name="presentation:name">
+				<ref name="string"/>
+			</attribute>
+			<attribute name="presentation:pages">
+				<ref name="string"/>
+			</attribute>
+		</interleave>
+	</define>
+	<define name="chart-chart">
+		<element name="chart:chart">
+			<ref name="chart-chart-attlist"/>
+			<optional>
+				<ref name="chart-title"/>
+			</optional>
+			<optional>
+				<ref name="chart-subtitle"/>
+			</optional>
+			<optional>
+				<ref name="chart-footer"/>
+			</optional>
+			<optional>
+				<ref name="chart-legend"/>
+			</optional>
+			<ref name="chart-plot-area"/>
+			<optional>
+				<ref name="table-table"/>
+			</optional>
+		</element>
+	</define>
+	<define name="chart-chart-attlist">
+		<interleave>
+			<attribute name="chart:class">
+				<ref name="namespacedToken"/>
+			</attribute>
+			<ref name="common-draw-size-attlist"/>
+			<optional>
+				<attribute name="chart:column-mapping">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:row-mapping">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<group>
+					<attribute name="xlink:type">
+						<value>simple</value>
+					</attribute>
+					<attribute name="xlink:href">
+						<ref name="anyIRI"/>
+					</attribute>
+				</group>
+			</optional>
+			<optional>
+				<ref name="xml-id"/>
+			</optional>
+		</interleave>
+	</define>
+	<define name="chart-title">
+		<element name="chart:title">
+			<ref name="chart-title-attlist"/>
+			<optional>
+				<ref name="text-p"/>
+			</optional>
+		</element>
+	</define>
+	<define name="chart-title-attlist">
+		<interleave>
+			<optional>
+				<attribute name="table:cell-range">
+					<ref name="cellRangeAddressList"/>
+				</attribute>
+			</optional>
+			<ref name="common-draw-position-attlist"/>
+			<optional>
+				<attribute name="chart:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="chart-subtitle">
+		<element name="chart:subtitle">
+			<ref name="chart-title-attlist"/>
+			<optional>
+				<ref name="text-p"/>
+			</optional>
+		</element>
+	</define>
+	<define name="chart-footer">
+		<element name="chart:footer">
+			<ref name="chart-title-attlist"/>
+			<optional>
+				<ref name="text-p"/>
+			</optional>
+		</element>
+	</define>
+	<define name="chart-legend">
+		<element name="chart:legend">
+			<ref name="chart-legend-attlist"/>
+			<optional>
+				<ref name="text-p"/>
+			</optional>
+		</element>
+	</define>
+	<define name="chart-legend-attlist">
+		<interleave>
+			<choice>
+				<group>
+					<attribute name="chart:legend-position">
+						<choice>
+							<value>start</value>
+							<value>end</value>
+							<value>top</value>
+							<value>bottom</value>
+						</choice>
+					</attribute>
+					<optional>
+						<attribute name="chart:legend-align">
+							<choice>
+								<value>start</value>
+								<value>center</value>
+								<value>end</value>
+							</choice>
+						</attribute>
+					</optional>
+				</group>
+				<attribute name="chart:legend-position">
+					<choice>
+						<value>top-start</value>
+						<value>bottom-start</value>
+						<value>top-end</value>
+						<value>bottom-end</value>
+					</choice>
+				</attribute>
+				<empty/>
+			</choice>
+			<ref name="common-draw-position-attlist"/>
+			<choice>
+				<attribute name="style:legend-expansion">
+					<choice>
+						<value>wide</value>
+						<value>high</value>
+						<value>balanced</value>
+					</choice>
+				</attribute>
+				<group>
+					<attribute name="style:legend-expansion">
+						<value>custom</value>
+					</attribute>
+					<attribute name="style:legend-expansion-aspect-ratio">
+						<ref name="double"/>
+					</attribute>
+				</group>
+				<empty/>
+			</choice>
+			<optional>
+				<attribute name="chart:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="chart-plot-area">
+		<element name="chart:plot-area">
+			<ref name="chart-plot-area-attlist"/>
+			<zeroOrMore>
+				<ref name="dr3d-light"/>
+			</zeroOrMore>
+			<zeroOrMore>
+				<ref name="chart-axis"/>
+			</zeroOrMore>
+			<zeroOrMore>
+				<ref name="chart-series"/>
+			</zeroOrMore>
+			<optional>
+				<ref name="chart-stock-gain-marker"/>
+			</optional>
+			<optional>
+				<ref name="chart-stock-loss-marker"/>
+			</optional>
+			<optional>
+				<ref name="chart-stock-range-line"/>
+			</optional>
+			<optional>
+				<ref name="chart-wall"/>
+			</optional>
+			<optional>
+				<ref name="chart-floor"/>
+			</optional>
+		</element>
+	</define>
+	<define name="chart-plot-area-attlist">
+		<interleave>
+			<ref name="common-draw-position-attlist"/>
+			<ref name="common-draw-size-attlist"/>
+			<optional>
+				<attribute name="chart:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:cell-range-address">
+					<ref name="cellRangeAddressList"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:data-source-has-labels">
+					<choice>
+						<value>none</value>
+						<value>row</value>
+						<value>column</value>
+						<value>both</value>
+					</choice>
+				</attribute>
+			</optional>
+			<ref name="dr3d-scene-attlist"/>
+			<ref name="common-dr3d-transform-attlist"/>
+			<optional>
+				<ref name="xml-id"/>
+			</optional>
+		</interleave>
+	</define>
+	<define name="chart-wall">
+		<element name="chart:wall">
+			<ref name="chart-wall-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="chart-wall-attlist">
+		<interleave>
+			<optional>
+				<attribute name="svg:width">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="chart-floor">
+		<element name="chart:floor">
+			<ref name="chart-floor-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="chart-floor-attlist">
+		<interleave>
+			<optional>
+				<attribute name="svg:width">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="chart-axis">
+		<element name="chart:axis">
+			<ref name="chart-axis-attlist"/>
+			<optional>
+				<ref name="chart-title"/>
+			</optional>
+			<optional>
+				<ref name="chart-categories"/>
+			</optional>
+			<zeroOrMore>
+				<ref name="chart-grid"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="chart-axis-attlist">
+		<interleave>
+			<attribute name="chart:dimension">
+				<ref name="chart-dimension"/>
+			</attribute>
+			<optional>
+				<attribute name="chart:name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="chart-dimension">
+		<choice>
+			<value>x</value>
+			<value>y</value>
+			<value>z</value>
+		</choice>
+	</define>
+	<define name="chart-categories">
+		<element name="chart:categories">
+			<optional>
+				<attribute name="table:cell-range-address">
+					<ref name="cellRangeAddressList"/>
+				</attribute>
+			</optional>
+		</element>
+	</define>
+	<define name="chart-grid">
+		<element name="chart:grid">
+			<ref name="chart-grid-attlist"/>
+		</element>
+	</define>
+	<define name="chart-grid-attlist">
+		<interleave>
+			<optional>
+				<attribute name="chart:class">
+					<choice>
+						<value>major</value>
+						<value>minor</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="chart-series">
+		<element name="chart:series">
+			<ref name="chart-series-attlist"/>
+			<zeroOrMore>
+				<ref name="chart-domain"/>
+			</zeroOrMore>
+			<optional>
+				<ref name="chart-mean-value"/>
+			</optional>
+			<zeroOrMore>
+				<ref name="chart-regression-curve"/>
+			</zeroOrMore>
+			<zeroOrMore>
+				<ref name="chart-error-indicator"/>
+			</zeroOrMore>
+			<zeroOrMore>
+				<ref name="chart-data-point"/>
+			</zeroOrMore>
+			<optional>
+				<ref name="chart-data-label"/>
+			</optional>
+		</element>
+	</define>
+	<define name="chart-series-attlist">
+		<interleave>
+			<optional>
+				<attribute name="chart:values-cell-range-address">
+					<ref name="cellRangeAddressList"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:label-cell-address">
+					<ref name="cellRangeAddressList"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:class">
+					<ref name="namespacedToken"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:attached-axis">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<ref name="xml-id"/>
+			</optional>
+		</interleave>
+	</define>
+	<define name="chart-domain">
+		<element name="chart:domain">
+			<optional>
+				<attribute name="table:cell-range-address">
+					<ref name="cellRangeAddressList"/>
+				</attribute>
+			</optional>
+		</element>
+	</define>
+	<define name="chart-data-point">
+		<element name="chart:data-point">
+			<ref name="chart-data-point-attlist"/>
+			<optional>
+				<ref name="chart-data-label"/>
+			</optional>
+		</element>
+	</define>
+	<define name="chart-data-point-attlist">
+		<interleave>
+			<optional>
+				<attribute name="chart:repeated">
+					<ref name="positiveInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<ref name="xml-id"/>
+			</optional>
+		</interleave>
+	</define>
+	<define name="chart-data-label">
+		<element name="chart:data-label">
+			<ref name="chart-data-label-attlist"/>
+			<optional>
+				<ref name="text-p"/>
+			</optional>
+		</element>
+	</define>
+	<define name="chart-data-label-attlist">
+		<interleave>
+			<ref name="common-draw-position-attlist"/>
+			<optional>
+				<attribute name="chart:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="chart-mean-value">
+		<element name="chart:mean-value">
+			<ref name="chart-mean-value-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="chart-mean-value-attlist">
+		<optional>
+			<attribute name="chart:style-name">
+				<ref name="styleNameRef"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="chart-error-indicator">
+		<element name="chart:error-indicator">
+			<ref name="chart-error-indicator-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="chart-error-indicator-attlist">
+		<interleave>
+			<optional>
+				<attribute name="chart:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<attribute name="chart:dimension">
+				<ref name="chart-dimension"/>
+			</attribute>
+		</interleave>
+	</define>
+	<define name="chart-regression-curve">
+		<element name="chart:regression-curve">
+			<ref name="chart-regression-curve-attlist"/>
+			<optional>
+				<ref name="chart-equation"/>
+			</optional>
+		</element>
+	</define>
+	<define name="chart-regression-curve-attlist">
+		<optional>
+			<attribute name="chart:style-name">
+				<ref name="styleNameRef"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="chart-equation">
+		<element name="chart:equation">
+			<ref name="chart-equation-attlist"/>
+			<optional>
+				<ref name="text-p"/>
+			</optional>
+		</element>
+	</define>
+	<define name="chart-equation-attlist">
+		<interleave>
+			<optional>
+				<attribute name="chart:automatic-content">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:display-r-square">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:display-equation">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<ref name="common-draw-position-attlist"/>
+			<optional>
+				<attribute name="chart:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="chart-stock-gain-marker">
+		<element name="chart:stock-gain-marker">
+			<ref name="common-stock-marker-attlist"/>
+		</element>
+	</define>
+	<define name="chart-stock-loss-marker">
+		<element name="chart:stock-loss-marker">
+			<ref name="common-stock-marker-attlist"/>
+		</element>
+	</define>
+	<define name="chart-stock-range-line">
+		<element name="chart:stock-range-line">
+			<ref name="common-stock-marker-attlist"/>
+		</element>
+	</define>
+	<define name="common-stock-marker-attlist">
+		<optional>
+			<attribute name="chart:style-name">
+				<ref name="styleNameRef"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="office-database">
+		<element name="office:database">
+			<ref name="db-data-source"/>
+			<optional>
+				<ref name="db-forms"/>
+			</optional>
+			<optional>
+				<ref name="db-reports"/>
+			</optional>
+			<optional>
+				<ref name="db-queries"/>
+			</optional>
+			<optional>
+				<ref name="db-table-presentations"/>
+			</optional>
+			<optional>
+				<ref name="db-schema-definition"/>
+			</optional>
+		</element>
+	</define>
+	<define name="db-data-source">
+		<element name="db:data-source">
+			<ref name="db-data-source-attlist"/>
+			<ref name="db-connection-data"/>
+			<optional>
+				<ref name="db-driver-settings"/>
+			</optional>
+			<optional>
+				<ref name="db-application-connection-settings"/>
+			</optional>
+		</element>
+	</define>
+	<define name="db-data-source-attlist">
+		<empty/>
+	</define>
+	<define name="db-connection-data">
+		<element name="db:connection-data">
+			<ref name="db-connection-data-attlist"/>
+			<choice>
+				<ref name="db-database-description"/>
+				<ref name="db-connection-resource"/>
+			</choice>
+			<optional>
+				<ref name="db-login"/>
+			</optional>
+		</element>
+	</define>
+	<define name="db-connection-data-attlist">
+		<empty/>
+	</define>
+	<define name="db-database-description">
+		<element name="db:database-description">
+			<ref name="db-database-description-attlist"/>
+			<choice>
+				<ref name="db-file-based-database"/>
+				<ref name="db-server-database"/>
+			</choice>
+		</element>
+	</define>
+	<define name="db-database-description-attlist">
+		<empty/>
+	</define>
+	<define name="db-file-based-database">
+		<element name="db:file-based-database">
+			<ref name="db-file-based-database-attlist"/>
+		</element>
+	</define>
+	<define name="db-file-based-database-attlist">
+		<interleave>
+			<attribute name="xlink:type">
+				<value>simple</value>
+			</attribute>
+			<attribute name="xlink:href">
+				<ref name="anyIRI"/>
+			</attribute>
+			<attribute name="db:media-type">
+				<ref name="string"/>
+			</attribute>
+			<optional>
+				<attribute name="db:extension">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="db-server-database">
+		<element name="db:server-database">
+			<ref name="db-server-database-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="db-server-database-attlist">
+		<interleave>
+			<attribute name="db:type">
+				<ref name="namespacedToken"/>
+			</attribute>
+			<choice>
+				<ref name="db-host-and-port"/>
+				<ref name="db-local-socket-name"/>
+			</choice>
+			<optional>
+				<attribute name="db:database-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="db-host-and-port">
+		<attribute name="db:hostname">
+			<ref name="string"/>
+		</attribute>
+		<optional>
+			<attribute name="db:port">
+				<ref name="positiveInteger"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="db-local-socket-name">
+		<optional>
+			<attribute name="db:local-socket">
+				<ref name="string"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="db-connection-resource">
+		<element name="db:connection-resource">
+			<ref name="db-connection-resource-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="db-connection-resource-attlist">
+		<attribute name="xlink:type">
+			<value>simple</value>
+		</attribute>
+		<attribute name="xlink:href">
+			<ref name="anyIRI"/>
+		</attribute>
+		<optional>
+			<attribute name="xlink:show">
+				<value>none</value>
+			</attribute>
+		</optional>
+		<optional>
+			<attribute name="xlink:actuate">
+				<value>onRequest</value>
+			</attribute>
+		</optional>
+	</define>
+	<define name="db-login">
+		<element name="db:login">
+			<ref name="db-login-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="db-login-attlist">
+		<interleave>
+			<optional>
+				<choice>
+					<attribute name="db:user-name">
+						<ref name="string"/>
+					</attribute>
+					<attribute name="db:use-system-user">
+						<ref name="boolean"/>
+					</attribute>
+				</choice>
+			</optional>
+			<optional>
+				<attribute name="db:is-password-required">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="db:login-timeout">
+					<ref name="positiveInteger"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="db-driver-settings">
+		<element name="db:driver-settings">
+			<ref name="db-driver-settings-attlist"/>
+			<optional>
+				<ref name="db-auto-increment"/>
+			</optional>
+			<optional>
+				<ref name="db-delimiter"/>
+			</optional>
+			<optional>
+				<ref name="db-character-set"/>
+			</optional>
+			<optional>
+				<ref name="db-table-settings"/>
+			</optional>
+		</element>
+	</define>
+	<define name="db-driver-settings-attlist">
+		<interleave>
+			<ref name="db-show-deleted"/>
+			<optional>
+				<attribute name="db:system-driver-settings">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="db:base-dn">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<ref name="db-is-first-row-header-line"/>
+			<optional>
+				<attribute name="db:parameter-name-substitution">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="db-show-deleted">
+		<optional>
+			<attribute name="db:show-deleted">
+				<ref name="boolean"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="db-is-first-row-header-line">
+		<optional>
+			<attribute name="db:is-first-row-header-line">
+				<ref name="boolean"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="db-auto-increment">
+		<element name="db:auto-increment">
+			<ref name="db-auto-increment-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="db-auto-increment-attlist">
+		<interleave>
+			<optional>
+				<attribute name="db:additional-column-statement">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="db:row-retrieving-statement">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="db-delimiter">
+		<element name="db:delimiter">
+			<ref name="db-delimiter-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="db-delimiter-attlist">
+		<interleave>
+			<optional>
+				<attribute name="db:field">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="db:string">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="db:decimal">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="db:thousand">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="db-character-set">
+		<element name="db:character-set">
+			<ref name="db-character-set-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="db-character-set-attlist">
+		<optional>
+			<attribute name="db:encoding">
+				<ref name="textEncoding"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="db-table-settings">
+		<element name="db:table-settings">
+			<zeroOrMore>
+				<ref name="db-table-setting"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="db-table-setting">
+		<element name="db:table-setting">
+			<ref name="db-table-setting-attlist"/>
+			<optional>
+				<ref name="db-delimiter"/>
+			</optional>
+			<optional>
+				<ref name="db-character-set"/>
+			</optional>
+			<empty/>
+		</element>
+	</define>
+	<define name="db-table-setting-attlist">
+		<ref name="db-is-first-row-header-line"/>
+		<ref name="db-show-deleted"/>
+	</define>
+	<define name="db-application-connection-settings">
+		<element name="db:application-connection-settings">
+			<ref name="db-application-connection-settings-attlist"/>
+			<optional>
+				<ref name="db-table-filter"/>
+			</optional>
+			<optional>
+				<ref name="db-table-type-filter"/>
+			</optional>
+			<optional>
+				<ref name="db-data-source-settings"/>
+			</optional>
+		</element>
+	</define>
+	<define name="db-application-connection-settings-attlist">
+		<interleave>
+			<optional>
+				<attribute name="db:is-table-name-length-limited">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="db:enable-sql92-check">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="db:append-table-alias-name">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="db:ignore-driver-privileges">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="db:boolean-comparison-mode">
+					<choice>
+						<value>equal-integer</value>
+						<value>is-boolean</value>
+						<value>equal-boolean</value>
+						<value>equal-use-only-zero</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="db:use-catalog">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="db:max-row-count">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="db:suppress-version-columns">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="db-table-filter">
+		<element name="db:table-filter">
+			<ref name="db-table-filter-attlist"/>
+			<optional>
+				<ref name="db-table-include-filter"/>
+			</optional>
+			<optional>
+				<ref name="db-table-exclude-filter"/>
+			</optional>
+		</element>
+	</define>
+	<define name="db-table-filter-attlist">
+		<empty/>
+	</define>
+	<define name="db-table-include-filter">
+		<element name="db:table-include-filter">
+			<ref name="db-table-include-filter-attlist"/>
+			<oneOrMore>
+				<ref name="db-table-filter-pattern"/>
+			</oneOrMore>
+		</element>
+	</define>
+	<define name="db-table-include-filter-attlist">
+		<empty/>
+	</define>
+	<define name="db-table-exclude-filter">
+		<element name="db:table-exclude-filter">
+			<ref name="db-table-exclude-filter-attlist"/>
+			<oneOrMore>
+				<ref name="db-table-filter-pattern"/>
+			</oneOrMore>
+		</element>
+	</define>
+	<define name="db-table-exclude-filter-attlist">
+		<empty/>
+	</define>
+	<define name="db-table-filter-pattern">
+		<element name="db:table-filter-pattern">
+			<ref name="db-table-filter-pattern-attlist"/>
+			<ref name="string"/>
+		</element>
+	</define>
+	<define name="db-table-filter-pattern-attlist">
+		<empty/>
+	</define>
+	<define name="db-table-type-filter">
+		<element name="db:table-type-filter">
+			<ref name="db-table-type-filter-attlist"/>
+			<zeroOrMore>
+				<ref name="db-table-type"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="db-table-type-filter-attlist">
+		<empty/>
+	</define>
+	<define name="db-table-type">
+		<element name="db:table-type">
+			<ref name="db-table-type-attlist"/>
+			<ref name="string"/>
+		</element>
+	</define>
+	<define name="db-table-type-attlist">
+		<empty/>
+	</define>
+	<define name="db-data-source-settings">
+		<element name="db:data-source-settings">
+			<ref name="db-data-source-settings-attlist"/>
+			<oneOrMore>
+				<ref name="db-data-source-setting"/>
+			</oneOrMore>
+		</element>
+	</define>
+	<define name="db-data-source-settings-attlist">
+		<empty/>
+	</define>
+	<define name="db-data-source-setting">
+		<element name="db:data-source-setting">
+			<ref name="db-data-source-setting-attlist"/>
+			<oneOrMore>
+				<ref name="db-data-source-setting-value"/>
+			</oneOrMore>
+		</element>
+	</define>
+	<define name="db-data-source-setting-attlist">
+		<interleave>
+			<optional>
+				<attribute name="db:data-source-setting-is-list">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<attribute name="db:data-source-setting-name">
+				<ref name="string"/>
+			</attribute>
+			<attribute name="db:data-source-setting-type">
+				<ref name="db-data-source-setting-types"/>
+			</attribute>
+		</interleave>
+	</define>
+	<define name="db-data-source-setting-types">
+		<choice>
+			<value>boolean</value>
+			<value>short</value>
+			<value>int</value>
+			<value>long</value>
+			<value>double</value>
+			<value>string</value>
+		</choice>
+	</define>
+	<define name="db-data-source-setting-value">
+		<element name="db:data-source-setting-value">
+			<ref name="db-data-source-setting-value-attlist"/>
+			<ref name="string"/>
+		</element>
+	</define>
+	<define name="db-data-source-setting-value-attlist">
+		<empty/>
+	</define>
+	<define name="db-forms">
+		<element name="db:forms">
+			<ref name="db-forms-attlist"/>
+			<zeroOrMore>
+				<choice>
+					<ref name="db-component"/>
+					<ref name="db-component-collection"/>
+				</choice>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="db-forms-attlist">
+		<empty/>
+	</define>
+	<define name="db-reports">
+		<element name="db:reports">
+			<ref name="db-reports-attlist"/>
+			<zeroOrMore>
+				<choice>
+					<ref name="db-component"/>
+					<ref name="db-component-collection"/>
+				</choice>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="db-reports-attlist">
+		<empty/>
+	</define>
+	<define name="db-component-collection">
+		<element name="db:component-collection">
+			<ref name="db-component-collection-attlist"/>
+			<ref name="common-db-object-name"/>
+			<ref name="common-db-object-title"/>
+			<ref name="common-db-object-description"/>
+			<zeroOrMore>
+				<choice>
+					<ref name="db-component"/>
+					<ref name="db-component-collection"/>
+				</choice>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="db-component-collection-attlist">
+		<empty/>
+	</define>
+	<define name="db-component">
+		<element name="db:component">
+			<ref name="db-component-attlist"/>
+			<ref name="common-db-object-name"/>
+			<ref name="common-db-object-title"/>
+			<ref name="common-db-object-description"/>
+			<optional>
+				<choice>
+					<ref name="office-document"/>
+					<ref name="math-math"/>
+				</choice>
+			</optional>
+		</element>
+	</define>
+	<define name="db-component-attlist">
+		<interleave>
+			<optional>
+				<attribute name="xlink:type">
+					<value>simple</value>
+				</attribute>
+				<attribute name="xlink:href">
+					<ref name="anyIRI"/>
+				</attribute>
+				<optional>
+					<attribute name="xlink:show">
+						<value>none</value>
+					</attribute>
+				</optional>
+				<optional>
+					<attribute name="xlink:actuate">
+						<value>onRequest</value>
+					</attribute>
+				</optional>
+			</optional>
+			<optional>
+				<attribute name="db:as-template">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="db-queries">
+		<element name="db:queries">
+			<ref name="db-queries-attlist"/>
+			<zeroOrMore>
+				<choice>
+					<ref name="db-query"/>
+					<ref name="db-query-collection"/>
+				</choice>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="db-queries-attlist">
+		<empty/>
+	</define>
+	<define name="db-query-collection">
+		<element name="db:query-collection">
+			<ref name="db-query-collection-attlist"/>
+			<ref name="common-db-object-name"/>
+			<ref name="common-db-object-title"/>
+			<ref name="common-db-object-description"/>
+			<zeroOrMore>
+				<choice>
+					<ref name="db-query"/>
+					<ref name="db-query-collection"/>
+				</choice>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="db-query-collection-attlist">
+		<empty/>
+	</define>
+	<define name="db-query">
+		<element name="db:query">
+			<ref name="db-query-attlist"/>
+			<ref name="common-db-object-name"/>
+			<ref name="common-db-object-title"/>
+			<ref name="common-db-object-description"/>
+			<ref name="common-db-table-style-name"/>
+			<optional>
+				<ref name="db-order-statement"/>
+			</optional>
+			<optional>
+				<ref name="db-filter-statement"/>
+			</optional>
+			<optional>
+				<ref name="db-columns"/>
+			</optional>
+			<optional>
+				<ref name="db-update-table"/>
+			</optional>
+		</element>
+	</define>
+	<define name="db-query-attlist">
+		<interleave>
+			<attribute name="db:command">
+				<ref name="string"/>
+			</attribute>
+			<optional>
+				<attribute name="db:escape-processing">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="db-order-statement">
+		<element name="db:order-statement">
+			<ref name="db-command"/>
+			<ref name="db-apply-command"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="db-filter-statement">
+		<element name="db:filter-statement">
+			<ref name="db-command"/>
+			<ref name="db-apply-command"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="db-update-table">
+		<element name="db:update-table">
+			<ref name="common-db-table-name-attlist"/>
+		</element>
+	</define>
+	<define name="db-table-presentations">
+		<element name="db:table-representations">
+			<ref name="db-table-presentations-attlist"/>
+			<zeroOrMore>
+				<ref name="db-table-presentation"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="db-table-presentations-attlist">
+		<empty/>
+	</define>
+	<define name="db-table-presentation">
+		<element name="db:table-representation">
+			<ref name="db-table-presentation-attlist"/>
+			<ref name="common-db-table-name-attlist"/>
+			<ref name="common-db-object-title"/>
+			<ref name="common-db-object-description"/>
+			<ref name="common-db-table-style-name"/>
+			<optional>
+				<ref name="db-order-statement"/>
+			</optional>
+			<optional>
+				<ref name="db-filter-statement"/>
+			</optional>
+			<optional>
+				<ref name="db-columns"/>
+			</optional>
+		</element>
+	</define>
+	<define name="db-table-presentation-attlist">
+		<empty/>
+	</define>
+	<define name="db-columns">
+		<element name="db:columns">
+			<ref name="db-columns-attlist"/>
+			<oneOrMore>
+				<ref name="db-column"/>
+			</oneOrMore>
+		</element>
+	</define>
+	<define name="db-columns-attlist">
+		<empty/>
+	</define>
+	<define name="db-column">
+		<element name="db:column">
+			<ref name="db-column-attlist"/>
+			<ref name="common-db-object-name"/>
+			<ref name="common-db-object-title"/>
+			<ref name="common-db-object-description"/>
+			<ref name="common-db-default-value"/>
+		</element>
+	</define>
+	<define name="db-column-attlist">
+		<interleave>
+			<optional>
+				<attribute name="db:visible">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+	
+			<optional>
+				<attribute name="db:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="db:default-cell-style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="db-command">
+		<attribute name="db:command">
+			<ref name="string"/>
+		</attribute>
+	</define>
+	<define name="db-apply-command">
+		<optional>
+			<attribute name="db:apply-command">
+				<ref name="boolean"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-db-table-name-attlist">
+		<interleave>
+			<attribute name="db:name">
+				<ref name="string"/>
+			</attribute>
+			<optional>
+				<attribute name="db:catalog-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="db:schema-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="common-db-object-name">
+		<attribute name="db:name">
+			<ref name="string"/>
+		</attribute>
+	</define>
+	<define name="common-db-object-title">
+		<optional>
+			<attribute name="db:title">
+				<ref name="string"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-db-object-description">
+		<optional>
+			<attribute name="db:description">
+				<ref name="string"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-db-table-style-name">
+		<interleave>
+			<optional>
+				<attribute name="db:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="db:default-row-style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="common-db-default-value">
+		<optional>
+			<ref name="common-value-and-type-attlist"/>
+		</optional>
+	</define>
+	<define name="db-schema-definition">
+		<element name="db:schema-definition">
+			<ref name="db-schema-definition-attlist"/>
+			<ref name="db-table-definitions"/>
+		</element>
+	</define>
+	<define name="db-schema-definition-attlist">
+		<empty/>
+	</define>
+	<define name="db-table-definitions">
+		<element name="db:table-definitions">
+			<ref name="db-table-definitions-attlist"/>
+			<zeroOrMore>
+				<ref name="db-table-definition"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="db-table-definitions-attlist">
+		<empty/>
+	</define>
+	<define name="db-table-definition">
+		<element name="db:table-definition">
+			<ref name="common-db-table-name-attlist"/>
+			<ref name="db-table-definition-attlist"/>
+			<ref name="db-column-definitions"/>
+			<optional>
+				<ref name="db-keys"/>
+			</optional>
+			<optional>
+				<ref name="db-indices"/>
+			</optional>
+		</element>
+	</define>
+	<define name="db-table-definition-attlist">
+		<optional>
+			<attribute name="db:type">
+				<ref name="string"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="db-column-definitions">
+		<element name="db:column-definitions">
+			<ref name="db-column-definitions-attlist"/>
+			<oneOrMore>
+				<ref name="db-column-definition"/>
+			</oneOrMore>
+		</element>
+	</define>
+	<define name="db-column-definitions-attlist">
+		<empty/>
+	</define>
+	<define name="db-column-definition">
+		<element name="db:column-definition">
+			<ref name="db-column-definition-attlist"/>
+			<ref name="common-db-default-value"/>
+		</element>
+	</define>
+	<define name="db-column-definition-attlist">
+		<interleave>
+			<attribute name="db:name">
+				<ref name="string"/>
+			</attribute>
+	
+			<optional>
+				<attribute name="db:data-type">
+					<ref name="db-data-types"/>
+				</attribute>
+			</optional>
+	
+			<optional>
+				<attribute name="db:type-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+	
+			<optional>
+				<attribute name="db:precision">
+					<ref name="positiveInteger"/>
+				</attribute>
+			</optional>
+	
+			<optional>
+				<attribute name="db:scale">
+					<ref name="positiveInteger"/>
+				</attribute>
+			</optional>
+	
+			<optional>
+				<attribute name="db:is-nullable">
+					<choice>
+						<value>no-nulls</value>
+						<value>nullable</value>
+					</choice>
+				</attribute>
+			</optional>
+	
+			<optional>
+				<attribute name="db:is-empty-allowed">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+	
+			<optional>
+				<attribute name="db:is-autoincrement">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="db-data-types">
+		<choice>
+			<value>bit</value>
+			<value>boolean</value>
+			<value>tinyint</value>
+			<value>smallint</value>
+			<value>integer</value>
+			<value>bigint</value>
+			<value>float</value>
+			<value>real</value>
+			<value>double</value>
+			<value>numeric</value>
+			<value>decimal</value>
+			<value>char</value>
+			<value>varchar</value>
+			<value>longvarchar</value>
+			<value>date</value>
+			<value>time</value>
+			<value>timestmp</value>
+			<value>binary</value>
+			<value>varbinary</value>
+			<value>longvarbinary</value>
+			<value>sqlnull</value>
+			<value>other</value>
+			<value>object</value>
+			<value>distinct</value>
+			<value>struct</value>
+			<value>array</value>
+			<value>blob</value>
+			<value>clob</value>
+			<value>ref</value>
+		</choice>
+	</define>
+	<define name="db-keys">
+		<element name="db:keys">
+			<ref name="db-keys-attlist"/>
+			<oneOrMore>
+				<ref name="db-key"/>
+			</oneOrMore>
+		</element>
+	</define>
+	<define name="db-keys-attlist">
+		<empty/>
+	</define>
+	<define name="db-key">
+		<element name="db:key">
+			<ref name="db-key-attlist"/>
+			<oneOrMore>
+				<ref name="db-key-columns"/>
+			</oneOrMore>
+		</element>
+	</define>
+	<define name="db-key-attlist">
+		<interleave>
+			<optional>
+				<attribute name="db:name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+	
+			<attribute name="db:type">
+				<choice>
+					<value>primary</value>
+					<value>unique</value>
+					<value>foreign</value>
+				</choice>
+			</attribute>
+	
+			<optional>
+				<attribute name="db:referenced-table-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+	
+			<optional>
+				<attribute name="db:update-rule">
+					<choice>
+						<value>cascade</value>
+						<value>restrict</value>
+						<value>set-null</value>
+						<value>no-action</value>
+						<value>set-default</value>
+					</choice>
+				</attribute>
+			</optional>
+	
+			<optional>
+				<attribute name="db:delete-rule">
+					<choice>
+						<value>cascade</value>
+						<value>restrict</value>
+						<value>set-null</value>
+						<value>no-action</value>
+						<value>set-default</value>
+					</choice>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="db-key-columns">
+		<element name="db:key-columns">
+			<ref name="db-key-columns-attlist"/>
+			<oneOrMore>
+				<ref name="db-key-column"/>
+			</oneOrMore>
+		</element>
+	</define>
+	<define name="db-key-columns-attlist">
+		<empty/>
+	</define>
+	<define name="db-key-column">
+		<element name="db:key-column">
+			<ref name="db-key-column-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="db-key-column-attlist">
+		<interleave>
+			<optional>
+				<attribute name="db:name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+	
+			<optional>
+				<attribute name="db:related-column-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="db-indices">
+		<element name="db:indices">
+			<ref name="db-indices-attlist"/>
+			<oneOrMore>
+				<ref name="db-index"/>
+			</oneOrMore>
+		</element>
+	</define>
+	<define name="db-indices-attlist">
+		<empty/>
+	</define>
+	<define name="db-index">
+		<element name="db:index">
+			<ref name="db-index-attlist"/>
+			<oneOrMore>
+				<ref name="db-index-columns"/>
+			</oneOrMore>
+		</element>
+	</define>
+	<define name="db-index-attlist">
+		<interleave>
+			<attribute name="db:name">
+				<ref name="string"/>
+			</attribute>
+	
+			<optional>
+				<attribute name="db:catalog-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+	
+			<optional>
+				<attribute name="db:is-unique">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+	
+			<optional>
+				<attribute name="db:is-clustered">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="db-index-columns">
+		<element name="db:index-columns">
+			<oneOrMore>
+				<ref name="db-index-column"/>
+			</oneOrMore>
+		</element>
+	</define>
+	<define name="db-index-column">
+		<element name="db:index-column">
+			<ref name="db-index-column-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="db-index-column-attlist">
+		<interleave>
+			<attribute name="db:name">
+				<ref name="string"/>
+			</attribute>
+	
+			<optional>
+				<attribute name="db:is-ascending">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="office-forms">
+		<optional>
+			<element name="office:forms">
+				<ref name="office-forms-attlist"/>
+				<zeroOrMore>
+					<choice>
+						<ref name="form-form"/>
+						<ref name="xforms-model"/>
+					</choice>
+				</zeroOrMore>
+			</element>
+		</optional>
+	</define>
+	<define name="office-forms-attlist">
+		<interleave>
+			<optional>
+				<attribute name="form:automatic-focus">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:apply-design-mode">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="form-form">
+		<element name="form:form">
+			<ref name="common-form-control-attlist"/>
+			<ref name="form-form-attlist"/>
+			<optional>
+				<ref name="form-properties"/>
+			</optional>
+			<optional>
+				<ref name="office-event-listeners"/>
+			</optional>
+			<zeroOrMore>
+				<choice>
+					<ref name="controls"/>
+					<ref name="form-form"/>
+				</choice>
+			</zeroOrMore>
+			<optional>
+				<ref name="form-connection-resource"/>
+			</optional>
+		</element>
+	</define>
+	<define name="form-form-attlist">
+		<interleave>
+			<optional>
+				<attribute name="xlink:type">
+					<value>simple</value>
+				</attribute>
+				<attribute name="xlink:href">
+					<ref name="anyIRI"/>
+				</attribute>
+				<optional>
+					<attribute name="xlink:actuate">
+						<value>onRequest</value>
+					</attribute>
+				</optional>
+			</optional>
+			<optional>
+				<attribute name="office:target-frame">
+					<ref name="targetFrameName"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:method">
+					<choice>
+						<value>get</value>
+						<value>post</value>
+						<ref name="string"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:enctype">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:allow-deletes">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:allow-inserts">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:allow-updates">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:apply-filter">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:command-type">
+					<choice>
+						<value>table</value>
+						<value>query</value>
+						<value>command</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:command">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:datasource">
+					<choice>
+						<ref name="anyIRI"/>
+						<ref name="string"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:master-fields">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:detail-fields">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:escape-processing">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:filter">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:ignore-result">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:navigation-mode">
+					<ref name="navigation"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:order">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:tab-cycle">
+					<ref name="tab-cycles"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="navigation">
+		<choice>
+			<value>none</value>
+			<value>current</value>
+			<value>parent</value>
+		</choice>
+	</define>
+	<define name="tab-cycles">
+		<choice>
+			<value>records</value>
+			<value>current</value>
+			<value>page</value>
+		</choice>
+	</define>
+	<define name="form-connection-resource">
+		<element name="form:connection-resource">
+			<attribute name="xlink:href">
+				<ref name="anyIRI"/>
+			</attribute>
+			<empty/>
+		</element>
+	</define>
+	<define name="xforms-model">
+		<element name="xforms:model">
+			<ref name="anyAttListOrElements"/>
+		</element>
+	</define>
+	<define name="column-controls">
+		<choice>
+			<element name="form:text">
+				<ref name="form-text-attlist"/>
+				<ref name="common-form-control-content"/>
+			</element>
+			<element name="form:textarea">
+				<ref name="form-textarea-attlist"/>
+				<ref name="common-form-control-content"/>
+				<zeroOrMore>
+					<ref name="text-p"/>
+				</zeroOrMore>
+			</element>
+			<element name="form:formatted-text">
+				<ref name="form-formatted-text-attlist"/>
+				<ref name="common-form-control-content"/>
+			</element>
+			<element name="form:number">
+				<ref name="form-number-attlist"/>
+				<ref name="common-numeric-control-attlist"/>
+				<ref name="common-form-control-content"/>
+				<ref name="common-linked-cell"/>
+				<ref name="common-spin-button"/>
+				<ref name="common-repeat"/>
+				<ref name="common-delay-for-repeat"/>
+			</element>
+			<element name="form:date">
+				<ref name="form-date-attlist"/>
+				<ref name="common-numeric-control-attlist"/>
+				<ref name="common-form-control-content"/>
+				<ref name="common-linked-cell"/>
+				<ref name="common-spin-button"/>
+				<ref name="common-repeat"/>
+				<ref name="common-delay-for-repeat"/>
+			</element>
+			<element name="form:time">
+				<ref name="form-time-attlist"/>
+				<ref name="common-numeric-control-attlist"/>
+				<ref name="common-form-control-content"/>
+				<ref name="common-linked-cell"/>
+				<ref name="common-spin-button"/>
+				<ref name="common-repeat"/>
+				<ref name="common-delay-for-repeat"/>
+			</element>
+			<element name="form:combobox">
+				<ref name="form-combobox-attlist"/>
+				<ref name="common-form-control-content"/>
+				<zeroOrMore>
+					<ref name="form-item"/>
+				</zeroOrMore>
+			</element>
+			<element name="form:listbox">
+				<ref name="form-listbox-attlist"/>
+				<ref name="common-form-control-content"/>
+				<zeroOrMore>
+					<ref name="form-option"/>
+				</zeroOrMore>
+			</element>
+			<element name="form:checkbox">
+				<ref name="form-checkbox-attlist"/>
+				<ref name="common-form-control-content"/>
+			</element>
+		</choice>
+	</define>
+	<define name="controls">
+		<choice>
+			<ref name="column-controls"/>
+			<element name="form:password">
+				<ref name="form-password-attlist"/>
+				<ref name="common-form-control-content"/>
+			</element>
+			<element name="form:file">
+				<ref name="form-file-attlist"/>
+				<ref name="common-form-control-content"/>
+			</element>
+			<element name="form:fixed-text">
+				<ref name="form-fixed-text-attlist"/>
+				<ref name="common-form-control-content"/>
+			</element>
+			<element name="form:button">
+				<ref name="form-button-attlist"/>
+				<ref name="common-form-control-content"/>
+			</element>
+			<element name="form:image">
+				<ref name="form-image-attlist"/>
+				<ref name="common-form-control-content"/>
+			</element>
+			<element name="form:radio">
+				<ref name="form-radio-attlist"/>
+				<ref name="common-form-control-content"/>
+			</element>
+			<element name="form:frame">
+				<ref name="form-frame-attlist"/>
+				<ref name="common-form-control-content"/>
+			</element>
+			<element name="form:image-frame">
+				<ref name="form-image-frame-attlist"/>
+				<ref name="common-form-control-content"/>
+			</element>
+			<element name="form:hidden">
+				<ref name="form-hidden-attlist"/>
+				<ref name="common-form-control-content"/>
+			</element>
+			<element name="form:grid">
+				<ref name="form-grid-attlist"/>
+				<ref name="common-form-control-content"/>
+				<zeroOrMore>
+					<ref name="form-column"/>
+				</zeroOrMore>
+			</element>
+			<element name="form:value-range">
+				<ref name="form-value-range-attlist"/>
+				<ref name="common-form-control-content"/>
+			</element>
+			<element name="form:generic-control">
+				<ref name="form-generic-control-attlist"/>
+				<ref name="common-form-control-content"/>
+			</element>
+		</choice>
+	</define>
+	<define name="form-text-attlist">
+		<ref name="form-control-attlist"/>
+		<ref name="common-current-value-attlist"/>
+		<ref name="common-disabled-attlist"/>
+		<ref name="common-maxlength-attlist"/>
+		<ref name="common-printable-attlist"/>
+		<ref name="common-readonly-attlist"/>
+		<ref name="common-tab-attlist"/>
+		<ref name="common-title-attlist"/>
+		<ref name="common-value-attlist"/>
+		<ref name="common-convert-empty-attlist"/>
+		<ref name="common-data-field-attlist"/>
+		<ref name="common-linked-cell"/>
+	</define>
+	<define name="form-control-attlist">
+		<ref name="common-form-control-attlist"/>
+		<ref name="common-control-id-attlist"/>
+		<ref name="xforms-bind-attlist"/>
+	</define>
+	<define name="common-form-control-content">
+		<optional>
+			<ref name="form-properties"/>
+		</optional>
+		<optional>
+			<ref name="office-event-listeners"/>
+		</optional>
+	</define>
+	<define name="form-textarea-attlist">
+		<ref name="form-control-attlist"/>
+		<ref name="common-current-value-attlist"/>
+		<ref name="common-disabled-attlist"/>
+		<ref name="common-maxlength-attlist"/>
+		<ref name="common-printable-attlist"/>
+		<ref name="common-readonly-attlist"/>
+		<ref name="common-tab-attlist"/>
+		<ref name="common-title-attlist"/>
+		<ref name="common-value-attlist"/>
+		<ref name="common-convert-empty-attlist"/>
+		<ref name="common-data-field-attlist"/>
+		<ref name="common-linked-cell"/>
+	</define>
+	<define name="form-password-attlist">
+		<interleave>
+			<ref name="form-control-attlist"/>
+			<ref name="common-disabled-attlist"/>
+			<ref name="common-maxlength-attlist"/>
+			<ref name="common-printable-attlist"/>
+			<ref name="common-tab-attlist"/>
+			<ref name="common-title-attlist"/>
+			<ref name="common-value-attlist"/>
+			<ref name="common-convert-empty-attlist"/>
+			<ref name="common-linked-cell"/>
+			<optional>
+				<attribute name="form:echo-char">
+					<ref name="character"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="form-file-attlist">
+		<ref name="form-control-attlist"/>
+		<ref name="common-current-value-attlist"/>
+		<ref name="common-disabled-attlist"/>
+		<ref name="common-maxlength-attlist"/>
+		<ref name="common-printable-attlist"/>
+		<ref name="common-readonly-attlist"/>
+		<ref name="common-tab-attlist"/>
+		<ref name="common-title-attlist"/>
+		<ref name="common-value-attlist"/>
+		<ref name="common-linked-cell"/>
+	</define>
+	<define name="form-formatted-text-attlist">
+		<interleave>
+			<ref name="form-control-attlist"/>
+			<ref name="common-current-value-attlist"/>
+			<ref name="common-disabled-attlist"/>
+			<ref name="common-maxlength-attlist"/>
+			<ref name="common-printable-attlist"/>
+			<ref name="common-readonly-attlist"/>
+			<ref name="common-tab-attlist"/>
+			<ref name="common-title-attlist"/>
+			<ref name="common-value-attlist"/>
+			<ref name="common-convert-empty-attlist"/>
+			<ref name="common-data-field-attlist"/>
+			<ref name="common-linked-cell"/>
+			<ref name="common-spin-button"/>
+			<ref name="common-repeat"/>
+			<ref name="common-delay-for-repeat"/>
+			<optional>
+				<attribute name="form:max-value">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:min-value">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:validation">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="common-numeric-control-attlist">
+		<ref name="form-control-attlist"/>
+		<ref name="common-disabled-attlist"/>
+		<ref name="common-maxlength-attlist"/>
+		<ref name="common-printable-attlist"/>
+		<ref name="common-readonly-attlist"/>
+		<ref name="common-tab-attlist"/>
+		<ref name="common-title-attlist"/>
+		<ref name="common-convert-empty-attlist"/>
+		<ref name="common-data-field-attlist"/>
+	</define>
+	<define name="form-number-attlist">
+		<interleave>
+			<optional>
+				<attribute name="form:value">
+					<ref name="double"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:current-value">
+					<ref name="double"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:min-value">
+					<ref name="double"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:max-value">
+					<ref name="double"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="form-date-attlist">
+		<interleave>
+			<optional>
+				<attribute name="form:value">
+					<ref name="date"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:current-value">
+					<ref name="date"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:min-value">
+					<ref name="date"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:max-value">
+					<ref name="date"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="form-time-attlist">
+		<interleave>
+			<optional>
+				<attribute name="form:value">
+					<ref name="time"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:current-value">
+					<ref name="time"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:min-value">
+					<ref name="time"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:max-value">
+					<ref name="time"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="form-fixed-text-attlist">
+		<interleave>
+			<ref name="form-control-attlist"/>
+			<ref name="for"/>
+			<ref name="common-disabled-attlist"/>
+			<ref name="label"/>
+			<ref name="common-printable-attlist"/>
+			<ref name="common-title-attlist"/>
+			<optional>
+				<attribute name="form:multi-line">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="form-combobox-attlist">
+		<interleave>
+			<ref name="form-control-attlist"/>
+			<ref name="common-current-value-attlist"/>
+			<ref name="common-disabled-attlist"/>
+			<ref name="dropdown"/>
+			<ref name="common-maxlength-attlist"/>
+			<ref name="common-printable-attlist"/>
+			<ref name="common-readonly-attlist"/>
+			<ref name="size"/>
+			<ref name="common-tab-attlist"/>
+			<ref name="common-title-attlist"/>
+			<ref name="common-value-attlist"/>
+			<ref name="common-convert-empty-attlist"/>
+			<ref name="common-data-field-attlist"/>
+			<ref name="list-source"/>
+			<ref name="list-source-type"/>
+			<ref name="common-linked-cell"/>
+			<ref name="common-source-cell-range"/>
+			<optional>
+				<attribute name="form:auto-complete">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="form-item">
+		<element name="form:item">
+			<ref name="form-item-attlist"/>
+			<text/>
+		</element>
+	</define>
+	<define name="form-item-attlist">
+		<ref name="label"/>
+	</define>
+	<define name="form-listbox-attlist">
+		<interleave>
+			<ref name="form-control-attlist"/>
+			<ref name="common-disabled-attlist"/>
+			<ref name="dropdown"/>
+			<ref name="common-printable-attlist"/>
+			<ref name="size"/>
+			<ref name="common-tab-attlist"/>
+			<ref name="common-title-attlist"/>
+			<ref name="bound-column"/>
+			<ref name="common-data-field-attlist"/>
+			<ref name="list-source"/>
+			<ref name="list-source-type"/>
+			<ref name="common-linked-cell"/>
+			<ref name="list-linkage-type"/>
+			<ref name="common-source-cell-range"/>
+			<optional>
+				<attribute name="form:multiple">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:xforms-list-source">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="list-linkage-type">
+		<optional>
+			<attribute name="form:list-linkage-type">
+				<choice>
+					<value>selection</value>
+					<value>selection-indices</value>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="form-option">
+		<element name="form:option">
+			<ref name="form-option-attlist"/>
+			<text/>
+		</element>
+	</define>
+	<define name="form-option-attlist">
+		<ref name="current-selected"/>
+		<ref name="selected"/>
+		<ref name="label"/>
+		<ref name="common-value-attlist"/>
+	</define>
+	<define name="form-button-attlist">
+		<interleave>
+			<ref name="form-control-attlist"/>
+			<ref name="button-type"/>
+			<ref name="common-disabled-attlist"/>
+			<ref name="label"/>
+			<ref name="image-data"/>
+			<ref name="common-printable-attlist"/>
+			<ref name="common-tab-attlist"/>
+			<ref name="target-frame"/>
+			<ref name="target-location"/>
+			<ref name="common-title-attlist"/>
+			<ref name="common-value-attlist"/>
+			<ref name="common-form-relative-image-position-attlist"/>
+			<ref name="common-repeat"/>
+			<ref name="common-delay-for-repeat"/>
+			<optional>
+				<attribute name="form:default-button">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:toggle">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:focus-on-click">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:xforms-submission">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="form-image-attlist">
+		<ref name="form-control-attlist"/>
+		<ref name="button-type"/>
+		<ref name="common-disabled-attlist"/>
+		<ref name="image-data"/>
+		<ref name="common-printable-attlist"/>
+		<ref name="common-tab-attlist"/>
+		<ref name="target-frame"/>
+		<ref name="target-location"/>
+		<ref name="common-title-attlist"/>
+		<ref name="common-value-attlist"/>
+	</define>
+	<define name="form-checkbox-attlist">
+		<interleave>
+			<ref name="form-control-attlist"/>
+			<ref name="common-disabled-attlist"/>
+			<ref name="label"/>
+			<ref name="common-printable-attlist"/>
+			<ref name="common-tab-attlist"/>
+			<ref name="common-title-attlist"/>
+			<ref name="common-value-attlist"/>
+			<ref name="common-data-field-attlist"/>
+			<ref name="common-form-visual-effect-attlist"/>
+			<ref name="common-form-relative-image-position-attlist"/>
+			<ref name="common-linked-cell"/>
+			<optional>
+				<attribute name="form:current-state">
+					<ref name="states"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:is-tristate">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:state">
+					<ref name="states"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="states">
+		<choice>
+			<value>unchecked</value>
+			<value>checked</value>
+			<value>unknown</value>
+		</choice>
+	</define>
+	<define name="form-radio-attlist">
+		<ref name="form-control-attlist"/>
+		<ref name="current-selected"/>
+		<ref name="common-disabled-attlist"/>
+		<ref name="label"/>
+		<ref name="common-printable-attlist"/>
+		<ref name="selected"/>
+		<ref name="common-tab-attlist"/>
+		<ref name="common-title-attlist"/>
+		<ref name="common-value-attlist"/>
+		<ref name="common-data-field-attlist"/>
+		<ref name="common-form-visual-effect-attlist"/>
+		<ref name="common-form-relative-image-position-attlist"/>
+		<ref name="common-linked-cell"/>
+	</define>
+	<define name="form-frame-attlist">
+		<ref name="form-control-attlist"/>
+		<ref name="common-disabled-attlist"/>
+		<ref name="for"/>
+		<ref name="label"/>
+		<ref name="common-printable-attlist"/>
+		<ref name="common-title-attlist"/>
+	</define>
+	<define name="form-image-frame-attlist">
+		<ref name="form-control-attlist"/>
+		<ref name="common-disabled-attlist"/>
+		<ref name="image-data"/>
+		<ref name="common-printable-attlist"/>
+		<ref name="common-readonly-attlist"/>
+		<ref name="common-title-attlist"/>
+		<ref name="common-data-field-attlist"/>
+	</define>
+	<define name="form-hidden-attlist">
+		<ref name="form-control-attlist"/>
+		<ref name="common-value-attlist"/>
+	</define>
+	<define name="form-grid-attlist">
+		<ref name="form-control-attlist"/>
+		<ref name="common-disabled-attlist"/>
+		<ref name="common-printable-attlist"/>
+		<ref name="common-tab-attlist"/>
+		<ref name="common-title-attlist"/>
+	</define>
+	<define name="form-column">
+		<element name="form:column">
+			<ref name="form-column-attlist"/>
+			<oneOrMore>
+				<ref name="column-controls"/>
+			</oneOrMore>
+		</element>
+	</define>
+	<define name="form-column-attlist">
+		<ref name="common-form-control-attlist"/>
+		<ref name="label"/>
+		<ref name="text-style-name"/>
+	</define>
+	<define name="text-style-name">
+		<optional>
+			<attribute name="form:text-style-name">
+				<ref name="styleNameRef"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="form-value-range-attlist">
+		<interleave>
+			<ref name="form-control-attlist"/>
+			<ref name="common-disabled-attlist"/>
+			<ref name="common-printable-attlist"/>
+			<ref name="common-tab-attlist"/>
+			<ref name="common-title-attlist"/>
+			<ref name="common-value-attlist"/>
+			<ref name="common-linked-cell"/>
+			<ref name="common-repeat"/>
+			<ref name="common-delay-for-repeat"/>
+			<optional>
+				<attribute name="form:max-value">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:min-value">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:step-size">
+					<ref name="positiveInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:page-step-size">
+					<ref name="positiveInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:orientation">
+					<choice>
+						<value>horizontal</value>
+						<value>vertical</value>
+					</choice>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="form-generic-control-attlist">
+		<ref name="form-control-attlist"/>
+	</define>
+	<define name="common-form-control-attlist">
+		<interleave>
+			<optional>
+				<attribute name="form:name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:control-implementation">
+					<ref name="namespacedToken"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="xforms-bind-attlist">
+		<optional>
+			<attribute name="xforms:bind">
+				<ref name="string"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="types">
+		<choice>
+			<value>submit</value>
+			<value>reset</value>
+			<value>push</value>
+			<value>url</value>
+		</choice>
+	</define>
+	<define name="button-type">
+		<optional>
+			<attribute name="form:button-type">
+				<ref name="types"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-control-id-attlist">
+		<group>
+			<ref name="xml-id"/>
+			<optional>
+				<attribute name="form:id">
+					<ref name="NCName"/>
+				</attribute>
+			</optional>
+		</group>
+	</define>
+	<define name="current-selected">
+		<optional>
+			<attribute name="form:current-selected">
+				<ref name="boolean"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-value-attlist">
+		<optional>
+			<attribute name="form:value">
+				<ref name="string"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-current-value-attlist">
+		<optional>
+			<attribute name="form:current-value">
+				<ref name="string"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-disabled-attlist">
+		<optional>
+			<attribute name="form:disabled">
+				<ref name="boolean"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="dropdown">
+		<optional>
+			<attribute name="form:dropdown">
+				<ref name="boolean"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="for">
+		<optional>
+			<attribute name="form:for">
+				<ref name="string"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="image-data">
+		<optional>
+			<attribute name="form:image-data">
+				<ref name="anyIRI"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="label">
+		<optional>
+			<attribute name="form:label">
+				<ref name="string"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-maxlength-attlist">
+		<optional>
+			<attribute name="form:max-length">
+				<ref name="nonNegativeInteger"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-printable-attlist">
+		<optional>
+			<attribute name="form:printable">
+				<ref name="boolean"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-readonly-attlist">
+		<optional>
+			<attribute name="form:readonly">
+				<ref name="boolean"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="selected">
+		<optional>
+			<attribute name="form:selected">
+				<ref name="boolean"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="size">
+		<optional>
+			<attribute name="form:size">
+				<ref name="nonNegativeInteger"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-tab-attlist">
+		<interleave>
+			<optional>
+				<attribute name="form:tab-index">
+					<ref name="nonNegativeInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="form:tab-stop">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="target-frame">
+		<optional>
+			<attribute name="office:target-frame">
+				<ref name="targetFrameName"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="target-location">
+		<optional>
+			<attribute name="xlink:href">
+				<ref name="anyIRI"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-title-attlist">
+		<optional>
+			<attribute name="form:title">
+				<ref name="string"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-form-visual-effect-attlist">
+		<optional>
+			<attribute name="form:visual-effect">
+				<choice>
+					<value>flat</value>
+					<value>3d</value>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-form-relative-image-position-attlist">
+		<choice>
+			<optional>
+				<attribute name="form:image-position">
+					<value>center</value>
+				</attribute>
+			</optional>
+			<group>
+				<attribute name="form:image-position">
+					<choice>
+						<value>start</value>
+						<value>end</value>
+						<value>top</value>
+						<value>bottom</value>
+					</choice>
+				</attribute>
+				<optional>
+					<attribute name="form:image-align">
+						<choice>
+							<value>start</value>
+							<value>center</value>
+							<value>end</value>
+						</choice>
+					</attribute>
+				</optional>
+			</group>
+		</choice>
+	</define>
+	<define name="bound-column">
+		<optional>
+			<attribute name="form:bound-column">
+				<ref name="string"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-convert-empty-attlist">
+		<optional>
+			<attribute name="form:convert-empty-to-null">
+				<ref name="boolean"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-data-field-attlist">
+		<optional>
+			<attribute name="form:data-field">
+				<ref name="string"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="list-source">
+		<optional>
+			<attribute name="form:list-source">
+				<ref name="string"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="list-source-type">
+		<optional>
+			<attribute name="form:list-source-type">
+				<choice>
+					<value>table</value>
+					<value>query</value>
+					<value>sql</value>
+					<value>sql-pass-through</value>
+					<value>value-list</value>
+					<value>table-fields</value>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-linked-cell">
+		<optional>
+			<attribute name="form:linked-cell">
+				<choice>
+					<ref name="cellAddress"/>
+					<ref name="string"/>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-source-cell-range">
+		<optional>
+			<attribute name="form:source-cell-range">
+				<choice>
+					<ref name="cellRangeAddress"/>
+					<ref name="string"/>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-spin-button">
+		<optional>
+			<attribute name="form:spin-button">
+				<ref name="boolean"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-repeat">
+		<optional>
+			<attribute name="form:repeat">
+				<ref name="boolean"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-delay-for-repeat">
+		<optional>
+			<attribute name="form:delay-for-repeat">
+				<ref name="duration"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="form-properties">
+		<element name="form:properties">
+			<oneOrMore>
+				<ref name="form-property"/>
+			</oneOrMore>
+		</element>
+	</define>
+	<define name="form-property">
+		<choice>
+			<element name="form:property">
+				<ref name="form-property-name"/>
+				<ref name="form-property-value-and-type-attlist"/>
+			</element>
+			<element name="form:list-property">
+				<ref name="form-property-name"/>
+				<ref name="form-property-type-and-value-list"/>
+			</element>
+		</choice>
+	</define>
+	<define name="form-property-name">
+		<attribute name="form:property-name">
+			<ref name="string"/>
+		</attribute>
+	</define>
+	<define name="form-property-value-and-type-attlist">
+		<choice>
+			<ref name="common-value-and-type-attlist"/>
+			<attribute name="office:value-type">
+				<value>void</value>
+			</attribute>
+		</choice>
+	</define>
+	<define name="form-property-type-and-value-list">
+		<choice>
+			<group>
+				<attribute name="office:value-type">
+					<value>float</value>
+				</attribute>
+				<zeroOrMore>
+					<element name="form:list-value">
+						<attribute name="office:value">
+							<ref name="double"/>
+						</attribute>
+					</element>
+				</zeroOrMore>
+			</group>
+			<group>
+				<attribute name="office:value-type">
+					<value>percentage</value>
+				</attribute>
+				<zeroOrMore>
+					<element name="form:list-value">
+						<attribute name="office:value">
+							<ref name="double"/>
+						</attribute>
+					</element>
+				</zeroOrMore>
+			</group>
+			<group>
+				<attribute name="office:value-type">
+					<value>currency</value>
+				</attribute>
+				<zeroOrMore>
+					<element name="form:list-value">
+						<attribute name="office:value">
+							<ref name="double"/>
+						</attribute>
+						<optional>
+							<attribute name="office:currency">
+								<ref name="string"/>
+							</attribute>
+						</optional>
+					</element>
+				</zeroOrMore>
+			</group>
+			<group>
+				<attribute name="office:value-type">
+					<value>date</value>
+				</attribute>
+				<zeroOrMore>
+					<element name="form:list-value">
+						<attribute name="office:date-value">
+							<ref name="dateOrDateTime"/>
+						</attribute>
+					</element>
+				</zeroOrMore>
+			</group>
+			<group>
+				<attribute name="office:value-type">
+					<value>time</value>
+				</attribute>
+				<zeroOrMore>
+					<element name="form:list-value">
+						<attribute name="office:time-value">
+							<ref name="duration"/>
+						</attribute>
+					</element>
+				</zeroOrMore>
+			</group>
+			<group>
+				<attribute name="office:value-type">
+					<value>boolean</value>
+				</attribute>
+				<zeroOrMore>
+					<element name="form:list-value">
+						<attribute name="office:boolean-value">
+							<ref name="boolean"/>
+						</attribute>
+					</element>
+				</zeroOrMore>
+			</group>
+			<group>
+				<attribute name="office:value-type">
+					<value>string</value>
+				</attribute>
+				<zeroOrMore>
+					<element name="form:list-value">
+						<attribute name="office:string-value">
+							<ref name="string"/>
+						</attribute>
+					</element>
+				</zeroOrMore>
+			</group>
+			<attribute name="office:value-type">
+				<value>void</value>
+			</attribute>
+		</choice>
+	</define>
+	<define name="office-annotation">
+		<element name="office:annotation">
+			<ref name="office-annotation-attlist"/>
+			<ref name="draw-caption-attlist"/>
+			<ref name="common-draw-position-attlist"/>
+			<ref name="common-draw-size-attlist"/>
+			<ref name="common-draw-shape-with-text-and-styles-attlist"/>
+			<optional>
+				<ref name="dc-creator"/>
+			</optional>
+			<optional>
+				<ref name="dc-date"/>
+			</optional>
+			<optional>
+				<ref name="meta-date-string"/>
+			</optional>
+			<zeroOrMore>
+				<choice>
+					<ref name="text-p"/>
+					<ref name="text-list"/>
+				</choice>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="office-annotation-end">
+		<element name="office:annotation-end">
+			<ref name="office-annotation-end-attlist"/>
+		</element>
+	</define>
+	<define name="office-annotation-attlist">
+		<interleave>
+			<optional>
+				<attribute name="office:display">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<ref name="common-office-annotation-name-attlist"/>
+			</optional>
+		</interleave>
+	</define>
+	<define name="office-annotation-end-attlist">
+		<ref name="common-office-annotation-name-attlist"/>
+	</define>
+	<define name="common-office-annotation-name-attlist">
+		<attribute name="office:name">
+			<ref name="string"/>
+		</attribute>
+	</define>
+	<define name="meta-date-string">
+		<element name="meta:date-string">
+			<ref name="string"/>
+		</element>
+	</define>
+	<define name="common-num-format-prefix-suffix-attlist">
+		<optional>
+			<attribute name="style:num-prefix">
+				<ref name="string"/>
+			</attribute>
+		</optional>
+		<optional>
+			<attribute name="style:num-suffix">
+				<ref name="string"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-num-format-attlist">
+		<choice>
+			<attribute name="style:num-format">
+				<choice>
+					<value>1</value>
+					<value>i</value>
+					<value>I</value>
+					<ref name="string"/>
+					<empty/>
+				</choice>
+			</attribute>
+			<group>
+				<attribute name="style:num-format">
+					<choice>
+						<value>a</value>
+						<value>A</value>
+					</choice>
+				</attribute>
+				<ref name="style-num-letter-sync-attlist"/>
+			</group>
+			<empty/>
+		</choice>
+	</define>
+	<define name="style-num-letter-sync-attlist">
+		<optional>
+			<attribute name="style:num-letter-sync">
+				<ref name="boolean"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="office-change-info">
+		<element name="office:change-info">
+			<ref name="dc-creator"/>
+			<ref name="dc-date"/>
+			<zeroOrMore>
+				<ref name="text-p"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="office-event-listeners">
+		<element name="office:event-listeners">
+			<zeroOrMore>
+				<choice>
+					<ref name="script-event-listener"/>
+					<ref name="presentation-event-listener"/>
+				</choice>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="script-event-listener">
+		<element name="script:event-listener">
+			<ref name="script-event-listener-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="script-event-listener-attlist">
+		<interleave>
+			<attribute name="script:event-name">
+				<ref name="string"/>
+			</attribute>
+			<attribute name="script:language">
+				<ref name="string"/>
+			</attribute>
+			<choice>
+				<attribute name="script:macro-name">
+					<ref name="string"/>
+				</attribute>
+				<group>
+					<attribute name="xlink:type">
+						<value>simple</value>
+					</attribute>
+					<attribute name="xlink:href">
+						<ref name="anyIRI"/>
+					</attribute>
+					<optional>
+						<attribute name="xlink:actuate">
+							<value>onRequest</value>
+						</attribute>
+					</optional>
+				</group>
+			</choice>
+		</interleave>
+	</define>
+	<define name="math-math">
+		<element name="math:math">
+			<ref name="mathMarkup"/>
+		</element>
+	</define>
+	<define name="mathMarkup">
+		<dc:description>To avoid inclusion of the complete MathML schema, anything is allowed within a math:math top-level element</dc:description>
+		<zeroOrMore>
+			<choice>
+				<attribute>
+					<anyName/>
+				</attribute>
+				<text/>
+				<element>
+					<anyName/>
+					<ref name="mathMarkup"/>
+				</element>
+			</choice>
+		</zeroOrMore>
+	</define>
+	<define name="text-dde-connection-decl">
+		<element name="text:dde-connection-decl">
+			<ref name="text-dde-connection-decl-attlist"/>
+			<ref name="common-dde-connection-decl-attlist"/>
+		</element>
+	</define>
+	<define name="text-dde-connection-decl-attlist">
+		<attribute name="office:name">
+			<ref name="string"/>
+		</attribute>
+	</define>
+	<define name="common-dde-connection-decl-attlist">
+		<interleave>
+			<attribute name="office:dde-application">
+				<ref name="string"/>
+			</attribute>
+			<attribute name="office:dde-topic">
+				<ref name="string"/>
+			</attribute>
+			<attribute name="office:dde-item">
+				<ref name="string"/>
+			</attribute>
+			<optional>
+				<attribute name="office:automatic-update">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="table-dde-link">
+		<element name="table:dde-link">
+			<ref name="office-dde-source"/>
+			<ref name="table-table"/>
+		</element>
+	</define>
+	<define name="office-dde-source">
+		<element name="office:dde-source">
+			<ref name="office-dde-source-attlist"/>
+			<ref name="common-dde-connection-decl-attlist"/>
+		</element>
+	</define>
+	<define name="office-dde-source-attlist">
+		<interleave>
+			<optional>
+				<attribute name="office:name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="office:conversion-mode">
+					<choice>
+						<value>into-default-style-data-style</value>
+						<value>into-english-number</value>
+						<value>keep-text</value>
+					</choice>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="animation-element">
+		<choice>
+			<element name="anim:animate">
+				<ref name="common-anim-target-attlist"/>
+				<ref name="common-anim-named-target-attlist"/>
+				<ref name="common-anim-values-attlist"/>
+				<ref name="common-anim-spline-mode-attlist"/>
+				<ref name="common-spline-anim-value-attlist"/>
+				<ref name="common-timing-attlist"/>
+				<ref name="common-anim-add-accum-attlist"/>
+			</element>
+			<element name="anim:set">
+				<ref name="common-anim-target-attlist"/>
+				<ref name="common-anim-named-target-attlist"/>
+				<ref name="common-anim-set-values-attlist"/>
+				<ref name="common-timing-attlist"/>
+				<ref name="common-anim-add-accum-attlist"/>
+			</element>
+			<element name="anim:animateMotion">
+				<ref name="anim-animate-motion-attlist"/>
+				<ref name="common-anim-target-attlist"/>
+				<ref name="common-anim-named-target-attlist"/>
+				<ref name="common-anim-add-accum-attlist"/>
+				<ref name="common-anim-values-attlist"/>
+				<ref name="common-timing-attlist"/>
+				<ref name="common-spline-anim-value-attlist"/>
+			</element>
+			<element name="anim:animateColor">
+				<ref name="common-anim-target-attlist"/>
+				<ref name="common-anim-named-target-attlist"/>
+				<ref name="common-anim-add-accum-attlist"/>
+				<ref name="common-anim-values-attlist"/>
+				<ref name="common-anim-spline-mode-attlist"/>
+				<ref name="common-spline-anim-value-attlist"/>
+				<ref name="anim-animate-color-attlist"/>
+				<ref name="common-timing-attlist"/>
+			</element>
+			<element name="anim:animateTransform">
+				<ref name="common-anim-target-attlist"/>
+				<ref name="common-anim-named-target-attlist"/>
+				<ref name="common-anim-add-accum-attlist"/>
+				<ref name="common-anim-values-attlist"/>
+				<ref name="anim-animate-transform-attlist"/>
+				<ref name="common-timing-attlist"/>
+			</element>
+			<element name="anim:transitionFilter">
+				<ref name="common-anim-target-attlist"/>
+				<ref name="common-anim-add-accum-attlist"/>
+				<ref name="common-anim-values-attlist"/>
+				<ref name="common-anim-spline-mode-attlist"/>
+				<ref name="anim-transition-filter-attlist"/>
+				<ref name="common-timing-attlist"/>
+			</element>
+			<element name="anim:par">
+				<ref name="common-anim-attlist"/>
+				<ref name="common-timing-attlist"/>
+				<ref name="common-endsync-timing-attlist"/>
+				<zeroOrMore>
+					<ref name="animation-element"/>
+				</zeroOrMore>
+			</element>
+			<element name="anim:seq">
+				<ref name="common-anim-attlist"/>
+				<ref name="common-endsync-timing-attlist"/>
+				<ref name="common-timing-attlist"/>
+				<zeroOrMore>
+					<ref name="animation-element"/>
+				</zeroOrMore>
+			</element>
+			<element name="anim:iterate">
+				<ref name="common-anim-attlist"/>
+				<ref name="anim-iterate-attlist"/>
+				<ref name="common-timing-attlist"/>
+				<ref name="common-endsync-timing-attlist"/>
+				<zeroOrMore>
+					<ref name="animation-element"/>
+				</zeroOrMore>
+			</element>
+			<element name="anim:audio">
+				<ref name="common-anim-attlist"/>
+				<ref name="anim-audio-attlist"/>
+				<ref name="common-basic-timing-attlist"/>
+			</element>
+			<element name="anim:command">
+				<ref name="common-anim-attlist"/>
+				<ref name="anim-command-attlist"/>
+				<ref name="common-begin-end-timing-attlist"/>
+				<ref name="common-anim-target-attlist"/>
+				<zeroOrMore>
+					<element name="anim:param">
+						<attribute name="anim:name">
+							<ref name="string"/>
+						</attribute>
+						<attribute name="anim:value">
+							<ref name="string"/>
+						</attribute>
+					</element>
+				</zeroOrMore>
+			</element>
+		</choice>
+	</define>
+	<define name="anim-animate-motion-attlist">
+		<interleave>
+			<optional>
+				<attribute name="svg:path">
+					<ref name="pathData"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:origin">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="smil:calcMode">
+					<choice>
+						<value>discrete</value>
+						<value>linear</value>
+						<value>paced</value>
+						<value>spline</value>
+					</choice>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="anim-animate-color-attlist">
+		<interleave>
+			<optional>
+				<attribute name="anim:color-interpolation">
+					<choice>
+						<value>rgb</value>
+						<value>hsl</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="anim:color-interpolation-direction">
+					<choice>
+						<value>clockwise</value>
+						<value>counter-clockwise</value>
+					</choice>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="anim-animate-transform-attlist">
+		<attribute name="svg:type">
+			<choice>
+				<value>translate</value>
+				<value>scale</value>
+				<value>rotate</value>
+				<value>skewX</value>
+				<value>skewY</value>
+			</choice>
+		</attribute>
+	</define>
+	<define name="anim-transition-filter-attlist">
+		<interleave>
+			<attribute name="smil:type">
+				<ref name="string"/>
+			</attribute>
+			<optional>
+				<attribute name="smil:subtype">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="smil:direction">
+					<choice>
+						<value>forward</value>
+						<value>reverse</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="smil:fadeColor">
+					<ref name="color"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="smil:mode">
+					<choice>
+						<value>in</value>
+						<value>out</value>
+					</choice>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="common-anim-target-attlist">
+		<interleave>
+			<optional>
+				<attribute name="smil:targetElement">
+					<ref name="IDREF"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="anim:sub-item">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="common-anim-named-target-attlist">
+		<attribute name="smil:attributeName">
+			<ref name="string"/>
+		</attribute>
+	</define>
+	<define name="common-anim-values-attlist">
+		<interleave>
+			<optional>
+				<attribute name="smil:values">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="anim:formula">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<ref name="common-anim-set-values-attlist"/>
+			<optional>
+				<attribute name="smil:from">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="smil:by">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="common-anim-spline-mode-attlist">
+		<optional>
+			<attribute name="smil:calcMode">
+				<choice>
+					<value>discrete</value>
+					<value>linear</value>
+					<value>paced</value>
+					<value>spline</value>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-spline-anim-value-attlist">
+		<interleave>
+			<optional>
+				<attribute name="smil:keyTimes">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="smil:keySplines">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="common-anim-add-accum-attlist">
+		<interleave>
+			<optional>
+				<attribute name="smil:accumulate">
+					<choice>
+						<value>none</value>
+						<value>sum</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="smil:additive">
+					<choice>
+						<value>replace</value>
+						<value>sum</value>
+					</choice>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="common-anim-set-values-attlist">
+		<optional>
+			<attribute name="smil:to">
+				<ref name="string"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-begin-end-timing-attlist">
+		<interleave>
+			<optional>
+				<attribute name="smil:begin">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="smil:end">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="common-dur-timing-attlist">
+		<optional>
+			<attribute name="smil:dur">
+				<ref name="string"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-endsync-timing-attlist">
+		<optional>
+			<attribute name="smil:endsync">
+				<choice>
+					<value>first</value>
+					<value>last</value>
+					<value>all</value>
+					<value>media</value>
+					<ref name="IDREF"/>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-repeat-timing-attlist">
+		<optional>
+			<attribute name="smil:repeatDur">
+				<ref name="string"/>
+			</attribute>
+		</optional>
+		<optional>
+			<attribute name="smil:repeatCount">
+				<choice>
+					<ref name="nonNegativeDecimal"/>
+					<value>indefinite</value>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="nonNegativeDecimal">
+		<data type="decimal">
+			<param name="minInclusive">0.0</param>
+		</data>
+	</define>
+	<define name="common-fill-timing-attlist">
+		<optional>
+			<attribute name="smil:fill">
+				<choice>
+					<value>remove</value>
+					<value>freeze</value>
+					<value>hold</value>
+					<value>auto</value>
+					<value>default</value>
+					<value>transition</value>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-fill-default-attlist">
+		<optional>
+			<attribute name="smil:fillDefault">
+				<choice>
+					<value>remove</value>
+					<value>freeze</value>
+					<value>hold</value>
+					<value>transition</value>
+					<value>auto</value>
+					<value>inherit</value>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-restart-timing-attlist">
+		<optional>
+			<attribute name="smil:restart">
+				<choice>
+					<value>never</value>
+					<value>always</value>
+					<value>whenNotActive</value>
+					<value>default</value>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-restart-default-attlist">
+		<optional>
+			<attribute name="smil:restartDefault">
+				<choice>
+					<value>never</value>
+					<value>always</value>
+					<value>whenNotActive</value>
+					<value>inherit</value>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-time-manip-attlist">
+		<interleave>
+			<optional>
+				<attribute name="smil:accelerate">
+					<ref name="zeroToOneDecimal"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="smil:decelerate">
+					<ref name="zeroToOneDecimal"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="smil:autoReverse">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="zeroToOneDecimal">
+		<data type="decimal">
+			<param name="minInclusive">0</param>
+			<param name="maxInclusive">1</param>
+		</data>
+	</define>
+	<define name="common-basic-timing-attlist">
+		<ref name="common-begin-end-timing-attlist"/>
+		<ref name="common-dur-timing-attlist"/>
+		<ref name="common-repeat-timing-attlist"/>
+		<ref name="common-restart-timing-attlist"/>
+		<ref name="common-restart-default-attlist"/>
+		<ref name="common-fill-timing-attlist"/>
+		<ref name="common-fill-default-attlist"/>
+	</define>
+	<define name="common-timing-attlist">
+		<ref name="common-basic-timing-attlist"/>
+		<ref name="common-time-manip-attlist"/>
+	</define>
+	<define name="anim-iterate-attlist">
+		<interleave>
+			<ref name="common-anim-target-attlist"/>
+			<optional>
+				<attribute name="anim:iterate-type">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="anim:iterate-interval">
+					<ref name="duration"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="anim-audio-attlist">
+		<interleave>
+			<optional>
+				<attribute name="xlink:href">
+					<ref name="anyIRI"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="anim:audio-level">
+					<ref name="double"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="anim-command-attlist">
+		<attribute name="anim:command">
+			<ref name="string"/>
+		</attribute>
+	</define>
+	<define name="style-style">
+		<element name="style:style">
+			<ref name="style-style-attlist"/>
+			<ref name="style-style-content"/>
+			<zeroOrMore>
+				<ref name="style-map"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="common-in-content-meta-attlist">
+		<attribute name="xhtml:about">
+			<ref name="URIorSafeCURIE"/>
+		</attribute>
+		<attribute name="xhtml:property">
+			<ref name="CURIEs"/>
+		</attribute>
+		<ref name="common-meta-literal-attlist"/>
+	</define>
+	<define name="common-meta-literal-attlist">
+		<optional>
+			<attribute name="xhtml:datatype">
+				<ref name="CURIE"/>
+			</attribute>
+		</optional>
+		<optional>
+			<attribute name="xhtml:content">
+				<ref name="string"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="xml-id">
+		<attribute name="xml:id">
+			<ref name="ID"/>
+		</attribute>
+	</define>
+	<define name="style-style-attlist">
+		<interleave>
+			<attribute name="style:name">
+				<ref name="styleName"/>
+			</attribute>
+			<optional>
+				<attribute name="style:display-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:parent-style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:next-style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:list-level">
+					<choice>
+						<ref name="positiveInteger"/>
+						<empty/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:list-style-name">
+					<choice>
+						<ref name="styleName"/>
+						<empty/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:master-page-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:auto-update">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:data-style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:percentage-data-style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:class">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:default-outline-level">
+					<choice>
+						<ref name="positiveInteger"/>
+						<empty/>
+					</choice>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="style-map">
+		<element name="style:map">
+			<ref name="style-map-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="style-map-attlist">
+		<interleave>
+			<attribute name="style:condition">
+				<ref name="string"/>
+			</attribute>
+			<attribute name="style:apply-style-name">
+				<ref name="styleNameRef"/>
+			</attribute>
+			<optional>
+				<attribute name="style:base-cell-address">
+					<ref name="cellAddress"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="style-default-style">
+		<element name="style:default-style">
+			<ref name="style-style-content"/>
+		</element>
+	</define>
+	<define name="style-page-layout">
+		<element name="style:page-layout">
+			<ref name="style-page-layout-attlist"/>
+			<ref name="style-page-layout-content"/>
+		</element>
+	</define>
+	<define name="style-page-layout-content">
+		<optional>
+			<ref name="style-page-layout-properties"/>
+		</optional>
+		<optional>
+			<ref name="style-header-style"/>
+		</optional>
+		<optional>
+			<ref name="style-footer-style"/>
+		</optional>
+	</define>
+	<define name="style-page-layout-attlist">
+		<interleave>
+			<attribute name="style:name">
+				<ref name="styleName"/>
+			</attribute>
+			<optional>
+				<attribute name="style:page-usage">
+					<choice>
+						<value>all</value>
+						<value>left</value>
+						<value>right</value>
+						<value>mirrored</value>
+					</choice>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="style-header-style">
+		<element name="style:header-style">
+			<optional>
+				<ref name="style-header-footer-properties"/>
+			</optional>
+		</element>
+	</define>
+	<define name="style-footer-style">
+		<element name="style:footer-style">
+			<optional>
+				<ref name="style-header-footer-properties"/>
+			</optional>
+		</element>
+	</define>
+	<define name="style-default-page-layout">
+		<element name="style:default-page-layout">
+			<ref name="style-page-layout-content"/>
+		</element>
+	</define>
+	<define name="style-master-page">
+		<element name="style:master-page">
+			<ref name="style-master-page-attlist"/>
+			<optional>
+				<ref name="style-header"/>
+				<optional>
+					<ref name="style-header-left"/>
+				</optional>
+			</optional>
+			<optional>
+				<ref name="style-footer"/>
+				<optional>
+					<ref name="style-footer-left"/>
+				</optional>
+			</optional>
+			<optional>
+				<ref name="draw-layer-set"/>
+			</optional>
+			<optional>
+				<ref name="office-forms"/>
+			</optional>
+			<zeroOrMore>
+				<ref name="shape"/>
+			</zeroOrMore>
+			<optional>
+				<ref name="animation-element"/>
+			</optional>
+			<optional>
+				<ref name="presentation-notes"/>
+			</optional>
+		</element>
+	</define>
+	<define name="style-master-page-attlist">
+		<interleave>
+			<attribute name="style:name">
+				<ref name="styleName"/>
+			</attribute>
+			<optional>
+				<attribute name="style:display-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<attribute name="style:page-layout-name">
+				<ref name="styleNameRef"/>
+			</attribute>
+			<optional>
+				<attribute name="draw:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:next-style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="style-header">
+		<element name="style:header">
+			<ref name="common-style-header-footer-attlist"/>
+			<ref name="header-footer-content"/>
+		</element>
+	</define>
+	<define name="style-footer">
+		<element name="style:footer">
+			<ref name="common-style-header-footer-attlist"/>
+			<ref name="header-footer-content"/>
+		</element>
+	</define>
+	<define name="style-header-left">
+		<element name="style:header-left">
+			<ref name="common-style-header-footer-attlist"/>
+			<ref name="header-footer-content"/>
+		</element>
+	</define>
+	<define name="style-footer-left">
+		<element name="style:footer-left">
+			<ref name="common-style-header-footer-attlist"/>
+			<ref name="header-footer-content"/>
+		</element>
+	</define>
+	<define name="header-footer-content">
+		<choice>
+			<group>
+				<ref name="text-tracked-changes"/>
+				<ref name="text-decls"/>
+				<zeroOrMore>
+					<choice>
+						<ref name="text-h"/>
+						<ref name="text-p"/>
+						<ref name="text-list"/>
+						<ref name="table-table"/>
+						<ref name="text-section"/>
+						<ref name="text-table-of-content"/>
+						<ref name="text-illustration-index"/>
+						<ref name="text-table-index"/>
+						<ref name="text-object-index"/>
+						<ref name="text-user-index"/>
+						<ref name="text-alphabetical-index"/>
+						<ref name="text-bibliography"/>
+						<ref name="text-index-title"/>
+						<ref name="change-marks"/>
+					</choice>
+				</zeroOrMore>
+			</group>
+			<group>
+				<optional>
+					<ref name="style-region-left"/>
+				</optional>
+				<optional>
+					<ref name="style-region-center"/>
+				</optional>
+				<optional>
+					<ref name="style-region-right"/>
+				</optional>
+			</group>
+		</choice>
+	</define>
+	<define name="common-style-header-footer-attlist">
+		<optional>
+			<attribute name="style:display">
+				<ref name="boolean"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="style-region-left">
+		<element name="style:region-left">
+			<ref name="region-content"/>
+		</element>
+	</define>
+	<define name="style-region-center">
+		<element name="style:region-center">
+			<ref name="region-content"/>
+		</element>
+	</define>
+	<define name="style-region-right">
+		<element name="style:region-right">
+			<ref name="region-content"/>
+		</element>
+	</define>
+	<define name="region-content">
+		<zeroOrMore>
+			<ref name="text-p"/>
+		</zeroOrMore>
+	</define>
+	<define name="presentation-notes">
+		<element name="presentation:notes">
+			<ref name="common-presentation-header-footer-attlist"/>
+			<ref name="presentation-notes-attlist"/>
+			<ref name="office-forms"/>
+			<zeroOrMore>
+				<ref name="shape"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="presentation-notes-attlist">
+		<interleave>
+			<optional>
+				<attribute name="style:page-layout-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="table-table-template">
+		<element name="table:table-template">
+			<ref name="table-table-template-attlist"/>
+			<optional>
+				<ref name="table-first-row"/>
+			</optional>
+			<optional>
+				<ref name="table-last-row"/>
+			</optional>
+			<optional>
+				<ref name="table-first-column"/>
+			</optional>
+			<optional>
+				<ref name="table-last-column"/>
+			</optional>
+			<ref name="table-body"/>
+			<optional>
+				<ref name="table-even-rows"/>
+			</optional>
+			<optional>
+				<ref name="table-odd-rows"/>
+			</optional>
+			<optional>
+				<ref name="table-even-columns"/>
+			</optional>
+			<optional>
+				<ref name="table-odd-columns"/>
+			</optional>
+			<optional>
+				<ref name="table-background"/>
+			</optional>
+		</element>
+	</define>
+	<define name="table-table-template-attlist">
+		<interleave>
+			<attribute name="table:name">
+				<ref name="string"/>
+			</attribute>
+			<attribute name="table:first-row-start-column">
+				<ref name="rowOrCol"/>
+			</attribute>
+			<attribute name="table:first-row-end-column">
+				<ref name="rowOrCol"/>
+			</attribute>
+			<attribute name="table:last-row-start-column">
+				<ref name="rowOrCol"/>
+			</attribute>
+			<attribute name="table:last-row-end-column">
+				<ref name="rowOrCol"/>
+			</attribute>
+		</interleave>
+	</define>
+	<define name="rowOrCol">
+		<choice>
+			<value>row</value>
+			<value>column</value>
+		</choice>
+	</define>
+	<define name="table-first-row">
+		<element name="table:first-row">
+			<ref name="common-table-template-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-last-row">
+		<element name="table:last-row">
+			<ref name="common-table-template-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-first-column">
+		<element name="table:first-column">
+			<ref name="common-table-template-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-last-column">
+		<element name="table:last-column">
+			<ref name="common-table-template-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-body">
+		<element name="table:body">
+			<ref name="common-table-template-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-even-rows">
+		<element name="table:even-rows">
+			<ref name="common-table-template-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-odd-rows">
+		<element name="table:odd-rows">
+			<ref name="common-table-template-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-even-columns">
+		<element name="table:even-columns">
+			<ref name="common-table-template-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-odd-columns">
+		<element name="table:odd-columns">
+			<ref name="common-table-template-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="common-table-template-attlist">
+		<attribute name="table:style-name">
+			<ref name="styleNameRef"/>
+		</attribute>
+		<optional>
+			<attribute name="table:paragraph-style-name">
+				<ref name="styleNameRef"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="table-background">
+		<element name="table:background">
+			<ref name="table-background-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="table-background-attlist">
+		<attribute name="table:style-name">
+			<ref name="styleNameRef"/>
+		</attribute>
+	</define>
+	<define name="style-font-face">
+		<element name="style:font-face">
+			<ref name="style-font-face-attlist"/>
+			<optional>
+				<ref name="svg-font-face-src"/>
+			</optional>
+			<optional>
+				<ref name="svg-definition-src"/>
+			</optional>
+		</element>
+	</define>
+	<define name="style-font-face-attlist">
+		<interleave>
+			<optional>
+				<attribute name="svg:font-family">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:font-style">
+					<ref name="fontStyle"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:font-variant">
+					<ref name="fontVariant"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:font-weight">
+					<ref name="fontWeight"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:font-stretch">
+					<choice>
+						<value>normal</value>
+						<value>ultra-condensed</value>
+						<value>extra-condensed</value>
+						<value>condensed</value>
+						<value>semi-condensed</value>
+						<value>semi-expanded</value>
+						<value>expanded</value>
+						<value>extra-expanded</value>
+						<value>ultra-expanded</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:font-size">
+					<ref name="positiveLength"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:unicode-range">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:units-per-em">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:panose-1">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:stemv">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:stemh">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:slope">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:cap-height">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:x-height">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:accent-height">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:ascent">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:descent">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:widths">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:bbox">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:ideographic">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:alphabetic">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:mathematical">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:hanging">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:v-ideographic">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:v-alphabetic">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:v-mathematical">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:v-hanging">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:underline-position">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:underline-thickness">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:strikethrough-position">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:strikethrough-thickness">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:overline-position">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:overline-thickness">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+			<attribute name="style:name">
+				<ref name="string"/>
+			</attribute>
+			<optional>
+				<attribute name="style:font-adornments">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:font-family-generic">
+					<ref name="fontFamilyGeneric"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:font-pitch">
+					<ref name="fontPitch"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:font-charset">
+					<ref name="textEncoding"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="svg-font-face-src">
+		<element name="svg:font-face-src">
+			<oneOrMore>
+				<choice>
+					<ref name="svg-font-face-uri"/>
+					<ref name="svg-font-face-name"/>
+				</choice>
+			</oneOrMore>
+		</element>
+	</define>
+	<define name="svg-font-face-uri">
+		<element name="svg:font-face-uri">
+			<ref name="common-svg-font-face-xlink-attlist"/>
+			<zeroOrMore>
+				<ref name="svg-font-face-format"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="svg-font-face-format">
+		<element name="svg:font-face-format">
+			<optional>
+				<attribute name="svg:string">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<empty/>
+		</element>
+	</define>
+	<define name="svg-font-face-name">
+		<element name="svg:font-face-name">
+			<optional>
+				<attribute name="svg:name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<empty/>
+		</element>
+	</define>
+	<define name="svg-definition-src">
+		<element name="svg:definition-src">
+			<ref name="common-svg-font-face-xlink-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="common-svg-font-face-xlink-attlist">
+		<attribute name="xlink:type">
+			<value>simple</value>
+		</attribute>
+		<attribute name="xlink:href">
+			<ref name="anyIRI"/>
+		</attribute>
+		<optional>
+			<attribute name="xlink:actuate">
+				<value>onRequest</value>
+			</attribute>
+		</optional>
+	</define>
+	<define name="number-number-style">
+		<element name="number:number-style">
+			<ref name="common-data-style-attlist"/>
+			<optional>
+				<ref name="style-text-properties"/>
+			</optional>
+			<optional>
+				<ref name="number-text"/>
+			</optional>
+			<optional>
+				<ref name="any-number"/>
+				<optional>
+					<ref name="number-text"/>
+				</optional>
+			</optional>
+			<zeroOrMore>
+				<ref name="style-map"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="any-number">
+		<choice>
+			<ref name="number-number"/>
+			<ref name="number-scientific-number"/>
+			<ref name="number-fraction"/>
+		</choice>
+	</define>
+	<define name="number-number">
+		<element name="number:number">
+			<ref name="number-number-attlist"/>
+			<ref name="common-decimal-places-attlist"/>
+			<ref name="common-number-attlist"/>
+			<zeroOrMore>
+				<ref name="number-embedded-text"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="number-number-attlist">
+		<interleave>
+			<optional>
+				<attribute name="number:decimal-replacement">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="number:display-factor">
+					<ref name="double"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="number-embedded-text">
+		<element name="number:embedded-text">
+			<ref name="number-embedded-text-attlist"/>
+			<text/>
+		</element>
+	</define>
+	<define name="number-embedded-text-attlist">
+		<attribute name="number:position">
+			<ref name="integer"/>
+		</attribute>
+	</define>
+	<define name="number-scientific-number">
+		<element name="number:scientific-number">
+			<ref name="number-scientific-number-attlist"/>
+			<ref name="common-decimal-places-attlist"/>
+			<ref name="common-number-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="number-scientific-number-attlist">
+		<optional>
+			<attribute name="number:min-exponent-digits">
+				<ref name="integer"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="number-fraction">
+		<element name="number:fraction">
+			<ref name="number-fraction-attlist"/>
+			<ref name="common-number-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="number-fraction-attlist">
+		<interleave>
+			<optional>
+				<attribute name="number:min-numerator-digits">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="number:min-denominator-digits">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="number:denominator-value">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="number-currency-style">
+		<element name="number:currency-style">
+			<ref name="common-data-style-attlist"/>
+			<ref name="common-auto-reorder-attlist"/>
+			<optional>
+				<ref name="style-text-properties"/>
+			</optional>
+			<optional>
+				<ref name="number-text"/>
+			</optional>
+			<optional>
+				<choice>
+					<group>
+						<ref name="number-and-text"/>
+						<optional>
+							<ref name="currency-symbol-and-text"/>
+						</optional>
+					</group>
+					<group>
+						<ref name="currency-symbol-and-text"/>
+						<optional>
+							<ref name="number-and-text"/>
+						</optional>
+					</group>
+				</choice>
+			</optional>
+			<zeroOrMore>
+				<ref name="style-map"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="currency-symbol-and-text">
+		<ref name="number-currency-symbol"/>
+		<optional>
+			<ref name="number-text"/>
+		</optional>
+	</define>
+	<define name="number-and-text">
+		<ref name="number-number"/>
+		<optional>
+			<ref name="number-text"/>
+		</optional>
+	</define>
+	<define name="number-currency-symbol">
+		<element name="number:currency-symbol">
+			<ref name="number-currency-symbol-attlist"/>
+			<text/>
+		</element>
+	</define>
+	<define name="number-currency-symbol-attlist">
+		<optional>
+			<attribute name="number:language">
+				<ref name="languageCode"/>
+			</attribute>
+		</optional>
+		<optional>
+			<attribute name="number:country">
+				<ref name="countryCode"/>
+			</attribute>
+		</optional>
+		<optional>
+			<attribute name="number:script">
+				<ref name="scriptCode"/>
+			</attribute>
+		</optional>
+		<optional>
+			<attribute name="number:rfc-language-tag">
+				<ref name="language"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="number-percentage-style">
+		<element name="number:percentage-style">
+			<ref name="common-data-style-attlist"/>
+			<optional>
+				<ref name="style-text-properties"/>
+			</optional>
+			<optional>
+				<ref name="number-text"/>
+			</optional>
+			<optional>
+				<ref name="number-and-text"/>
+			</optional>
+			<zeroOrMore>
+				<ref name="style-map"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="number-date-style">
+		<element name="number:date-style">
+			<ref name="common-data-style-attlist"/>
+			<ref name="common-auto-reorder-attlist"/>
+			<ref name="common-format-source-attlist"/>
+			<optional>
+				<ref name="style-text-properties"/>
+			</optional>
+			<optional>
+				<ref name="number-text"/>
+			</optional>
+			<oneOrMore>
+				<ref name="any-date"/>
+				<optional>
+					<ref name="number-text"/>
+				</optional>
+			</oneOrMore>
+			<zeroOrMore>
+				<ref name="style-map"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="any-date">
+		<choice>
+			<ref name="number-day"/>
+			<ref name="number-month"/>
+			<ref name="number-year"/>
+			<ref name="number-era"/>
+			<ref name="number-day-of-week"/>
+			<ref name="number-week-of-year"/>
+			<ref name="number-quarter"/>
+			<ref name="number-hours"/>
+			<ref name="number-am-pm"/>
+			<ref name="number-minutes"/>
+			<ref name="number-seconds"/>
+		</choice>
+	</define>
+	<define name="number-day">
+		<element name="number:day">
+			<ref name="number-day-attlist"/>
+			<ref name="common-calendar-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="number-day-attlist">
+		<optional>
+			<attribute name="number:style">
+				<choice>
+					<value>short</value>
+					<value>long</value>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="number-month">
+		<element name="number:month">
+			<ref name="number-month-attlist"/>
+			<ref name="common-calendar-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="number-month-attlist">
+		<interleave>
+			<optional>
+				<attribute name="number:textual">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="number:possessive-form">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="number:style">
+					<choice>
+						<value>short</value>
+						<value>long</value>
+					</choice>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="number-year">
+		<element name="number:year">
+			<ref name="number-year-attlist"/>
+			<ref name="common-calendar-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="number-year-attlist">
+		<optional>
+			<attribute name="number:style">
+				<choice>
+					<value>short</value>
+					<value>long</value>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="number-era">
+		<element name="number:era">
+			<ref name="number-era-attlist"/>
+			<ref name="common-calendar-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="number-era-attlist">
+		<optional>
+			<attribute name="number:style">
+				<choice>
+					<value>short</value>
+					<value>long</value>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="number-day-of-week">
+		<element name="number:day-of-week">
+			<ref name="number-day-of-week-attlist"/>
+			<ref name="common-calendar-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="number-day-of-week-attlist">
+		<optional>
+			<attribute name="number:style">
+				<choice>
+					<value>short</value>
+					<value>long</value>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="number-week-of-year">
+		<element name="number:week-of-year">
+			<ref name="common-calendar-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="number-quarter">
+		<element name="number:quarter">
+			<ref name="number-quarter-attlist"/>
+			<ref name="common-calendar-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="number-quarter-attlist">
+		<optional>
+			<attribute name="number:style">
+				<choice>
+					<value>short</value>
+					<value>long</value>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="number-time-style">
+		<element name="number:time-style">
+			<ref name="number-time-style-attlist"/>
+			<ref name="common-data-style-attlist"/>
+			<ref name="common-format-source-attlist"/>
+			<optional>
+				<ref name="style-text-properties"/>
+			</optional>
+			<optional>
+				<ref name="number-text"/>
+			</optional>
+			<oneOrMore>
+				<ref name="any-time"/>
+				<optional>
+					<ref name="number-text"/>
+				</optional>
+			</oneOrMore>
+			<zeroOrMore>
+				<ref name="style-map"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="any-time">
+		<choice>
+			<ref name="number-hours"/>
+			<ref name="number-am-pm"/>
+			<ref name="number-minutes"/>
+			<ref name="number-seconds"/>
+		</choice>
+	</define>
+	<define name="number-time-style-attlist">
+		<optional>
+			<attribute name="number:truncate-on-overflow">
+				<ref name="boolean"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="number-hours">
+		<element name="number:hours">
+			<ref name="number-hours-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="number-hours-attlist">
+		<optional>
+			<attribute name="number:style">
+				<choice>
+					<value>short</value>
+					<value>long</value>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="number-minutes">
+		<element name="number:minutes">
+			<ref name="number-minutes-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="number-minutes-attlist">
+		<optional>
+			<attribute name="number:style">
+				<choice>
+					<value>short</value>
+					<value>long</value>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="number-seconds">
+		<element name="number:seconds">
+			<ref name="number-seconds-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="number-seconds-attlist">
+		<interleave>
+			<optional>
+				<attribute name="number:style">
+					<choice>
+						<value>short</value>
+						<value>long</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="number:decimal-places">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="number-am-pm">
+		<element name="number:am-pm">
+			<empty/>
+		</element>
+	</define>
+	<define name="number-boolean-style">
+		<element name="number:boolean-style">
+			<ref name="common-data-style-attlist"/>
+			<optional>
+				<ref name="style-text-properties"/>
+			</optional>
+			<optional>
+				<ref name="number-text"/>
+			</optional>
+			<optional>
+				<ref name="number-boolean"/>
+				<optional>
+					<ref name="number-text"/>
+				</optional>
+			</optional>
+			<zeroOrMore>
+				<ref name="style-map"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="number-boolean">
+		<element name="number:boolean">
+			<empty/>
+		</element>
+	</define>
+	<define name="number-text-style">
+		<element name="number:text-style">
+			<ref name="common-data-style-attlist"/>
+			<optional>
+				<ref name="style-text-properties"/>
+			</optional>
+			<optional>
+				<ref name="number-text"/>
+			</optional>
+			<zeroOrMore>
+				<ref name="number-text-content"/>
+				<optional>
+					<ref name="number-text"/>
+				</optional>
+			</zeroOrMore>
+			<zeroOrMore>
+				<ref name="style-map"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="number-text">
+		<element name="number:text">
+			<text/>
+		</element>
+	</define>
+	<define name="number-text-content">
+		<element name="number:text-content">
+			<empty/>
+		</element>
+	</define>
+	<define name="common-data-style-attlist">
+		<interleave>
+			<attribute name="style:name">
+				<ref name="styleName"/>
+			</attribute>
+			<optional>
+				<attribute name="style:display-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="number:language">
+					<ref name="languageCode"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="number:country">
+					<ref name="countryCode"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="number:script">
+					<ref name="scriptCode"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="number:rfc-language-tag">
+					<ref name="language"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="number:title">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:volatile">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="number:transliteration-format">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="number:transliteration-language">
+					<ref name="countryCode"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="number:transliteration-country">
+					<ref name="countryCode"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="number:transliteration-style">
+					<choice>
+						<value>short</value>
+						<value>medium</value>
+						<value>long</value>
+					</choice>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="common-auto-reorder-attlist">
+		<optional>
+			<attribute name="number:automatic-order">
+				<ref name="boolean"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-format-source-attlist">
+		<optional>
+			<attribute name="number:format-source">
+				<choice>
+					<value>fixed</value>
+					<value>language</value>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-decimal-places-attlist">
+		<optional>
+			<attribute name="number:decimal-places">
+				<ref name="integer"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-number-attlist">
+		<interleave>
+			<optional>
+				<attribute name="number:min-integer-digits">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="number:grouping">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="common-calendar-attlist">
+		<optional>
+			<attribute name="number:calendar">
+				<choice>
+					<value>gregorian</value>
+					<value>gengou</value>
+					<value>ROC</value>
+					<value>hanja_yoil</value>
+					<value>hanja</value>
+					<value>hijri</value>
+					<value>jewish</value>
+					<value>buddhist</value>
+					<ref name="string"/>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="style-style-content">
+		<choice>
+			<group>
+				<attribute name="style:family">
+					<value>text</value>
+				</attribute>
+				<optional>
+					<ref name="style-text-properties"/>
+				</optional>
+			</group>
+			<group>
+				<attribute name="style:family">
+					<value>paragraph</value>
+				</attribute>
+				<optional>
+					<ref name="style-paragraph-properties"/>
+				</optional>
+				<optional>
+					<ref name="style-text-properties"/>
+				</optional>
+			</group>
+			<group>
+				<attribute name="style:family">
+					<value>section</value>
+				</attribute>
+				<optional>
+					<ref name="style-section-properties"/>
+				</optional>
+			</group>
+			<group>
+				<attribute name="style:family">
+					<value>ruby</value>
+				</attribute>
+				<optional>
+					<ref name="style-ruby-properties"/>
+				</optional>
+			</group>
+			<group>
+				<attribute name="style:family">
+					<value>table</value>
+				</attribute>
+				<optional>
+					<ref name="style-table-properties"/>
+				</optional>
+			</group>
+			<group>
+				<attribute name="style:family">
+					<value>table-column</value>
+				</attribute>
+				<optional>
+					<ref name="style-table-column-properties"/>
+				</optional>
+			</group>
+			<group>
+				<attribute name="style:family">
+					<value>table-row</value>
+				</attribute>
+				<optional>
+					<ref name="style-table-row-properties"/>
+				</optional>
+			</group>
+			<group>
+				<attribute name="style:family">
+					<value>table-cell</value>
+				</attribute>
+				<optional>
+					<ref name="style-table-cell-properties"/>
+				</optional>
+				<optional>
+					<ref name="style-paragraph-properties"/>
+				</optional>
+				<optional>
+					<ref name="style-text-properties"/>
+				</optional>
+			</group>
+			<group>
+				<attribute name="style:family">
+					<choice>
+						<value>graphic</value>
+						<value>presentation</value>
+					</choice>
+				</attribute>
+				<optional>
+					<ref name="style-graphic-properties"/>
+				</optional>
+				<optional>
+					<ref name="style-paragraph-properties"/>
+				</optional>
+				<optional>
+					<ref name="style-text-properties"/>
+				</optional>
+			</group>
+			<group>
+				<attribute name="style:family">
+					<value>drawing-page</value>
+				</attribute>
+				<optional>
+					<ref name="style-drawing-page-properties"/>
+				</optional>
+			</group>
+			<group>
+				<attribute name="style:family">
+					<value>chart</value>
+				</attribute>
+				<optional>
+					<ref name="style-chart-properties"/>
+				</optional>
+				<optional>
+					<ref name="style-graphic-properties"/>
+				</optional>
+				<optional>
+					<ref name="style-paragraph-properties"/>
+				</optional>
+				<optional>
+					<ref name="style-text-properties"/>
+				</optional>
+			</group>
+		</choice>
+	</define>
+	<define name="text-linenumbering-configuration">
+		<element name="text:linenumbering-configuration">
+			<ref name="text-linenumbering-configuration-attlist"/>
+			<optional>
+				<ref name="text-linenumbering-separator"/>
+			</optional>
+		</element>
+	</define>
+	<define name="text-linenumbering-configuration-attlist">
+		<interleave>
+			<optional>
+				<attribute name="text:number-lines">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<ref name="common-num-format-attlist"/>
+			</optional>
+			<optional>
+				<attribute name="text:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:increment">
+					<ref name="nonNegativeInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:number-position">
+					<choice>
+						<value>left</value>
+						<value>right</value>
+						<value>inner</value>
+						<value>outer</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:offset">
+					<ref name="nonNegativeLength"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:count-empty-lines">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:count-in-text-boxes">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:restart-on-page">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="text-linenumbering-separator">
+		<element name="text:linenumbering-separator">
+			<optional>
+				<attribute name="text:increment">
+					<ref name="nonNegativeInteger"/>
+				</attribute>
+			</optional>
+			<text/>
+		</element>
+	</define>
+	<define name="text-notes-configuration">
+		<element name="text:notes-configuration">
+			<ref name="text-notes-configuration-content"/>
+		</element>
+	</define>
+	<define name="text-notes-configuration-content">
+		<interleave>
+			<ref name="text-note-class"/>
+			<optional>
+				<attribute name="text:citation-style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:citation-body-style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:default-style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:master-page-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:start-value">
+					<ref name="nonNegativeInteger"/>
+				</attribute>
+			</optional>
+			<ref name="common-num-format-prefix-suffix-attlist"/>
+			<optional>
+				<ref name="common-num-format-attlist"/>
+			</optional>
+			<optional>
+				<attribute name="text:start-numbering-at">
+					<choice>
+						<value>document</value>
+						<value>chapter</value>
+						<value>page</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:footnotes-position">
+					<choice>
+						<value>text</value>
+						<value>page</value>
+						<value>section</value>
+						<value>document</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<element name="text:note-continuation-notice-forward">
+					<text/>
+				</element>
+			</optional>
+			<optional>
+				<element name="text:note-continuation-notice-backward">
+					<text/>
+				</element>
+			</optional>
+		</interleave>
+	</define>
+	<define name="text-bibliography-configuration">
+		<element name="text:bibliography-configuration">
+			<ref name="text-bibliography-configuration-attlist"/>
+			<zeroOrMore>
+				<ref name="text-sort-key"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="text-bibliography-configuration-attlist">
+		<interleave>
+			<optional>
+				<attribute name="text:prefix">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:suffix">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:numbered-entries">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:sort-by-position">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:language">
+					<ref name="languageCode"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:country">
+					<ref name="countryCode"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:script">
+					<ref name="scriptCode"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:rfc-language-tag">
+					<ref name="language"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:sort-algorithm">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="text-sort-key">
+		<element name="text:sort-key">
+			<ref name="text-sort-key-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="text-sort-key-attlist">
+		<attribute name="text:key">
+			<choice>
+				<value>address</value>
+				<value>annote</value>
+				<value>author</value>
+				<value>bibliography-type</value>
+				<value>booktitle</value>
+				<value>chapter</value>
+				<value>custom1</value>
+				<value>custom2</value>
+				<value>custom3</value>
+				<value>custom4</value>
+				<value>custom5</value>
+				<value>edition</value>
+				<value>editor</value>
+				<value>howpublished</value>
+				<value>identifier</value>
+				<value>institution</value>
+				<value>isbn</value>
+				<value>issn</value>
+				<value>journal</value>
+				<value>month</value>
+				<value>note</value>
+				<value>number</value>
+				<value>organizations</value>
+				<value>pages</value>
+				<value>publisher</value>
+				<value>report-type</value>
+				<value>school</value>
+				<value>series</value>
+				<value>title</value>
+				<value>url</value>
+				<value>volume</value>
+				<value>year</value>
+			</choice>
+		</attribute>
+		<optional>
+			<attribute name="text:sort-ascending">
+				<ref name="boolean"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="text-list-style">
+		<element name="text:list-style">
+			<ref name="text-list-style-attr"/>
+			<zeroOrMore>
+				<ref name="text-list-style-content"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="text-list-style-attr">
+		<interleave>
+			<attribute name="style:name">
+				<ref name="styleName"/>
+			</attribute>
+			<optional>
+				<attribute name="style:display-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:consecutive-numbering">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="text-list-style-content">
+		<choice>
+			<element name="text:list-level-style-number">
+				<ref name="text-list-level-style-attr"/>
+				<ref name="text-list-level-style-number-attr"/>
+				<optional>
+					<ref name="style-list-level-properties"/>
+				</optional>
+				<optional>
+					<ref name="style-text-properties"/>
+				</optional>
+			</element>
+			<element name="text:list-level-style-bullet">
+				<ref name="text-list-level-style-attr"/>
+				<ref name="text-list-level-style-bullet-attr"/>
+				<optional>
+					<ref name="style-list-level-properties"/>
+				</optional>
+				<optional>
+					<ref name="style-text-properties"/>
+				</optional>
+			</element>
+			<element name="text:list-level-style-image">
+				<ref name="text-list-level-style-attr"/>
+				<ref name="text-list-level-style-image-attr"/>
+				<optional>
+					<ref name="style-list-level-properties"/>
+				</optional>
+			</element>
+		</choice>
+	</define>
+	<define name="text-list-level-style-number-attr">
+		<interleave>
+			<optional>
+				<attribute name="text:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<ref name="common-num-format-attlist"/>
+			<ref name="common-num-format-prefix-suffix-attlist"/>
+			<optional>
+				<attribute name="text:display-levels">
+					<ref name="positiveInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:start-value">
+					<ref name="positiveInteger"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="text-list-level-style-bullet-attr">
+		<interleave>
+			<optional>
+				<attribute name="text:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<attribute name="text:bullet-char">
+				<ref name="character"/>
+			</attribute>
+			<ref name="common-num-format-prefix-suffix-attlist"/>
+			<optional>
+				<attribute name="text:bullet-relative-size">
+					<ref name="percent"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="text-list-level-style-image-attr">
+		<choice>
+			<ref name="common-draw-data-attlist"/>
+			<ref name="office-binary-data"/>
+		</choice>
+	</define>
+	<define name="text-list-level-style-attr">
+		<attribute name="text:level">
+			<ref name="positiveInteger"/>
+		</attribute>
+	</define>
+	<define name="text-outline-style">
+		<element name="text:outline-style">
+			<ref name="text-outline-style-attr"/>
+			<oneOrMore>
+				<ref name="text-outline-level-style"/>
+			</oneOrMore>
+		</element>
+	</define>
+	<define name="text-outline-style-attr">
+		<attribute name="style:name">
+			<ref name="styleName"/>
+		</attribute>
+	</define>
+	<define name="text-outline-level-style">
+		<element name="text:outline-level-style">
+			<ref name="text-outline-level-style-attlist"/>
+			<optional>
+				<ref name="style-list-level-properties"/>
+			</optional>
+			<optional>
+				<ref name="style-text-properties"/>
+			</optional>
+		</element>
+	</define>
+	<define name="text-outline-level-style-attlist">
+		<interleave>
+			<attribute name="text:level">
+				<ref name="positiveInteger"/>
+			</attribute>
+			<optional>
+				<attribute name="text:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<ref name="common-num-format-attlist"/>
+			<ref name="common-num-format-prefix-suffix-attlist"/>
+			<optional>
+				<attribute name="text:display-levels">
+					<ref name="positiveInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:start-value">
+					<ref name="positiveInteger"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="style-graphic-properties">
+		<element name="style:graphic-properties">
+			<ref name="style-graphic-properties-content-strict"/>
+		</element>
+	</define>
+	<define name="style-graphic-properties-content-strict">
+		<ref name="style-graphic-properties-attlist"/>
+		<ref name="style-graphic-fill-properties-attlist"/>
+		<ref name="style-graphic-properties-elements"/>
+	</define>
+	<define name="style-drawing-page-properties">
+		<element name="style:drawing-page-properties">
+			<ref name="style-drawing-page-properties-content-strict"/>
+		</element>
+	</define>
+	<define name="style-drawing-page-properties-content-strict">
+		<ref name="style-graphic-fill-properties-attlist"/>
+		<ref name="style-drawing-page-properties-attlist"/>
+		<ref name="style-drawing-page-properties-elements"/>
+	</define>
+	<define name="draw-gradient">
+		<element name="draw:gradient">
+			<ref name="common-draw-gradient-attlist"/>
+			<ref name="draw-gradient-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="common-draw-gradient-attlist">
+		<interleave>
+			<optional>
+				<attribute name="draw:name">
+					<ref name="styleName"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:display-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<attribute name="draw:style">
+				<ref name="gradient-style"/>
+			</attribute>
+			<optional>
+				<attribute name="draw:cx">
+					<ref name="percent"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:cy">
+					<ref name="percent"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:angle">
+					<ref name="angle"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:border">
+					<ref name="percent"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="gradient-style">
+		<choice>
+			<value>linear</value>
+			<value>axial</value>
+			<value>radial</value>
+			<value>ellipsoid</value>
+			<value>square</value>
+			<value>rectangular</value>
+		</choice>
+	</define>
+	<define name="draw-gradient-attlist">
+		<interleave>
+			<optional>
+				<attribute name="draw:start-color">
+					<ref name="color"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:end-color">
+					<ref name="color"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:start-intensity">
+					<ref name="zeroToHundredPercent"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:end-intensity">
+					<ref name="zeroToHundredPercent"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="svg-linearGradient">
+		<element name="svg:linearGradient">
+			<ref name="common-svg-gradient-attlist"/>
+			<optional>
+				<attribute name="svg:x1">
+					<choice>
+						<ref name="coordinate"/>
+						<ref name="percent"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:y1">
+					<choice>
+						<ref name="coordinate"/>
+						<ref name="percent"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:x2">
+					<choice>
+						<ref name="coordinate"/>
+						<ref name="percent"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:y2">
+					<choice>
+						<ref name="coordinate"/>
+						<ref name="percent"/>
+					</choice>
+				</attribute>
+			</optional>
+			<zeroOrMore>
+				<ref name="svg-stop"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="svg-radialGradient">
+		<element name="svg:radialGradient">
+			<ref name="common-svg-gradient-attlist"/>
+			<optional>
+				<attribute name="svg:cx">
+					<choice>
+						<ref name="coordinate"/>
+						<ref name="percent"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:cy">
+					<choice>
+						<ref name="coordinate"/>
+						<ref name="percent"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:r">
+					<choice>
+						<ref name="coordinate"/>
+						<ref name="percent"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:fx">
+					<choice>
+						<ref name="coordinate"/>
+						<ref name="percent"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:fy">
+					<choice>
+						<ref name="coordinate"/>
+						<ref name="percent"/>
+					</choice>
+				</attribute>
+			</optional>
+			<zeroOrMore>
+				<ref name="svg-stop"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="svg-stop">
+		<element name="svg:stop">
+			<attribute name="svg:offset">
+				<choice>
+					<ref name="double"/>
+					<ref name="percent"/>
+				</choice>
+			</attribute>
+			<optional>
+				<attribute name="svg:stop-color">
+					<ref name="color"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:stop-opacity">
+					<ref name="double"/>
+				</attribute>
+			</optional>
+		</element>
+	</define>
+	<define name="common-svg-gradient-attlist">
+		<interleave>
+			<optional>
+				<attribute name="svg:gradientUnits">
+					<value>objectBoundingBox</value>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:gradientTransform">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:spreadMethod">
+					<choice>
+						<value>pad</value>
+						<value>reflect</value>
+						<value>repeat</value>
+					</choice>
+				</attribute>
+			</optional>
+			<attribute name="draw:name">
+				<ref name="styleName"/>
+			</attribute>
+			<optional>
+				<attribute name="draw:display-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="draw-hatch">
+		<element name="draw:hatch">
+			<ref name="draw-hatch-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="draw-hatch-attlist">
+		<interleave>
+			<attribute name="draw:name">
+				<ref name="styleName"/>
+			</attribute>
+			<optional>
+				<attribute name="draw:display-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<attribute name="draw:style">
+				<choice>
+					<value>single</value>
+					<value>double</value>
+					<value>triple</value>
+				</choice>
+			</attribute>
+			<optional>
+				<attribute name="draw:color">
+					<ref name="color"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:distance">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:rotation">
+					<ref name="angle"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="draw-fill-image">
+		<element name="draw:fill-image">
+			<ref name="draw-fill-image-attlist"/>
+			<attribute name="xlink:type">
+				<value>simple</value>
+			</attribute>
+			<attribute name="xlink:href">
+				<ref name="anyIRI"/>
+			</attribute>
+			<optional>
+				<attribute name="xlink:show">
+					<value>embed</value>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="xlink:actuate">
+					<value>onLoad</value>
+				</attribute>
+			</optional>
+			<empty/>
+		</element>
+	</define>
+	<define name="draw-fill-image-attlist">
+		<interleave>
+			<attribute name="draw:name">
+				<ref name="styleName"/>
+			</attribute>
+			<optional>
+				<attribute name="draw:display-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:width">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:height">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="draw-opacity">
+		<element name="draw:opacity">
+			<ref name="common-draw-gradient-attlist"/>
+			<ref name="draw-opacity-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="draw-opacity-attlist">
+		<optional>
+			<attribute name="draw:start">
+				<ref name="zeroToHundredPercent"/>
+			</attribute>
+		</optional>
+		<optional>
+			<attribute name="draw:end">
+				<ref name="zeroToHundredPercent"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="draw-marker">
+		<element name="draw:marker">
+			<ref name="draw-marker-attlist"/>
+			<ref name="common-draw-viewbox-attlist"/>
+			<ref name="common-draw-path-data-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="draw-marker-attlist">
+		<interleave>
+			<attribute name="draw:name">
+				<ref name="styleName"/>
+			</attribute>
+			<optional>
+				<attribute name="draw:display-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="draw-stroke-dash">
+		<element name="draw:stroke-dash">
+			<ref name="draw-stroke-dash-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="draw-stroke-dash-attlist">
+		<interleave>
+			<attribute name="draw:name">
+				<ref name="styleName"/>
+			</attribute>
+			<optional>
+				<attribute name="draw:display-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:style">
+					<choice>
+						<value>rect</value>
+						<value>round</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:dots1">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:dots1-length">
+					<choice>
+						<ref name="length"/>
+						<ref name="percent"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:dots2">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:dots2-length">
+					<choice>
+						<ref name="length"/>
+						<ref name="percent"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:distance">
+					<choice>
+						<ref name="length"/>
+						<ref name="percent"/>
+					</choice>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="style-presentation-page-layout">
+		<element name="style:presentation-page-layout">
+			<attribute name="style:name">
+				<ref name="styleName"/>
+			</attribute>
+			<optional>
+				<attribute name="style:display-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<zeroOrMore>
+				<ref name="presentation-placeholder"/>
+			</zeroOrMore>
+		</element>
+	</define>
+	<define name="presentation-placeholder">
+		<element name="presentation:placeholder">
+			<attribute name="presentation:object">
+				<ref name="presentation-classes"/>
+			</attribute>
+			<attribute name="svg:x">
+				<choice>
+					<ref name="coordinate"/>
+					<ref name="percent"/>
+				</choice>
+			</attribute>
+			<attribute name="svg:y">
+				<choice>
+					<ref name="coordinate"/>
+					<ref name="percent"/>
+				</choice>
+			</attribute>
+			<attribute name="svg:width">
+				<choice>
+					<ref name="length"/>
+					<ref name="percent"/>
+				</choice>
+			</attribute>
+			<attribute name="svg:height">
+				<choice>
+					<ref name="length"/>
+					<ref name="percent"/>
+				</choice>
+			</attribute>
+			<empty/>
+		</element>
+	</define>
+	<define name="style-page-layout-properties">
+		<element name="style:page-layout-properties">
+			<ref name="style-page-layout-properties-content-strict"/>
+		</element>
+	</define>
+	<define name="style-page-layout-properties-content-strict">
+		<ref name="style-page-layout-properties-attlist"/>
+		<ref name="style-page-layout-properties-elements"/>
+	</define>
+	<define name="style-page-layout-properties-attlist">
+		<interleave>
+			<optional>
+				<attribute name="fo:page-width">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:page-height">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+			<optional>
+				<ref name="common-num-format-attlist"/>
+			</optional>
+			<ref name="common-num-format-prefix-suffix-attlist"/>
+			<optional>
+				<attribute name="style:paper-tray-name">
+					<choice>
+						<value>default</value>
+						<ref name="string"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:print-orientation">
+					<choice>
+						<value>portrait</value>
+						<value>landscape</value>
+					</choice>
+				</attribute>
+			</optional>
+			<ref name="common-horizontal-margin-attlist"/>
+			<ref name="common-vertical-margin-attlist"/>
+			<ref name="common-margin-attlist"/>
+			<ref name="common-border-attlist"/>
+			<ref name="common-border-line-width-attlist"/>
+			<ref name="common-padding-attlist"/>
+			<ref name="common-shadow-attlist"/>
+			<ref name="common-background-color-attlist"/>
+			<optional>
+				<attribute name="style:register-truth-ref-style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:print">
+					<list>
+						<zeroOrMore>
+							<choice>
+								<value>headers</value>
+								<value>grid</value>
+								<value>annotations</value>
+								<value>objects</value>
+								<value>charts</value>
+								<value>drawings</value>
+								<value>formulas</value>
+								<value>zero-values</value>
+							</choice>
+						</zeroOrMore>
+					</list>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:print-page-order">
+					<choice>
+						<value>ttb</value>
+						<value>ltr</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:first-page-number">
+					<choice>
+						<ref name="positiveInteger"/>
+						<value>continue</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:scale-to">
+					<ref name="percent"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:scale-to-pages">
+					<ref name="positiveInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:table-centering">
+					<choice>
+						<value>horizontal</value>
+						<value>vertical</value>
+						<value>both</value>
+						<value>none</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:footnote-max-height">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+			<ref name="common-writing-mode-attlist"/>
+			<optional>
+				<attribute name="style:layout-grid-mode">
+					<choice>
+						<value>none</value>
+						<value>line</value>
+						<value>both</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:layout-grid-standard-mode">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:layout-grid-base-height">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:layout-grid-ruby-height">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:layout-grid-lines">
+					<ref name="positiveInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:layout-grid-base-width">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:layout-grid-color">
+					<ref name="color"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:layout-grid-ruby-below">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:layout-grid-print">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:layout-grid-display">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:layout-grid-snap-to">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="style-page-layout-properties-elements">
+		<interleave>
+			<ref name="style-background-image"/>
+			<ref name="style-columns"/>
+			<ref name="style-footnote-sep"/>
+		</interleave>
+	</define>
+	<define name="style-footnote-sep">
+		<optional>
+			<element name="style:footnote-sep">
+				<ref name="style-footnote-sep-attlist"/>
+				<empty/>
+			</element>
+		</optional>
+	</define>
+	<define name="style-footnote-sep-attlist">
+		<optional>
+			<attribute name="style:width">
+				<ref name="length"/>
+			</attribute>
+		</optional>
+		<optional>
+			<attribute name="style:rel-width">
+				<ref name="percent"/>
+			</attribute>
+		</optional>
+		<optional>
+			<attribute name="style:color">
+				<ref name="color"/>
+			</attribute>
+		</optional>
+		<optional>
+			<attribute name="style:line-style">
+				<ref name="lineStyle"/>
+			</attribute>
+		</optional>
+		<optional>
+			<attribute name="style:adjustment">
+				<choice>
+					<value>left</value>
+					<value>center</value>
+					<value>right</value>
+				</choice>
+			</attribute>
+		</optional>
+		<optional>
+			<attribute name="style:distance-before-sep">
+				<ref name="length"/>
+			</attribute>
+		</optional>
+		<optional>
+			<attribute name="style:distance-after-sep">
+				<ref name="length"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="style-header-footer-properties">
+		<element name="style:header-footer-properties">
+			<ref name="style-header-footer-properties-content-strict"/>
+		</element>
+	</define>
+	<define name="style-header-footer-properties-content-strict">
+		<ref name="style-header-footer-properties-attlist"/>
+		<ref name="style-header-footer-properties-elements"/>
+	</define>
+	<define name="style-header-footer-properties-attlist">
+		<interleave>
+			<optional>
+				<attribute name="svg:height">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:min-height">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+			<ref name="common-horizontal-margin-attlist"/>
+			<ref name="common-vertical-margin-attlist"/>
+			<ref name="common-margin-attlist"/>
+			<ref name="common-border-attlist"/>
+			<ref name="common-border-line-width-attlist"/>
+			<ref name="common-padding-attlist"/>
+			<ref name="common-background-color-attlist"/>
+			<ref name="common-shadow-attlist"/>
+			<optional>
+				<attribute name="style:dynamic-spacing">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="style-header-footer-properties-elements">
+		<ref name="style-background-image"/>
+	</define>
+	<define name="style-text-properties">
+		<element name="style:text-properties">
+			<ref name="style-text-properties-content-strict"/>
+		</element>
+	</define>
+	<define name="style-text-properties-content-strict">
+		<ref name="style-text-properties-attlist"/>
+		<ref name="style-text-properties-elements"/>
+	</define>
+	<define name="style-text-properties-elements">
+		<empty/>
+	</define>
+	<define name="style-text-properties-attlist">
+		<interleave>
+			<optional>
+				<attribute name="fo:font-variant">
+					<ref name="fontVariant"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:text-transform">
+					<choice>
+						<value>none</value>
+						<value>lowercase</value>
+						<value>uppercase</value>
+						<value>capitalize</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:color">
+					<ref name="color"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:use-window-font-color">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:text-outline">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:text-line-through-type">
+					<ref name="lineType"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:text-line-through-style">
+					<ref name="lineStyle"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:text-line-through-width">
+					<ref name="lineWidth"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:text-line-through-color">
+					<choice>
+						<value>font-color</value>
+						<ref name="color"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:text-line-through-text">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:text-line-through-text-style">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:text-position">
+					<list>
+						<choice>
+							<ref name="percent"/>
+							<value>super</value>
+							<value>sub</value>
+						</choice>
+						<optional>
+							<ref name="percent"/>
+						</optional>
+					</list>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:font-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:font-name-asian">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:font-name-complex">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:font-family">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:font-family-asian">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:font-family-complex">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:font-family-generic">
+					<ref name="fontFamilyGeneric"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:font-family-generic-asian">
+					<ref name="fontFamilyGeneric"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:font-family-generic-complex">
+					<ref name="fontFamilyGeneric"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:font-style-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:font-style-name-asian">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:font-style-name-complex">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:font-pitch">
+					<ref name="fontPitch"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:font-pitch-asian">
+					<ref name="fontPitch"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:font-pitch-complex">
+					<ref name="fontPitch"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:font-charset">
+					<ref name="textEncoding"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:font-charset-asian">
+					<ref name="textEncoding"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:font-charset-complex">
+					<ref name="textEncoding"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:font-size">
+					<choice>
+						<ref name="positiveLength"/>
+						<ref name="percent"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:font-size-asian">
+					<choice>
+						<ref name="positiveLength"/>
+						<ref name="percent"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:font-size-complex">
+					<choice>
+						<ref name="positiveLength"/>
+						<ref name="percent"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:font-size-rel">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:font-size-rel-asian">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:font-size-rel-complex">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:script-type">
+					<choice>
+						<value>latin</value>
+						<value>asian</value>
+						<value>complex</value>
+						<value>ignore</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:letter-spacing">
+					<choice>
+						<ref name="length"/>
+						<value>normal</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:language">
+					<ref name="languageCode"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:language-asian">
+					<ref name="languageCode"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:language-complex">
+					<ref name="languageCode"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:country">
+					<ref name="countryCode"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:country-asian">
+					<ref name="countryCode"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:country-complex">
+					<ref name="countryCode"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:script">
+					<ref name="scriptCode"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:script-asian">
+					<ref name="scriptCode"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:script-complex">
+					<ref name="scriptCode"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:rfc-language-tag">
+					<ref name="language"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:rfc-language-tag-asian">
+					<ref name="language"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:rfc-language-tag-complex">
+					<ref name="language"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:font-style">
+					<ref name="fontStyle"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:font-style-asian">
+					<ref name="fontStyle"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:font-style-complex">
+					<ref name="fontStyle"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:font-relief">
+					<choice>
+						<value>none</value>
+						<value>embossed</value>
+						<value>engraved</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:text-shadow">
+					<ref name="shadowType"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:text-underline-type">
+					<ref name="lineType"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:text-underline-style">
+					<ref name="lineStyle"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:text-underline-width">
+					<ref name="lineWidth"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:text-underline-color">
+					<choice>
+						<value>font-color</value>
+						<ref name="color"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:text-overline-type">
+					<ref name="lineType"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:text-overline-style">
+					<ref name="lineStyle"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:text-overline-width">
+					<ref name="lineWidth"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:text-overline-color">
+					<choice>
+						<value>font-color</value>
+						<ref name="color"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:text-overline-mode">
+					<ref name="lineMode"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:font-weight">
+					<ref name="fontWeight"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:font-weight-asian">
+					<ref name="fontWeight"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:font-weight-complex">
+					<ref name="fontWeight"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:text-underline-mode">
+					<ref name="lineMode"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:text-line-through-mode">
+					<ref name="lineMode"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:letter-kerning">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:text-blinking">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<ref name="common-background-color-attlist"/>
+			<optional>
+				<attribute name="style:text-combine">
+					<choice>
+						<value>none</value>
+						<value>letters</value>
+						<value>lines</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:text-combine-start-char">
+					<ref name="character"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:text-combine-end-char">
+					<ref name="character"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:text-emphasize">
+					<choice>
+						<value>none</value>
+						<list>
+							<choice>
+								<value>none</value>
+								<value>accent</value>
+								<value>dot</value>
+								<value>circle</value>
+								<value>disc</value>
+							</choice>
+							<choice>
+								<value>above</value>
+								<value>below</value>
+							</choice>
+						</list>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:text-scale">
+					<ref name="percent"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:text-rotation-angle">
+					<ref name="angle"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:text-rotation-scale">
+					<choice>
+						<value>fixed</value>
+						<value>line-height</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:hyphenate">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:hyphenation-remain-char-count">
+					<ref name="positiveInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:hyphenation-push-char-count">
+					<ref name="positiveInteger"/>
+				</attribute>
+			</optional>
+			<choice>
+				<attribute name="text:display">
+					<value>true</value>
+				</attribute>
+				<attribute name="text:display">
+					<value>none</value>
+				</attribute>
+				<group>
+					<attribute name="text:display">
+						<value>condition</value>
+					</attribute>
+					<attribute name="text:condition">
+						<value>none</value>
+					</attribute>
+				</group>
+				<empty/>
+			</choice>
+		</interleave>
+	</define>
+	<define name="fontVariant">
+		<choice>
+			<value>normal</value>
+			<value>small-caps</value>
+		</choice>
+	</define>
+	<define name="fontFamilyGeneric">
+		<choice>
+			<value>roman</value>
+			<value>swiss</value>
+			<value>modern</value>
+			<value>decorative</value>
+			<value>script</value>
+			<value>system</value>
+		</choice>
+	</define>
+	<define name="fontPitch">
+		<choice>
+			<value>fixed</value>
+			<value>variable</value>
+		</choice>
+	</define>
+	<define name="textEncoding">
+		<data type="string">
+			<param name="pattern">[A-Za-z][A-Za-z0-9._\-]*</param>
+		</data>
+	</define>
+	<define name="fontStyle">
+		<choice>
+			<value>normal</value>
+			<value>italic</value>
+			<value>oblique</value>
+		</choice>
+	</define>
+	<define name="shadowType">
+		<choice>
+			<value>none</value>
+			<ref name="string"/>
+		</choice>
+	</define>
+	<define name="lineType">
+		<choice>
+			<value>none</value>
+			<value>single</value>
+			<value>double</value>
+		</choice>
+	</define>
+	<define name="lineStyle">
+		<choice>
+			<value>none</value>
+			<value>solid</value>
+			<value>dotted</value>
+			<value>dash</value>
+			<value>long-dash</value>
+			<value>dot-dash</value>
+			<value>dot-dot-dash</value>
+			<value>wave</value>
+		</choice>
+	</define>
+	<define name="lineWidth">
+		<choice>
+			<value>auto</value>
+			<value>normal</value>
+			<value>bold</value>
+			<value>thin</value>
+			<value>medium</value>
+			<value>thick</value>
+			<ref name="positiveInteger"/>
+			<ref name="percent"/>
+			<ref name="positiveLength"/>
+		</choice>
+	</define>
+	<define name="fontWeight">
+		<choice>
+			<value>normal</value>
+			<value>bold</value>
+			<value>100</value>
+			<value>200</value>
+			<value>300</value>
+			<value>400</value>
+			<value>500</value>
+			<value>600</value>
+			<value>700</value>
+			<value>800</value>
+			<value>900</value>
+		</choice>
+	</define>
+	<define name="lineMode">
+		<choice>
+			<value>continuous</value>
+			<value>skip-white-space</value>
+		</choice>
+	</define>
+	<define name="style-paragraph-properties">
+		<element name="style:paragraph-properties">
+			<ref name="style-paragraph-properties-content-strict"/>
+		</element>
+	</define>
+	<define name="style-paragraph-properties-content-strict">
+		<ref name="style-paragraph-properties-attlist"/>
+		<ref name="style-paragraph-properties-elements"/>
+	</define>
+	<define name="style-paragraph-properties-attlist">
+		<interleave>
+			<optional>
+				<attribute name="fo:line-height">
+					<choice>
+						<value>normal</value>
+						<ref name="nonNegativeLength"/>
+						<ref name="percent"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:line-height-at-least">
+					<ref name="nonNegativeLength"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:line-spacing">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:font-independent-line-spacing">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<ref name="common-text-align"/>
+			<optional>
+				<attribute name="fo:text-align-last">
+					<choice>
+						<value>start</value>
+						<value>center</value>
+						<value>justify</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:justify-single-word">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:keep-together">
+					<choice>
+						<value>auto</value>
+						<value>always</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:widows">
+					<ref name="nonNegativeInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:orphans">
+					<ref name="nonNegativeInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:tab-stop-distance">
+					<ref name="nonNegativeLength"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:hyphenation-keep">
+					<choice>
+						<value>auto</value>
+						<value>page</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:hyphenation-ladder-count">
+					<choice>
+						<value>no-limit</value>
+						<ref name="positiveInteger"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:register-true">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+	
+			<ref name="common-horizontal-margin-attlist"/>
+			<optional>
+				<attribute name="fo:text-indent">
+					<choice>
+						<ref name="length"/>
+						<ref name="percent"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:auto-text-indent">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<ref name="common-vertical-margin-attlist"/>
+			<ref name="common-margin-attlist"/>
+			<ref name="common-break-attlist"/>
+			<ref name="common-background-color-attlist"/>
+			<ref name="common-border-attlist"/>
+			<ref name="common-border-line-width-attlist"/>
+			<optional>
+				<attribute name="style:join-border">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<ref name="common-padding-attlist"/>
+			<ref name="common-shadow-attlist"/>
+			<ref name="common-keep-with-next-attlist"/>
+			<optional>
+				<attribute name="text:number-lines">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:line-number">
+					<ref name="nonNegativeInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:text-autospace">
+					<choice>
+						<value>none</value>
+						<value>ideograph-alpha</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:punctuation-wrap">
+					<choice>
+						<value>simple</value>
+						<value>hanging</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:line-break">
+					<choice>
+						<value>normal</value>
+						<value>strict</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:vertical-align">
+					<choice>
+						<value>top</value>
+						<value>middle</value>
+						<value>bottom</value>
+						<value>auto</value>
+						<value>baseline</value>
+					</choice>
+				</attribute>
+			</optional>
+			<ref name="common-writing-mode-attlist"/>
+			<optional>
+				<attribute name="style:writing-mode-automatic">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:snap-to-layout-grid">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<ref name="common-page-number-attlist"/>
+			<ref name="common-background-transparency-attlist"/>
+		</interleave>
+	</define>
+	<define name="common-text-align">
+		<optional>
+			<attribute name="fo:text-align">
+				<choice>
+					<value>start</value>
+					<value>end</value>
+					<value>left</value>
+					<value>right</value>
+					<value>center</value>
+					<value>justify</value>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="style-paragraph-properties-elements">
+		<interleave>
+			<ref name="style-tab-stops"/>
+			<ref name="style-drop-cap"/>
+			<ref name="style-background-image"/>
+		</interleave>
+	</define>
+	<define name="style-tab-stops">
+		<optional>
+			<element name="style:tab-stops">
+				<zeroOrMore>
+					<ref name="style-tab-stop"/>
+				</zeroOrMore>
+			</element>
+		</optional>
+	</define>
+	<define name="style-tab-stop">
+		<element name="style:tab-stop">
+			<ref name="style-tab-stop-attlist"/>
+			<empty/>
+		</element>
+	</define>
+	<define name="style-tab-stop-attlist">
+		<interleave>
+			<attribute name="style:position">
+				<ref name="length"/>
+			</attribute>
+			<choice>
+				<optional>
+					<attribute name="style:type">
+						<choice>
+							<value>left</value>
+							<value>center</value>
+							<value>right</value>
+						</choice>
+					</attribute>
+				</optional>
+				<group>
+					<attribute name="style:type">
+						<value>char</value>
+					</attribute>
+					<ref name="style-tab-stop-char-attlist"/>
+				</group>
+			</choice>
+			<optional>
+				<attribute name="style:leader-type">
+					<ref name="lineType"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:leader-style">
+					<ref name="lineStyle"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:leader-width">
+					<ref name="lineWidth"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:leader-color">
+					<choice>
+						<value>font-color</value>
+						<ref name="color"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:leader-text">
+					<ref name="character"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:leader-text-style">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="style-tab-stop-char-attlist">
+		<attribute name="style:char">
+			<ref name="character"/>
+		</attribute>
+	</define>
+	<define name="style-drop-cap">
+		<optional>
+			<element name="style:drop-cap">
+				<ref name="style-drop-cap-attlist"/>
+				<empty/>
+			</element>
+		</optional>
+	</define>
+	<define name="style-drop-cap-attlist">
+		<interleave>
+			<optional>
+				<attribute name="style:length">
+					<choice>
+						<value>word</value>
+						<ref name="positiveInteger"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:lines">
+					<ref name="positiveInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:distance">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:style-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="common-horizontal-margin-attlist">
+		<optional>
+			<attribute name="fo:margin-left">
+				<choice>
+					<ref name="length"/>
+					<ref name="percent"/>
+				</choice>
+			</attribute>
+		</optional>
+		<optional>
+			<attribute name="fo:margin-right">
+				<choice>
+					<ref name="length"/>
+					<ref name="percent"/>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-vertical-margin-attlist">
+		<optional>
+			<attribute name="fo:margin-top">
+				<choice>
+					<ref name="nonNegativeLength"/>
+					<ref name="percent"/>
+				</choice>
+			</attribute>
+		</optional>
+		<optional>
+			<attribute name="fo:margin-bottom">
+				<choice>
+					<ref name="nonNegativeLength"/>
+					<ref name="percent"/>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-margin-attlist">
+		<optional>
+			<attribute name="fo:margin">
+				<choice>
+					<ref name="nonNegativeLength"/>
+					<ref name="percent"/>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-break-attlist">
+		<optional>
+			<attribute name="fo:break-before">
+				<choice>
+					<value>auto</value>
+					<value>column</value>
+					<value>page</value>
+				</choice>
+			</attribute>
+		</optional>
+		<optional>
+			<attribute name="fo:break-after">
+				<choice>
+					<value>auto</value>
+					<value>column</value>
+					<value>page</value>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-background-color-attlist">
+		<optional>
+			<attribute name="fo:background-color">
+				<choice>
+					<value>transparent</value>
+					<ref name="color"/>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="style-background-image">
+		<optional>
+			<element name="style:background-image">
+				<ref name="style-background-image-attlist"/>
+				<choice>
+					<ref name="common-draw-data-attlist"/>
+					<ref name="office-binary-data"/>
+					<empty/>
+				</choice>
+			</element>
+		</optional>
+	</define>
+	<define name="style-background-image-attlist">
+		<interleave>
+			<optional>
+				<attribute name="style:repeat">
+					<choice>
+						<value>no-repeat</value>
+						<value>repeat</value>
+						<value>stretch</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:position">
+					<choice>
+						<value>left</value>
+						<value>center</value>
+						<value>right</value>
+						<value>top</value>
+						<value>bottom</value>
+						<list>
+							<ref name="horiBackPos"/>
+							<ref name="vertBackPos"/>
+						</list>
+						<list>
+							<ref name="vertBackPos"/>
+							<ref name="horiBackPos"/>
+						</list>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:filter-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:opacity">
+					<ref name="zeroToHundredPercent"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="horiBackPos">
+		<choice>
+			<value>left</value>
+			<value>center</value>
+			<value>right</value>
+		</choice>
+	</define>
+	<define name="vertBackPos">
+		<choice>
+			<value>top</value>
+			<value>center</value>
+			<value>bottom</value>
+		</choice>
+	</define>
+	<define name="common-border-attlist">
+		<optional>
+			<attribute name="fo:border">
+				<ref name="string"/>
+			</attribute>
+		</optional>
+		<optional>
+			<attribute name="fo:border-top">
+				<ref name="string"/>
+			</attribute>
+		</optional>
+		<optional>
+			<attribute name="fo:border-bottom">
+				<ref name="string"/>
+			</attribute>
+		</optional>
+		<optional>
+			<attribute name="fo:border-left">
+				<ref name="string"/>
+			</attribute>
+		</optional>
+		<optional>
+			<attribute name="fo:border-right">
+				<ref name="string"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-border-line-width-attlist">
+		<optional>
+			<attribute name="style:border-line-width">
+				<ref name="borderWidths"/>
+			</attribute>
+		</optional>
+		<optional>
+			<attribute name="style:border-line-width-top">
+				<ref name="borderWidths"/>
+			</attribute>
+		</optional>
+		<optional>
+			<attribute name="style:border-line-width-bottom">
+				<ref name="borderWidths"/>
+			</attribute>
+		</optional>
+		<optional>
+			<attribute name="style:border-line-width-left">
+				<ref name="borderWidths"/>
+			</attribute>
+		</optional>
+		<optional>
+			<attribute name="style:border-line-width-right">
+				<ref name="borderWidths"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="borderWidths">
+		<list>
+			<ref name="positiveLength"/>
+			<ref name="positiveLength"/>
+			<ref name="positiveLength"/>
+		</list>
+	</define>
+	<define name="common-padding-attlist">
+		<optional>
+			<attribute name="fo:padding">
+				<ref name="nonNegativeLength"/>
+			</attribute>
+		</optional>
+		<optional>
+			<attribute name="fo:padding-top">
+				<ref name="nonNegativeLength"/>
+			</attribute>
+		</optional>
+		<optional>
+			<attribute name="fo:padding-bottom">
+				<ref name="nonNegativeLength"/>
+			</attribute>
+		</optional>
+		<optional>
+			<attribute name="fo:padding-left">
+				<ref name="nonNegativeLength"/>
+			</attribute>
+		</optional>
+		<optional>
+			<attribute name="fo:padding-right">
+				<ref name="nonNegativeLength"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-shadow-attlist">
+		<optional>
+			<attribute name="style:shadow">
+				<ref name="shadowType"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-keep-with-next-attlist">
+		<optional>
+			<attribute name="fo:keep-with-next">
+				<choice>
+					<value>auto</value>
+					<value>always</value>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-writing-mode-attlist">
+		<optional>
+			<attribute name="style:writing-mode">
+				<choice>
+					<value>lr-tb</value>
+					<value>rl-tb</value>
+					<value>tb-rl</value>
+					<value>tb-lr</value>
+					<value>lr</value>
+					<value>rl</value>
+					<value>tb</value>
+					<value>page</value>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-page-number-attlist">
+		<optional>
+			<attribute name="style:page-number">
+				<choice>
+					<ref name="positiveInteger"/>
+					<value>auto</value>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-background-transparency-attlist">
+		<optional>
+			<attribute name="style:background-transparency">
+				<ref name="zeroToHundredPercent"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="style-ruby-properties">
+		<element name="style:ruby-properties">
+			<ref name="style-ruby-properties-content-strict"/>
+		</element>
+	</define>
+	<define name="style-ruby-properties-content-strict">
+		<ref name="style-ruby-properties-attlist"/>
+		<ref name="style-ruby-properties-elements"/>
+	</define>
+	<define name="style-ruby-properties-elements">
+		<empty/>
+	</define>
+	<define name="style-ruby-properties-attlist">
+		<interleave>
+			<optional>
+				<attribute name="style:ruby-position">
+					<choice>
+						<value>above</value>
+						<value>below</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:ruby-align">
+					<choice>
+						<value>left</value>
+						<value>center</value>
+						<value>right</value>
+						<value>distribute-letter</value>
+						<value>distribute-space</value>
+					</choice>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="style-section-properties">
+		<element name="style:section-properties">
+			<ref name="style-section-properties-content-strict"/>
+		</element>
+	</define>
+	<define name="style-section-properties-content-strict">
+		<ref name="style-section-properties-attlist"/>
+		<ref name="style-section-properties-elements"/>
+	</define>
+	<define name="style-section-properties-attlist">
+		<interleave>
+			<ref name="common-background-color-attlist"/>
+			<ref name="common-horizontal-margin-attlist"/>
+			<optional>
+				<attribute name="style:protect">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<ref name="common-editable-attlist"/>
+			<optional>
+				<attribute name="text:dont-balance-text-columns">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<ref name="common-writing-mode-attlist"/>
+		</interleave>
+	</define>
+	<define name="style-section-properties-elements">
+		<interleave>
+			<ref name="style-background-image"/>
+			<ref name="style-columns"/>
+			<zeroOrMore>
+				<ref name="text-notes-configuration"/>
+			</zeroOrMore>
+		</interleave>
+	</define>
+	<define name="style-columns">
+		<optional>
+			<element name="style:columns">
+				<ref name="style-columns-attlist"/>
+				<optional>
+					<ref name="style-column-sep"/>
+				</optional>
+				<zeroOrMore>
+					<ref name="style-column"/>
+				</zeroOrMore>
+			</element>
+		</optional>
+	</define>
+	<define name="style-columns-attlist">
+		<interleave>
+			<attribute name="fo:column-count">
+				<ref name="positiveInteger"/>
+			</attribute>
+			<optional>
+				<attribute name="fo:column-gap">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="style-column">
+		<element name="style:column">
+			<ref name="style-column-attlist"/>
+		</element>
+	</define>
+	<define name="style-column-attlist">
+		<interleave>
+			<attribute name="style:rel-width">
+				<ref name="relativeLength"/>
+			</attribute>
+			<optional>
+				<attribute name="fo:start-indent">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:end-indent">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:space-before">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:space-after">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="style-column-sep">
+		<element name="style:column-sep">
+			<ref name="style-column-sep-attlist"/>
+		</element>
+	</define>
+	<define name="style-column-sep-attlist">
+		<interleave>
+			<optional>
+				<attribute name="style:style">
+					<choice>
+						<value>none</value>
+						<value>solid</value>
+						<value>dotted</value>
+						<value>dashed</value>
+						<value>dot-dashed</value>
+					</choice>
+				</attribute>
+			</optional>
+			<attribute name="style:width">
+				<ref name="length"/>
+			</attribute>
+			<optional>
+				<attribute name="style:height">
+					<ref name="zeroToHundredPercent"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:vertical-align">
+					<choice>
+						<value>top</value>
+						<value>middle</value>
+						<value>bottom</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:color">
+					<ref name="color"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="style-table-properties">
+		<element name="style:table-properties">
+			<ref name="style-table-properties-content-strict"/>
+		</element>
+	</define>
+	<define name="style-table-properties-content-strict">
+		<ref name="style-table-properties-attlist"/>
+		<ref name="style-table-properties-elements"/>
+	</define>
+	<define name="style-table-properties-attlist">
+		<interleave>
+			<optional>
+				<attribute name="style:width">
+					<ref name="positiveLength"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:rel-width">
+					<ref name="percent"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:align">
+					<choice>
+						<value>left</value>
+						<value>center</value>
+						<value>right</value>
+						<value>margins</value>
+					</choice>
+				</attribute>
+			</optional>
+			<ref name="common-horizontal-margin-attlist"/>
+			<ref name="common-vertical-margin-attlist"/>
+			<ref name="common-margin-attlist"/>
+			<ref name="common-page-number-attlist"/>
+			<ref name="common-break-attlist"/>
+			<ref name="common-background-color-attlist"/>
+			<ref name="common-shadow-attlist"/>
+			<ref name="common-keep-with-next-attlist"/>
+			<optional>
+				<attribute name="style:may-break-between-rows">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="table:border-model">
+					<choice>
+						<value>collapsing</value>
+						<value>separating</value>
+					</choice>
+				</attribute>
+			</optional>
+			<ref name="common-writing-mode-attlist"/>
+			<optional>
+				<attribute name="table:display">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="style-table-properties-elements">
+		<ref name="style-background-image"/>
+	</define>
+	<define name="style-table-column-properties">
+		<element name="style:table-column-properties">
+			<ref name="style-table-column-properties-content-strict"/>
+		</element>
+	</define>
+	<define name="style-table-column-properties-content-strict">
+		<ref name="style-table-column-properties-attlist"/>
+		<ref name="style-table-column-properties-elements"/>
+	</define>
+	<define name="style-table-column-properties-elements">
+		<empty/>
+	</define>
+	<define name="style-table-column-properties-attlist">
+		<interleave>
+			<optional>
+				<attribute name="style:column-width">
+					<ref name="positiveLength"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:rel-column-width">
+					<ref name="relativeLength"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:use-optimal-column-width">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<ref name="common-break-attlist"/>
+		</interleave>
+	</define>
+	<define name="style-table-row-properties">
+		<element name="style:table-row-properties">
+			<ref name="style-table-row-properties-content-strict"/>
+		</element>
+	</define>
+	<define name="style-table-row-properties-content-strict">
+		<ref name="style-table-row-properties-attlist"/>
+		<ref name="style-table-row-properties-elements"/>
+	</define>
+	<define name="style-table-row-properties-attlist">
+		<interleave>
+			<optional>
+				<attribute name="style:row-height">
+					<ref name="positiveLength"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:min-row-height">
+					<ref name="nonNegativeLength"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:use-optimal-row-height">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<ref name="common-background-color-attlist"/>
+			<ref name="common-break-attlist"/>
+			<optional>
+				<attribute name="fo:keep-together">
+					<choice>
+						<value>auto</value>
+						<value>always</value>
+					</choice>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="style-table-row-properties-elements">
+		<ref name="style-background-image"/>
+	</define>
+	<define name="style-table-cell-properties">
+		<element name="style:table-cell-properties">
+			<ref name="style-table-cell-properties-content-strict"/>
+		</element>
+	</define>
+	<define name="style-table-cell-properties-content-strict">
+		<ref name="style-table-cell-properties-attlist"/>
+		<ref name="style-table-cell-properties-elements"/>
+	</define>
+	<define name="style-table-cell-properties-attlist">
+		<interleave>
+			<optional>
+				<attribute name="style:vertical-align">
+					<choice>
+						<value>top</value>
+						<value>middle</value>
+						<value>bottom</value>
+						<value>automatic</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:text-align-source">
+					<choice>
+						<value>fix</value>
+						<value>value-type</value>
+					</choice>
+				</attribute>
+			</optional>
+			<ref name="common-style-direction-attlist"/>
+			<optional>
+				<attribute name="style:glyph-orientation-vertical">
+					<choice>
+						<value>auto</value>
+						<value>0</value>
+						<value>0deg</value>
+						<value>0rad</value>
+						<value>0grad</value>
+					</choice>
+				</attribute>
+			</optional>
+			<ref name="common-writing-mode-attlist"/>
+			<ref name="common-shadow-attlist"/>
+			<ref name="common-background-color-attlist"/>
+			<ref name="common-border-attlist"/>
+			<optional>
+				<attribute name="style:diagonal-tl-br">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:diagonal-tl-br-widths">
+					<ref name="borderWidths"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:diagonal-bl-tr">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:diagonal-bl-tr-widths">
+					<ref name="borderWidths"/>
+				</attribute>
+			</optional>
+			<ref name="common-border-line-width-attlist"/>
+			<ref name="common-padding-attlist"/>
+			<optional>
+				<attribute name="fo:wrap-option">
+					<choice>
+						<value>no-wrap</value>
+						<value>wrap</value>
+					</choice>
+				</attribute>
+			</optional>
+			<ref name="common-rotation-angle-attlist"/>
+			<optional>
+				<attribute name="style:rotation-align">
+					<choice>
+						<value>none</value>
+						<value>bottom</value>
+						<value>top</value>
+						<value>center</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:cell-protect">
+					<choice>
+						<value>none</value>
+						<value>hidden-and-protected</value>
+						<list>
+							<oneOrMore>
+								<choice>
+									<value>protected</value>
+									<value>formula-hidden</value>
+								</choice>
+							</oneOrMore>
+						</list>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:print-content">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:decimal-places">
+					<ref name="nonNegativeInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:repeat-content">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:shrink-to-fit">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="common-style-direction-attlist">
+		<optional>
+			<attribute name="style:direction">
+				<choice>
+					<value>ltr</value>
+					<value>ttb</value>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="style-table-cell-properties-elements">
+		<ref name="style-background-image"/>
+	</define>
+	<define name="common-rotation-angle-attlist">
+		<optional>
+			<attribute name="style:rotation-angle">
+				<ref name="angle"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="style-list-level-properties">
+		<element name="style:list-level-properties">
+			<ref name="style-list-level-properties-content-strict"/>
+		</element>
+	</define>
+	<define name="style-list-level-properties-content-strict">
+		<ref name="style-list-level-properties-attlist"/>
+		<ref name="style-list-level-properties-elements"/>
+	</define>
+	<define name="style-list-level-properties-attlist">
+		<interleave>
+			<ref name="common-text-align"/>
+			<optional>
+				<attribute name="text:space-before">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:min-label-width">
+					<ref name="nonNegativeLength"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:min-label-distance">
+					<ref name="nonNegativeLength"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:font-name">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:width">
+					<ref name="positiveLength"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:height">
+					<ref name="positiveLength"/>
+				</attribute>
+			</optional>
+			<ref name="common-vertical-rel-attlist"/>
+			<ref name="common-vertical-pos-attlist"/>
+			<optional>
+				<attribute name="text:list-level-position-and-space-mode">
+					<choice>
+						<value>label-width-and-position</value>
+						<value>label-alignment</value>
+					</choice>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="style-list-level-properties-elements">
+		<ref name="style-list-level-label-alignment"/>
+	</define>
+	<define name="style-list-level-label-alignment">
+		<optional>
+			<element name="style:list-level-label-alignment">
+				<ref name="style-list-level-label-alignment-attlist"/>
+				<empty/>
+			</element>
+		</optional>
+	</define>
+	<define name="style-list-level-label-alignment-attlist">
+		<interleave>
+			<attribute name="text:label-followed-by">
+				<choice>
+					<value>listtab</value>
+					<value>space</value>
+					<value>nothing</value>
+				</choice>
+			</attribute>
+			<optional>
+				<attribute name="text:list-tab-stop-position">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:text-indent">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:margin-left">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="style-graphic-properties-attlist">
+		<interleave>
+			<optional>
+				<attribute name="draw:stroke">
+					<choice>
+						<value>none</value>
+						<value>dash</value>
+						<value>solid</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:stroke-dash">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:stroke-dash-names">
+					<ref name="styleNameRefs"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:stroke-width">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:stroke-color">
+					<ref name="color"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:marker-start">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:marker-end">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:marker-start-width">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:marker-end-width">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:marker-start-center">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:marker-end-center">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:stroke-opacity">
+					<choice>
+						<data type="double">
+							<param name="minInclusive">0</param>
+							<param name="maxInclusive">1</param>
+						</data>
+						<ref name="zeroToHundredPercent"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:stroke-linejoin">
+					<choice>
+						<value>miter</value>
+						<value>round</value>
+						<value>bevel</value>
+						<value>middle</value>
+						<value>none</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:stroke-linecap">
+					<choice>
+						<value>butt</value>
+						<value>square</value>
+						<value>round</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:symbol-color">
+					<ref name="color"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:animation">
+					<choice>
+						<value>none</value>
+						<value>scroll</value>
+						<value>alternate</value>
+						<value>slide</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:animation-direction">
+					<choice>
+						<value>left</value>
+						<value>right</value>
+						<value>up</value>
+						<value>down</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:animation-start-inside">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:animation-stop-inside">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:animation-repeat">
+					<ref name="nonNegativeInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:animation-delay">
+					<ref name="duration"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:animation-steps">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:auto-grow-width">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:auto-grow-height">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:fit-to-size">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:fit-to-contour">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:textarea-vertical-align">
+					<choice>
+						<value>top</value>
+						<value>middle</value>
+						<value>bottom</value>
+						<value>justify</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:textarea-horizontal-align">
+					<choice>
+						<value>left</value>
+						<value>center</value>
+						<value>right</value>
+						<value>justify</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:wrap-option">
+					<choice>
+						<value>no-wrap</value>
+						<value>wrap</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:shrink-to-fit">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:color-mode">
+					<choice>
+						<value>greyscale</value>
+						<value>mono</value>
+						<value>watermark</value>
+						<value>standard</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:color-inversion">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:luminance">
+					<ref name="zeroToHundredPercent"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:contrast">
+					<ref name="percent"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:gamma">
+					<ref name="percent"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:red">
+					<ref name="signedZeroToHundredPercent"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:green">
+					<ref name="signedZeroToHundredPercent"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:blue">
+					<ref name="signedZeroToHundredPercent"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:image-opacity">
+					<ref name="zeroToHundredPercent"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:shadow">
+					<choice>
+						<value>visible</value>
+						<value>hidden</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:shadow-offset-x">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:shadow-offset-y">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:shadow-color">
+					<ref name="color"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:shadow-opacity">
+					<ref name="zeroToHundredPercent"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:start-line-spacing-horizontal">
+					<ref name="distance"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:start-line-spacing-vertical">
+					<ref name="distance"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:end-line-spacing-horizontal">
+					<ref name="distance"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:end-line-spacing-vertical">
+					<ref name="distance"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:line-distance">
+					<ref name="distance"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:guide-overhang">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:guide-distance">
+					<ref name="distance"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:start-guide">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:end-guide">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:placing">
+					<choice>
+						<value>below</value>
+						<value>above</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:parallel">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:measure-align">
+					<choice>
+						<value>automatic</value>
+						<value>left-outside</value>
+						<value>inside</value>
+						<value>right-outside</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:measure-vertical-align">
+					<choice>
+						<value>automatic</value>
+						<value>above</value>
+						<value>below</value>
+						<value>center</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:unit">
+					<choice>
+						<value>automatic</value>
+						<value>mm</value>
+						<value>cm</value>
+						<value>m</value>
+						<value>km</value>
+						<value>pt</value>
+						<value>pc</value>
+						<value>inch</value>
+						<value>ft</value>
+						<value>mi</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:show-unit">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:decimal-places">
+					<ref name="nonNegativeInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:caption-type">
+					<choice>
+						<value>straight-line</value>
+						<value>angled-line</value>
+						<value>angled-connector-line</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:caption-angle-type">
+					<choice>
+						<value>fixed</value>
+						<value>free</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:caption-angle">
+					<ref name="angle"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:caption-gap">
+					<ref name="distance"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:caption-escape-direction">
+					<choice>
+						<value>horizontal</value>
+						<value>vertical</value>
+						<value>auto</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:caption-escape">
+					<choice>
+						<ref name="length"/>
+						<ref name="percent"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:caption-line-length">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:caption-fit-line-length">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="dr3d:horizontal-segments">
+					<ref name="nonNegativeInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="dr3d:vertical-segments">
+					<ref name="nonNegativeInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="dr3d:edge-rounding">
+					<ref name="percent"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="dr3d:edge-rounding-mode">
+					<choice>
+						<value>correct</value>
+						<value>attractive</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="dr3d:back-scale">
+					<ref name="percent"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="dr3d:depth">
+					<ref name="length"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="dr3d:backface-culling">
+					<choice>
+						<value>enabled</value>
+						<value>disabled</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="dr3d:end-angle">
+					<ref name="angle"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="dr3d:close-front">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="dr3d:close-back">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="dr3d:lighting-mode">
+					<choice>
+						<value>standard</value>
+						<value>double-sided</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="dr3d:normals-kind">
+					<choice>
+						<value>object</value>
+						<value>flat</value>
+						<value>sphere</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="dr3d:normals-direction">
+					<choice>
+						<value>normal</value>
+						<value>inverse</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="dr3d:texture-generation-mode-x">
+					<choice>
+						<value>object</value>
+						<value>parallel</value>
+						<value>sphere</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="dr3d:texture-generation-mode-y">
+					<choice>
+						<value>object</value>
+						<value>parallel</value>
+						<value>sphere</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="dr3d:texture-kind">
+					<choice>
+						<value>luminance</value>
+						<value>intensity</value>
+						<value>color</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="dr3d:texture-filter">
+					<choice>
+						<value>enabled</value>
+						<value>disabled</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="dr3d:texture-mode">
+					<choice>
+						<value>replace</value>
+						<value>modulate</value>
+						<value>blend</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="dr3d:ambient-color">
+					<ref name="color"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="dr3d:emissive-color">
+					<ref name="color"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="dr3d:specular-color">
+					<ref name="color"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="dr3d:diffuse-color">
+					<ref name="color"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="dr3d:shininess">
+					<ref name="percent"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="dr3d:shadow">
+					<choice>
+						<value>visible</value>
+						<value>hidden</value>
+					</choice>
+				</attribute>
+			</optional>
+			<ref name="common-draw-rel-size-attlist"/>
+			<optional>
+				<attribute name="fo:min-width">
+					<choice>
+						<ref name="length"/>
+						<ref name="percent"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:min-height">
+					<choice>
+						<ref name="length"/>
+						<ref name="percent"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:max-height">
+					<choice>
+						<ref name="length"/>
+						<ref name="percent"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:max-width">
+					<choice>
+						<ref name="length"/>
+						<ref name="percent"/>
+					</choice>
+				</attribute>
+			</optional>
+			<ref name="common-horizontal-margin-attlist"/>
+			<ref name="common-vertical-margin-attlist"/>
+			<ref name="common-margin-attlist"/>
+			<optional>
+				<attribute name="style:print-content">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:protect">
+					<choice>
+						<value>none</value>
+						<list>
+							<oneOrMore>
+								<choice>
+									<value>content</value>
+									<value>position</value>
+									<value>size</value>
+								</choice>
+							</oneOrMore>
+						</list>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:horizontal-pos">
+					<choice>
+						<value>left</value>
+						<value>center</value>
+						<value>right</value>
+						<value>from-left</value>
+						<value>inside</value>
+						<value>outside</value>
+						<value>from-inside</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:x">
+					<ref name="coordinate"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:horizontal-rel">
+					<choice>
+						<value>page</value>
+						<value>page-content</value>
+						<value>page-start-margin</value>
+						<value>page-end-margin</value>
+						<value>frame</value>
+						<value>frame-content</value>
+						<value>frame-start-margin</value>
+						<value>frame-end-margin</value>
+						<value>paragraph</value>
+						<value>paragraph-content</value>
+						<value>paragraph-start-margin</value>
+						<value>paragraph-end-margin</value>
+						<value>char</value>
+					</choice>
+				</attribute>
+			</optional>
+			<ref name="common-vertical-pos-attlist"/>
+			<ref name="common-vertical-rel-attlist"/>
+			<ref name="common-text-anchor-attlist"/>
+			<ref name="common-border-attlist"/>
+			<ref name="common-border-line-width-attlist"/>
+			<ref name="common-padding-attlist"/>
+			<ref name="common-shadow-attlist"/>
+			<ref name="common-background-color-attlist"/>
+			<ref name="common-background-transparency-attlist"/>
+			<ref name="common-editable-attlist"/>
+			<optional>
+				<attribute name="style:wrap">
+					<choice>
+						<value>none</value>
+						<value>left</value>
+						<value>right</value>
+						<value>parallel</value>
+						<value>dynamic</value>
+						<value>run-through</value>
+						<value>biggest</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:wrap-dynamic-threshold">
+					<ref name="nonNegativeLength"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:number-wrapped-paragraphs">
+					<choice>
+						<value>no-limit</value>
+						<ref name="positiveInteger"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:wrap-contour">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:wrap-contour-mode">
+					<choice>
+						<value>full</value>
+						<value>outside</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:run-through">
+					<choice>
+						<value>foreground</value>
+						<value>background</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:flow-with-text">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:overflow-behavior">
+					<choice>
+						<value>clip</value>
+						<value>auto-create-new-frame</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:mirror">
+					<choice>
+						<value>none</value>
+						<value>vertical</value>
+						<ref name="horizontal-mirror"/>
+						<list>
+							<value>vertical</value>
+							<ref name="horizontal-mirror"/>
+						</list>
+						<list>
+							<ref name="horizontal-mirror"/>
+							<value>vertical</value>
+						</list>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="fo:clip">
+					<choice>
+						<value>auto</value>
+						<ref name="clipShape"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:wrap-influence-on-position">
+					<choice>
+						<value>iterative</value>
+						<value>once-concurrent</value>
+						<value>once-successive</value>
+					</choice>
+				</attribute>
+			</optional>
+			<ref name="common-writing-mode-attlist"/>
+			<optional>
+				<attribute name="draw:frame-display-scrollbar">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:frame-display-border">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:frame-margin-horizontal">
+					<ref name="nonNegativePixelLength"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:frame-margin-vertical">
+					<ref name="nonNegativePixelLength"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:visible-area-left">
+					<ref name="nonNegativeLength"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:visible-area-top">
+					<ref name="nonNegativeLength"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:visible-area-width">
+					<ref name="positiveLength"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:visible-area-height">
+					<ref name="positiveLength"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:draw-aspect">
+					<choice>
+						<value>content</value>
+						<value>thumbnail</value>
+						<value>icon</value>
+						<value>print-view</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:ole-draw-aspect">
+					<ref name="nonNegativeInteger"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="style-graphic-fill-properties-attlist">
+		<interleave>
+			<optional>
+				<attribute name="draw:fill">
+					<choice>
+						<value>none</value>
+						<value>solid</value>
+						<value>bitmap</value>
+						<value>gradient</value>
+						<value>hatch</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:fill-color">
+					<ref name="color"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:secondary-fill-color">
+					<ref name="color"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:fill-gradient-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:gradient-step-count">
+					<ref name="nonNegativeInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:fill-hatch-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:fill-hatch-solid">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:fill-image-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="style:repeat">
+					<choice>
+						<value>no-repeat</value>
+						<value>repeat</value>
+						<value>stretch</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:fill-image-width">
+					<choice>
+						<ref name="length"/>
+						<ref name="percent"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:fill-image-height">
+					<choice>
+						<ref name="length"/>
+						<ref name="percent"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:fill-image-ref-point-x">
+					<ref name="percent"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:fill-image-ref-point-y">
+					<ref name="percent"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:fill-image-ref-point">
+					<choice>
+						<value>top-left</value>
+						<value>top</value>
+						<value>top-right</value>
+						<value>left</value>
+						<value>center</value>
+						<value>right</value>
+						<value>bottom-left</value>
+						<value>bottom</value>
+						<value>bottom-right</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:tile-repeat-offset">
+					<list>
+						<ref name="zeroToHundredPercent"/>
+						<choice>
+							<value>horizontal</value>
+							<value>vertical</value>
+						</choice>
+					</list>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:opacity">
+					<ref name="zeroToHundredPercent"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:opacity-name">
+					<ref name="styleNameRef"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="svg:fill-rule">
+					<choice>
+						<value>nonzero</value>
+						<value>evenodd</value>
+					</choice>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="style-graphic-properties-elements">
+		<interleave>
+			<optional>
+				<ref name="text-list-style"/>
+			</optional>
+			<ref name="style-background-image"/>
+			<ref name="style-columns"/>
+		</interleave>
+	</define>
+	<define name="common-vertical-pos-attlist">
+		<optional>
+			<attribute name="style:vertical-pos">
+				<choice>
+					<value>top</value>
+					<value>middle</value>
+					<value>bottom</value>
+					<value>from-top</value>
+					<value>below</value>
+				</choice>
+			</attribute>
+		</optional>
+		<optional>
+			<attribute name="svg:y">
+				<ref name="coordinate"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-vertical-rel-attlist">
+		<optional>
+			<attribute name="style:vertical-rel">
+				<choice>
+					<value>page</value>
+					<value>page-content</value>
+					<value>frame</value>
+					<value>frame-content</value>
+					<value>paragraph</value>
+					<value>paragraph-content</value>
+					<value>char</value>
+					<value>line</value>
+					<value>baseline</value>
+					<value>text</value>
+				</choice>
+			</attribute>
+		</optional>
+	</define>
+	<define name="common-editable-attlist">
+		<optional>
+			<attribute name="style:editable">
+				<ref name="boolean"/>
+			</attribute>
+		</optional>
+	</define>
+	<define name="horizontal-mirror">
+		<choice>
+			<value>horizontal</value>
+			<value>horizontal-on-odd</value>
+			<value>horizontal-on-even</value>
+		</choice>
+	</define>
+	<define name="clipShape">
+		<data type="string">
+			<param name="pattern">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}[ ]*\)</param>
+		</data>
+	</define>
+	<define name="nonNegativePixelLength">
+		<data type="string">
+			<param name="pattern">([0-9]+(\.[0-9]*)?|\.[0-9]+)(px)</param>
+		</data>
+	</define>
+	<define name="style-chart-properties">
+		<element name="style:chart-properties">
+			<ref name="style-chart-properties-content-strict"/>
+		</element>
+	</define>
+	<define name="style-chart-properties-content-strict">
+		<ref name="style-chart-properties-attlist"/>
+		<ref name="style-chart-properties-elements"/>
+	</define>
+	<define name="style-chart-properties-elements">
+		<empty/>
+	</define>
+	<define name="style-chart-properties-attlist">
+		<interleave>
+			<optional>
+				<attribute name="chart:scale-text">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:three-dimensional">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:deep">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:right-angled-axes">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<choice>
+				<attribute name="chart:symbol-type">
+					<value>none</value>
+				</attribute>
+				<attribute name="chart:symbol-type">
+					<value>automatic</value>
+				</attribute>
+				<group>
+					<attribute name="chart:symbol-type">
+						<value>named-symbol</value>
+					</attribute>
+					<attribute name="chart:symbol-name">
+						<choice>
+							<value>square</value>
+							<value>diamond</value>
+							<value>arrow-down</value>
+							<value>arrow-up</value>
+							<value>arrow-right</value>
+							<value>arrow-left</value>
+							<value>bow-tie</value>
+							<value>hourglass</value>
+							<value>circle</value>
+							<value>star</value>
+							<value>x</value>
+							<value>plus</value>
+							<value>asterisk</value>
+							<value>horizontal-bar</value>
+							<value>vertical-bar</value>
+						</choice>
+					</attribute>
+				</group>
+				<group>
+					<attribute name="chart:symbol-type">
+						<value>image</value>
+					</attribute>
+					<element name="chart:symbol-image">
+						<attribute name="xlink:href">
+							<ref name="anyIRI"/>
+						</attribute>
+					</element>
+				</group>
+				<empty/>
+			</choice>
+			<optional>
+				<attribute name="chart:symbol-width">
+					<ref name="nonNegativeLength"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:symbol-height">
+					<ref name="nonNegativeLength"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:sort-by-x-values">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:vertical">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:connect-bars">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:gap-width">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:overlap">
+					<ref name="integer"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:group-bars-per-axis">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:japanese-candle-stick">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:interpolation">
+					<choice>
+						<value>none</value>
+						<value>cubic-spline</value>
+						<value>b-spline</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:spline-order">
+					<ref name="positiveInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:spline-resolution">
+					<ref name="positiveInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:pie-offset">
+					<ref name="nonNegativeInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:angle-offset">
+					<ref name="angle"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:hole-size">
+					<ref name="percent"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:lines">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:solid-type">
+					<choice>
+						<value>cuboid</value>
+						<value>cylinder</value>
+						<value>cone</value>
+						<value>pyramid</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:stacked">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:percentage">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:treat-empty-cells">
+					<choice>
+						<value>use-zero</value>
+						<value>leave-gap</value>
+						<value>ignore</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:link-data-style-to-source">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:logarithmic">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:maximum">
+					<ref name="double"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:minimum">
+					<ref name="double"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:origin">
+					<ref name="double"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:interval-major">
+					<ref name="double"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:interval-minor-divisor">
+					<ref name="positiveInteger"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:tick-marks-major-inner">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:tick-marks-major-outer">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:tick-marks-minor-inner">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:tick-marks-minor-outer">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:reverse-direction">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:display-label">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:text-overlap">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="text:line-break">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:label-arrangement">
+					<choice>
+						<value>side-by-side</value>
+						<value>stagger-even</value>
+						<value>stagger-odd</value>
+					</choice>
+				</attribute>
+			</optional>
+			<ref name="common-style-direction-attlist"/>
+			<ref name="common-rotation-angle-attlist"/>
+			<optional>
+				<attribute name="chart:data-label-number">
+					<choice>
+						<value>none</value>
+						<value>value</value>
+						<value>percentage</value>
+						<value>value-and-percentage</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:data-label-text">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:data-label-symbol">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<element name="chart:label-separator">
+					<ref name="text-p"/>
+				</element>
+			</optional>
+			<optional>
+				<attribute name="chart:label-position">
+					<ref name="labelPositions"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:label-position-negative">
+					<ref name="labelPositions"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:visible">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:auto-position">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:auto-size">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:mean-value">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:error-category">
+					<choice>
+						<value>none</value>
+						<value>variance</value>
+						<value>standard-deviation</value>
+						<value>percentage</value>
+						<value>error-margin</value>
+						<value>constant</value>
+						<value>standard-error</value>
+						<value>cell-range</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:error-percentage">
+					<ref name="double"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:error-margin">
+					<ref name="double"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:error-lower-limit">
+					<ref name="double"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:error-upper-limit">
+					<ref name="double"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:error-upper-indicator">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:error-lower-indicator">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:error-lower-range">
+					<ref name="cellRangeAddressList"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:error-upper-range">
+					<ref name="cellRangeAddressList"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:series-source">
+					<choice>
+						<value>columns</value>
+						<value>rows</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:regression-type">
+					<choice>
+						<value>none</value>
+						<value>linear</value>
+						<value>logarithmic</value>
+						<value>exponential</value>
+						<value>power</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:axis-position">
+					<choice>
+						<value>start</value>
+						<value>end</value>
+						<ref name="double"/>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:axis-label-position">
+					<choice>
+						<value>near-axis</value>
+						<value>near-axis-other-side</value>
+						<value>outside-start</value>
+						<value>outside-end</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:tick-mark-position">
+					<choice>
+						<value>at-labels</value>
+						<value>at-axis</value>
+						<value>at-labels-and-axis</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="chart:include-hidden-cells">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="labelPositions">
+		<choice>
+			<value>avoid-overlap</value>
+			<value>center</value>
+			<value>top</value>
+			<value>top-right</value>
+			<value>right</value>
+			<value>bottom-right</value>
+			<value>bottom</value>
+			<value>bottom-left</value>
+			<value>left</value>
+			<value>top-left</value>
+			<value>inside</value>
+			<value>outside</value>
+			<value>near-origin</value>
+		</choice>
+	</define>
+	<define name="style-drawing-page-properties-attlist">
+		<interleave>
+			<optional>
+				<attribute name="presentation:transition-type">
+					<choice>
+						<value>manual</value>
+						<value>automatic</value>
+						<value>semi-automatic</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:transition-style">
+					<choice>
+						<value>none</value>
+						<value>fade-from-left</value>
+						<value>fade-from-top</value>
+						<value>fade-from-right</value>
+						<value>fade-from-bottom</value>
+						<value>fade-from-upperleft</value>
+						<value>fade-from-upperright</value>
+						<value>fade-from-lowerleft</value>
+						<value>fade-from-lowerright</value>
+						<value>move-from-left</value>
+						<value>move-from-top</value>
+						<value>move-from-right</value>
+						<value>move-from-bottom</value>
+						<value>move-from-upperleft</value>
+						<value>move-from-upperright</value>
+						<value>move-from-lowerleft</value>
+						<value>move-from-lowerright</value>
+						<value>uncover-to-left</value>
+						<value>uncover-to-top</value>
+						<value>uncover-to-right</value>
+						<value>uncover-to-bottom</value>
+						<value>uncover-to-upperleft</value>
+						<value>uncover-to-upperright</value>
+						<value>uncover-to-lowerleft</value>
+						<value>uncover-to-lowerright</value>
+						<value>fade-to-center</value>
+						<value>fade-from-center</value>
+						<value>vertical-stripes</value>
+						<value>horizontal-stripes</value>
+						<value>clockwise</value>
+						<value>counterclockwise</value>
+						<value>open-vertical</value>
+						<value>open-horizontal</value>
+						<value>close-vertical</value>
+						<value>close-horizontal</value>
+						<value>wavyline-from-left</value>
+						<value>wavyline-from-top</value>
+						<value>wavyline-from-right</value>
+						<value>wavyline-from-bottom</value>
+						<value>spiralin-left</value>
+						<value>spiralin-right</value>
+						<value>spiralout-left</value>
+						<value>spiralout-right</value>
+						<value>roll-from-top</value>
+						<value>roll-from-left</value>
+						<value>roll-from-right</value>
+						<value>roll-from-bottom</value>
+						<value>stretch-from-left</value>
+						<value>stretch-from-top</value>
+						<value>stretch-from-right</value>
+						<value>stretch-from-bottom</value>
+						<value>vertical-lines</value>
+						<value>horizontal-lines</value>
+						<value>dissolve</value>
+						<value>random</value>
+						<value>vertical-checkerboard</value>
+						<value>horizontal-checkerboard</value>
+						<value>interlocking-horizontal-left</value>
+						<value>interlocking-horizontal-right</value>
+						<value>interlocking-vertical-top</value>
+						<value>interlocking-vertical-bottom</value>
+						<value>fly-away</value>
+						<value>open</value>
+						<value>close</value>
+						<value>melt</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:transition-speed">
+					<ref name="presentationSpeeds"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="smil:type">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="smil:subtype">
+					<ref name="string"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="smil:direction">
+					<choice>
+						<value>forward</value>
+						<value>reverse</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="smil:fadeColor">
+					<ref name="color"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:duration">
+					<ref name="duration"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:visibility">
+					<choice>
+						<value>visible</value>
+						<value>hidden</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="draw:background-size">
+					<choice>
+						<value>full</value>
+						<value>border</value>
+					</choice>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:background-objects-visible">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:background-visible">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:display-header">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:display-footer">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:display-page-number">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+			<optional>
+				<attribute name="presentation:display-date-time">
+					<ref name="boolean"/>
+				</attribute>
+			</optional>
+		</interleave>
+	</define>
+	<define name="style-drawing-page-properties-elements">
+		<optional>
+			<ref name="presentation-sound"/>
+		</optional>
+	</define>
+	<define name="string">
+		<data type="string"/>
+	</define>
+	<define name="date">
+		<data type="date"/>
+	</define>
+	<define name="time">
+		<data type="time"/>
+	</define>
+	<define name="dateTime">
+		<data type="dateTime"/>
+	</define>
+	<define name="duration">
+		<data type="duration"/>
+	</define>
+	<define name="integer">
+		<data type="integer"/>
+	</define>
+	<define name="nonNegativeInteger">
+		<data type="nonNegativeInteger"/>
+	</define>
+	<define name="positiveInteger">
+		<data type="positiveInteger"/>
+	</define>
+	<define name="double">
+		<data type="double"/>
+	</define>
+	<define name="anyURI">
+		<data type="anyURI"/>
+	</define>
+	<define name="base64Binary">
+		<data type="base64Binary"/>
+	</define>
+	<define name="ID">
+		<data type="ID"/>
+	</define>
+	<define name="IDREF">
+		<data type="IDREF"/>
+	</define>
+	<define name="IDREFS">
+		<data type="IDREFS"/>
+	</define>
+	<define name="NCName">
+		<data type="NCName"/>
+	</define>
+	<define name="boolean">
+		<choice>
+			<value>true</value>
+			<value>false</value>
+		</choice>
+	</define>
+	<define name="dateOrDateTime">
+		<choice>
+			<data type="date"/>
+			<data type="dateTime"/>
+		</choice>
+	</define>
+	<define name="timeOrDateTime">
+		<choice>
+			<data type="time"/>
+			<data type="dateTime"/>
+		</choice>
+	</define>
+	<define name="language">
+		<data type="language"/>
+	</define>
+	<define name="countryCode">
+		<data type="token">
+			<param name="pattern">[A-Za-z0-9]{1,8}</param>
+		</data>
+	</define>
+	<define name="languageCode">
+		<data type="token">
+			<param name="pattern">[A-Za-z]{1,8}</param>
+		</data>
+	</define>
+	<define name="scriptCode">
+		<data type="token">
+			<param name="pattern">[A-Za-z0-9]{1,8}</param>
+		</data>
+	</define>
+	<define name="character">
+		<data type="string">
+			<param name="length">1</param>
+		</data>
+	</define>
+	<define name="length">
+		<data type="string">
+			<param name="pattern">-?([0-9]+(\.[0-9]*)?|\.[0-9]+)((cm)|(mm)|(in)|(pt)|(pc)|(px))</param>
+		</data>
+	</define>
+	<define name="nonNegativeLength">
+		<data type="string">
+			<param name="pattern">([0-9]+(\.[0-9]*)?|\.[0-9]+)((cm)|(mm)|(in)|(pt)|(pc)|(px))</param>
+		</data>
+	</define>
+	<define name="positiveLength">
+		<data type="string">
+			<param name="pattern">([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))</param>
+		</data>
+	</define>
+	<define name="percent">
+		<data type="string">
+			<param name="pattern">-?([0-9]+(\.[0-9]*)?|\.[0-9]+)%</param>
+		</data>
+	</define>
+	<define name="zeroToHundredPercent">
+		<data type="string">
+			<param name="pattern">([0-9]?[0-9](\.[0-9]*)?|100(\.0*)?|\.[0-9]+)%</param>
+		</data>
+	</define>
+	<define name="signedZeroToHundredPercent">
+		<data type="string">
+			<param name="pattern">-?([0-9]?[0-9](\.[0-9]*)?|100(\.0*)?|\.[0-9]+)%</param>
+		</data>
+	</define>
+	<define name="relativeLength">
+		<data type="string">
+			<param name="pattern">[0-9]+\*</param>
+		</data>
+	</define>
+	<define name="coordinate">
+		<ref name="length"/>
+	</define>
+	<define name="distance">
+		<ref name="length"/>
+	</define>
+	<define name="color">
+		<data type="string">
+			<param name="pattern">#[0-9a-fA-F]{6}</param>
+		</data>
+	</define>
+	<define name="angle">
+		<data type="string"/>
+	</define>
+	<define name="CURIE">
+		<data type="string">
+			<param name="pattern">(([\i-[:]][\c-[:]]*)?:)?.+</param>
+			<param name="minLength">1</param>
+		</data>
+	</define>
+	<define name="CURIEs">
+		<list>
+			<oneOrMore>
+				<ref name="CURIE"/>
+			</oneOrMore>
+		</list>
+	</define>
+	<define name="SafeCURIE">
+		<data type="string">
+			<param name="pattern">\[(([\i-[:]][\c-[:]]*)?:)?.+\]</param>
+			<param name="minLength">3</param>
+		</data>
+	</define>
+	<define name="URIorSafeCURIE">
+		<choice>
+			<ref name="anyURI"/>
+			<ref name="SafeCURIE"/>
+		</choice>
+	</define>
+	<define name="styleName">
+		<data type="NCName"/>
+	</define>
+	<define name="styleNameRef">
+		<choice>
+			<data type="NCName"/>
+			<empty/>
+		</choice>
+	</define>
+	<define name="styleNameRefs">
+		<list>
+			<zeroOrMore>
+				<data type="NCName"/>
+			</zeroOrMore>
+		</list>
+	</define>
+	<define name="variableName">
+		<data type="string"/>
+	</define>
+	<define name="targetFrameName">
+		<choice>
+			<value>_self</value>
+			<value>_blank</value>
+			<value>_parent</value>
+			<value>_top</value>
+			<ref name="string"/>
+		</choice>
+	</define>
+	<define name="valueType">
+		<choice>
+			<value>float</value>
+			<value>time</value>
+			<value>date</value>
+			<value>percentage</value>
+			<value>currency</value>
+			<value>boolean</value>
+			<value>string</value>
+		</choice>
+	</define>
+	<define name="points">
+		<data type="string">
+			<param name="pattern">-?[0-9]+,-?[0-9]+([ ]+-?[0-9]+,-?[0-9]+)*</param>
+		</data>
+	</define>
+	<define name="pathData">
+		<data type="string"/>
+	</define>
+	<define name="vector3D">
+		<data type="string">
+			<param name="pattern">\([ ]*-?([0-9]+(\.[0-9]*)?|\.[0-9]+)([ ]+-?([0-9]+(\.[0-9]*)?|\.[0-9]+)){2}[ ]*\)</param>
+		</data>
+	</define>
+	<define name="namespacedToken">
+		<data type="QName">
+			<param name="pattern">[^:]+:[^:]+</param>
+		</data>
+	</define>
+	<define name="anyIRI">
+		<data type="anyURI"/>
+		<dc:description>An IRI-reference as defined in [RFC3987]. See ODF 1.2 Part 1 section 18.3.</dc:description> 
+	</define>
+	<define name="anyAttListOrElements">
+		<zeroOrMore>
+			<attribute>
+				<anyName/>
+				<text/>
+			</attribute>
+		</zeroOrMore>
+		<ref name="anyElements"/>
+	</define>
+	<define name="anyElements">
+		<zeroOrMore>
+			<element>
+				<anyName/>
+				<mixed>
+					<ref name="anyAttListOrElements"/>
+				</mixed>
+			</element>
+		</zeroOrMore>
+	</define>
+</grammar>

+ 298 - 0
contrib/odt/README.org

@@ -0,0 +1,298 @@
+#+TITLE:	OpenDocumentText Exporter for Orgmode
+#+AUTHOR:	Jambunathan K 
+#+EMAIL:	emacs-orgmode@gnu.org
+#+DATE:		%Y-%m-%d %T %Z
+#+DESCRIPTION:
+#+KEYWORDS:
+#+LANGUAGE:  en
+#+OPTIONS:   H:3 num:t toc:t \n:nil @:t ::t |:t ^:t -:t f:t *:t <:t
+#+OPTIONS:   TeX:t LaTeX:dvipng skip:nil d:nil todo:t pri:nil tags:not-in-toc
+
+#+EXPORT_SELECT_TAGS: export
+#+EXPORT_EXCLUDE_TAGS: noexport
+#+LINK_UP:   
+#+LINK_HOME: 
+#+XSLT:
+
+
+* Summary
+  
+  This package adds support for exporting of Orgmode files to
+  OpenDocumentText.
+
+  The latest version of this document is available at 
+
+# - Text version :: http://repo.or.cz/w/org-mode/org-jambu.git/blob_plain/HEAD:/doc/ReleaseNotes.org
+  - Web page :: http://repo.or.cz/w/org-mode/org-jambu.git/blob_plain/HEAD:/packages/README.html
+
+* Compatibility with Official Orgmode
+  :PROPERTIES:
+  :CUSTOM_ID: compatibility
+  :END:
+
+  This release is is as good as *org-20110613 (git commit c4737ae)*
+  with *only* the following changes left out.
+
+  | git commit | Description                                                            |
+  |------------+------------------------------------------------------------------------|
+  | 2f50b1     | add an alternate for inline images                                     |
+  | 49e6bc     | Fix for html & docbook export of desc list items                       |
+  | a201b1     | Fix HTML export of footnotes with lists, tables, quotes.               |
+  | 9f57b8     | Mixed export of numbered and unnumbered sections in HTML               |
+  | 438536     | Revert "Change underscores to hyphens in section labels"               |
+  | 33bae1     | Revert "Fix markup problems when using references in source fragments" |
+  | fa12fe     | Revert "org-html.el: Fix export of table.el tables."                   |
+  | f72541     | Revert "HTML export -- Allow to change the name of the global DIV"     |
+
+* Implementation Details
+
+  This package enhances Orgmode in the following manner:
+  1. A new line-oriented generic exporter
+  2. All new html exporter re-implemented as a plugin to (1).
+  3. A odt backend as a plugin to (1).
+
+  Feature (1) is provided by =org-lparse.el=.
+  Feture (2) is provided by =lisp/org-html.el=.
+  Feature (3) is provided by =lisp/org-odt.el=.
+
+  The new html exporter is feature-compatible with the official html
+  exporter.
+
+* Notes for Reviewers and Fellow Developers
+  
+  =org-lparse= is the entry point for the generic exporter and
+  drives html and odt backends. 
+
+  =org-do-lparse= is the genericized version of the original
+  =org-export-as-html= routine.
+
+  =C-h v org-lparse-native-backends= is a good starting point for
+  exploring the generic exporter.
+
+* Package Layout
+  
+  - odt/README.org
+  - odt/lisp/
+    - org-lparse.el :: Generic line-oriented exporter
+    - org-xhtml.el :: All new XHTML exporter
+    - org-odt.el :: The OpenDocumentText backend
+  - contrib/odt/tests
+    - org-mode-unicorn.png :: 
+    - test.org :: Sample files for validating the exporter
+  - contrib/odt/styles
+    - OrgOdtAutomaticStyles.xml :: The default styles.xml file used by
+         the OpenDocumentText exporter.
+    - OrgOdtStyles.xml :: Automatic styles inserted in to content.xml
+  - odt/BasicODConverter/
+    - BasicODConverter-0.8.0.oxt :: OpenOffice extension for
+         converting between various file formats supported by
+         OpenOffice. A poor clone of unoconv.
+    - Filters.bas :: 
+    - Main.bas :: StarBasic files that contribute to the above
+                  extension.
+  - odt/OASIS
+    - OpenDocument-v1.2-cs01-schema.rng :: Copy of
+	 http://docs.oasis-open.org/office/v1.2/cs01/OpenDocument-v1.2-cs01-schema.rng
+    - OpenDocument-v1.2-cs01-manifest-schema.rng :: Copy of
+	 http://docs.oasis-open.org/office/v1.2/cs01/OpenDocument-v1.2-cs01-manifest-schema.rng
+    - OpenDocument-schema-v1.1.rng :: Copy of
+	 http://docs.oasis-open.org/office/v1.1/OS/OpenDocument-schema-v1.1.rng
+  - odt/etc/schema
+    - od-schema-v1.1.rnc :: 
+    - od-manifest-schema-v1.2-cs01.rnc :: 
+    - od-schema-v1.2-cs01.rnc :: rnc files for above rng
+         files. Generated using [[http://www.thaiopensource.com/relaxng/trang.html][trang]].
+
+    - schemas.xml :: schema location file for auto validating the XML
+                     files that form part of an OpenDocument
+                     file. Refer =C-h f
+                     rng-set-schema-file-and-validate= FILENAME and
+                     =C-h f rng-what-schema=. 
+
+    All the above files have been submitted for inclusing in Emacs
+    proper. See
+    http://lists.gnu.org/archive/html/emacs-devel/2011-06/msg00671.html
+
+* Obtaining OpenDocumentExporter
+
+  The OpenDocumentExporter could be downloaded by one of the following
+  methods:
+
+** git checkout
+   - Checkout URL ::  http://repo.or.cz/r/org-mode/org-jambu.git
+   - Web URL :: http://repo.or.cz/w/org-mode/org-jambu.git/
+
+** Conventional tar
+   - Download URL :: http://repo.or.cz/w/org-mode/org-jambu.git/snapshot/HEAD.tar.gz
+
+** ELPA Tarball
+   - Archive URL :: http://repo.or.cz/w/org-mode/org-jambu.git/blob_plain/HEAD:/packages/
+ 		      
+   The tarball is distributed as an org-odt package (for example
+   =org-odt-20110519.tar=).
+
+   You need to have an *Org build >= org-20110626* for the exporter to
+   function properly.
+
+   The most hassle-free way to download and install org-odt is through
+   ELPA.
+
+   More help on all the above methods are available at
+   http://orgmode.org/worg/org-faq.html.
+
+* Test driving the Exporter
+
+  Once the package is installed in to your load-path, use 
+  =C-u M-x org-odt-unit-test= to visit an example org file bundled
+  with this package.
+
+  1. Use =C-c C-e O= to export the buffer to OpenDocumentText.
+  2. Use =M-x org-lparse= or =M-x org-lparse-and-open= for
+     exporting to MS doc format.
+  3. Use =M-x org-export-convert= on a buffer visiting odt file.
+
+  Steps 2 and 3 require that a converter be installed on the
+  system. See [[#converter][this FAQ entry]] for more information on this.
+
+  - Misc. Info :: This package re-implements HTML exporter as
+                  well. You will see the following warning message
+                  *"Exporting to HTML using org-lparse..."* while you
+                  are exporting using new HTML exporter.
+		  
+  - Hint :: If you are using BasicODConverter, you can use steps 2 and
+            3 for exporting an Org outline to presentation formats
+            like OpenOffice Impress (odp) and Microsoft Powerpoint
+            (ppt)
+  - Know Issues :: If you have dvipng installed it is possible that
+                   the exported odt file has embedded images
+                   clobbered. This is *not* a bug in the exporter but
+                   seems like a bug in the package installer. See
+                   http://lists.gnu.org/archive/html/bug-gnu-emacs/2011-06/msg00445.html.
+
+* Bug Reports and Feature Requests
+
+  Send in your bug report and feature requests to
+  =emacs-orgmode@gnu.org= or to =kjambunathan at gmail dot com=. 
+
+  Please search the Mailing List Archive -
+  http://lists.gnu.org/archive/html/emacs-orgmode/ for =org-odt=
+  before posting a question or a request either to me or the mailing
+  list.
+
+  Posting to mailing list is preferable. It is possible that your post
+  helps another user out there.
+
+* Possible Feature Enhacmentes
+
+** TODO Support for fontification of babel blocks
+   May require enhancements to htmlfontify or htmlize packages.
+
+** TODO Enhance table.el to support Odt format
+
+** TODO Add support for exporting to odp
+   
+   Use OpenOffice's File->Send->{Outline to Presentation |
+   AutoAbstract to Presentation}. Also see
+
+   http://wiki.services.openoffice.org/wiki/Documentation/OOoAuthors_User_Manual/Impress_Guide/Creating_slides_from_an_outline
+
+** TODO Support for generating MathML for LaTeX fragments
+   See http://lists.gnu.org/archive/html/emacs-orgmode/2011-03/msg01755.html
+
+* Frequently Asked Questions
+
+** What features does the OpenDocumentExporter support?
+
+   At the moment, the exporter supports the following most commonly
+   used features of Org
+
+   - Various Character Styles
+   - Various Paragraph Styles (including Source Blocks)
+   - Embedded ODT
+   - Embedded MathML
+   - Numbered, Bulleted and Description lists
+   - Embedding and Resizing of Images including embedding of LaTeX fragments
+   - Fuzzy, Dedicated and Radio Targets and Links
+   - Tables
+   - Footnotes
+   - Outline Numbering and Table Of Contents
+   - Special markups for elements like TODOs, Timestamps and Tags
+
+   The exporter is quite usable and stable.
+
+** Is OpenDocumentExporter part of Orgmode or Emacs?
+
+   Not yet. I have expressed my willingness to merge this package in
+   to official Orgmode and thus to Emacs. The current maintainer of
+   Orgmode - =Bastien Guerry bzg at gnu.org= - has agreed to consider
+   the package for integration. If you are interested in having this
+   package merged with Orgmode send your requests to the maintainer.
+
+   For the sake of record, I am the sole author of the changes
+   included in this package and I am consenting to have this work or
+   derivative works make it's way into Emacs proper. My FSF copyright
+   assignment number is #618390.
+
+** How does it compare with official Orgmode
+   For information about the latest release see [[#compatibility][this.]] For general
+   information refer
+   http://lists.gnu.org/archive/html/emacs-orgmode/2011-05/msg00751.html.
+
+** How can I export via command line?
+
+   See the following post
+   http://lists.gnu.org/archive/html/emacs-orgmode/2011-04/msg00952.html.
+
+** How can I export to doc or docx format?
+   :PROPERTIES:
+   :CUSTOM_ID: converter
+   :END:
+   Here are the steps.
+
+*** Install the converter program. 
+
+    There are numerous converters that are available: =unoconv=,
+    =PyODConverter=, =JODConverter= etc etc.
+
+    org-odt is distributed with it's own converter
+    =BasicODConverter=. It is /Basic/ not only because it is
+    implemented in StarBasic but is a a very basic clone of unoconv.
+
+**** BasicODConverter
+     Install [[http://repo.or.cz/w/org-mode/org-jambu.git/blob/HEAD:/contrib/odt/BasicODConverter-0.8.0.oxt][BasicODConverter]] as a OpenOffice Extension.
+
+**** unoconv
+
+     If you prefer using unoconv as the converter add the following
+     snippet to your =.emacs=.
+
+#+begin_src emacs-lisp
+  ;; not tested with unoconv
+  (require 'org-html)
+  (setq org-export-convert-process '("unoconv" "-f" "%f" "-o" "%d" "%i"))
+#+end_src
+
+*** Convert using new interactive functions
+
+**** Export an Org buffer
+     Use =M-x org-lparse= or =M-x org-lparse-and-open= and follow
+     the prompts. Use TAB for completion if you are not already using
+     ido.
+     
+***** Additional Note 
+     1. If you are using BasicODConverter you can export an Org file
+        to =odp= or =ppt= formats.
+     2. You can convert csv files to xls format
+     3. OpenOffice doesn't ship with mediawiki or docbook export
+       	filters by default. So make sure that these extensions are
+       	installed before trying out these converters.
+
+**** Export an existing file
+
+     Use =M-x org-export-convert= to convert an existing file.
+
+
+** How can I apply custom styles?
+
+   See this thread:
+   http://lists.gnu.org/archive/html/emacs-orgmode/2011-03/msg01460.html

+ 88 - 0
contrib/odt/etc/schema/od-manifest-schema-v1.2-cs01.rnc

@@ -0,0 +1,88 @@
+# Open Document Format for Office Applications (OpenDocument) Version 1.2
+# Committee Specification (CS) 01, 17 March 2011
+# Manifest Relax-NG Schema
+# 
+# Copyright (c) OASIS Open 2002-2011. All Rights Reserved.
+# 
+# All capitalized terms in the following text have the meanings assigned to them
+# in the OASIS Intellectual Property Rights Policy (the "OASIS IPR Policy"). The
+# full Policy may be found at the OASIS website.
+# 
+# This document and translations of it may be copied and furnished to others, and
+# derivative works that comment on or otherwise explain it or assist in its
+# implementation may be prepared, copied, published, and distributed, in whole or
+# in part, without restriction of any kind, provided that the above copyright
+# notice and this section are included on all such copies and derivative works.
+# However, this document itself may not be modified in any way, including by
+# removing the copyright notice or references to OASIS, except as needed for the
+# purpose of developing any document or deliverable produced by an OASIS
+# Technical Committee (in which case the rules applicable to copyrights, as set
+# forth in the OASIS IPR Policy, must be followed) or as required to translate it
+# into languages other than English.
+# 
+# The limited permissions granted above are perpetual and will not be revoked by
+# OASIS or its successors or assigns.
+# 
+# This document and the information contained herein is provided on an "AS IS"
+# basis and OASIS DISCLAIMS ALL WARRANTIES, EXPRESS OR IMPLIED, INCLUDING BUT NOT
+# LIMITED TO ANY WARRANTY THAT THE USE OF THE INFORMATION HEREIN WILL NOT
+# INFRINGE ANY OWNERSHIP RIGHTS OR ANY IMPLIED WARRANTIES OF MERCHANTABILITY OR
+# FITNESS FOR A PARTICULAR PURPOSE. 
+
+namespace manifest =
+  "urn:oasis:names:tc:opendocument:xmlns:manifest:1.0"
+
+start = manifest
+manifest = element manifest:manifest { manifest-attlist, file-entry+ }
+manifest-attlist = attribute manifest:version { "1.2" }
+file-entry =
+  element manifest:file-entry { file-entry-attlist, encryption-data? }
+file-entry-attlist =
+  attribute manifest:full-path { \string }
+  & attribute manifest:size { nonNegativeInteger }?
+  & attribute manifest:media-type { \string }
+  & attribute manifest:preferred-view-mode {
+      "edit" | "presentation-slide-show" | "read-only" | namespacedToken
+    }?
+  & attribute manifest:version { \string }?
+encryption-data =
+  element manifest:encryption-data {
+    encryption-data-attlist,
+    algorithm,
+    start-key-generation?,
+    key-derivation
+  }
+encryption-data-attlist =
+  attribute manifest:checksum-type { "SHA1/1K" | anyURI }
+  & attribute manifest:checksum { base64Binary }
+algorithm =
+  element manifest:algorithm { algorithm-attlist, anyElements }
+algorithm-attlist =
+  attribute manifest:algorithm-name { "Blowfish CFB" | anyURI }
+  & attribute manifest:initialisation-vector { base64Binary }
+anyAttListOrElements =
+  attribute * { text }*,
+  anyElements
+anyElements =
+  element * {
+    mixed { anyAttListOrElements }
+  }*
+key-derivation =
+  element manifest:key-derivation { key-derivation-attlist, empty }
+key-derivation-attlist =
+  attribute manifest:key-derivation-name { "PBKDF2" | anyURI }
+  & attribute manifest:salt { base64Binary }
+  & attribute manifest:iteration-count { nonNegativeInteger }
+  & attribute manifest:key-size { nonNegativeInteger }?
+start-key-generation =
+  element manifest:start-key-generation {
+    start-key-generation-attlist, empty
+  }
+start-key-generation-attlist =
+  attribute manifest:start-key-generation-name { "SHA1" | anyURI }
+  & attribute manifest:key-size { nonNegativeInteger }?
+base64Binary = xsd:base64Binary
+namespacedToken = xsd:QName { pattern = "[^:]+:[^:]+" }
+nonNegativeInteger = xsd:nonNegativeInteger
+\string = xsd:string
+anyURI = xsd:anyURI

+ 6444 - 0
contrib/odt/etc/schema/od-schema-v1.1.rnc

@@ -0,0 +1,6444 @@
+# OASIS OpenDocument v1.1
+# OASIS Standard, 1 Feb 2007
+# Relax-NG Schema
+# 
+# $Id$
+# 
+# © 2002-2007 OASIS Open
+# © 1999-2007 Sun Microsystems, Inc.
+
+namespace a = "http://relaxng.org/ns/compatibility/annotations/1.0"
+namespace anim = "urn:oasis:names:tc:opendocument:xmlns:animation:1.0"
+namespace chart = "urn:oasis:names:tc:opendocument:xmlns:chart:1.0"
+namespace config = "urn:oasis:names:tc:opendocument:xmlns:config:1.0"
+namespace dc = "http://purl.org/dc/elements/1.1/"
+namespace dr3d = "urn:oasis:names:tc:opendocument:xmlns:dr3d:1.0"
+namespace draw = "urn:oasis:names:tc:opendocument:xmlns:drawing:1.0"
+namespace fo =
+  "urn:oasis:names:tc:opendocument:xmlns:xsl-fo-compatible:1.0"
+namespace form = "urn:oasis:names:tc:opendocument:xmlns:form:1.0"
+namespace math = "http://www.w3.org/1998/Math/MathML"
+namespace meta = "urn:oasis:names:tc:opendocument:xmlns:meta:1.0"
+namespace number = "urn:oasis:names:tc:opendocument:xmlns:datastyle:1.0"
+namespace office = "urn:oasis:names:tc:opendocument:xmlns:office:1.0"
+namespace presentation =
+  "urn:oasis:names:tc:opendocument:xmlns:presentation:1.0"
+namespace script = "urn:oasis:names:tc:opendocument:xmlns:script:1.0"
+namespace smil =
+  "urn:oasis:names:tc:opendocument:xmlns:smil-compatible:1.0"
+namespace style = "urn:oasis:names:tc:opendocument:xmlns:style:1.0"
+namespace svg =
+  "urn:oasis:names:tc:opendocument:xmlns:svg-compatible:1.0"
+namespace table = "urn:oasis:names:tc:opendocument:xmlns:table:1.0"
+namespace text = "urn:oasis:names:tc:opendocument:xmlns:text:1.0"
+namespace xforms = "http://www.w3.org/2002/xforms"
+namespace xlink = "http://www.w3.org/1999/xlink"
+
+office-process-content =
+  [ a:defaultValue = "true" ]
+  attribute office:process-content { boolean }?
+start =
+  office-document
+  | office-document-content
+  | office-document-styles
+  | office-document-meta
+  | office-document-settings
+office-document =
+  element office:document {
+    office-document-attrs,
+    office-document-common-attrs,
+    office-meta,
+    office-settings,
+    office-scripts,
+    office-font-face-decls,
+    office-styles,
+    office-automatic-styles,
+    office-master-styles,
+    office-body
+  }
+office-document-content =
+  element office:document-content {
+    office-document-common-attrs,
+    office-scripts,
+    office-font-face-decls,
+    office-automatic-styles,
+    office-body
+  }
+office-document-styles =
+  element office:document-styles {
+    office-document-common-attrs,
+    office-font-face-decls,
+    office-styles,
+    office-automatic-styles,
+    office-master-styles
+  }
+office-document-meta =
+  element office:document-meta {
+    office-document-common-attrs, office-meta
+  }
+office-document-settings =
+  element office:document-settings {
+    office-document-common-attrs, office-settings
+  }
+office-document-common-attrs &= attribute office:version { \string }?
+office-document-attrs &= attribute office:mimetype { \string }
+office-meta = element office:meta { office-meta-content }?
+office-meta-content = anyElements
+office-meta-content-strict = office-meta-data*
+office-body = element office:body { office-body-content }
+office-body-content |=
+  element office:text {
+    office-text-attlist,
+    office-text-content-prelude,
+    office-text-content-main*,
+    office-text-content-epilogue
+  }
+office-text-content-prelude =
+  office-forms, text-tracked-changes, text-decls, table-decls
+office-text-content-main =
+  text-content*
+  | (text-page-sequence, (draw-a | shape)*)
+text-content =
+  text-h
+  | text-p
+  | text-list
+  | text-numbered-paragraph
+  | table-table
+  | draw-a
+  | text-section
+  | text-soft-page-break
+  | text-table-of-content
+  | text-illustration-index
+  | text-table-index
+  | text-object-index
+  | text-user-index
+  | text-alphabetical-index
+  | text-bibliography
+  | shape
+  | change-marks
+office-text-content-epilogue = table-functions
+office-text-attlist &=
+  [ a:defaultValue = "false" ] attribute text:global { boolean }?
+office-text-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute text:use-soft-page-breaks { boolean }?
+office-body-content |=
+  element office:drawing {
+    office-drawing-attlist,
+    office-drawing-content-prelude,
+    office-drawing-content-main,
+    office-drawing-content-epilogue
+  }
+office-drawing-attlist = empty
+office-drawing-content-prelude = text-decls, table-decls
+office-drawing-content-main = draw-page*
+office-drawing-content-epilogue = table-functions
+office-body-content |=
+  element office:presentation {
+    office-presentation-attlist,
+    office-presentation-content-prelude,
+    office-presentation-content-main,
+    office-presentation-content-epilogue
+  }
+office-presentation-attlist = empty
+office-presentation-content-prelude =
+  text-decls, table-decls, presentation-decls
+office-presentation-content-main = draw-page*
+office-presentation-content-epilogue =
+  presentation-settings, table-functions
+office-body-content |=
+  element office:spreadsheet {
+    office-spreadsheet-attlist,
+    office-spreadsheet-content-prelude,
+    office-spreadsheet-content-main,
+    office-spreadsheet-content-epilogue
+  }
+office-spreadsheet-content-prelude =
+  table-tracked-changes?, text-decls, table-decls
+table-decls =
+  table-calculation-settings?,
+  table-content-validations?,
+  table-label-ranges?
+office-spreadsheet-content-main = table-table*
+office-spreadsheet-content-epilogue = table-functions
+table-functions =
+  table-named-expressions?,
+  table-database-ranges?,
+  table-data-pilot-tables?,
+  table-consolidation?,
+  table-dde-links?
+office-body-content |=
+  element office:chart {
+    office-chart-attlist,
+    office-chart-content-prelude,
+    office-chart-content-main,
+    office-chart-content-epilogue
+  }
+office-chart-attlist = empty
+office-chart-content-prelude = text-decls, table-decls
+office-chart-content-main = chart-chart
+office-chart-content-epilogue = table-functions
+office-body-content |=
+  element office:image {
+    office-image-attlist,
+    office-image-content-prelude,
+    office-image-content-main,
+    office-image-content-epilogue
+  }
+office-image-attlist = empty
+office-image-content-prelude = empty
+office-image-content-main = draw-frame
+office-image-content-epilogue = empty
+office-settings = element office:settings { config-config-item-set+ }?
+config-config-item-set =
+  element config:config-item-set {
+    config-config-item-set-attlist, config-items
+  }
+config-items =
+  (config-config-item
+   | config-config-item-set
+   | config-config-item-map-named
+   | config-config-item-map-indexed)+
+config-config-item-set-attlist &= attribute config:name { \string }
+config-config-item =
+  element config:config-item { config-config-item-attlist, text }
+config-config-item-attlist &= attribute config:name { \string }
+config-config-item-attlist &=
+  attribute config:type {
+    "boolean"
+    | "short"
+    | "int"
+    | "long"
+    | "double"
+    | "string"
+    | "datetime"
+    | "base64Binary"
+  }
+config-config-item-map-indexed =
+  element config:config-item-map-indexed {
+    config-config-item-map-indexed-attlist,
+    config-config-item-map-entry+
+  }
+config-config-item-map-indexed-attlist &=
+  attribute config:name { \string }
+config-config-item-map-entry =
+  element config:config-item-map-entry {
+    config-config-item-map-entry-attlist, config-items
+  }
+config-config-item-map-entry-attlist &=
+  attribute config:name { \string }?
+config-config-item-map-named =
+  element config:config-item-map-named {
+    config-config-item-map-named-attlist, config-config-item-map-entry+
+  }
+config-config-item-map-named-attlist &=
+  attribute config:name { \string }
+office-scripts =
+  element office:scripts { office-script*, office-event-listeners? }?
+office-script =
+  element office:script {
+    office-script-attlist,
+    mixed { anyElements }
+  }
+office-script-attlist = attribute script:language { \string }
+office-font-face-decls =
+  element office:font-face-decls { style-font-face* }?
+office-styles =
+  element office:styles {
+    styles
+    & style-default-style*
+    & text-outline-style?
+    & text-notes-configuration*
+    & text-bibliography-configuration?
+    & text-linenumbering-configuration?
+    & draw-gradient*
+    & svg-linearGradient*
+    & svg-radialGradient*
+    & draw-hatch*
+    & draw-fill-image*
+    & draw-marker*
+    & draw-stroke-dash*
+    & draw-opacity*
+    & style-presentation-page-layout*
+  }?
+office-automatic-styles =
+  element office:automatic-styles { styles & style-page-layout* }?
+office-master-styles =
+  element office:master-styles {
+    style-master-page* & style-handout-master? & draw-layer-set?
+  }?
+styles =
+  style-style*
+  & text-list-style*
+  & number-number-style*
+  & number-currency-style*
+  & number-percentage-style*
+  & number-date-style*
+  & number-time-style*
+  & number-boolean-style*
+  & number-text-style*
+office-meta-data |= element meta:generator { \string }
+office-meta-data |= element dc:title { \string }
+office-meta-data |= element dc:description { \string }
+office-meta-data |= element dc:subject { \string }
+office-meta-data |= element meta:keyword { \string }
+office-meta-data |= element meta:initial-creator { \string }
+office-meta-data |= dc-creator
+dc-creator = element dc:creator { \string }
+office-meta-data |= element meta:printed-by { \string }
+office-meta-data |= element meta:creation-date { dateTime }
+office-meta-data |= dc-date
+dc-date = element dc:date { dateTime }
+office-meta-data |= element meta:print-date { dateTime }
+office-meta-data |=
+  element meta:template {
+    attribute xlink:href { anyURI },
+    [ a:defaultValue = "simple" ] attribute xlink:type { "simple" }?,
+    [ a:defaultValue = "onRequest" ]
+    attribute xlink:actuate { "onRequest" }?,
+    attribute xlink:title { \string }?,
+    attribute meta:date { dateTime }?
+  }
+office-meta-data |=
+  element meta:auto-reload {
+    [ a:defaultValue = "simple" ] attribute xlink:type { "simple" }?,
+    [ a:defaultValue = "replace" ] attribute xlink:show { "replace" }?,
+    [ a:defaultValue = "onLoad" ] attribute xlink:actuate { "onLoad" }?,
+    attribute xlink:href { anyURI }?,
+    attribute meta:delay { duration }?
+  }
+office-meta-data |=
+  element meta:hyperlink-behaviour {
+    attribute office:target-frame-name { targetFrameName }?,
+    attribute xlink:show { "new" | "replace" }?
+  }
+office-meta-data |= element dc:language { language }
+office-meta-data |= element meta:editing-cycles { nonNegativeInteger }
+office-meta-data |= element meta:editing-duration { duration }
+office-meta-data |=
+  element meta:document-statistic {
+    attribute meta:page-count { nonNegativeInteger }?,
+    attribute meta:table-count { nonNegativeInteger }?,
+    attribute meta:draw-count { nonNegativeInteger }?,
+    attribute meta:image-count { nonNegativeInteger }?,
+    attribute meta:ole-object-count { nonNegativeInteger }?,
+    attribute meta:object-count { nonNegativeInteger }?,
+    attribute meta:paragraph-count { nonNegativeInteger }?,
+    attribute meta:word-count { nonNegativeInteger }?,
+    attribute meta:character-count { nonNegativeInteger }?,
+    attribute frame-count { nonNegativeInteger }?,
+    attribute sentence-count { nonNegativeInteger }?,
+    attribute syllable-count { nonNegativeInteger }?,
+    attribute non-whitespace-character-count { nonNegativeInteger }?,
+    attribute meta:row-count { nonNegativeInteger }?,
+    attribute meta:cell-count { nonNegativeInteger }?
+  }
+office-meta-data |=
+  element meta:user-defined {
+    attribute meta:name { \string },
+    ((attribute meta:value-type { "float" },
+      double)
+     | (attribute meta:value-type { "date" },
+        dateOrDateTime)
+     | (attribute meta:value-type { "time" },
+        duration)
+     | (attribute meta:value-type { "boolean" },
+        boolean)
+     | (attribute meta:value-type { "string" },
+        \string)
+     | text)
+  }
+text-h =
+  element text:h {
+    heading-attrs, paragraph-attrs, text-number?, paragraph-content*
+  }
+heading-attrs &= attribute text:outline-level { positiveInteger }
+heading-attrs &=
+  [ a:defaultValue = "false" ]
+  attribute text:restart-numbering { boolean }?
+heading-attrs &= attribute text:start-value { nonNegativeInteger }?
+heading-attrs &=
+  [ a:defaultValue = "false" ]
+  attribute text:is-list-header { boolean }?
+text-number = element text:number { \string }
+text-p = element text:p { paragraph-attrs, paragraph-content* }
+paragraph-attrs =
+  attribute text:style-name { styleNameRef }?,
+  attribute text:class-names { styleNameRefs }?,
+  attribute text:cond-style-name { styleNameRef }?
+paragraph-attrs &= text-id?
+text-page-sequence = element text:page-sequence { text-page+ }
+text-page = element text:page { text-page-attlist, empty }
+text-page-attlist = attribute text:master-page-name { styleNameRef }
+text-list =
+  element text:list {
+    text-list-attr, text-list-header?, text-list-item*
+  }
+text-list-attr &= attribute text:style-name { styleNameRef }?
+text-list-attr &= attribute text:continue-numbering { boolean }?
+text-list-item =
+  element text:list-item { text-list-item-attr, text-list-item-content }
+text-list-item-content =
+  text-number?, (text-p | text-h | text-list | text-soft-page-break)*
+text-list-item-attr &=
+  attribute text:start-value { nonNegativeInteger }?
+text-list-header = element text:list-header { text-list-item-content }
+text-numbered-paragraph =
+  element text:numbered-paragraph {
+    text-numbered-paragraph-attr, text-number?, (text-p | text-h)
+  }
+text-numbered-paragraph-attr &=
+  [ a:defaultValue = "1" ] attribute text:level { positiveInteger }?
+text-numbered-paragraph-attr &= text-list-attr
+text-numbered-paragraph-attr &= text-list-item-attr
+text-section =
+  element text:section {
+    text-section-attr,
+    (text-section-source | text-section-source-dde | empty),
+    text-content*
+  }
+text-section-attr &= sectionAttr
+sectionAttr &= attribute text:style-name { styleNameRef }?
+sectionAttr &= attribute text:name { \string }
+sectionAttr &= attribute text:protected { boolean }?
+sectionAttr &= attribute text:protection-key { \string }?
+text-section-attr &=
+  attribute text:display { "true" | "none" }
+  | (attribute text:display { "condition" },
+     attribute text:condition { \string })
+  | empty
+text-section-source =
+  element text:section-source { text-section-source-attr }
+text-section-source-attr &=
+  (attribute xlink:href { anyURI },
+   [ a:defaultValue = "simple" ] attribute xlink:type { "simple" }?,
+   [ a:defaultValue = "embed" ] attribute xlink:show { "embed" }?)?
+text-section-source-attr &= attribute text:section-name { \string }?
+text-section-source-attr &= attribute text:filter-name { \string }?
+text-section-source-dde = office-dde-source
+text-tracked-changes =
+  element text:tracked-changes {
+    text-tracked-changes-attr, text-changed-region*
+  }?
+text-tracked-changes-attr &=
+  [ a:defaultValue = "true" ] attribute text:track-changes { boolean }?
+text-changed-region =
+  element text:changed-region {
+    text-changed-region-attr, text-changed-region-content
+  }
+text-changed-region-attr &= attribute text:id { ID }
+text-changed-region-content |=
+  element text:insertion { office-change-info }
+text-changed-region-content |=
+  element text:deletion { office-change-info, text-content* }
+text-changed-region-content |=
+  element text:format-change { office-change-info }
+change-marks =
+  element text:change { change-mark-attr }
+  | element text:change-start { change-mark-attr }
+  | element text:change-end { change-mark-attr }
+change-mark-attr = attribute text:change-id { IDREF }
+text-soft-page-break = element text:soft-page-break { empty }
+text-decls =
+  element text:variable-decls { text-variable-decl* }?,
+  element text:sequence-decls { text-sequence-decl* }?,
+  element text:user-field-decls { text-user-field-decl* }?,
+  element text:dde-connection-decls { text-dde-connection-decl* }?,
+  text-alphabetical-index-auto-mark-file?
+paragraph-content |= text
+paragraph-content |=
+  element text:s {
+    attribute text:c { nonNegativeInteger }?
+  }
+paragraph-content |= element text:tab { text-tab-attr }
+text-tab-attr = attribute text:tab-ref { nonNegativeInteger }?
+paragraph-content |= element text:line-break { empty }
+paragraph-content |= text-soft-page-break
+paragraph-content |=
+  element text:span {
+    attribute text:style-name { styleNameRef }?,
+    attribute text:class-names { styleNameRefs }?,
+    paragraph-content*
+  }
+paragraph-content |=
+  element text:a {
+    text-a-attlist, office-event-listeners?, paragraph-content*
+  }
+text-a-attlist &= attribute office:name { \string }?
+text-a-attlist &= attribute office:title { \string }?
+text-a-attlist &=
+  attribute xlink:href { anyURI },
+  [ a:defaultValue = "simple" ] attribute xlink:type { "simple" }?,
+  [ a:defaultValue = "onRequest" ]
+  attribute xlink:actuate { "onRequest" }?
+text-a-attlist &=
+  attribute office:target-frame-name { targetFrameName }?,
+  attribute xlink:show { "new" | "replace" }?
+text-a-attlist &=
+  attribute text:style-name { styleNameRef }?,
+  attribute text:visited-style-name { styleNameRef }?
+paragraph-content |=
+  element text:bookmark {
+    attribute text:name { \string }
+  }
+  | element text:bookmark-start {
+      attribute text:name { \string }
+    }
+  | element text:bookmark-end {
+      attribute text:name { \string }
+    }
+paragraph-content |=
+  element text:reference-mark {
+    attribute text:name { \string }
+  }
+paragraph-content |=
+  element text:reference-mark-start {
+    attribute text:name { \string }
+  }
+  | element text:reference-mark-end {
+      attribute text:name { \string }
+    }
+paragraph-content |=
+  element text:note {
+    text-note-class,
+    attribute text:id { \string }?,
+    element text:note-citation {
+      attribute text:label { \string }?,
+      text
+    },
+    element text:note-body { text-content* }
+  }
+text-note-class = attribute text:note-class { "footnote" | "endnote" }
+paragraph-content |=
+  element text:ruby {
+    attribute text:style-name { styleNameRef }?,
+    element text:ruby-base { paragraph-content },
+    element text:ruby-text {
+      attribute text:style-name { styleNameRef }?,
+      text
+    }
+  }
+paragraph-content |= office-annotation
+paragraph-content |= change-marks
+paragraph-content |= shape | draw-a
+paragraph-content |= element text:date { text-date-attlist, text }
+text-date-attlist &=
+  common-field-fixed-attlist & common-field-data-style-name-attlist
+text-date-attlist &= attribute text:date-value { dateOrDateTime }?
+text-date-attlist &= attribute text:date-adjust { duration }?
+paragraph-content |= element text:time { text-time-attlist, text }
+text-time-attlist &=
+  common-field-fixed-attlist & common-field-data-style-name-attlist
+text-time-attlist &= attribute text:time-value { timeOrDateTime }?
+text-time-attlist &= attribute text:time-adjust { duration }?
+paragraph-content |=
+  element text:page-number { text-page-number-attlist, text }
+text-page-number-attlist &=
+  common-field-num-format-attlist & common-field-fixed-attlist
+text-page-number-attlist &= attribute text:page-adjust { integer }?
+text-page-number-attlist &=
+  attribute text:select-page { "previous" | "current" | "next" }?
+paragraph-content |=
+  element text:page-continuation {
+    text-page-continuation-attlist, text
+  }
+text-page-continuation-attlist &=
+  attribute text:select-page { "previous" | "next" }
+text-page-continuation-attlist &=
+  attribute text:string-value { \string }?
+paragraph-content |=
+  element text:sender-firstname { common-field-fixed-attlist, text }
+paragraph-content |=
+  element text:sender-lastname { common-field-fixed-attlist, text }
+paragraph-content |=
+  element text:sender-initials { common-field-fixed-attlist, text }
+paragraph-content |=
+  element text:sender-title { common-field-fixed-attlist, text }
+paragraph-content |=
+  element text:sender-position { common-field-fixed-attlist, text }
+paragraph-content |=
+  element text:sender-email { common-field-fixed-attlist, text }
+paragraph-content |=
+  element text:sender-phone-private { common-field-fixed-attlist, text }
+paragraph-content |=
+  element text:sender-fax { common-field-fixed-attlist, text }
+paragraph-content |=
+  element text:sender-company { common-field-fixed-attlist, text }
+paragraph-content |=
+  element text:sender-phone-work { common-field-fixed-attlist, text }
+paragraph-content |=
+  element text:sender-street { common-field-fixed-attlist, text }
+paragraph-content |=
+  element text:sender-city { common-field-fixed-attlist, text }
+paragraph-content |=
+  element text:sender-postal-code { common-field-fixed-attlist, text }
+paragraph-content |=
+  element text:sender-country { common-field-fixed-attlist, text }
+paragraph-content |=
+  element text:sender-state-or-province {
+    common-field-fixed-attlist, text
+  }
+paragraph-content |=
+  element text:author-name { common-field-fixed-attlist, text }
+paragraph-content |=
+  element text:author-initials { common-field-fixed-attlist, text }
+paragraph-content |= element text:chapter { text-chapter-attlist, text }
+text-chapter-attlist &=
+  attribute text:display {
+    "name"
+    | "number"
+    | "number-and-name"
+    | "plain-number-and-name"
+    | "plain-number"
+  }
+text-chapter-attlist &=
+  attribute text:outline-level { nonNegativeInteger }
+paragraph-content |=
+  element text:file-name { text-file-name-attlist, text }
+text-file-name-attlist &=
+  attribute text:display {
+    "full" | "path" | "name" | "name-and-extension"
+  }?
+text-file-name-attlist &= common-field-fixed-attlist
+paragraph-content |=
+  element text:template-name { text-template-name-attlist, text }
+text-template-name-attlist =
+  attribute text:display {
+    "full" | "path" | "name" | "name-and-extension" | "area" | "title"
+  }?
+paragraph-content |= element text:sheet-name { text }
+text-variable-decl =
+  element text:variable-decl {
+    common-field-name-attlist, common-value-type-attlist
+  }
+paragraph-content |=
+  element text:variable-set {
+    (common-field-name-attlist
+     & common-field-formula-attlist
+     & common-value-and-type-attlist
+     & common-field-display-value-none-attlist
+     & common-field-data-style-name-attlist),
+    text
+  }
+paragraph-content |=
+  element text:variable-get {
+    (common-field-name-attlist
+     & common-field-display-value-formula-attlist
+     & common-field-data-style-name-attlist),
+    text
+  }
+paragraph-content |=
+  element text:variable-input {
+    (common-field-name-attlist
+     & common-field-description-attlist
+     & common-value-type-attlist
+     & common-field-display-value-none-attlist
+     & common-field-data-style-name-attlist),
+    text
+  }
+text-user-field-decl =
+  element text:user-field-decl {
+    common-field-name-attlist,
+    common-field-formula-attlist?,
+    common-value-and-type-attlist
+  }
+paragraph-content |=
+  element text:user-field-get {
+    (common-field-name-attlist
+     & common-field-display-value-formula-none-attlist
+     & common-field-data-style-name-attlist),
+    text
+  }
+paragraph-content |=
+  element text:user-field-input {
+    (common-field-name-attlist
+     & common-field-description-attlist
+     & common-field-data-style-name-attlist),
+    text
+  }
+text-sequence-decl =
+  element text:sequence-decl { text-sequence-decl-attlist }
+text-sequence-decl-attlist &= common-field-name-attlist
+text-sequence-decl-attlist &=
+  attribute text:display-outline-level { nonNegativeInteger }
+text-sequence-decl-attlist &=
+  attribute text:separation-character { character }?
+paragraph-content |=
+  element text:sequence {
+    (common-field-name-attlist
+     & common-field-formula-attlist
+     & common-field-num-format-attlist
+     & text-sequence-ref-name),
+    text
+  }
+text-sequence-ref-name = attribute text:ref-name { \string }?
+paragraph-content |=
+  element text:expression {
+    (common-field-formula-attlist
+     & common-value-and-type-attlist?
+     & common-field-display-value-formula-attlist
+     & common-field-data-style-name-attlist),
+    text
+  }
+paragraph-content |=
+  element text:text-input { common-field-description-attlist, text }
+paragraph-content |=
+  element text:initial-creator { common-field-fixed-attlist, text }
+paragraph-content |=
+  element text:creation-date {
+    (common-field-fixed-attlist
+     & common-field-data-style-name-attlist
+     & attribute text:date-value { dateOrDateTime }?),
+    text
+  }
+paragraph-content |=
+  element text:creation-time {
+    (common-field-fixed-attlist
+     & common-field-data-style-name-attlist
+     & attribute text:time-value { timeOrDateTime }?),
+    text
+  }
+paragraph-content |=
+  element text:description { common-field-fixed-attlist, text }
+paragraph-content |=
+  element text:user-defined {
+    (common-field-fixed-attlist
+     & attribute text:name { \string }
+     & common-field-data-style-name-attlist
+     & attribute office:value { double }?
+     & attribute office:date-value { dateOrDateTime }?
+     & attribute office:time-value { duration }?
+     & attribute office:boolean-value { boolean }?
+     & attribute office:string-value { \string }?),
+    text
+  }
+paragraph-content |=
+  element text:print-time {
+    (common-field-fixed-attlist
+     & common-field-data-style-name-attlist
+     & attribute text:time-value { time }?),
+    text
+  }
+paragraph-content |=
+  element text:print-date {
+    (common-field-fixed-attlist
+     & common-field-data-style-name-attlist
+     & attribute text:date-value { date }?),
+    text
+  }
+paragraph-content |=
+  element text:printed-by { common-field-fixed-attlist, text }
+paragraph-content |=
+  element text:title { common-field-fixed-attlist, text }
+paragraph-content |=
+  element text:subject { common-field-fixed-attlist, text }
+paragraph-content |=
+  element text:keywords { common-field-fixed-attlist, text }
+paragraph-content |=
+  element text:editing-cycles { common-field-fixed-attlist, text }
+paragraph-content |=
+  element text:editing-duration {
+    (common-field-fixed-attlist
+     & common-field-data-style-name-attlist
+     & attribute text:duration { duration }?),
+    text
+  }
+paragraph-content |=
+  element text:modification-time {
+    (common-field-fixed-attlist
+     & common-field-data-style-name-attlist
+     & attribute text:time-value { time }?),
+    text
+  }
+paragraph-content |=
+  element text:modification-date {
+    (common-field-fixed-attlist
+     & common-field-data-style-name-attlist
+     & attribute text:date-value { date }?),
+    text
+  }
+paragraph-content |=
+  element text:creator { common-field-fixed-attlist, text }
+paragraph-content |=
+  element text:page-count
+          | text:paragraph-count
+          | text:word-count
+          | text:character-count
+          | text:table-count
+          | text:image-count
+          | text:object-count { common-field-num-format-attlist, text }
+common-field-database-table =
+  common-field-database-table-attlist, common-field-database-name
+common-field-database-name |= attribute text:database-name { \string }?
+common-field-database-name |= form-connection-resource
+common-field-database-table-attlist &=
+  attribute text:table-name { \string }
+common-field-database-table-attlist &=
+  attribute text:table-type { "table" | "query" | "command" }?
+paragraph-content |=
+  element text:database-display { text-database-display-attlist, text }
+text-database-display-attlist &= common-field-database-table
+text-database-display-attlist &= common-field-data-style-name-attlist
+text-database-display-attlist &= attribute text:column-name { \string }
+paragraph-content |=
+  element text:database-next { text-database-next-attlist }
+text-database-next-attlist &= common-field-database-table
+text-database-next-attlist &= attribute text:condition { formula }?
+paragraph-content |=
+  element text:database-row-select { text-database-row-select-attlist }
+text-database-row-select-attlist &= common-field-database-table
+text-database-row-select-attlist &=
+  attribute text:condition { formula }?
+text-database-row-select-attlist &=
+  attribute text:row-number { nonNegativeInteger }?
+paragraph-content |=
+  element text:database-row-number {
+    (common-field-database-table
+     & common-field-num-format-attlist
+     & attribute text:value { nonNegativeInteger }?),
+    text
+  }
+paragraph-content |=
+  element text:database-name { common-field-database-table, text }
+paragraph-content |=
+  element text:page-variable-set {
+    text-set-page-variable-attlist, text
+  }
+text-set-page-variable-attlist &= attribute text:active { boolean }?
+text-set-page-variable-attlist &=
+  attribute text:page-adjust { integer }?
+paragraph-content |=
+  element text:page-variable-get {
+    text-get-page-variable-attlist, text
+  }
+text-get-page-variable-attlist &= common-field-num-format-attlist
+paragraph-content |=
+  element text:placeholder { text-placeholder-attlist, text }
+text-placeholder-attlist &=
+  attribute text:placeholder-type {
+    "text" | "table" | "text-box" | "image" | "object"
+  }
+text-placeholder-attlist &= common-field-description-attlist
+paragraph-content |=
+  element text:conditional-text { text-conditional-text-attlist, text }
+text-conditional-text-attlist &= attribute text:condition { formula }
+text-conditional-text-attlist &=
+  attribute text:string-value-if-true { \string }
+text-conditional-text-attlist &=
+  attribute text:string-value-if-false { \string }
+text-conditional-text-attlist &=
+  attribute text:current-value { boolean }?
+paragraph-content |=
+  element text:hidden-text { text-hidden-text-attlist, text }
+text-hidden-text-attlist &= attribute text:condition { formula }
+text-hidden-text-attlist &= attribute text:string-value { \string }
+text-hidden-text-attlist &= attribute text:is-hidden { boolean }?
+paragraph-content |=
+  element text:reference-ref | text:bookmark-ref {
+    text-common-ref-content & text-ref-content
+  }
+paragraph-content |=
+  element text:note-ref {
+    text-common-ref-content & text-note-ref-content & text-ref-content
+  }
+paragraph-content |=
+  element text:sequence-ref {
+    text-common-ref-content & text-sequence-ref-content
+  }
+text-common-ref-content &= text
+text-common-ref-content &= attribute text:ref-name { \string }?
+text-note-ref-content &= text-note-class
+text-ref-content &=
+  attribute text:reference-format {
+    "page" | "chapter" | "direction" | "text"
+  }?
+text-sequence-ref-content &=
+  attribute text:reference-format {
+    "page"
+    | "chapter"
+    | "direction"
+    | "text"
+    | "category-and-value"
+    | "caption"
+    | "value"
+  }?
+paragraph-content |=
+  element text:script {
+    ((attribute xlink:href { anyURI },
+      [ a:defaultValue = "simple" ] attribute xlink:type { "simple" }?)
+     | text)
+    & attribute script:language { \string }?
+  }
+paragraph-content |=
+  element text:execute-macro {
+    attribute text:name { \string }?,
+    office-event-listeners?,
+    text
+  }
+paragraph-content |=
+  element text:hidden-paragraph { text-hidden-paragraph-attlist, text }
+text-hidden-paragraph-attlist &= attribute text:condition { formula }
+text-hidden-paragraph-attlist &= attribute text:is-hidden { boolean }?
+paragraph-content |=
+  element text:dde-connection {
+    attribute text:connection-name { \string },
+    text
+  }
+paragraph-content |=
+  element text:measure {
+    attribute text:kind { "value" | "unit" | "gap" },
+    text
+  }
+paragraph-content |=
+  element text:table-formula {
+    (common-field-formula-attlist
+     & common-field-display-value-formula-attlist
+     & common-field-data-style-name-attlist),
+    text
+  }
+common-value-type-attlist = attribute office:value-type { valueType }
+common-value-and-type-attlist =
+  (attribute office:value-type { "float" },
+   attribute office:value { double })
+  | (attribute office:value-type { "percentage" },
+     attribute office:value { double })
+  | (attribute office:value-type { "currency" },
+     attribute office:value { double },
+     attribute office:currency { \string }?)
+  | (attribute office:value-type { "date" },
+     attribute office:date-value { dateOrDateTime })
+  | (attribute office:value-type { "time" },
+     attribute office:time-value { duration })
+  | (attribute office:value-type { "boolean" },
+     attribute office:boolean-value { boolean })
+  | (attribute office:value-type { "string" },
+     attribute office:string-value { \string }?)
+common-field-fixed-attlist = attribute text:fixed { boolean }?
+common-field-name-attlist = attribute text:name { variableName }
+common-field-description-attlist = attribute text:description { text }?
+common-field-display-value-none-attlist =
+  attribute text:display { "value" | "none" }?
+common-field-display-value-formula-none-attlist =
+  attribute text:display { "value" | "formula" | "none" }?
+common-field-display-value-formula-attlist =
+  attribute text:display { "value" | "formula" }?
+common-field-formula-attlist = attribute text:formula { formula }?
+common-field-data-style-name-attlist =
+  attribute style:data-style-name { styleNameRef }?
+common-field-num-format-attlist = common-num-format-attlist?
+paragraph-content |=
+  element text:toc-mark-start { text-toc-mark-start-attrs }
+text-toc-mark-start-attrs = text-id, text-outline-level
+text-outline-level = attribute text:outline-level { positiveInteger }?
+text-id = attribute text:id { \string }
+paragraph-content |= element text:toc-mark-end { text-id }
+paragraph-content |=
+  element text:toc-mark {
+    attribute text:string-value { \string },
+    text-outline-level
+  }
+paragraph-content |=
+  element text:user-index-mark-start {
+    text-id, text-outline-level, text-index-name
+  }
+paragraph-content |=
+  element text:user-index-mark-end { text-id, text-outline-level }
+paragraph-content |=
+  element text:user-index-mark {
+    attribute text:string-value { \string },
+    text-outline-level,
+    text-index-name
+  }
+text-index-name = attribute text:index-name { \string }
+paragraph-content |=
+  element text:alphabetical-index-mark-start {
+    text-id, text-alphabetical-index-mark-attrs
+  }
+paragraph-content |=
+  element text:alphabetical-index-mark-end { text-id }
+paragraph-content |=
+  element text:alphabetical-index-mark {
+    attribute text:string-value { \string },
+    text-alphabetical-index-mark-attrs
+  }
+text-alphabetical-index-mark-attrs &=
+  attribute text:key1 { \string }?,
+  attribute text:key2 { \string }?
+text-alphabetical-index-mark-attrs &=
+  attribute text:string-value-phonetic { \string }?,
+  attribute text:key1-phonetic { \string }?,
+  attribute text:key2-phonetic { \string }?
+text-alphabetical-index-mark-attrs &=
+  [ a:defaultValue = "false" ] attribute text:main-entry { boolean }?
+paragraph-content |=
+  element text:bibliography-mark {
+    attribute text:bibliography-type { text-bibliography-types },
+    attribute text:identifier
+              | text:address
+              | text:annote
+              | text:author
+              | text:booktitle
+              | text:chapter
+              | text:edition
+              | text:editor
+              | text:howpublished
+              | text:institution
+              | text:journal
+              | text:month
+              | text:note
+              | text:number
+              | text:organizations
+              | text:pages
+              | text:publisher
+              | text:school
+              | text:series
+              | text:title
+              | text:report-type
+              | text:volume
+              | text:year
+              | text:url
+              | text:custom1
+              | text:custom2
+              | text:custom3
+              | text:custom4
+              | text:custom5
+              | text:isbn
+              | text:issn { \string }*,
+    text
+  }
+text-bibliography-types =
+  "article"
+  | "book"
+  | "booklet"
+  | "conference"
+  | "custom1"
+  | "custom2"
+  | "custom3"
+  | "custom4"
+  | "custom5"
+  | "email"
+  | "inbook"
+  | "incollection"
+  | "inproceedings"
+  | "journal"
+  | "manual"
+  | "mastersthesis"
+  | "misc"
+  | "phdthesis"
+  | "proceedings"
+  | "techreport"
+  | "unpublished"
+  | "www"
+text-index-body = element text:index-body { index-content-main* }
+index-content-main = text-content | text-index-title
+text-index-title =
+  element text:index-title { sectionAttr, index-content-main* }
+text-table-of-content =
+  element text:table-of-content {
+    sectionAttr, text-table-of-content-source, text-index-body
+  }
+text-table-of-content-source =
+  element text:table-of-content-source {
+    text-table-of-content-source-attlist,
+    text-index-title-template?,
+    text-table-of-content-entry-template*,
+    text-index-source-styles*
+  }
+text-table-of-content-source-attlist &=
+  attribute text:outline-level { positiveInteger }?
+text-table-of-content-source-attlist &=
+  [ a:defaultValue = "true" ]
+  attribute text:use-outline-level { boolean }?
+text-table-of-content-source-attlist &=
+  attribute text:use-index-marks { boolean }?
+text-table-of-content-source-attlist &=
+  attribute text:use-index-source-styles { boolean }?
+text-table-of-content-source-attlist &=
+  attribute text:index-scope { "document" | "chapter" }?
+text-table-of-content-source-attlist &=
+  attribute text:relative-tab-stop-position { boolean }?
+text-table-of-content-entry-template =
+  element text:table-of-content-entry-template {
+    text-table-of-content-entry-template-attlist,
+    text-table-of-content-children*
+  }
+text-table-of-content-children =
+  text-index-entry-chapter
+  | text-index-entry-page-number
+  | text-index-entry-text
+  | text-index-entry-span
+  | text-index-entry-tab-stop
+  | text-index-entry-link-start
+  | text-index-entry-link-end
+text-table-of-content-entry-template-attlist &=
+  attribute text:outline-level { positiveInteger }
+text-table-of-content-entry-template-attlist &=
+  attribute text:style-name { styleNameRef }
+text-illustration-index =
+  element text:illustration-index {
+    sectionAttr, text-illustration-index-source, text-index-body
+  }
+text-illustration-index-source =
+  element text:illustration-index-source {
+    text-illustration-index-source-attrs,
+    text-index-title-template?,
+    text-illustration-index-entry-template?
+  }
+text-illustration-index-source-attrs &= text-index-scope-attr
+text-index-scope-attr =
+  [ a:defaultValue = "document" ]
+  attribute text:index-scope { "document" | "chapter" }?
+text-illustration-index-source-attrs &=
+  text-relative-tab-stop-position-attr
+text-relative-tab-stop-position-attr =
+  [ a:defaultValue = "true" ]
+  attribute text:relative-tab-stop-position { boolean }?
+text-illustration-index-source-attrs &=
+  [ a:defaultValue = "true" ] attribute text:use-caption { boolean }?
+text-illustration-index-source-attrs &=
+  attribute text:caption-sequence-name { \string }?
+text-illustration-index-source-attrs &=
+  attribute text:caption-sequence-format {
+    "text" | "category-and-value" | "caption"
+  }?
+text-illustration-index-entry-template =
+  element text:illustration-index-entry-template {
+    text-illustration-index-entry-content
+  }
+text-illustration-index-entry-content =
+  text-illustration-index-entry-template-attrs,
+  (text-index-entry-page-number
+   | text-index-entry-text
+   | text-index-entry-span
+   | text-index-entry-tab-stop)*
+text-illustration-index-entry-template-attrs =
+  attribute text:style-name { styleNameRef }
+text-table-index =
+  element text:table-index {
+    sectionAttr, text-table-index-source, text-index-body
+  }
+text-table-index-source =
+  element text:table-index-source {
+    text-illustration-index-source-attrs,
+    text-index-title-template?,
+    text-table-index-entry-template?
+  }
+text-table-index-entry-template =
+  element text:table-index-entry-template {
+    text-illustration-index-entry-content
+  }
+text-object-index =
+  element text:object-index {
+    sectionAttr, text-object-index-source, text-index-body
+  }
+text-object-index-source =
+  element text:object-index-source {
+    text-object-index-source-attrs,
+    text-index-title-template?,
+    text-object-index-entry-template?
+  }
+text-object-index-source-attrs &= text-index-scope-attr
+text-object-index-source-attrs &= text-relative-tab-stop-position-attr
+text-object-index-source-attrs &=
+  [ a:defaultValue = "false" ]
+  attribute text:use-spreadsheet-objects { boolean }?
+text-object-index-source-attrs &=
+  [ a:defaultValue = "false" ]
+  attribute text:use-math-objects { boolean }?
+text-object-index-source-attrs &=
+  [ a:defaultValue = "false" ]
+  attribute text:use-draw-objects { boolean }?
+text-object-index-source-attrs &=
+  [ a:defaultValue = "false" ]
+  attribute text:use-chart-objects { boolean }?
+text-object-index-source-attrs &=
+  [ a:defaultValue = "false" ]
+  attribute text:use-other-objects { boolean }?
+text-object-index-entry-template =
+  element text:object-index-entry-template {
+    text-illustration-index-entry-content
+  }
+text-user-index =
+  element text:user-index {
+    sectionAttr, text-user-index-source, text-index-body
+  }
+text-user-index-source =
+  element text:user-index-source {
+    text-user-index-source-attr,
+    text-index-title-template?,
+    text-user-index-entry-template*,
+    text-index-source-styles*
+  }
+text-user-index-source-attr &=
+  text-index-scope-attr,
+  text-relative-tab-stop-position-attr,
+  attribute text:index-name { \string }
+text-user-index-source-attr &=
+  [ a:defaultValue = "false" ]
+  attribute text:use-index-marks { boolean }?,
+  [ a:defaultValue = "false" ] attribute text:use-graphics { boolean }?,
+  [ a:defaultValue = "false" ] attribute text:use-tables { boolean }?,
+  [ a:defaultValue = "false" ]
+  attribute text:use-floating-frames { boolean }?,
+  [ a:defaultValue = "false" ] attribute text:use-objects { boolean }?
+text-user-index-source-attr &=
+  [ a:defaultValue = "false" ]
+  attribute text:copy-outline-levels { boolean }?
+text-user-index-entry-template =
+  element text:user-index-entry-template {
+    text-user-index-entry-template-attrs,
+    (text-index-entry-chapter
+     | text-index-entry-page-number
+     | text-index-entry-text
+     | text-index-entry-span
+     | text-index-entry-tab-stop)*
+  }
+text-user-index-entry-template-attrs &=
+  attribute text:outline-level { positiveInteger }
+text-user-index-entry-template-attrs &=
+  attribute text:style-name { styleNameRef }
+text-alphabetical-index =
+  element text:alphabetical-index {
+    sectionAttr, text-alphabetical-index-source, text-index-body
+  }
+text-alphabetical-index-source =
+  element text:alphabetical-index-source {
+    text-alphabetical-index-source-attrs,
+    text-index-title-template?,
+    text-alphabetical-index-entry-template*
+  }
+text-alphabetical-index-source-attrs &=
+  text-index-scope-attr, text-relative-tab-stop-position-attr
+text-alphabetical-index-source-attrs &=
+  [ a:defaultValue = "false" ] attribute text:ignore-case { boolean }?
+text-alphabetical-index-source-attrs &=
+  attribute text:main-entry-style-name { styleNameRef }?
+text-alphabetical-index-source-attrs &=
+  [ a:defaultValue = "false" ]
+  attribute text:alphabetical-separators { boolean }?
+text-alphabetical-index-source-attrs &=
+  [ a:defaultValue = "true" ]
+  attribute text:combine-entries { boolean }?,
+  [ a:defaultValue = "false" ]
+  attribute text:combine-entries-with-dash { boolean }?,
+  [ a:defaultValue = "true" ]
+  attribute text:combine-entries-with-pp { boolean }?
+text-alphabetical-index-source-attrs &=
+  [ a:defaultValue = "false" ]
+  attribute text:use-keys-as-entries { boolean }?
+text-alphabetical-index-source-attrs &=
+  [ a:defaultValue = "false" ]
+  attribute text:capitalize-entries { boolean }?
+text-alphabetical-index-source-attrs &=
+  [ a:defaultValue = "false" ]
+  attribute text:comma-separated { boolean }?
+text-alphabetical-index-source-attrs &=
+  attribute fo:language { languageCode }?
+text-alphabetical-index-source-attrs &=
+  attribute fo:country { countryCode }?
+text-alphabetical-index-source-attrs &=
+  attribute text:sort-algorithm { \string }?
+text-alphabetical-index-auto-mark-file =
+  element text:alphabetical-index-auto-mark-file {
+    attribute xlink:href { anyURI },
+    [ a:defaultValue = "simple" ] attribute xlink:type { "simple" }?
+  }
+text-alphabetical-index-entry-template =
+  element text:alphabetical-index-entry-template {
+    text-alphabetical-index-entry-template-attrs,
+    (text-index-entry-chapter
+     | text-index-entry-page-number
+     | text-index-entry-text
+     | text-index-entry-span
+     | text-index-entry-tab-stop)*
+  }
+text-alphabetical-index-entry-template-attrs &=
+  attribute text:outline-level { "1" | "2" | "3" | "separator" }
+text-alphabetical-index-entry-template-attrs &=
+  attribute text:style-name { styleNameRef }
+text-bibliography =
+  element text:bibliography {
+    sectionAttr, text-bibliography-source, text-index-body
+  }
+text-bibliography-source =
+  element text:bibliography-source {
+    text-index-title-template?, text-bibliography-entry-template*
+  }
+text-bibliography-entry-template =
+  element text:bibliography-entry-template {
+    text-bibliography-entry-template-attrs,
+    (text-index-entry-span
+     | text-index-entry-tab-stop
+     | text-index-entry-bibliography)*
+  }
+text-bibliography-entry-template-attrs &=
+  attribute text:bibliography-type { text-bibliography-types }
+text-bibliography-entry-template-attrs &=
+  attribute text:style-name { styleNameRef }
+text-index-source-styles =
+  element text:index-source-styles {
+    attribute text:outline-level { positiveInteger },
+    text-index-source-style*
+  }
+text-index-source-style =
+  element text:index-source-style {
+    attribute text:style-name { styleName },
+    empty
+  }
+text-index-title-template =
+  element text:index-title-template {
+    attribute text:style-name { styleNameRef }?,
+    text
+  }
+text-index-entry-chapter =
+  element text:index-entry-chapter {
+    attribute text:style-name { styleNameRef }?,
+    text-index-entry-chapter-attrs
+  }
+text-index-entry-chapter-attrs =
+  [ a:defaultValue = "number" ]
+  attribute text:display { "name" | "number" | "number-and-name" }?
+text-index-entry-text =
+  element text:index-entry-text {
+    attribute text:style-name { styleNameRef }?
+  }
+text-index-entry-page-number =
+  element text:index-entry-page-number {
+    attribute text:style-name { styleNameRef }?
+  }
+text-index-entry-span =
+  element text:index-entry-span {
+    attribute text:style-name { styleNameRef }?,
+    text
+  }
+text-index-entry-bibliography =
+  element text:index-entry-bibliography {
+    text-index-entry-bibliography-attrs
+  }
+text-index-entry-bibliography-attrs &=
+  attribute text:style-name { styleNameRef }?
+text-index-entry-bibliography-attrs &=
+  attribute text:bibliography-data-field {
+    "address"
+    | "annote"
+    | "author"
+    | "bibliography-type"
+    | "booktitle"
+    | "chapter"
+    | "custom1"
+    | "custom2"
+    | "custom3"
+    | "custom4"
+    | "custom5"
+    | "edition"
+    | "editor"
+    | "howpublished"
+    | "identifier"
+    | "institution"
+    | "isbn"
+    | "issn"
+    | "journal"
+    | "month"
+    | "note"
+    | "number"
+    | "organizations"
+    | "pages"
+    | "publisher"
+    | "report-type"
+    | "school"
+    | "series"
+    | "title"
+    | "url"
+    | "volume"
+    | "year"
+  }
+text-index-entry-tab-stop =
+  element text:index-entry-tab-stop {
+    attribute text:style-name { styleNameRef }?,
+    text-index-entry-tab-stop-attrs
+  }
+text-index-entry-tab-stop-attrs &=
+  attribute style:leader-char { character }?
+text-index-entry-tab-stop-attrs &=
+  attribute style:type { "right" }
+  | (attribute style:type { "left" },
+     attribute style:position { length })
+text-index-entry-link-start =
+  element text:index-entry-link-start {
+    attribute text:style-name { styleNameRef }?
+  }
+text-index-entry-link-end =
+  element text:index-entry-link-end {
+    attribute text:style-name { styleNameRef }?
+  }
+table-table =
+  element table:table {
+    table-table-attlist,
+    table-table-source?,
+    office-dde-source?,
+    table-scenario?,
+    office-forms?,
+    table-shapes?,
+    table-columns-and-groups,
+    table-rows-and-groups
+  }
+table-columns-and-groups =
+  (table-table-column-group | table-columns-no-group)+
+table-columns-no-group =
+  (table-columns, (table-table-header-columns, table-columns?)?)
+  | (table-table-header-columns, table-columns?)
+table-columns = table-table-columns | table-table-column+
+table-rows-and-groups = (table-table-row-group | table-rows-no-group)+
+table-rows-no-group =
+  (table-rows, (table-table-header-rows, table-rows?)?)
+  | (table-table-header-rows, table-rows?)
+table-rows =
+  table-table-rows | (text-soft-page-break?, table-table-row)+
+table-table-attlist &= attribute table:name { \string }?
+table-table-attlist &= attribute table:style-name { styleNameRef }?
+table-table-attlist &=
+  [ a:defaultValue = "false" ] attribute table:protected { boolean }?,
+  attribute table:protection-key { text }?
+table-table-attlist &=
+  [ a:defaultValue = "true" ] attribute table:print { boolean }?
+table-table-attlist &=
+  attribute table:print-ranges { cellRangeAddressList }?
+table-table-row =
+  element table:table-row {
+    table-table-row-attlist,
+    (table-table-cell | table-covered-table-cell)+
+  }
+table-table-row-attlist &=
+  [ a:defaultValue = "1" ]
+  attribute table:number-rows-repeated { positiveInteger }?
+table-table-row-attlist &= attribute table:style-name { styleNameRef }?
+table-table-row-attlist &=
+  attribute table:default-cell-style-name { styleNameRef }?
+table-table-row-attlist &=
+  [ a:defaultValue = "visible" ]
+  attribute table:visibility { table-visibility-value }?
+table-visibility-value = "visible" | "collapse" | "filter"
+table-table-cell =
+  element table:table-cell {
+    table-table-cell-attlist,
+    table-table-cell-attlist-extra,
+    table-table-cell-content
+  }
+table-covered-table-cell =
+  element table:covered-table-cell {
+    table-table-cell-attlist, table-table-cell-content
+  }
+table-table-cell-content =
+  table-cell-range-source?,
+  office-annotation?,
+  table-detective?,
+  text-content*
+table-table-cell-attlist &=
+  [ a:defaultValue = "1" ]
+  attribute table:number-columns-repeated { positiveInteger }?
+table-table-cell-attlist-extra &=
+  [ a:defaultValue = "1" ]
+  attribute table:number-columns-spanned { positiveInteger }?,
+  [ a:defaultValue = "1" ]
+  attribute table:number-rows-spanned { positiveInteger }?
+table-table-cell-attlist &= attribute table:style-name { styleNameRef }?
+table-table-cell-attlist &=
+  attribute table:content-validation-name { \string }?
+table-table-cell-attlist &= attribute table:formula { \string }?
+table-table-cell-attlist-extra &=
+  attribute table:number-matrix-columns-spanned { positiveInteger }?,
+  attribute table:number-matrix-rows-spanned { positiveInteger }?
+table-table-cell-attlist &= common-value-and-type-attlist?
+table-table-cell-attlist &=
+  [ a:defaultValue = "false" ] attribute table:protect { boolean }?
+table-table-column =
+  element table:table-column { table-table-column-attlist, empty }
+table-table-column-attlist &=
+  [ a:defaultValue = "1" ]
+  attribute table:number-columns-repeated { positiveInteger }?
+table-table-column-attlist &=
+  attribute table:style-name { styleNameRef }?
+table-table-column-attlist &=
+  [ a:defaultValue = "visible" ]
+  attribute table:visibility { table-visibility-value }?
+table-table-column-attlist &=
+  attribute table:default-cell-style-name { styleNameRef }?
+table-table-header-columns =
+  element table:table-header-columns { table-table-column+ }
+table-table-columns =
+  element table:table-columns { table-table-column+ }
+table-table-column-group =
+  element table:table-column-group {
+    table-table-column-group-attlist, table-columns-and-groups
+  }
+table-table-column-group-attlist &=
+  [ a:defaultValue = "true" ] attribute table:display { boolean }?
+table-table-header-rows =
+  element table:table-header-rows {
+    (text-soft-page-break?, table-table-row)+
+  }
+table-table-rows =
+  element table:table-rows { (text-soft-page-break?, table-table-row)+ }
+table-table-row-group =
+  element table:table-row-group {
+    table-table-row-group-attlist, table-rows-and-groups
+  }
+table-table-row-group-attlist &=
+  [ a:defaultValue = "true" ] attribute table:display { boolean }?
+table-table-attlist &=
+  [ a:defaultValue = "false" ] attribute table:is-sub-table { boolean }?
+cellAddress =
+  xsd:string {
+    pattern = "($?([^\. ']+|'([^']|'')+'))?\.$?[A-Z]+$?[0-9]+"
+  }
+cellRangeAddress =
+  xsd:string {
+    pattern =
+      "($?([^\. ']+|'([^']|'')+'))?\.$?[A-Z]+$?[0-9]+(:($?([^\. ']+|'([^']|'')+'))?\.$?[A-Z]+$?[0-9]+)?"
+  }
+cellRangeAddressList =
+  # Value is a space separated list of "cellRangeAddress" patterns
+  xsd:string
+table-table-source =
+  element table:table-source {
+    table-table-source-attlist, table-linked-source-attlist, empty
+  }
+table-table-source-attlist &=
+  [ a:defaultValue = "copy-all" ]
+  attribute table:mode { "copy-all" | "copy-results-only" }?
+table-table-source-attlist &= attribute table:table-name { \string }?
+table-linked-source-attlist &=
+  [ a:defaultValue = "simple" ] attribute xlink:type { "simple" }?,
+  [ a:defaultValue = "onRequest" ]
+  attribute xlink:actuate { "onRequest" }?,
+  attribute xlink:href { anyURI }
+table-linked-source-attlist &= attribute table:filter-name { \string }?
+table-linked-source-attlist &=
+  attribute table:filter-options { \string }?
+table-linked-source-attlist &=
+  attribute table:refresh-delay { duration }?
+table-scenario =
+  element table:scenario { table-scenario-attlist, empty }
+table-scenario-attlist &=
+  attribute table:scenario-ranges { cellRangeAddressList }
+table-scenario-attlist &= attribute table:is-active { boolean }
+table-scenario-attlist &=
+  [ a:defaultValue = "true" ]
+  attribute table:display-border { boolean }?
+table-scenario-attlist &= attribute table:border-color { color }?
+table-scenario-attlist &=
+  [ a:defaultValue = "true" ] attribute table:copy-back { boolean }?
+table-scenario-attlist &=
+  [ a:defaultValue = "true" ] attribute table:copy-styles { boolean }?
+table-scenario-attlist &=
+  [ a:defaultValue = "true" ] attribute table:copy-formulas { boolean }?
+table-scenario-attlist &= attribute table:comment { \string }?
+table-scenario-attlist &= attribute table:protected { boolean }?
+table-shapes = element table:shapes { shape+ }
+table-cell-range-source =
+  element table:cell-range-source {
+    table-table-cell-range-source-attlist,
+    table-linked-source-attlist,
+    empty
+  }
+table-table-cell-range-source-attlist &=
+  attribute table:name { \string }
+table-table-cell-range-source-attlist &=
+  attribute table:last-column-spanned { positiveInteger },
+  attribute table:last-row-spanned { positiveInteger }
+table-detective =
+  element table:detective { table-highlighted-range*, table-operation* }
+table-operation =
+  element table:operation { table-operation-attlist, empty }
+table-operation-attlist &=
+  attribute table:name {
+    "trace-dependents"
+    | "remove-dependents"
+    | "trace-precedents"
+    | "remove-precedents"
+    | "trace-errors"
+  }
+table-operation-attlist &= attribute table:index { nonNegativeInteger }
+table-highlighted-range =
+  element table:highlighted-range {
+    (table-highlighted-range-attlist
+     | table-highlighted-range-attlist-invalid),
+    empty
+  }
+table-highlighted-range-attlist &=
+  attribute table:cell-range-address { cellRangeAddress }?
+table-highlighted-range-attlist &=
+  attribute table:direction {
+    "from-another-table" | "to-another-table" | "from-same-table"
+  }
+table-highlighted-range-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute table:contains-error { boolean }?
+table-highlighted-range-attlist-invalid &=
+  attribute table:marked-invalid { boolean }
+office-spreadsheet-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute table:structure-protected { boolean }?,
+  attribute table:protection-key { \string }?
+table-calculation-settings =
+  element table:calculation-settings {
+    table-calculation-setting-attlist,
+    table-null-date?,
+    table-iteration?
+  }
+table-calculation-setting-attlist &=
+  [ a:defaultValue = "true" ]
+  attribute table:case-sensitive { boolean }?
+table-calculation-setting-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute table:precision-as-shown { boolean }?
+table-calculation-setting-attlist &=
+  [ a:defaultValue = "true" ]
+  attribute table:search-criteria-must-apply-to-whole-cell { boolean }?
+table-calculation-setting-attlist &=
+  [ a:defaultValue = "true" ]
+  attribute table:automatic-find-labels { boolean }?
+table-calculation-setting-attlist &=
+  [ a:defaultValue = "true" ]
+  attribute table:use-regular-expressions { boolean }?
+table-calculation-setting-attlist &=
+  [ a:defaultValue = "1930" ]
+  attribute table:null-year { positiveInteger }?
+table-null-date =
+  element table:null-date {
+    [ a:defaultValue = "date" ]
+    attribute table:value-type { valueType }?,
+    [ a:defaultValue = "1899-12-30" ]
+    attribute table:date-value { date }?,
+    empty
+  }
+table-iteration =
+  element table:iteration {
+    [ a:defaultValue = "disable" ]
+    attribute table:status { "enable" | "disable" }?,
+    [ a:defaultValue = "100" ]
+    attribute table:steps { positiveInteger }?,
+    [ a:defaultValue = "0.001" ]
+    attribute table:maximum-difference { double }?,
+    empty
+  }
+table-content-validations =
+  element table:content-validations { table-content-validation+ }
+table-content-validation =
+  element table:content-validation {
+    table-validation-attlist,
+    table-help-message?,
+    (table-error-message
+     | (table-error-macro, office-event-listeners?))?
+  }
+table-validation-attlist &= attribute table:name { \string }
+table-validation-attlist &= attribute table:condition { \string }?
+table-validation-attlist &=
+  attribute table:base-cell-address { cellAddress }?
+table-validation-attlist &=
+  [ a:defaultValue = "true" ]
+  attribute table:allow-empty-cell { boolean }?
+table-validation-attlist &=
+  [ a:defaultValue = "unsorted" ]
+  attribute table:display-list {
+    "none" | "unsorted" | "sort-ascending"
+  }?
+table-help-message =
+  element table:help-message {
+    attribute table:title { \string }?,
+    [ a:defaultValue = "false" ] attribute table:display { boolean }?,
+    text-p*
+  }
+table-error-message =
+  element table:error-message {
+    attribute table:title { \string }?,
+    [ a:defaultValue = "false" ] attribute table:display { boolean }?,
+    [ a:defaultValue = "stop" ]
+    attribute table:message-type {
+      "stop" | "warning" | "information"
+    }?,
+    text-p*
+  }
+table-error-macro =
+  element table:error-macro {
+    [ a:defaultValue = "true" ] attribute table:execute { boolean }?
+  }
+table-label-ranges = element table:label-ranges { table-label-range* }
+table-label-range =
+  element table:label-range { table-label-range-attlist, empty }
+table-label-range-attlist &=
+  attribute table:label-cell-range-address { cellRangeAddress }
+table-label-range-attlist &=
+  attribute table:data-cell-range-address { cellRangeAddress }
+table-label-range-attlist &=
+  attribute table:orientation { "column" | "row" }
+table-named-expressions =
+  element table:named-expressions {
+    (table-named-range | table-named-expression)*
+  }
+table-named-range =
+  element table:named-range { table-named-range-attlist, empty }
+table-named-range-attlist &=
+  attribute table:name { \string },
+  attribute table:cell-range-address { cellRangeAddress },
+  attribute table:base-cell-address { cellAddress }?,
+  [ a:defaultValue = "none" ]
+  attribute table:range-usable-as {
+    "none"
+    | list {
+        ("print-range" | "filter" | "repeat-row" | "repeat-column")+
+      }
+  }?
+table-named-expression =
+  element table:named-expression {
+    table-named-expression-attlist, empty
+  }
+table-named-expression-attlist &=
+  attribute table:name { \string },
+  attribute table:expression { \string },
+  attribute table:base-cell-address { cellAddress }?
+table-database-ranges =
+  element table:database-ranges { table-database-range* }
+table-database-range =
+  element table:database-range {
+    table-database-range-attlist,
+    (table-database-source-sql
+     | table-database-source-table
+     | table-database-source-query)?,
+    table-filter?,
+    table-sort?,
+    table-subtotal-rules?
+  }
+table-database-range-attlist &= attribute table:name { \string }?
+table-database-range-attlist &=
+  [ a:defaultValue = "false" ] attribute table:is-selection { boolean }?
+table-database-range-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute table:on-update-keep-styles { boolean }?
+table-database-range-attlist &=
+  [ a:defaultValue = "true" ]
+  attribute table:on-update-keep-size { boolean }?
+table-database-range-attlist &=
+  [ a:defaultValue = "true" ]
+  attribute table:has-persistent-data { boolean }?
+table-database-range-attlist &=
+  [ a:defaultValue = "row" ]
+  attribute table:orientation { "column" | "row" }?
+table-database-range-attlist &=
+  [ a:defaultValue = "true" ]
+  attribute table:contains-header { boolean }?
+table-database-range-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute table:display-filter-buttons { boolean }?
+table-database-range-attlist &=
+  attribute table:target-range-address { cellRangeAddress }
+table-database-range-attlist &=
+  attribute table:refresh-delay { boolean }?
+table-database-source-sql =
+  element table:database-source-sql {
+    table-database-source-sql-attlist, empty
+  }
+table-database-source-sql-attlist &=
+  attribute table:database-name { \string }
+table-database-source-sql-attlist &=
+  attribute table:sql-statement { \string }
+table-database-source-sql-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute table:parse-sql-statement { boolean }?
+table-database-source-query =
+  element table:database-source-table {
+    table-database-source-table-attlist, empty
+  }
+table-database-source-table-attlist &=
+  attribute table:database-name { \string }
+table-database-source-table-attlist &=
+  attribute table:database-table-name { \string }
+table-database-source-table =
+  element table:database-source-query {
+    table-database-source-query-attlist, empty
+  }
+table-database-source-query-attlist &=
+  attribute table:database-name { \string }
+table-database-source-query-attlist &=
+  attribute table:query-name { \string }
+table-sort = element table:sort { table-sort-attlist, table-sort-by+ }
+table-sort-attlist &=
+  [ a:defaultValue = "true" ]
+  attribute table:bind-styles-to-content { boolean }?
+table-sort-attlist &=
+  attribute table:target-range-address { cellRangeAddress }?
+table-sort-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute table:case-sensitive { boolean }?
+table-sort-attlist &= attribute table:language { languageCode }?
+table-sort-attlist &= attribute table:country { countryCode }?
+table-sort-attlist &= attribute table:algorithm { \string }?
+table-sort-by = element table:sort-by { table-sort-by-attlist, empty }
+table-sort-by-attlist &=
+  attribute table:field-number { nonNegativeInteger }
+table-sort-by-attlist &=
+  [ a:defaultValue = "automatic" ]
+  attribute table:data-type {
+    "text" | "number" | "automatic" | \string
+  }?
+table-sort-by-attlist &=
+  [ a:defaultValue = "ascending" ]
+  attribute table:order { "ascending" | "descending" }?
+table-subtotal-rules =
+  element table:subtotal-rules {
+    table-subtotal-rules-attlist,
+    table-sort-groups?,
+    table-subtotal-rule*
+  }
+table-subtotal-rules-attlist &=
+  [ a:defaultValue = "true" ]
+  attribute table:bind-styles-to-content { boolean }?
+table-subtotal-rules-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute table:case-sensitive { boolean }?
+table-subtotal-rules-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute table:page-breaks-on-group-change { boolean }?
+table-sort-groups =
+  element table:sort-groups { table-sort-groups-attlist, empty }
+table-sort-groups-attlist &=
+  [ a:defaultValue = "automatic" ]
+  attribute table:data-type {
+    "text" | "number" | "automatic" | \string
+  }?
+table-sort-groups-attlist &=
+  [ a:defaultValue = "ascending" ]
+  attribute table:order { "ascending" | "descending" }?
+table-subtotal-rule =
+  element table:subtotal-rule {
+    table-subtotal-rule-attlist, table-subtotal-field*
+  }
+table-subtotal-rule-attlist &=
+  attribute table:group-by-field-number { nonNegativeInteger }
+table-subtotal-field =
+  element table:subtotal-field { table-subtotal-field-attlist, empty }
+table-subtotal-field-attlist &=
+  attribute table:field-number { nonNegativeInteger }
+table-subtotal-field-attlist &=
+  attribute table:function {
+    "auto"
+    | "average"
+    | "count"
+    | "countnums"
+    | "max"
+    | "min"
+    | "product"
+    | "stdev"
+    | "stdevp"
+    | "sum"
+    | "var"
+    | "varp"
+    | \string
+  }
+table-filter =
+  element table:filter {
+    table-filter-attlist,
+    (table-filter-condition | table-filter-and | table-filter-or)
+  }
+table-filter-attlist &=
+  attribute table:target-range-address { cellRangeAddress }?
+table-filter-attlist &=
+  [ a:defaultValue = "self" ]
+  attribute table:condition-source { "self" | "cell-range" }?
+table-filter-attlist &=
+  attribute table:condition-source-range-address { cellRangeAddress }?
+table-filter-attlist &=
+  [ a:defaultValue = "true" ]
+  attribute table:display-duplicates { boolean }?
+table-filter-and =
+  element table:filter-and {
+    (table-filter-or | table-filter-condition)+
+  }
+table-filter-or =
+  element table:filter-or {
+    (table-filter-and | table-filter-condition)+
+  }
+table-filter-condition =
+  element table:filter-condition {
+    table-filter-condition-attlist, empty
+  }
+table-filter-condition-attlist &=
+  attribute table:field-number { nonNegativeInteger }
+table-filter-condition-attlist &= attribute table:value { \string }
+table-filter-condition-attlist &= attribute table:operator { \string }
+table-filter-condition-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute table:case-sensitive { \string }?
+table-filter-condition-attlist &=
+  [ a:defaultValue = "text" ]
+  attribute table:data-type { "text" | "number" }?
+table-data-pilot-tables =
+  element table:data-pilot-tables { table-data-pilot-table* }
+table-data-pilot-table =
+  element table:data-pilot-table {
+    table-data-pilot-table-attlist,
+    (table-database-source-sql
+     | table-database-source-table
+     | table-database-source-query
+     | table-source-service
+     | table-source-cell-range)?,
+    table-data-pilot-field+
+  }
+table-data-pilot-table-attlist &= attribute table:name { \string }
+table-data-pilot-table-attlist &=
+  attribute table:application-data { \string }?
+table-data-pilot-table-attlist &=
+  [ a:defaultValue = "both" ]
+  attribute table:grand-total { "none" | "row" | "column" | "both" }?
+table-data-pilot-table-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute table:ignore-empty-rows { boolean }?
+table-data-pilot-table-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute table:identify-categories { boolean }?
+table-data-pilot-table-attlist &=
+  attribute table:target-range-address { cellRangeAddress }
+table-data-pilot-table-attlist &=
+  attribute table:buttons { cellRangeAddressList }?
+table-data-pilot-table-attlist &=
+  [ a:defaultValue = "true" ]
+  attribute table:show-filter-button { boolean }?
+table-data-pilot-table-attlist &=
+  [ a:defaultValue = "true" ]
+  attribute table:drill-down-on-double-click { boolean }?
+table-source-cell-range =
+  element table:source-cell-range {
+    table-source-cell-range-attlist, table-filter?
+  }
+table-source-cell-range-attlist &=
+  attribute table:cell-range-address { cellRangeAddress }
+table-source-service =
+  element table:source-service { table-source-service-attlist, empty }
+table-source-service-attlist &= attribute table:name { \string }
+table-source-service-attlist &= attribute table:source-name { \string }
+table-source-service-attlist &= attribute table:object-name { \string }
+table-source-service-attlist &= attribute table:user-name { \string }?
+table-source-service-attlist &= attribute table:password { \string }?
+table-data-pilot-field =
+  element table:data-pilot-field {
+    table-data-pilot-field-attlist,
+    table-data-pilot-level?,
+    table-data-pilot-field-reference?,
+    table-data-pilot-groups?
+  }
+table-data-pilot-field-attlist &=
+  attribute table:source-field-name { \string }
+table-data-pilot-field-attlist &=
+  attribute table:orientation { "row" | "column" | "data" | "hidden" }
+  | (attribute table:orientation { "page" },
+     attribute table:selected-page { \string })
+table-data-pilot-field-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute table:is-data-layout-field { \string }?
+table-data-pilot-field-attlist &=
+  attribute table:function {
+    "auto"
+    | "average"
+    | "count"
+    | "countnums"
+    | "max"
+    | "min"
+    | "product"
+    | "stdev"
+    | "stdevp"
+    | "sum"
+    | "var"
+    | "varp"
+    | \string
+  }?
+table-data-pilot-field-attlist &=
+  [ a:defaultValue = "-1" ] attribute table:used-hierarchy { integer }?
+table-data-pilot-level =
+  element table:data-pilot-level {
+    table-data-pilot-level-attlist,
+    table-data-pilot-subtotals?,
+    table-data-pilot-members?,
+    table-data-pilot-display-info?,
+    table-data-pilot-sort-info?,
+    table-data-pilot-layout-info?
+  }
+table-data-pilot-level-attlist &=
+  attribute table:show-empty { boolean }?
+table-data-pilot-subtotals =
+  element table:data-pilot-subtotals { table-data-pilot-subtotal* }
+table-data-pilot-subtotal =
+  element table:data-pilot-subtotal {
+    table-data-pilot-subtotal-attlist, empty
+  }
+table-data-pilot-subtotal-attlist &=
+  attribute table:function {
+    "auto"
+    | "average"
+    | "count"
+    | "countnums"
+    | "max"
+    | "min"
+    | "product"
+    | "stdev"
+    | "stdevp"
+    | "sum"
+    | "var"
+    | "varp"
+    | \string
+  }
+table-data-pilot-members =
+  element table:data-pilot-members { table-data-pilot-member* }
+table-data-pilot-member =
+  element table:data-pilot-member {
+    table-data-pilot-member-attlist, empty
+  }
+table-data-pilot-member-attlist &= attribute table:name { \string }
+table-data-pilot-member-attlist &= attribute table:display { boolean }?
+table-data-pilot-member-attlist &=
+  attribute table:show-details { boolean }?
+table-data-pilot-display-info =
+  element table:data-pilot-display-info {
+    table-data-pilot-display-info-attlist, empty
+  }
+table-data-pilot-display-info-attlist &=
+  attribute table:enabled { boolean }
+table-data-pilot-display-info-attlist &=
+  attribute table:data-field { \string }
+table-data-pilot-display-info-attlist &=
+  attribute table:member-count { nonNegativeInteger }
+table-data-pilot-display-info-attlist &=
+  attribute table:display-member-mode { "from-top" | "from-bottom" }
+table-data-pilot-sort-info =
+  element table:data-pilot-sort-info {
+    table-data-pilot-sort-info-attlist, empty
+  }
+table-data-pilot-sort-info-attlist &=
+  (attribute table:sort-mode { "data" },
+   attribute table:data-field { \string })
+  | attribute table:sort-mode { "none" | "manual" | "name" }
+table-data-pilot-sort-info-attlist &=
+  attribute table:order { "ascending" | "descending" }
+table-data-pilot-layout-info =
+  element table:data-pilot-layout-info {
+    table-data-pilot-layout-info-attlist, empty
+  }
+table-data-pilot-layout-info-attlist &=
+  attribute table:layout-mode {
+    "tabular-layout"
+    | "outline-subtotals-top"
+    | "outline-subtotals-bottom"
+  }
+table-data-pilot-layout-info-attlist &=
+  attribute table:add-empty-lines { boolean }
+table-data-pilot-field-reference =
+  element table:data-pilot-field-reference {
+    table-data-pilot-field-reference-attlist
+  }
+table-data-pilot-field-reference-attlist &=
+  attribute table:field-name { \string }
+table-data-pilot-field-reference-attlist &=
+  (attribute table:member-type { "named" },
+   attribute table:member-name { \string })
+  | attribute table:member-type { "previous" | "next" }
+table-data-pilot-field-reference-attlist &=
+  attribute table:type {
+    "none"
+    | "member-difference"
+    | "member-percentage"
+    | "member-percentage-difference"
+    | "running-total"
+    | "row-percentage"
+    | "column-percentage"
+    | "total-percentage"
+    | "index"
+  }
+table-data-pilot-groups =
+  element table:data-pilot-groups {
+    table-data-pilot-groups-attlist, table-data-pilot-group+
+  }
+table-data-pilot-groups-attlist &=
+  attribute table:source-field-name { \string }
+table-data-pilot-groups-attlist &=
+  attribute table:date-start { dateOrDateTime | "auto" }
+  | attribute table:start { double | "auto" }
+table-data-pilot-groups-attlist &=
+  attribute table:date-end { dateOrDateTime | "auto" }
+  | attribute table:end { double | "auto" }
+table-data-pilot-groups-attlist &= attribute table:step { double }
+table-data-pilot-groups-attlist &=
+  attribute table:grouped-by {
+    "seconds"
+    | "minutes"
+    | "hours"
+    | "days"
+    | "months"
+    | "quarters"
+    | "years"
+  }
+table-data-pilot-group =
+  element table:data-pilot-group {
+    table-data-pilot-group-attlist, table-data-pilot-group-member+
+  }
+table-data-pilot-group-attlist &= attribute table:name { \string }
+table-data-pilot-group-member =
+  element table:data-pilot-group-member {
+    table-data-pilot-group-member-attlist
+  }
+table-data-pilot-group-member-attlist &=
+  attribute table:name { \string }
+table-consolidation =
+  element table:consolidation { table-consolidation-attlist, empty }
+table-consolidation-attlist &=
+  attribute table:function {
+    "auto"
+    | "average"
+    | "count"
+    | "countnums"
+    | "max"
+    | "min"
+    | "product"
+    | "stdev"
+    | "stdevp"
+    | "sum"
+    | "var"
+    | "varp"
+    | \string
+  }
+table-consolidation-attlist &=
+  attribute table:source-cell-range-addresses { cellRangeAddressList }
+table-consolidation-attlist &=
+  attribute table:target-cell-address { cellAddress }
+table-consolidation-attlist &=
+  [ a:defaultValue = "none" ]
+  attribute table:use-labels { "none" | "row" | "column" | "both" }?
+table-consolidation-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute table:link-to-source-data { boolean }?
+table-dde-links = element table:dde-links { table-dde-link+ }
+table-tracked-changes =
+  element table:tracked-changes {
+    table-tracked-changes-attlist,
+    (table-cell-content-change
+     | table-insertion
+     | table-deletion
+     | table-movement)*
+  }
+table-tracked-changes-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute table:track-changes { boolean }?
+table-insertion =
+  element table:insertion {
+    table-insertion-attlist,
+    common-table-change-attlist,
+    office-change-info,
+    table-dependencies?,
+    table-deletions?
+  }
+table-insertion-attlist &=
+  attribute table:type { "row" | "column" | "table" }
+table-insertion-attlist &= attribute table:position { integer }
+table-insertion-attlist &=
+  [ a:defaultValue = "1" ] attribute table:count { positiveInteger }?
+table-insertion-attlist &= attribute table:table { integer }?
+table-dependencies = element table:dependencies { table-dependency+ }
+table-dependency =
+  element table:dependency {
+    attribute table:id { \string },
+    empty
+  }
+table-deletions =
+  element table:deletions {
+    (table-cell-content-deletion | table-change-deletion)+
+  }
+table-cell-content-deletion =
+  element table:cell-content-deletion {
+    attribute table:id { \string }?,
+    table-cell-address?,
+    table-change-track-table-cell?
+  }
+table-change-deletion =
+  element table:change-deletion {
+    attribute table:id { \string }?,
+    empty
+  }
+table-deletion =
+  element table:deletion {
+    table-deletion-attlist,
+    common-table-change-attlist,
+    office-change-info,
+    table-dependencies?,
+    table-deletions?,
+    table-cut-offs?
+  }
+table-deletion-attlist &=
+  attribute table:type { "row" | "column" | "table" }
+table-deletion-attlist &= attribute table:position { integer }
+table-deletion-attlist &= attribute table:table { integer }?
+table-deletion-attlist &=
+  attribute table:multi-deletion-spanned { integer }?
+table-cut-offs =
+  element table:cut-offs {
+    table-movement-cut-off+
+    | (table-insertion-cut-off, table-movement-cut-off*)
+  }
+table-insertion-cut-off =
+  element table:insertion-cut-off {
+    table-insertion-cut-off-attlist, empty
+  }
+table-insertion-cut-off-attlist &= attribute table:id { \string }
+table-insertion-cut-off-attlist &= attribute table:position { integer }
+table-movement-cut-off =
+  element table:movement-cut-off {
+    table-movement-cut-off-attlist, empty
+  }
+table-movement-cut-off-attlist &=
+  attribute table:position { integer }
+  | (attribute table:start-position { integer },
+     attribute table:end-position { integer })
+table-movement =
+  element table:movement {
+    common-table-change-attlist,
+    table-source-range-address,
+    table-target-range-address,
+    office-change-info,
+    table-dependencies?,
+    table-deletions?
+  }
+table-source-range-address =
+  element table:source-range-address {
+    common-table-range-attlist, empty
+  }
+table-target-range-address =
+  element table:target-range-address {
+    common-table-range-attlist, empty
+  }
+common-table-range-attlist &=
+  common-table-cell-address-attlist
+  | common-table-cell-range-address-attlist
+common-table-cell-address-attlist &=
+  attribute table:column { integer },
+  attribute table:row { integer },
+  attribute table:table { integer }
+common-table-cell-range-address-attlist &=
+  attribute table:start-column { integer },
+  attribute table:start-row { integer },
+  attribute table:start-table { integer },
+  attribute table:end-column { integer },
+  attribute table:end-row { integer },
+  attribute table:end-table { integer }
+table-change-track-table-cell &=
+  element table:change-track-table-cell {
+    table-change-track-table-cell-attlist, text-p*
+  }
+table-change-track-table-cell-attlist &=
+  attribute table:cell-address { cellAddress }?
+table-change-track-table-cell-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute table:matrix-covered { boolean }?
+table-change-track-table-cell-attlist &=
+  attribute table:formula { \string }?,
+  attribute table:number-matrix-columns-spanned { positiveInteger }?,
+  attribute table:number-matrix-rows-spanned { positiveInteger }?,
+  common-value-and-type-attlist?
+table-cell-content-change =
+  element table:cell-content-change {
+    common-table-change-attlist,
+    table-cell-address,
+    office-change-info,
+    table-dependencies?,
+    table-deletions?,
+    table-previous
+  }
+table-cell-address =
+  element table:cell-address {
+    common-table-cell-address-attlist, empty
+  }
+table-previous =
+  element table:previous {
+    attribute table:id { \string }?,
+    table-change-track-table-cell
+  }
+common-table-change-attlist &= attribute table:id { \string }
+common-table-change-attlist &=
+  [ a:defaultValue = "pending" ]
+  attribute table:acceptance-state {
+    "accepted" | "rejected" | "pending"
+  }?
+common-table-change-attlist &=
+  attribute table:rejecting-change-id { \string }?
+style-handout-master =
+  element style:handout-master {
+    common-presentation-header-footer-attlist,
+    style-handout-master-attlist,
+    shape*
+  }
+style-handout-master-attlist &=
+  attribute presentation:presentation-page-layout-name { styleNameRef }?
+style-handout-master-attlist &=
+  attribute style:page-layout-name { styleNameRef }
+style-handout-master-attlist &=
+  attribute draw:style-name { styleNameRef }?
+draw-layer-set = element draw:layer-set { draw-layer* }
+draw-layer =
+  element draw:layer { draw-layer-attlist, svg-title?, svg-desc? }
+draw-layer-attlist &= attribute draw:name { \string }
+draw-layer-attlist &=
+  [ a:defaultValue = "false" ] attribute draw:protected { boolean }?
+draw-layer-attlist &=
+  [ a:defaultValue = "always" ]
+  attribute draw:display { "always" | "screen" | "printer" | "none" }?
+draw-page =
+  element draw:page {
+    common-presentation-header-footer-attlist,
+    draw-page-attlist,
+    office-forms?,
+    shape*,
+    (presentation-animations | animation-element)?,
+    presentation-notes?
+  }
+draw-page-attlist &= attribute draw:name { \string }?
+draw-page-attlist &= attribute draw:style-name { styleNameRef }?
+draw-page-attlist &= attribute draw:master-page-name { styleNameRef }
+draw-page-attlist &=
+  attribute presentation:presentation-page-layout-name { styleNameRef }?
+common-presentation-header-footer-attlist &=
+  attribute presentation:use-header-name { \string }?
+common-presentation-header-footer-attlist &=
+  attribute presentation:use-footer-name { \string }?
+common-presentation-header-footer-attlist &=
+  attribute presentation:use-date-time-name { \string }?
+draw-page-attlist &= attribute draw:id { ID }?
+draw-page-attlist &= attribute draw:nav-order { IDREFS }?
+shape =
+  draw-rect
+  | draw-line
+  | draw-polyline
+  | draw-polygon
+  | draw-regular-polygon
+  | draw-path
+  | draw-circle
+  | draw-ellipse
+  | draw-g
+  | draw-page-thumbnail
+  | draw-frame
+  | draw-measure
+  | draw-caption
+  | draw-connector
+  | draw-control
+  | dr3d-scene
+  | draw-custom-shape
+draw-rect =
+  element draw:rect {
+    draw-rect-attlist,
+    common-draw-position-attlist,
+    common-draw-size-attlist,
+    common-draw-shape-with-text-and-styles-attlist,
+    common-draw-caption-id-attlist,
+    svg-title?,
+    svg-desc?,
+    office-event-listeners?,
+    draw-glue-point*,
+    draw-text
+  }
+draw-rect-attlist &= attribute draw:corner-radius { nonNegativeLength }?
+draw-line =
+  element draw:line {
+    draw-line-attlist,
+    common-draw-shape-with-text-and-styles-attlist,
+    common-draw-caption-id-attlist,
+    svg-title?,
+    svg-desc?,
+    office-event-listeners?,
+    draw-glue-point*,
+    draw-text
+  }
+draw-line-attlist &=
+  attribute svg:x1 { coordinate },
+  attribute svg:y1 { coordinate }
+draw-line-attlist &=
+  attribute svg:x2 { coordinate },
+  attribute svg:y2 { coordinate }
+draw-polyline =
+  element draw:polyline {
+    common-draw-points-attlist,
+    common-draw-position-attlist,
+    common-draw-size-attlist,
+    common-draw-viewbox-attlist,
+    common-draw-shape-with-text-and-styles-attlist,
+    common-draw-caption-id-attlist,
+    svg-title?,
+    svg-desc?,
+    office-event-listeners?,
+    draw-glue-point*,
+    draw-text
+  }
+common-draw-points-attlist = attribute draw:points { points }
+draw-polygon =
+  element draw:polygon {
+    common-draw-points-attlist,
+    common-draw-position-attlist,
+    common-draw-size-attlist,
+    common-draw-viewbox-attlist,
+    common-draw-shape-with-text-and-styles-attlist,
+    common-draw-caption-id-attlist,
+    svg-title?,
+    svg-desc?,
+    office-event-listeners?,
+    draw-glue-point*,
+    draw-text
+  }
+draw-regular-polygon =
+  element draw:regular-polygon {
+    draw-regular-polygon-attlist,
+    common-draw-position-attlist,
+    common-draw-size-attlist,
+    common-draw-shape-with-text-and-styles-attlist,
+    common-draw-caption-id-attlist,
+    svg-title?,
+    svg-desc?,
+    office-event-listeners?,
+    draw-glue-point*,
+    draw-text
+  }
+draw-regular-polygon-attlist &=
+  attribute draw:concave { "false" }
+  | (attribute draw:concave { "true" },
+     draw-regular-polygon-sharpness-attlist)
+draw-regular-polygon-attlist &=
+  attribute draw:corners { positiveInteger }
+draw-regular-polygon-sharpness-attlist =
+  attribute draw:sharpness { percent }
+draw-path =
+  element draw:path {
+    common-draw-path-data-attlist,
+    common-draw-position-attlist,
+    common-draw-size-attlist,
+    common-draw-viewbox-attlist,
+    common-draw-shape-with-text-and-styles-attlist,
+    common-draw-caption-id-attlist,
+    svg-title?,
+    svg-desc?,
+    office-event-listeners?,
+    draw-glue-point*,
+    draw-text
+  }
+common-draw-path-data-attlist = attribute svg:d { pathData }
+draw-circle =
+  element draw:circle {
+    draw-circle-attlist,
+    common-draw-circle-ellipse-attlist,
+    common-draw-position-attlist,
+    common-draw-size-attlist,
+    common-draw-shape-with-text-and-styles-attlist,
+    common-draw-caption-id-attlist,
+    svg-title?,
+    svg-desc?,
+    office-event-listeners?,
+    draw-glue-point*,
+    draw-text
+  }
+common-draw-circle-ellipse-attlist &=
+  (attribute svg:cx { coordinate },
+   attribute svg:cy { coordinate })?
+draw-circle-attlist &= attribute svg:r { length }?
+common-draw-circle-ellipse-attlist &=
+  [ a:defaultValue = "full" ]
+  attribute draw:kind { "full" | "section" | "cut" | "arc" }?
+common-draw-circle-ellipse-attlist &=
+  attribute draw:start-angle { double }?
+common-draw-circle-ellipse-attlist &=
+  attribute draw:end-angle { double }?
+draw-ellipse =
+  element draw:ellipse {
+    common-draw-circle-ellipse-attlist,
+    draw-ellipse-attlist,
+    common-draw-position-attlist,
+    common-draw-size-attlist,
+    common-draw-shape-with-text-and-styles-attlist,
+    common-draw-caption-id-attlist,
+    svg-title?,
+    svg-desc?,
+    office-event-listeners?,
+    draw-glue-point*,
+    draw-text
+  }
+draw-ellipse-attlist &=
+  (attribute svg:rx { length },
+   attribute svg:ry { length })?
+draw-connector =
+  element draw:connector {
+    draw-connector-attlist,
+    common-draw-shape-with-text-and-styles-attlist,
+    common-draw-caption-id-attlist,
+    svg-title?,
+    svg-desc?,
+    office-event-listeners?,
+    draw-glue-point*,
+    draw-text
+  }
+draw-connector-attlist &=
+  [ a:defaultValue = "standard" ]
+  attribute draw:type { "standard" | "lines" | "line" | "curve" }?
+draw-connector-attlist &=
+  (attribute svg:x1 { coordinate },
+   attribute svg:y1 { coordinate })?
+draw-connector-attlist &= attribute draw:start-shape { IDREF }?
+draw-connector-attlist &=
+  attribute draw:start-glue-point { nonNegativeInteger }?
+draw-connector-attlist &=
+  (attribute svg:x2 { coordinate },
+   attribute svg:y2 { coordinate })?
+draw-connector-attlist &= attribute draw:end-shape { IDREF }?
+draw-connector-attlist &=
+  attribute draw:end-glue-point { nonNegativeInteger }?
+draw-connector-attlist &=
+  attribute draw:line-skew {
+    list { length, (length, length?)? }
+  }?
+draw-caption =
+  element draw:caption {
+    draw-caption-attlist,
+    common-draw-position-attlist,
+    common-draw-size-attlist,
+    common-draw-shape-with-text-and-styles-attlist,
+    common-draw-caption-id-attlist,
+    svg-title?,
+    svg-desc?,
+    office-event-listeners?,
+    draw-glue-point*,
+    draw-text
+  }
+draw-caption-attlist &=
+  (attribute draw:caption-point-x { coordinate },
+   attribute draw:caption-point-y { coordinate })?
+draw-caption-attlist &=
+  attribute draw:corner-radius { nonNegativeLength }?
+draw-measure =
+  element draw:measure {
+    draw-measure-attlist,
+    common-draw-shape-with-text-and-styles-attlist,
+    common-draw-caption-id-attlist,
+    svg-title?,
+    svg-desc?,
+    office-event-listeners?,
+    draw-glue-point*,
+    draw-text
+  }
+draw-measure-attlist &=
+  attribute svg:x1 { coordinate },
+  attribute svg:y1 { coordinate }
+draw-measure-attlist &=
+  attribute svg:x2 { coordinate },
+  attribute svg:y2 { coordinate }
+draw-control =
+  element draw:control {
+    draw-control-attlist,
+    common-draw-position-attlist,
+    common-draw-size-attlist,
+    common-draw-shape-with-text-and-styles-attlist,
+    common-draw-caption-id-attlist,
+    svg-title?,
+    svg-desc?,
+    draw-glue-point*
+  }
+draw-control-attlist &= attribute draw:control { IDREF }
+draw-page-thumbnail =
+  element draw:page-thumbnail {
+    draw-page-thumbnail-attlist,
+    common-draw-position-attlist,
+    common-draw-size-attlist,
+    presentation-shape-attlist,
+    common-draw-shape-with-styles-attlist,
+    common-draw-caption-id-attlist,
+    svg-title?,
+    svg-desc?
+  }
+draw-page-thumbnail-attlist =
+  attribute draw:page-number { positiveInteger }?
+draw-g =
+  element draw:g {
+    draw-g-attlist,
+    common-draw-z-index-attlist,
+    common-draw-name-attlist,
+    common-draw-id-attlist,
+    common-draw-style-name-attlist,
+    common-text-spreadsheet-shape-attlist,
+    common-draw-caption-id-attlist,
+    svg-title?,
+    svg-desc?,
+    office-event-listeners?,
+    draw-glue-point*,
+    shape*
+  }
+draw-g-attlist &= attribute svg:y { coordinate }?
+common-draw-name-attlist &= attribute draw:name { \string }?
+common-draw-caption-id-attlist &= attribute draw:caption-id { IDREF }?
+common-draw-position-attlist =
+  attribute svg:x { coordinate }?,
+  attribute svg:y { coordinate }?
+common-draw-size-attlist =
+  attribute svg:width { length }?,
+  attribute svg:height { length }?
+common-draw-transform-attlist = attribute draw:transform { \string }?
+common-draw-viewbox-attlist =
+  attribute svg:viewBox {
+    list { integer, integer, integer, integer }
+  }
+common-draw-style-name-attlist =
+  (attribute draw:style-name { styleNameRef }?,
+   attribute draw:class-names { styleNameRefs }?)
+  | (attribute presentation:style-name { styleNameRef }?,
+     attribute presentation:class-names { styleNameRefs }?)
+common-draw-text-style-name-attlist =
+  attribute draw:text-style-name { styleNameRef }?
+common-draw-layer-name-attlist = attribute draw:layer { xsd:string }?
+common-draw-id-attlist = attribute draw:id { ID }?
+common-draw-z-index-attlist =
+  attribute draw:z-index { nonNegativeInteger }?
+common-text-spreadsheet-shape-attlist &=
+  attribute table:end-cell-address { cellAddress }?,
+  attribute table:end-x { coordinate }?,
+  attribute table:end-y { coordinate }?
+common-text-spreadsheet-shape-attlist &=
+  attribute table:table-background { boolean }?
+common-text-spreadsheet-shape-attlist &= common-text-anchor-attlist
+common-text-anchor-attlist &=
+  attribute text:anchor-type {
+    "page" | "frame" | "paragraph" | "char" | "as-char"
+  }?
+common-text-anchor-attlist &=
+  attribute text:anchor-page-number { positiveInteger }?
+draw-text = (text-p | text-list)*
+common-draw-shape-with-styles-attlist =
+  common-draw-z-index-attlist,
+  common-draw-id-attlist,
+  common-draw-layer-name-attlist,
+  common-draw-style-name-attlist,
+  common-draw-transform-attlist,
+  common-draw-name-attlist,
+  common-text-spreadsheet-shape-attlist
+common-draw-shape-with-text-and-styles-attlist =
+  common-draw-shape-with-styles-attlist,
+  common-draw-text-style-name-attlist
+draw-glue-point =
+  element draw:glue-point { draw-glue-point-attlist, empty }
+draw-glue-point-attlist &= attribute draw:id { nonNegativeInteger }
+draw-glue-point-attlist &=
+  attribute svg:x { distance | percent },
+  attribute svg:y { distance | percent }
+draw-glue-point-attlist &=
+  attribute draw:align {
+    "top-left"
+    | "top"
+    | "top-right"
+    | "left"
+    | "center"
+    | "right"
+    | "bottom-left"
+    | "bottom-right"
+  }?
+draw-glue-points-attlist &=
+  attribute draw:escape-direction {
+    "auto"
+    | "left"
+    | "right"
+    | "up"
+    | "down"
+    | "horizontal"
+    | "vertical"
+  }
+svg-title = element svg:title { text }
+svg-desc = element svg:desc { text }
+draw-frame =
+  element draw:frame {
+    common-draw-shape-with-text-and-styles-attlist,
+    common-draw-position-attlist,
+    common-draw-rel-size-attlist,
+    common-draw-caption-id-attlist,
+    presentation-shape-attlist,
+    draw-frame-attlist,
+    (draw-text-box
+     | draw-image
+     | draw-object
+     | draw-object-ole
+     | draw-applet
+     | draw-floating-frame
+     | draw-plugin)*,
+    office-event-listeners?,
+    draw-glue-point*,
+    draw-image-map?,
+    svg-title?,
+    svg-desc?,
+    (draw-contour-polygon | draw-contour-path)?
+  }
+common-draw-rel-size-attlist =
+  common-draw-size-attlist,
+  attribute style:rel-width { percent | "scale" | "scale-min" }?,
+  attribute style:rel-height { percent | "scale" | "scale-min" }?
+draw-frame-attlist &= attribute draw:copy-of { \string }?
+draw-text-box =
+  element draw:text-box { draw-text-box-attlist, text-content* }
+draw-text-box-attlist &= attribute draw:chain-next-name { \string }?
+draw-text-box-attlist &=
+  attribute draw:corner-radius { nonNegativeLength }?
+draw-text-box-attlist &=
+  attribute fo:min-height { length | percent }?,
+  attribute fo:min-width { length | percent }?
+draw-text-box-attlist &=
+  attribute fo:max-height { length | percent }?,
+  attribute fo:max-width { length | percent }?
+draw-text-box-attlist &= text-id?
+draw-image =
+  element draw:image {
+    draw-image-attlist,
+    (common-draw-data-attlist | office-binary-data),
+    draw-text
+  }
+common-draw-data-attlist &=
+  attribute xlink:href { anyURI },
+  [ a:defaultValue = "simple" ] attribute xlink:type { "simple" }?,
+  [ a:defaultValue = "embed" ] attribute xlink:show { "embed" }?,
+  [ a:defaultValue = "onLoad" ] attribute xlink:actuate { "onLoad" }?
+office-binary-data = element office:binary-data { base64Binary }
+draw-image-attlist &= attribute draw:filter-name { \string }?
+draw-object =
+  element draw:object {
+    draw-object-attlist,
+    (common-draw-data-attlist | office-document | math-math)
+  }
+draw-object-ole =
+  element draw:object-ole {
+    draw-object-ole-attlist,
+    (common-draw-data-attlist | office-binary-data)
+  }
+draw-object-attlist &=
+  attribute draw:notify-on-update-of-ranges { \string }?
+draw-object-ole-attlist &= attribute draw:class-id { text }?
+draw-applet =
+  element draw:applet {
+    draw-applet-attlist, common-draw-data-attlist?, draw-param*
+  }
+draw-applet-attlist &= attribute draw:code { text }?
+draw-applet-attlist &= attribute draw:object { text }?
+draw-applet-attlist &= attribute draw:archive { text }?
+draw-applet-attlist &=
+  [ a:defaultValue = "false" ] attribute draw:may-script { boolean }?
+draw-plugin =
+  element draw:plugin {
+    draw-plugin-attlist, common-draw-data-attlist, draw-param*
+  }
+draw-plugin-attlist &= attribute draw:mime-type { text }?
+draw-param = element draw:param { draw-param-attlist, empty }
+draw-param-attlist &= attribute draw:name { text }?
+draw-param-attlist &= attribute draw:value { text }?
+draw-floating-frame =
+  element draw:floating-frame {
+    draw-floating-frame-attlist, common-draw-data-attlist
+  }
+draw-floating-frame-attlist &= attribute draw:frame-name { \string }?
+draw-contour-polygon =
+  element draw:contour-polygon {
+    common-contour-attlist,
+    common-draw-size-attlist,
+    common-draw-viewbox-attlist,
+    common-draw-points-attlist,
+    empty
+  }
+draw-contour-path =
+  element draw:contour-path {
+    common-contour-attlist,
+    common-draw-size-attlist,
+    common-draw-viewbox-attlist,
+    common-draw-path-data-attlist,
+    empty
+  }
+common-contour-attlist &= attribute draw:recreate-on-edit { boolean }
+draw-a = element draw:a { draw-a-attlist, draw-frame }
+draw-a-attlist &=
+  attribute xlink:href { anyURI },
+  [ a:defaultValue = "simple" ] attribute xlink:type { "simple" }?,
+  [ a:defaultValue = "onRequest" ]
+  attribute xlink:actuate { "onRequest" }?
+draw-a-attlist &=
+  attribute office:target-frame-name { targetFrameName }?,
+  attribute xlink:show { "new" | "replace" }?
+draw-a-attlist &= attribute office:name { \string }?
+draw-a-attlist &= attribute office:title { \string }?
+draw-a-attlist &=
+  [ a:defaultValue = "false" ] attribute office:server-map { boolean }?
+draw-image-map =
+  element draw:image-map {
+    (draw-area-rectangle | draw-area-circle | draw-area-polygon)*
+  }
+draw-area-rectangle =
+  element draw:area-rectangle {
+    common-draw-area-attlist,
+    attribute svg:x { coordinate },
+    attribute svg:y { coordinate },
+    attribute svg:width { length },
+    attribute svg:height { length },
+    svg-title?,
+    svg-desc?,
+    office-event-listeners?
+  }
+draw-area-circle =
+  element draw:area-circle {
+    common-draw-area-attlist,
+    attribute svg:cx { coordinate },
+    attribute svg:cy { coordinate },
+    attribute svg:r { length },
+    svg-title?,
+    svg-desc?,
+    office-event-listeners?
+  }
+draw-area-polygon =
+  element draw:area-polygon {
+    common-draw-area-attlist,
+    attribute svg:x { coordinate },
+    attribute svg:y { coordinate },
+    attribute svg:width { length },
+    attribute svg:height { length },
+    common-draw-viewbox-attlist,
+    common-draw-points-attlist,
+    svg-title?,
+    svg-desc?,
+    office-event-listeners?
+  }
+common-draw-area-attlist &=
+  attribute xlink:href { anyURI }?,
+  [ a:defaultValue = "simple" ] attribute xlink:type { "simple" }?,
+  attribute office:target-frame-name { targetFrameName }?,
+  attribute xlink:show { "new" | "replace" }?
+common-draw-area-attlist &= attribute office:name { \string }?
+common-draw-area-attlist &= attribute draw:nohref { "nohref" }?
+dr3d-scene =
+  element dr3d:scene {
+    dr3d-scene-attlist,
+    common-draw-position-attlist,
+    common-draw-size-attlist,
+    common-draw-style-name-attlist,
+    common-draw-z-index-attlist,
+    common-draw-id-attlist,
+    common-draw-layer-name-attlist,
+    common-text-spreadsheet-shape-attlist,
+    common-dr3d-transform-attlist,
+    common-draw-caption-id-attlist,
+    svg-title?,
+    svg-desc?,
+    dr3d-light*,
+    shapes3d*
+  }
+shapes3d =
+  dr3d-scene | dr3d-extrude | dr3d-sphere | dr3d-rotate | dr3d-cube
+dr3d-scene-attlist &=
+  attribute dr3d:vrp { vector3D }?,
+  attribute dr3d:vpn { vector3D }?,
+  attribute dr3d:vup { vector3D }?
+dr3d-scene-attlist &=
+  attribute dr3d:projection { "parallel" | "perspective" }?
+dr3d-scene-attlist &= attribute dr3d:distance { length }?
+dr3d-scene-attlist &= attribute dr3d:focal-length { length }?
+dr3d-scene-attlist &=
+  attribute dr3d:shadow-slant { nonNegativeInteger }?
+dr3d-scene-attlist &=
+  attribute dr3d:shade-mode { "flat" | "phong" | "gouraud" | "draft" }?
+dr3d-scene-attlist &= attribute dr3d:ambient-color { color }?
+dr3d-scene-attlist &= attribute dr3d:lighting-mode { boolean }?
+common-dr3d-transform-attlist = attribute dr3d:transform { text }?
+dr3d-light = element dr3d:light { dr3d-light-attlist, empty }
+dr3d-light-attlist &= attribute dr3d:diffuse-color { color }?
+dr3d-light-attlist &= attribute dr3d:direction { vector3D }
+dr3d-light-attlist &= attribute dr3d:enabled { boolean }?
+dr3d-light-attlist &= attribute dr3d:specular { boolean }?
+dr3d-cube =
+  element dr3d:cube {
+    dr3d-cube-attlist,
+    common-draw-z-index-attlist,
+    common-draw-id-attlist,
+    common-draw-layer-name-attlist,
+    common-draw-style-name-attlist,
+    common-dr3d-transform-attlist,
+    empty
+  }
+dr3d-cube-attlist &=
+  attribute dr3d:min-edge { vector3D }?,
+  attribute dr3d:max-edge { vector3D }?
+dr3d-sphere =
+  element dr3d:sphere {
+    dr3d-sphere-attlist,
+    common-draw-z-index-attlist,
+    common-draw-id-attlist,
+    common-draw-layer-name-attlist,
+    common-draw-style-name-attlist,
+    common-dr3d-transform-attlist,
+    empty
+  }
+dr3d-sphere-attlist &= attribute dr3d:center { vector3D }?
+dr3d-sphere-attlist &= attribute dr3d:size { vector3D }?
+dr3d-extrude =
+  element dr3d:extrude {
+    common-draw-path-data-attlist,
+    common-draw-viewbox-attlist,
+    common-draw-id-attlist,
+    common-draw-z-index-attlist,
+    common-draw-layer-name-attlist,
+    common-draw-style-name-attlist,
+    common-dr3d-transform-attlist,
+    empty
+  }
+dr3d-rotate =
+  element dr3d:rotate {
+    common-draw-viewbox-attlist,
+    common-draw-path-data-attlist,
+    common-draw-z-index-attlist,
+    common-draw-id-attlist,
+    common-draw-layer-name-attlist,
+    common-draw-style-name-attlist,
+    common-dr3d-transform-attlist,
+    empty
+  }
+draw-custom-shape =
+  element draw:custom-shape {
+    draw-custom-shape-attlist,
+    common-draw-position-attlist,
+    common-draw-size-attlist,
+    common-draw-shape-with-text-and-styles-attlist,
+    common-draw-caption-id-attlist,
+    svg-title?,
+    svg-desc?,
+    office-event-listeners?,
+    draw-glue-point*,
+    draw-text,
+    draw-enhanced-geometry?
+  }
+draw-custom-shape-attlist &= attribute draw:engine { namespacedToken }?
+draw-custom-shape-attlist &= attribute draw:data { \string }?
+draw-enhanced-geometry =
+  element draw:enhanced-geometry {
+    draw-enhanced-geometry-attlist, draw-equation*, draw-handle*
+  }
+draw-enhanced-geometry-attlist &=
+  [ a:defaultValue = "non-primitive" ]
+  attribute draw:type { custom-shape-type }?
+custom-shape-type = "non-primitive" | \string
+draw-enhanced-geometry-attlist &=
+  attribute svg:viewBox {
+    list { integer, integer, integer, integer }
+  }?
+draw-enhanced-geometry-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute draw:mirror-vertical { boolean }?,
+  [ a:defaultValue = "false" ]
+  attribute draw:mirror-horizontal { boolean }?
+draw-enhanced-geometry-attlist &=
+  [ a:defaultValue = "0" ] attribute draw:text-rotate-angle { double }?
+draw-enhanced-geometry-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute draw:extrusion-allowed { boolean }?
+draw-enhanced-geometry-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute draw:text-path-allowed { boolean }?
+draw-enhanced-geometry-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute draw:concentric-gradient-fill-allowed { boolean }?
+draw-enhanced-geometry-attlist &=
+  [ a:defaultValue = "false" ] attribute draw:extrusion { boolean }?
+draw-enhanced-geometry-attlist &=
+  [ a:defaultValue = "33%" ]
+  attribute draw:extrusion-brightness { percent }?
+draw-enhanced-geometry-attlist &=
+  [ a:defaultValue = "36pt 0" ]
+  attribute draw:extrusion-depth {
+    list { length, double }
+  }?
+draw-enhanced-geometry-attlist &=
+  [ a:defaultValue = "0%" ]
+  attribute draw:extrusion-diffusion { percent }?
+draw-enhanced-geometry-attlist &=
+  [ a:defaultValue = "30" ]
+  attribute draw:extrusion-number-of-line-segments { integer }?
+draw-enhanced-geometry-attlist &=
+  [ a:defaultValue = "true" ]
+  attribute draw:extrusion-light-face { boolean }?
+draw-enhanced-geometry-attlist &=
+  [ a:defaultValue = "true" ]
+  attribute draw:extrusion-first-light-harsh { boolean }?
+draw-enhanced-geometry-attlist &=
+  [ a:defaultValue = "true" ]
+  attribute draw:extrusion-second-light-harsh { boolean }?
+draw-enhanced-geometry-attlist &=
+  [ a:defaultValue = "66%" ]
+  attribute draw:extrusion-first-light-level { percent }?
+draw-enhanced-geometry-attlist &=
+  [ a:defaultValue = "66%" ]
+  attribute draw:extrusion-second-light-level { percent }?
+draw-enhanced-geometry-attlist &=
+  [ a:defaultValue = "(5 0 1)" ]
+  attribute draw:extrusion-first-light-direction { vector3D }?
+draw-enhanced-geometry-attlist &=
+  [ a:defaultValue = "(-5 0 1)" ]
+  attribute draw:extrusion-second-light-direction { vector3D }?
+draw-enhanced-geometry-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute draw:extrusion-metal { boolean }?
+draw-enhanced-geometry-attlist &=
+  [ a:defaultValue = "flat" ]
+  attribute dr3d:shade-mode { "flat" | "phong" | "gouraud" | "draft" }?
+draw-enhanced-geometry-attlist &=
+  [ a:defaultValue = "0 0" ]
+  attribute draw:extrusion-rotation-angle {
+    list { double, double }
+  }?
+draw-enhanced-geometry-attlist &=
+  attribute draw:extrusion-rotation-center { vector3D }?
+draw-enhanced-geometry-attlist &=
+  [ a:defaultValue = "50%" ]
+  attribute draw:extrusion-shininess { percent }?
+draw-enhanced-geometry-attlist &=
+  [ a:defaultValue = "50 45" ]
+  attribute draw:extrusion-skew {
+    list { double, double }
+  }?
+draw-enhanced-geometry-attlist &=
+  [ a:defaultValue = "0%" ]
+  attribute draw:extrusion-specularity { percent }?
+draw-enhanced-geometry-attlist &=
+  [ a:defaultValue = "parallel" ]
+  attribute dr3d:projection { "parallel" | "perspective" }?
+draw-enhanced-geometry-attlist &=
+  [ a:defaultValue = "3.5cm -3.5cm 25cm" ]
+  attribute draw:extrusion-viewpoint { point3D }?
+point3D = xsd:string
+draw-enhanced-geometry-attlist &=
+  [ a:defaultValue = "0.5 -0.5" ]
+  attribute draw:extrusion-origin {
+    list { double, double }
+  }?
+draw-enhanced-geometry-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute draw:extrusion-color { boolean }?
+draw-enhanced-geometry-attlist &=
+  attribute draw:enhanced-path { \string }?
+draw-enhanced-geometry-attlist &=
+  [ a:defaultValue = "0" ]
+  attribute draw:path-stretchpoint-x { double }?,
+  [ a:defaultValue = "0" ]
+  attribute draw:path-stretchpoint-y { double }?
+draw-enhanced-geometry-attlist &= attribute draw:text-areas { \string }?
+draw-enhanced-geometry-attlist &=
+  attribute draw:glue-points { \string }?
+draw-enhanced-geometry-attlist &=
+  [ a:defaultValue = "none" ]
+  attribute draw:glue-point-type { "none" | "segments" | "rectangle" }?
+draw-enhanced-geometry-attlist &=
+  attribute draw:glue-point-leaving-directions { text }?
+draw-enhanced-geometry-attlist &=
+  [ a:defaultValue = "false" ] attribute draw:text-path { boolean }?
+draw-enhanced-geometry-attlist &=
+  [ a:defaultValue = "normal" ]
+  attribute draw:text-path-mode { "normal" | "path" | "shape" }?
+draw-enhanced-geometry-attlist &=
+  [ a:defaultValue = "path" ]
+  attribute draw:text-path-scale { "path" | "shape" }?
+draw-enhanced-geometry-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute draw:text-path-same-letter-heights { boolean }?
+draw-enhanced-geometry-attlist &= attribute draw:modifiers { \string }?
+draw-equation = element draw:equation { draw-equation-attlist, empty }
+draw-equation-attlist &= attribute draw:name { \string }?
+draw-equation-attlist &= attribute draw:formula { \string }?
+draw-handle = element draw:handle { draw-handle-attlist, empty }
+draw-handle-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute draw:handle-mirror-vertical { boolean }?
+draw-handle-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute draw:handle-mirror-horizontal { boolean }?
+draw-handle-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute draw:handle-switched { boolean }?
+draw-handle-attlist &= attribute draw:handle-position { \string }
+draw-handle-attlist &=
+  attribute draw:handle-range-x-minimum { \string }?
+draw-handle-attlist &=
+  attribute draw:handle-range-x-maximum { \string }?
+draw-handle-attlist &=
+  attribute draw:handle-range-y-minimum { \string }?
+draw-handle-attlist &=
+  attribute draw:handle-range-y-maximum { \string }?
+draw-handle-attlist &= attribute draw:handle-polar { \string }?
+draw-handle-attlist &=
+  attribute draw:handle-radius-range-minimum { \string }?
+draw-handle-attlist &=
+  attribute draw:handle-radius-range-maximum { \string }?
+presentation-shape-attlist &=
+  attribute presentation:class { presentation-classes }?
+presentation-classes =
+  "title"
+  | "outline"
+  | "subtitle"
+  | "text"
+  | "graphic"
+  | "object"
+  | "chart"
+  | "table"
+  | "orgchart"
+  | "page"
+  | "notes"
+  | "handout"
+  | "header"
+  | "footer"
+  | "date-time"
+  | "page-number"
+presentation-shape-attlist &=
+  attribute presentation:placeholder { boolean }?
+presentation-shape-attlist &=
+  attribute presentation:user-transformed { boolean }?
+presentation-animations =
+  element presentation:animations {
+    (presentation-animation-elements | presentation-animation-group)*
+  }
+presentation-animation-elements =
+  presentation-show-shape
+  | presentation-show-text
+  | presentation-hide-shape
+  | presentation-hide-text
+  | presentation-dim
+  | presentation-play
+presentation-sound =
+  element presentation:sound {
+    presentation-sound-attlist,
+    attribute xlink:href { anyURI },
+    [ a:defaultValue = "simple" ] attribute xlink:type { "simple" }?,
+    [ a:defaultValue = "onRequest" ]
+    attribute xlink:actuate { "onRequest" }?,
+    attribute xlink:show { "new" | "replace" }?,
+    empty
+  }
+presentation-sound-attlist &=
+  attribute presentation:play-full { boolean }?
+presentation-show-shape =
+  element presentation:show-shape {
+    common-presentation-effect-attlist, presentation-sound?
+  }
+common-presentation-effect-attlist &= attribute draw:shape-id { IDREF }
+common-presentation-effect-attlist &=
+  [ a:defaultValue = "none" ]
+  attribute presentation:effect { presentationEffects }?
+presentationEffects =
+  "none"
+  | "fade"
+  | "move"
+  | "stripes"
+  | "open"
+  | "close"
+  | "dissolve"
+  | "wavyline"
+  | "random"
+  | "lines"
+  | "laser"
+  | "appear"
+  | "hide"
+  | "move-short"
+  | "checkerboard"
+  | "rotate"
+  | "stretch"
+common-presentation-effect-attlist &=
+  [ a:defaultValue = "none" ]
+  attribute presentation:direction { presentationEffectDirections }?
+presentationEffectDirections =
+  "none"
+  | "from-left"
+  | "from-top"
+  | "from-right"
+  | "from-bottom"
+  | "from-center"
+  | "from-upper-left"
+  | "from-upper-right"
+  | "from-lower-left"
+  | "from-lower-right"
+  | "to-left"
+  | "to-top"
+  | "to-right"
+  | "to-bottom"
+  | "to-upper-left"
+  | "to-upper-right"
+  | "to-lower-right"
+  | "to-lower-left"
+  | "path"
+  | "spiral-inward-left"
+  | "spiral-inward-right"
+  | "spiral-outward-left"
+  | "spiral-outward-right"
+  | "vertical"
+  | "horizontal"
+  | "to-center"
+  | "clockwise"
+  | "counter-clockwise"
+common-presentation-effect-attlist &=
+  [ a:defaultValue = "medium" ]
+  attribute presentation:speed { presentationSpeeds }?
+presentationSpeeds = "slow" | "medium" | "fast"
+common-presentation-effect-attlist &=
+  attribute presentation:delay { duration }?
+common-presentation-effect-attlist &=
+  [ a:defaultValue = "100%" ]
+  attribute presentation:start-scale { percent }?
+common-presentation-effect-attlist &=
+  attribute presentation:path-id { text }?
+presentation-show-text =
+  element presentation:show-text {
+    common-presentation-effect-attlist, presentation-sound?
+  }
+presentation-hide-shape =
+  element presentation:hide-shape {
+    common-presentation-effect-attlist, presentation-sound?
+  }
+presentation-hide-text =
+  element presentation:hide-text {
+    common-presentation-effect-attlist, presentation-sound?
+  }
+presentation-dim =
+  element presentation:dim {
+    presentation-dim-attlist, presentation-sound?
+  }
+presentation-dim-attlist &= attribute draw:shape-id { IDREF }
+presentation-dim-attlist &= attribute draw:color { color }
+presentation-play =
+  element presentation:play { presentation-play-attlist, empty }
+presentation-play-attlist &=
+  attribute draw:shape-id { IDREF },
+  [ a:defaultValue = "medium" ]
+  attribute presentation:speed { presentationSpeeds }?
+presentation-animation-group =
+  element presentation:animation-group {
+    presentation-animation-elements*
+  }
+common-anim-attlist &=
+  [ a:defaultValue = "default" ]
+  attribute presentation:node-type {
+    "default"
+    | "on-click"
+    | "with-previous"
+    | "after-previous"
+    | "timing-root"
+    | "main-sequence"
+    | "interactive-sequence"
+  }?
+common-anim-attlist &= attribute presentation:preset-id { \string }?
+common-anim-attlist &=
+  attribute presentation:preset-sub-type { \string }?
+common-anim-attlist &=
+  [ a:defaultValue = "custom" ]
+  attribute presentation:preset-class {
+    "custom"
+    | "entrance"
+    | "exit"
+    | "emphasis"
+    | "motion-path"
+    | "ole-action"
+    | "media-call"
+  }?
+common-anim-attlist &= attribute presentation:master-element { IDREF }?
+common-anim-attlist &= attribute presentation:group-id { \string }?
+presentation-event-listener =
+  element presentation:event-listener {
+    presentation-event-listener-attlist, presentation-sound?
+  }
+presentation-event-listener-attlist &=
+  attribute script:event-name { \string }
+presentation-event-listener-attlist &=
+  attribute presentation:action {
+    "none"
+    | "previous-page"
+    | "next-page"
+    | "first-page"
+    | "last-page"
+    | "hide"
+    | "stop"
+    | "execute"
+    | "show"
+    | "verb"
+    | "fade-out"
+    | "sound"
+  }
+presentation-event-listener-attlist &=
+  [ a:defaultValue = "none" ]
+  attribute presentation:effect { presentationEffects }?
+presentation-event-listener-attlist &=
+  [ a:defaultValue = "none" ]
+  attribute presentation:direction { presentationEffectDirections }?
+presentation-event-listener-attlist &=
+  [ a:defaultValue = "medium" ]
+  attribute presentation:speed { presentationSpeeds }?
+presentation-event-listener-attlist &=
+  [ a:defaultValue = "100%" ]
+  attribute presentation:start-scale { percent }?
+presentation-event-listener-attlist &=
+  attribute xlink:href { anyURI }?,
+  [ a:defaultValue = "simple" ] attribute xlink:type { "simple" }?,
+  [ a:defaultValue = "embed" ] attribute xlink:show { "embed" }?,
+  [ a:defaultValue = "onRequest" ]
+  attribute xlink:actuate { "onRequest" }?
+presentation-event-listener-attlist &=
+  attribute presentation:verb { nonNegativeInteger }?
+paragraph-content |= element presentation:header { empty }
+paragraph-content |= element presentation:footer { empty }
+paragraph-content |= element presentation:date-time { empty }
+presentation-decls = presentation-decl*
+presentation-decl |=
+  element presentation:header-decl {
+    presentation-header-decl-attlist, text
+  }
+presentation-header-decl-attlist &=
+  attribute presentation:name { \string }
+presentation-decl |=
+  element presentation:footer-decl {
+    presentation-footer-decl-attlist, text
+  }
+presentation-footer-decl-attlist &=
+  attribute presentation:name { \string }
+presentation-decl |=
+  element presentation:date-time-decl {
+    presentation-date-time-decl-attlist, text
+  }
+presentation-date-time-decl-attlist &=
+  attribute presentation:name { \string }
+presentation-date-time-decl-attlist &=
+  attribute presentation:source { "fixed" | "current-date" }
+presentation-date-time-decl-attlist &=
+  attribute style:data-style-name { styleNameRef }?
+presentation-settings =
+  element presentation:settings {
+    presentation-settings-attlist, presentation-show*
+  }?
+presentation-settings-attlist &=
+  attribute presentation:start-page { \string }?
+presentation-settings-attlist &=
+  attribute presentation:show { \string }?
+presentation-settings-attlist &=
+  [ a:defaultValue = "true" ]
+  attribute presentation:full-screen { boolean }?
+presentation-settings-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute presentation:endless { boolean }?
+presentation-settings-attlist &=
+  attribute presentation:pause { duration }?
+presentation-settings-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute presentation:show-logo { boolean }?
+presentation-settings-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute presentation:force-manual { boolean }?
+presentation-settings-attlist &=
+  [ a:defaultValue = "true" ]
+  attribute presentation:mouse-visible { boolean }?
+presentation-settings-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute presentation:mouse-as-pen { boolean }?
+presentation-settings-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute presentation:start-with-navigator { boolean }?
+presentation-settings-attlist &=
+  [ a:defaultValue = "enabled" ]
+  attribute presentation:animations { "enabled" | "disabled" }?
+presentation-settings-attlist &=
+  [ a:defaultValue = "enabled" ]
+  attribute presentation:transition-on-click { "enabled" | "disabled" }?
+presentation-settings-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute presentation:stay-on-top { boolean }?
+presentation-settings-attlist &=
+  [ a:defaultValue = "true" ]
+  attribute presentation:show-end-of-presentation-slide { boolean }?
+presentation-show =
+  element presentation:show { presentation-show-attlist, empty }
+presentation-show-attlist &= attribute presentation:name { \string }
+presentation-show-attlist &= attribute presentation:pages { text }
+chart-chart =
+  element chart:chart {
+    chart-chart-attlist,
+    chart-title?,
+    chart-subtitle?,
+    chart-footer?,
+    chart-legend?,
+    chart-plot-area,
+    table-table?
+  }
+chart-chart-attlist &= attribute chart:class { namespacedToken }
+chart-chart-attlist &= common-draw-size-attlist
+chart-chart-attlist &= attribute chart:column-mapping { \string }?
+chart-chart-attlist &= attribute chart:row-mapping { \string }?
+chart-chart-attlist &= attribute chart:style-name { styleNameRef }?
+chart-title = element chart:title { chart-title-attlist, text-p? }
+chart-title-attlist &= attribute table:cell-range { cellAddress }?
+chart-title-attlist &= common-draw-position-attlist
+chart-title-attlist &= attribute chart:style-name { styleNameRef }?
+chart-subtitle = element chart:subtitle { chart-title-attlist, text-p? }
+chart-footer = element chart:footer { chart-title-attlist, text-p? }
+chart-legend = element chart:legend { chart-legend-attlist, empty }
+chart-legend-attlist &=
+  (attribute chart:legend-position {
+     "start" | "end" | "top" | "bottom"
+   },
+   attribute chart:legend-align { "start" | "center" | "end" }?)
+  | attribute chart:legend-position {
+      "top-start" | "bottom-start" | "top-end" | "bottom-end"
+    }
+  | empty
+chart-legend-attlist &= common-draw-position-attlist
+chart-legend-attlist &=
+  attribute style:legend-expansion { "wide" | "high" | "balanced" }
+  | (attribute style:legend-expansion { "custom" },
+     attribute style:legend-expansion-aspect-ratio { double })
+  | empty
+chart-legend-attlist &= attribute chart:style-name { styleNameRef }?
+chart-plot-area =
+  element chart:plot-area {
+    chart-plot-area-attlist,
+    dr3d-light*,
+    chart-axis*,
+    chart-series*,
+    chart-stock-gain-marker?,
+    chart-stock-loss-marker?,
+    chart-stock-range-line?,
+    chart-wall?,
+    chart-floor?
+  }
+chart-plot-area-attlist &=
+  common-draw-position-attlist, common-draw-size-attlist
+chart-plot-area-attlist &= attribute chart:style-name { styleNameRef }?
+chart-plot-area-attlist &=
+  attribute table:cell-range-address { cellRangeAddress }?
+chart-plot-area-attlist &=
+  [ a:defaultValue = "none" ]
+  attribute chart:data-source-has-labels {
+    "none" | "row" | "column" | "both"
+  }?
+chart-plot-area-attlist &=
+  dr3d-scene-attlist, common-dr3d-transform-attlist
+chart-wall = element chart:wall { chart-wall-attlist, empty }
+chart-wall-attlist &= attribute svg:width { length }?
+chart-wall-attlist &= attribute chart:style-name { styleNameRef }?
+chart-floor = element chart:floor { chart-floor-attlist, empty }
+chart-floor-attlist &= attribute svg:width { length }?
+chart-floor-attlist &= attribute chart:style-name { styleNameRef }?
+chart-axis =
+  element chart:axis {
+    chart-axis-attlist, chart-title?, chart-categories?, chart-grid*
+  }
+chart-axis-attlist &= attribute chart:dimension { "x" | "y" | "z" }
+chart-axis-attlist &= attribute chart:name { \string }?
+chart-axis-attlist &= attribute chart:style-name { styleNameRef }?
+chart-grid = element chart:grid { chart-grid-attlist }
+chart-grid-attlist &=
+  [ a:defaultValue = "major" ]
+  attribute chart:class { "major" | "minor" }?
+chart-grid-attlist &= attribute chart:style-name { styleNameRef }?
+chart-series =
+  element chart:series {
+    chart-series-attlist,
+    chart-domain*,
+    chart-mean-value?,
+    chart-regression-curve?,
+    chart-error-indicator?,
+    chart-data-point*
+  }
+chart-series-attlist &=
+  attribute chart:values-cell-range-address { cellRangeAddress }?
+chart-series-attlist &=
+  attribute chart:label-cell-address { cellAddress }?
+chart-series-attlist &= attribute chart:class { namespacedToken }?
+chart-series-attlist &= attribute chart:attached-axis { \string }?
+chart-series-attlist &= attribute chart:style-name { styleNameRef }?
+chart-domain =
+  element chart:domain {
+    attribute table:cell-range-address { cellRangeAddress }?
+  }
+chart-categories =
+  element chart:categories {
+    attribute table:cell-range-address { cellRangeAddress }?
+  }
+chart-data-point =
+  element chart:data-point { chart-data-point-attlist, empty }
+chart-data-point-attlist &=
+  attribute chart:repeated { nonNegativeInteger }?
+chart-data-point-attlist &= attribute chart:style-name { styleNameRef }?
+chart-mean-value =
+  element chart:mean-value { chart-mean-value-attlist, empty }
+chart-mean-value-attlist &= attribute chart:style-name { styleNameRef }?
+chart-error-indicator =
+  element chart:error-indicator { chart-error-indicator-attlist, empty }
+chart-error-indicator-attlist &=
+  attribute chart:style-name { styleNameRef }?
+chart-regression-curve =
+  element chart:regression-curve {
+    chart-regression-curve-attlist, empty
+  }
+chart-regression-curve-attlist &=
+  attribute chart:style-name { styleNameRef }?
+chart-stock-gain-marker =
+  element chart:stock-gain-marker { common-stock-marker-attlist }
+chart-stock-loss-marker =
+  element chart:stock-loss-marker { common-stock-marker-attlist }
+chart-stock-range-line =
+  element chart:stock-range-line { common-stock-marker-attlist }
+common-stock-marker-attlist =
+  attribute chart:style-name { styleNameRef }?
+office-forms =
+  element office:forms {
+    office-forms-attlist, (form-form | xforms-model)*
+  }?
+office-forms-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute form:automatic-focus { boolean }?
+office-forms-attlist &=
+  [ a:defaultValue = "true" ]
+  attribute form:apply-design-mode { boolean }?
+form-form =
+  element form:form {
+    common-form-control-attlist,
+    form-form-attlist,
+    form-properties?,
+    office-event-listeners?,
+    (controls | form-form)*,
+    form-connection-resource?
+  }
+form-form-attlist &=
+  (attribute xlink:href { anyURI },
+   [ a:defaultValue = "simple" ] attribute xlink:type { "simple" }?,
+   [ a:defaultValue = "onRequest" ]
+   attribute xlink:actuate { "onRequest" }?)?
+form-form-attlist &=
+  [ a:defaultValue = "_blank" ]
+  attribute office:target-frame { targetFrameName }?
+form-form-attlist &=
+  [ a:defaultValue = "get" ]
+  attribute form:method { "get" | "post" | \string }?
+form-form-attlist &=
+  [ a:defaultValue = "application/x-www-form-urlencoded" ]
+  attribute form:enctype { \string }?
+form-form-attlist &=
+  [ a:defaultValue = "true" ] attribute form:allow-deletes { boolean }?
+form-form-attlist &=
+  [ a:defaultValue = "true" ] attribute form:allow-inserts { boolean }?
+form-form-attlist &=
+  [ a:defaultValue = "true" ] attribute form:allow-updates { boolean }?
+form-form-attlist &=
+  [ a:defaultValue = "false" ] attribute form:apply-filter { boolean }?
+form-form-attlist &=
+  [ a:defaultValue = "command" ]
+  attribute form:command-type { "table" | "query" | "command" }?
+form-form-attlist &= attribute form:command { text }?
+form-form-attlist &= attribute form:datasource { anyURI | \string }?
+form-form-attlist &= attribute form:master-fields { \string }?
+form-form-attlist &= attribute form:detail-fields { \string }?
+form-form-attlist &=
+  [ a:defaultValue = "true" ]
+  attribute form:escape-processing { boolean }?
+form-form-attlist &= attribute form:filter { \string }?
+form-form-attlist &=
+  [ a:defaultValue = "false" ] attribute form:ignore-result { boolean }?
+form-form-attlist &= attribute form:navigation-mode { navigation }?
+navigation = "none" | "current" | "parent"
+form-form-attlist &= attribute form:order { \string }?
+form-form-attlist &= attribute form:tab-cycle { tab-cycles }?
+tab-cycles = "records" | "current" | "page"
+form-connection-resource =
+  element form:connection-resource {
+    attribute xlink:href { anyURI },
+    empty
+  }
+xforms-model = element xforms:model { anyAttListOrElements }
+column-controls |=
+  element form:text { form-text-attlist, common-form-control-content }
+controls |= column-controls
+form-text-attlist =
+  form-control-attlist,
+  common-current-value-attlist,
+  common-disabled-attlist,
+  common-maxlength-attlist,
+  common-printable-attlist,
+  common-readonly-attlist,
+  common-tab-attlist,
+  common-title-attlist,
+  common-value-attlist,
+  common-convert-empty-attlist,
+  common-data-field-attlist
+form-control-attlist =
+  common-form-control-attlist,
+  common-control-id-attlist,
+  xforms-bind-attlist
+common-form-control-content = form-properties?, office-event-listeners?
+column-controls |=
+  element form:textarea {
+    form-textarea-attlist, common-form-control-content, text-p*
+  }
+form-textarea-attlist =
+  form-control-attlist,
+  common-current-value-attlist,
+  common-disabled-attlist,
+  common-maxlength-attlist,
+  common-printable-attlist,
+  common-readonly-attlist,
+  common-tab-attlist,
+  common-title-attlist,
+  common-value-attlist,
+  common-convert-empty-attlist,
+  common-data-field-attlist
+controls |=
+  element form:password {
+    form-password-attlist, common-form-control-content
+  }
+form-password-attlist &=
+  form-control-attlist,
+  common-disabled-attlist,
+  common-maxlength-attlist,
+  common-printable-attlist,
+  common-tab-attlist,
+  common-title-attlist,
+  common-value-attlist,
+  common-convert-empty-attlist
+form-password-attlist &=
+  [ a:defaultValue = "*" ] attribute form:echo-char { character }?
+controls |=
+  element form:file { form-file-attlist, common-form-control-content }
+form-file-attlist &=
+  form-control-attlist,
+  common-current-value-attlist,
+  common-disabled-attlist,
+  common-maxlength-attlist,
+  common-printable-attlist,
+  common-readonly-attlist,
+  common-tab-attlist,
+  common-title-attlist,
+  common-value-attlist
+column-controls |=
+  element form:formatted-text {
+    form-formatted-text-attlist, common-form-control-content
+  }
+form-formatted-text-attlist &=
+  form-control-attlist,
+  common-current-value-attlist,
+  common-disabled-attlist,
+  common-maxlength-attlist,
+  common-printable-attlist,
+  common-readonly-attlist,
+  common-tab-attlist,
+  common-title-attlist,
+  common-value-attlist,
+  common-convert-empty-attlist,
+  common-data-field-attlist
+form-formatted-text-attlist &= attribute form:max-value { \string }?
+form-formatted-text-attlist &= attribute form:min-value { \string }?
+form-formatted-text-attlist &=
+  [ a:defaultValue = "false" ] attribute form:validation { boolean }?
+column-controls |=
+  element form:number {
+    form-number-attlist,
+    common-numeric-control-attlist,
+    common-form-control-content
+  }
+common-numeric-control-attlist =
+  form-control-attlist,
+  common-disabled-attlist,
+  common-maxlength-attlist,
+  common-printable-attlist,
+  common-readonly-attlist,
+  common-tab-attlist,
+  common-title-attlist,
+  common-convert-empty-attlist,
+  common-data-field-attlist
+form-number-attlist &= attribute form:value { double }?
+form-number-attlist &= attribute form:current-value { double }?
+form-number-attlist &= attribute form:min-value { double }?
+form-number-attlist &= attribute form:max-value { double }?
+column-controls |=
+  element form:date {
+    form-date-attlist,
+    common-numeric-control-attlist,
+    common-form-control-content
+  }
+controls |=
+  element form:time {
+    form-time-attlist,
+    common-numeric-control-attlist,
+    common-form-control-content
+  }
+form-date-attlist &= attribute form:value { date }?
+form-time-attlist &= attribute form:value { time }?
+form-date-attlist &= attribute form:current-value { date }?
+form-time-attlist &= attribute form:current-value { time }?
+form-date-attlist &= attribute form:min-value { date }?
+form-time-attlist &= attribute form:min-value { time }?
+form-date-attlist &= attribute form:max-value { date }?
+form-time-attlist &= attribute form:max-value { time }?
+controls |=
+  element form:fixed-text {
+    form-fixed-text-attlist, common-form-control-content
+  }
+form-fixed-text-attlist &=
+  form-control-attlist,
+  for,
+  common-disabled-attlist,
+  label,
+  common-printable-attlist,
+  common-title-attlist
+form-fixed-text-attlist &=
+  [ a:defaultValue = "false" ] attribute form:multi-line { boolean }?
+column-controls |=
+  element form:combobox {
+    form-combobox-attlist, common-form-control-content, form-item*
+  }
+form-combobox-attlist &=
+  form-control-attlist,
+  common-current-value-attlist,
+  common-disabled-attlist,
+  dropdown,
+  common-maxlength-attlist,
+  common-printable-attlist,
+  common-readonly-attlist,
+  size,
+  common-tab-attlist,
+  common-title-attlist,
+  common-value-attlist,
+  common-convert-empty-attlist,
+  common-data-field-attlist,
+  list-source,
+  list-source-type
+form-combobox-attlist &= attribute form:auto-complete { boolean }?
+form-item = element form:item { form-item-attlist, text }
+form-item-attlist &= label
+column-controls |=
+  element form:listbox {
+    form-listbox-attlist, common-form-control-content, form-option*
+  }
+form-listbox-attlist &=
+  form-control-attlist,
+  common-disabled-attlist,
+  dropdown,
+  common-printable-attlist,
+  size,
+  common-tab-attlist,
+  common-title-attlist,
+  bound-column,
+  common-data-field-attlist,
+  list-source,
+  list-source-type
+form-listbox-attlist &=
+  [ a:defaultValue = "false" ] attribute form:multiple { boolean }?
+form-listbox-attlist &= attribute form:xforms-list-source { \string }?
+form-option = element form:option { form-option-attlist, text }
+form-option-attlist &=
+  current-selected, selected, label, common-value-attlist
+controls |=
+  element form:button {
+    form-button-attlist, common-form-control-content
+  }
+form-button-attlist &=
+  form-control-attlist,
+  button-type,
+  common-disabled-attlist,
+  label,
+  image-data,
+  common-printable-attlist,
+  common-tab-attlist,
+  target-frame,
+  target-location,
+  common-title-attlist,
+  common-value-attlist,
+  common-form-relative-image-position-attlist
+form-button-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute form:default-button { boolean }?
+form-button-attlist &=
+  [ a:default-value = "false" ] attribute form:toggle { boolean }?
+form-button-attlist &= attribute form:focus-on-click { boolean }?
+form-button-attlist &= attribute form:xforms-submission { \string }?
+controls |=
+  element form:image { form-image-attlist, common-form-control-content }
+form-image-attlist &=
+  form-control-attlist,
+  button-type,
+  common-disabled-attlist,
+  image-data,
+  common-printable-attlist,
+  common-tab-attlist,
+  target-frame,
+  target-location,
+  common-title-attlist,
+  common-value-attlist
+column-controls |=
+  element form:checkbox {
+    form-checkbox-attlist, common-form-control-content
+  }
+form-checkbox-attlist &=
+  form-control-attlist,
+  common-disabled-attlist,
+  label,
+  common-printable-attlist,
+  common-tab-attlist,
+  common-title-attlist,
+  common-value-attlist,
+  common-data-field-attlist,
+  common-form-visual-effect-attlist,
+  common-form-relative-image-position-attlist
+states = "unchecked" | "checked" | "unknown"
+form-checkbox-attlist &= attribute form:current-state { states }?
+form-checkbox-attlist &=
+  [ a:defaultValue = "false" ] attribute form:is-tristate { boolean }?
+form-checkbox-attlist &=
+  [ a:defaultValue = "unchecked" ] attribute form:state { states }?
+controls |=
+  element form:radio { form-radio-attlist, common-form-control-content }
+form-radio-attlist &=
+  form-control-attlist,
+  current-selected,
+  common-disabled-attlist,
+  label,
+  common-printable-attlist,
+  selected,
+  common-tab-attlist,
+  common-title-attlist,
+  common-value-attlist,
+  common-data-field-attlist,
+  common-form-visual-effect-attlist,
+  common-form-relative-image-position-attlist
+controls |=
+  element form:frame { form-frame-attlist, common-form-control-content }
+form-frame-attlist &=
+  form-control-attlist,
+  common-disabled-attlist,
+  for,
+  label,
+  common-printable-attlist,
+  common-title-attlist
+controls |=
+  element form:image-frame {
+    form-image-frame-attlist, common-form-control-content
+  }
+form-image-frame-attlist &=
+  form-control-attlist,
+  common-disabled-attlist,
+  image-data,
+  common-printable-attlist,
+  common-readonly-attlist,
+  common-title-attlist,
+  common-data-field-attlist
+controls |=
+  element form:hidden {
+    form-hidden-attlist, common-form-control-content
+  }
+form-hidden-attlist &= form-control-attlist, common-value-attlist
+controls |=
+  element form:grid {
+    form-grid-attlist, common-form-control-content, form-column*
+  }
+form-grid-attlist &=
+  form-control-attlist,
+  common-disabled-attlist,
+  common-printable-attlist,
+  common-tab-attlist,
+  common-title-attlist
+form-column =
+  element form:column { form-column-attlist, column-controls+ }
+form-column-attlist &=
+  common-form-control-attlist, label, text-style-name
+text-style-name = attribute form:text-style-name { styleNameRef }?
+controls |=
+  element form:value-range {
+    form-value-range-attlist, common-form-control-content
+  }
+form-value-range-attlist &=
+  form-control-attlist,
+  common-disabled-attlist,
+  common-printable-attlist,
+  common-tab-attlist,
+  common-title-attlist,
+  common-value-attlist
+form-value-range-attlist &= attribute form:max-value { \string }?
+form-value-range-attlist &= attribute form:min-value { \string }?
+form-value-range-attlist &=
+  [ a:defaultName = "1" ] attribute form:step-size { positiveInteger }?
+form-value-range-attlist &=
+  attribute form:page-step-size { positiveInteger }?
+form-value-range-attlist &=
+  attribute form:delay-for-repeat { duration }?
+form-value-range-attlist &=
+  attribute form:orientation { "horizontal" | "vertical" }?
+controls |=
+  element form:generic-control {
+    form-generic-control-attlist, common-form-control-content
+  }
+form-generic-control-attlist &= form-control-attlist
+common-form-control-attlist &= attribute form:name { \string }?
+common-form-control-attlist &=
+  attribute form:control-implementation { namespacedToken }?
+xforms-bind-attlist = attribute xforms:bind { \string }?
+types = "submit" | "reset" | "push" | "url"
+button-type =
+  [ a:defaultValue = "push" ] attribute form:button-type { types }?
+common-control-id-attlist = attribute form:id { ID }
+current-selected =
+  [ a:defaultValue = "false" ]
+  attribute form:current-selected { boolean }?
+common-value-attlist = attribute form:value { \string }?
+common-current-value-attlist = attribute form:current-value { \string }?
+common-disabled-attlist =
+  [ a:defaultValue = "false" ] attribute form:disabled { boolean }?
+dropdown =
+  [ a:defaultValue = "false" ] attribute form:dropdown { boolean }?
+for = attribute form:for { \string }?
+image-data = attribute form:image-data { anyURI }?
+label = attribute form:label { \string }?
+common-maxlength-attlist =
+  attribute form:max-length { nonNegativeInteger }?
+common-printable-attlist =
+  [ a:defaultValue = "true" ] attribute form:printable { boolean }?
+common-readonly-attlist =
+  [ a:defaultValue = "false" ] attribute form:readonly { boolean }?
+selected =
+  [ a:defaultValue = "false" ] attribute form:selected { boolean }?
+size = attribute form:size { nonNegativeInteger }?
+common-tab-attlist &=
+  [ a:defaultValue = "0" ]
+  attribute form:tab-index { nonNegativeInteger }?
+common-tab-attlist &=
+  [ a:defaultValue = "true" ] attribute form:tab-stop { boolean }?
+target-frame =
+  [ a:defaultValue = "_blank" ]
+  attribute office:target-frame { targetFrameName }?
+target-location = attribute xlink:href { anyURI }?
+common-title-attlist = attribute form:title { text }?
+common-form-visual-effect-attlist &=
+  attribute form:visual-effect { "flat" | "3d" }?
+common-form-relative-image-position-attlist &=
+  [ a:defaultValue = "center" ]
+  attribute form:image-position { "center" }?
+  | (attribute form:image-position {
+       "start" | "end" | "top" | "bottom"
+     },
+     [ a:defaultValue = "center" ]
+     attribute form:image-align { "start" | "center" | "end" }?)
+bound-column = attribute form:bound-column { \string }?
+common-convert-empty-attlist =
+  [ a:defaultValue = "false" ]
+  attribute form:convert-empty-to-null { boolean }?
+common-data-field-attlist = attribute form:data-field { \string }?
+list-source = attribute form:list-source { \string }?
+list-source-type =
+  attribute form:list-source-type {
+    "table"
+    | "query"
+    | "sql"
+    | "sql-pass-through"
+    | "value-list"
+    | "table-fields"
+  }?
+form-properties = element form:properties { form-property+ }
+form-property |=
+  element form:property {
+    form-property-name, form-property-value-and-type-attlist
+  }
+form-property-name &= attribute form:property-name { \string }
+form-property-value-and-type-attlist &=
+  common-value-and-type-attlist
+  | attribute office:value-type { "void" }
+form-property |=
+  element form:list-property {
+    form-property-name, form-property-type-and-value-list
+  }
+form-property-type-and-value-list =
+  (attribute office:value-type { "float" },
+   element form:list-value {
+     attribute office:value { double }
+   }*)
+  | (attribute office:value-type { "percentage" },
+     element form:list-value {
+       attribute office:value { double }
+     }*)
+  | (attribute office:value-type { "currency" },
+     element form:list-value {
+       attribute office:value { double },
+       attribute office:currency { \string }?
+     }*)
+  | (attribute office:value-type { "date" },
+     element form:list-value {
+       attribute office:date-value { dateOrDateTime }
+     }*)
+  | (attribute office:value-type { "time" },
+     element form:list-value {
+       attribute office:time-value { duration }
+     }*)
+  | (attribute office:value-type { "boolean" },
+     element form:list-value {
+       attribute office:boolean-value { boolean }
+     }*)
+  | (attribute office:value-type { "string" },
+     element form:list-value {
+       attribute office:string-value { \string }
+     }*)
+  | attribute office:value-type { "void" }
+office-annotation =
+  element office:annotation {
+    office-annotation-attlist,
+    draw-caption-attlist,
+    common-draw-position-attlist,
+    common-draw-size-attlist,
+    common-draw-shape-with-text-and-styles-attlist,
+    dc-creator?,
+    dc-date?,
+    meta-date-string?,
+    (text-p | text-list)*
+  }
+office-annotation-attlist &= attribute office:display { boolean }?
+meta-date-string = element meta:date-string { \string }
+common-num-format-prefix-suffix-attlist &=
+  attribute style:num-prefix { \string }?,
+  attribute style:num-suffix { \string }?
+common-num-format-attlist &=
+  attribute style:num-format { "1" | "i" | "I" | \string | empty }
+  | (attribute style:num-format { "a" | "A" },
+     style-num-letter-sync-attlist)
+  | empty
+style-num-letter-sync-attlist &=
+  attribute style:num-letter-sync { boolean }?
+office-change-info =
+  element office:change-info { dc-creator, dc-date, text-p* }
+office-event-listeners =
+  element office:event-listeners {
+    (script-event-listener | presentation-event-listener)*
+  }
+script-event-listener &=
+  element script:event-listener { script-event-listener-attlist, empty }
+script-event-listener-attlist &= attribute script:event-name { \string }
+script-event-listener-attlist &= attribute script:language { \string }
+script-event-listener-attlist &=
+  attribute script:macro-name { \string }
+  | (attribute xlink:href { anyURI },
+     [ a:defaultValue = "simple" ] attribute xlink:type { "simple" }?,
+     [ a:defaultValue = "onRequest" ]
+     attribute xlink:actuate { "onRequest" }?)
+math-math = element math:math { mathMarkup }
+# To avoid inclusion of the complete MathML schema, anything
+
+# is allowed within a math:math top-level element
+mathMarkup =
+  (attribute * { text }
+   | text
+   | element * { mathMarkup })*
+text-dde-connection-decl =
+  element text:dde-connection-decl {
+    text-dde-connection-decl-attlist, common-dde-connection-decl-attlist
+  }
+text-dde-connection-decl-attlist &= attribute office:name { \string }
+common-dde-connection-decl-attlist &=
+  attribute office:dde-application { \string }
+common-dde-connection-decl-attlist &=
+  attribute office:dde-topic { \string }
+common-dde-connection-decl-attlist &=
+  attribute office:dde-item { \string }
+common-dde-connection-decl-attlist &=
+  [ a:defaultValue = "true" ]
+  attribute office:automatic-update { boolean }?
+table-dde-link =
+  element table:dde-link { office-dde-source, table-table }
+office-dde-source =
+  element office:dde-source {
+    office-dde-source-attlist, common-dde-connection-decl-attlist
+  }
+office-dde-source-attlist &= attribute office:name { \string }?
+office-dde-source-attlist &=
+  [ a:defaultValue = "into-default-style-data-style" ]
+  attribute office:conversion-mode {
+    "into-default-style-data-style"
+    | "into-english-number"
+    | "keep-text"
+  }?
+animation-element |=
+  element anim:animate {
+    common-anim-target-attlist,
+    common-anim-named-target-attlist,
+    common-anim-values-attlist,
+    common-anim-spline-mode-attlist,
+    common-spline-anim-value-attlist,
+    common-timing-attlist,
+    common-anim-add-accum-attlist
+  }
+animation-element |=
+  element anim:set {
+    common-anim-target-attlist,
+    common-anim-named-target-attlist,
+    common-anim-set-values-attlist,
+    common-timing-attlist,
+    common-anim-add-accum-attlist
+  }
+animation-element |=
+  element anim:animateMotion {
+    anim-animate-motion-attlist,
+    common-anim-target-attlist,
+    common-anim-named-target-attlist,
+    common-anim-add-accum-attlist,
+    common-anim-values-attlist,
+    common-timing-attlist,
+    common-spline-anim-value-attlist
+  }
+anim-animate-motion-attlist &= attribute svg:path { pathData }?
+anim-animate-motion-attlist &= attribute svg:origin { \string }?
+anim-animate-motion-attlist &=
+  [ a:defaultValue = "paced" ]
+  attribute smil:calcMode {
+    "discrete" | "linear" | "paced" | "spline"
+  }?
+animation-element |=
+  element anim:animateColor {
+    common-anim-target-attlist,
+    common-anim-named-target-attlist,
+    common-anim-add-accum-attlist,
+    common-anim-values-attlist,
+    common-anim-spline-mode-attlist,
+    common-spline-anim-value-attlist,
+    anim-animate-color-attlist,
+    common-timing-attlist
+  }
+anim-animate-color-attlist &=
+  [ a:defaultValue = "rgb" ]
+  attribute anim:color-interpolation { "rgb" | "hsl" }?
+anim-animate-color-attlist &=
+  [ a:defaultValue = "clockwise" ]
+  attribute anim:color-interpolation-direction {
+    "clockwise" | "counter-clockwise"
+  }?
+animation-element |=
+  element anim:animateTransform {
+    common-anim-target-attlist,
+    common-anim-named-target-attlist,
+    common-anim-add-accum-attlist,
+    common-anim-values-attlist,
+    anim-animate-transform-attlist,
+    common-timing-attlist
+  }
+anim-animate-transform-attlist &=
+  attribute svg:type {
+    "translate" | "scale" | "rotate" | "skewX" | "skewY"
+  }
+animation-element |=
+  element anim:transitionFilter {
+    common-anim-target-attlist,
+    common-anim-add-accum-attlist,
+    common-anim-values-attlist,
+    common-anim-spline-mode-attlist,
+    anim-transition-filter-attlist,
+    common-timing-attlist
+  }
+anim-transition-filter-attlist &= attribute smil:type { \string }
+anim-transition-filter-attlist &= attribute smil:subtype { \string }?
+anim-transition-filter-attlist &=
+  [ a:defaultValue = "forward" ]
+  attribute smil:direction { "forward" | "reverse" }?
+anim-transition-filter-attlist &=
+  attribute smil:fadeColor { "forward" | "reverse" }?
+anim-transition-filter-attlist &=
+  [ a:defaultValue = "in" ] attribute smil:mode { "in" | "out" }?
+common-anim-attlist &= attribute anim:id { ID }?
+common-anim-target-attlist &= attribute smil:targetElement { IDREF }?
+common-anim-named-target-attlist &=
+  attribute smil:attributeName { \string }
+common-anim-target-attlist &= attribute anim:sub-item { \string }?
+common-anim-values-attlist &= attribute smil:values { \string }?
+common-anim-spline-mode-attlist &=
+  [ a:defaultValue = "discrete" ]
+  attribute smil:calcMode {
+    "discrete" | "linear" | "paced" | "spline"
+  }?
+common-spline-anim-value-attlist &= attribute smil:keyTimes { \string }?
+common-spline-anim-value-attlist &=
+  attribute smil:keySplines { \string }?
+common-anim-add-accum-attlist &=
+  attribute smil:accumulate { "none" | "sum" }?
+common-anim-add-accum-attlist &=
+  attribute smil:additive { "replace" | "sum" }?
+common-anim-values-attlist &= attribute anim:formula { \string }?
+common-anim-set-values-attlist &= attribute smil:to { \string }?
+common-anim-values-attlist &=
+  common-anim-set-values-attlist,
+  attribute smil:from { \string }?,
+  attribute smil:by { \string }?
+common-begin-end-timing-attlist &= attribute smil:begin { \string }?
+common-begin-end-timing-attlist &= attribute smil:end { \string }?
+common-dur-timing-attlist &= attribute smil:dur { \string }?
+common-endsync-timing-attlist &=
+  attribute smil:endsync { "first" | "last" | "all" | "media" }?
+common-repeat-timing-attlist &=
+  attribute smil:repeatDur { \string }?,
+  attribute smil:repeatCount { nonNegativeInteger | "indefinite" }?
+common-fill-timing-attlist &=
+  attribute smil:fill {
+    "remove" | "freeze" | "hold" | "auto" | "default" | "transition"
+  }?
+common-fill-default-attlist &=
+  attribute smil:fillDefault {
+    "remove" | "freeze" | "hold" | "transition" | "auto" | "inherit"
+  }?
+common-restart-timing-attlist &=
+  [ a:defaultValue = "default" ]
+  attribute smil:restart {
+    "never" | "always" | "whenNotActive" | "default"
+  }?
+common-restart-default-attlist &=
+  [ a:defaultValue = "inherit" ]
+  attribute smil:restartDefault {
+    "never" | "always" | "whenNotActive" | "inherit"
+  }?
+common-time-manip-attlist &=
+  [ a:defaultValue = "0.0" ] attribute smil:accelerate { double }?
+common-time-manip-attlist &=
+  [ a:defaultValue = "0.0" ] attribute smil:decelerate { double }?
+common-time-manip-attlist &=
+  [ a:defaultValue = "false" ] attribute smil:autoReverse { boolean }?
+animation-element |=
+  element anim:par {
+    common-anim-attlist,
+    common-timing-attlist,
+    common-endsync-timing-attlist,
+    animation-element*
+  }
+common-basic-timing-attlist &=
+  common-begin-end-timing-attlist,
+  common-dur-timing-attlist,
+  common-repeat-timing-attlist
+common-timing-attlist &=
+  common-basic-timing-attlist,
+  common-restart-timing-attlist,
+  common-restart-default-attlist,
+  common-fill-timing-attlist,
+  common-fill-default-attlist,
+  common-time-manip-attlist
+animation-element |=
+  element anim:seq {
+    common-anim-attlist,
+    common-endsync-timing-attlist,
+    common-timing-attlist,
+    animation-element*
+  }
+animation-element |=
+  element anim:iterate {
+    common-anim-attlist,
+    anim-iterate-attlist,
+    common-timing-attlist,
+    common-endsync-timing-attlist,
+    animation-element*
+  }
+anim-iterate-attlist &= common-anim-target-attlist
+anim-iterate-attlist &= attribute anim:iterate-type { \string }?
+anim-iterate-attlist &= attribute anim:iterate-interval { duration }?
+animation-element |=
+  element anim:audio {
+    common-anim-attlist, anim-audio-attlist, common-basic-timing-attlist
+  }
+anim-audio-attlist &= attribute xlink:href { anyURI }?
+anim-audio-attlist &= attribute anim:audio-level { double }?
+animation-element |=
+  element anim:command {
+    common-anim-attlist,
+    anim-command-attlist,
+    common-begin-end-timing-attlist,
+    common-anim-target-attlist,
+    element anim:param {
+      attribute anim:name { text },
+      attribute anim:value { text }
+    }*
+  }
+anim-command-attlist &= attribute anim:command { \string }
+style-style =
+  element style:style {
+    style-style-attlist, style-style-content, style-map*
+  }
+style-style-attlist &= attribute style:name { styleName }
+style-style-attlist &= attribute style:display-name { \string }?
+style-style-attlist &=
+  attribute style:parent-style-name { styleNameRef }?
+style-style-attlist &= attribute style:next-style-name { styleNameRef }?
+style-style-attlist &=
+  attribute style:list-style-name { styleName | empty }?
+style-style-attlist &=
+  attribute style:master-page-name { styleNameRef }?
+style-style-attlist &=
+  [ a:defaultValue = "false" ] attribute style:auto-update { boolean }?
+style-style-attlist &= attribute style:data-style-name { styleNameRef }?
+style-style-attlist &= attribute style:class { \string }?
+style-style-attlist &=
+  attribute style:default-outline-level { positiveInteger }?
+style-map = element style:map { style-map-attlist, empty }
+style-map-attlist &= attribute style:condition { \string }
+style-map-attlist &= attribute style:apply-style-name { styleNameRef }
+style-map-attlist &= attribute style:base-cell-address { cellAddress }?
+style-default-style =
+  element style:default-style { style-style-content }
+style-page-layout =
+  element style:page-layout {
+    style-page-layout-attlist,
+    style-page-layout-properties?,
+    style-header-style?,
+    style-footer-style?
+  }
+style-page-layout-attlist &= attribute style:name { styleName }
+style-page-layout-attlist &=
+  [ a:defaultValue = "all" ]
+  attribute style:page-usage { "all" | "left" | "right" | "mirrored" }?
+style-header-style =
+  element style:header-style { style-header-footer-properties? }
+style-footer-style =
+  element style:footer-style { style-header-footer-properties? }
+style-master-page =
+  element style:master-page {
+    style-master-page-attlist,
+    (style-header, style-header-left?)?,
+    (style-footer, style-footer-left?)?,
+    office-forms?,
+    style-style*,
+    shape*,
+    presentation-notes?
+  }
+style-master-page-attlist &= attribute style:name { styleName }
+style-master-page-attlist &= attribute style:display-name { \string }?
+style-master-page-attlist &=
+  attribute style:page-layout-name { styleNameRef }
+style-master-page-attlist &= attribute draw:style-name { styleNameRef }?
+style-master-page-attlist &=
+  attribute style:next-style-name { styleNameRef }?
+style-header =
+  element style:header {
+    common-style-header-footer-attlist, header-footer-content
+  }
+style-footer =
+  element style:footer {
+    common-style-header-footer-attlist, header-footer-content
+  }
+style-header-left =
+  element style:header-left {
+    common-style-header-footer-attlist, header-footer-content
+  }
+style-footer-left =
+  element style:footer-left {
+    common-style-header-footer-attlist, header-footer-content
+  }
+header-footer-content =
+  (text-tracked-changes,
+   text-decls,
+   (text-h
+    | text-p
+    | text-list
+    | table-table
+    | text-section
+    | text-table-of-content
+    | text-illustration-index
+    | text-table-index
+    | text-object-index
+    | text-user-index
+    | text-alphabetical-index
+    | text-bibliography
+    | text-index-title
+    | change-marks)*)
+  | (style-region-left?, style-region-center?, style-region-right?)
+common-style-header-footer-attlist &=
+  [ a:defaultValue = "true" ] attribute style:display { boolean }?
+style-region-left = element style:region-left { region-content }
+style-region-center = element style:region-center { region-content }
+style-region-right = element style:region-right { region-content }
+region-content = text-p*
+presentation-notes =
+  element presentation:notes {
+    common-presentation-header-footer-attlist,
+    presentation-notes-attlist,
+    office-forms,
+    shape*
+  }
+presentation-notes-attlist &=
+  attribute style:page-layout-name { styleNameRef }?
+presentation-notes-attlist &=
+  attribute draw:style-name { styleNameRef }?
+table-table-template =
+  element table:table-template {
+    table-table-template-attlist,
+    table-first-row?,
+    table-last-row?,
+    table-first-column?,
+    table-last-column?,
+    (table-body
+     | (table-even-rows, table-odd-rows)
+     | (table-even-columns, table-odd-columns))
+  }
+table-table-template-attlist &= attribute text:name { \string }
+table-table-template-attlist &=
+  attribute text:first-row-start-column { rowOrCol }
+table-table-template-attlist &=
+  attribute text:first-row-end-column { rowOrCol }
+table-table-template-attlist &=
+  attribute text:last-row-start-column { rowOrCol }
+table-table-template-attlist &=
+  attribute text:last-row-end-column { rowOrCol }
+rowOrCol = "row" | "column"
+table-first-row =
+  element table:first-row { common-table-template-attlist, empty }
+table-last-row =
+  element table:last-row { common-table-template-attlist, empty }
+table-first-column =
+  element table:first-column { common-table-template-attlist, empty }
+table-last-column =
+  element table:last-column { common-table-template-attlist, empty }
+table-body = element table:body { common-table-template-attlist, empty }
+table-even-rows =
+  element table:even-rows { common-table-template-attlist, empty }
+table-odd-rows =
+  element table:odd-rows { common-table-template-attlist, empty }
+table-even-columns =
+  element table:even-columns { common-table-template-attlist, empty }
+table-odd-columns =
+  element table:odd-columns { common-table-template-attlist, empty }
+common-table-template-attlist &=
+  attribute text:style-name { styleNameRef },
+  attribute text:paragraph-style-name { styleNameRef? }
+style-font-face =
+  element style:font-face {
+    style-font-face-attlist, svg-font-face-src?, svg-definition-src?
+  }
+style-font-face-attlist &=
+  attribute svg:font-family { \string }?,
+  attribute svg:font-style { fontStyle }?,
+  attribute svg:font-variant { fontVariant }?,
+  attribute svg:font-weight { fontWeight }?,
+  attribute svg:font-stretch {
+    "normal"
+    | "ultra-condensed"
+    | "extra-condensed"
+    | "condensed"
+    | "semi-condensed"
+    | "semi-expanded"
+    | "expanded"
+    | "extra-expanded"
+    | "ultra-expanded"
+  }?,
+  attribute svg:font-size { positiveLength }?,
+  attribute svg:unicode-range { text }?,
+  attribute svg:units-per-em { integer }?,
+  attribute svg:panose-1 { text }?,
+  attribute svg:stemv { integer }?,
+  attribute svg:stemh { integer }?,
+  attribute svg:slope { integer }?,
+  attribute svg:cap-height { integer }?,
+  attribute svg:x-height { integer }?,
+  attribute svg:accent-height { integer }?,
+  attribute svg:ascent { integer }?,
+  attribute svg:descent { integer }?,
+  attribute svg:widths { text }?,
+  attribute svg:bbox { text }?,
+  attribute svg:ideographic { integer }?,
+  attribute svg:alphabetic { integer }?,
+  attribute svg:mathematical { integer }?,
+  attribute svg:hanging { integer }?,
+  attribute svg:v-ideographic { integer }?,
+  attribute svg:v-alphabetic { integer }?,
+  attribute svg:v-mathematical { integer }?,
+  attribute svg:v-hanging { integer }?,
+  attribute svg:underline-position { integer }?,
+  attribute svg:underline-thickness { integer }?,
+  attribute svg:strikethrough-position { integer }?,
+  attribute svg:strikethrough-thickness { integer }?,
+  attribute svg:overline-position { integer }?,
+  attribute svg:overline-thickness { integer }?
+svg-font-face-src =
+  element svg:font-face-src {
+    (svg-font-face-uri | svg-font-face-name)+
+  }
+svg-font-face-uri =
+  element svg:font-face-uri {
+    common-svg-font-face-xlink-attlist, svg-font-face-format*
+  }
+svg-font-face-format =
+  element svg:font-face-format {
+    attribute svg:string { text }?,
+    empty
+  }
+svg-font-face-name =
+  element svg:font-face-name {
+    attribute svg:name { text }?,
+    empty
+  }
+svg-definition-src =
+  element svg:definition-src {
+    common-svg-font-face-xlink-attlist, empty
+  }
+common-svg-font-face-xlink-attlist &=
+  attribute xlink:href { anyURI },
+  [ a:defaultValue = "simple" ] attribute xlink:type { "simple" }?,
+  [ a:defaultValue = "onRequest" ]
+  attribute xlink:actuate { "onRequest" }?
+style-font-face-attlist &= attribute style:name { \string }
+style-font-face-attlist &= attribute style:font-adornments { \string }?
+style-font-face-attlist &=
+  attribute style:font-family-generic { fontFamilyGeneric }?
+style-font-face-attlist &= attribute style:font-pitch { fontPitch }?
+style-font-face-attlist &=
+  attribute style:font-charset { textEncoding }?
+number-number-style =
+  element number:number-style {
+    common-data-style-attlist,
+    style-text-properties?,
+    number-text?,
+    (any-number, number-text?)?,
+    style-map*
+  }
+any-number = number-number | number-scientific-number | number-fraction
+number-number =
+  element number:number {
+    number-number-attlist,
+    common-decimal-places-attlist,
+    common-number-attlist,
+    number-embedded-text*
+  }
+number-number-attlist &= attribute number:decimal-replacement { text }?
+number-number-attlist &=
+  [ a:defaultValue = "1" ] attribute number:display-factor { double }?
+number-embedded-text =
+  element number:embedded-text { number-embedded-text-attlist, text }
+number-embedded-text-attlist &= attribute number:position { integer }
+number-scientific-number =
+  element number:scientific-number {
+    number-scientific-number-attlist,
+    common-decimal-places-attlist,
+    common-number-attlist,
+    empty
+  }
+number-scientific-number-attlist &=
+  attribute number:min-exponent-digits { integer }?
+number-fraction =
+  element number:fraction {
+    number-fraction-attlist, common-number-attlist, empty
+  }
+number-fraction-attlist &=
+  attribute number:min-numerator-digits { integer }?
+number-fraction-attlist &=
+  attribute number:min-denominator-digits { integer }?
+number-fraction-attlist &=
+  attribute number:denominator-value { integer }?
+number-currency-style =
+  element number:currency-style {
+    common-data-style-attlist,
+    common-auto-reorder-attlist,
+    style-text-properties?,
+    number-text?,
+    ((number-and-text, currency-symbol-and-text?)
+     | (currency-symbol-and-text, number-and-text?))?,
+    style-map*
+  }
+currency-symbol-and-text = number-currency-symbol, number-text?
+number-and-text = number-number, number-text?
+number-currency-symbol =
+  element number:currency-symbol {
+    number-currency-symbol-attlist, text
+  }
+number-currency-symbol-attlist &=
+  attribute number:language { languageCode }?,
+  attribute number:country { countryCode }?
+number-percentage-style =
+  element number:percentage-style {
+    common-data-style-attlist,
+    style-text-properties?,
+    number-text?,
+    number-and-text?,
+    style-map*
+  }
+number-date-style =
+  element number:date-style {
+    common-data-style-attlist,
+    common-auto-reorder-attlist,
+    common-format-source-attlist,
+    style-text-properties?,
+    # This DTD does not reflect the fact that some elements must not
+    
+    # occur more than once.
+    number-text?,
+    (any-date, number-text?)+,
+    style-map*
+  }
+any-date =
+  number-day
+  | number-month
+  | number-year
+  | number-era
+  | number-day-of-week
+  | number-week-of-year
+  | number-quarter
+  | number-hours
+  | number-am-pm
+  | number-minutes
+  | number-seconds
+number-day =
+  element number:day {
+    number-day-attlist, common-calendar-attlist, empty
+  }
+number-day-attlist &=
+  [ a:defaultValue = "short" ]
+  attribute number:style { "short" | "long" }?
+number-month =
+  element number:month {
+    number-month-attlist, common-calendar-attlist, empty
+  }
+number-month-attlist &=
+  [ a:defaultValue = "false" ] attribute number:textual { boolean }?
+number-month-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute number:possessive-form { boolean }?
+number-month-attlist &=
+  [ a:defaultValue = "short" ]
+  attribute number:style { "short" | "long" }?
+number-year =
+  element number:year {
+    number-year-attlist, common-calendar-attlist, empty
+  }
+number-year-attlist &=
+  [ a:defaultValue = "short" ]
+  attribute number:style { "short" | "long" }?
+number-era =
+  element number:era {
+    number-era-attlist, common-calendar-attlist, empty
+  }
+number-era-attlist &=
+  [ a:defaultValue = "short" ]
+  attribute number:style { "short" | "long" }?
+number-day-of-week =
+  element number:day-of-week {
+    number-day-of-week-attlist, common-calendar-attlist, empty
+  }
+number-day-of-week-attlist &=
+  [ a:defaultValue = "short" ]
+  attribute number:style { "short" | "long" }?
+number-week-of-year =
+  element number:week-of-year { common-calendar-attlist, empty }
+number-quarter =
+  element number:quarter {
+    number-quarter-attlist, common-calendar-attlist, empty
+  }
+number-quarter-attlist &=
+  [ a:defaultValue = "short" ]
+  attribute number:style { "short" | "long" }?
+number-time-style =
+  element number:time-style {
+    number-time-style-attlist,
+    common-data-style-attlist,
+    common-format-source-attlist,
+    style-text-properties?,
+    # This DTD does not reflect the fact that some elements must not
+    
+    # occur more than once.
+    number-text?,
+    (any-time, number-text?)+,
+    style-map*
+  }
+any-time = number-hours | number-am-pm | number-minutes | number-seconds
+number-time-style-attlist &=
+  [ a:defaultValue = "true" ]
+  attribute number:truncate-on-overflow { boolean }?
+number-hours = element number:hours { number-hours-attlist, empty }
+number-hours-attlist &=
+  [ a:defaultValue = "short" ]
+  attribute number:style { "short" | "long" }?
+number-minutes =
+  element number:minutes { number-minutes-attlist, empty }
+number-minutes-attlist &=
+  [ a:defaultValue = "short" ]
+  attribute number:style { "short" | "long" }?
+number-seconds =
+  element number:seconds { number-seconds-attlist, empty }
+number-seconds-attlist &=
+  [ a:defaultValue = "short" ]
+  attribute number:style { "short" | "long" }?
+number-seconds-attlist &=
+  [ a:defaultValue = "0" ] attribute number:decimal-places { integer }?
+number-am-pm = element number:am-pm { empty }
+number-boolean-style =
+  element number:boolean-style {
+    common-data-style-attlist,
+    style-text-properties?,
+    number-text?,
+    (number-boolean, number-text?)?,
+    style-map*
+  }
+number-boolean = element number:boolean { empty }
+number-text-style =
+  element number:text-style {
+    common-data-style-attlist,
+    style-text-properties?,
+    number-text?,
+    (number-text-content, number-text?)*,
+    style-map*
+  }
+number-text = element number:text { text }
+number-text-content = element number:text-content { empty }
+common-data-style-attlist &= attribute style:name { styleName }
+style-data-style-attlist &= attribute style:display-name { \string }?
+common-data-style-attlist &= attribute number:language { languageCode }?
+common-data-style-attlist &= attribute number:country { countryCode }?
+common-data-style-attlist &= attribute number:title { text }?
+common-data-style-attlist &= attribute style:volatile { boolean }?
+common-auto-reorder-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute number:automatic-order { boolean }?
+common-format-source-attlist =
+  [ a:defaultValue = "fixed" ]
+  attribute number:format-source { "fixed" | "language" }?
+common-data-style-attlist &=
+  [ a:defaultValue = "1" ]
+  attribute number:transliteration-format { \string }?
+common-data-style-attlist &=
+  attribute number:transliteration-language { countryCode }?
+common-data-style-attlist &=
+  attribute number:transliteration-country { countryCode }?
+common-data-style-attlist &=
+  [ a:defaultValue = "short" ]
+  attribute number:transliteration-style {
+    "short" | "medium" | "long"
+  }?
+common-decimal-places-attlist =
+  attribute number:decimal-places { integer }?
+common-number-attlist &=
+  attribute number:min-integer-digits { integer }?
+common-number-attlist &=
+  [ a:defaultValue = "false" ] attribute number:grouping { boolean }?
+common-calendar-attlist &=
+  attribute number:calendar {
+    "gregorian"
+    | "gengou"
+    | "ROC"
+    | "hanja_yoil"
+    | "hanja"
+    | "hijri"
+    | "jewish"
+    | "buddhist"
+    | \string
+  }?
+style-style-content |=
+  attribute style:family { "text" },
+  style-text-properties?
+style-style-content |=
+  attribute style:family { "paragraph" },
+  style-paragraph-properties?,
+  style-text-properties?
+style-style-content |=
+  attribute style:family { "section" },
+  style-section-properties?
+style-style-content |=
+  attribute style:family { "ruby" },
+  style-ruby-properties?
+text-linenumbering-configuration =
+  element text:linenumbering-configuration {
+    text-linenumbering-configuration-attlist,
+    text-linenumbering-separator?
+  }
+text-linenumbering-configuration-attlist &=
+  [ a:defaultValue = "true" ] attribute text:number-lines { boolean }?
+text-linenumbering-configuration-attlist &= common-num-format-attlist?
+text-linenumbering-configuration-attlist &=
+  attribute text:style-name { styleNameRef }?
+text-linenumbering-configuration-attlist &=
+  attribute text:increment { nonNegativeInteger }?
+text-linenumbering-configuration-attlist &=
+  [ a:defaultValue = "left" ]
+  attribute text:number-position {
+    "left" | "right" | "inner" | "outer"
+  }?
+text-linenumbering-configuration-attlist &=
+  attribute text:offset { nonNegativeLength }?
+text-linenumbering-configuration-attlist &=
+  [ a:defaultValue = "true" ]
+  attribute text:count-empty-lines { boolean }?
+text-linenumbering-configuration-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute text:count-in-text-boxes { boolean }?
+text-linenumbering-configuration-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute text:restart-on-page { boolean }?
+text-linenumbering-separator =
+  element text:linenumbering-separator {
+    attribute text:increment { nonNegativeInteger }?,
+    text
+  }
+text-notes-configuration =
+  element text:notes-configuration { text-notes-configuration-content }
+text-notes-configuration-content &= text-note-class
+text-notes-configuration-content &=
+  attribute text:citation-style-name { styleNameRef }?
+text-notes-configuration-content &=
+  attribute text:citation-body-style-name { styleNameRef }?
+text-notes-configuration-content &=
+  attribute text:default-style-name { styleNameRef }?
+text-notes-configuration-content &=
+  attribute text:master-page-name { styleNameRef }?
+text-notes-configuration-content &=
+  attribute text:start-value { nonNegativeInteger }?
+text-notes-configuration-content &=
+  common-num-format-prefix-suffix-attlist, common-num-format-attlist?
+text-notes-configuration-content &=
+  attribute text:start-numbering-at { "document" | "chapter" | "page" }?
+text-notes-configuration-content &=
+  attribute text:footnotes-position {
+    "text" | "page" | "section" | "document"
+  }?
+text-notes-configuration-content &=
+  element text:note-continuation-notice-forward { text }?
+text-notes-configuration-content &=
+  element text:note-continuation-notice-backward { text }?
+text-bibliography-configuration =
+  element text:bibliography-configuration {
+    text-bibliography-configuration-attlist, text-sort-key*
+  }
+text-bibliography-configuration-attlist &=
+  attribute text:prefix { \string }?,
+  attribute text:suffix { \string }?
+text-bibliography-configuration-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute text:numbered-entries { boolean }?
+text-bibliography-configuration-attlist &=
+  [ a:defaultValue = "true" ]
+  attribute text:sort-by-position { boolean }?,
+  attribute fo:language { languageCode }?,
+  attribute fo:country { countryCode }?,
+  attribute text:sort-algorithm { \string }?
+text-sort-key = element text:sort-key { text-sort-key-attlist, empty }
+text-sort-key-attlist &=
+  attribute text:key {
+    "address"
+    | "annote"
+    | "author"
+    | "bibliography-type"
+    | "booktitle"
+    | "chapter"
+    | "custom1"
+    | "custom2"
+    | "custom3"
+    | "custom4"
+    | "custom5"
+    | "edition"
+    | "editor"
+    | "howpublished"
+    | "identifier"
+    | "institution"
+    | "isbn"
+    | "issn"
+    | "journal"
+    | "month"
+    | "note"
+    | "number"
+    | "organizations"
+    | "pages"
+    | "publisher"
+    | "report-type"
+    | "school"
+    | "series"
+    | "title"
+    | "url"
+    | "volume"
+    | "year"
+  },
+  [ a:defaultValue = "true" ] attribute text:sort-ascending { boolean }?
+text-list-style =
+  element text:list-style {
+    text-list-style-attr, text-list-style-content*
+  }
+text-list-style-attr &= attribute style:name { styleName }
+text-list-style-attr &= attribute style:display-name { \string }?
+text-list-style-attr &=
+  [ a:defaultValue = "false" ]
+  attribute text:consecutive-numbering { boolean }?
+text-list-level-style-attr = attribute text:level { positiveInteger }
+text-list-style-content |=
+  element text:list-level-style-number {
+    text-list-level-style-attr,
+    text-list-level-style-number-attr,
+    style-list-level-properties?,
+    style-text-properties?
+  }
+text-list-level-style-number-attr &=
+  attribute text:style-name { styleNameRef }?
+text-list-level-style-number-attr &=
+  common-num-format-attlist, common-num-format-prefix-suffix-attlist
+text-list-level-style-number-attr &=
+  [ a:defaultValue = "1" ]
+  attribute text:display-levels { positiveInteger }?
+text-list-level-style-number-attr &=
+  [ a:defaultValue = "1" ]
+  attribute text:start-value { positiveInteger }?
+text-list-style-content |=
+  element text:list-level-style-bullet {
+    text-list-level-style-attr,
+    text-list-level-style-bullet-attr,
+    style-list-level-properties?,
+    style-text-properties?
+  }
+text-list-level-style-bullet-attr &=
+  attribute text:style-name { styleNameRef }?
+text-list-level-style-bullet-attr &=
+  attribute text:bullet-char { character }
+text-list-level-style-bullet-attr &=
+  common-num-format-prefix-suffix-attlist
+text-list-level-style-bullet-attr &=
+  attribute text:bullet-relative-size { percent }?
+text-list-style-content |=
+  element text:list-level-style-image {
+    text-list-level-style-attr,
+    text-list-level-style-image-attr,
+    style-list-level-properties?
+  }
+text-list-level-style-image-attr &=
+  common-draw-data-attlist | office-binary-data
+text-outline-style =
+  element text:outline-style { text-outline-level-style+ }
+text-outline-level-style =
+  element text:outline-level-style {
+    text-outline-level-style-attlist,
+    style-list-level-properties?,
+    style-text-properties?
+  }
+text-outline-level-style-attlist &=
+  attribute text:level { positiveInteger }
+text-outline-level-style-attlist &=
+  attribute text:style-name { styleNameRef }?
+text-outline-level-style-attlist &=
+  common-num-format-attlist, common-num-format-prefix-suffix-attlist
+text-outline-level-style-attlist &=
+  [ a:defaultValue = "1" ]
+  attribute text:display-levels { positiveInteger }?
+text-outline-level-style-attlist &=
+  [ a:defaultValue = "1" ]
+  attribute text:start-value { positiveInteger }?
+style-style-content |=
+  attribute style:family { "table" },
+  style-table-properties?
+style-style-content |=
+  attribute style:family { "table-column" },
+  style-table-column-properties?
+style-style-content |=
+  attribute style:family { "table-row" },
+  style-table-row-properties?
+style-style-content |=
+  attribute style:family { "table-cell" },
+  style-table-cell-properties?,
+  style-paragraph-properties?,
+  style-text-properties?
+style-style-content |=
+  attribute style:family { "graphic" | "presentation" },
+  style-graphic-properties?,
+  style-paragraph-properties?,
+  style-text-properties?
+style-graphic-properties =
+  element style:graphic-properties { style-graphic-properties-content }
+style-graphic-properties-content = style-properties-content
+style-graphic-properties-content-strict =
+  style-graphic-properties-attlist,
+  style-graphic-fill-properties-attlist,
+  style-graphic-properties-elements
+style-graphic-properties-elements = empty
+style-style-content |=
+  attribute style:family { "drawing-page" },
+  style-drawing-page-properties?
+style-drawing-page-properties =
+  element style:drawing-page-properties {
+    style-drawing-page-properties-content
+  }
+style-drawing-page-properties-content = style-properties-content
+style-drawing-page-properties-content-strict =
+  style-graphic-fill-properties-attlist,
+  style-drawing-page-properties-attlist,
+  style-drawing-page-properties-elements
+draw-gradient =
+  element draw:gradient {
+    common-draw-gradient-attlist, draw-gradient-attlist, empty
+  }
+common-draw-gradient-attlist &= attribute draw:name { styleName }?
+common-draw-gradient-attlist &= attribute draw:display-name { \string }?
+common-draw-gradient-attlist &= attribute draw:style { gradient-style }
+gradient-style =
+  "linear" | "axial" | "radial" | "ellipsoid" | "square" | "rectangular"
+common-draw-gradient-attlist &=
+  attribute draw:cx { percent }?,
+  attribute draw:cy { percent }?
+draw-gradient-attlist &=
+  attribute draw:start-color { color }?,
+  attribute draw:end-color { color }?
+draw-gradient-attlist &=
+  attribute draw:start-intensity { percent }?,
+  attribute draw:end-intensity { percent }?
+common-draw-gradient-attlist &= attribute draw:angle { integer }?
+common-draw-gradient-attlist &= attribute draw:border { percent }?
+svg-linearGradient =
+  element svg:linearGradient {
+    common-svg-gradient-attlist,
+    [ a:defaultValue = "0%" ]
+    attribute svg:x1 { coordinate | percent }?,
+    [ a:defaultValue = "0%" ]
+    attribute svg:y1 { coordinate | percent }?,
+    [ a:defaultValue = "100%" ]
+    attribute svg:x2 { coordinate | percent }?,
+    [ a:defaultValue = "100%" ]
+    attribute svg:y2 { coordinate | percent }?,
+    svg-stop*
+  }
+svg-radialGradient =
+  element svg:radialGradient {
+    common-svg-gradient-attlist,
+    [ a:defaultValue = "50%" ]
+    attribute svg:cx { coordinate | percent }?,
+    [ a:defaultValue = "50%" ]
+    attribute svg:cy { coordinate | percent }?,
+    [ a:defaultValue = "50%" ]
+    attribute svg:r { coordinate | percent }?,
+    attribute svg:fx { coordinate | percent }?,
+    attribute svg:fy { coordinate | percent }?,
+    svg-stop*
+  }
+svg-stop =
+  element svg:stop {
+    attribute svg:offset { double | percent },
+    attribute svg:stop-color { color }?,
+    attribute svg:stop-opacity { double }?
+  }
+common-svg-gradient-attlist &=
+  [ a:defaultValue = "objectBoundingBox" ]
+  attribute svg:gradientUnits { "objectBoundingBox" }?,
+  attribute svg:gradientTransform { \string }?,
+  [ a:defaultValue = "pad" ]
+  attribute svg:spreadMethod { "pad" | "reflect" | "repeat" }?
+common-svg-gradient-attlist &= attribute draw:name { styleName }
+common-svg-gradient-attlist &= attribute draw:display-name { \string }?
+draw-hatch = element draw:hatch { draw-hatch-attlist, empty }
+draw-hatch-attlist &= attribute draw:name { styleName }
+draw-hatch-attlist &= attribute draw:display-name { \string }?
+draw-hatch-attlist &=
+  attribute draw:style { "single" | "double" | "triple" }
+draw-hatch-attlist &= attribute draw:color { color }?
+draw-hatch-attlist &= attribute draw:distance { length }?
+draw-hatch-attlist &= attribute draw:rotation { integer }?
+draw-fill-image =
+  element draw:fill-image {
+    draw-fill-image-attlist,
+    attribute xlink:href { anyURI },
+    [ a:defaultValue = "simple" ] attribute xlink:type { "simple" }?,
+    [ a:defaultValue = "embed" ] attribute xlink:show { "embed" }?,
+    [ a:defaultValue = "onLoad" ] attribute xlink:actuate { "onLoad" }?,
+    empty
+  }
+draw-fill-image-attlist &= attribute draw:name { styleName }
+draw-fill-image-attlist &= attribute draw:display-name { \string }?
+draw-fill-image-attlist &=
+  attribute svg:width { length }?,
+  attribute svg:height { length }?
+draw-opacity =
+  element draw:opacity {
+    common-draw-gradient-attlist, draw-opacity-attlist, empty
+  }
+draw-opacity-attlist &=
+  attribute draw:start { percent }?,
+  attribute draw:end { percent }?
+draw-marker =
+  element draw:marker {
+    draw-marker-attlist,
+    common-draw-viewbox-attlist,
+    common-draw-path-data-attlist,
+    empty
+  }
+draw-marker-attlist &= attribute draw:name { styleName }
+draw-marker-attlist &= attribute draw:display-name { \string }?
+draw-stroke-dash =
+  element draw:stroke-dash { draw-stroke-dash-attlist, empty }
+draw-stroke-dash-attlist &= attribute draw:name { styleName }
+draw-stroke-dash-attlist &= attribute draw:display-name { \string }?
+draw-stroke-dash-attlist &= attribute draw:style { "rect" | "round" }?
+draw-stroke-dash-attlist &=
+  attribute draw:dots1 { integer }?,
+  attribute draw:dots1-length { length }?,
+  attribute draw:dots2 { integer }?,
+  attribute draw:dots2-length { length }?
+draw-stroke-dash-attlist &= attribute draw:distance { length }?
+style-presentation-page-layout =
+  element style:presentation-page-layout {
+    attribute style:name { styleName },
+    attribute style:display-name { \string }?,
+    presentation-placeholder*
+  }
+presentation-placeholder =
+  element presentation:placeholder {
+    attribute presentation:object { presentation-classes },
+    attribute svg:x { coordinate | percent },
+    attribute svg:y { coordinate | percent },
+    attribute svg:width { length | percent },
+    attribute svg:height { length | percent },
+    empty
+  }
+style-style-content |=
+  attribute style:family { "chart" },
+  style-chart-properties?,
+  style-graphic-properties?,
+  style-paragraph-properties?,
+  style-text-properties?
+style-properties-content = anyAttListOrElements
+style-page-layout-properties =
+  element style:page-layout-properties {
+    style-page-layout-properties-content
+  }
+style-page-layout-properties-content = style-properties-content
+style-page-layout-properties-content-strict =
+  style-page-layout-properties-attlist,
+  style-page-layout-properties-elements
+style-page-layout-properties-attlist &=
+  attribute fo:page-width { length }?,
+  attribute fo:page-height { length }?
+style-page-layout-properties-attlist &=
+  common-num-format-attlist?, common-num-format-prefix-suffix-attlist
+style-page-layout-properties-attlist &=
+  attribute style:paper-tray-name { "default" | \string }?
+style-page-layout-properties-attlist &=
+  attribute style:print-orientation { "portrait" | "landscape" }?
+style-page-layout-properties-attlist &=
+  common-horizontal-margin-attlist,
+  common-vertical-margin-attlist,
+  common-margin-attlist
+style-page-layout-properties-attlist &= common-border-attlist
+style-page-layout-properties-attlist &= common-border-line-width-attlist
+style-page-layout-properties-attlist &= common-padding-attlist
+style-page-layout-properties-attlist &= common-shadow-attlist
+style-page-layout-properties-attlist &= common-background-color-attlist
+style-page-layout-properties-elements &= style-background-image
+style-page-layout-properties-elements &= style-columns
+style-page-layout-properties-attlist &=
+  attribute style:register-truth-ref-style-name { styleNameRef }?
+style-page-layout-properties-attlist &=
+  attribute style:print {
+    list {
+      ("headers"
+       | "grid"
+       | "annotations"
+       | "objects"
+       | "charts"
+       | "drawings"
+       | "formulas"
+       | "zero-values")*
+    }
+  }?
+style-page-layout-properties-attlist &=
+  attribute style:print-page-order { "ttb" | "ltr" }?
+style-page-layout-properties-attlist &=
+  attribute style:first-page-number { positiveInteger | "continue" }?
+style-page-layout-properties-attlist &=
+  attribute style:scale-to { percent }?,
+  attribute style:scale-to-pages { positiveInteger }?
+style-page-layout-properties-attlist &=
+  attribute style:table-centering {
+    "horizontal" | "vertical" | "both" | "none"
+  }?
+style-page-layout-properties-attlist &=
+  attribute style:footnote-max-height { length }?
+style-page-layout-properties-attlist &= common-writing-mode-attlist
+style-page-layout-properties-elements &= style-footnote-sep
+style-footnote-sep =
+  element style:footnote-sep { style-footnote-sep-attlist, empty }?
+style-footnote-sep-attlist &=
+  attribute style:width { length }?,
+  attribute style:rel-width { percent }?,
+  attribute style:color { color }?,
+  attribute style:line-style { lineStyle }?,
+  [ a:defaultValue = "left" ]
+  attribute style:adjustment { "left" | "center" | "right" }?,
+  attribute style:distance-before-sep { length }?,
+  attribute style:distance-after-sep { length }?
+style-page-layout-properties-attlist &=
+  attribute style:layout-grid-mode { "none" | "line" | "both" }?
+style-page-layout-properties-attlist &=
+  attribute style:layout-grid-base-height { length }?
+style-page-layout-properties-attlist &=
+  attribute style:layout-grid-ruby-height { length }?
+style-page-layout-properties-attlist &=
+  attribute style:layout-grid-lines { positiveInteger }?
+style-page-layout-properties-attlist &=
+  attribute style:layout-grid-color { color }?
+style-page-layout-properties-attlist &=
+  attribute style:layout-grid-ruby-below { boolean }?
+style-page-layout-properties-attlist &=
+  attribute style:layout-grid-print { boolean }?
+style-page-layout-properties-attlist &=
+  attribute style:layout-grid-display { boolean }?
+style-header-footer-properties =
+  element style:header-footer-properties {
+    style-header-footer-properties-content
+  }
+style-header-footer-properties-content = style-properties-content
+style-header-footer-properties-content-strict =
+  style-header-footer-properties-attlist,
+  style-header-footer-properties-elements
+style-header-footer-properties-attlist &=
+  attribute svg:height { length }?,
+  attribute fo:min-height { length }?
+style-header-footer-properties-attlist &=
+  common-horizontal-margin-attlist,
+  common-vertical-margin-attlist,
+  common-margin-attlist
+style-header-footer-properties-attlist &= common-border-attlist
+style-header-footer-properties-attlist &=
+  common-border-line-width-attlist
+style-header-footer-properties-attlist &= common-padding-attlist
+style-header-footer-properties-attlist &=
+  common-background-color-attlist
+style-header-footer-properties-elements &= style-background-image
+style-header-footer-properties-attlist &= common-shadow-attlist
+style-header-footer-properties-attlist &=
+  attribute style:dynamic-spacing { boolean }?
+style-text-properties =
+  element style:text-properties { style-text-properties-content }
+style-text-properties-content = style-properties-content
+style-text-properties-content-strict =
+  style-text-properties-attlist, style-text-properties-elements
+style-text-properties-elements = empty
+style-text-properties-attlist &=
+  attribute fo:font-variant { fontVariant }?
+fontVariant = "normal" | "small-caps"
+style-text-properties-attlist &=
+  attribute fo:text-transform {
+    "none" | "lowercase" | "uppercase" | "capitalize"
+  }?
+style-text-properties-attlist &= attribute fo:color { color }?
+style-text-properties-attlist &=
+  attribute style:use-window-font-color { boolean }?
+style-text-properties-attlist &=
+  attribute style:text-outline { boolean }?
+style-text-properties-attlist &=
+  attribute style:text-line-through-type { lineType }?
+style-text-properties-attlist &=
+  attribute style:text-line-through-style { lineStyle }?
+style-text-properties-attlist &=
+  attribute style:text-line-through-width { lineWidth }?
+style-text-properties-attlist &=
+  attribute style:text-line-through-color { "font-color" | color }?
+style-text-properties-attlist &=
+  attribute style:text-line-through-text { \string }?
+style-text-properties-attlist &=
+  attribute style:text-line-through-text-style { styleNameRef }?
+style-text-properties-attlist &=
+  attribute style:text-position {
+    list { (percent | "super" | "sub"), percent? }
+  }?
+style-text-properties-attlist &=
+  attribute style:font-name { \string }?,
+  attribute style:font-name-asian { \string }?,
+  attribute style:font-name-complex { \string }?
+style-text-properties-attlist &=
+  attribute fo:font-family { \string }?,
+  attribute style:font-family-asian { \string }?,
+  attribute style:font-family-complex { \string }?
+style-text-properties-attlist &=
+  attribute style:font-family-generic { fontFamilyGeneric }?,
+  attribute style:font-family-generic-asian { fontFamilyGeneric }?,
+  attribute style:font-family-generic-complex { fontFamilyGeneric }?
+fontFamilyGeneric =
+  "roman" | "swiss" | "modern" | "decorative" | "script" | "system"
+style-text-properties-attlist &=
+  attribute style:font-style-name { \string }?,
+  attribute style:font-style-name-asian { \string }?,
+  attribute style:font-style-name-complex { \string }?
+style-text-properties-attlist &=
+  attribute style:font-pitch { fontPitch }?,
+  attribute style:font-pitch-asian { fontPitch }?,
+  attribute style:font-pitch-complex { fontPitch }?
+fontPitch = "fixed" | "variable"
+style-text-properties-attlist &=
+  attribute style:font-charset { textEncoding }?,
+  attribute style:font-charset-asian { textEncoding }?,
+  attribute style:font-charset-complex { textEncoding }?
+textEncoding = xsd:string { pattern = "[A-Za-z][A-Za-z0-9._\-]*" }
+style-text-properties-attlist &=
+  attribute fo:font-size { positiveLength | percent }?,
+  attribute style:font-size-asian { positiveLength | percent }?,
+  attribute style:font-size-complex { positiveLength | percent }?
+style-text-properties-attlist &=
+  attribute style:font-size-rel { length }?,
+  attribute style:font-size-rel-asian { length }?,
+  attribute style:font-size-rel-complex { length }?
+style-text-properties-attlist &=
+  attribute style:script-type {
+    "latin" | "asian" | "complex" | "ignore"
+  }?
+style-text-properties-attlist &=
+  attribute fo:letter-spacing { length | "normal" }?
+style-text-properties-attlist &=
+  attribute fo:language { languageCode }?,
+  attribute style:language-asian { languageCode }?,
+  attribute style:language-complex { languageCode }?
+style-text-properties-attlist &=
+  attribute fo:country { countryCode }?,
+  attribute style:country-asian { countryCode }?,
+  attribute style:country-complex { countryCode }?
+style-text-properties-attlist &=
+  attribute fo:font-style { fontStyle }?,
+  attribute style:font-style-asian { fontStyle }?,
+  attribute style:font-style-complex { fontStyle }?
+fontStyle = "normal" | "italic" | "oblique"
+style-text-properties-attlist &=
+  attribute style:font-relief { "none" | "embossed" | "engraved" }?
+style-text-properties-attlist &=
+  attribute fo:text-shadow { shadowType }?
+shadowType =
+  "none"
+  | # The following string must match an XSL shadow decl
+    \string
+style-text-properties-attlist &=
+  attribute style:text-underline-type { lineType }?
+lineType = "none" | "single" | "double"
+style-text-properties-attlist &=
+  attribute style:text-underline-style { lineStyle }?
+lineStyle =
+  "none"
+  | "solid"
+  | "dotted"
+  | "dash"
+  | "long-dash"
+  | "dot-dash"
+  | "dot-dot-dash"
+  | "wave"
+style-text-properties-attlist &=
+  attribute style:text-underline-width { lineWidth }?
+lineWidth =
+  "auto"
+  | "normal"
+  | "bold"
+  | "thin"
+  | "dash"
+  | "medium"
+  | "thick"
+  | positiveInteger
+  | percent
+  | positiveLength
+style-text-properties-attlist &=
+  attribute style:text-underline-color { "font-color" | color }?
+style-text-properties-attlist &=
+  attribute fo:font-weight { fontWeight }?,
+  attribute style:font-weight-asian { fontWeight }?,
+  attribute style:font-weight-complex { fontWeight }?
+fontWeight =
+  "normal"
+  | "bold"
+  | "100"
+  | "200"
+  | "300"
+  | "400"
+  | "500"
+  | "600"
+  | "700"
+  | "800"
+  | "900"
+style-text-properties-attlist &=
+  attribute style:text-underline-mode { lineMode }?
+lineMode = "continuous" | "skip-white-space"
+style-text-properties-attlist &=
+  attribute style:text-line-through-mode { lineMode }?
+style-text-properties-attlist &=
+  attribute style:letter-kerning { boolean }?
+style-text-properties-attlist &=
+  attribute style:text-blinking { boolean }?
+style-text-properties-attlist &= common-background-color-attlist
+style-text-properties-attlist &=
+  attribute style:text-combine { "none" | "letters" | "lines" }?
+style-text-properties-attlist &=
+  attribute style:text-combine-start-char { character }?,
+  attribute style:text-combine-end-char { character }?
+style-text-properties-attlist &=
+  attribute style:text-emphasize {
+    "none"
+    | list {
+        ("none" | "accent" | "dot" | "circle" | "disc"),
+        ("above" | "below")
+      }
+  }?
+style-text-properties-attlist &= attribute style:text-scale { percent }?
+style-text-properties-attlist &=
+  attribute style:text-rotation-angle { integer }?
+style-text-properties-attlist &=
+  attribute style:text-rotation-scale { "fixed" | "line-height" }?
+style-text-properties-attlist &= attribute fo:hyphenate { boolean }?
+style-text-properties-attlist &=
+  attribute fo:hyphenation-remain-char-count { positiveInteger }?
+style-text-properties-attlist &=
+  attribute fo:hyphenation-push-char-count { positiveInteger }?
+style-text-properties-attlist &=
+  attribute text:display { "true" }
+  | attribute text:display { "none" }
+  | (attribute text:display { "condition" },
+     attribute text:condition { "none" })
+  | empty
+style-paragraph-properties =
+  element style:paragraph-properties {
+    style-paragraph-properties-content
+  }
+style-paragraph-properties-content = style-properties-content
+style-paragraph-properties-content-strict =
+  style-paragraph-properties-attlist,
+  style-paragraph-properties-elements
+style-paragraph-properties-attlist &=
+  attribute fo:line-height { "normal" | nonNegativeLength | percent }?
+style-paragraph-properties-attlist &=
+  attribute style:line-height-at-least { nonNegativeLength }?
+style-paragraph-properties-attlist &=
+  attribute style:line-spacing { length }?
+style-paragraph-properties-attlist &=
+  attribute style:font-independent-line-spacing { boolean }?
+style-paragraph-properties-attlist &= common-text-align
+common-text-align =
+  attribute fo:text-align {
+    "start" | "end" | "left" | "right" | "center" | "justify"
+  }?
+style-paragraph-properties-attlist &=
+  attribute fo:text-align-last { "start" | "center" | "justify" }?
+style-paragraph-properties-attlist &=
+  attribute style:justify-single-word { boolean }?
+style-paragraph-properties-attlist &=
+  attribute fo:keep-together { "auto" | "always" }?
+style-paragraph-properties-attlist &=
+  attribute fo:widows { nonNegativeInteger }?
+style-paragraph-properties-attlist &=
+  attribute fo:orphans { nonNegativeInteger }?
+style-paragraph-properties-elements &= style-tab-stops
+style-tab-stops = element style:tab-stops { style-tab-stop* }?
+style-tab-stop =
+  element style:tab-stop { style-tab-stop-attlist, empty }
+style-tab-stop-attlist &= attribute style:position { nonNegativeLength }
+style-tab-stop-attlist &=
+  [ a:defaultValue = "left" ]
+  attribute style:type { "left" | "center" | "right" }?
+  | (attribute style:type { "char" },
+     style-tab-stop-char-attlist)
+style-tab-stop-char-attlist &= attribute style:char { character }
+style-tab-stop-attlist &= attribute style:leader-type { lineType }?
+style-tab-stop-attlist &= attribute style:leader-style { lineStyle }?
+style-tab-stop-attlist &= attribute style:leader-width { lineWidth }?
+style-tab-stop-attlist &=
+  attribute style:leader-color { "font-color" | color }?
+style-tab-stop-attlist &=
+  [ a:defaultValue = " " ] attribute style:leader-text { \string }?
+style-tab-stop-attlist &=
+  attribute style:leader-text-style { styleNameRef }?
+style-paragraph-properties-attlist &=
+  attribute style:tab-stop-distance { nonNegativeLength }?
+style-paragraph-properties-attlist &=
+  attribute fo:hyphenation-keep { "auto" | "page" }?
+style-paragraph-properties-attlist &=
+  attribute fo:hyphenation-ladder-count {
+    "no-limit" | positiveInteger
+  }?
+style-paragraph-properties-elements &= style-drop-cap
+style-drop-cap =
+  element style:drop-cap { style-drop-cap-attlist, empty }?
+style-drop-cap-attlist &=
+  [ a:defaultValue = "1" ]
+  attribute style:length { "word" | positiveInteger }?
+style-drop-cap-attlist &=
+  [ a:defaultValue = "1" ] attribute style:lines { positiveInteger }?
+style-drop-cap-attlist &=
+  [ a:defaultValue = "0cm" ] attribute style:distance { length }?
+style-drop-cap-attlist &= attribute style:style-name { styleNameRef }?
+style-paragraph-properties-attlist &=
+  attribute style:register-true { boolean }?
+style-paragraph-properties-attlist &= common-horizontal-margin-attlist
+common-horizontal-margin-attlist =
+  attribute fo:margin-left { length | percent }?,
+  attribute fo:margin-right { length | percent }?
+style-paragraph-properties-attlist &=
+  attribute fo:text-indent { length | percent }?
+style-paragraph-properties-attlist &=
+  attribute style:auto-text-indent { boolean }?
+style-paragraph-properties-attlist &= common-vertical-margin-attlist
+common-vertical-margin-attlist =
+  attribute fo:margin-top { nonNegativeLength | percent }?,
+  attribute fo:margin-bottom { nonNegativeLength | percent }?
+style-paragraph-properties-attlist &= common-margin-attlist
+common-margin-attlist =
+  attribute fo:margin { nonNegativeLength | percent }?
+style-paragraph-properties-attlist &= common-break-attlist
+common-break-attlist =
+  attribute fo:break-before { "auto" | "column" | "page" }?,
+  attribute fo:break-after { "auto" | "column" | "page" }?
+style-paragraph-properties-attlist &= common-background-color-attlist
+common-background-color-attlist =
+  attribute fo:background-color { "transparent" | color }?
+style-paragraph-properties-elements &= style-background-image
+style-background-image =
+  element style:background-image {
+    style-background-image-attlist,
+    (common-draw-data-attlist | office-binary-data | empty)
+  }?
+style-background-image-attlist &=
+  [ a:defaultValue = "repeat" ]
+  attribute style:repeat { "no-repeat" | "repeat" | "stretch" }?
+style-background-image-attlist &=
+  [ a:defaultValue = "center" ]
+  attribute style:position {
+    "left"
+    | "center"
+    | "right"
+    | "top"
+    | "bottom"
+    | list { horiBackPos, vertBackPos }
+    | list { vertBackPos, horiBackPos }
+  }?
+horiBackPos = "left" | "center" | "right"
+vertBackPos = "top" | "center" | "bottom"
+style-background-image-attlist &=
+  attribute style:filter-name { \string }?
+style-background-image-attlist &= attribute draw:opacity { percent }?
+style-paragraph-properties-attlist &= common-border-attlist
+common-border-attlist =
+  attribute fo:border { \string }?,
+  attribute fo:border-top { \string }?,
+  attribute fo:border-bottom { \string }?,
+  attribute fo:border-left { \string }?,
+  attribute fo:border-right { \string }?
+style-paragraph-properties-attlist &= common-border-line-width-attlist
+common-border-line-width-attlist =
+  attribute style:border-line-width { borderWidths }?,
+  attribute style:border-line-width-top { borderWidths }?,
+  attribute style:border-line-width-bottom { borderWidths }?,
+  attribute style:border-line-width-left { borderWidths }?,
+  attribute style:border-line-width-right { borderWidths }?
+borderWidths = list { positiveLength, positiveLength, positiveLength }
+style-paragraph-properties-attlist &= common-padding-attlist
+common-padding-attlist =
+  attribute fo:padding { nonNegativeLength }?,
+  attribute fo:padding-top { nonNegativeLength }?,
+  attribute fo:padding-bottom { nonNegativeLength }?,
+  attribute fo:padding-left { nonNegativeLength }?,
+  attribute fo:padding-right { nonNegativeLength }?
+style-paragraph-properties-attlist &= common-shadow-attlist
+common-shadow-attlist = attribute style:shadow { shadowType }?
+style-paragraph-properties-attlist &= common-keep-with-next-attlist
+common-keep-with-next-attlist =
+  attribute fo:keep-with-next { "auto" | "always" }?
+style-paragraph-properties-attlist &=
+  [ a:defaultValue = "false" ] attribute text:number-lines { boolean }?
+style-paragraph-properties-attlist &=
+  attribute text:line-number { nonNegativeInteger }?
+style-paragraph-properties-attlist &=
+  attribute style:text-autospace { "none" | "ideograph-alpha" }?
+style-paragraph-properties-attlist &=
+  attribute style:punctuation-wrap { "simple" | "hanging" }?
+style-paragraph-properties-attlist &=
+  attribute style:line-break { "normal" | "strict" }?
+style-paragraph-properties-attlist &=
+  [ a:defaultValue = "auto" ]
+  attribute style:vertical-align {
+    "top" | "middle" | "bottom" | "auto" | "baseline"
+  }?
+style-paragraph-properties-attlist &= common-writing-mode-attlist
+common-writing-mode-attlist =
+  attribute style:writing-mode {
+    "lr-tb" | "rl-tb" | "tb-rl" | "tb-lr" | "lr" | "rl" | "tb" | "page"
+  }?
+style-paragraph-properties-attlist &=
+  attribute style:writing-mode-automatic { boolean }?
+style-paragraph-properties-attlist &=
+  attribute style:snap-to-layout-grid { boolean }?
+style-paragraph-properties-attlist &= common-page-number-attlist
+common-page-number-attlist =
+  attribute style:page-number { positiveInteger | "auto" }?
+style-paragraph-properties-attlist &=
+  attribute style:background-transparency { percent }?
+style-ruby-properties =
+  element style:ruby-properties { style-ruby-properties-content }
+style-ruby-properties-content = style-properties-content
+style-ruby-properties-content-strict =
+  style-ruby-properties-attlist, style-ruby-properties-elements
+style-ruby-properties-elements = empty
+style-ruby-properties-attlist &=
+  attribute style:ruby-position { "above" | "below" }?
+style-ruby-properties-attlist &=
+  attribute style:ruby-align {
+    "left"
+    | "center"
+    | "right"
+    | "distribute-letter"
+    | "distribute-space"
+  }?
+style-section-properties =
+  element style:section-properties { style-section-properties-content }
+style-section-properties-content = style-properties-content
+style-section-properties-content-strict =
+  style-section-properties-attlist, style-section-properties-elements
+style-section-properties-attlist &= common-background-color-attlist
+style-section-properties-elements &= style-background-image
+style-section-properties-attlist &= common-horizontal-margin-attlist
+style-section-properties-elements &= style-columns
+style-columns =
+  element style:columns {
+    style-columns-attlist, style-column-sep?, style-column*
+  }?
+style-columns-attlist &= attribute fo:column-count { positiveInteger }
+style-columns-attlist &= attribute fo:column-gap { length }?
+style-column = element style:column { style-column-attlist }
+style-column-attlist &= attribute style:rel-width { relativeLength }
+style-column-attlist &=
+  [ a:defaultValue = "0cm" ] attribute fo:start-indent { length }?
+style-column-attlist &=
+  [ a:defaultValue = "0cm" ] attribute fo:end-indent { length }?
+style-column-attlist &=
+  [ a:defaultValue = "0cm" ] attribute fo:space-before { length }?
+style-column-attlist &=
+  [ a:defaultValue = "0cm" ] attribute fo:space-after { length }?
+style-column-sep = element style:column-sep { style-column-sep-attlist }
+style-column-sep-attlist &=
+  [ a:defaultValue = "solid" ]
+  attribute style:style {
+    "none" | "solid" | "dotted" | "dashed" | "dot-dashed"
+  }?
+style-column-sep-attlist &= attribute style:width { length }
+style-column-sep-attlist &=
+  [ a:defaultValue = "100%" ] attribute style:height { percent }?
+style-column-sep-attlist &=
+  [ a:defaultValue = "top" ]
+  attribute style:vertical-align { "top" | "middle" | "bottom" }?
+style-column-sep-attlist &=
+  [ a:defaultValue = "#000000" ] attribute style:color { color }?
+style-section-properties-attlist &=
+  [ a:defaultValue = "false" ] attribute style:protect { boolean }?
+style-section-properties-attlist &=
+  attribute text:dont-balance-text-columns { boolean }?
+style-section-properties-attlist &= common-writing-mode-attlist
+style-section-properties-elements &= text-notes-configuration*
+style-table-properties =
+  element style:table-properties { style-table-properties-content }
+style-table-properties-content = style-properties-content
+style-table-properties-content-strict =
+  style-table-properties-attlist, style-table-properties-elements
+style-table-properties-attlist &=
+  attribute style:width { positiveLength }?,
+  attribute style:rel-width { percent }?
+style-table-properties-attlist &=
+  attribute table:align { "left" | "center" | "right" | "margins" }?
+style-table-properties-attlist &= common-horizontal-margin-attlist
+style-table-properties-attlist &= common-vertical-margin-attlist
+style-table-properties-attlist &= common-margin-attlist
+style-table-properties-attlist &= common-page-number-attlist
+style-table-properties-attlist &= common-break-attlist
+style-table-properties-attlist &= common-background-color-attlist
+style-table-properties-elements &= style-background-image
+style-table-properties-attlist &= common-shadow-attlist
+style-table-properties-attlist &= common-keep-with-next-attlist
+style-table-properties-attlist &=
+  attribute style:may-break-between-rows { boolean }?
+style-table-properties-attlist &=
+  attribute table:border-model { "collapsing" | "separating" }?
+style-table-properties-attlist &= common-writing-mode-attlist
+style-table-properties-attlist &= attribute table:display { boolean }?
+style-table-column-properties =
+  element style:table-column-properties {
+    style-table-column-properties-content
+  }
+style-table-column-properties-content = style-properties-content
+style-table-column-properties-content-strict =
+  style-table-column-properties-attlist,
+  style-table-column-properties-elements
+style-table-column-properties-elements = empty
+style-table-column-properties-attlist &=
+  attribute style:column-width { positiveLength }?,
+  attribute style:rel-column-width { relativeLength }?
+style-table-column-properties-attlist &=
+  attribute style:use-optimal-column-width { boolean }?
+style-table-column-properties-attlist &= common-break-attlist
+style-table-row-properties =
+  element style:table-row-properties {
+    style-table-row-properties-content
+  }
+style-table-row-properties-content = style-properties-content
+style-table-row-properties-content-strict =
+  style-table-row-properties-attlist,
+  style-table-row-properties-elements
+style-table-row-properties-attlist &=
+  attribute style:row-height { positiveLength }?,
+  attribute style:min-row-height { nonNegativeLength }?
+style-table-row-properties-attlist &=
+  attribute style:use-optimal-row-height { boolean }?
+style-table-row-properties-attlist &= common-background-color-attlist
+style-table-row-properties-elements &= style-background-image
+style-table-row-properties-attlist &= common-break-attlist
+style-table-row-properties-attlist &=
+  attribute fo:keep-together { "auto" | "always" }?
+style-table-cell-properties =
+  element style:table-cell-properties {
+    style-table-cell-properties-content
+  }
+style-table-cell-properties-content = style-properties-content
+style-table-cell-properties-content-strict =
+  style-table-cell-properties-attlist,
+  style-table-cell-properties-elements
+style-table-cell-properties-attlist &=
+  attribute style:vertical-align {
+    "top" | "middle" | "bottom" | "automatic"
+  }?
+style-table-cell-properties-attlist &=
+  attribute style:text-align-source { "fix" | "value-type" }?
+style-table-cell-properties-attlist &= common-style-direction-attlist
+common-style-direction-attlist =
+  attribute style:direction { "ltr" | "ttb" }?
+style-table-cell-properties-attlist &=
+  attribute style:glyph-orientation-vertical { "auto" | "0" }?
+style-table-cell-properties-attlist &= common-shadow-attlist
+style-table-cell-properties-attlist &= common-background-color-attlist
+style-table-cell-properties-elements &= style-background-image
+style-table-cell-properties-attlist &= common-border-attlist
+style-table-cell-properties-attlist &=
+  attribute style:diagonal-tl-br { \string }?,
+  attribute style:diagonal-tl-br-widths { borderWidths }?,
+  attribute style:diagonal-bl-tr { \string }?,
+  attribute style:diagonal-bl-tr-widths { borderWidths }?
+style-table-cell-properties-attlist &= common-border-line-width-attlist
+style-table-cell-properties-attlist &= common-padding-attlist
+style-table-cell-properties-attlist &=
+  attribute fo:wrap-option { "no-wrap" | "wrap" }?
+style-table-cell-properties-attlist &= common-rotation-angle-attlist
+common-rotation-angle-attlist =
+  attribute style:rotation-angle { nonNegativeInteger }?
+style-table-cell-properties-attlist &=
+  attribute style:rotation-align {
+    "none" | "bottom" | "top" | "center"
+  }?
+style-table-cell-properties-attlist &=
+  attribute style:cell-protect {
+    "none"
+    | "hidden-and-protected"
+    | list { ("protected" | "formula-hidden")+ }
+  }?
+style-table-cell-properties-attlist &=
+  attribute style:print-content { boolean }?
+style-table-cell-properties-attlist &=
+  attribute style:decimal-places { nonNegativeInteger }?
+style-table-cell-properties-attlist &=
+  attribute style:repeat-content { boolean }?
+style-table-cell-properties-attlist &=
+  attribute style:shrink-to-fit { boolean }?
+style-list-level-properties =
+  element style:list-level-properties {
+    style-list-level-properties-content
+  }
+style-list-level-properties-content = style-properties-content
+style-list-level-properties-content-strict =
+  style-list-level-properties-attlist,
+  style-list-level-properties-elements
+style-list-level-properties-elements = empty
+style-list-level-properties-attlist &= common-text-align
+style-list-level-properties-attlist &=
+  attribute text:space-before { nonNegativeLength }?
+style-list-level-properties-attlist &=
+  attribute text:min-label-width { nonNegativeLength }?
+style-list-level-properties-attlist &=
+  attribute text:min-label-distance { nonNegativeLength }?
+style-list-level-properties-attlist &=
+  attribute style:font-name { \string }?
+style-list-level-properties-attlist &=
+  attribute fo:width { positiveLength }?,
+  attribute fo:height { positiveLength }?
+style-list-level-properties-attlist &=
+  common-vertical-rel-attlist, common-vertical-pos-attlist
+style-graphic-properties-attlist &=
+  attribute draw:stroke { "none" | "dash" | "solid" }?
+style-graphic-properties-attlist &=
+  attribute draw:stroke-dash { styleNameRef }?
+style-graphic-properties-attlist &=
+  attribute draw:stroke-dash-names { styleNameRefs }?
+style-graphic-properties-attlist &=
+  attribute svg:stroke-width { length }?
+style-graphic-properties-attlist &=
+  attribute svg:stroke-color { color }?
+style-graphic-properties-attlist &=
+  attribute draw:marker-start { styleNameRef }?
+style-graphic-properties-attlist &=
+  attribute draw:marker-end { styleNameRef }?
+style-graphic-properties-attlist &=
+  attribute draw:marker-start-width { length }?
+style-graphic-properties-attlist &=
+  attribute draw:marker-end-width { length }?
+style-graphic-properties-attlist &=
+  attribute draw:marker-start-center { boolean }?
+style-graphic-properties-attlist &=
+  attribute draw:marker-end-center { boolean }?
+style-graphic-properties-attlist &=
+  attribute svg:stroke-opacity {
+    xsd:double { minInclusive = "0" maxInclusive = "1" }
+    | percent
+  }?
+style-graphic-properties-attlist &=
+  attribute draw:stroke-linejoin {
+    "miter" | "round" | "bevel" | "middle" | "none" | "inherit"
+  }?
+style-graphic-fill-properties-attlist &=
+  attribute draw:fill {
+    "none" | "solid" | "bitmap" | "gradient" | "hatch"
+  }?
+style-graphic-fill-properties-attlist &=
+  attribute draw:fill-color { color }?
+style-graphic-fill-properties-attlist &=
+  attribute draw:secondary-fill-color { color }?
+style-graphic-fill-properties-attlist &=
+  attribute draw:fill-gradient-name { styleNameRef }?
+style-graphic-fill-properties-attlist &=
+  attribute draw:gradient-step-count { nonNegativeInteger }?
+style-graphic-fill-properties-attlist &=
+  attribute draw:fill-hatch-name { styleNameRef }?
+style-graphic-fill-properties-attlist &=
+  attribute draw:fill-hatch-solid { boolean }?
+style-graphic-fill-properties-attlist &=
+  attribute draw:fill-image-name { styleNameRef }?
+style-graphic-fill-properties-attlist &=
+  attribute style:repeat { "no-repeat" | "repeat" | "stretch" }?
+style-graphic-fill-properties-attlist &=
+  attribute draw:fill-image-width { length | percent }?,
+  attribute draw:fill-image-height { length | percent }?
+style-graphic-fill-properties-attlist &=
+  attribute draw:fill-image-ref-point-x { percent }?,
+  attribute draw:fill-image-ref-point-y { percent }?,
+  attribute draw:fill-image-ref-point {
+    "top-left"
+    | "top"
+    | "top-right"
+    | "left"
+    | "center"
+    | "right"
+    | "bottom-left"
+    | "bottom"
+    | "bottom-right"
+  }?
+style-graphic-fill-properties-attlist &=
+  attribute draw:tile-repeat-offset { text }?
+style-graphic-fill-properties-attlist &=
+  attribute draw:opacity { percent }?
+style-graphic-fill-properties-attlist &=
+  attribute draw:opacity-name { styleNameRef }?
+style-graphic-fill-properties-attlist &=
+  attribute svg:fill-rule { "nonzero" | "evenodd" }?
+style-graphic-properties-attlist &=
+  attribute draw:symbol-color { color }?
+style-graphic-properties-attlist &=
+  attribute text:animation {
+    "none" | "scroll" | "alternate" | "slide"
+  }?
+style-graphic-properties-attlist &=
+  attribute text:animation-direction {
+    "left" | "right" | "up" | "down"
+  }?
+style-graphic-properties-attlist &=
+  attribute text:animation-start-inside { boolean }?
+style-graphic-properties-attlist &=
+  attribute text:animation-stop-inside { boolean }?
+style-graphic-properties-attlist &=
+  attribute text:animation-repeat { nonNegativeInteger }?
+style-graphic-properties-attlist &=
+  attribute text:animation-delay { duration }?
+style-graphic-properties-attlist &=
+  attribute text:animation-steps { length }?
+style-graphic-properties-attlist &=
+  attribute draw:auto-grow-width { boolean }?,
+  attribute draw:auto-grow-height { boolean }?
+style-graphic-properties-attlist &=
+  attribute draw:fit-to-size { boolean }?
+style-graphic-properties-attlist &=
+  attribute draw:fit-to-contour { boolean }?
+style-graphic-properties-attlist &=
+  attribute draw:textarea-vertical-align {
+    "top" | "middle" | "bottom" | "justify"
+  }?
+style-graphic-properties-attlist &=
+  attribute draw:textarea-horizontal-align {
+    "left" | "center" | "right" | "justify"
+  }?
+style-graphic-properties-attlist &=
+  attribute fo:wrap-option { "no-wrap" | "wrap" }?
+style-graphic-properties-elements &= text-list-style?
+style-graphic-properties-attlist &=
+  attribute draw:color-mode {
+    "greyscale" | "mono" | "watermark" | "standard"
+  }?
+style-graphic-properties-attlist &=
+  attribute draw:color-inversion { boolean }?
+style-graphic-properties-attlist &=
+  attribute draw:luminance { percent }?
+style-graphic-properties-attlist &= attribute draw:contrast { percent }?
+style-graphic-properties-attlist &= attribute draw:gamma { percent }?
+style-graphic-properties-attlist &= attribute draw:red { percent }?
+style-graphic-properties-attlist &= attribute draw:green { percent }?
+style-graphic-properties-attlist &= attribute draw:blue { percent }?
+style-graphic-properties-attlist &=
+  attribute draw:image-opacity { percent }?
+style-graphic-properties-attlist &=
+  attribute draw:shadow { "visible" | "hidden" }?
+style-graphic-properties-attlist &=
+  attribute draw:shadow-offset-x { length }?,
+  attribute draw:shadow-offset-y { length }?
+style-graphic-properties-attlist &=
+  attribute draw:shadow-color { color }?
+style-graphic-properties-attlist &=
+  attribute draw:shadow-opacity { percent }?
+style-graphic-properties-attlist &=
+  attribute draw:start-line-spacing-horizontal { distance }?,
+  attribute draw:start-line-spacing-vertical { distance }?
+style-graphic-properties-attlist &=
+  attribute draw:end-line-spacing-horizontal { distance }?,
+  attribute draw:end-line-spacing-vertical { distance }?
+style-graphic-properties-attlist &=
+  attribute draw:line-distance { distance }?
+style-graphic-properties-attlist &=
+  attribute draw:guide-overhang { length }?
+style-graphic-properties-attlist &=
+  attribute draw:guide-distance { distance }?
+style-graphic-properties-attlist &=
+  attribute draw:start-guide { length }?
+style-graphic-properties-attlist &= attribute draw:end-guide { length }?
+style-graphic-properties-attlist &=
+  attribute draw:placing { "below" | "above" }?
+style-graphic-properties-attlist &= attribute draw:parallel { boolean }?
+style-graphic-properties-attlist &=
+  attribute draw:measure-align {
+    "automatic" | "left-outside" | "inside" | "right-outside"
+  }?,
+  attribute draw:measure-vertical-align {
+    "automatic" | "above" | "below" | "center"
+  }?
+style-graphic-properties-attlist &=
+  attribute draw:unit {
+    "automatic"
+    | "mm"
+    | "cm"
+    | "m"
+    | "km"
+    | "pt"
+    | "pc"
+    | "inch"
+    | "ft"
+    | "mi"
+  }?
+style-graphic-properties-attlist &=
+  attribute draw:show-unit { boolean }?
+style-graphic-properties-attlist &=
+  attribute draw:decimal-places { nonNegativeInteger }?
+style-graphic-properties-attlist &=
+  attribute draw:caption-type {
+    "straight-line" | "angled-line" | "angled-connector-line"
+  }?
+style-graphic-properties-attlist &=
+  attribute draw:caption-angle-type { "fixed" | "free" }?
+style-graphic-properties-attlist &=
+  attribute draw:caption-angle { nonNegativeInteger }?
+style-graphic-properties-attlist &=
+  attribute draw:caption-gap { distance }?
+style-graphic-properties-attlist &=
+  attribute draw:caption-escape-direction {
+    "horizontal" | "vertical" | "auto"
+  }?
+style-graphic-properties-attlist &=
+  attribute draw:caption-escape { length | percent }?
+style-graphic-properties-attlist &=
+  attribute draw:caption-line-length { length }?
+style-graphic-properties-attlist &=
+  attribute draw:caption-fit-line-length { boolean }?
+style-graphic-properties-attlist &=
+  attribute dr3d:horizontal-segments { nonNegativeInteger }?
+style-graphic-properties-attlist &=
+  attribute dr3d:vertical-segments { nonNegativeInteger }?
+style-graphic-properties-attlist &=
+  attribute dr3d:edge-rounding { percent }?
+style-graphic-properties-attlist &=
+  attribute dr3d:edge-rounding-mode { "correct" | "attractive" }?
+style-graphic-properties-attlist &=
+  attribute dr3d:back-scale { percent }?
+style-graphic-properties-attlist &= attribute dr3d:depth { length }?
+style-graphic-properties-attlist &=
+  attribute dr3d:backface-culling { "enabled" | "disabled" }?
+style-graphic-properties-attlist &=
+  attribute dr3d:end-angle { nonNegativeInteger }?
+style-graphic-properties-attlist &=
+  attribute dr3d:close-front { boolean }?
+style-graphic-properties-attlist &=
+  attribute dr3d:close-back { boolean }?
+style-graphic-properties-attlist &=
+  attribute dr3d:lighting-mode { "standard" | "double-sided" }?
+style-graphic-properties-attlist &=
+  attribute dr3d:normals-kind { "object" | "flat" | "sphere" }?
+style-graphic-properties-attlist &=
+  attribute dr3d:normals-direction { "normal" | "inverse" }?
+style-graphic-properties-attlist &=
+  attribute dr3d:texture-generation-mode-x {
+    "object" | "parallel" | "sphere"
+  }?,
+  attribute dr3d:texture-generation-mode-y {
+    "object" | "parallel" | "sphere"
+  }?
+style-graphic-properties-attlist &=
+  attribute dr3d:texture-kind { "luminance" | "intensity" | "color" }?
+style-graphic-properties-attlist &=
+  attribute dr3d:texture-filter { "enabled" | "disabled" }?
+style-graphic-properties-attlist &=
+  attribute dr3d:texture-mode { "replace" | "modulate" | "blend" }?
+style-graphic-properties-attlist &=
+  attribute dr3d:ambient-color { color }?,
+  attribute dr3d:emissive-color { color }?,
+  attribute dr3d:specular-color { color }?,
+  attribute dr3d:diffuse-color { color }?
+style-graphic-properties-attlist &=
+  attribute dr3d:shininess { percent }?
+style-graphic-properties-attlist &=
+  attribute dr3d:shadow { "visible" | "hidden" }?
+style-graphic-properties-attlist &=
+  common-draw-rel-size-attlist,
+  attribute fo:min-width { length | percent }?
+style-graphic-properties-attlist &=
+  attribute fo:min-height { length | percent }?
+style-graphic-properties-attlist &=
+  attribute fo:max-height { length | percent }?,
+  attribute fo:max-width { length | percent }?
+style-graphic-properties-attlist &= common-horizontal-margin-attlist
+style-graphic-properties-attlist &= common-vertical-margin-attlist
+style-graphic-properties-attlist &= common-margin-attlist
+style-graphic-properties-attlist &=
+  attribute style:print-content { boolean }?
+style-graphic-properties-attlist &=
+  attribute style:protect {
+    "none"
+    | list { ("content" | "position" | "size")+ }
+  }?
+style-graphic-properties-attlist &=
+  attribute style:horizontal-pos {
+    "left"
+    | "center"
+    | "right"
+    | "from-left"
+    | "inside"
+    | "outside"
+    | "from-inside"
+  }?,
+  attribute svg:x { coordinate }?
+style-graphic-properties-attlist &=
+  attribute style:horizontal-rel {
+    "page"
+    | "page-content"
+    | "page-start-margin"
+    | "page-end-margin"
+    | "frame"
+    | "frame-content"
+    | "frame-start-margin"
+    | "frame-end-margin"
+    | "paragraph"
+    | "paragraph-content"
+    | "paragraph-start-margin"
+    | "paragraph-end-margin"
+    | "char"
+  }?
+style-graphic-properties-attlist &= common-vertical-pos-attlist
+common-vertical-pos-attlist =
+  attribute style:vertical-pos {
+    "top" | "middle" | "bottom" | "from-top" | "below"
+  }?,
+  attribute svg:y { coordinate }?
+style-graphic-properties-attlist &= common-vertical-rel-attlist
+common-vertical-rel-attlist =
+  attribute style:vertical-rel {
+    "page"
+    | "page-content"
+    | "frame"
+    | "frame-content"
+    | "paragraph"
+    | "paragraph-content"
+    | "char"
+    | "line"
+    | "baseline"
+    | "text"
+  }?
+style-graphic-properties-attlist &= common-text-anchor-attlist
+style-graphic-properties-attlist &= common-border-attlist
+style-graphic-properties-attlist &= common-border-line-width-attlist
+style-graphic-properties-attlist &= common-padding-attlist
+style-graphic-properties-attlist &= common-shadow-attlist
+style-graphic-properties-attlist &= common-background-color-attlist
+style-graphic-properties-elements &= style-background-image
+style-graphic-properties-elements &= style-columns
+style-graphic-properties-attlist &=
+  attribute style:editable { boolean }?
+style-graphic-properties-attlist &=
+  attribute style:wrap {
+    "none"
+    | "left"
+    | "right"
+    | "parallel"
+    | "dynamic"
+    | "run-through"
+    | "biggest"
+  }?
+style-graphic-properties-attlist &=
+  attribute style:wrap-dynamic-threshold { nonNegativeLength }?
+style-graphic-properties-attlist &=
+  attribute style:number-wrapped-paragraphs {
+    "no-limit" | positiveInteger
+  }?
+style-graphic-properties-attlist &=
+  attribute style:wrap-contour { boolean }?
+style-graphic-properties-attlist &=
+  attribute style:wrap-contour-mode { "full" | "outside" }?
+style-graphic-properties-attlist &=
+  attribute style:run-through { "foreground" | "background" }?
+style-graphic-properties-attlist &=
+  attribute style:flow-with-text { boolean }?
+style-graphic-properties-attlist &=
+  attribute style:overflow-behavior {
+    "clip" | "auto-create-new-frame"
+  }?
+style-graphic-properties-attlist &=
+  attribute style:mirror {
+    "none"
+    | "vertical"
+    | horizontal-mirror
+    | list { "vertical", horizontal-mirror }
+    | list { horizontal-mirror, "vertical" }
+  }?
+horizontal-mirror =
+  "horizontal" | "horizontal-on-odd" | "horizontal-on-even"
+style-graphic-properties-attlist &=
+  attribute fo:clip {
+    # The attribute value must match the one XSL's clip
+    \string
+  }?
+style-graphic-properties-attlist &=
+  [ a:defaultValue = "iterative" ]
+  attribute draw:wrap-influence-on-position {
+    "iterative" | "once-concurrent" | "once-successive"
+  }?
+style-graphic-properties-attlist &= common-writing-mode-attlist
+style-graphic-properties-attlist &=
+  attribute draw:frame-display-scrollbar { boolean }?
+style-graphic-properties-attlist &=
+  attribute draw:frame-display-border { boolean }?
+style-graphic-properties-attlist &=
+  attribute draw:frame-margin-horizontal { nonNegativePixelLength }?,
+  attribute draw:frame-margin-vertical { nonNegativePixelLength }?
+nonNegativePixelLength =
+  xsd:string { pattern = "([0-9]+(\.[0-9]*)?|\.[0-9]+)(px)" }
+style-graphic-properties-attlist &=
+  attribute draw:visible-area-left { nonNegativeLength }?,
+  attribute draw:visible-area-top { nonNegativeLength }?,
+  attribute draw:visible-area-width { positiveLength }?,
+  attribute draw:visible-area-height { positiveLength }?
+style-graphic-properties-attlist &=
+  attribute draw:ole-draw-aspect { nonNegativeInteger }?
+style-chart-properties =
+  element style:chart-properties { style-chart-properties-content }
+style-chart-properties-content = style-properties-content
+style-chart-properties-content-strict =
+  style-chart-properties-attlist, style-chart-properties-elements
+style-chart-properties-elements = empty
+style-chart-properties-attlist &=
+  [ a:defaultValue = "true" ] attribute chart:scale-text { boolean }?
+style-chart-properties-attlist &=
+  attribute chart:three-dimensional { boolean }?
+style-chart-properties-attlist &= attribute chart:deep { boolean }?
+style-chart-properties-attlist &=
+  attribute chart:symbol-type { "none" }
+  | attribute chart:symbol-type { "automatic" }
+  | (attribute chart:symbol-type { "named-symbol" },
+     attribute chart:symbol-name {
+       "square"
+       | "diamond"
+       | "arrow-down"
+       | "arrow-up"
+       | "arrow-right"
+       | "arrow-left"
+       | "bow-tie"
+       | "hourglass"
+       | "circle"
+       | "star"
+       | "x"
+       | "plus"
+       | "asterisk"
+       | "horizontal-bar"
+       | "vertical-bar"
+     })
+  | (attribute chart:symbol-type { "image" },
+     element chart:symbol-image {
+       attribute xlink:href { anyURI }
+     })
+  | empty
+style-chart-properties-attlist &=
+  attribute chart:symbol-width { nonNegativeLength }?,
+  attribute chart:symbol-height { nonNegativeLength }?
+style-chart-properties-attlist &=
+  [ a:defaultValue = "false" ] attribute chart:vertical { boolean }?
+style-chart-properties-attlist &=
+  [ a:defaultValue = "false" ] attribute chart:connect-bars { boolean }?
+style-chart-properties-attlist &=
+  attribute chart:gap-width { integer }?,
+  attribute chart:overlap { integer }?
+style-chart-properties-attlist &=
+  [ a:defaultValue = "false" ]
+  attribute chart:japanese-candle-stick { boolean }?
+style-chart-properties-attlist &=
+  [ a:defaultValue = "none" ]
+  attribute chart:interpolation {
+    "none" | "cubic-spline" | "b-spline"
+  }?,
+  [ a:defaultValue = "2" ]
+  attribute chart:spline-order { positiveInteger }?,
+  [ a:defaultValue = "20" ]
+  attribute chart:spline-resolution { positiveInteger }?
+style-chart-properties-attlist &=
+  [ a:defaultValue = "0" ]
+  attribute chart:pie-offset { nonNegativeInteger }?
+style-chart-properties-attlist &=
+  [ a:defaultValue = "false" ] attribute chart:lines { boolean }?
+style-chart-properties-attlist &=
+  [ a:defaultValue = "cuboid" ]
+  attribute chart:solid-type {
+    "cuboid" | "cylinder" | "cone" | "pyramid"
+  }?
+style-chart-properties-attlist &=
+  [ a:defaultValue = "false" ] attribute chart:stacked { boolean }?,
+  [ a:defaultValue = "false" ] attribute chart:percentage { boolean }?
+style-chart-properties-attlist &=
+  attribute chart:link-data-style-to-source { boolean }?
+style-chart-properties-attlist &= attribute chart:visible { boolean }?
+style-chart-properties-attlist &=
+  attribute chart:logarithmic { boolean }?
+style-chart-properties-attlist &=
+  attribute chart:maximum { double }?,
+  attribute chart:minimum { double }?,
+  attribute chart:origin { double }?,
+  attribute chart:interval-major { double }?,
+  attribute chart:interval-minor-divisor { positiveInteger }?
+style-chart-properties-attlist &=
+  attribute chart:tick-marks-major-inner { boolean }?,
+  attribute chart:tick-marks-major-outer { boolean }?,
+  attribute chart:tick-marks-minor-inner { boolean }?,
+  attribute chart:tick-marks-minor-outer { boolean }?
+style-chart-properties-attlist &=
+  attribute chart:display-label { boolean }?,
+  attribute chart:text-overlap { boolean }?,
+  attribute text:line-break { boolean }?,
+  [ a:defaultValue = "side-by-side" ]
+  attribute chart:label-arrangement {
+    "side-by-side" | "stagger-even" | "stagger-odd"
+  }?
+style-chart-properties-attlist &= common-style-direction-attlist
+style-chart-properties-attlist &= common-rotation-angle-attlist
+style-chart-properties-attlist &=
+  attribute chart:data-label-number { "none" | "value" | "percentage" }?
+style-chart-properties-attlist &=
+  attribute chart:data-label-text { boolean }?
+style-chart-properties-attlist &=
+  attribute chart:data-label-symbol { boolean }?
+style-chart-properties-attlist &=
+  attribute chart:mean-value { boolean }?
+style-chart-properties-attlist &=
+  [ a:defaultValue = "none" ]
+  attribute chart:error-category {
+    "none"
+    | "variance"
+    | "standard-deviation"
+    | "percentage"
+    | "error-margin"
+    | "constant"
+  }?
+style-chart-properties-attlist &=
+  attribute chart:error-percentage { double }?
+style-chart-properties-attlist &=
+  attribute chart:error-margin { double }?
+style-chart-properties-attlist &=
+  attribute chart:error-lower-limit { double }?,
+  attribute chart:error-upper-limit { double }?
+style-chart-properties-attlist &=
+  attribute chart:error-upper-indicator { boolean }?,
+  attribute chart:error-lower-indicator { boolean }?
+style-chart-properties-attlist &=
+  [ a:defaultValue = "columns" ]
+  attribute chart:series-source { "columns" | "rows" }?
+style-chart-properties-attlist &=
+  [ a:defaultValue = "none" ]
+  attribute chart:regression-type {
+    "none" | "linear" | "logarithmic" | "exponential" | "power"
+  }?
+style-drawing-page-properties-attlist &=
+  attribute presentation:transition-type {
+    "manual" | "automatic" | "semi-automatic"
+  }?
+style-drawing-page-properties-attlist &=
+  attribute presentation:transition-style {
+    "none"
+    | "fade-from-left"
+    | "fade-from-top"
+    | "fade-from-right"
+    | "fade-from-bottom"
+    | "fade-from-upperleft"
+    | "fade-from-upperright"
+    | "fade-from-lowerleft"
+    | "fade-from-lowerright"
+    | "move-from-left"
+    | "move-from-top"
+    | "move-from-right"
+    | "move-from-bottom"
+    | "move-from-upperleft"
+    | "move-from-upperright"
+    | "move-from-lowerleft"
+    | "move-from-lowerright"
+    | "uncover-to-left"
+    | "uncover-to-top"
+    | "uncover-to-right"
+    | "uncover-to-bottom"
+    | "uncover-to-upperleft"
+    | "uncover-to-upperright"
+    | "uncover-to-lowerleft"
+    | "uncover-to-lowerright"
+    | "fade-to-center"
+    | "fade-from-center"
+    | "vertical-stripes"
+    | "horizontal-stripes"
+    | "clockwise"
+    | "counterclockwise"
+    | "open-vertical"
+    | "open-horizontal"
+    | "close-vertical"
+    | "close-horizontal"
+    | "wavyline-from-left"
+    | "wavyline-from-top"
+    | "wavyline-from-right"
+    | "wavyline-from-bottom"
+    | "spiralin-left"
+    | "spiralin-right"
+    | "spiralout-left"
+    | "spiralout-right"
+    | "roll-from-top"
+    | "roll-from-left"
+    | "roll-from-right"
+    | "roll-from-bottom"
+    | "stretch-from-left"
+    | "stretch-from-top"
+    | "stretch-from-right"
+    | "stretch-from-bottom"
+    | "vertical-lines"
+    | "horizontal-lines"
+    | "dissolve"
+    | "random"
+    | "vertical-checkerboard"
+    | "horizontal-checkerboard"
+    | "interlocking-horizontal-left"
+    | "interlocking-horizontal-right"
+    | "interlocking-vertical-top"
+    | "interlocking-vertical-bottom"
+    | "fly-away"
+    | "open"
+    | "close"
+    | "melt"
+  }?
+style-drawing-page-properties-attlist &=
+  attribute presentation:transition-speed { presentationSpeeds }?
+style-drawing-page-properties-attlist &=
+  attribute smil:type { \string }?
+style-drawing-page-properties-attlist &=
+  attribute smil:subtype { \string }?
+style-drawing-page-properties-attlist &=
+  [ a:defaultValue = "forward" ]
+  attribute smil:direction { "forward" | "reverse" }?
+style-drawing-page-properties-attlist &=
+  attribute smil:fadeColor { color }?
+style-drawing-page-properties-attlist &=
+  attribute presentation:duration { duration }?
+style-drawing-page-properties-attlist &=
+  attribute presentation:visibility { "visible" | "hidden" }?
+style-drawing-page-properties-elements &= presentation-sound?
+style-drawing-page-properties-attlist &=
+  attribute draw:background-size { "full" | "border" }?
+style-drawing-page-properties-attlist &=
+  attribute presentation:background-objects-visible { boolean }?
+style-drawing-page-properties-attlist &=
+  attribute presentation:background-visible { boolean }?
+style-drawing-page-properties-attlist &=
+  attribute presentation:display-header { boolean }?
+style-drawing-page-properties-attlist &=
+  attribute presentation:display-footer { boolean }?
+style-drawing-page-properties-attlist &=
+  attribute presentation:display-page-number { boolean }?
+style-drawing-page-properties-attlist &=
+  attribute presentation:display-date-time { boolean }?
+\string = xsd:string
+date = xsd:date
+time = xsd:time
+dateTime = xsd:dateTime
+duration = xsd:duration
+integer = xsd:integer
+nonNegativeInteger = xsd:nonNegativeInteger
+positiveInteger = xsd:positiveInteger
+double = xsd:double
+anyURI = xsd:anyURI
+base64Binary = xsd:base64Binary
+ID = xsd:ID
+IDREF = xsd:IDREF
+IDREFS = xsd:IDREFS
+boolean = "true" | "false"
+dateOrDateTime = xsd:date | xsd:dateTime
+timeOrDateTime = xsd:time | xsd:dateTime
+language = xsd:language
+countryCode = xsd:token { pattern = "[A-Za-z0-9]{1,8}" }
+languageCode = xsd:token { pattern = "[A-Za-z]{1,8}" }
+character = xsd:string { length = "1" }
+length =
+  xsd:string {
+    pattern =
+      "-?([0-9]+(\.[0-9]*)?|\.[0-9]+)((cm)|(mm)|(in)|(pt)|(pc)|(px))"
+  }
+nonNegativeLength =
+  xsd:string {
+    pattern =
+      "([0-9]+(\.[0-9]*)?|\.[0-9]+)((cm)|(mm)|(in)|(pt)|(pc)|(px))"
+  }
+positiveLength =
+  xsd:string {
+    pattern =
+      "([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))"
+  }
+percent = xsd:string { pattern = "-?([0-9]+(\.[0-9]*)?|\.[0-9]+)%" }
+relativeLength = xsd:string { pattern = "[0-9]+\*" }
+coordinate = length
+distance = length
+color = xsd:string { pattern = "#[0-9a-fA-F]{6}" }
+styleName = xsd:NCName
+styleNameRef = xsd:NCName | empty
+styleNameRefs = list { xsd:NCName* }
+variableName = xsd:string
+formula =
+  # A formula should start with a namespace prefix,
+  
+  #  but has no restrictions
+  xsd:string
+targetFrameName = "_self" | "_blank" | "_parent" | "_top" | \string
+valueType =
+  "float"
+  | "time"
+  | "date"
+  | "percentage"
+  | "currency"
+  | "boolean"
+  | "string"
+points =
+  xsd:string { pattern = "-?[0-9]+,-?[0-9]+([ ]+-?[0-9]+,-?[0-9]+)*" }
+pathData = xsd:string
+vector3D =
+  xsd:string {
+    pattern =
+      "\([ ]*-?([0-9]+(\.[0-9]*)?|\.[0-9]+)([ ]+-?([0-9]+(\.[0-9]*)?|\.[0-9]+)){2}[ ]*\)"
+  }
+namespacedToken =
+  xsd:string { pattern = "[0-9a-zA-Z_]+:[0-9a-zA-Z._\-]+" }
+anyAttListOrElements =
+  attribute * { text }*,
+  anyElements
+anyElements =
+  element * {
+    mixed { anyAttListOrElements }
+  }*

+ 6280 - 0
contrib/odt/etc/schema/od-schema-v1.2-cs01.rnc

@@ -0,0 +1,6280 @@
+# Open Document Format for Office Applications (OpenDocument) Version 1.2
+# Committee Specification (CS) 01, 17 March 2011
+# Relax-NG Schema
+# 
+# Copyright (c) OASIS Open 2002-2011. All Rights Reserved.
+# 
+# All capitalized terms in the following text have the meanings assigned to them
+# in the OASIS Intellectual Property Rights Policy (the "OASIS IPR Policy"). The
+# full Policy may be found at the OASIS website.
+# 
+# This document and translations of it may be copied and furnished to others, and
+# derivative works that comment on or otherwise explain it or assist in its
+# implementation may be prepared, copied, published, and distributed, in whole or
+# in part, without restriction of any kind, provided that the above copyright
+# notice and this section are included on all such copies and derivative works.
+# However, this document itself may not be modified in any way, including by
+# removing the copyright notice or references to OASIS, except as needed for the
+# purpose of developing any document or deliverable produced by an OASIS
+# Technical Committee (in which case the rules applicable to copyrights, as set
+# forth in the OASIS IPR Policy, must be followed) or as required to translate it
+# into languages other than English.
+# 
+# The limited permissions granted above are perpetual and will not be revoked by
+# OASIS or its successors or assigns.
+# 
+# This document and the information contained herein is provided on an "AS IS"
+# basis and OASIS DISCLAIMS ALL WARRANTIES, EXPRESS OR IMPLIED, INCLUDING BUT NOT
+# LIMITED TO ANY WARRANTY THAT THE USE OF THE INFORMATION HEREIN WILL NOT
+# INFRINGE ANY OWNERSHIP RIGHTS OR ANY IMPLIED WARRANTIES OF MERCHANTABILITY OR
+# FITNESS FOR A PARTICULAR PURPOSE. 
+
+namespace anim = "urn:oasis:names:tc:opendocument:xmlns:animation:1.0"
+namespace chart = "urn:oasis:names:tc:opendocument:xmlns:chart:1.0"
+namespace config = "urn:oasis:names:tc:opendocument:xmlns:config:1.0"
+namespace db = "urn:oasis:names:tc:opendocument:xmlns:database:1.0"
+namespace dc = "http://purl.org/dc/elements/1.1/"
+namespace dr3d = "urn:oasis:names:tc:opendocument:xmlns:dr3d:1.0"
+namespace draw = "urn:oasis:names:tc:opendocument:xmlns:drawing:1.0"
+namespace fo =
+  "urn:oasis:names:tc:opendocument:xmlns:xsl-fo-compatible:1.0"
+namespace form = "urn:oasis:names:tc:opendocument:xmlns:form:1.0"
+namespace grddl = "http://www.w3.org/2003/g/data-view#"
+namespace math = "http://www.w3.org/1998/Math/MathML"
+namespace meta = "urn:oasis:names:tc:opendocument:xmlns:meta:1.0"
+namespace number = "urn:oasis:names:tc:opendocument:xmlns:datastyle:1.0"
+namespace office = "urn:oasis:names:tc:opendocument:xmlns:office:1.0"
+namespace presentation =
+  "urn:oasis:names:tc:opendocument:xmlns:presentation:1.0"
+namespace script = "urn:oasis:names:tc:opendocument:xmlns:script:1.0"
+namespace smil =
+  "urn:oasis:names:tc:opendocument:xmlns:smil-compatible:1.0"
+namespace style = "urn:oasis:names:tc:opendocument:xmlns:style:1.0"
+namespace svg =
+  "urn:oasis:names:tc:opendocument:xmlns:svg-compatible:1.0"
+namespace table = "urn:oasis:names:tc:opendocument:xmlns:table:1.0"
+namespace text = "urn:oasis:names:tc:opendocument:xmlns:text:1.0"
+namespace xforms = "http://www.w3.org/2002/xforms"
+namespace xhtml = "http://www.w3.org/1999/xhtml"
+namespace xlink = "http://www.w3.org/1999/xlink"
+
+office-process-content = attribute office:process-content { boolean }?
+start =
+  office-document
+  | office-document-content
+  | office-document-styles
+  | office-document-meta
+  | office-document-settings
+office-document =
+  element office:document {
+    office-document-attrs,
+    office-document-common-attrs,
+    office-meta,
+    office-settings,
+    office-scripts,
+    office-font-face-decls,
+    office-styles,
+    office-automatic-styles,
+    office-master-styles,
+    office-body
+  }
+office-document-content =
+  element office:document-content {
+    office-document-common-attrs,
+    office-scripts,
+    office-font-face-decls,
+    office-automatic-styles,
+    office-body
+  }
+office-document-styles =
+  element office:document-styles {
+    office-document-common-attrs,
+    office-font-face-decls,
+    office-styles,
+    office-automatic-styles,
+    office-master-styles
+  }
+office-document-meta =
+  element office:document-meta {
+    office-document-common-attrs, office-meta
+  }
+office-document-settings =
+  element office:document-settings {
+    office-document-common-attrs, office-settings
+  }
+office-document-common-attrs =
+  attribute office:version { "1.2" }
+  & attribute grddl:transformation {
+      list { anyIRI* }
+    }?
+office-document-attrs = attribute office:mimetype { \string }
+office-meta = element office:meta { office-meta-content-strict }?
+office-meta-content-strict = office-meta-data*
+office-body = element office:body { office-body-content }
+office-body-content =
+  element office:text {
+    office-text-attlist,
+    office-text-content-prelude,
+    office-text-content-main,
+    office-text-content-epilogue
+  }
+  | element office:drawing {
+      office-drawing-attlist,
+      office-drawing-content-prelude,
+      office-drawing-content-main,
+      office-drawing-content-epilogue
+    }
+  | element office:presentation {
+      office-presentation-attlist,
+      office-presentation-content-prelude,
+      office-presentation-content-main,
+      office-presentation-content-epilogue
+    }
+  | element office:spreadsheet {
+      office-spreadsheet-attlist,
+      office-spreadsheet-content-prelude,
+      office-spreadsheet-content-main,
+      office-spreadsheet-content-epilogue
+    }
+  | element office:chart {
+      office-chart-attlist,
+      office-chart-content-prelude,
+      office-chart-content-main,
+      office-chart-content-epilogue
+    }
+  | element office:image {
+      office-image-attlist,
+      office-image-content-prelude,
+      office-image-content-main,
+      office-image-content-epilogue
+    }
+  | office-database
+office-text-content-prelude =
+  office-forms, text-tracked-changes, text-decls, table-decls
+office-text-content-main =
+  text-content*
+  | (text-page-sequence, (shape)*)
+text-content =
+  text-h
+  | text-p
+  | text-list
+  | text-numbered-paragraph
+  | table-table
+  | text-section
+  | text-soft-page-break
+  | text-table-of-content
+  | text-illustration-index
+  | text-table-index
+  | text-object-index
+  | text-user-index
+  | text-alphabetical-index
+  | text-bibliography
+  | shape
+  | change-marks
+office-text-content-epilogue = table-functions
+office-text-attlist =
+  attribute text:global { boolean }?
+  & attribute text:use-soft-page-breaks { boolean }?
+office-drawing-attlist = empty
+office-drawing-content-prelude = text-decls, table-decls
+office-drawing-content-main = draw-page*
+office-drawing-content-epilogue = table-functions
+office-presentation-attlist = empty
+office-presentation-content-prelude =
+  text-decls, table-decls, presentation-decls
+office-presentation-content-main = draw-page*
+office-presentation-content-epilogue =
+  presentation-settings, table-functions
+office-spreadsheet-content-prelude =
+  table-tracked-changes?, text-decls, table-decls
+table-decls =
+  table-calculation-settings?,
+  table-content-validations?,
+  table-label-ranges?
+office-spreadsheet-content-main = table-table*
+office-spreadsheet-content-epilogue = table-functions
+table-functions =
+  table-named-expressions?,
+  table-database-ranges?,
+  table-data-pilot-tables?,
+  table-consolidation?,
+  table-dde-links?
+office-chart-attlist = empty
+office-chart-content-prelude = text-decls, table-decls
+office-chart-content-main = chart-chart
+office-chart-content-epilogue = table-functions
+office-image-attlist = empty
+office-image-content-prelude = empty
+office-image-content-main = draw-frame
+office-image-content-epilogue = empty
+office-settings = element office:settings { config-config-item-set+ }?
+config-config-item-set =
+  element config:config-item-set {
+    config-config-item-set-attlist, config-items
+  }
+config-items =
+  (config-config-item
+   | config-config-item-set
+   | config-config-item-map-named
+   | config-config-item-map-indexed)+
+config-config-item-set-attlist = attribute config:name { \string }
+config-config-item =
+  element config:config-item { config-config-item-attlist, text }
+config-config-item-attlist =
+  attribute config:name { \string }
+  & attribute config:type {
+      "boolean"
+      | "short"
+      | "int"
+      | "long"
+      | "double"
+      | "string"
+      | "datetime"
+      | "base64Binary"
+    }
+config-config-item-map-indexed =
+  element config:config-item-map-indexed {
+    config-config-item-map-indexed-attlist,
+    config-config-item-map-entry+
+  }
+config-config-item-map-indexed-attlist =
+  attribute config:name { \string }
+config-config-item-map-entry =
+  element config:config-item-map-entry {
+    config-config-item-map-entry-attlist, config-items
+  }
+config-config-item-map-entry-attlist =
+  attribute config:name { \string }?
+config-config-item-map-named =
+  element config:config-item-map-named {
+    config-config-item-map-named-attlist, config-config-item-map-entry+
+  }
+config-config-item-map-named-attlist = attribute config:name { \string }
+office-scripts =
+  element office:scripts { office-script*, office-event-listeners? }?
+office-script =
+  element office:script {
+    office-script-attlist,
+    mixed { anyElements }
+  }
+office-script-attlist = attribute script:language { \string }
+office-font-face-decls =
+  element office:font-face-decls { style-font-face* }?
+office-styles =
+  element office:styles {
+    styles
+    & style-default-style*
+    & style-default-page-layout?
+    & text-outline-style?
+    & text-notes-configuration*
+    & text-bibliography-configuration?
+    & text-linenumbering-configuration?
+    & draw-gradient*
+    & svg-linearGradient*
+    & svg-radialGradient*
+    & draw-hatch*
+    & draw-fill-image*
+    & draw-marker*
+    & draw-stroke-dash*
+    & draw-opacity*
+    & style-presentation-page-layout*
+    & table-table-template*
+  }?
+office-automatic-styles =
+  element office:automatic-styles { styles & style-page-layout* }?
+office-master-styles =
+  element office:master-styles {
+    style-master-page* & style-handout-master? & draw-layer-set?
+  }?
+styles =
+  style-style*
+  & text-list-style*
+  & number-number-style*
+  & number-currency-style*
+  & number-percentage-style*
+  & number-date-style*
+  & number-time-style*
+  & number-boolean-style*
+  & number-text-style*
+office-meta-data =
+  element meta:generator { \string }
+  | element dc:title { \string }
+  | element dc:description { \string }
+  | element dc:subject { \string }
+  | element meta:keyword { \string }
+  | element meta:initial-creator { \string }
+  | dc-creator
+  | element meta:printed-by { \string }
+  | element meta:creation-date { dateTime }
+  | dc-date
+  | element meta:print-date { dateTime }
+  | element meta:template {
+      attribute xlink:type { "simple" },
+      attribute xlink:href { anyIRI },
+      attribute xlink:actuate { "onRequest" }?,
+      attribute xlink:title { \string }?,
+      attribute meta:date { dateTime }?
+    }
+  | element meta:auto-reload {
+      (attribute xlink:type { "simple" },
+       attribute xlink:href { anyIRI },
+       attribute xlink:show { "replace" }?,
+       attribute xlink:actuate { "onLoad" }?)?,
+      attribute meta:delay { duration }?
+    }
+  | element meta:hyperlink-behaviour {
+      attribute office:target-frame-name { targetFrameName }?,
+      attribute xlink:show { "new" | "replace" }?
+    }
+  | element dc:language { language }
+  | element meta:editing-cycles { nonNegativeInteger }
+  | element meta:editing-duration { duration }
+  | element meta:document-statistic {
+      attribute meta:page-count { nonNegativeInteger }?,
+      attribute meta:table-count { nonNegativeInteger }?,
+      attribute meta:draw-count { nonNegativeInteger }?,
+      attribute meta:image-count { nonNegativeInteger }?,
+      attribute meta:ole-object-count { nonNegativeInteger }?,
+      attribute meta:object-count { nonNegativeInteger }?,
+      attribute meta:paragraph-count { nonNegativeInteger }?,
+      attribute meta:word-count { nonNegativeInteger }?,
+      attribute meta:character-count { nonNegativeInteger }?,
+      attribute meta:frame-count { nonNegativeInteger }?,
+      attribute meta:sentence-count { nonNegativeInteger }?,
+      attribute meta:syllable-count { nonNegativeInteger }?,
+      attribute meta:non-whitespace-character-count {
+        nonNegativeInteger
+      }?,
+      attribute meta:row-count { nonNegativeInteger }?,
+      attribute meta:cell-count { nonNegativeInteger }?
+    }
+  | element meta:user-defined {
+      attribute meta:name { \string },
+      ((attribute meta:value-type { "float" },
+        double)
+       | (attribute meta:value-type { "date" },
+          dateOrDateTime)
+       | (attribute meta:value-type { "time" },
+          duration)
+       | (attribute meta:value-type { "boolean" },
+          boolean)
+       | (attribute meta:value-type { "string" },
+          \string)
+       | text)
+    }
+dc-creator = element dc:creator { \string }
+dc-date = element dc:date { dateTime }
+text-h =
+  element text:h {
+    heading-attrs,
+    paragraph-attrs,
+    text-number?,
+    paragraph-content-or-hyperlink*
+  }
+heading-attrs =
+  attribute text:outline-level { positiveInteger }
+  & attribute text:restart-numbering { boolean }?
+  & attribute text:start-value { nonNegativeInteger }?
+  & attribute text:is-list-header { boolean }?
+text-number = element text:number { \string }
+text-p =
+  element text:p { paragraph-attrs, paragraph-content-or-hyperlink* }
+paragraph-attrs =
+  attribute text:style-name { styleNameRef }?
+  & attribute text:class-names { styleNameRefs }?
+  & attribute text:cond-style-name { styleNameRef }?
+  & (xml-id,
+     attribute text:id { NCName }?)?
+  & common-in-content-meta-attlist?
+text-page-sequence = element text:page-sequence { text-page+ }
+text-page = element text:page { text-page-attlist, empty }
+text-page-attlist = attribute text:master-page-name { styleNameRef }
+text-list =
+  element text:list {
+    text-list-attr, text-list-header?, text-list-item*
+  }
+text-list-attr =
+  attribute text:style-name { styleNameRef }?
+  & attribute text:continue-numbering { boolean }?
+  & attribute text:continue-list { IDREF }?
+  & xml-id?
+text-list-item =
+  element text:list-item { text-list-item-attr, text-list-item-content }
+text-list-item-content =
+  text-number?, (text-p | text-h | text-list | text-soft-page-break)*
+text-list-item-attr =
+  attribute text:start-value { nonNegativeInteger }?
+  & attribute text:style-override { styleNameRef }?
+  & xml-id?
+text-list-header =
+  element text:list-header {
+    text-list-header-attr, text-list-item-content
+  }
+text-list-header-attr = xml-id?
+text-numbered-paragraph =
+  element text:numbered-paragraph {
+    text-numbered-paragraph-attr, text-number?, (text-p | text-h)
+  }
+text-numbered-paragraph-attr =
+  attribute text:list-id { NCName }
+  & attribute text:level { positiveInteger }?
+  & (attribute text:style-name { styleNameRef },
+     attribute text:continue-numbering { boolean },
+     attribute text:start-value { nonNegativeInteger })?
+  & xml-id?
+text-section =
+  element text:section {
+    text-section-attlist,
+    (text-section-source | text-section-source-dde | empty),
+    text-content*
+  }
+text-section-attlist =
+  common-section-attlist
+  & (attribute text:display { "true" | "none" }
+     | (attribute text:display { "condition" },
+        attribute text:condition { \string })
+     | empty)
+common-section-attlist =
+  attribute text:style-name { styleNameRef }?
+  & attribute text:name { \string }
+  & attribute text:protected { boolean }?
+  & attribute text:protection-key { \string }?
+  & attribute text:protection-key-digest-algorithm { anyIRI }?
+  & xml-id?
+text-section-source =
+  element text:section-source { text-section-source-attr }
+text-section-source-attr =
+  (attribute xlink:type { "simple" },
+   attribute xlink:href { anyIRI },
+   attribute xlink:show { "embed" }?)?
+  & attribute text:section-name { \string }?
+  & attribute text:filter-name { \string }?
+text-section-source-dde = office-dde-source
+text-tracked-changes =
+  element text:tracked-changes {
+    text-tracked-changes-attr, text-changed-region*
+  }?
+text-tracked-changes-attr = attribute text:track-changes { boolean }?
+text-changed-region =
+  element text:changed-region {
+    text-changed-region-attr, text-changed-region-content
+  }
+text-changed-region-attr =
+  xml-id,
+  attribute text:id { NCName }?
+text-changed-region-content =
+  element text:insertion { office-change-info }
+  | element text:deletion { office-change-info, text-content* }
+  | element text:format-change { office-change-info }
+change-marks =
+  element text:change { change-mark-attr }
+  | element text:change-start { change-mark-attr }
+  | element text:change-end { change-mark-attr }
+change-mark-attr = attribute text:change-id { IDREF }
+text-soft-page-break = element text:soft-page-break { empty }
+text-decls =
+  element text:variable-decls { text-variable-decl* }?,
+  element text:sequence-decls { text-sequence-decl* }?,
+  element text:user-field-decls { text-user-field-decl* }?,
+  element text:dde-connection-decls { text-dde-connection-decl* }?,
+  text-alphabetical-index-auto-mark-file?
+paragraph-content-or-hyperlink = paragraph-content | text-a
+paragraph-content =
+  text
+  | element text:s {
+      attribute text:c { nonNegativeInteger }?
+    }
+  | element text:tab { text-tab-attr }
+  | element text:line-break { empty }
+  | text-soft-page-break
+  | element text:span {
+      attribute text:style-name { styleNameRef }?,
+      attribute text:class-names { styleNameRefs }?,
+      paragraph-content-or-hyperlink*
+    }
+  | element text:meta {
+      text-meta-attlist, paragraph-content-or-hyperlink*
+    }
+  | (text-bookmark | text-bookmark-start | text-bookmark-end)
+  | element text:reference-mark {
+      attribute text:name { \string }
+    }
+  | (element text:reference-mark-start {
+       attribute text:name { \string }
+     }
+     | element text:reference-mark-end {
+         attribute text:name { \string }
+       })
+  | element text:note {
+      text-note-class,
+      attribute text:id { \string }?,
+      element text:note-citation {
+        attribute text:label { \string }?,
+        text
+      },
+      element text:note-body { text-content* }
+    }
+  | element text:ruby {
+      attribute text:style-name { styleNameRef }?,
+      element text:ruby-base { paragraph-content-or-hyperlink* },
+      element text:ruby-text {
+        attribute text:style-name { styleNameRef }?,
+        text
+      }
+    }
+  | (office-annotation | office-annotation-end)
+  | change-marks
+  | shape
+  | element text:date { text-date-attlist, text }
+  | element text:time { text-time-attlist, text }
+  | element text:page-number { text-page-number-attlist, text }
+  | element text:page-continuation {
+      text-page-continuation-attlist, text
+    }
+  | element text:sender-firstname { common-field-fixed-attlist, text }
+  | element text:sender-lastname { common-field-fixed-attlist, text }
+  | element text:sender-initials { common-field-fixed-attlist, text }
+  | element text:sender-title { common-field-fixed-attlist, text }
+  | element text:sender-position { common-field-fixed-attlist, text }
+  | element text:sender-email { common-field-fixed-attlist, text }
+  | element text:sender-phone-private {
+      common-field-fixed-attlist, text
+    }
+  | element text:sender-fax { common-field-fixed-attlist, text }
+  | element text:sender-company { common-field-fixed-attlist, text }
+  | element text:sender-phone-work { common-field-fixed-attlist, text }
+  | element text:sender-street { common-field-fixed-attlist, text }
+  | element text:sender-city { common-field-fixed-attlist, text }
+  | element text:sender-postal-code { common-field-fixed-attlist, text }
+  | element text:sender-country { common-field-fixed-attlist, text }
+  | element text:sender-state-or-province {
+      common-field-fixed-attlist, text
+    }
+  | element text:author-name { common-field-fixed-attlist, text }
+  | element text:author-initials { common-field-fixed-attlist, text }
+  | element text:chapter { text-chapter-attlist, text }
+  | element text:file-name { text-file-name-attlist, text }
+  | element text:template-name { text-template-name-attlist, text }
+  | element text:sheet-name { text }
+  | element text:variable-set {
+      (common-field-name-attlist
+       & common-field-formula-attlist
+       & common-value-and-type-attlist
+       & common-field-display-value-none-attlist
+       & common-field-data-style-name-attlist),
+      text
+    }
+  | element text:variable-get {
+      (common-field-name-attlist
+       & common-field-display-value-formula-attlist
+       & common-field-data-style-name-attlist),
+      text
+    }
+  | element text:variable-input {
+      (common-field-name-attlist
+       & common-field-description-attlist
+       & common-value-type-attlist
+       & common-field-display-value-none-attlist
+       & common-field-data-style-name-attlist),
+      text
+    }
+  | element text:user-field-get {
+      (common-field-name-attlist
+       & common-field-display-value-formula-none-attlist
+       & common-field-data-style-name-attlist),
+      text
+    }
+  | element text:user-field-input {
+      (common-field-name-attlist
+       & common-field-description-attlist
+       & common-field-data-style-name-attlist),
+      text
+    }
+  | element text:sequence {
+      (common-field-name-attlist
+       & common-field-formula-attlist
+       & common-field-num-format-attlist
+       & text-sequence-ref-name),
+      text
+    }
+  | element text:expression {
+      (common-field-formula-attlist
+       & common-value-and-type-attlist?
+       & common-field-display-value-formula-attlist
+       & common-field-data-style-name-attlist),
+      text
+    }
+  | element text:text-input { common-field-description-attlist, text }
+  | element text:initial-creator { common-field-fixed-attlist, text }
+  | element text:creation-date {
+      (common-field-fixed-attlist
+       & common-field-data-style-name-attlist
+       & attribute text:date-value { dateOrDateTime }?),
+      text
+    }
+  | element text:creation-time {
+      (common-field-fixed-attlist
+       & common-field-data-style-name-attlist
+       & attribute text:time-value { timeOrDateTime }?),
+      text
+    }
+  | element text:description { common-field-fixed-attlist, text }
+  | element text:user-defined {
+      (common-field-fixed-attlist
+       & attribute text:name { \string }
+       & common-field-data-style-name-attlist
+       & attribute office:value { double }?
+       & attribute office:date-value { dateOrDateTime }?
+       & attribute office:time-value { duration }?
+       & attribute office:boolean-value { boolean }?
+       & attribute office:string-value { \string }?),
+      text
+    }
+  | element text:print-time {
+      (common-field-fixed-attlist
+       & common-field-data-style-name-attlist
+       & attribute text:time-value { time }?),
+      text
+    }
+  | element text:print-date {
+      (common-field-fixed-attlist
+       & common-field-data-style-name-attlist
+       & attribute text:date-value { date }?),
+      text
+    }
+  | element text:printed-by { common-field-fixed-attlist, text }
+  | element text:title { common-field-fixed-attlist, text }
+  | element text:subject { common-field-fixed-attlist, text }
+  | element text:keywords { common-field-fixed-attlist, text }
+  | element text:editing-cycles { common-field-fixed-attlist, text }
+  | element text:editing-duration {
+      (common-field-fixed-attlist
+       & common-field-data-style-name-attlist
+       & attribute text:duration { duration }?),
+      text
+    }
+  | element text:modification-time {
+      (common-field-fixed-attlist
+       & common-field-data-style-name-attlist
+       & attribute text:time-value { time }?),
+      text
+    }
+  | element text:modification-date {
+      (common-field-fixed-attlist
+       & common-field-data-style-name-attlist
+       & attribute text:date-value { date }?),
+      text
+    }
+  | element text:creator { common-field-fixed-attlist, text }
+  | element text:page-count
+            | text:paragraph-count
+            | text:word-count
+            | text:character-count
+            | text:table-count
+            | text:image-count
+            | text:object-count {
+      common-field-num-format-attlist, text
+    }
+  | element text:database-display {
+      text-database-display-attlist, text
+    }
+  | element text:database-next { text-database-next-attlist }
+  | element text:database-row-select {
+      text-database-row-select-attlist
+    }
+  | element text:database-row-number {
+      (common-field-database-table
+       & common-field-num-format-attlist
+       & attribute text:value { nonNegativeInteger }?),
+      text
+    }
+  | element text:database-name { common-field-database-table, text }
+  | element text:page-variable-set {
+      text-set-page-variable-attlist, text
+    }
+  | element text:page-variable-get {
+      text-get-page-variable-attlist, text
+    }
+  | element text:placeholder { text-placeholder-attlist, text }
+  | element text:conditional-text {
+      text-conditional-text-attlist, text
+    }
+  | element text:hidden-text { text-hidden-text-attlist, text }
+  | element text:reference-ref | text:bookmark-ref {
+      text-common-ref-content & text-bookmark-ref-content
+    }
+  | element text:note-ref {
+      text-common-ref-content & text-note-ref-content
+    }
+  | element text:sequence-ref {
+      text-common-ref-content & text-sequence-ref-content
+    }
+  | element text:script {
+      ((attribute xlink:type { "simple" },
+        attribute xlink:href { anyIRI })
+       | text)
+      & attribute script:language { \string }?
+    }
+  | element text:execute-macro {
+      attribute text:name { \string }?,
+      office-event-listeners?,
+      text
+    }
+  | element text:hidden-paragraph {
+      text-hidden-paragraph-attlist, text
+    }
+  | element text:dde-connection {
+      attribute text:connection-name { \string },
+      text
+    }
+  | element text:measure {
+      attribute text:kind { "value" | "unit" | "gap" },
+      text
+    }
+  | element text:table-formula {
+      (common-field-formula-attlist
+       & common-field-display-value-formula-attlist
+       & common-field-data-style-name-attlist),
+      text
+    }
+  | element text:meta-field {
+      text-meta-field-attlist, paragraph-content-or-hyperlink*
+    }
+  | element text:toc-mark-start { text-toc-mark-start-attrs }
+  | element text:toc-mark-end { text-id }
+  | element text:toc-mark {
+      attribute text:string-value { \string },
+      text-outline-level
+    }
+  | element text:user-index-mark-start {
+      text-id, text-outline-level, text-index-name
+    }
+  | element text:user-index-mark-end { text-id }
+  | element text:user-index-mark {
+      attribute text:string-value { \string },
+      text-outline-level,
+      text-index-name
+    }
+  | element text:alphabetical-index-mark-start {
+      text-id, text-alphabetical-index-mark-attrs
+    }
+  | element text:alphabetical-index-mark-end { text-id }
+  | element text:alphabetical-index-mark {
+      attribute text:string-value { \string },
+      text-alphabetical-index-mark-attrs
+    }
+  | element text:bibliography-mark {
+      attribute text:bibliography-type { text-bibliography-types },
+      attribute text:identifier
+                | text:address
+                | text:annote
+                | text:author
+                | text:booktitle
+                | text:chapter
+                | text:edition
+                | text:editor
+                | text:howpublished
+                | text:institution
+                | text:journal
+                | text:month
+                | text:note
+                | text:number
+                | text:organizations
+                | text:pages
+                | text:publisher
+                | text:school
+                | text:series
+                | text:title
+                | text:report-type
+                | text:volume
+                | text:year
+                | text:url
+                | text:custom1
+                | text:custom2
+                | text:custom3
+                | text:custom4
+                | text:custom5
+                | text:isbn
+                | text:issn { \string }*,
+      text
+    }
+  | element presentation:header { empty }
+  | element presentation:footer { empty }
+  | element presentation:date-time { empty }
+text-tab-attr = attribute text:tab-ref { nonNegativeInteger }?
+text-a =
+  element text:a {
+    text-a-attlist, office-event-listeners?, paragraph-content*
+  }
+text-a-attlist =
+  attribute office:name { \string }?
+  & attribute office:title { \string }?
+  & attribute xlink:type { "simple" }
+  & attribute xlink:href { anyIRI }
+  & attribute xlink:actuate { "onRequest" }?
+  & attribute office:target-frame-name { targetFrameName }?
+  & attribute xlink:show { "new" | "replace" }?
+  & attribute text:style-name { styleNameRef }?
+  & attribute text:visited-style-name { styleNameRef }?
+text-meta-attlist = common-in-content-meta-attlist? & xml-id?
+text-bookmark = element text:bookmark { text-bookmark-attlist, empty }
+text-bookmark-start =
+  element text:bookmark-start { text-bookmark-start-attlist, empty }
+text-bookmark-end =
+  element text:bookmark-end { text-bookmark-end-attlist, empty }
+text-bookmark-attlist =
+  attribute text:name { \string }
+  & xml-id?
+text-bookmark-start-attlist =
+  attribute text:name { \string }
+  & xml-id?
+  & common-in-content-meta-attlist?
+text-bookmark-end-attlist = attribute text:name { \string }
+text-note-class = attribute text:note-class { "footnote" | "endnote" }
+text-date-attlist =
+  (common-field-fixed-attlist & common-field-data-style-name-attlist)
+  & attribute text:date-value { dateOrDateTime }?
+  & attribute text:date-adjust { duration }?
+text-time-attlist =
+  (common-field-fixed-attlist & common-field-data-style-name-attlist)
+  & attribute text:time-value { timeOrDateTime }?
+  & attribute text:time-adjust { duration }?
+text-page-number-attlist =
+  (common-field-num-format-attlist & common-field-fixed-attlist)
+  & attribute text:page-adjust { integer }?
+  & attribute text:select-page { "previous" | "current" | "next" }?
+text-page-continuation-attlist =
+  attribute text:select-page { "previous" | "next" }
+  & attribute text:string-value { \string }?
+text-chapter-attlist =
+  attribute text:display {
+    "name"
+    | "number"
+    | "number-and-name"
+    | "plain-number-and-name"
+    | "plain-number"
+  }
+  & attribute text:outline-level { nonNegativeInteger }
+text-file-name-attlist =
+  attribute text:display {
+    "full" | "path" | "name" | "name-and-extension"
+  }?
+  & common-field-fixed-attlist
+text-template-name-attlist =
+  attribute text:display {
+    "full" | "path" | "name" | "name-and-extension" | "area" | "title"
+  }?
+text-variable-decl =
+  element text:variable-decl {
+    common-field-name-attlist, common-value-type-attlist
+  }
+text-user-field-decl =
+  element text:user-field-decl {
+    common-field-name-attlist,
+    common-field-formula-attlist?,
+    common-value-and-type-attlist
+  }
+text-sequence-decl =
+  element text:sequence-decl { text-sequence-decl-attlist }
+text-sequence-decl-attlist =
+  common-field-name-attlist
+  & attribute text:display-outline-level { nonNegativeInteger }
+  & attribute text:separation-character { character }?
+text-sequence-ref-name = attribute text:ref-name { \string }?
+common-field-database-table =
+  common-field-database-table-attlist, common-field-database-name
+common-field-database-name =
+  attribute text:database-name { \string }?
+  | form-connection-resource
+common-field-database-table-attlist =
+  attribute text:table-name { \string }
+  & attribute text:table-type { "table" | "query" | "command" }?
+text-database-display-attlist =
+  common-field-database-table
+  & common-field-data-style-name-attlist
+  & attribute text:column-name { \string }
+text-database-next-attlist =
+  common-field-database-table
+  & attribute text:condition { \string }?
+text-database-row-select-attlist =
+  common-field-database-table
+  & attribute text:condition { \string }?
+  & attribute text:row-number { nonNegativeInteger }?
+text-set-page-variable-attlist =
+  attribute text:active { boolean }?
+  & attribute text:page-adjust { integer }?
+text-get-page-variable-attlist = common-field-num-format-attlist
+text-placeholder-attlist =
+  attribute text:placeholder-type {
+    "text" | "table" | "text-box" | "image" | "object"
+  }
+  & common-field-description-attlist
+text-conditional-text-attlist =
+  attribute text:condition { \string }
+  & attribute text:string-value-if-true { \string }
+  & attribute text:string-value-if-false { \string }
+  & attribute text:current-value { boolean }?
+text-hidden-text-attlist =
+  attribute text:condition { \string }
+  & attribute text:string-value { \string }
+  & attribute text:is-hidden { boolean }?
+text-common-ref-content =
+  text
+  & attribute text:ref-name { \string }?
+text-bookmark-ref-content =
+  attribute text:reference-format {
+    common-ref-format-values
+    | "number-no-superior"
+    | "number-all-superior"
+    | "number"
+  }?
+text-note-ref-content =
+  attribute text:reference-format { common-ref-format-values }?
+  & text-note-class
+text-sequence-ref-content =
+  attribute text:reference-format {
+    common-ref-format-values
+    | "category-and-value"
+    | "caption"
+    | "value"
+  }?
+common-ref-format-values = "page" | "chapter" | "direction" | "text"
+text-hidden-paragraph-attlist =
+  attribute text:condition { \string }
+  & attribute text:is-hidden { boolean }?
+text-meta-field-attlist = xml-id & common-field-data-style-name-attlist
+common-value-type-attlist = attribute office:value-type { valueType }
+common-value-and-type-attlist =
+  (attribute office:value-type { "float" },
+   attribute office:value { double })
+  | (attribute office:value-type { "percentage" },
+     attribute office:value { double })
+  | (attribute office:value-type { "currency" },
+     attribute office:value { double },
+     attribute office:currency { \string }?)
+  | (attribute office:value-type { "date" },
+     attribute office:date-value { dateOrDateTime })
+  | (attribute office:value-type { "time" },
+     attribute office:time-value { duration })
+  | (attribute office:value-type { "boolean" },
+     attribute office:boolean-value { boolean })
+  | (attribute office:value-type { "string" },
+     attribute office:string-value { \string }?)
+common-field-fixed-attlist = attribute text:fixed { boolean }?
+common-field-name-attlist = attribute text:name { variableName }
+common-field-description-attlist =
+  attribute text:description { \string }?
+common-field-display-value-none-attlist =
+  attribute text:display { "value" | "none" }?
+common-field-display-value-formula-none-attlist =
+  attribute text:display { "value" | "formula" | "none" }?
+common-field-display-value-formula-attlist =
+  attribute text:display { "value" | "formula" }?
+common-field-formula-attlist = attribute text:formula { \string }?
+common-field-data-style-name-attlist =
+  attribute style:data-style-name { styleNameRef }?
+common-field-num-format-attlist = common-num-format-attlist?
+text-toc-mark-start-attrs = text-id, text-outline-level
+text-outline-level = attribute text:outline-level { positiveInteger }?
+text-id = attribute text:id { \string }
+text-index-name = attribute text:index-name { \string }
+text-alphabetical-index-mark-attrs =
+  attribute text:key1 { \string }?
+  & attribute text:key2 { \string }?
+  & attribute text:string-value-phonetic { \string }?
+  & attribute text:key1-phonetic { \string }?
+  & attribute text:key2-phonetic { \string }?
+  & attribute text:main-entry { boolean }?
+text-bibliography-types =
+  "article"
+  | "book"
+  | "booklet"
+  | "conference"
+  | "custom1"
+  | "custom2"
+  | "custom3"
+  | "custom4"
+  | "custom5"
+  | "email"
+  | "inbook"
+  | "incollection"
+  | "inproceedings"
+  | "journal"
+  | "manual"
+  | "mastersthesis"
+  | "misc"
+  | "phdthesis"
+  | "proceedings"
+  | "techreport"
+  | "unpublished"
+  | "www"
+text-index-body = element text:index-body { index-content-main* }
+index-content-main = text-content | text-index-title
+text-index-title =
+  element text:index-title {
+    common-section-attlist, index-content-main*
+  }
+text-table-of-content =
+  element text:table-of-content {
+    common-section-attlist,
+    text-table-of-content-source,
+    text-index-body
+  }
+text-table-of-content-source =
+  element text:table-of-content-source {
+    text-table-of-content-source-attlist,
+    text-index-title-template?,
+    text-table-of-content-entry-template*,
+    text-index-source-styles*
+  }
+text-table-of-content-source-attlist =
+  attribute text:outline-level { positiveInteger }?
+  & attribute text:use-outline-level { boolean }?
+  & attribute text:use-index-marks { boolean }?
+  & attribute text:use-index-source-styles { boolean }?
+  & attribute text:index-scope { "document" | "chapter" }?
+  & attribute text:relative-tab-stop-position { boolean }?
+text-table-of-content-entry-template =
+  element text:table-of-content-entry-template {
+    text-table-of-content-entry-template-attlist,
+    text-table-of-content-children*
+  }
+text-table-of-content-children =
+  text-index-entry-chapter
+  | text-index-entry-page-number
+  | text-index-entry-text
+  | text-index-entry-span
+  | text-index-entry-tab-stop
+  | text-index-entry-link-start
+  | text-index-entry-link-end
+text-table-of-content-entry-template-attlist =
+  attribute text:outline-level { positiveInteger }
+  & attribute text:style-name { styleNameRef }
+text-illustration-index =
+  element text:illustration-index {
+    common-section-attlist,
+    text-illustration-index-source,
+    text-index-body
+  }
+text-illustration-index-source =
+  element text:illustration-index-source {
+    text-illustration-index-source-attrs,
+    text-index-title-template?,
+    text-illustration-index-entry-template?
+  }
+text-illustration-index-source-attrs =
+  text-index-scope-attr
+  & text-relative-tab-stop-position-attr
+  & attribute text:use-caption { boolean }?
+  & attribute text:caption-sequence-name { \string }?
+  & attribute text:caption-sequence-format {
+      "text" | "category-and-value" | "caption"
+    }?
+text-index-scope-attr =
+  attribute text:index-scope { "document" | "chapter" }?
+text-relative-tab-stop-position-attr =
+  attribute text:relative-tab-stop-position { boolean }?
+text-illustration-index-entry-template =
+  element text:illustration-index-entry-template {
+    text-illustration-index-entry-content
+  }
+text-illustration-index-entry-content =
+  text-illustration-index-entry-template-attrs,
+  (text-index-entry-chapter
+   | text-index-entry-page-number
+   | text-index-entry-text
+   | text-index-entry-span
+   | text-index-entry-tab-stop)*
+text-illustration-index-entry-template-attrs =
+  attribute text:style-name { styleNameRef }
+text-table-index =
+  element text:table-index {
+    common-section-attlist, text-table-index-source, text-index-body
+  }
+text-table-index-source =
+  element text:table-index-source {
+    text-illustration-index-source-attrs,
+    text-index-title-template?,
+    text-table-index-entry-template?
+  }
+text-table-index-entry-template =
+  element text:table-index-entry-template {
+    text-illustration-index-entry-content
+  }
+text-object-index =
+  element text:object-index {
+    common-section-attlist, text-object-index-source, text-index-body
+  }
+text-object-index-source =
+  element text:object-index-source {
+    text-object-index-source-attrs,
+    text-index-title-template?,
+    text-object-index-entry-template?
+  }
+text-object-index-source-attrs =
+  text-index-scope-attr
+  & text-relative-tab-stop-position-attr
+  & attribute text:use-spreadsheet-objects { boolean }?
+  & attribute text:use-math-objects { boolean }?
+  & attribute text:use-draw-objects { boolean }?
+  & attribute text:use-chart-objects { boolean }?
+  & attribute text:use-other-objects { boolean }?
+text-object-index-entry-template =
+  element text:object-index-entry-template {
+    text-illustration-index-entry-content
+  }
+text-user-index =
+  element text:user-index {
+    common-section-attlist, text-user-index-source, text-index-body
+  }
+text-user-index-source =
+  element text:user-index-source {
+    text-user-index-source-attr,
+    text-index-title-template?,
+    text-user-index-entry-template*,
+    text-index-source-styles*
+  }
+text-user-index-source-attr =
+  text-index-scope-attr
+  & text-relative-tab-stop-position-attr
+  & attribute text:use-index-marks { boolean }?
+  & attribute text:use-index-source-styles { boolean }?
+  & attribute text:use-graphics { boolean }?
+  & attribute text:use-tables { boolean }?
+  & attribute text:use-floating-frames { boolean }?
+  & attribute text:use-objects { boolean }?
+  & attribute text:copy-outline-levels { boolean }?
+  & attribute text:index-name { \string }
+text-user-index-entry-template =
+  element text:user-index-entry-template {
+    text-user-index-entry-template-attrs,
+    (text-index-entry-chapter
+     | text-index-entry-page-number
+     | text-index-entry-text
+     | text-index-entry-span
+     | text-index-entry-tab-stop)*
+  }
+text-user-index-entry-template-attrs =
+  attribute text:outline-level { positiveInteger }
+  & attribute text:style-name { styleNameRef }
+text-alphabetical-index =
+  element text:alphabetical-index {
+    common-section-attlist,
+    text-alphabetical-index-source,
+    text-index-body
+  }
+text-alphabetical-index-source =
+  element text:alphabetical-index-source {
+    text-alphabetical-index-source-attrs,
+    text-index-title-template?,
+    text-alphabetical-index-entry-template*
+  }
+text-alphabetical-index-source-attrs =
+  text-index-scope-attr
+  & text-relative-tab-stop-position-attr
+  & attribute text:ignore-case { boolean }?
+  & attribute text:main-entry-style-name { styleNameRef }?
+  & attribute text:alphabetical-separators { boolean }?
+  & attribute text:combine-entries { boolean }?
+  & attribute text:combine-entries-with-dash { boolean }?
+  & attribute text:combine-entries-with-pp { boolean }?
+  & attribute text:use-keys-as-entries { boolean }?
+  & attribute text:capitalize-entries { boolean }?
+  & attribute text:comma-separated { boolean }?
+  & attribute fo:language { languageCode }?
+  & attribute fo:country { countryCode }?
+  & attribute fo:script { scriptCode }?
+  & attribute style:rfc-language-tag { language }?
+  & attribute text:sort-algorithm { \string }?
+text-alphabetical-index-auto-mark-file =
+  element text:alphabetical-index-auto-mark-file {
+    attribute xlink:type { "simple" },
+    attribute xlink:href { anyIRI }
+  }
+text-alphabetical-index-entry-template =
+  element text:alphabetical-index-entry-template {
+    text-alphabetical-index-entry-template-attrs,
+    (text-index-entry-chapter
+     | text-index-entry-page-number
+     | text-index-entry-text
+     | text-index-entry-span
+     | text-index-entry-tab-stop)*
+  }
+text-alphabetical-index-entry-template-attrs =
+  attribute text:outline-level { "1" | "2" | "3" | "separator" }
+  & attribute text:style-name { styleNameRef }
+text-bibliography =
+  element text:bibliography {
+    common-section-attlist, text-bibliography-source, text-index-body
+  }
+text-bibliography-source =
+  element text:bibliography-source {
+    text-index-title-template?, text-bibliography-entry-template*
+  }
+text-bibliography-entry-template =
+  element text:bibliography-entry-template {
+    text-bibliography-entry-template-attrs,
+    (text-index-entry-span
+     | text-index-entry-tab-stop
+     | text-index-entry-bibliography)*
+  }
+text-bibliography-entry-template-attrs =
+  attribute text:bibliography-type { text-bibliography-types }
+  & attribute text:style-name { styleNameRef }
+text-index-source-styles =
+  element text:index-source-styles {
+    attribute text:outline-level { positiveInteger },
+    text-index-source-style*
+  }
+text-index-source-style =
+  element text:index-source-style {
+    attribute text:style-name { styleName },
+    empty
+  }
+text-index-title-template =
+  element text:index-title-template {
+    attribute text:style-name { styleNameRef }?,
+    text
+  }
+text-index-entry-chapter =
+  element text:index-entry-chapter {
+    attribute text:style-name { styleNameRef }?,
+    text-index-entry-chapter-attrs
+  }
+text-index-entry-chapter-attrs =
+  attribute text:display {
+    "name"
+    | "number"
+    | "number-and-name"
+    | "plain-number"
+    | "plain-number-and-name"
+  }?
+  & attribute text:outline-level { positiveInteger }?
+text-index-entry-text =
+  element text:index-entry-text {
+    attribute text:style-name { styleNameRef }?
+  }
+text-index-entry-page-number =
+  element text:index-entry-page-number {
+    attribute text:style-name { styleNameRef }?
+  }
+text-index-entry-span =
+  element text:index-entry-span {
+    attribute text:style-name { styleNameRef }?,
+    text
+  }
+text-index-entry-bibliography =
+  element text:index-entry-bibliography {
+    text-index-entry-bibliography-attrs
+  }
+text-index-entry-bibliography-attrs =
+  attribute text:style-name { styleNameRef }?
+  & attribute text:bibliography-data-field {
+      "address"
+      | "annote"
+      | "author"
+      | "bibliography-type"
+      | "booktitle"
+      | "chapter"
+      | "custom1"
+      | "custom2"
+      | "custom3"
+      | "custom4"
+      | "custom5"
+      | "edition"
+      | "editor"
+      | "howpublished"
+      | "identifier"
+      | "institution"
+      | "isbn"
+      | "issn"
+      | "journal"
+      | "month"
+      | "note"
+      | "number"
+      | "organizations"
+      | "pages"
+      | "publisher"
+      | "report-type"
+      | "school"
+      | "series"
+      | "title"
+      | "url"
+      | "volume"
+      | "year"
+    }
+text-index-entry-tab-stop =
+  element text:index-entry-tab-stop {
+    attribute text:style-name { styleNameRef }?,
+    text-index-entry-tab-stop-attrs
+  }
+text-index-entry-tab-stop-attrs =
+  attribute style:leader-char { character }?
+  & (attribute style:type { "right" }
+     | (attribute style:type { "left" },
+        attribute style:position { length }))
+text-index-entry-link-start =
+  element text:index-entry-link-start {
+    attribute text:style-name { styleNameRef }?
+  }
+text-index-entry-link-end =
+  element text:index-entry-link-end {
+    attribute text:style-name { styleNameRef }?
+  }
+table-table =
+  element table:table {
+    table-table-attlist,
+    table-title?,
+    table-desc?,
+    table-table-source?,
+    office-dde-source?,
+    table-scenario?,
+    office-forms?,
+    table-shapes?,
+    table-columns-and-groups,
+    table-rows-and-groups,
+    table-named-expressions?
+  }
+table-columns-and-groups =
+  (table-table-column-group | table-columns-no-group)+
+table-columns-no-group =
+  (table-columns, (table-table-header-columns, table-columns?)?)
+  | (table-table-header-columns, table-columns?)
+table-columns = table-table-columns | table-table-column+
+table-rows-and-groups = (table-table-row-group | table-rows-no-group)+
+table-rows-no-group =
+  (table-rows, (table-table-header-rows, table-rows?)?)
+  | (table-table-header-rows, table-rows?)
+table-rows =
+  table-table-rows | (text-soft-page-break?, table-table-row)+
+table-table-attlist =
+  attribute table:name { \string }?
+  & attribute table:style-name { styleNameRef }?
+  & attribute table:template-name { \string }?
+  & attribute table:use-first-row-styles { boolean }?
+  & attribute table:use-last-row-styles { boolean }?
+  & attribute table:use-first-column-styles { boolean }?
+  & attribute table:use-last-column-styles { boolean }?
+  & attribute table:use-banding-rows-styles { boolean }?
+  & attribute table:use-banding-columns-styles { boolean }?
+  & attribute table:protected { boolean }?
+  & attribute table:protection-key { \string }?
+  & attribute table:protection-key-digest-algorithm { anyIRI }?
+  & attribute table:print { boolean }?
+  & attribute table:print-ranges { cellRangeAddressList }?
+  & xml-id?
+  & attribute table:is-sub-table { boolean }?
+table-title = element table:title { text }
+table-desc = element table:desc { text }
+table-table-row =
+  element table:table-row {
+    table-table-row-attlist,
+    (table-table-cell | table-covered-table-cell)+
+  }
+table-table-row-attlist =
+  attribute table:number-rows-repeated { positiveInteger }?
+  & attribute table:style-name { styleNameRef }?
+  & attribute table:default-cell-style-name { styleNameRef }?
+  & attribute table:visibility { table-visibility-value }?
+  & xml-id?
+table-visibility-value = "visible" | "collapse" | "filter"
+table-table-cell =
+  element table:table-cell {
+    table-table-cell-attlist,
+    table-table-cell-attlist-extra,
+    table-table-cell-content
+  }
+table-covered-table-cell =
+  element table:covered-table-cell {
+    table-table-cell-attlist, table-table-cell-content
+  }
+table-table-cell-content =
+  table-cell-range-source?,
+  office-annotation?,
+  table-detective?,
+  text-content*
+table-table-cell-attlist =
+  attribute table:number-columns-repeated { positiveInteger }?
+  & attribute table:style-name { styleNameRef }?
+  & attribute table:content-validation-name { \string }?
+  & attribute table:formula { \string }?
+  & common-value-and-type-attlist?
+  & attribute table:protect { boolean }?
+  & attribute table:protected { boolean }?
+  & xml-id?
+  & common-in-content-meta-attlist?
+table-table-cell-attlist-extra =
+  attribute table:number-columns-spanned { positiveInteger }?
+  & attribute table:number-rows-spanned { positiveInteger }?
+  & attribute table:number-matrix-columns-spanned { positiveInteger }?
+  & attribute table:number-matrix-rows-spanned { positiveInteger }?
+table-table-column =
+  element table:table-column { table-table-column-attlist, empty }
+table-table-column-attlist =
+  attribute table:number-columns-repeated { positiveInteger }?
+  & attribute table:style-name { styleNameRef }?
+  & attribute table:visibility { table-visibility-value }?
+  & attribute table:default-cell-style-name { styleNameRef }?
+  & xml-id?
+table-table-header-columns =
+  element table:table-header-columns { table-table-column+ }
+table-table-columns =
+  element table:table-columns { table-table-column+ }
+table-table-column-group =
+  element table:table-column-group {
+    table-table-column-group-attlist, table-columns-and-groups
+  }
+table-table-column-group-attlist = attribute table:display { boolean }?
+table-table-header-rows =
+  element table:table-header-rows {
+    (text-soft-page-break?, table-table-row)+
+  }
+table-table-rows =
+  element table:table-rows { (text-soft-page-break?, table-table-row)+ }
+table-table-row-group =
+  element table:table-row-group {
+    table-table-row-group-attlist, table-rows-and-groups
+  }
+table-table-row-group-attlist = attribute table:display { boolean }?
+cellAddress =
+  xsd:string {
+    pattern = "($?([^\. ']+|'([^']|'')+'))?\.$?[A-Z]+$?[0-9]+"
+  }
+cellRangeAddress =
+  xsd:string {
+    pattern =
+      "($?([^\. ']+|'([^']|'')+'))?\.$?[A-Z]+$?[0-9]+(:($?([^\. ']+|'([^']|'')+'))?\.$?[A-Z]+$?[0-9]+)?"
+  }
+  | xsd:string {
+      pattern =
+        "($?([^\. ']+|'([^']|'')+'))?\.$?[0-9]+:($?([^\. ']+|'([^']|'')+'))?\.$?[0-9]+"
+    }
+  | xsd:string {
+      pattern =
+        "($?([^\. ']+|'([^']|'')+'))?\.$?[A-Z]+:($?([^\. ']+|'([^']|'')+'))?\.$?[A-Z]+"
+    }
+cellRangeAddressList =
+  xsd:string
+  >> dc:description [
+       'Value is a space separated list of "cellRangeAddress" patterns'
+     ]
+table-table-source =
+  element table:table-source {
+    table-table-source-attlist, table-linked-source-attlist, empty
+  }
+table-table-source-attlist =
+  attribute table:mode { "copy-all" | "copy-results-only" }?
+  & attribute table:table-name { \string }?
+table-linked-source-attlist =
+  attribute xlink:type { "simple" }
+  & attribute xlink:href { anyIRI }
+  & attribute xlink:actuate { "onRequest" }?
+  & attribute table:filter-name { \string }?
+  & attribute table:filter-options { \string }?
+  & attribute table:refresh-delay { duration }?
+table-scenario =
+  element table:scenario { table-scenario-attlist, empty }
+table-scenario-attlist =
+  attribute table:scenario-ranges { cellRangeAddressList }
+  & attribute table:is-active { boolean }
+  & attribute table:display-border { boolean }?
+  & attribute table:border-color { color }?
+  & attribute table:copy-back { boolean }?
+  & attribute table:copy-styles { boolean }?
+  & attribute table:copy-formulas { boolean }?
+  & attribute table:comment { \string }?
+  & attribute table:protected { boolean }?
+table-shapes = element table:shapes { shape+ }
+table-cell-range-source =
+  element table:cell-range-source {
+    table-table-cell-range-source-attlist,
+    table-linked-source-attlist,
+    empty
+  }
+table-table-cell-range-source-attlist =
+  attribute table:name { \string }
+  & attribute table:last-column-spanned { positiveInteger }
+  & attribute table:last-row-spanned { positiveInteger }
+table-detective =
+  element table:detective { table-highlighted-range*, table-operation* }
+table-operation =
+  element table:operation { table-operation-attlist, empty }
+table-operation-attlist =
+  attribute table:name {
+    "trace-dependents"
+    | "remove-dependents"
+    | "trace-precedents"
+    | "remove-precedents"
+    | "trace-errors"
+  }
+  & attribute table:index { nonNegativeInteger }
+table-highlighted-range =
+  element table:highlighted-range {
+    (table-highlighted-range-attlist
+     | table-highlighted-range-attlist-invalid),
+    empty
+  }
+table-highlighted-range-attlist =
+  attribute table:cell-range-address { cellRangeAddress }?
+  & attribute table:direction {
+      "from-another-table" | "to-another-table" | "from-same-table"
+    }
+  & attribute table:contains-error { boolean }?
+table-highlighted-range-attlist-invalid =
+  attribute table:marked-invalid { boolean }
+office-spreadsheet-attlist =
+  attribute table:structure-protected { boolean }?,
+  attribute table:protection-key { \string }?,
+  attribute table:protection-key-digest-algorithm { anyIRI }?
+table-calculation-settings =
+  element table:calculation-settings {
+    table-calculation-setting-attlist,
+    table-null-date?,
+    table-iteration?
+  }
+table-calculation-setting-attlist =
+  attribute table:case-sensitive { boolean }?
+  & attribute table:precision-as-shown { boolean }?
+  & attribute table:search-criteria-must-apply-to-whole-cell {
+      boolean
+    }?
+  & attribute table:automatic-find-labels { boolean }?
+  & attribute table:use-regular-expressions { boolean }?
+  & attribute table:use-wildcards { boolean }?
+  & attribute table:null-year { positiveInteger }?
+table-null-date =
+  element table:null-date {
+    attribute table:value-type { "date" }?,
+    attribute table:date-value { date }?,
+    empty
+  }
+table-iteration =
+  element table:iteration {
+    attribute table:status { "enable" | "disable" }?,
+    attribute table:steps { positiveInteger }?,
+    attribute table:maximum-difference { double }?,
+    empty
+  }
+table-content-validations =
+  element table:content-validations { table-content-validation+ }
+table-content-validation =
+  element table:content-validation {
+    table-validation-attlist,
+    table-help-message?,
+    (table-error-message | (table-error-macro, office-event-listeners))?
+  }
+table-validation-attlist =
+  attribute table:name { \string }
+  & attribute table:condition { \string }?
+  & attribute table:base-cell-address { cellAddress }?
+  & attribute table:allow-empty-cell { boolean }?
+  & attribute table:display-list {
+      "none" | "unsorted" | "sort-ascending"
+    }?
+table-help-message =
+  element table:help-message {
+    attribute table:title { \string }?,
+    attribute table:display { boolean }?,
+    text-p*
+  }
+table-error-message =
+  element table:error-message {
+    attribute table:title { \string }?,
+    attribute table:display { boolean }?,
+    attribute table:message-type {
+      "stop" | "warning" | "information"
+    }?,
+    text-p*
+  }
+table-error-macro =
+  element table:error-macro {
+    attribute table:execute { boolean }?
+  }
+table-label-ranges = element table:label-ranges { table-label-range* }
+table-label-range =
+  element table:label-range { table-label-range-attlist, empty }
+table-label-range-attlist =
+  attribute table:label-cell-range-address { cellRangeAddress }
+  & attribute table:data-cell-range-address { cellRangeAddress }
+  & attribute table:orientation { "column" | "row" }
+table-named-expressions =
+  element table:named-expressions {
+    (table-named-range | table-named-expression)*
+  }
+table-named-range =
+  element table:named-range { table-named-range-attlist, empty }
+table-named-range-attlist =
+  attribute table:name { \string },
+  attribute table:cell-range-address { cellRangeAddress },
+  attribute table:base-cell-address { cellAddress }?,
+  attribute table:range-usable-as {
+    "none"
+    | list {
+        ("print-range" | "filter" | "repeat-row" | "repeat-column")+
+      }
+  }?
+table-named-expression =
+  element table:named-expression {
+    table-named-expression-attlist, empty
+  }
+table-named-expression-attlist =
+  attribute table:name { \string },
+  attribute table:expression { \string },
+  attribute table:base-cell-address { cellAddress }?
+table-database-ranges =
+  element table:database-ranges { table-database-range* }
+table-database-range =
+  element table:database-range {
+    table-database-range-attlist,
+    (table-database-source-sql
+     | table-database-source-table
+     | table-database-source-query)?,
+    table-filter?,
+    table-sort?,
+    table-subtotal-rules?
+  }
+table-database-range-attlist =
+  attribute table:name { \string }?
+  & attribute table:is-selection { boolean }?
+  & attribute table:on-update-keep-styles { boolean }?
+  & attribute table:on-update-keep-size { boolean }?
+  & attribute table:has-persistent-data { boolean }?
+  & attribute table:orientation { "column" | "row" }?
+  & attribute table:contains-header { boolean }?
+  & attribute table:display-filter-buttons { boolean }?
+  & attribute table:target-range-address { cellRangeAddress }
+  & attribute table:refresh-delay { boolean }?
+table-database-source-sql =
+  element table:database-source-sql {
+    table-database-source-sql-attlist, empty
+  }
+table-database-source-sql-attlist =
+  attribute table:database-name { \string }
+  & attribute table:sql-statement { \string }
+  & attribute table:parse-sql-statement { boolean }?
+table-database-source-query =
+  element table:database-source-table {
+    table-database-source-table-attlist, empty
+  }
+table-database-source-table-attlist =
+  attribute table:database-name { \string }
+  & attribute table:database-table-name { \string }
+table-database-source-table =
+  element table:database-source-query {
+    table-database-source-query-attlist, empty
+  }
+table-database-source-query-attlist =
+  attribute table:database-name { \string }
+  & attribute table:query-name { \string }
+table-sort = element table:sort { table-sort-attlist, table-sort-by+ }
+table-sort-attlist =
+  attribute table:bind-styles-to-content { boolean }?
+  & attribute table:target-range-address { cellRangeAddress }?
+  & attribute table:case-sensitive { boolean }?
+  & attribute table:language { languageCode }?
+  & attribute table:country { countryCode }?
+  & attribute table:script { scriptCode }?
+  & attribute table:rfc-language-tag { language }?
+  & attribute table:algorithm { \string }?
+  & attribute table:embedded-number-behavior {
+      "alpha-numeric" | "integer" | "double"
+    }?
+table-sort-by = element table:sort-by { table-sort-by-attlist, empty }
+table-sort-by-attlist =
+  attribute table:field-number { nonNegativeInteger }
+  & attribute table:data-type {
+      "text" | "number" | "automatic" | \string
+    }?
+  & attribute table:order { "ascending" | "descending" }?
+table-subtotal-rules =
+  element table:subtotal-rules {
+    table-subtotal-rules-attlist,
+    table-sort-groups?,
+    table-subtotal-rule*
+  }
+table-subtotal-rules-attlist =
+  attribute table:bind-styles-to-content { boolean }?
+  & attribute table:case-sensitive { boolean }?
+  & attribute table:page-breaks-on-group-change { boolean }?
+table-sort-groups =
+  element table:sort-groups { table-sort-groups-attlist, empty }
+table-sort-groups-attlist =
+  attribute table:data-type {
+    "text" | "number" | "automatic" | \string
+  }?
+  & attribute table:order { "ascending" | "descending" }?
+table-subtotal-rule =
+  element table:subtotal-rule {
+    table-subtotal-rule-attlist, table-subtotal-field*
+  }
+table-subtotal-rule-attlist =
+  attribute table:group-by-field-number { nonNegativeInteger }
+table-subtotal-field =
+  element table:subtotal-field { table-subtotal-field-attlist, empty }
+table-subtotal-field-attlist =
+  attribute table:field-number { nonNegativeInteger }
+  & attribute table:function {
+      "average"
+      | "count"
+      | "countnums"
+      | "max"
+      | "min"
+      | "product"
+      | "stdev"
+      | "stdevp"
+      | "sum"
+      | "var"
+      | "varp"
+      | \string
+    }
+table-filter =
+  element table:filter {
+    table-filter-attlist,
+    (table-filter-condition | table-filter-and | table-filter-or)
+  }
+table-filter-attlist =
+  attribute table:target-range-address { cellRangeAddress }?
+  & attribute table:condition-source { "self" | "cell-range" }?
+  & attribute table:condition-source-range-address { cellRangeAddress }?
+  & attribute table:display-duplicates { boolean }?
+table-filter-and =
+  element table:filter-and {
+    (table-filter-or | table-filter-condition)+
+  }
+table-filter-or =
+  element table:filter-or {
+    (table-filter-and | table-filter-condition)+
+  }
+table-filter-condition =
+  element table:filter-condition {
+    table-filter-condition-attlist, table-filter-set-item*
+  }
+table-filter-condition-attlist =
+  attribute table:field-number { nonNegativeInteger }
+  & attribute table:value { \string | double }
+  & attribute table:operator { \string }
+  & attribute table:case-sensitive { \string }?
+  & attribute table:data-type { "text" | "number" }?
+table-filter-set-item =
+  element table:filter-set-item {
+    attribute table:value { \string },
+    empty
+  }
+table-data-pilot-tables =
+  element table:data-pilot-tables { table-data-pilot-table* }
+table-data-pilot-table =
+  element table:data-pilot-table {
+    table-data-pilot-table-attlist,
+    (table-database-source-sql
+     | table-database-source-table
+     | table-database-source-query
+     | table-source-service
+     | table-source-cell-range)?,
+    table-data-pilot-field+
+  }
+table-data-pilot-table-attlist =
+  attribute table:name { \string }
+  & attribute table:application-data { \string }?
+  & attribute table:grand-total { "none" | "row" | "column" | "both" }?
+  & attribute table:ignore-empty-rows { boolean }?
+  & attribute table:identify-categories { boolean }?
+  & attribute table:target-range-address { cellRangeAddress }
+  & attribute table:buttons { cellRangeAddressList }?
+  & attribute table:show-filter-button { boolean }?
+  & attribute table:drill-down-on-double-click { boolean }?
+table-source-cell-range =
+  element table:source-cell-range {
+    table-source-cell-range-attlist, table-filter?
+  }
+table-source-cell-range-attlist =
+  attribute table:cell-range-address { cellRangeAddress }
+table-source-service =
+  element table:source-service { table-source-service-attlist, empty }
+table-source-service-attlist =
+  attribute table:name { \string }
+  & attribute table:source-name { \string }
+  & attribute table:object-name { \string }
+  & attribute table:user-name { \string }?
+  & attribute table:password { \string }?
+table-data-pilot-field =
+  element table:data-pilot-field {
+    table-data-pilot-field-attlist,
+    table-data-pilot-level?,
+    table-data-pilot-field-reference?,
+    table-data-pilot-groups?
+  }
+table-data-pilot-field-attlist =
+  attribute table:source-field-name { \string }
+  & (attribute table:orientation {
+       "row" | "column" | "data" | "hidden"
+     }
+     | (attribute table:orientation { "page" },
+        attribute table:selected-page { \string }))
+  & attribute table:is-data-layout-field { \string }?
+  & attribute table:function {
+      "auto"
+      | "average"
+      | "count"
+      | "countnums"
+      | "max"
+      | "min"
+      | "product"
+      | "stdev"
+      | "stdevp"
+      | "sum"
+      | "var"
+      | "varp"
+      | \string
+    }?
+  & attribute table:used-hierarchy { integer }?
+table-data-pilot-level =
+  element table:data-pilot-level {
+    table-data-pilot-level-attlist,
+    table-data-pilot-subtotals?,
+    table-data-pilot-members?,
+    table-data-pilot-display-info?,
+    table-data-pilot-sort-info?,
+    table-data-pilot-layout-info?
+  }
+table-data-pilot-level-attlist = attribute table:show-empty { boolean }?
+table-data-pilot-subtotals =
+  element table:data-pilot-subtotals { table-data-pilot-subtotal* }
+table-data-pilot-subtotal =
+  element table:data-pilot-subtotal {
+    table-data-pilot-subtotal-attlist, empty
+  }
+table-data-pilot-subtotal-attlist =
+  attribute table:function {
+    "auto"
+    | "average"
+    | "count"
+    | "countnums"
+    | "max"
+    | "min"
+    | "product"
+    | "stdev"
+    | "stdevp"
+    | "sum"
+    | "var"
+    | "varp"
+    | \string
+  }
+table-data-pilot-members =
+  element table:data-pilot-members { table-data-pilot-member* }
+table-data-pilot-member =
+  element table:data-pilot-member {
+    table-data-pilot-member-attlist, empty
+  }
+table-data-pilot-member-attlist =
+  attribute table:name { \string }
+  & attribute table:display { boolean }?
+  & attribute table:show-details { boolean }?
+table-data-pilot-display-info =
+  element table:data-pilot-display-info {
+    table-data-pilot-display-info-attlist, empty
+  }
+table-data-pilot-display-info-attlist =
+  attribute table:enabled { boolean }
+  & attribute table:data-field { \string }
+  & attribute table:member-count { nonNegativeInteger }
+  & attribute table:display-member-mode { "from-top" | "from-bottom" }
+table-data-pilot-sort-info =
+  element table:data-pilot-sort-info {
+    table-data-pilot-sort-info-attlist, empty
+  }
+table-data-pilot-sort-info-attlist =
+  ((attribute table:sort-mode { "data" },
+    attribute table:data-field { \string })
+   | attribute table:sort-mode { "none" | "manual" | "name" })
+  & attribute table:order { "ascending" | "descending" }
+table-data-pilot-layout-info =
+  element table:data-pilot-layout-info {
+    table-data-pilot-layout-info-attlist, empty
+  }
+table-data-pilot-layout-info-attlist =
+  attribute table:layout-mode {
+    "tabular-layout"
+    | "outline-subtotals-top"
+    | "outline-subtotals-bottom"
+  }
+  & attribute table:add-empty-lines { boolean }
+table-data-pilot-field-reference =
+  element table:data-pilot-field-reference {
+    table-data-pilot-field-reference-attlist
+  }
+table-data-pilot-field-reference-attlist =
+  attribute table:field-name { \string }
+  & ((attribute table:member-type { "named" },
+      attribute table:member-name { \string })
+     | attribute table:member-type { "previous" | "next" })
+  & attribute table:type {
+      "none"
+      | "member-difference"
+      | "member-percentage"
+      | "member-percentage-difference"
+      | "running-total"
+      | "row-percentage"
+      | "column-percentage"
+      | "total-percentage"
+      | "index"
+    }
+table-data-pilot-groups =
+  element table:data-pilot-groups {
+    table-data-pilot-groups-attlist, table-data-pilot-group+
+  }
+table-data-pilot-groups-attlist =
+  attribute table:source-field-name { \string }
+  & (attribute table:date-start { dateOrDateTime | "auto" }
+     | attribute table:start { double | "auto" })
+  & (attribute table:date-end { dateOrDateTime | "auto" }
+     | attribute table:end { double | "auto" })
+  & attribute table:step { double }
+  & attribute table:grouped-by {
+      "seconds"
+      | "minutes"
+      | "hours"
+      | "days"
+      | "months"
+      | "quarters"
+      | "years"
+    }
+table-data-pilot-group =
+  element table:data-pilot-group {
+    table-data-pilot-group-attlist, table-data-pilot-group-member+
+  }
+table-data-pilot-group-attlist = attribute table:name { \string }
+table-data-pilot-group-member =
+  element table:data-pilot-group-member {
+    table-data-pilot-group-member-attlist
+  }
+table-data-pilot-group-member-attlist = attribute table:name { \string }
+table-consolidation =
+  element table:consolidation { table-consolidation-attlist, empty }
+table-consolidation-attlist =
+  attribute table:function {
+    "average"
+    | "count"
+    | "countnums"
+    | "max"
+    | "min"
+    | "product"
+    | "stdev"
+    | "stdevp"
+    | "sum"
+    | "var"
+    | "varp"
+    | \string
+  }
+  & attribute table:source-cell-range-addresses { cellRangeAddressList }
+  & attribute table:target-cell-address { cellAddress }
+  & attribute table:use-labels { "none" | "row" | "column" | "both" }?
+  & attribute table:link-to-source-data { boolean }?
+table-dde-links = element table:dde-links { table-dde-link+ }
+table-tracked-changes =
+  element table:tracked-changes {
+    table-tracked-changes-attlist,
+    (table-cell-content-change
+     | table-insertion
+     | table-deletion
+     | table-movement)*
+  }
+table-tracked-changes-attlist =
+  attribute table:track-changes { boolean }?
+table-insertion =
+  element table:insertion {
+    table-insertion-attlist,
+    common-table-change-attlist,
+    office-change-info,
+    table-dependencies?,
+    table-deletions?
+  }
+table-insertion-attlist =
+  attribute table:type { "row" | "column" | "table" }
+  & attribute table:position { integer }
+  & attribute table:count { positiveInteger }?
+  & attribute table:table { integer }?
+table-dependencies = element table:dependencies { table-dependency+ }
+table-dependency =
+  element table:dependency {
+    attribute table:id { \string },
+    empty
+  }
+table-deletions =
+  element table:deletions {
+    (table-cell-content-deletion | table-change-deletion)+
+  }
+table-cell-content-deletion =
+  element table:cell-content-deletion {
+    attribute table:id { \string }?,
+    table-cell-address?,
+    table-change-track-table-cell?
+  }
+table-change-deletion =
+  element table:change-deletion {
+    attribute table:id { \string }?,
+    empty
+  }
+table-deletion =
+  element table:deletion {
+    table-deletion-attlist,
+    common-table-change-attlist,
+    office-change-info,
+    table-dependencies?,
+    table-deletions?,
+    table-cut-offs?
+  }
+table-deletion-attlist =
+  attribute table:type { "row" | "column" | "table" }
+  & attribute table:position { integer }
+  & attribute table:table { integer }?
+  & attribute table:multi-deletion-spanned { integer }?
+table-cut-offs =
+  element table:cut-offs {
+    table-movement-cut-off+
+    | (table-insertion-cut-off, table-movement-cut-off*)
+  }
+table-insertion-cut-off =
+  element table:insertion-cut-off {
+    table-insertion-cut-off-attlist, empty
+  }
+table-insertion-cut-off-attlist =
+  attribute table:id { \string }
+  & attribute table:position { integer }
+table-movement-cut-off =
+  element table:movement-cut-off {
+    table-movement-cut-off-attlist, empty
+  }
+table-movement-cut-off-attlist =
+  attribute table:position { integer }
+  | (attribute table:start-position { integer },
+     attribute table:end-position { integer })
+table-movement =
+  element table:movement {
+    common-table-change-attlist,
+    table-source-range-address,
+    table-target-range-address,
+    office-change-info,
+    table-dependencies?,
+    table-deletions?
+  }
+table-source-range-address =
+  element table:source-range-address {
+    common-table-range-attlist, empty
+  }
+table-target-range-address =
+  element table:target-range-address {
+    common-table-range-attlist, empty
+  }
+common-table-range-attlist =
+  common-table-cell-address-attlist
+  | common-table-cell-range-address-attlist
+common-table-cell-address-attlist =
+  attribute table:column { integer },
+  attribute table:row { integer },
+  attribute table:table { integer }
+common-table-cell-range-address-attlist =
+  attribute table:start-column { integer },
+  attribute table:start-row { integer },
+  attribute table:start-table { integer },
+  attribute table:end-column { integer },
+  attribute table:end-row { integer },
+  attribute table:end-table { integer }
+table-change-track-table-cell =
+  element table:change-track-table-cell {
+    table-change-track-table-cell-attlist, text-p*
+  }
+table-change-track-table-cell-attlist =
+  attribute table:cell-address { cellAddress }?
+  & attribute table:matrix-covered { boolean }?
+  & attribute table:formula { \string }?
+  & attribute table:number-matrix-columns-spanned { positiveInteger }?
+  & attribute table:number-matrix-rows-spanned { positiveInteger }?
+  & common-value-and-type-attlist?
+table-cell-content-change =
+  element table:cell-content-change {
+    common-table-change-attlist,
+    table-cell-address,
+    office-change-info,
+    table-dependencies?,
+    table-deletions?,
+    table-previous
+  }
+table-cell-address =
+  element table:cell-address {
+    common-table-cell-address-attlist, empty
+  }
+table-previous =
+  element table:previous {
+    attribute table:id { \string }?,
+    table-change-track-table-cell
+  }
+common-table-change-attlist =
+  attribute table:id { \string }
+  & attribute table:acceptance-state {
+      "accepted" | "rejected" | "pending"
+    }?
+  & attribute table:rejecting-change-id { \string }?
+style-handout-master =
+  element style:handout-master {
+    common-presentation-header-footer-attlist,
+    style-handout-master-attlist,
+    shape*
+  }
+style-handout-master-attlist =
+  attribute presentation:presentation-page-layout-name { styleNameRef }?
+  & attribute style:page-layout-name { styleNameRef }
+  & attribute draw:style-name { styleNameRef }?
+draw-layer-set = element draw:layer-set { draw-layer* }
+draw-layer =
+  element draw:layer { draw-layer-attlist, svg-title?, svg-desc? }
+draw-layer-attlist =
+  attribute draw:name { \string }
+  & attribute draw:protected { boolean }?
+  & attribute draw:display { "always" | "screen" | "printer" | "none" }?
+draw-page =
+  element draw:page {
+    common-presentation-header-footer-attlist,
+    draw-page-attlist,
+    svg-title?,
+    svg-desc?,
+    draw-layer-set?,
+    office-forms?,
+    shape*,
+    (presentation-animations | animation-element)?,
+    presentation-notes?
+  }
+draw-page-attlist =
+  attribute draw:name { \string }?
+  & attribute draw:style-name { styleNameRef }?
+  & attribute draw:master-page-name { styleNameRef }
+  & attribute presentation:presentation-page-layout-name {
+      styleNameRef
+    }?
+  & (xml-id,
+     attribute draw:id { NCName }?)?
+  & attribute draw:nav-order { IDREFS }?
+common-presentation-header-footer-attlist =
+  attribute presentation:use-header-name { \string }?
+  & attribute presentation:use-footer-name { \string }?
+  & attribute presentation:use-date-time-name { \string }?
+shape = shape-instance | draw-a
+shape-instance =
+  draw-rect
+  | draw-line
+  | draw-polyline
+  | draw-polygon
+  | draw-regular-polygon
+  | draw-path
+  | draw-circle
+  | draw-ellipse
+  | draw-g
+  | draw-page-thumbnail
+  | draw-frame
+  | draw-measure
+  | draw-caption
+  | draw-connector
+  | draw-control
+  | dr3d-scene
+  | draw-custom-shape
+draw-rect =
+  element draw:rect {
+    draw-rect-attlist,
+    common-draw-position-attlist,
+    common-draw-size-attlist,
+    common-draw-shape-with-text-and-styles-attlist,
+    common-draw-caption-id-attlist,
+    svg-title?,
+    svg-desc?,
+    office-event-listeners?,
+    draw-glue-point*,
+    draw-text
+  }
+draw-rect-attlist =
+  attribute draw:corner-radius { nonNegativeLength }?
+  | (attribute svg:rx { nonNegativeLength }?,
+     attribute svg:ry { nonNegativeLength }?)
+draw-line =
+  element draw:line {
+    draw-line-attlist,
+    common-draw-shape-with-text-and-styles-attlist,
+    common-draw-caption-id-attlist,
+    svg-title?,
+    svg-desc?,
+    office-event-listeners?,
+    draw-glue-point*,
+    draw-text
+  }
+draw-line-attlist =
+  attribute svg:x1 { coordinate }
+  & attribute svg:y1 { coordinate }
+  & attribute svg:x2 { coordinate }
+  & attribute svg:y2 { coordinate }
+draw-polyline =
+  element draw:polyline {
+    common-draw-points-attlist,
+    common-draw-position-attlist,
+    common-draw-size-attlist,
+    common-draw-viewbox-attlist,
+    common-draw-shape-with-text-and-styles-attlist,
+    common-draw-caption-id-attlist,
+    svg-title?,
+    svg-desc?,
+    office-event-listeners?,
+    draw-glue-point*,
+    draw-text
+  }
+common-draw-points-attlist = attribute draw:points { points }
+draw-polygon =
+  element draw:polygon {
+    common-draw-points-attlist,
+    common-draw-position-attlist,
+    common-draw-size-attlist,
+    common-draw-viewbox-attlist,
+    common-draw-shape-with-text-and-styles-attlist,
+    common-draw-caption-id-attlist,
+    svg-title?,
+    svg-desc?,
+    office-event-listeners?,
+    draw-glue-point*,
+    draw-text
+  }
+draw-regular-polygon =
+  element draw:regular-polygon {
+    draw-regular-polygon-attlist,
+    common-draw-position-attlist,
+    common-draw-size-attlist,
+    common-draw-shape-with-text-and-styles-attlist,
+    common-draw-caption-id-attlist,
+    svg-title?,
+    svg-desc?,
+    office-event-listeners?,
+    draw-glue-point*,
+    draw-text
+  }
+draw-regular-polygon-attlist =
+  (attribute draw:concave { "false" }
+   | (attribute draw:concave { "true" },
+      draw-regular-polygon-sharpness-attlist))
+  & attribute draw:corners { positiveInteger }
+draw-regular-polygon-sharpness-attlist =
+  attribute draw:sharpness { percent }
+draw-path =
+  element draw:path {
+    common-draw-path-data-attlist,
+    common-draw-position-attlist,
+    common-draw-size-attlist,
+    common-draw-viewbox-attlist,
+    common-draw-shape-with-text-and-styles-attlist,
+    common-draw-caption-id-attlist,
+    svg-title?,
+    svg-desc?,
+    office-event-listeners?,
+    draw-glue-point*,
+    draw-text
+  }
+common-draw-path-data-attlist = attribute svg:d { pathData }
+draw-circle =
+  element draw:circle {
+    ((draw-circle-attlist, common-draw-circle-ellipse-pos-attlist)
+     | (common-draw-position-attlist, common-draw-size-attlist)),
+    common-draw-circle-ellipse-attlist,
+    common-draw-shape-with-text-and-styles-attlist,
+    common-draw-caption-id-attlist,
+    svg-title?,
+    svg-desc?,
+    office-event-listeners?,
+    draw-glue-point*,
+    draw-text
+  }
+common-draw-circle-ellipse-pos-attlist =
+  attribute svg:cx { coordinate },
+  attribute svg:cy { coordinate }
+draw-circle-attlist = attribute svg:r { length }
+common-draw-circle-ellipse-attlist =
+  attribute draw:kind { "full" | "section" | "cut" | "arc" }?
+  & attribute draw:start-angle { angle }?
+  & attribute draw:end-angle { angle }?
+draw-ellipse =
+  element draw:ellipse {
+    ((draw-ellipse-attlist, common-draw-circle-ellipse-pos-attlist)
+     | (common-draw-position-attlist, common-draw-size-attlist)),
+    common-draw-circle-ellipse-attlist,
+    common-draw-shape-with-text-and-styles-attlist,
+    common-draw-caption-id-attlist,
+    svg-title?,
+    svg-desc?,
+    office-event-listeners?,
+    draw-glue-point*,
+    draw-text
+  }
+draw-ellipse-attlist =
+  attribute svg:rx { length },
+  attribute svg:ry { length }
+draw-connector =
+  element draw:connector {
+    draw-connector-attlist,
+    common-draw-shape-with-text-and-styles-attlist,
+    common-draw-caption-id-attlist,
+    common-draw-viewbox-attlist,
+    svg-title?,
+    svg-desc?,
+    office-event-listeners?,
+    draw-glue-point*,
+    draw-text
+  }
+draw-connector-attlist =
+  attribute draw:type { "standard" | "lines" | "line" | "curve" }?
+  & (attribute svg:x1 { coordinate },
+     attribute svg:y1 { coordinate })?
+  & attribute draw:start-shape { IDREF }?
+  & attribute draw:start-glue-point { nonNegativeInteger }?
+  & (attribute svg:x2 { coordinate },
+     attribute svg:y2 { coordinate })?
+  & attribute draw:end-shape { IDREF }?
+  & attribute draw:end-glue-point { nonNegativeInteger }?
+  & attribute draw:line-skew {
+      list { length, (length, length?)? }
+    }?
+  & attribute svg:d { pathData }?
+draw-caption =
+  element draw:caption {
+    draw-caption-attlist,
+    common-draw-position-attlist,
+    common-draw-size-attlist,
+    common-draw-shape-with-text-and-styles-attlist,
+    common-draw-caption-id-attlist,
+    svg-title?,
+    svg-desc?,
+    office-event-listeners?,
+    draw-glue-point*,
+    draw-text
+  }
+draw-caption-attlist =
+  (attribute draw:caption-point-x { coordinate },
+   attribute draw:caption-point-y { coordinate })?
+  & attribute draw:corner-radius { nonNegativeLength }?
+draw-measure =
+  element draw:measure {
+    draw-measure-attlist,
+    common-draw-shape-with-text-and-styles-attlist,
+    common-draw-caption-id-attlist,
+    svg-title?,
+    svg-desc?,
+    office-event-listeners?,
+    draw-glue-point*,
+    draw-text
+  }
+draw-measure-attlist =
+  attribute svg:x1 { coordinate }
+  & attribute svg:y1 { coordinate }
+  & attribute svg:x2 { coordinate }
+  & attribute svg:y2 { coordinate }
+draw-control =
+  element draw:control {
+    draw-control-attlist,
+    common-draw-position-attlist,
+    common-draw-size-attlist,
+    common-draw-shape-with-text-and-styles-attlist,
+    common-draw-caption-id-attlist,
+    svg-title?,
+    svg-desc?,
+    draw-glue-point*
+  }
+draw-control-attlist = attribute draw:control { IDREF }
+draw-page-thumbnail =
+  element draw:page-thumbnail {
+    draw-page-thumbnail-attlist,
+    common-draw-position-attlist,
+    common-draw-size-attlist,
+    presentation-shape-attlist,
+    common-draw-shape-with-styles-attlist,
+    common-draw-caption-id-attlist,
+    svg-title?,
+    svg-desc?
+  }
+draw-page-thumbnail-attlist =
+  attribute draw:page-number { positiveInteger }?
+draw-g =
+  element draw:g {
+    draw-g-attlist,
+    common-draw-z-index-attlist,
+    common-draw-name-attlist,
+    common-draw-id-attlist,
+    common-draw-style-name-attlist,
+    common-text-spreadsheet-shape-attlist,
+    common-draw-caption-id-attlist,
+    svg-title?,
+    svg-desc?,
+    office-event-listeners?,
+    draw-glue-point*,
+    shape*
+  }
+draw-g-attlist = attribute svg:y { coordinate }?
+common-draw-name-attlist = attribute draw:name { \string }?
+common-draw-caption-id-attlist = attribute draw:caption-id { IDREF }?
+common-draw-position-attlist =
+  attribute svg:x { coordinate }?,
+  attribute svg:y { coordinate }?
+common-draw-size-attlist =
+  attribute svg:width { length }?,
+  attribute svg:height { length }?
+common-draw-transform-attlist = attribute draw:transform { \string }?
+common-draw-viewbox-attlist =
+  attribute svg:viewBox {
+    list { integer, integer, integer, integer }
+  }
+common-draw-style-name-attlist =
+  (attribute draw:style-name { styleNameRef }?,
+   attribute draw:class-names { styleNameRefs }?)
+  | (attribute presentation:style-name { styleNameRef }?,
+     attribute presentation:class-names { styleNameRefs }?)
+common-draw-text-style-name-attlist =
+  attribute draw:text-style-name { styleNameRef }?
+common-draw-layer-name-attlist = attribute draw:layer { \string }?
+common-draw-id-attlist =
+  (xml-id,
+   attribute draw:id { NCName }?)?
+common-draw-z-index-attlist =
+  attribute draw:z-index { nonNegativeInteger }?
+common-text-spreadsheet-shape-attlist =
+  attribute table:end-cell-address { cellAddress }?
+  & attribute table:end-x { coordinate }?
+  & attribute table:end-y { coordinate }?
+  & attribute table:table-background { boolean }?
+  & common-text-anchor-attlist
+common-text-anchor-attlist =
+  attribute text:anchor-type {
+    "page" | "frame" | "paragraph" | "char" | "as-char"
+  }?
+  & attribute text:anchor-page-number { positiveInteger }?
+draw-text = (text-p | text-list)*
+common-draw-shape-with-styles-attlist =
+  common-draw-z-index-attlist,
+  common-draw-id-attlist,
+  common-draw-layer-name-attlist,
+  common-draw-style-name-attlist,
+  common-draw-transform-attlist,
+  common-draw-name-attlist,
+  common-text-spreadsheet-shape-attlist
+common-draw-shape-with-text-and-styles-attlist =
+  common-draw-shape-with-styles-attlist,
+  common-draw-text-style-name-attlist
+draw-glue-point =
+  element draw:glue-point { draw-glue-point-attlist, empty }
+draw-glue-point-attlist =
+  attribute draw:id { nonNegativeInteger }
+  & attribute svg:x { distance | percent }
+  & attribute svg:y { distance | percent }
+  & attribute draw:align {
+      "top-left"
+      | "top"
+      | "top-right"
+      | "left"
+      | "center"
+      | "right"
+      | "bottom-left"
+      | "bottom-right"
+    }?
+  & attribute draw:escape-direction {
+      "auto"
+      | "left"
+      | "right"
+      | "up"
+      | "down"
+      | "horizontal"
+      | "vertical"
+    }
+svg-title = element svg:title { text }
+svg-desc = element svg:desc { text }
+draw-frame =
+  element draw:frame {
+    common-draw-shape-with-text-and-styles-attlist,
+    common-draw-position-attlist,
+    common-draw-rel-size-attlist,
+    common-draw-caption-id-attlist,
+    presentation-shape-attlist,
+    draw-frame-attlist,
+    (draw-text-box
+     | draw-image
+     | draw-object
+     | draw-object-ole
+     | draw-applet
+     | draw-floating-frame
+     | draw-plugin
+     | table-table)*,
+    office-event-listeners?,
+    draw-glue-point*,
+    draw-image-map?,
+    svg-title?,
+    svg-desc?,
+    (draw-contour-polygon | draw-contour-path)?
+  }
+common-draw-rel-size-attlist =
+  common-draw-size-attlist,
+  attribute style:rel-width { percent | "scale" | "scale-min" }?,
+  attribute style:rel-height { percent | "scale" | "scale-min" }?
+draw-frame-attlist = attribute draw:copy-of { \string }?
+draw-text-box =
+  element draw:text-box { draw-text-box-attlist, text-content* }
+draw-text-box-attlist =
+  attribute draw:chain-next-name { \string }?
+  & attribute draw:corner-radius { nonNegativeLength }?
+  & attribute fo:min-height { length | percent }?
+  & attribute fo:min-width { length | percent }?
+  & attribute fo:max-height { length | percent }?
+  & attribute fo:max-width { length | percent }?
+  & (xml-id,
+     attribute text:id { NCName }?)?
+draw-image =
+  element draw:image {
+    draw-image-attlist,
+    (common-draw-data-attlist | office-binary-data),
+    draw-text
+  }
+common-draw-data-attlist =
+  attribute xlink:type { "simple" },
+  attribute xlink:href { anyIRI },
+  attribute xlink:show { "embed" }?,
+  attribute xlink:actuate { "onLoad" }?
+office-binary-data = element office:binary-data { base64Binary }
+draw-image-attlist =
+  attribute draw:filter-name { \string }?
+  & xml-id?
+draw-object =
+  element draw:object {
+    draw-object-attlist,
+    (common-draw-data-attlist | office-document | math-math)
+  }
+draw-object-ole =
+  element draw:object-ole {
+    draw-object-ole-attlist,
+    (common-draw-data-attlist | office-binary-data)
+  }
+draw-object-attlist =
+  attribute draw:notify-on-update-of-ranges {
+    cellRangeAddressList | \string
+  }?
+  & xml-id?
+draw-object-ole-attlist =
+  attribute draw:class-id { \string }?
+  & xml-id?
+draw-applet =
+  element draw:applet {
+    draw-applet-attlist, common-draw-data-attlist?, draw-param*
+  }
+draw-applet-attlist =
+  attribute draw:code { \string }?
+  & attribute draw:object { \string }?
+  & attribute draw:archive { \string }?
+  & attribute draw:may-script { boolean }?
+  & xml-id?
+draw-plugin =
+  element draw:plugin {
+    draw-plugin-attlist, common-draw-data-attlist, draw-param*
+  }
+draw-plugin-attlist =
+  attribute draw:mime-type { \string }?
+  & xml-id?
+draw-param = element draw:param { draw-param-attlist, empty }
+draw-param-attlist =
+  attribute draw:name { \string }?
+  & attribute draw:value { \string }?
+draw-floating-frame =
+  element draw:floating-frame {
+    draw-floating-frame-attlist, common-draw-data-attlist
+  }
+draw-floating-frame-attlist =
+  attribute draw:frame-name { \string }?
+  & xml-id?
+draw-contour-polygon =
+  element draw:contour-polygon {
+    common-contour-attlist,
+    common-draw-size-attlist,
+    common-draw-viewbox-attlist,
+    common-draw-points-attlist,
+    empty
+  }
+draw-contour-path =
+  element draw:contour-path {
+    common-contour-attlist,
+    common-draw-size-attlist,
+    common-draw-viewbox-attlist,
+    common-draw-path-data-attlist,
+    empty
+  }
+common-contour-attlist = attribute draw:recreate-on-edit { boolean }
+draw-a = element draw:a { draw-a-attlist, shape-instance }
+draw-a-attlist =
+  attribute xlink:type { "simple" }
+  & attribute xlink:href { anyIRI }
+  & attribute xlink:actuate { "onRequest" }?
+  & attribute office:target-frame-name { targetFrameName }?
+  & attribute xlink:show { "new" | "replace" }?
+  & attribute office:name { \string }?
+  & attribute office:title { \string }?
+  & attribute office:server-map { boolean }?
+  & xml-id?
+draw-image-map =
+  element draw:image-map {
+    (draw-area-rectangle | draw-area-circle | draw-area-polygon)*
+  }
+draw-area-rectangle =
+  element draw:area-rectangle {
+    common-draw-area-attlist,
+    attribute svg:x { coordinate },
+    attribute svg:y { coordinate },
+    attribute svg:width { length },
+    attribute svg:height { length },
+    svg-title?,
+    svg-desc?,
+    office-event-listeners?
+  }
+draw-area-circle =
+  element draw:area-circle {
+    common-draw-area-attlist,
+    attribute svg:cx { coordinate },
+    attribute svg:cy { coordinate },
+    attribute svg:r { length },
+    svg-title?,
+    svg-desc?,
+    office-event-listeners?
+  }
+draw-area-polygon =
+  element draw:area-polygon {
+    common-draw-area-attlist,
+    attribute svg:x { coordinate },
+    attribute svg:y { coordinate },
+    attribute svg:width { length },
+    attribute svg:height { length },
+    common-draw-viewbox-attlist,
+    common-draw-points-attlist,
+    svg-title?,
+    svg-desc?,
+    office-event-listeners?
+  }
+common-draw-area-attlist =
+  (attribute xlink:type { "simple" },
+   attribute xlink:href { anyIRI },
+   attribute office:target-frame-name { targetFrameName }?,
+   attribute xlink:show { "new" | "replace" }?)?
+  & attribute office:name { \string }?
+  & attribute draw:nohref { "nohref" }?
+dr3d-scene =
+  element dr3d:scene {
+    dr3d-scene-attlist,
+    common-draw-position-attlist,
+    common-draw-size-attlist,
+    common-draw-style-name-attlist,
+    common-draw-z-index-attlist,
+    common-draw-id-attlist,
+    common-draw-layer-name-attlist,
+    common-text-spreadsheet-shape-attlist,
+    common-dr3d-transform-attlist,
+    common-draw-caption-id-attlist,
+    svg-title?,
+    svg-desc?,
+    dr3d-light*,
+    shapes3d*,
+    draw-glue-point*
+  }
+shapes3d =
+  dr3d-scene | dr3d-extrude | dr3d-sphere | dr3d-rotate | dr3d-cube
+dr3d-scene-attlist =
+  attribute dr3d:vrp { vector3D }?
+  & attribute dr3d:vpn { vector3D }?
+  & attribute dr3d:vup { vector3D }?
+  & attribute dr3d:projection { "parallel" | "perspective" }?
+  & attribute dr3d:distance { length }?
+  & attribute dr3d:focal-length { length }?
+  & attribute dr3d:shadow-slant { angle }?
+  & attribute dr3d:shade-mode {
+      "flat" | "phong" | "gouraud" | "draft"
+    }?
+  & attribute dr3d:ambient-color { color }?
+  & attribute dr3d:lighting-mode { boolean }?
+common-dr3d-transform-attlist = attribute dr3d:transform { \string }?
+dr3d-light = element dr3d:light { dr3d-light-attlist, empty }
+dr3d-light-attlist =
+  attribute dr3d:diffuse-color { color }?
+  & attribute dr3d:direction { vector3D }
+  & attribute dr3d:enabled { boolean }?
+  & attribute dr3d:specular { boolean }?
+dr3d-cube =
+  element dr3d:cube {
+    dr3d-cube-attlist,
+    common-draw-z-index-attlist,
+    common-draw-id-attlist,
+    common-draw-layer-name-attlist,
+    common-draw-style-name-attlist,
+    common-dr3d-transform-attlist,
+    empty
+  }
+dr3d-cube-attlist =
+  attribute dr3d:min-edge { vector3D }?,
+  attribute dr3d:max-edge { vector3D }?
+dr3d-sphere =
+  element dr3d:sphere {
+    dr3d-sphere-attlist,
+    common-draw-z-index-attlist,
+    common-draw-id-attlist,
+    common-draw-layer-name-attlist,
+    common-draw-style-name-attlist,
+    common-dr3d-transform-attlist,
+    empty
+  }
+dr3d-sphere-attlist =
+  attribute dr3d:center { vector3D }?
+  & attribute dr3d:size { vector3D }?
+dr3d-extrude =
+  element dr3d:extrude {
+    common-draw-path-data-attlist,
+    common-draw-viewbox-attlist,
+    common-draw-id-attlist,
+    common-draw-z-index-attlist,
+    common-draw-layer-name-attlist,
+    common-draw-style-name-attlist,
+    common-dr3d-transform-attlist,
+    empty
+  }
+dr3d-rotate =
+  element dr3d:rotate {
+    common-draw-viewbox-attlist,
+    common-draw-path-data-attlist,
+    common-draw-z-index-attlist,
+    common-draw-id-attlist,
+    common-draw-layer-name-attlist,
+    common-draw-style-name-attlist,
+    common-dr3d-transform-attlist,
+    empty
+  }
+draw-custom-shape =
+  element draw:custom-shape {
+    draw-custom-shape-attlist,
+    common-draw-position-attlist,
+    common-draw-size-attlist,
+    common-draw-shape-with-text-and-styles-attlist,
+    common-draw-caption-id-attlist,
+    svg-title?,
+    svg-desc?,
+    office-event-listeners?,
+    draw-glue-point*,
+    draw-text,
+    draw-enhanced-geometry?
+  }
+draw-custom-shape-attlist =
+  attribute draw:engine { namespacedToken }?
+  & attribute draw:data { \string }?
+draw-enhanced-geometry =
+  element draw:enhanced-geometry {
+    draw-enhanced-geometry-attlist, draw-equation*, draw-handle*
+  }
+draw-enhanced-geometry-attlist =
+  attribute draw:type { custom-shape-type }?
+  & attribute svg:viewBox {
+      list { integer, integer, integer, integer }
+    }?
+  & attribute draw:mirror-vertical { boolean }?
+  & attribute draw:mirror-horizontal { boolean }?
+  & attribute draw:text-rotate-angle { angle }?
+  & attribute draw:extrusion-allowed { boolean }?
+  & attribute draw:text-path-allowed { boolean }?
+  & attribute draw:concentric-gradient-fill-allowed { boolean }?
+  & attribute draw:extrusion { boolean }?
+  & attribute draw:extrusion-brightness { zeroToHundredPercent }?
+  & attribute draw:extrusion-depth {
+      list { length, double }
+    }?
+  & attribute draw:extrusion-diffusion { percent }?
+  & attribute draw:extrusion-number-of-line-segments { integer }?
+  & attribute draw:extrusion-light-face { boolean }?
+  & attribute draw:extrusion-first-light-harsh { boolean }?
+  & attribute draw:extrusion-second-light-harsh { boolean }?
+  & attribute draw:extrusion-first-light-level { zeroToHundredPercent }?
+  & attribute draw:extrusion-second-light-level {
+      zeroToHundredPercent
+    }?
+  & attribute draw:extrusion-first-light-direction { vector3D }?
+  & attribute draw:extrusion-second-light-direction { vector3D }?
+  & attribute draw:extrusion-metal { boolean }?
+  & attribute dr3d:shade-mode {
+      "flat" | "phong" | "gouraud" | "draft"
+    }?
+  & attribute draw:extrusion-rotation-angle {
+      list { angle, angle }
+    }?
+  & attribute draw:extrusion-rotation-center { vector3D }?
+  & attribute draw:extrusion-shininess { zeroToHundredPercent }?
+  & attribute draw:extrusion-skew {
+      list { double, angle }
+    }?
+  & attribute draw:extrusion-specularity { zeroToHundredPercent }?
+  & attribute dr3d:projection { "parallel" | "perspective" }?
+  & attribute draw:extrusion-viewpoint { point3D }?
+  & attribute draw:extrusion-origin {
+      list { extrusionOrigin, extrusionOrigin }
+    }?
+  & attribute draw:extrusion-color { boolean }?
+  & attribute draw:enhanced-path { \string }?
+  & attribute draw:path-stretchpoint-x { double }?
+  & attribute draw:path-stretchpoint-y { double }?
+  & attribute draw:text-areas { \string }?
+  & attribute draw:glue-points { \string }?
+  & attribute draw:glue-point-type {
+      "none" | "segments" | "rectangle"
+    }?
+  & attribute draw:glue-point-leaving-directions { \string }?
+  & attribute draw:text-path { boolean }?
+  & attribute draw:text-path-mode { "normal" | "path" | "shape" }?
+  & attribute draw:text-path-scale { "path" | "shape" }?
+  & attribute draw:text-path-same-letter-heights { boolean }?
+  & attribute draw:modifiers { \string }?
+custom-shape-type = "non-primitive" | \string
+point3D =
+  xsd:string {
+    pattern =
+      "\([ ]*-?([0-9]+(\.[0-9]*)?|\.[0-9]+)((cm)|(mm)|(in)|(pt)|(pc))([ ]+-?([0-9]+(\.[0-9]*)?|\.[0-9]+)((cm)|(mm)|(in)|(pt)|(pc))){2}[ ]*\)"
+  }
+extrusionOrigin =
+  xsd:double { minInclusive = "-0.5" maxInclusive = "0.5" }
+draw-equation = element draw:equation { draw-equation-attlist, empty }
+draw-equation-attlist =
+  attribute draw:name { \string }?
+  & attribute draw:formula { \string }?
+draw-handle = element draw:handle { draw-handle-attlist, empty }
+draw-handle-attlist =
+  attribute draw:handle-mirror-vertical { boolean }?
+  & attribute draw:handle-mirror-horizontal { boolean }?
+  & attribute draw:handle-switched { boolean }?
+  & attribute draw:handle-position { \string }
+  & attribute draw:handle-range-x-minimum { \string }?
+  & attribute draw:handle-range-x-maximum { \string }?
+  & attribute draw:handle-range-y-minimum { \string }?
+  & attribute draw:handle-range-y-maximum { \string }?
+  & attribute draw:handle-polar { \string }?
+  & attribute draw:handle-radius-range-minimum { \string }?
+  & attribute draw:handle-radius-range-maximum { \string }?
+presentation-shape-attlist =
+  attribute presentation:class { presentation-classes }?
+  & attribute presentation:placeholder { boolean }?
+  & attribute presentation:user-transformed { boolean }?
+presentation-classes =
+  "title"
+  | "outline"
+  | "subtitle"
+  | "text"
+  | "graphic"
+  | "object"
+  | "chart"
+  | "table"
+  | "orgchart"
+  | "page"
+  | "notes"
+  | "handout"
+  | "header"
+  | "footer"
+  | "date-time"
+  | "page-number"
+presentation-animations =
+  element presentation:animations {
+    (presentation-animation-elements | presentation-animation-group)*
+  }
+presentation-animation-elements =
+  presentation-show-shape
+  | presentation-show-text
+  | presentation-hide-shape
+  | presentation-hide-text
+  | presentation-dim
+  | presentation-play
+presentation-sound =
+  element presentation:sound {
+    presentation-sound-attlist,
+    attribute xlink:type { "simple" },
+    attribute xlink:href { anyIRI },
+    attribute xlink:actuate { "onRequest" }?,
+    attribute xlink:show { "new" | "replace" }?,
+    empty
+  }
+presentation-sound-attlist =
+  attribute presentation:play-full { boolean }?
+  & xml-id?
+presentation-show-shape =
+  element presentation:show-shape {
+    common-presentation-effect-attlist, presentation-sound?
+  }
+common-presentation-effect-attlist =
+  attribute draw:shape-id { IDREF }
+  & attribute presentation:effect { presentationEffects }?
+  & attribute presentation:direction { presentationEffectDirections }?
+  & attribute presentation:speed { presentationSpeeds }?
+  & attribute presentation:delay { duration }?
+  & attribute presentation:start-scale { percent }?
+  & attribute presentation:path-id { \string }?
+presentationEffects =
+  "none"
+  | "fade"
+  | "move"
+  | "stripes"
+  | "open"
+  | "close"
+  | "dissolve"
+  | "wavyline"
+  | "random"
+  | "lines"
+  | "laser"
+  | "appear"
+  | "hide"
+  | "move-short"
+  | "checkerboard"
+  | "rotate"
+  | "stretch"
+presentationEffectDirections =
+  "none"
+  | "from-left"
+  | "from-top"
+  | "from-right"
+  | "from-bottom"
+  | "from-center"
+  | "from-upper-left"
+  | "from-upper-right"
+  | "from-lower-left"
+  | "from-lower-right"
+  | "to-left"
+  | "to-top"
+  | "to-right"
+  | "to-bottom"
+  | "to-upper-left"
+  | "to-upper-right"
+  | "to-lower-right"
+  | "to-lower-left"
+  | "path"
+  | "spiral-inward-left"
+  | "spiral-inward-right"
+  | "spiral-outward-left"
+  | "spiral-outward-right"
+  | "vertical"
+  | "horizontal"
+  | "to-center"
+  | "clockwise"
+  | "counter-clockwise"
+presentationSpeeds = "slow" | "medium" | "fast"
+presentation-show-text =
+  element presentation:show-text {
+    common-presentation-effect-attlist, presentation-sound?
+  }
+presentation-hide-shape =
+  element presentation:hide-shape {
+    common-presentation-effect-attlist, presentation-sound?
+  }
+presentation-hide-text =
+  element presentation:hide-text {
+    common-presentation-effect-attlist, presentation-sound?
+  }
+presentation-dim =
+  element presentation:dim {
+    presentation-dim-attlist, presentation-sound?
+  }
+presentation-dim-attlist =
+  attribute draw:shape-id { IDREF }
+  & attribute draw:color { color }
+presentation-play =
+  element presentation:play { presentation-play-attlist, empty }
+presentation-play-attlist =
+  attribute draw:shape-id { IDREF },
+  attribute presentation:speed { presentationSpeeds }?
+presentation-animation-group =
+  element presentation:animation-group {
+    presentation-animation-elements*
+  }
+common-anim-attlist =
+  attribute presentation:node-type {
+    "default"
+    | "on-click"
+    | "with-previous"
+    | "after-previous"
+    | "timing-root"
+    | "main-sequence"
+    | "interactive-sequence"
+  }?
+  & attribute presentation:preset-id { \string }?
+  & attribute presentation:preset-sub-type { \string }?
+  & attribute presentation:preset-class {
+      "custom"
+      | "entrance"
+      | "exit"
+      | "emphasis"
+      | "motion-path"
+      | "ole-action"
+      | "media-call"
+    }?
+  & attribute presentation:master-element { IDREF }?
+  & attribute presentation:group-id { \string }?
+  & (xml-id,
+     attribute anim:id { NCName }?)?
+presentation-event-listener =
+  element presentation:event-listener {
+    presentation-event-listener-attlist, presentation-sound?
+  }
+presentation-event-listener-attlist =
+  attribute script:event-name { \string }
+  & attribute presentation:action {
+      "none"
+      | "previous-page"
+      | "next-page"
+      | "first-page"
+      | "last-page"
+      | "hide"
+      | "stop"
+      | "execute"
+      | "show"
+      | "verb"
+      | "fade-out"
+      | "sound"
+      | "last-visited-page"
+    }
+  & attribute presentation:effect { presentationEffects }?
+  & attribute presentation:direction { presentationEffectDirections }?
+  & attribute presentation:speed { presentationSpeeds }?
+  & attribute presentation:start-scale { percent }?
+  & (attribute xlink:type { "simple" },
+     attribute xlink:href { anyIRI },
+     attribute xlink:show { "embed" }?,
+     attribute xlink:actuate { "onRequest" }?)?
+  & attribute presentation:verb { nonNegativeInteger }?
+presentation-decls = presentation-decl*
+presentation-decl =
+  element presentation:header-decl {
+    presentation-header-decl-attlist, text
+  }
+  | element presentation:footer-decl {
+      presentation-footer-decl-attlist, text
+    }
+  | element presentation:date-time-decl {
+      presentation-date-time-decl-attlist, text
+    }
+presentation-header-decl-attlist =
+  attribute presentation:name { \string }
+presentation-footer-decl-attlist =
+  attribute presentation:name { \string }
+presentation-date-time-decl-attlist =
+  attribute presentation:name { \string }
+  & attribute presentation:source { "fixed" | "current-date" }
+  & attribute style:data-style-name { styleNameRef }?
+presentation-settings =
+  element presentation:settings {
+    presentation-settings-attlist, presentation-show*
+  }?
+presentation-settings-attlist =
+  attribute presentation:start-page { \string }?
+  & attribute presentation:show { \string }?
+  & attribute presentation:full-screen { boolean }?
+  & attribute presentation:endless { boolean }?
+  & attribute presentation:pause { duration }?
+  & attribute presentation:show-logo { boolean }?
+  & attribute presentation:force-manual { boolean }?
+  & attribute presentation:mouse-visible { boolean }?
+  & attribute presentation:mouse-as-pen { boolean }?
+  & attribute presentation:start-with-navigator { boolean }?
+  & attribute presentation:animations { "enabled" | "disabled" }?
+  & attribute presentation:transition-on-click {
+      "enabled" | "disabled"
+    }?
+  & attribute presentation:stay-on-top { boolean }?
+  & attribute presentation:show-end-of-presentation-slide { boolean }?
+presentation-show =
+  element presentation:show { presentation-show-attlist, empty }
+presentation-show-attlist =
+  attribute presentation:name { \string }
+  & attribute presentation:pages { \string }
+chart-chart =
+  element chart:chart {
+    chart-chart-attlist,
+    chart-title?,
+    chart-subtitle?,
+    chart-footer?,
+    chart-legend?,
+    chart-plot-area,
+    table-table?
+  }
+chart-chart-attlist =
+  attribute chart:class { namespacedToken }
+  & common-draw-size-attlist
+  & attribute chart:column-mapping { \string }?
+  & attribute chart:row-mapping { \string }?
+  & attribute chart:style-name { styleNameRef }?
+  & (attribute xlink:type { "simple" },
+     attribute xlink:href { anyIRI })?
+  & xml-id?
+chart-title = element chart:title { chart-title-attlist, text-p? }
+chart-title-attlist =
+  attribute table:cell-range { cellRangeAddressList }?
+  & common-draw-position-attlist
+  & attribute chart:style-name { styleNameRef }?
+chart-subtitle = element chart:subtitle { chart-title-attlist, text-p? }
+chart-footer = element chart:footer { chart-title-attlist, text-p? }
+chart-legend = element chart:legend { chart-legend-attlist, text-p? }
+chart-legend-attlist =
+  ((attribute chart:legend-position {
+      "start" | "end" | "top" | "bottom"
+    },
+    attribute chart:legend-align { "start" | "center" | "end" }?)
+   | attribute chart:legend-position {
+       "top-start" | "bottom-start" | "top-end" | "bottom-end"
+     }
+   | empty)
+  & common-draw-position-attlist
+  & (attribute style:legend-expansion { "wide" | "high" | "balanced" }
+     | (attribute style:legend-expansion { "custom" },
+        attribute style:legend-expansion-aspect-ratio { double })
+     | empty)
+  & attribute chart:style-name { styleNameRef }?
+chart-plot-area =
+  element chart:plot-area {
+    chart-plot-area-attlist,
+    dr3d-light*,
+    chart-axis*,
+    chart-series*,
+    chart-stock-gain-marker?,
+    chart-stock-loss-marker?,
+    chart-stock-range-line?,
+    chart-wall?,
+    chart-floor?
+  }
+chart-plot-area-attlist =
+  common-draw-position-attlist
+  & common-draw-size-attlist
+  & attribute chart:style-name { styleNameRef }?
+  & attribute table:cell-range-address { cellRangeAddressList }?
+  & attribute chart:data-source-has-labels {
+      "none" | "row" | "column" | "both"
+    }?
+  & dr3d-scene-attlist
+  & common-dr3d-transform-attlist
+  & xml-id?
+chart-wall = element chart:wall { chart-wall-attlist, empty }
+chart-wall-attlist =
+  attribute svg:width { length }?
+  & attribute chart:style-name { styleNameRef }?
+chart-floor = element chart:floor { chart-floor-attlist, empty }
+chart-floor-attlist =
+  attribute svg:width { length }?
+  & attribute chart:style-name { styleNameRef }?
+chart-axis =
+  element chart:axis {
+    chart-axis-attlist, chart-title?, chart-categories?, chart-grid*
+  }
+chart-axis-attlist =
+  attribute chart:dimension { chart-dimension }
+  & attribute chart:name { \string }?
+  & attribute chart:style-name { styleNameRef }?
+chart-dimension = "x" | "y" | "z"
+chart-categories =
+  element chart:categories {
+    attribute table:cell-range-address { cellRangeAddressList }?
+  }
+chart-grid = element chart:grid { chart-grid-attlist }
+chart-grid-attlist =
+  attribute chart:class { "major" | "minor" }?
+  & attribute chart:style-name { styleNameRef }?
+chart-series =
+  element chart:series {
+    chart-series-attlist,
+    chart-domain*,
+    chart-mean-value?,
+    chart-regression-curve*,
+    chart-error-indicator*,
+    chart-data-point*,
+    chart-data-label?
+  }
+chart-series-attlist =
+  attribute chart:values-cell-range-address { cellRangeAddressList }?
+  & attribute chart:label-cell-address { cellRangeAddressList }?
+  & attribute chart:class { namespacedToken }?
+  & attribute chart:attached-axis { \string }?
+  & attribute chart:style-name { styleNameRef }?
+  & xml-id?
+chart-domain =
+  element chart:domain {
+    attribute table:cell-range-address { cellRangeAddressList }?
+  }
+chart-data-point =
+  element chart:data-point {
+    chart-data-point-attlist, chart-data-label?
+  }
+chart-data-point-attlist =
+  attribute chart:repeated { positiveInteger }?
+  & attribute chart:style-name { styleNameRef }?
+  & xml-id?
+chart-data-label =
+  element chart:data-label { chart-data-label-attlist, text-p? }
+chart-data-label-attlist =
+  common-draw-position-attlist
+  & attribute chart:style-name { styleNameRef }?
+chart-mean-value =
+  element chart:mean-value { chart-mean-value-attlist, empty }
+chart-mean-value-attlist = attribute chart:style-name { styleNameRef }?
+chart-error-indicator =
+  element chart:error-indicator { chart-error-indicator-attlist, empty }
+chart-error-indicator-attlist =
+  attribute chart:style-name { styleNameRef }?
+  & attribute chart:dimension { chart-dimension }
+chart-regression-curve =
+  element chart:regression-curve {
+    chart-regression-curve-attlist, chart-equation?
+  }
+chart-regression-curve-attlist =
+  attribute chart:style-name { styleNameRef }?
+chart-equation =
+  element chart:equation { chart-equation-attlist, text-p? }
+chart-equation-attlist =
+  attribute chart:automatic-content { boolean }?
+  & attribute chart:display-r-square { boolean }?
+  & attribute chart:display-equation { boolean }?
+  & common-draw-position-attlist
+  & attribute chart:style-name { styleNameRef }?
+chart-stock-gain-marker =
+  element chart:stock-gain-marker { common-stock-marker-attlist }
+chart-stock-loss-marker =
+  element chart:stock-loss-marker { common-stock-marker-attlist }
+chart-stock-range-line =
+  element chart:stock-range-line { common-stock-marker-attlist }
+common-stock-marker-attlist =
+  attribute chart:style-name { styleNameRef }?
+office-database =
+  element office:database {
+    db-data-source,
+    db-forms?,
+    db-reports?,
+    db-queries?,
+    db-table-presentations?,
+    db-schema-definition?
+  }
+db-data-source =
+  element db:data-source {
+    db-data-source-attlist,
+    db-connection-data,
+    db-driver-settings?,
+    db-application-connection-settings?
+  }
+db-data-source-attlist = empty
+db-connection-data =
+  element db:connection-data {
+    db-connection-data-attlist,
+    (db-database-description | db-connection-resource),
+    db-login?
+  }
+db-connection-data-attlist = empty
+db-database-description =
+  element db:database-description {
+    db-database-description-attlist,
+    (db-file-based-database | db-server-database)
+  }
+db-database-description-attlist = empty
+db-file-based-database =
+  element db:file-based-database { db-file-based-database-attlist }
+db-file-based-database-attlist =
+  attribute xlink:type { "simple" }
+  & attribute xlink:href { anyIRI }
+  & attribute db:media-type { \string }
+  & attribute db:extension { \string }?
+db-server-database =
+  element db:server-database { db-server-database-attlist, empty }
+db-server-database-attlist =
+  attribute db:type { namespacedToken }
+  & (db-host-and-port | db-local-socket-name)
+  & attribute db:database-name { \string }?
+db-host-and-port =
+  attribute db:hostname { \string },
+  attribute db:port { positiveInteger }?
+db-local-socket-name = attribute db:local-socket { \string }?
+db-connection-resource =
+  element db:connection-resource {
+    db-connection-resource-attlist, empty
+  }
+db-connection-resource-attlist =
+  attribute xlink:type { "simple" },
+  attribute xlink:href { anyIRI },
+  attribute xlink:show { "none" }?,
+  attribute xlink:actuate { "onRequest" }?
+db-login = element db:login { db-login-attlist, empty }
+db-login-attlist =
+  (attribute db:user-name { \string }
+   | attribute db:use-system-user { boolean })?
+  & attribute db:is-password-required { boolean }?
+  & attribute db:login-timeout { positiveInteger }?
+db-driver-settings =
+  element db:driver-settings {
+    db-driver-settings-attlist,
+    db-auto-increment?,
+    db-delimiter?,
+    db-character-set?,
+    db-table-settings?
+  }
+db-driver-settings-attlist =
+  db-show-deleted
+  & attribute db:system-driver-settings { \string }?
+  & attribute db:base-dn { \string }?
+  & db-is-first-row-header-line
+  & attribute db:parameter-name-substitution { boolean }?
+db-show-deleted = attribute db:show-deleted { boolean }?
+db-is-first-row-header-line =
+  attribute db:is-first-row-header-line { boolean }?
+db-auto-increment =
+  element db:auto-increment { db-auto-increment-attlist, empty }
+db-auto-increment-attlist =
+  attribute db:additional-column-statement { \string }?
+  & attribute db:row-retrieving-statement { \string }?
+db-delimiter = element db:delimiter { db-delimiter-attlist, empty }
+db-delimiter-attlist =
+  attribute db:field { \string }?
+  & attribute db:string { \string }?
+  & attribute db:decimal { \string }?
+  & attribute db:thousand { \string }?
+db-character-set =
+  element db:character-set { db-character-set-attlist, empty }
+db-character-set-attlist = attribute db:encoding { textEncoding }?
+db-table-settings = element db:table-settings { db-table-setting* }
+db-table-setting =
+  element db:table-setting {
+    db-table-setting-attlist, db-delimiter?, db-character-set?, empty
+  }
+db-table-setting-attlist = db-is-first-row-header-line, db-show-deleted
+db-application-connection-settings =
+  element db:application-connection-settings {
+    db-application-connection-settings-attlist,
+    db-table-filter?,
+    db-table-type-filter?,
+    db-data-source-settings?
+  }
+db-application-connection-settings-attlist =
+  attribute db:is-table-name-length-limited { boolean }?
+  & attribute db:enable-sql92-check { boolean }?
+  & attribute db:append-table-alias-name { boolean }?
+  & attribute db:ignore-driver-privileges { boolean }?
+  & attribute db:boolean-comparison-mode {
+      "equal-integer"
+      | "is-boolean"
+      | "equal-boolean"
+      | "equal-use-only-zero"
+    }?
+  & attribute db:use-catalog { boolean }?
+  & attribute db:max-row-count { integer }?
+  & attribute db:suppress-version-columns { boolean }?
+db-table-filter =
+  element db:table-filter {
+    db-table-filter-attlist,
+    db-table-include-filter?,
+    db-table-exclude-filter?
+  }
+db-table-filter-attlist = empty
+db-table-include-filter =
+  element db:table-include-filter {
+    db-table-include-filter-attlist, db-table-filter-pattern+
+  }
+db-table-include-filter-attlist = empty
+db-table-exclude-filter =
+  element db:table-exclude-filter {
+    db-table-exclude-filter-attlist, db-table-filter-pattern+
+  }
+db-table-exclude-filter-attlist = empty
+db-table-filter-pattern =
+  element db:table-filter-pattern {
+    db-table-filter-pattern-attlist, \string
+  }
+db-table-filter-pattern-attlist = empty
+db-table-type-filter =
+  element db:table-type-filter {
+    db-table-type-filter-attlist, db-table-type*
+  }
+db-table-type-filter-attlist = empty
+db-table-type = element db:table-type { db-table-type-attlist, \string }
+db-table-type-attlist = empty
+db-data-source-settings =
+  element db:data-source-settings {
+    db-data-source-settings-attlist, db-data-source-setting+
+  }
+db-data-source-settings-attlist = empty
+db-data-source-setting =
+  element db:data-source-setting {
+    db-data-source-setting-attlist, db-data-source-setting-value+
+  }
+db-data-source-setting-attlist =
+  attribute db:data-source-setting-is-list { boolean }?
+  & attribute db:data-source-setting-name { \string }
+  & attribute db:data-source-setting-type {
+      db-data-source-setting-types
+    }
+db-data-source-setting-types =
+  "boolean" | "short" | "int" | "long" | "double" | "string"
+db-data-source-setting-value =
+  element db:data-source-setting-value {
+    db-data-source-setting-value-attlist, \string
+  }
+db-data-source-setting-value-attlist = empty
+db-forms =
+  element db:forms {
+    db-forms-attlist, (db-component | db-component-collection)*
+  }
+db-forms-attlist = empty
+db-reports =
+  element db:reports {
+    db-reports-attlist, (db-component | db-component-collection)*
+  }
+db-reports-attlist = empty
+db-component-collection =
+  element db:component-collection {
+    db-component-collection-attlist,
+    common-db-object-name,
+    common-db-object-title,
+    common-db-object-description,
+    (db-component | db-component-collection)*
+  }
+db-component-collection-attlist = empty
+db-component =
+  element db:component {
+    db-component-attlist,
+    common-db-object-name,
+    common-db-object-title,
+    common-db-object-description,
+    (office-document | math-math)?
+  }
+db-component-attlist =
+  (attribute xlink:type { "simple" },
+   attribute xlink:href { anyIRI },
+   attribute xlink:show { "none" }?,
+   attribute xlink:actuate { "onRequest" }?)?
+  & attribute db:as-template { boolean }?
+db-queries =
+  element db:queries {
+    db-queries-attlist, (db-query | db-query-collection)*
+  }
+db-queries-attlist = empty
+db-query-collection =
+  element db:query-collection {
+    db-query-collection-attlist,
+    common-db-object-name,
+    common-db-object-title,
+    common-db-object-description,
+    (db-query | db-query-collection)*
+  }
+db-query-collection-attlist = empty
+db-query =
+  element db:query {
+    db-query-attlist,
+    common-db-object-name,
+    common-db-object-title,
+    common-db-object-description,
+    common-db-table-style-name,
+    db-order-statement?,
+    db-filter-statement?,
+    db-columns?,
+    db-update-table?
+  }
+db-query-attlist =
+  attribute db:command { \string }
+  & attribute db:escape-processing { boolean }?
+db-order-statement =
+  element db:order-statement { db-command, db-apply-command, empty }
+db-filter-statement =
+  element db:filter-statement { db-command, db-apply-command, empty }
+db-update-table =
+  element db:update-table { common-db-table-name-attlist }
+db-table-presentations =
+  element db:table-representations {
+    db-table-presentations-attlist, db-table-presentation*
+  }
+db-table-presentations-attlist = empty
+db-table-presentation =
+  element db:table-representation {
+    db-table-presentation-attlist,
+    common-db-table-name-attlist,
+    common-db-object-title,
+    common-db-object-description,
+    common-db-table-style-name,
+    db-order-statement?,
+    db-filter-statement?,
+    db-columns?
+  }
+db-table-presentation-attlist = empty
+db-columns = element db:columns { db-columns-attlist, db-column+ }
+db-columns-attlist = empty
+db-column =
+  element db:column {
+    db-column-attlist,
+    common-db-object-name,
+    common-db-object-title,
+    common-db-object-description,
+    common-db-default-value
+  }
+db-column-attlist =
+  attribute db:visible { boolean }?
+  & attribute db:style-name { styleNameRef }?
+  & attribute db:default-cell-style-name { styleNameRef }?
+db-command = attribute db:command { \string }
+db-apply-command = attribute db:apply-command { boolean }?
+common-db-table-name-attlist =
+  attribute db:name { \string }
+  & attribute db:catalog-name { \string }?
+  & attribute db:schema-name { \string }?
+common-db-object-name = attribute db:name { \string }
+common-db-object-title = attribute db:title { \string }?
+common-db-object-description = attribute db:description { \string }?
+common-db-table-style-name =
+  attribute db:style-name { styleNameRef }?
+  & attribute db:default-row-style-name { styleNameRef }?
+common-db-default-value = common-value-and-type-attlist?
+db-schema-definition =
+  element db:schema-definition {
+    db-schema-definition-attlist, db-table-definitions
+  }
+db-schema-definition-attlist = empty
+db-table-definitions =
+  element db:table-definitions {
+    db-table-definitions-attlist, db-table-definition*
+  }
+db-table-definitions-attlist = empty
+db-table-definition =
+  element db:table-definition {
+    common-db-table-name-attlist,
+    db-table-definition-attlist,
+    db-column-definitions,
+    db-keys?,
+    db-indices?
+  }
+db-table-definition-attlist = attribute db:type { \string }?
+db-column-definitions =
+  element db:column-definitions {
+    db-column-definitions-attlist, db-column-definition+
+  }
+db-column-definitions-attlist = empty
+db-column-definition =
+  element db:column-definition {
+    db-column-definition-attlist, common-db-default-value
+  }
+db-column-definition-attlist =
+  attribute db:name { \string }
+  & attribute db:data-type { db-data-types }?
+  & attribute db:type-name { \string }?
+  & attribute db:precision { positiveInteger }?
+  & attribute db:scale { positiveInteger }?
+  & attribute db:is-nullable { "no-nulls" | "nullable" }?
+  & attribute db:is-empty-allowed { boolean }?
+  & attribute db:is-autoincrement { boolean }?
+db-data-types =
+  "bit"
+  | "boolean"
+  | "tinyint"
+  | "smallint"
+  | "integer"
+  | "bigint"
+  | "float"
+  | "real"
+  | "double"
+  | "numeric"
+  | "decimal"
+  | "char"
+  | "varchar"
+  | "longvarchar"
+  | "date"
+  | "time"
+  | "timestmp"
+  | "binary"
+  | "varbinary"
+  | "longvarbinary"
+  | "sqlnull"
+  | "other"
+  | "object"
+  | "distinct"
+  | "struct"
+  | "array"
+  | "blob"
+  | "clob"
+  | "ref"
+db-keys = element db:keys { db-keys-attlist, db-key+ }
+db-keys-attlist = empty
+db-key = element db:key { db-key-attlist, db-key-columns+ }
+db-key-attlist =
+  attribute db:name { \string }?
+  & attribute db:type { "primary" | "unique" | "foreign" }
+  & attribute db:referenced-table-name { \string }?
+  & attribute db:update-rule {
+      "cascade" | "restrict" | "set-null" | "no-action" | "set-default"
+    }?
+  & attribute db:delete-rule {
+      "cascade" | "restrict" | "set-null" | "no-action" | "set-default"
+    }?
+db-key-columns =
+  element db:key-columns { db-key-columns-attlist, db-key-column+ }
+db-key-columns-attlist = empty
+db-key-column = element db:key-column { db-key-column-attlist, empty }
+db-key-column-attlist =
+  attribute db:name { \string }?
+  & attribute db:related-column-name { \string }?
+db-indices = element db:indices { db-indices-attlist, db-index+ }
+db-indices-attlist = empty
+db-index = element db:index { db-index-attlist, db-index-columns+ }
+db-index-attlist =
+  attribute db:name { \string }
+  & attribute db:catalog-name { \string }?
+  & attribute db:is-unique { boolean }?
+  & attribute db:is-clustered { boolean }?
+db-index-columns = element db:index-columns { db-index-column+ }
+db-index-column =
+  element db:index-column { db-index-column-attlist, empty }
+db-index-column-attlist =
+  attribute db:name { \string }
+  & attribute db:is-ascending { boolean }?
+office-forms =
+  element office:forms {
+    office-forms-attlist, (form-form | xforms-model)*
+  }?
+office-forms-attlist =
+  attribute form:automatic-focus { boolean }?
+  & attribute form:apply-design-mode { boolean }?
+form-form =
+  element form:form {
+    common-form-control-attlist,
+    form-form-attlist,
+    form-properties?,
+    office-event-listeners?,
+    (controls | form-form)*,
+    form-connection-resource?
+  }
+form-form-attlist =
+  (attribute xlink:type { "simple" },
+   attribute xlink:href { anyIRI },
+   attribute xlink:actuate { "onRequest" }?)?
+  & attribute office:target-frame { targetFrameName }?
+  & attribute form:method { "get" | "post" | \string }?
+  & attribute form:enctype { \string }?
+  & attribute form:allow-deletes { boolean }?
+  & attribute form:allow-inserts { boolean }?
+  & attribute form:allow-updates { boolean }?
+  & attribute form:apply-filter { boolean }?
+  & attribute form:command-type { "table" | "query" | "command" }?
+  & attribute form:command { \string }?
+  & attribute form:datasource { anyIRI | \string }?
+  & attribute form:master-fields { \string }?
+  & attribute form:detail-fields { \string }?
+  & attribute form:escape-processing { boolean }?
+  & attribute form:filter { \string }?
+  & attribute form:ignore-result { boolean }?
+  & attribute form:navigation-mode { navigation }?
+  & attribute form:order { \string }?
+  & attribute form:tab-cycle { tab-cycles }?
+navigation = "none" | "current" | "parent"
+tab-cycles = "records" | "current" | "page"
+form-connection-resource =
+  element form:connection-resource {
+    attribute xlink:href { anyIRI },
+    empty
+  }
+xforms-model = element xforms:model { anyAttListOrElements }
+column-controls =
+  element form:text { form-text-attlist, common-form-control-content }
+  | element form:textarea {
+      form-textarea-attlist, common-form-control-content, text-p*
+    }
+  | element form:formatted-text {
+      form-formatted-text-attlist, common-form-control-content
+    }
+  | element form:number {
+      form-number-attlist,
+      common-numeric-control-attlist,
+      common-form-control-content,
+      common-linked-cell,
+      common-spin-button,
+      common-repeat,
+      common-delay-for-repeat
+    }
+  | element form:date {
+      form-date-attlist,
+      common-numeric-control-attlist,
+      common-form-control-content,
+      common-linked-cell,
+      common-spin-button,
+      common-repeat,
+      common-delay-for-repeat
+    }
+  | element form:time {
+      form-time-attlist,
+      common-numeric-control-attlist,
+      common-form-control-content,
+      common-linked-cell,
+      common-spin-button,
+      common-repeat,
+      common-delay-for-repeat
+    }
+  | element form:combobox {
+      form-combobox-attlist, common-form-control-content, form-item*
+    }
+  | element form:listbox {
+      form-listbox-attlist, common-form-control-content, form-option*
+    }
+  | element form:checkbox {
+      form-checkbox-attlist, common-form-control-content
+    }
+controls =
+  column-controls
+  | element form:password {
+      form-password-attlist, common-form-control-content
+    }
+  | element form:file { form-file-attlist, common-form-control-content }
+  | element form:fixed-text {
+      form-fixed-text-attlist, common-form-control-content
+    }
+  | element form:button {
+      form-button-attlist, common-form-control-content
+    }
+  | element form:image {
+      form-image-attlist, common-form-control-content
+    }
+  | element form:radio {
+      form-radio-attlist, common-form-control-content
+    }
+  | element form:frame {
+      form-frame-attlist, common-form-control-content
+    }
+  | element form:image-frame {
+      form-image-frame-attlist, common-form-control-content
+    }
+  | element form:hidden {
+      form-hidden-attlist, common-form-control-content
+    }
+  | element form:grid {
+      form-grid-attlist, common-form-control-content, form-column*
+    }
+  | element form:value-range {
+      form-value-range-attlist, common-form-control-content
+    }
+  | element form:generic-control {
+      form-generic-control-attlist, common-form-control-content
+    }
+form-text-attlist =
+  form-control-attlist,
+  common-current-value-attlist,
+  common-disabled-attlist,
+  common-maxlength-attlist,
+  common-printable-attlist,
+  common-readonly-attlist,
+  common-tab-attlist,
+  common-title-attlist,
+  common-value-attlist,
+  common-convert-empty-attlist,
+  common-data-field-attlist,
+  common-linked-cell
+form-control-attlist =
+  common-form-control-attlist,
+  common-control-id-attlist,
+  xforms-bind-attlist
+common-form-control-content = form-properties?, office-event-listeners?
+form-textarea-attlist =
+  form-control-attlist,
+  common-current-value-attlist,
+  common-disabled-attlist,
+  common-maxlength-attlist,
+  common-printable-attlist,
+  common-readonly-attlist,
+  common-tab-attlist,
+  common-title-attlist,
+  common-value-attlist,
+  common-convert-empty-attlist,
+  common-data-field-attlist,
+  common-linked-cell
+form-password-attlist =
+  form-control-attlist
+  & common-disabled-attlist
+  & common-maxlength-attlist
+  & common-printable-attlist
+  & common-tab-attlist
+  & common-title-attlist
+  & common-value-attlist
+  & common-convert-empty-attlist
+  & common-linked-cell
+  & attribute form:echo-char { character }?
+form-file-attlist =
+  form-control-attlist,
+  common-current-value-attlist,
+  common-disabled-attlist,
+  common-maxlength-attlist,
+  common-printable-attlist,
+  common-readonly-attlist,
+  common-tab-attlist,
+  common-title-attlist,
+  common-value-attlist,
+  common-linked-cell
+form-formatted-text-attlist =
+  form-control-attlist
+  & common-current-value-attlist
+  & common-disabled-attlist
+  & common-maxlength-attlist
+  & common-printable-attlist
+  & common-readonly-attlist
+  & common-tab-attlist
+  & common-title-attlist
+  & common-value-attlist
+  & common-convert-empty-attlist
+  & common-data-field-attlist
+  & common-linked-cell
+  & common-spin-button
+  & common-repeat
+  & common-delay-for-repeat
+  & attribute form:max-value { \string }?
+  & attribute form:min-value { \string }?
+  & attribute form:validation { boolean }?
+common-numeric-control-attlist =
+  form-control-attlist,
+  common-disabled-attlist,
+  common-maxlength-attlist,
+  common-printable-attlist,
+  common-readonly-attlist,
+  common-tab-attlist,
+  common-title-attlist,
+  common-convert-empty-attlist,
+  common-data-field-attlist
+form-number-attlist =
+  attribute form:value { double }?
+  & attribute form:current-value { double }?
+  & attribute form:min-value { double }?
+  & attribute form:max-value { double }?
+form-date-attlist =
+  attribute form:value { date }?
+  & attribute form:current-value { date }?
+  & attribute form:min-value { date }?
+  & attribute form:max-value { date }?
+form-time-attlist =
+  attribute form:value { time }?
+  & attribute form:current-value { time }?
+  & attribute form:min-value { time }?
+  & attribute form:max-value { time }?
+form-fixed-text-attlist =
+  form-control-attlist
+  & for
+  & common-disabled-attlist
+  & label
+  & common-printable-attlist
+  & common-title-attlist
+  & attribute form:multi-line { boolean }?
+form-combobox-attlist =
+  form-control-attlist
+  & common-current-value-attlist
+  & common-disabled-attlist
+  & dropdown
+  & common-maxlength-attlist
+  & common-printable-attlist
+  & common-readonly-attlist
+  & size
+  & common-tab-attlist
+  & common-title-attlist
+  & common-value-attlist
+  & common-convert-empty-attlist
+  & common-data-field-attlist
+  & list-source
+  & list-source-type
+  & common-linked-cell
+  & common-source-cell-range
+  & attribute form:auto-complete { boolean }?
+form-item = element form:item { form-item-attlist, text }
+form-item-attlist = label
+form-listbox-attlist =
+  form-control-attlist
+  & common-disabled-attlist
+  & dropdown
+  & common-printable-attlist
+  & size
+  & common-tab-attlist
+  & common-title-attlist
+  & bound-column
+  & common-data-field-attlist
+  & list-source
+  & list-source-type
+  & common-linked-cell
+  & list-linkage-type
+  & common-source-cell-range
+  & attribute form:multiple { boolean }?
+  & attribute form:xforms-list-source { \string }?
+list-linkage-type =
+  attribute form:list-linkage-type {
+    "selection" | "selection-indices"
+  }?
+form-option = element form:option { form-option-attlist, text }
+form-option-attlist =
+  current-selected, selected, label, common-value-attlist
+form-button-attlist =
+  form-control-attlist
+  & button-type
+  & common-disabled-attlist
+  & label
+  & image-data
+  & common-printable-attlist
+  & common-tab-attlist
+  & target-frame
+  & target-location
+  & common-title-attlist
+  & common-value-attlist
+  & common-form-relative-image-position-attlist
+  & common-repeat
+  & common-delay-for-repeat
+  & attribute form:default-button { boolean }?
+  & attribute form:toggle { boolean }?
+  & attribute form:focus-on-click { boolean }?
+  & attribute form:xforms-submission { \string }?
+form-image-attlist =
+  form-control-attlist,
+  button-type,
+  common-disabled-attlist,
+  image-data,
+  common-printable-attlist,
+  common-tab-attlist,
+  target-frame,
+  target-location,
+  common-title-attlist,
+  common-value-attlist
+form-checkbox-attlist =
+  form-control-attlist
+  & common-disabled-attlist
+  & label
+  & common-printable-attlist
+  & common-tab-attlist
+  & common-title-attlist
+  & common-value-attlist
+  & common-data-field-attlist
+  & common-form-visual-effect-attlist
+  & common-form-relative-image-position-attlist
+  & common-linked-cell
+  & attribute form:current-state { states }?
+  & attribute form:is-tristate { boolean }?
+  & attribute form:state { states }?
+states = "unchecked" | "checked" | "unknown"
+form-radio-attlist =
+  form-control-attlist,
+  current-selected,
+  common-disabled-attlist,
+  label,
+  common-printable-attlist,
+  selected,
+  common-tab-attlist,
+  common-title-attlist,
+  common-value-attlist,
+  common-data-field-attlist,
+  common-form-visual-effect-attlist,
+  common-form-relative-image-position-attlist,
+  common-linked-cell
+form-frame-attlist =
+  form-control-attlist,
+  common-disabled-attlist,
+  for,
+  label,
+  common-printable-attlist,
+  common-title-attlist
+form-image-frame-attlist =
+  form-control-attlist,
+  common-disabled-attlist,
+  image-data,
+  common-printable-attlist,
+  common-readonly-attlist,
+  common-title-attlist,
+  common-data-field-attlist
+form-hidden-attlist = form-control-attlist, common-value-attlist
+form-grid-attlist =
+  form-control-attlist,
+  common-disabled-attlist,
+  common-printable-attlist,
+  common-tab-attlist,
+  common-title-attlist
+form-column =
+  element form:column { form-column-attlist, column-controls+ }
+form-column-attlist =
+  common-form-control-attlist, label, text-style-name
+text-style-name = attribute form:text-style-name { styleNameRef }?
+form-value-range-attlist =
+  form-control-attlist
+  & common-disabled-attlist
+  & common-printable-attlist
+  & common-tab-attlist
+  & common-title-attlist
+  & common-value-attlist
+  & common-linked-cell
+  & common-repeat
+  & common-delay-for-repeat
+  & attribute form:max-value { integer }?
+  & attribute form:min-value { integer }?
+  & attribute form:step-size { positiveInteger }?
+  & attribute form:page-step-size { positiveInteger }?
+  & attribute form:orientation { "horizontal" | "vertical" }?
+form-generic-control-attlist = form-control-attlist
+common-form-control-attlist =
+  attribute form:name { \string }?
+  & attribute form:control-implementation { namespacedToken }?
+xforms-bind-attlist = attribute xforms:bind { \string }?
+types = "submit" | "reset" | "push" | "url"
+button-type = attribute form:button-type { types }?
+common-control-id-attlist =
+  xml-id,
+  attribute form:id { NCName }?
+current-selected = attribute form:current-selected { boolean }?
+common-value-attlist = attribute form:value { \string }?
+common-current-value-attlist = attribute form:current-value { \string }?
+common-disabled-attlist = attribute form:disabled { boolean }?
+dropdown = attribute form:dropdown { boolean }?
+for = attribute form:for { \string }?
+image-data = attribute form:image-data { anyIRI }?
+label = attribute form:label { \string }?
+common-maxlength-attlist =
+  attribute form:max-length { nonNegativeInteger }?
+common-printable-attlist = attribute form:printable { boolean }?
+common-readonly-attlist = attribute form:readonly { boolean }?
+selected = attribute form:selected { boolean }?
+size = attribute form:size { nonNegativeInteger }?
+common-tab-attlist =
+  attribute form:tab-index { nonNegativeInteger }?
+  & attribute form:tab-stop { boolean }?
+target-frame = attribute office:target-frame { targetFrameName }?
+target-location = attribute xlink:href { anyIRI }?
+common-title-attlist = attribute form:title { \string }?
+common-form-visual-effect-attlist =
+  attribute form:visual-effect { "flat" | "3d" }?
+common-form-relative-image-position-attlist =
+  attribute form:image-position { "center" }?
+  | (attribute form:image-position {
+       "start" | "end" | "top" | "bottom"
+     },
+     attribute form:image-align { "start" | "center" | "end" }?)
+bound-column = attribute form:bound-column { \string }?
+common-convert-empty-attlist =
+  attribute form:convert-empty-to-null { boolean }?
+common-data-field-attlist = attribute form:data-field { \string }?
+list-source = attribute form:list-source { \string }?
+list-source-type =
+  attribute form:list-source-type {
+    "table"
+    | "query"
+    | "sql"
+    | "sql-pass-through"
+    | "value-list"
+    | "table-fields"
+  }?
+common-linked-cell =
+  attribute form:linked-cell { cellAddress | \string }?
+common-source-cell-range =
+  attribute form:source-cell-range { cellRangeAddress | \string }?
+common-spin-button = attribute form:spin-button { boolean }?
+common-repeat = attribute form:repeat { boolean }?
+common-delay-for-repeat = attribute form:delay-for-repeat { duration }?
+form-properties = element form:properties { form-property+ }
+form-property =
+  element form:property {
+    form-property-name, form-property-value-and-type-attlist
+  }
+  | element form:list-property {
+      form-property-name, form-property-type-and-value-list
+    }
+form-property-name = attribute form:property-name { \string }
+form-property-value-and-type-attlist =
+  common-value-and-type-attlist
+  | attribute office:value-type { "void" }
+form-property-type-and-value-list =
+  (attribute office:value-type { "float" },
+   element form:list-value {
+     attribute office:value { double }
+   }*)
+  | (attribute office:value-type { "percentage" },
+     element form:list-value {
+       attribute office:value { double }
+     }*)
+  | (attribute office:value-type { "currency" },
+     element form:list-value {
+       attribute office:value { double },
+       attribute office:currency { \string }?
+     }*)
+  | (attribute office:value-type { "date" },
+     element form:list-value {
+       attribute office:date-value { dateOrDateTime }
+     }*)
+  | (attribute office:value-type { "time" },
+     element form:list-value {
+       attribute office:time-value { duration }
+     }*)
+  | (attribute office:value-type { "boolean" },
+     element form:list-value {
+       attribute office:boolean-value { boolean }
+     }*)
+  | (attribute office:value-type { "string" },
+     element form:list-value {
+       attribute office:string-value { \string }
+     }*)
+  | attribute office:value-type { "void" }
+office-annotation =
+  element office:annotation {
+    office-annotation-attlist,
+    draw-caption-attlist,
+    common-draw-position-attlist,
+    common-draw-size-attlist,
+    common-draw-shape-with-text-and-styles-attlist,
+    dc-creator?,
+    dc-date?,
+    meta-date-string?,
+    (text-p | text-list)*
+  }
+office-annotation-end =
+  element office:annotation-end { office-annotation-end-attlist }
+office-annotation-attlist =
+  attribute office:display { boolean }?
+  & common-office-annotation-name-attlist?
+office-annotation-end-attlist = common-office-annotation-name-attlist
+common-office-annotation-name-attlist =
+  attribute office:name { \string }
+meta-date-string = element meta:date-string { \string }
+common-num-format-prefix-suffix-attlist =
+  attribute style:num-prefix { \string }?,
+  attribute style:num-suffix { \string }?
+common-num-format-attlist =
+  attribute style:num-format { "1" | "i" | "I" | \string | empty }
+  | (attribute style:num-format { "a" | "A" },
+     style-num-letter-sync-attlist)
+  | empty
+style-num-letter-sync-attlist =
+  attribute style:num-letter-sync { boolean }?
+office-change-info =
+  element office:change-info { dc-creator, dc-date, text-p* }
+office-event-listeners =
+  element office:event-listeners {
+    (script-event-listener | presentation-event-listener)*
+  }
+script-event-listener =
+  element script:event-listener { script-event-listener-attlist, empty }
+script-event-listener-attlist =
+  attribute script:event-name { \string }
+  & attribute script:language { \string }
+  & (attribute script:macro-name { \string }
+     | (attribute xlink:type { "simple" },
+        attribute xlink:href { anyIRI },
+        attribute xlink:actuate { "onRequest" }?))
+math-math = element math:math { mathMarkup }
+[
+  dc:description [
+    "To avoid inclusion of the complete MathML schema, anything is allowed within a math:math top-level element"
+  ]
+]
+mathMarkup =
+  (attribute * { text }
+   | text
+   | element * { mathMarkup })*
+text-dde-connection-decl =
+  element text:dde-connection-decl {
+    text-dde-connection-decl-attlist, common-dde-connection-decl-attlist
+  }
+text-dde-connection-decl-attlist = attribute office:name { \string }
+common-dde-connection-decl-attlist =
+  attribute office:dde-application { \string }
+  & attribute office:dde-topic { \string }
+  & attribute office:dde-item { \string }
+  & attribute office:automatic-update { boolean }?
+table-dde-link =
+  element table:dde-link { office-dde-source, table-table }
+office-dde-source =
+  element office:dde-source {
+    office-dde-source-attlist, common-dde-connection-decl-attlist
+  }
+office-dde-source-attlist =
+  attribute office:name { \string }?
+  & attribute office:conversion-mode {
+      "into-default-style-data-style"
+      | "into-english-number"
+      | "keep-text"
+    }?
+animation-element =
+  element anim:animate {
+    common-anim-target-attlist,
+    common-anim-named-target-attlist,
+    common-anim-values-attlist,
+    common-anim-spline-mode-attlist,
+    common-spline-anim-value-attlist,
+    common-timing-attlist,
+    common-anim-add-accum-attlist
+  }
+  | element anim:set {
+      common-anim-target-attlist,
+      common-anim-named-target-attlist,
+      common-anim-set-values-attlist,
+      common-timing-attlist,
+      common-anim-add-accum-attlist
+    }
+  | element anim:animateMotion {
+      anim-animate-motion-attlist,
+      common-anim-target-attlist,
+      common-anim-named-target-attlist,
+      common-anim-add-accum-attlist,
+      common-anim-values-attlist,
+      common-timing-attlist,
+      common-spline-anim-value-attlist
+    }
+  | element anim:animateColor {
+      common-anim-target-attlist,
+      common-anim-named-target-attlist,
+      common-anim-add-accum-attlist,
+      common-anim-values-attlist,
+      common-anim-spline-mode-attlist,
+      common-spline-anim-value-attlist,
+      anim-animate-color-attlist,
+      common-timing-attlist
+    }
+  | element anim:animateTransform {
+      common-anim-target-attlist,
+      common-anim-named-target-attlist,
+      common-anim-add-accum-attlist,
+      common-anim-values-attlist,
+      anim-animate-transform-attlist,
+      common-timing-attlist
+    }
+  | element anim:transitionFilter {
+      common-anim-target-attlist,
+      common-anim-add-accum-attlist,
+      common-anim-values-attlist,
+      common-anim-spline-mode-attlist,
+      anim-transition-filter-attlist,
+      common-timing-attlist
+    }
+  | element anim:par {
+      common-anim-attlist,
+      common-timing-attlist,
+      common-endsync-timing-attlist,
+      animation-element*
+    }
+  | element anim:seq {
+      common-anim-attlist,
+      common-endsync-timing-attlist,
+      common-timing-attlist,
+      animation-element*
+    }
+  | element anim:iterate {
+      common-anim-attlist,
+      anim-iterate-attlist,
+      common-timing-attlist,
+      common-endsync-timing-attlist,
+      animation-element*
+    }
+  | element anim:audio {
+      common-anim-attlist,
+      anim-audio-attlist,
+      common-basic-timing-attlist
+    }
+  | element anim:command {
+      common-anim-attlist,
+      anim-command-attlist,
+      common-begin-end-timing-attlist,
+      common-anim-target-attlist,
+      element anim:param {
+        attribute anim:name { \string },
+        attribute anim:value { \string }
+      }*
+    }
+anim-animate-motion-attlist =
+  attribute svg:path { pathData }?
+  & attribute svg:origin { \string }?
+  & attribute smil:calcMode {
+      "discrete" | "linear" | "paced" | "spline"
+    }?
+anim-animate-color-attlist =
+  attribute anim:color-interpolation { "rgb" | "hsl" }?
+  & attribute anim:color-interpolation-direction {
+      "clockwise" | "counter-clockwise"
+    }?
+anim-animate-transform-attlist =
+  attribute svg:type {
+    "translate" | "scale" | "rotate" | "skewX" | "skewY"
+  }
+anim-transition-filter-attlist =
+  attribute smil:type { \string }
+  & attribute smil:subtype { \string }?
+  & attribute smil:direction { "forward" | "reverse" }?
+  & attribute smil:fadeColor { color }?
+  & attribute smil:mode { "in" | "out" }?
+common-anim-target-attlist =
+  attribute smil:targetElement { IDREF }?
+  & attribute anim:sub-item { \string }?
+common-anim-named-target-attlist =
+  attribute smil:attributeName { \string }
+common-anim-values-attlist =
+  attribute smil:values { \string }?
+  & attribute anim:formula { \string }?
+  & common-anim-set-values-attlist
+  & attribute smil:from { \string }?
+  & attribute smil:by { \string }?
+common-anim-spline-mode-attlist =
+  attribute smil:calcMode {
+    "discrete" | "linear" | "paced" | "spline"
+  }?
+common-spline-anim-value-attlist =
+  attribute smil:keyTimes { \string }?
+  & attribute smil:keySplines { \string }?
+common-anim-add-accum-attlist =
+  attribute smil:accumulate { "none" | "sum" }?
+  & attribute smil:additive { "replace" | "sum" }?
+common-anim-set-values-attlist = attribute smil:to { \string }?
+common-begin-end-timing-attlist =
+  attribute smil:begin { \string }?
+  & attribute smil:end { \string }?
+common-dur-timing-attlist = attribute smil:dur { \string }?
+common-endsync-timing-attlist =
+  attribute smil:endsync { "first" | "last" | "all" | "media" | IDREF }?
+common-repeat-timing-attlist =
+  attribute smil:repeatDur { \string }?,
+  attribute smil:repeatCount { nonNegativeDecimal | "indefinite" }?
+nonNegativeDecimal = xsd:decimal { minInclusive = "0.0" }
+common-fill-timing-attlist =
+  attribute smil:fill {
+    "remove" | "freeze" | "hold" | "auto" | "default" | "transition"
+  }?
+common-fill-default-attlist =
+  attribute smil:fillDefault {
+    "remove" | "freeze" | "hold" | "transition" | "auto" | "inherit"
+  }?
+common-restart-timing-attlist =
+  attribute smil:restart {
+    "never" | "always" | "whenNotActive" | "default"
+  }?
+common-restart-default-attlist =
+  attribute smil:restartDefault {
+    "never" | "always" | "whenNotActive" | "inherit"
+  }?
+common-time-manip-attlist =
+  attribute smil:accelerate { zeroToOneDecimal }?
+  & attribute smil:decelerate { zeroToOneDecimal }?
+  & attribute smil:autoReverse { boolean }?
+zeroToOneDecimal = xsd:decimal { minInclusive = "0" maxInclusive = "1" }
+common-basic-timing-attlist =
+  common-begin-end-timing-attlist,
+  common-dur-timing-attlist,
+  common-repeat-timing-attlist,
+  common-restart-timing-attlist,
+  common-restart-default-attlist,
+  common-fill-timing-attlist,
+  common-fill-default-attlist
+common-timing-attlist =
+  common-basic-timing-attlist, common-time-manip-attlist
+anim-iterate-attlist =
+  common-anim-target-attlist
+  & attribute anim:iterate-type { \string }?
+  & attribute anim:iterate-interval { duration }?
+anim-audio-attlist =
+  attribute xlink:href { anyIRI }?
+  & attribute anim:audio-level { double }?
+anim-command-attlist = attribute anim:command { \string }
+style-style =
+  element style:style {
+    style-style-attlist, style-style-content, style-map*
+  }
+common-in-content-meta-attlist =
+  attribute xhtml:about { URIorSafeCURIE },
+  attribute xhtml:property { CURIEs },
+  common-meta-literal-attlist
+common-meta-literal-attlist =
+  attribute xhtml:datatype { CURIE }?,
+  attribute xhtml:content { \string }?
+xml-id = attribute xml:id { ID }
+style-style-attlist =
+  attribute style:name { styleName }
+  & attribute style:display-name { \string }?
+  & attribute style:parent-style-name { styleNameRef }?
+  & attribute style:next-style-name { styleNameRef }?
+  & attribute style:list-level { positiveInteger | empty }?
+  & attribute style:list-style-name { styleName | empty }?
+  & attribute style:master-page-name { styleNameRef }?
+  & attribute style:auto-update { boolean }?
+  & attribute style:data-style-name { styleNameRef }?
+  & attribute style:percentage-data-style-name { styleNameRef }?
+  & attribute style:class { \string }?
+  & attribute style:default-outline-level { positiveInteger | empty }?
+style-map = element style:map { style-map-attlist, empty }
+style-map-attlist =
+  attribute style:condition { \string }
+  & attribute style:apply-style-name { styleNameRef }
+  & attribute style:base-cell-address { cellAddress }?
+style-default-style =
+  element style:default-style { style-style-content }
+style-page-layout =
+  element style:page-layout {
+    style-page-layout-attlist, style-page-layout-content
+  }
+style-page-layout-content =
+  style-page-layout-properties?,
+  style-header-style?,
+  style-footer-style?
+style-page-layout-attlist =
+  attribute style:name { styleName }
+  & attribute style:page-usage {
+      "all" | "left" | "right" | "mirrored"
+    }?
+style-header-style =
+  element style:header-style { style-header-footer-properties? }
+style-footer-style =
+  element style:footer-style { style-header-footer-properties? }
+style-default-page-layout =
+  element style:default-page-layout { style-page-layout-content }
+style-master-page =
+  element style:master-page {
+    style-master-page-attlist,
+    (style-header, style-header-left?)?,
+    (style-footer, style-footer-left?)?,
+    draw-layer-set?,
+    office-forms?,
+    shape*,
+    animation-element?,
+    presentation-notes?
+  }
+style-master-page-attlist =
+  attribute style:name { styleName }
+  & attribute style:display-name { \string }?
+  & attribute style:page-layout-name { styleNameRef }
+  & attribute draw:style-name { styleNameRef }?
+  & attribute style:next-style-name { styleNameRef }?
+style-header =
+  element style:header {
+    common-style-header-footer-attlist, header-footer-content
+  }
+style-footer =
+  element style:footer {
+    common-style-header-footer-attlist, header-footer-content
+  }
+style-header-left =
+  element style:header-left {
+    common-style-header-footer-attlist, header-footer-content
+  }
+style-footer-left =
+  element style:footer-left {
+    common-style-header-footer-attlist, header-footer-content
+  }
+header-footer-content =
+  (text-tracked-changes,
+   text-decls,
+   (text-h
+    | text-p
+    | text-list
+    | table-table
+    | text-section
+    | text-table-of-content
+    | text-illustration-index
+    | text-table-index
+    | text-object-index
+    | text-user-index
+    | text-alphabetical-index
+    | text-bibliography
+    | text-index-title
+    | change-marks)*)
+  | (style-region-left?, style-region-center?, style-region-right?)
+common-style-header-footer-attlist =
+  attribute style:display { boolean }?
+style-region-left = element style:region-left { region-content }
+style-region-center = element style:region-center { region-content }
+style-region-right = element style:region-right { region-content }
+region-content = text-p*
+presentation-notes =
+  element presentation:notes {
+    common-presentation-header-footer-attlist,
+    presentation-notes-attlist,
+    office-forms,
+    shape*
+  }
+presentation-notes-attlist =
+  attribute style:page-layout-name { styleNameRef }?
+  & attribute draw:style-name { styleNameRef }?
+table-table-template =
+  element table:table-template {
+    table-table-template-attlist,
+    table-first-row?,
+    table-last-row?,
+    table-first-column?,
+    table-last-column?,
+    table-body,
+    table-even-rows?,
+    table-odd-rows?,
+    table-even-columns?,
+    table-odd-columns?,
+    table-background?
+  }
+table-table-template-attlist =
+  attribute table:name { \string }
+  & attribute table:first-row-start-column { rowOrCol }
+  & attribute table:first-row-end-column { rowOrCol }
+  & attribute table:last-row-start-column { rowOrCol }
+  & attribute table:last-row-end-column { rowOrCol }
+rowOrCol = "row" | "column"
+table-first-row =
+  element table:first-row { common-table-template-attlist, empty }
+table-last-row =
+  element table:last-row { common-table-template-attlist, empty }
+table-first-column =
+  element table:first-column { common-table-template-attlist, empty }
+table-last-column =
+  element table:last-column { common-table-template-attlist, empty }
+table-body = element table:body { common-table-template-attlist, empty }
+table-even-rows =
+  element table:even-rows { common-table-template-attlist, empty }
+table-odd-rows =
+  element table:odd-rows { common-table-template-attlist, empty }
+table-even-columns =
+  element table:even-columns { common-table-template-attlist, empty }
+table-odd-columns =
+  element table:odd-columns { common-table-template-attlist, empty }
+common-table-template-attlist =
+  attribute table:style-name { styleNameRef },
+  attribute table:paragraph-style-name { styleNameRef }?
+table-background =
+  element table:background { table-background-attlist, empty }
+table-background-attlist = attribute table:style-name { styleNameRef }
+style-font-face =
+  element style:font-face {
+    style-font-face-attlist, svg-font-face-src?, svg-definition-src?
+  }
+style-font-face-attlist =
+  attribute svg:font-family { \string }?
+  & attribute svg:font-style { fontStyle }?
+  & attribute svg:font-variant { fontVariant }?
+  & attribute svg:font-weight { fontWeight }?
+  & attribute svg:font-stretch {
+      "normal"
+      | "ultra-condensed"
+      | "extra-condensed"
+      | "condensed"
+      | "semi-condensed"
+      | "semi-expanded"
+      | "expanded"
+      | "extra-expanded"
+      | "ultra-expanded"
+    }?
+  & attribute svg:font-size { positiveLength }?
+  & attribute svg:unicode-range { \string }?
+  & attribute svg:units-per-em { integer }?
+  & attribute svg:panose-1 { \string }?
+  & attribute svg:stemv { integer }?
+  & attribute svg:stemh { integer }?
+  & attribute svg:slope { integer }?
+  & attribute svg:cap-height { integer }?
+  & attribute svg:x-height { integer }?
+  & attribute svg:accent-height { integer }?
+  & attribute svg:ascent { integer }?
+  & attribute svg:descent { integer }?
+  & attribute svg:widths { \string }?
+  & attribute svg:bbox { \string }?
+  & attribute svg:ideographic { integer }?
+  & attribute svg:alphabetic { integer }?
+  & attribute svg:mathematical { integer }?
+  & attribute svg:hanging { integer }?
+  & attribute svg:v-ideographic { integer }?
+  & attribute svg:v-alphabetic { integer }?
+  & attribute svg:v-mathematical { integer }?
+  & attribute svg:v-hanging { integer }?
+  & attribute svg:underline-position { integer }?
+  & attribute svg:underline-thickness { integer }?
+  & attribute svg:strikethrough-position { integer }?
+  & attribute svg:strikethrough-thickness { integer }?
+  & attribute svg:overline-position { integer }?
+  & attribute svg:overline-thickness { integer }?
+  & attribute style:name { \string }
+  & attribute style:font-adornments { \string }?
+  & attribute style:font-family-generic { fontFamilyGeneric }?
+  & attribute style:font-pitch { fontPitch }?
+  & attribute style:font-charset { textEncoding }?
+svg-font-face-src =
+  element svg:font-face-src {
+    (svg-font-face-uri | svg-font-face-name)+
+  }
+svg-font-face-uri =
+  element svg:font-face-uri {
+    common-svg-font-face-xlink-attlist, svg-font-face-format*
+  }
+svg-font-face-format =
+  element svg:font-face-format {
+    attribute svg:string { \string }?,
+    empty
+  }
+svg-font-face-name =
+  element svg:font-face-name {
+    attribute svg:name { \string }?,
+    empty
+  }
+svg-definition-src =
+  element svg:definition-src {
+    common-svg-font-face-xlink-attlist, empty
+  }
+common-svg-font-face-xlink-attlist =
+  attribute xlink:type { "simple" },
+  attribute xlink:href { anyIRI },
+  attribute xlink:actuate { "onRequest" }?
+number-number-style =
+  element number:number-style {
+    common-data-style-attlist,
+    style-text-properties?,
+    number-text?,
+    (any-number, number-text?)?,
+    style-map*
+  }
+any-number = number-number | number-scientific-number | number-fraction
+number-number =
+  element number:number {
+    number-number-attlist,
+    common-decimal-places-attlist,
+    common-number-attlist,
+    number-embedded-text*
+  }
+number-number-attlist =
+  attribute number:decimal-replacement { \string }?
+  & attribute number:display-factor { double }?
+number-embedded-text =
+  element number:embedded-text { number-embedded-text-attlist, text }
+number-embedded-text-attlist = attribute number:position { integer }
+number-scientific-number =
+  element number:scientific-number {
+    number-scientific-number-attlist,
+    common-decimal-places-attlist,
+    common-number-attlist,
+    empty
+  }
+number-scientific-number-attlist =
+  attribute number:min-exponent-digits { integer }?
+number-fraction =
+  element number:fraction {
+    number-fraction-attlist, common-number-attlist, empty
+  }
+number-fraction-attlist =
+  attribute number:min-numerator-digits { integer }?
+  & attribute number:min-denominator-digits { integer }?
+  & attribute number:denominator-value { integer }?
+number-currency-style =
+  element number:currency-style {
+    common-data-style-attlist,
+    common-auto-reorder-attlist,
+    style-text-properties?,
+    number-text?,
+    ((number-and-text, currency-symbol-and-text?)
+     | (currency-symbol-and-text, number-and-text?))?,
+    style-map*
+  }
+currency-symbol-and-text = number-currency-symbol, number-text?
+number-and-text = number-number, number-text?
+number-currency-symbol =
+  element number:currency-symbol {
+    number-currency-symbol-attlist, text
+  }
+number-currency-symbol-attlist =
+  attribute number:language { languageCode }?,
+  attribute number:country { countryCode }?,
+  attribute number:script { scriptCode }?,
+  attribute number:rfc-language-tag { language }?
+number-percentage-style =
+  element number:percentage-style {
+    common-data-style-attlist,
+    style-text-properties?,
+    number-text?,
+    number-and-text?,
+    style-map*
+  }
+number-date-style =
+  element number:date-style {
+    common-data-style-attlist,
+    common-auto-reorder-attlist,
+    common-format-source-attlist,
+    style-text-properties?,
+    number-text?,
+    (any-date, number-text?)+,
+    style-map*
+  }
+any-date =
+  number-day
+  | number-month
+  | number-year
+  | number-era
+  | number-day-of-week
+  | number-week-of-year
+  | number-quarter
+  | number-hours
+  | number-am-pm
+  | number-minutes
+  | number-seconds
+number-day =
+  element number:day {
+    number-day-attlist, common-calendar-attlist, empty
+  }
+number-day-attlist = attribute number:style { "short" | "long" }?
+number-month =
+  element number:month {
+    number-month-attlist, common-calendar-attlist, empty
+  }
+number-month-attlist =
+  attribute number:textual { boolean }?
+  & attribute number:possessive-form { boolean }?
+  & attribute number:style { "short" | "long" }?
+number-year =
+  element number:year {
+    number-year-attlist, common-calendar-attlist, empty
+  }
+number-year-attlist = attribute number:style { "short" | "long" }?
+number-era =
+  element number:era {
+    number-era-attlist, common-calendar-attlist, empty
+  }
+number-era-attlist = attribute number:style { "short" | "long" }?
+number-day-of-week =
+  element number:day-of-week {
+    number-day-of-week-attlist, common-calendar-attlist, empty
+  }
+number-day-of-week-attlist =
+  attribute number:style { "short" | "long" }?
+number-week-of-year =
+  element number:week-of-year { common-calendar-attlist, empty }
+number-quarter =
+  element number:quarter {
+    number-quarter-attlist, common-calendar-attlist, empty
+  }
+number-quarter-attlist = attribute number:style { "short" | "long" }?
+number-time-style =
+  element number:time-style {
+    number-time-style-attlist,
+    common-data-style-attlist,
+    common-format-source-attlist,
+    style-text-properties?,
+    number-text?,
+    (any-time, number-text?)+,
+    style-map*
+  }
+any-time = number-hours | number-am-pm | number-minutes | number-seconds
+number-time-style-attlist =
+  attribute number:truncate-on-overflow { boolean }?
+number-hours = element number:hours { number-hours-attlist, empty }
+number-hours-attlist = attribute number:style { "short" | "long" }?
+number-minutes =
+  element number:minutes { number-minutes-attlist, empty }
+number-minutes-attlist = attribute number:style { "short" | "long" }?
+number-seconds =
+  element number:seconds { number-seconds-attlist, empty }
+number-seconds-attlist =
+  attribute number:style { "short" | "long" }?
+  & attribute number:decimal-places { integer }?
+number-am-pm = element number:am-pm { empty }
+number-boolean-style =
+  element number:boolean-style {
+    common-data-style-attlist,
+    style-text-properties?,
+    number-text?,
+    (number-boolean, number-text?)?,
+    style-map*
+  }
+number-boolean = element number:boolean { empty }
+number-text-style =
+  element number:text-style {
+    common-data-style-attlist,
+    style-text-properties?,
+    number-text?,
+    (number-text-content, number-text?)*,
+    style-map*
+  }
+number-text = element number:text { text }
+number-text-content = element number:text-content { empty }
+common-data-style-attlist =
+  attribute style:name { styleName }
+  & attribute style:display-name { \string }?
+  & attribute number:language { languageCode }?
+  & attribute number:country { countryCode }?
+  & attribute number:script { scriptCode }?
+  & attribute number:rfc-language-tag { language }?
+  & attribute number:title { \string }?
+  & attribute style:volatile { boolean }?
+  & attribute number:transliteration-format { \string }?
+  & attribute number:transliteration-language { countryCode }?
+  & attribute number:transliteration-country { countryCode }?
+  & attribute number:transliteration-style {
+      "short" | "medium" | "long"
+    }?
+common-auto-reorder-attlist =
+  attribute number:automatic-order { boolean }?
+common-format-source-attlist =
+  attribute number:format-source { "fixed" | "language" }?
+common-decimal-places-attlist =
+  attribute number:decimal-places { integer }?
+common-number-attlist =
+  attribute number:min-integer-digits { integer }?
+  & attribute number:grouping { boolean }?
+common-calendar-attlist =
+  attribute number:calendar {
+    "gregorian"
+    | "gengou"
+    | "ROC"
+    | "hanja_yoil"
+    | "hanja"
+    | "hijri"
+    | "jewish"
+    | "buddhist"
+    | \string
+  }?
+style-style-content =
+  (attribute style:family { "text" },
+   style-text-properties?)
+  | (attribute style:family { "paragraph" },
+     style-paragraph-properties?,
+     style-text-properties?)
+  | (attribute style:family { "section" },
+     style-section-properties?)
+  | (attribute style:family { "ruby" },
+     style-ruby-properties?)
+  | (attribute style:family { "table" },
+     style-table-properties?)
+  | (attribute style:family { "table-column" },
+     style-table-column-properties?)
+  | (attribute style:family { "table-row" },
+     style-table-row-properties?)
+  | (attribute style:family { "table-cell" },
+     style-table-cell-properties?,
+     style-paragraph-properties?,
+     style-text-properties?)
+  | (attribute style:family { "graphic" | "presentation" },
+     style-graphic-properties?,
+     style-paragraph-properties?,
+     style-text-properties?)
+  | (attribute style:family { "drawing-page" },
+     style-drawing-page-properties?)
+  | (attribute style:family { "chart" },
+     style-chart-properties?,
+     style-graphic-properties?,
+     style-paragraph-properties?,
+     style-text-properties?)
+text-linenumbering-configuration =
+  element text:linenumbering-configuration {
+    text-linenumbering-configuration-attlist,
+    text-linenumbering-separator?
+  }
+text-linenumbering-configuration-attlist =
+  attribute text:number-lines { boolean }?
+  & common-num-format-attlist?
+  & attribute text:style-name { styleNameRef }?
+  & attribute text:increment { nonNegativeInteger }?
+  & attribute text:number-position {
+      "left" | "right" | "inner" | "outer"
+    }?
+  & attribute text:offset { nonNegativeLength }?
+  & attribute text:count-empty-lines { boolean }?
+  & attribute text:count-in-text-boxes { boolean }?
+  & attribute text:restart-on-page { boolean }?
+text-linenumbering-separator =
+  element text:linenumbering-separator {
+    attribute text:increment { nonNegativeInteger }?,
+    text
+  }
+text-notes-configuration =
+  element text:notes-configuration { text-notes-configuration-content }
+text-notes-configuration-content =
+  text-note-class
+  & attribute text:citation-style-name { styleNameRef }?
+  & attribute text:citation-body-style-name { styleNameRef }?
+  & attribute text:default-style-name { styleNameRef }?
+  & attribute text:master-page-name { styleNameRef }?
+  & attribute text:start-value { nonNegativeInteger }?
+  & common-num-format-prefix-suffix-attlist
+  & common-num-format-attlist?
+  & attribute text:start-numbering-at {
+      "document" | "chapter" | "page"
+    }?
+  & attribute text:footnotes-position {
+      "text" | "page" | "section" | "document"
+    }?
+  & element text:note-continuation-notice-forward { text }?
+  & element text:note-continuation-notice-backward { text }?
+text-bibliography-configuration =
+  element text:bibliography-configuration {
+    text-bibliography-configuration-attlist, text-sort-key*
+  }
+text-bibliography-configuration-attlist =
+  attribute text:prefix { \string }?
+  & attribute text:suffix { \string }?
+  & attribute text:numbered-entries { boolean }?
+  & attribute text:sort-by-position { boolean }?
+  & attribute fo:language { languageCode }?
+  & attribute fo:country { countryCode }?
+  & attribute fo:script { scriptCode }?
+  & attribute style:rfc-language-tag { language }?
+  & attribute text:sort-algorithm { \string }?
+text-sort-key = element text:sort-key { text-sort-key-attlist, empty }
+text-sort-key-attlist =
+  attribute text:key {
+    "address"
+    | "annote"
+    | "author"
+    | "bibliography-type"
+    | "booktitle"
+    | "chapter"
+    | "custom1"
+    | "custom2"
+    | "custom3"
+    | "custom4"
+    | "custom5"
+    | "edition"
+    | "editor"
+    | "howpublished"
+    | "identifier"
+    | "institution"
+    | "isbn"
+    | "issn"
+    | "journal"
+    | "month"
+    | "note"
+    | "number"
+    | "organizations"
+    | "pages"
+    | "publisher"
+    | "report-type"
+    | "school"
+    | "series"
+    | "title"
+    | "url"
+    | "volume"
+    | "year"
+  },
+  attribute text:sort-ascending { boolean }?
+text-list-style =
+  element text:list-style {
+    text-list-style-attr, text-list-style-content*
+  }
+text-list-style-attr =
+  attribute style:name { styleName }
+  & attribute style:display-name { \string }?
+  & attribute text:consecutive-numbering { boolean }?
+text-list-style-content =
+  element text:list-level-style-number {
+    text-list-level-style-attr,
+    text-list-level-style-number-attr,
+    style-list-level-properties?,
+    style-text-properties?
+  }
+  | element text:list-level-style-bullet {
+      text-list-level-style-attr,
+      text-list-level-style-bullet-attr,
+      style-list-level-properties?,
+      style-text-properties?
+    }
+  | element text:list-level-style-image {
+      text-list-level-style-attr,
+      text-list-level-style-image-attr,
+      style-list-level-properties?
+    }
+text-list-level-style-number-attr =
+  attribute text:style-name { styleNameRef }?
+  & common-num-format-attlist
+  & common-num-format-prefix-suffix-attlist
+  & attribute text:display-levels { positiveInteger }?
+  & attribute text:start-value { positiveInteger }?
+text-list-level-style-bullet-attr =
+  attribute text:style-name { styleNameRef }?
+  & attribute text:bullet-char { character }
+  & common-num-format-prefix-suffix-attlist
+  & attribute text:bullet-relative-size { percent }?
+text-list-level-style-image-attr =
+  common-draw-data-attlist | office-binary-data
+text-list-level-style-attr = attribute text:level { positiveInteger }
+text-outline-style =
+  element text:outline-style {
+    text-outline-style-attr, text-outline-level-style+
+  }
+text-outline-style-attr = attribute style:name { styleName }
+text-outline-level-style =
+  element text:outline-level-style {
+    text-outline-level-style-attlist,
+    style-list-level-properties?,
+    style-text-properties?
+  }
+text-outline-level-style-attlist =
+  attribute text:level { positiveInteger }
+  & attribute text:style-name { styleNameRef }?
+  & common-num-format-attlist
+  & common-num-format-prefix-suffix-attlist
+  & attribute text:display-levels { positiveInteger }?
+  & attribute text:start-value { positiveInteger }?
+style-graphic-properties =
+  element style:graphic-properties {
+    style-graphic-properties-content-strict
+  }
+style-graphic-properties-content-strict =
+  style-graphic-properties-attlist,
+  style-graphic-fill-properties-attlist,
+  style-graphic-properties-elements
+style-drawing-page-properties =
+  element style:drawing-page-properties {
+    style-drawing-page-properties-content-strict
+  }
+style-drawing-page-properties-content-strict =
+  style-graphic-fill-properties-attlist,
+  style-drawing-page-properties-attlist,
+  style-drawing-page-properties-elements
+draw-gradient =
+  element draw:gradient {
+    common-draw-gradient-attlist, draw-gradient-attlist, empty
+  }
+common-draw-gradient-attlist =
+  attribute draw:name { styleName }?
+  & attribute draw:display-name { \string }?
+  & attribute draw:style { gradient-style }
+  & attribute draw:cx { percent }?
+  & attribute draw:cy { percent }?
+  & attribute draw:angle { angle }?
+  & attribute draw:border { percent }?
+gradient-style =
+  "linear" | "axial" | "radial" | "ellipsoid" | "square" | "rectangular"
+draw-gradient-attlist =
+  attribute draw:start-color { color }?
+  & attribute draw:end-color { color }?
+  & attribute draw:start-intensity { zeroToHundredPercent }?
+  & attribute draw:end-intensity { zeroToHundredPercent }?
+svg-linearGradient =
+  element svg:linearGradient {
+    common-svg-gradient-attlist,
+    attribute svg:x1 { coordinate | percent }?,
+    attribute svg:y1 { coordinate | percent }?,
+    attribute svg:x2 { coordinate | percent }?,
+    attribute svg:y2 { coordinate | percent }?,
+    svg-stop*
+  }
+svg-radialGradient =
+  element svg:radialGradient {
+    common-svg-gradient-attlist,
+    attribute svg:cx { coordinate | percent }?,
+    attribute svg:cy { coordinate | percent }?,
+    attribute svg:r { coordinate | percent }?,
+    attribute svg:fx { coordinate | percent }?,
+    attribute svg:fy { coordinate | percent }?,
+    svg-stop*
+  }
+svg-stop =
+  element svg:stop {
+    attribute svg:offset { double | percent },
+    attribute svg:stop-color { color }?,
+    attribute svg:stop-opacity { double }?
+  }
+common-svg-gradient-attlist =
+  attribute svg:gradientUnits { "objectBoundingBox" }?
+  & attribute svg:gradientTransform { \string }?
+  & attribute svg:spreadMethod { "pad" | "reflect" | "repeat" }?
+  & attribute draw:name { styleName }
+  & attribute draw:display-name { \string }?
+draw-hatch = element draw:hatch { draw-hatch-attlist, empty }
+draw-hatch-attlist =
+  attribute draw:name { styleName }
+  & attribute draw:display-name { \string }?
+  & attribute draw:style { "single" | "double" | "triple" }
+  & attribute draw:color { color }?
+  & attribute draw:distance { length }?
+  & attribute draw:rotation { angle }?
+draw-fill-image =
+  element draw:fill-image {
+    draw-fill-image-attlist,
+    attribute xlink:type { "simple" },
+    attribute xlink:href { anyIRI },
+    attribute xlink:show { "embed" }?,
+    attribute xlink:actuate { "onLoad" }?,
+    empty
+  }
+draw-fill-image-attlist =
+  attribute draw:name { styleName }
+  & attribute draw:display-name { \string }?
+  & attribute svg:width { length }?
+  & attribute svg:height { length }?
+draw-opacity =
+  element draw:opacity {
+    common-draw-gradient-attlist, draw-opacity-attlist, empty
+  }
+draw-opacity-attlist =
+  attribute draw:start { zeroToHundredPercent }?,
+  attribute draw:end { zeroToHundredPercent }?
+draw-marker =
+  element draw:marker {
+    draw-marker-attlist,
+    common-draw-viewbox-attlist,
+    common-draw-path-data-attlist,
+    empty
+  }
+draw-marker-attlist =
+  attribute draw:name { styleName }
+  & attribute draw:display-name { \string }?
+draw-stroke-dash =
+  element draw:stroke-dash { draw-stroke-dash-attlist, empty }
+draw-stroke-dash-attlist =
+  attribute draw:name { styleName }
+  & attribute draw:display-name { \string }?
+  & attribute draw:style { "rect" | "round" }?
+  & attribute draw:dots1 { integer }?
+  & attribute draw:dots1-length { length | percent }?
+  & attribute draw:dots2 { integer }?
+  & attribute draw:dots2-length { length | percent }?
+  & attribute draw:distance { length | percent }?
+style-presentation-page-layout =
+  element style:presentation-page-layout {
+    attribute style:name { styleName },
+    attribute style:display-name { \string }?,
+    presentation-placeholder*
+  }
+presentation-placeholder =
+  element presentation:placeholder {
+    attribute presentation:object { presentation-classes },
+    attribute svg:x { coordinate | percent },
+    attribute svg:y { coordinate | percent },
+    attribute svg:width { length | percent },
+    attribute svg:height { length | percent },
+    empty
+  }
+style-page-layout-properties =
+  element style:page-layout-properties {
+    style-page-layout-properties-content-strict
+  }
+style-page-layout-properties-content-strict =
+  style-page-layout-properties-attlist,
+  style-page-layout-properties-elements
+style-page-layout-properties-attlist =
+  attribute fo:page-width { length }?
+  & attribute fo:page-height { length }?
+  & common-num-format-attlist?
+  & common-num-format-prefix-suffix-attlist
+  & attribute style:paper-tray-name { "default" | \string }?
+  & attribute style:print-orientation { "portrait" | "landscape" }?
+  & common-horizontal-margin-attlist
+  & common-vertical-margin-attlist
+  & common-margin-attlist
+  & common-border-attlist
+  & common-border-line-width-attlist
+  & common-padding-attlist
+  & common-shadow-attlist
+  & common-background-color-attlist
+  & attribute style:register-truth-ref-style-name { styleNameRef }?
+  & attribute style:print {
+      list {
+        ("headers"
+         | "grid"
+         | "annotations"
+         | "objects"
+         | "charts"
+         | "drawings"
+         | "formulas"
+         | "zero-values")*
+      }
+    }?
+  & attribute style:print-page-order { "ttb" | "ltr" }?
+  & attribute style:first-page-number { positiveInteger | "continue" }?
+  & attribute style:scale-to { percent }?
+  & attribute style:scale-to-pages { positiveInteger }?
+  & attribute style:table-centering {
+      "horizontal" | "vertical" | "both" | "none"
+    }?
+  & attribute style:footnote-max-height { length }?
+  & common-writing-mode-attlist
+  & attribute style:layout-grid-mode { "none" | "line" | "both" }?
+  & attribute style:layout-grid-standard-mode { boolean }?
+  & attribute style:layout-grid-base-height { length }?
+  & attribute style:layout-grid-ruby-height { length }?
+  & attribute style:layout-grid-lines { positiveInteger }?
+  & attribute style:layout-grid-base-width { length }?
+  & attribute style:layout-grid-color { color }?
+  & attribute style:layout-grid-ruby-below { boolean }?
+  & attribute style:layout-grid-print { boolean }?
+  & attribute style:layout-grid-display { boolean }?
+  & attribute style:layout-grid-snap-to { boolean }?
+style-page-layout-properties-elements =
+  style-background-image & style-columns & style-footnote-sep
+style-footnote-sep =
+  element style:footnote-sep { style-footnote-sep-attlist, empty }?
+style-footnote-sep-attlist =
+  attribute style:width { length }?,
+  attribute style:rel-width { percent }?,
+  attribute style:color { color }?,
+  attribute style:line-style { lineStyle }?,
+  attribute style:adjustment { "left" | "center" | "right" }?,
+  attribute style:distance-before-sep { length }?,
+  attribute style:distance-after-sep { length }?
+style-header-footer-properties =
+  element style:header-footer-properties {
+    style-header-footer-properties-content-strict
+  }
+style-header-footer-properties-content-strict =
+  style-header-footer-properties-attlist,
+  style-header-footer-properties-elements
+style-header-footer-properties-attlist =
+  attribute svg:height { length }?
+  & attribute fo:min-height { length }?
+  & common-horizontal-margin-attlist
+  & common-vertical-margin-attlist
+  & common-margin-attlist
+  & common-border-attlist
+  & common-border-line-width-attlist
+  & common-padding-attlist
+  & common-background-color-attlist
+  & common-shadow-attlist
+  & attribute style:dynamic-spacing { boolean }?
+style-header-footer-properties-elements = style-background-image
+style-text-properties =
+  element style:text-properties { style-text-properties-content-strict }
+style-text-properties-content-strict =
+  style-text-properties-attlist, style-text-properties-elements
+style-text-properties-elements = empty
+style-text-properties-attlist =
+  attribute fo:font-variant { fontVariant }?
+  & attribute fo:text-transform {
+      "none" | "lowercase" | "uppercase" | "capitalize"
+    }?
+  & attribute fo:color { color }?
+  & attribute style:use-window-font-color { boolean }?
+  & attribute style:text-outline { boolean }?
+  & attribute style:text-line-through-type { lineType }?
+  & attribute style:text-line-through-style { lineStyle }?
+  & attribute style:text-line-through-width { lineWidth }?
+  & attribute style:text-line-through-color { "font-color" | color }?
+  & attribute style:text-line-through-text { \string }?
+  & attribute style:text-line-through-text-style { styleNameRef }?
+  & attribute style:text-position {
+      list { (percent | "super" | "sub"), percent? }
+    }?
+  & attribute style:font-name { \string }?
+  & attribute style:font-name-asian { \string }?
+  & attribute style:font-name-complex { \string }?
+  & attribute fo:font-family { \string }?
+  & attribute style:font-family-asian { \string }?
+  & attribute style:font-family-complex { \string }?
+  & attribute style:font-family-generic { fontFamilyGeneric }?
+  & attribute style:font-family-generic-asian { fontFamilyGeneric }?
+  & attribute style:font-family-generic-complex { fontFamilyGeneric }?
+  & attribute style:font-style-name { \string }?
+  & attribute style:font-style-name-asian { \string }?
+  & attribute style:font-style-name-complex { \string }?
+  & attribute style:font-pitch { fontPitch }?
+  & attribute style:font-pitch-asian { fontPitch }?
+  & attribute style:font-pitch-complex { fontPitch }?
+  & attribute style:font-charset { textEncoding }?
+  & attribute style:font-charset-asian { textEncoding }?
+  & attribute style:font-charset-complex { textEncoding }?
+  & attribute fo:font-size { positiveLength | percent }?
+  & attribute style:font-size-asian { positiveLength | percent }?
+  & attribute style:font-size-complex { positiveLength | percent }?
+  & attribute style:font-size-rel { length }?
+  & attribute style:font-size-rel-asian { length }?
+  & attribute style:font-size-rel-complex { length }?
+  & attribute style:script-type {
+      "latin" | "asian" | "complex" | "ignore"
+    }?
+  & attribute fo:letter-spacing { length | "normal" }?
+  & attribute fo:language { languageCode }?
+  & attribute style:language-asian { languageCode }?
+  & attribute style:language-complex { languageCode }?
+  & attribute fo:country { countryCode }?
+  & attribute style:country-asian { countryCode }?
+  & attribute style:country-complex { countryCode }?
+  & attribute fo:script { scriptCode }?
+  & attribute style:script-asian { scriptCode }?
+  & attribute style:script-complex { scriptCode }?
+  & attribute style:rfc-language-tag { language }?
+  & attribute style:rfc-language-tag-asian { language }?
+  & attribute style:rfc-language-tag-complex { language }?
+  & attribute fo:font-style { fontStyle }?
+  & attribute style:font-style-asian { fontStyle }?
+  & attribute style:font-style-complex { fontStyle }?
+  & attribute style:font-relief { "none" | "embossed" | "engraved" }?
+  & attribute fo:text-shadow { shadowType }?
+  & attribute style:text-underline-type { lineType }?
+  & attribute style:text-underline-style { lineStyle }?
+  & attribute style:text-underline-width { lineWidth }?
+  & attribute style:text-underline-color { "font-color" | color }?
+  & attribute style:text-overline-type { lineType }?
+  & attribute style:text-overline-style { lineStyle }?
+  & attribute style:text-overline-width { lineWidth }?
+  & attribute style:text-overline-color { "font-color" | color }?
+  & attribute style:text-overline-mode { lineMode }?
+  & attribute fo:font-weight { fontWeight }?
+  & attribute style:font-weight-asian { fontWeight }?
+  & attribute style:font-weight-complex { fontWeight }?
+  & attribute style:text-underline-mode { lineMode }?
+  & attribute style:text-line-through-mode { lineMode }?
+  & attribute style:letter-kerning { boolean }?
+  & attribute style:text-blinking { boolean }?
+  & common-background-color-attlist
+  & attribute style:text-combine { "none" | "letters" | "lines" }?
+  & attribute style:text-combine-start-char { character }?
+  & attribute style:text-combine-end-char { character }?
+  & attribute style:text-emphasize {
+      "none"
+      | list {
+          ("none" | "accent" | "dot" | "circle" | "disc"),
+          ("above" | "below")
+        }
+    }?
+  & attribute style:text-scale { percent }?
+  & attribute style:text-rotation-angle { angle }?
+  & attribute style:text-rotation-scale { "fixed" | "line-height" }?
+  & attribute fo:hyphenate { boolean }?
+  & attribute fo:hyphenation-remain-char-count { positiveInteger }?
+  & attribute fo:hyphenation-push-char-count { positiveInteger }?
+  & (attribute text:display { "true" }
+     | attribute text:display { "none" }
+     | (attribute text:display { "condition" },
+        attribute text:condition { "none" })
+     | empty)
+fontVariant = "normal" | "small-caps"
+fontFamilyGeneric =
+  "roman" | "swiss" | "modern" | "decorative" | "script" | "system"
+fontPitch = "fixed" | "variable"
+textEncoding = xsd:string { pattern = "[A-Za-z][A-Za-z0-9._\-]*" }
+fontStyle = "normal" | "italic" | "oblique"
+shadowType = "none" | \string
+lineType = "none" | "single" | "double"
+lineStyle =
+  "none"
+  | "solid"
+  | "dotted"
+  | "dash"
+  | "long-dash"
+  | "dot-dash"
+  | "dot-dot-dash"
+  | "wave"
+lineWidth =
+  "auto"
+  | "normal"
+  | "bold"
+  | "thin"
+  | "medium"
+  | "thick"
+  | positiveInteger
+  | percent
+  | positiveLength
+fontWeight =
+  "normal"
+  | "bold"
+  | "100"
+  | "200"
+  | "300"
+  | "400"
+  | "500"
+  | "600"
+  | "700"
+  | "800"
+  | "900"
+lineMode = "continuous" | "skip-white-space"
+style-paragraph-properties =
+  element style:paragraph-properties {
+    style-paragraph-properties-content-strict
+  }
+style-paragraph-properties-content-strict =
+  style-paragraph-properties-attlist,
+  style-paragraph-properties-elements
+style-paragraph-properties-attlist =
+  attribute fo:line-height { "normal" | nonNegativeLength | percent }?
+  & attribute style:line-height-at-least { nonNegativeLength }?
+  & attribute style:line-spacing { length }?
+  & attribute style:font-independent-line-spacing { boolean }?
+  & common-text-align
+  & attribute fo:text-align-last { "start" | "center" | "justify" }?
+  & attribute style:justify-single-word { boolean }?
+  & attribute fo:keep-together { "auto" | "always" }?
+  & attribute fo:widows { nonNegativeInteger }?
+  & attribute fo:orphans { nonNegativeInteger }?
+  & attribute style:tab-stop-distance { nonNegativeLength }?
+  & attribute fo:hyphenation-keep { "auto" | "page" }?
+  & attribute fo:hyphenation-ladder-count {
+      "no-limit" | positiveInteger
+    }?
+  & attribute style:register-true { boolean }?
+  & common-horizontal-margin-attlist
+  & attribute fo:text-indent { length | percent }?
+  & attribute style:auto-text-indent { boolean }?
+  & common-vertical-margin-attlist
+  & common-margin-attlist
+  & common-break-attlist
+  & common-background-color-attlist
+  & common-border-attlist
+  & common-border-line-width-attlist
+  & attribute style:join-border { boolean }?
+  & common-padding-attlist
+  & common-shadow-attlist
+  & common-keep-with-next-attlist
+  & attribute text:number-lines { boolean }?
+  & attribute text:line-number { nonNegativeInteger }?
+  & attribute style:text-autospace { "none" | "ideograph-alpha" }?
+  & attribute style:punctuation-wrap { "simple" | "hanging" }?
+  & attribute style:line-break { "normal" | "strict" }?
+  & attribute style:vertical-align {
+      "top" | "middle" | "bottom" | "auto" | "baseline"
+    }?
+  & common-writing-mode-attlist
+  & attribute style:writing-mode-automatic { boolean }?
+  & attribute style:snap-to-layout-grid { boolean }?
+  & common-page-number-attlist
+  & common-background-transparency-attlist
+common-text-align =
+  attribute fo:text-align {
+    "start" | "end" | "left" | "right" | "center" | "justify"
+  }?
+style-paragraph-properties-elements =
+  style-tab-stops & style-drop-cap & style-background-image
+style-tab-stops = element style:tab-stops { style-tab-stop* }?
+style-tab-stop =
+  element style:tab-stop { style-tab-stop-attlist, empty }
+style-tab-stop-attlist =
+  attribute style:position { length }
+  & (attribute style:type { "left" | "center" | "right" }?
+     | (attribute style:type { "char" },
+        style-tab-stop-char-attlist))
+  & attribute style:leader-type { lineType }?
+  & attribute style:leader-style { lineStyle }?
+  & attribute style:leader-width { lineWidth }?
+  & attribute style:leader-color { "font-color" | color }?
+  & attribute style:leader-text { character }?
+  & attribute style:leader-text-style { styleNameRef }?
+style-tab-stop-char-attlist = attribute style:char { character }
+style-drop-cap =
+  element style:drop-cap { style-drop-cap-attlist, empty }?
+style-drop-cap-attlist =
+  attribute style:length { "word" | positiveInteger }?
+  & attribute style:lines { positiveInteger }?
+  & attribute style:distance { length }?
+  & attribute style:style-name { styleNameRef }?
+common-horizontal-margin-attlist =
+  attribute fo:margin-left { length | percent }?,
+  attribute fo:margin-right { length | percent }?
+common-vertical-margin-attlist =
+  attribute fo:margin-top { nonNegativeLength | percent }?,
+  attribute fo:margin-bottom { nonNegativeLength | percent }?
+common-margin-attlist =
+  attribute fo:margin { nonNegativeLength | percent }?
+common-break-attlist =
+  attribute fo:break-before { "auto" | "column" | "page" }?,
+  attribute fo:break-after { "auto" | "column" | "page" }?
+common-background-color-attlist =
+  attribute fo:background-color { "transparent" | color }?
+style-background-image =
+  element style:background-image {
+    style-background-image-attlist,
+    (common-draw-data-attlist | office-binary-data | empty)
+  }?
+style-background-image-attlist =
+  attribute style:repeat { "no-repeat" | "repeat" | "stretch" }?
+  & attribute style:position {
+      "left"
+      | "center"
+      | "right"
+      | "top"
+      | "bottom"
+      | list { horiBackPos, vertBackPos }
+      | list { vertBackPos, horiBackPos }
+    }?
+  & attribute style:filter-name { \string }?
+  & attribute draw:opacity { zeroToHundredPercent }?
+horiBackPos = "left" | "center" | "right"
+vertBackPos = "top" | "center" | "bottom"
+common-border-attlist =
+  attribute fo:border { \string }?,
+  attribute fo:border-top { \string }?,
+  attribute fo:border-bottom { \string }?,
+  attribute fo:border-left { \string }?,
+  attribute fo:border-right { \string }?
+common-border-line-width-attlist =
+  attribute style:border-line-width { borderWidths }?,
+  attribute style:border-line-width-top { borderWidths }?,
+  attribute style:border-line-width-bottom { borderWidths }?,
+  attribute style:border-line-width-left { borderWidths }?,
+  attribute style:border-line-width-right { borderWidths }?
+borderWidths = list { positiveLength, positiveLength, positiveLength }
+common-padding-attlist =
+  attribute fo:padding { nonNegativeLength }?,
+  attribute fo:padding-top { nonNegativeLength }?,
+  attribute fo:padding-bottom { nonNegativeLength }?,
+  attribute fo:padding-left { nonNegativeLength }?,
+  attribute fo:padding-right { nonNegativeLength }?
+common-shadow-attlist = attribute style:shadow { shadowType }?
+common-keep-with-next-attlist =
+  attribute fo:keep-with-next { "auto" | "always" }?
+common-writing-mode-attlist =
+  attribute style:writing-mode {
+    "lr-tb" | "rl-tb" | "tb-rl" | "tb-lr" | "lr" | "rl" | "tb" | "page"
+  }?
+common-page-number-attlist =
+  attribute style:page-number { positiveInteger | "auto" }?
+common-background-transparency-attlist =
+  attribute style:background-transparency { zeroToHundredPercent }?
+style-ruby-properties =
+  element style:ruby-properties { style-ruby-properties-content-strict }
+style-ruby-properties-content-strict =
+  style-ruby-properties-attlist, style-ruby-properties-elements
+style-ruby-properties-elements = empty
+style-ruby-properties-attlist =
+  attribute style:ruby-position { "above" | "below" }?
+  & attribute style:ruby-align {
+      "left"
+      | "center"
+      | "right"
+      | "distribute-letter"
+      | "distribute-space"
+    }?
+style-section-properties =
+  element style:section-properties {
+    style-section-properties-content-strict
+  }
+style-section-properties-content-strict =
+  style-section-properties-attlist, style-section-properties-elements
+style-section-properties-attlist =
+  common-background-color-attlist
+  & common-horizontal-margin-attlist
+  & attribute style:protect { boolean }?
+  & common-editable-attlist
+  & attribute text:dont-balance-text-columns { boolean }?
+  & common-writing-mode-attlist
+style-section-properties-elements =
+  style-background-image & style-columns & text-notes-configuration*
+style-columns =
+  element style:columns {
+    style-columns-attlist, style-column-sep?, style-column*
+  }?
+style-columns-attlist =
+  attribute fo:column-count { positiveInteger }
+  & attribute fo:column-gap { length }?
+style-column = element style:column { style-column-attlist }
+style-column-attlist =
+  attribute style:rel-width { relativeLength }
+  & attribute fo:start-indent { length }?
+  & attribute fo:end-indent { length }?
+  & attribute fo:space-before { length }?
+  & attribute fo:space-after { length }?
+style-column-sep = element style:column-sep { style-column-sep-attlist }
+style-column-sep-attlist =
+  attribute style:style {
+    "none" | "solid" | "dotted" | "dashed" | "dot-dashed"
+  }?
+  & attribute style:width { length }
+  & attribute style:height { zeroToHundredPercent }?
+  & attribute style:vertical-align { "top" | "middle" | "bottom" }?
+  & attribute style:color { color }?
+style-table-properties =
+  element style:table-properties {
+    style-table-properties-content-strict
+  }
+style-table-properties-content-strict =
+  style-table-properties-attlist, style-table-properties-elements
+style-table-properties-attlist =
+  attribute style:width { positiveLength }?
+  & attribute style:rel-width { percent }?
+  & attribute table:align { "left" | "center" | "right" | "margins" }?
+  & common-horizontal-margin-attlist
+  & common-vertical-margin-attlist
+  & common-margin-attlist
+  & common-page-number-attlist
+  & common-break-attlist
+  & common-background-color-attlist
+  & common-shadow-attlist
+  & common-keep-with-next-attlist
+  & attribute style:may-break-between-rows { boolean }?
+  & attribute table:border-model { "collapsing" | "separating" }?
+  & common-writing-mode-attlist
+  & attribute table:display { boolean }?
+style-table-properties-elements = style-background-image
+style-table-column-properties =
+  element style:table-column-properties {
+    style-table-column-properties-content-strict
+  }
+style-table-column-properties-content-strict =
+  style-table-column-properties-attlist,
+  style-table-column-properties-elements
+style-table-column-properties-elements = empty
+style-table-column-properties-attlist =
+  attribute style:column-width { positiveLength }?
+  & attribute style:rel-column-width { relativeLength }?
+  & attribute style:use-optimal-column-width { boolean }?
+  & common-break-attlist
+style-table-row-properties =
+  element style:table-row-properties {
+    style-table-row-properties-content-strict
+  }
+style-table-row-properties-content-strict =
+  style-table-row-properties-attlist,
+  style-table-row-properties-elements
+style-table-row-properties-attlist =
+  attribute style:row-height { positiveLength }?
+  & attribute style:min-row-height { nonNegativeLength }?
+  & attribute style:use-optimal-row-height { boolean }?
+  & common-background-color-attlist
+  & common-break-attlist
+  & attribute fo:keep-together { "auto" | "always" }?
+style-table-row-properties-elements = style-background-image
+style-table-cell-properties =
+  element style:table-cell-properties {
+    style-table-cell-properties-content-strict
+  }
+style-table-cell-properties-content-strict =
+  style-table-cell-properties-attlist,
+  style-table-cell-properties-elements
+style-table-cell-properties-attlist =
+  attribute style:vertical-align {
+    "top" | "middle" | "bottom" | "automatic"
+  }?
+  & attribute style:text-align-source { "fix" | "value-type" }?
+  & common-style-direction-attlist
+  & attribute style:glyph-orientation-vertical {
+      "auto" | "0" | "0deg" | "0rad" | "0grad"
+    }?
+  & common-writing-mode-attlist
+  & common-shadow-attlist
+  & common-background-color-attlist
+  & common-border-attlist
+  & attribute style:diagonal-tl-br { \string }?
+  & attribute style:diagonal-tl-br-widths { borderWidths }?
+  & attribute style:diagonal-bl-tr { \string }?
+  & attribute style:diagonal-bl-tr-widths { borderWidths }?
+  & common-border-line-width-attlist
+  & common-padding-attlist
+  & attribute fo:wrap-option { "no-wrap" | "wrap" }?
+  & common-rotation-angle-attlist
+  & attribute style:rotation-align {
+      "none" | "bottom" | "top" | "center"
+    }?
+  & attribute style:cell-protect {
+      "none"
+      | "hidden-and-protected"
+      | list { ("protected" | "formula-hidden")+ }
+    }?
+  & attribute style:print-content { boolean }?
+  & attribute style:decimal-places { nonNegativeInteger }?
+  & attribute style:repeat-content { boolean }?
+  & attribute style:shrink-to-fit { boolean }?
+common-style-direction-attlist =
+  attribute style:direction { "ltr" | "ttb" }?
+style-table-cell-properties-elements = style-background-image
+common-rotation-angle-attlist =
+  attribute style:rotation-angle { angle }?
+style-list-level-properties =
+  element style:list-level-properties {
+    style-list-level-properties-content-strict
+  }
+style-list-level-properties-content-strict =
+  style-list-level-properties-attlist,
+  style-list-level-properties-elements
+style-list-level-properties-attlist =
+  common-text-align
+  & attribute text:space-before { length }?
+  & attribute text:min-label-width { nonNegativeLength }?
+  & attribute text:min-label-distance { nonNegativeLength }?
+  & attribute style:font-name { \string }?
+  & attribute fo:width { positiveLength }?
+  & attribute fo:height { positiveLength }?
+  & common-vertical-rel-attlist
+  & common-vertical-pos-attlist
+  & attribute text:list-level-position-and-space-mode {
+      "label-width-and-position" | "label-alignment"
+    }?
+style-list-level-properties-elements = style-list-level-label-alignment
+style-list-level-label-alignment =
+  element style:list-level-label-alignment {
+    style-list-level-label-alignment-attlist, empty
+  }?
+style-list-level-label-alignment-attlist =
+  attribute text:label-followed-by { "listtab" | "space" | "nothing" }
+  & attribute text:list-tab-stop-position { length }?
+  & attribute fo:text-indent { length }?
+  & attribute fo:margin-left { length }?
+style-graphic-properties-attlist =
+  attribute draw:stroke { "none" | "dash" | "solid" }?
+  & attribute draw:stroke-dash { styleNameRef }?
+  & attribute draw:stroke-dash-names { styleNameRefs }?
+  & attribute svg:stroke-width { length }?
+  & attribute svg:stroke-color { color }?
+  & attribute draw:marker-start { styleNameRef }?
+  & attribute draw:marker-end { styleNameRef }?
+  & attribute draw:marker-start-width { length }?
+  & attribute draw:marker-end-width { length }?
+  & attribute draw:marker-start-center { boolean }?
+  & attribute draw:marker-end-center { boolean }?
+  & attribute svg:stroke-opacity {
+      xsd:double { minInclusive = "0" maxInclusive = "1" }
+      | zeroToHundredPercent
+    }?
+  & attribute draw:stroke-linejoin {
+      "miter" | "round" | "bevel" | "middle" | "none"
+    }?
+  & attribute svg:stroke-linecap { "butt" | "square" | "round" }?
+  & attribute draw:symbol-color { color }?
+  & attribute text:animation {
+      "none" | "scroll" | "alternate" | "slide"
+    }?
+  & attribute text:animation-direction {
+      "left" | "right" | "up" | "down"
+    }?
+  & attribute text:animation-start-inside { boolean }?
+  & attribute text:animation-stop-inside { boolean }?
+  & attribute text:animation-repeat { nonNegativeInteger }?
+  & attribute text:animation-delay { duration }?
+  & attribute text:animation-steps { length }?
+  & attribute draw:auto-grow-width { boolean }?
+  & attribute draw:auto-grow-height { boolean }?
+  & attribute draw:fit-to-size { boolean }?
+  & attribute draw:fit-to-contour { boolean }?
+  & attribute draw:textarea-vertical-align {
+      "top" | "middle" | "bottom" | "justify"
+    }?
+  & attribute draw:textarea-horizontal-align {
+      "left" | "center" | "right" | "justify"
+    }?
+  & attribute fo:wrap-option { "no-wrap" | "wrap" }?
+  & attribute style:shrink-to-fit { boolean }?
+  & attribute draw:color-mode {
+      "greyscale" | "mono" | "watermark" | "standard"
+    }?
+  & attribute draw:color-inversion { boolean }?
+  & attribute draw:luminance { zeroToHundredPercent }?
+  & attribute draw:contrast { percent }?
+  & attribute draw:gamma { percent }?
+  & attribute draw:red { signedZeroToHundredPercent }?
+  & attribute draw:green { signedZeroToHundredPercent }?
+  & attribute draw:blue { signedZeroToHundredPercent }?
+  & attribute draw:image-opacity { zeroToHundredPercent }?
+  & attribute draw:shadow { "visible" | "hidden" }?
+  & attribute draw:shadow-offset-x { length }?
+  & attribute draw:shadow-offset-y { length }?
+  & attribute draw:shadow-color { color }?
+  & attribute draw:shadow-opacity { zeroToHundredPercent }?
+  & attribute draw:start-line-spacing-horizontal { distance }?
+  & attribute draw:start-line-spacing-vertical { distance }?
+  & attribute draw:end-line-spacing-horizontal { distance }?
+  & attribute draw:end-line-spacing-vertical { distance }?
+  & attribute draw:line-distance { distance }?
+  & attribute draw:guide-overhang { length }?
+  & attribute draw:guide-distance { distance }?
+  & attribute draw:start-guide { length }?
+  & attribute draw:end-guide { length }?
+  & attribute draw:placing { "below" | "above" }?
+  & attribute draw:parallel { boolean }?
+  & attribute draw:measure-align {
+      "automatic" | "left-outside" | "inside" | "right-outside"
+    }?
+  & attribute draw:measure-vertical-align {
+      "automatic" | "above" | "below" | "center"
+    }?
+  & attribute draw:unit {
+      "automatic"
+      | "mm"
+      | "cm"
+      | "m"
+      | "km"
+      | "pt"
+      | "pc"
+      | "inch"
+      | "ft"
+      | "mi"
+    }?
+  & attribute draw:show-unit { boolean }?
+  & attribute draw:decimal-places { nonNegativeInteger }?
+  & attribute draw:caption-type {
+      "straight-line" | "angled-line" | "angled-connector-line"
+    }?
+  & attribute draw:caption-angle-type { "fixed" | "free" }?
+  & attribute draw:caption-angle { angle }?
+  & attribute draw:caption-gap { distance }?
+  & attribute draw:caption-escape-direction {
+      "horizontal" | "vertical" | "auto"
+    }?
+  & attribute draw:caption-escape { length | percent }?
+  & attribute draw:caption-line-length { length }?
+  & attribute draw:caption-fit-line-length { boolean }?
+  & attribute dr3d:horizontal-segments { nonNegativeInteger }?
+  & attribute dr3d:vertical-segments { nonNegativeInteger }?
+  & attribute dr3d:edge-rounding { percent }?
+  & attribute dr3d:edge-rounding-mode { "correct" | "attractive" }?
+  & attribute dr3d:back-scale { percent }?
+  & attribute dr3d:depth { length }?
+  & attribute dr3d:backface-culling { "enabled" | "disabled" }?
+  & attribute dr3d:end-angle { angle }?
+  & attribute dr3d:close-front { boolean }?
+  & attribute dr3d:close-back { boolean }?
+  & attribute dr3d:lighting-mode { "standard" | "double-sided" }?
+  & attribute dr3d:normals-kind { "object" | "flat" | "sphere" }?
+  & attribute dr3d:normals-direction { "normal" | "inverse" }?
+  & attribute dr3d:texture-generation-mode-x {
+      "object" | "parallel" | "sphere"
+    }?
+  & attribute dr3d:texture-generation-mode-y {
+      "object" | "parallel" | "sphere"
+    }?
+  & attribute dr3d:texture-kind { "luminance" | "intensity" | "color" }?
+  & attribute dr3d:texture-filter { "enabled" | "disabled" }?
+  & attribute dr3d:texture-mode { "replace" | "modulate" | "blend" }?
+  & attribute dr3d:ambient-color { color }?
+  & attribute dr3d:emissive-color { color }?
+  & attribute dr3d:specular-color { color }?
+  & attribute dr3d:diffuse-color { color }?
+  & attribute dr3d:shininess { percent }?
+  & attribute dr3d:shadow { "visible" | "hidden" }?
+  & common-draw-rel-size-attlist
+  & attribute fo:min-width { length | percent }?
+  & attribute fo:min-height { length | percent }?
+  & attribute fo:max-height { length | percent }?
+  & attribute fo:max-width { length | percent }?
+  & common-horizontal-margin-attlist
+  & common-vertical-margin-attlist
+  & common-margin-attlist
+  & attribute style:print-content { boolean }?
+  & attribute style:protect {
+      "none"
+      | list { ("content" | "position" | "size")+ }
+    }?
+  & attribute style:horizontal-pos {
+      "left"
+      | "center"
+      | "right"
+      | "from-left"
+      | "inside"
+      | "outside"
+      | "from-inside"
+    }?
+  & attribute svg:x { coordinate }?
+  & attribute style:horizontal-rel {
+      "page"
+      | "page-content"
+      | "page-start-margin"
+      | "page-end-margin"
+      | "frame"
+      | "frame-content"
+      | "frame-start-margin"
+      | "frame-end-margin"
+      | "paragraph"
+      | "paragraph-content"
+      | "paragraph-start-margin"
+      | "paragraph-end-margin"
+      | "char"
+    }?
+  & common-vertical-pos-attlist
+  & common-vertical-rel-attlist
+  & common-text-anchor-attlist
+  & common-border-attlist
+  & common-border-line-width-attlist
+  & common-padding-attlist
+  & common-shadow-attlist
+  & common-background-color-attlist
+  & common-background-transparency-attlist
+  & common-editable-attlist
+  & attribute style:wrap {
+      "none"
+      | "left"
+      | "right"
+      | "parallel"
+      | "dynamic"
+      | "run-through"
+      | "biggest"
+    }?
+  & attribute style:wrap-dynamic-threshold { nonNegativeLength }?
+  & attribute style:number-wrapped-paragraphs {
+      "no-limit" | positiveInteger
+    }?
+  & attribute style:wrap-contour { boolean }?
+  & attribute style:wrap-contour-mode { "full" | "outside" }?
+  & attribute style:run-through { "foreground" | "background" }?
+  & attribute style:flow-with-text { boolean }?
+  & attribute style:overflow-behavior {
+      "clip" | "auto-create-new-frame"
+    }?
+  & attribute style:mirror {
+      "none"
+      | "vertical"
+      | horizontal-mirror
+      | list { "vertical", horizontal-mirror }
+      | list { horizontal-mirror, "vertical" }
+    }?
+  & attribute fo:clip { "auto" | clipShape }?
+  & attribute draw:wrap-influence-on-position {
+      "iterative" | "once-concurrent" | "once-successive"
+    }?
+  & common-writing-mode-attlist
+  & attribute draw:frame-display-scrollbar { boolean }?
+  & attribute draw:frame-display-border { boolean }?
+  & attribute draw:frame-margin-horizontal { nonNegativePixelLength }?
+  & attribute draw:frame-margin-vertical { nonNegativePixelLength }?
+  & attribute draw:visible-area-left { nonNegativeLength }?
+  & attribute draw:visible-area-top { nonNegativeLength }?
+  & attribute draw:visible-area-width { positiveLength }?
+  & attribute draw:visible-area-height { positiveLength }?
+  & attribute draw:draw-aspect {
+      "content" | "thumbnail" | "icon" | "print-view"
+    }?
+  & attribute draw:ole-draw-aspect { nonNegativeInteger }?
+style-graphic-fill-properties-attlist =
+  attribute draw:fill {
+    "none" | "solid" | "bitmap" | "gradient" | "hatch"
+  }?
+  & attribute draw:fill-color { color }?
+  & attribute draw:secondary-fill-color { color }?
+  & attribute draw:fill-gradient-name { styleNameRef }?
+  & attribute draw:gradient-step-count { nonNegativeInteger }?
+  & attribute draw:fill-hatch-name { styleNameRef }?
+  & attribute draw:fill-hatch-solid { boolean }?
+  & attribute draw:fill-image-name { styleNameRef }?
+  & attribute style:repeat { "no-repeat" | "repeat" | "stretch" }?
+  & attribute draw:fill-image-width { length | percent }?
+  & attribute draw:fill-image-height { length | percent }?
+  & attribute draw:fill-image-ref-point-x { percent }?
+  & attribute draw:fill-image-ref-point-y { percent }?
+  & attribute draw:fill-image-ref-point {
+      "top-left"
+      | "top"
+      | "top-right"
+      | "left"
+      | "center"
+      | "right"
+      | "bottom-left"
+      | "bottom"
+      | "bottom-right"
+    }?
+  & attribute draw:tile-repeat-offset {
+      list { zeroToHundredPercent, ("horizontal" | "vertical") }
+    }?
+  & attribute draw:opacity { zeroToHundredPercent }?
+  & attribute draw:opacity-name { styleNameRef }?
+  & attribute svg:fill-rule { "nonzero" | "evenodd" }?
+style-graphic-properties-elements =
+  text-list-style? & style-background-image & style-columns
+common-vertical-pos-attlist =
+  attribute style:vertical-pos {
+    "top" | "middle" | "bottom" | "from-top" | "below"
+  }?,
+  attribute svg:y { coordinate }?
+common-vertical-rel-attlist =
+  attribute style:vertical-rel {
+    "page"
+    | "page-content"
+    | "frame"
+    | "frame-content"
+    | "paragraph"
+    | "paragraph-content"
+    | "char"
+    | "line"
+    | "baseline"
+    | "text"
+  }?
+common-editable-attlist = attribute style:editable { boolean }?
+horizontal-mirror =
+  "horizontal" | "horizontal-on-odd" | "horizontal-on-even"
+clipShape =
+  xsd:string {
+    pattern =
+      "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}[ ]*\)"
+  }
+nonNegativePixelLength =
+  xsd:string { pattern = "([0-9]+(\.[0-9]*)?|\.[0-9]+)(px)" }
+style-chart-properties =
+  element style:chart-properties {
+    style-chart-properties-content-strict
+  }
+style-chart-properties-content-strict =
+  style-chart-properties-attlist, style-chart-properties-elements
+style-chart-properties-elements = empty
+style-chart-properties-attlist =
+  attribute chart:scale-text { boolean }?
+  & attribute chart:three-dimensional { boolean }?
+  & attribute chart:deep { boolean }?
+  & attribute chart:right-angled-axes { boolean }?
+  & (attribute chart:symbol-type { "none" }
+     | attribute chart:symbol-type { "automatic" }
+     | (attribute chart:symbol-type { "named-symbol" },
+        attribute chart:symbol-name {
+          "square"
+          | "diamond"
+          | "arrow-down"
+          | "arrow-up"
+          | "arrow-right"
+          | "arrow-left"
+          | "bow-tie"
+          | "hourglass"
+          | "circle"
+          | "star"
+          | "x"
+          | "plus"
+          | "asterisk"
+          | "horizontal-bar"
+          | "vertical-bar"
+        })
+     | (attribute chart:symbol-type { "image" },
+        element chart:symbol-image {
+          attribute xlink:href { anyIRI }
+        })
+     | empty)
+  & attribute chart:symbol-width { nonNegativeLength }?
+  & attribute chart:symbol-height { nonNegativeLength }?
+  & attribute chart:sort-by-x-values { boolean }?
+  & attribute chart:vertical { boolean }?
+  & attribute chart:connect-bars { boolean }?
+  & attribute chart:gap-width { integer }?
+  & attribute chart:overlap { integer }?
+  & attribute chart:group-bars-per-axis { boolean }?
+  & attribute chart:japanese-candle-stick { boolean }?
+  & attribute chart:interpolation {
+      "none" | "cubic-spline" | "b-spline"
+    }?
+  & attribute chart:spline-order { positiveInteger }?
+  & attribute chart:spline-resolution { positiveInteger }?
+  & attribute chart:pie-offset { nonNegativeInteger }?
+  & attribute chart:angle-offset { angle }?
+  & attribute chart:hole-size { percent }?
+  & attribute chart:lines { boolean }?
+  & attribute chart:solid-type {
+      "cuboid" | "cylinder" | "cone" | "pyramid"
+    }?
+  & attribute chart:stacked { boolean }?
+  & attribute chart:percentage { boolean }?
+  & attribute chart:treat-empty-cells {
+      "use-zero" | "leave-gap" | "ignore"
+    }?
+  & attribute chart:link-data-style-to-source { boolean }?
+  & attribute chart:logarithmic { boolean }?
+  & attribute chart:maximum { double }?
+  & attribute chart:minimum { double }?
+  & attribute chart:origin { double }?
+  & attribute chart:interval-major { double }?
+  & attribute chart:interval-minor-divisor { positiveInteger }?
+  & attribute chart:tick-marks-major-inner { boolean }?
+  & attribute chart:tick-marks-major-outer { boolean }?
+  & attribute chart:tick-marks-minor-inner { boolean }?
+  & attribute chart:tick-marks-minor-outer { boolean }?
+  & attribute chart:reverse-direction { boolean }?
+  & attribute chart:display-label { boolean }?
+  & attribute chart:text-overlap { boolean }?
+  & attribute text:line-break { boolean }?
+  & attribute chart:label-arrangement {
+      "side-by-side" | "stagger-even" | "stagger-odd"
+    }?
+  & common-style-direction-attlist
+  & common-rotation-angle-attlist
+  & attribute chart:data-label-number {
+      "none" | "value" | "percentage" | "value-and-percentage"
+    }?
+  & attribute chart:data-label-text { boolean }?
+  & attribute chart:data-label-symbol { boolean }?
+  & element chart:label-separator { text-p }?
+  & attribute chart:label-position { labelPositions }?
+  & attribute chart:label-position-negative { labelPositions }?
+  & attribute chart:visible { boolean }?
+  & attribute chart:auto-position { boolean }?
+  & attribute chart:auto-size { boolean }?
+  & attribute chart:mean-value { boolean }?
+  & attribute chart:error-category {
+      "none"
+      | "variance"
+      | "standard-deviation"
+      | "percentage"
+      | "error-margin"
+      | "constant"
+      | "standard-error"
+      | "cell-range"
+    }?
+  & attribute chart:error-percentage { double }?
+  & attribute chart:error-margin { double }?
+  & attribute chart:error-lower-limit { double }?
+  & attribute chart:error-upper-limit { double }?
+  & attribute chart:error-upper-indicator { boolean }?
+  & attribute chart:error-lower-indicator { boolean }?
+  & attribute chart:error-lower-range { cellRangeAddressList }?
+  & attribute chart:error-upper-range { cellRangeAddressList }?
+  & attribute chart:series-source { "columns" | "rows" }?
+  & attribute chart:regression-type {
+      "none" | "linear" | "logarithmic" | "exponential" | "power"
+    }?
+  & attribute chart:axis-position { "start" | "end" | double }?
+  & attribute chart:axis-label-position {
+      "near-axis"
+      | "near-axis-other-side"
+      | "outside-start"
+      | "outside-end"
+    }?
+  & attribute chart:tick-mark-position {
+      "at-labels" | "at-axis" | "at-labels-and-axis"
+    }?
+  & attribute chart:include-hidden-cells { boolean }?
+labelPositions =
+  "avoid-overlap"
+  | "center"
+  | "top"
+  | "top-right"
+  | "right"
+  | "bottom-right"
+  | "bottom"
+  | "bottom-left"
+  | "left"
+  | "top-left"
+  | "inside"
+  | "outside"
+  | "near-origin"
+style-drawing-page-properties-attlist =
+  attribute presentation:transition-type {
+    "manual" | "automatic" | "semi-automatic"
+  }?
+  & attribute presentation:transition-style {
+      "none"
+      | "fade-from-left"
+      | "fade-from-top"
+      | "fade-from-right"
+      | "fade-from-bottom"
+      | "fade-from-upperleft"
+      | "fade-from-upperright"
+      | "fade-from-lowerleft"
+      | "fade-from-lowerright"
+      | "move-from-left"
+      | "move-from-top"
+      | "move-from-right"
+      | "move-from-bottom"
+      | "move-from-upperleft"
+      | "move-from-upperright"
+      | "move-from-lowerleft"
+      | "move-from-lowerright"
+      | "uncover-to-left"
+      | "uncover-to-top"
+      | "uncover-to-right"
+      | "uncover-to-bottom"
+      | "uncover-to-upperleft"
+      | "uncover-to-upperright"
+      | "uncover-to-lowerleft"
+      | "uncover-to-lowerright"
+      | "fade-to-center"
+      | "fade-from-center"
+      | "vertical-stripes"
+      | "horizontal-stripes"
+      | "clockwise"
+      | "counterclockwise"
+      | "open-vertical"
+      | "open-horizontal"
+      | "close-vertical"
+      | "close-horizontal"
+      | "wavyline-from-left"
+      | "wavyline-from-top"
+      | "wavyline-from-right"
+      | "wavyline-from-bottom"
+      | "spiralin-left"
+      | "spiralin-right"
+      | "spiralout-left"
+      | "spiralout-right"
+      | "roll-from-top"
+      | "roll-from-left"
+      | "roll-from-right"
+      | "roll-from-bottom"
+      | "stretch-from-left"
+      | "stretch-from-top"
+      | "stretch-from-right"
+      | "stretch-from-bottom"
+      | "vertical-lines"
+      | "horizontal-lines"
+      | "dissolve"
+      | "random"
+      | "vertical-checkerboard"
+      | "horizontal-checkerboard"
+      | "interlocking-horizontal-left"
+      | "interlocking-horizontal-right"
+      | "interlocking-vertical-top"
+      | "interlocking-vertical-bottom"
+      | "fly-away"
+      | "open"
+      | "close"
+      | "melt"
+    }?
+  & attribute presentation:transition-speed { presentationSpeeds }?
+  & attribute smil:type { \string }?
+  & attribute smil:subtype { \string }?
+  & attribute smil:direction { "forward" | "reverse" }?
+  & attribute smil:fadeColor { color }?
+  & attribute presentation:duration { duration }?
+  & attribute presentation:visibility { "visible" | "hidden" }?
+  & attribute draw:background-size { "full" | "border" }?
+  & attribute presentation:background-objects-visible { boolean }?
+  & attribute presentation:background-visible { boolean }?
+  & attribute presentation:display-header { boolean }?
+  & attribute presentation:display-footer { boolean }?
+  & attribute presentation:display-page-number { boolean }?
+  & attribute presentation:display-date-time { boolean }?
+style-drawing-page-properties-elements = presentation-sound?
+\string = xsd:string
+date = xsd:date
+time = xsd:time
+dateTime = xsd:dateTime
+duration = xsd:duration
+integer = xsd:integer
+nonNegativeInteger = xsd:nonNegativeInteger
+positiveInteger = xsd:positiveInteger
+double = xsd:double
+anyURI = xsd:anyURI
+base64Binary = xsd:base64Binary
+ID = xsd:ID
+IDREF = xsd:IDREF
+IDREFS = xsd:IDREFS
+NCName = xsd:NCName
+boolean = "true" | "false"
+dateOrDateTime = xsd:date | xsd:dateTime
+timeOrDateTime = xsd:time | xsd:dateTime
+language = xsd:language
+countryCode = xsd:token { pattern = "[A-Za-z0-9]{1,8}" }
+languageCode = xsd:token { pattern = "[A-Za-z]{1,8}" }
+scriptCode = xsd:token { pattern = "[A-Za-z0-9]{1,8}" }
+character = xsd:string { length = "1" }
+length =
+  xsd:string {
+    pattern =
+      "-?([0-9]+(\.[0-9]*)?|\.[0-9]+)((cm)|(mm)|(in)|(pt)|(pc)|(px))"
+  }
+nonNegativeLength =
+  xsd:string {
+    pattern =
+      "([0-9]+(\.[0-9]*)?|\.[0-9]+)((cm)|(mm)|(in)|(pt)|(pc)|(px))"
+  }
+positiveLength =
+  xsd:string {
+    pattern =
+      "([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))"
+  }
+percent = xsd:string { pattern = "-?([0-9]+(\.[0-9]*)?|\.[0-9]+)%" }
+zeroToHundredPercent =
+  xsd:string {
+    pattern = "([0-9]?[0-9](\.[0-9]*)?|100(\.0*)?|\.[0-9]+)%"
+  }
+signedZeroToHundredPercent =
+  xsd:string {
+    pattern = "-?([0-9]?[0-9](\.[0-9]*)?|100(\.0*)?|\.[0-9]+)%"
+  }
+relativeLength = xsd:string { pattern = "[0-9]+\*" }
+coordinate = length
+distance = length
+color = xsd:string { pattern = "#[0-9a-fA-F]{6}" }
+angle = xsd:string
+CURIE =
+  xsd:string { pattern = "(([\i-[:]][\c-[:]]*)?:)?.+" minLength = "1" }
+CURIEs = list { CURIE+ }
+SafeCURIE =
+  xsd:string {
+    pattern = "\[(([\i-[:]][\c-[:]]*)?:)?.+\]"
+    minLength = "3"
+  }
+URIorSafeCURIE = anyURI | SafeCURIE
+styleName = xsd:NCName
+styleNameRef = xsd:NCName | empty
+styleNameRefs = list { xsd:NCName* }
+variableName = xsd:string
+targetFrameName = "_self" | "_blank" | "_parent" | "_top" | \string
+valueType =
+  "float"
+  | "time"
+  | "date"
+  | "percentage"
+  | "currency"
+  | "boolean"
+  | "string"
+points =
+  xsd:string { pattern = "-?[0-9]+,-?[0-9]+([ ]+-?[0-9]+,-?[0-9]+)*" }
+pathData = xsd:string
+vector3D =
+  xsd:string {
+    pattern =
+      "\([ ]*-?([0-9]+(\.[0-9]*)?|\.[0-9]+)([ ]+-?([0-9]+(\.[0-9]*)?|\.[0-9]+)){2}[ ]*\)"
+  }
+namespacedToken = xsd:QName { pattern = "[^:]+:[^:]+" }
+anyIRI =
+  xsd:anyURI
+  >> dc:description [
+       "An IRI-reference as defined in [RFC3987]. See ODF 1.2 Part 1 section 18.3."
+     ]
+anyAttListOrElements =
+  attribute * { text }*,
+  anyElements
+anyElements =
+  element * {
+    mixed { anyAttListOrElements }
+  }*

+ 7 - 0
contrib/odt/etc/schema/schemas.xml

@@ -0,0 +1,7 @@
+<?xml version="1.0"?>
+<locatingRules xmlns="http://thaiopensource.com/ns/locating-rules/1.0">
+  <documentElement prefix="office" typeId="OpenDocument"/>
+  <documentElement prefix="manifest" localName="manifest" typeId="OpenDocument Manifest"/>
+  <typeId id="OpenDocument" uri="od-schema-v1.2-cs01.rnc"/>
+  <typeId id="OpenDocument Manifest" uri="od-manifest-schema-v1.2-cs01.rnc"/>
+</locatingRules>

+ 152 - 0
contrib/odt/styles/OrgOdtAutomaticStyles.xml

@@ -0,0 +1,152 @@
+  <!-- scripts -->
+  <office:scripts/>
+
+  <!-- font face declarations -->
+  <office:font-face-decls>
+    <style:font-face style:name="Tahoma1" svg:font-family="Tahoma"/>
+    <style:font-face style:name="courier" svg:font-family="courier, monospace"/>
+    <style:font-face style:name="Arial Unicode MS" svg:font-family="&apos;Arial Unicode MS&apos;" style:font-pitch="variable"/>
+    <style:font-face style:name="HG Mincho Light J" svg:font-family="&apos;HG Mincho Light J&apos;" style:font-pitch="variable"/>
+    <style:font-face style:name="Thorndale" svg:font-family="Thorndale" style:font-family-generic="roman" style:font-pitch="variable"/>
+    <style:font-face style:name="Times New Roman" svg:font-family="&apos;Times New Roman&apos;" style:font-family-generic="roman" style:font-pitch="variable"/>
+    <style:font-face style:name="Albany" svg:font-family="Albany" style:font-family-generic="swiss" style:font-pitch="variable"/>
+    <style:font-face style:name="SimSun" svg:font-family="SimSun" style:font-family-generic="system" style:font-pitch="variable"/>
+    <style:font-face style:name="Tahoma" svg:font-family="Tahoma" style:font-family-generic="system" style:font-pitch="variable"/>
+  </office:font-face-decls>
+
+  <!-- automatic styles -->
+  <office:automatic-styles>
+  <style:style style:name="OrgTable" style:family="table">
+   <style:table-properties style:width="12cm" table:align="center"/>
+  </style:style>
+  <style:style style:name="OrgTblCell" style:family="table-cell">
+      <style:table-cell-properties style:vertical-align="middle" fo:padding="0.159cm" fo:border-top="none" fo:border-bottom="none" fo:border-left="none" fo:border-right="none"/>
+    </style:style>
+  <style:style style:name="OrgTblCellL" style:family="table-cell">
+      <style:table-cell-properties style:vertical-align="middle" fo:padding="0.159cm" fo:border-top="none" fo:border-bottom="none" fo:border-left="0.035cm solid #808080" fo:border-right="none"/>
+    </style:style>
+  <style:style style:name="OrgTblCellR" style:family="table-cell">
+      <style:table-cell-properties style:vertical-align="middle" fo:padding="0.159cm" fo:border-top="none" fo:border-bottom="none" fo:border-left="none" fo:border-right="0.035cm solid #808080"/>
+    </style:style>
+  <style:style style:name="OrgTblCellLR" style:family="table-cell">
+      <style:table-cell-properties style:vertical-align="middle" fo:padding="0.159cm" fo:border-top="none" fo:border-bottom="none" fo:border-left="0.035cm solid #808080" fo:border-right="0.035cm solid #808080"/>
+    </style:style>
+  <style:style style:name="OrgTblCellT" style:family="table-cell">
+      <style:table-cell-properties style:vertical-align="middle" fo:padding="0.159cm" fo:border-top="0.035cm solid #808080" fo:border-bottom="none" fo:border-left="none" fo:border-right="none"/>
+    </style:style>
+  <style:style style:name="OrgTblCellTL" style:family="table-cell">
+      <style:table-cell-properties style:vertical-align="middle" fo:padding="0.159cm" fo:border-top="0.035cm solid #808080" fo:border-bottom="none" fo:border-left="0.035cm solid #808080" fo:border-right="none"/>
+    </style:style>
+  <style:style style:name="OrgTblCellTR" style:family="table-cell">
+      <style:table-cell-properties style:vertical-align="middle" fo:padding="0.159cm" fo:border-top="0.035cm solid #808080" fo:border-bottom="none" fo:border-left="none" fo:border-right="0.035cm solid #808080"/>
+    </style:style>
+  <style:style style:name="OrgTblCellTLR" style:family="table-cell">
+      <style:table-cell-properties style:vertical-align="middle" fo:padding="0.159cm" fo:border-top="0.035cm solid #808080" fo:border-bottom="none" fo:border-left="0.035cm solid #808080" fo:border-right="0.035cm solid #808080"/>
+    </style:style>
+  <style:style style:name="OrgTblCellB" style:family="table-cell">
+      <style:table-cell-properties style:vertical-align="middle" fo:padding="0.159cm" fo:border-top="none" fo:border-bottom="0.035cm solid #808080" fo:border-left="none" fo:border-right="none"/>
+    </style:style>
+  <style:style style:name="OrgTblCellBL" style:family="table-cell">
+      <style:table-cell-properties style:vertical-align="middle" fo:padding="0.159cm" fo:border-top="none" fo:border-bottom="0.035cm solid #808080" fo:border-left="0.035cm solid #808080" fo:border-right="none"/>
+    </style:style>
+  <style:style style:name="OrgTblCellBR" style:family="table-cell">
+      <style:table-cell-properties style:vertical-align="middle" fo:padding="0.159cm" fo:border-top="none" fo:border-bottom="0.035cm solid #808080" fo:border-left="none" fo:border-right="0.035cm solid #808080"/>
+    </style:style>
+  <style:style style:name="OrgTblCellBLR" style:family="table-cell">
+      <style:table-cell-properties style:vertical-align="middle" fo:padding="0.159cm" fo:border-top="none" fo:border-bottom="0.035cm solid #808080" fo:border-left="0.035cm solid #808080" fo:border-right="0.035cm solid #808080"/>
+    </style:style>
+  <style:style style:name="OrgTblCellTB" style:family="table-cell">
+      <style:table-cell-properties style:vertical-align="middle" fo:padding="0.159cm" fo:border-top="0.035cm solid #808080" fo:border-bottom="0.035cm solid #808080" fo:border-left="none" fo:border-right="none"/>
+    </style:style>
+  <style:style style:name="OrgTblCellTBL" style:family="table-cell">
+      <style:table-cell-properties style:vertical-align="middle" fo:padding="0.159cm" fo:border-top="0.035cm solid #808080" fo:border-bottom="0.035cm solid #808080" fo:border-left="0.035cm solid #808080" fo:border-right="none"/>
+    </style:style>
+  <style:style style:name="OrgTblCellTBR" style:family="table-cell">
+      <style:table-cell-properties style:vertical-align="middle" fo:padding="0.159cm" fo:border-top="0.035cm solid #808080" fo:border-bottom="0.035cm solid #808080" fo:border-left="none" fo:border-right="0.035cm solid #808080"/>
+    </style:style>
+  <style:style style:name="OrgTblCellTBLR" style:family="table-cell">
+      <style:table-cell-properties style:vertical-align="middle" fo:padding="0.159cm" fo:border-top="0.035cm solid #808080" fo:border-bottom="0.035cm solid #808080" fo:border-left="0.035cm solid #808080" fo:border-right="0.035cm solid #808080"/>
+    </style:style>
+    <style:style style:name="OrgFrame" 
+		 style:family="graphic" 
+		 style:parent-style-name="Frame">
+      <style:graphic-properties fo:margin-left="0cm" 
+				fo:margin-right="0cm" 
+				fo:margin-top="0cm" 
+				fo:margin-bottom="0cm" 
+				style:run-through="foreground" 
+				style:wrap="none" 
+				style:vertical-pos="top" 
+				style:vertical-rel="paragraph" 
+				style:horizontal-pos="center" 
+				style:horizontal-rel="paragraph" 
+				fo:padding="0cm" fo:border="none" 
+				style:shadow="none"/>
+    </style:style>
+
+    <style:style style:name="OrgGraphicsParagraphContent" 
+		 style:family="graphic" 
+		 style:parent-style-name="Graphics">
+      <style:graphic-properties fo:margin-left="0cm" 
+				fo:margin-right="0cm" 
+				fo:margin-top="0cm" 
+				fo:margin-bottom="0cm" 
+				style:run-through="foreground" 
+				style:wrap="none" 
+				style:vertical-pos="from-top" 
+				style:vertical-rel="paragraph-content" 
+				style:horizontal-pos="from-left" 
+				style:horizontal-rel="paragraph-content" 
+				fo:padding="0cm" 
+				fo:border="none" 
+				style:shadow="none" 
+				style:mirror="none" 
+				fo:clip="rect(0cm, 0cm, 0cm, 0cm)" 
+				draw:luminance="0%" 
+				draw:contrast="0%" 
+				draw:red="0%" 
+				draw:green="0%" 
+				draw:blue="0%" 
+				draw:gamma="100%" 
+				draw:color-inversion="false" 
+				draw:image-opacity="100%" 
+				draw:color-mode="standard"/>
+    </style:style>
+
+    <style:style style:name="OrgGraphicsBaseline" 
+		 style:family="graphic" 
+		 style:parent-style-name="Graphics">
+      <style:graphic-properties style:vertical-pos="top" 
+				style:vertical-rel="baseline" 
+				style:mirror="none" 
+				fo:clip="rect(0cm, 0cm, 0cm, 0cm)" 
+				draw:luminance="0%" 
+				draw:contrast="0%" 
+				draw:red="0%" 
+				draw:green="0%" 
+				draw:blue="0%" 
+				draw:gamma="100%" 
+				draw:color-inversion="false" 
+				draw:image-opacity="100%" 
+				draw:color-mode="standard"/>
+    </style:style>
+
+    <style:style style:name="OrgGraphicsParagraph" 
+		 style:family="graphic" 
+		 style:parent-style-name="Graphics">
+      <style:graphic-properties style:horizontal-pos="center" 
+				style:horizontal-rel="paragraph" 
+				style:mirror="none" 
+				fo:clip="rect(0cm, 0cm, 0cm, 0cm)" 
+				draw:luminance="0%" 
+				draw:contrast="0%" 
+				draw:red="0%" 
+				draw:green="0%" 
+				draw:blue="0%" 
+				draw:gamma="100%" 
+				draw:color-inversion="false" 
+				draw:image-opacity="100%" 
+				draw:color-mode="standard"/>
+    </style:style>
+
+  </office:automatic-styles>

+ 668 - 0
contrib/odt/styles/OrgOdtStyles.xml

@@ -0,0 +1,668 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<office:document-styles xmlns:office="urn:oasis:names:tc:opendocument:xmlns:office:1.0" xmlns:style="urn:oasis:names:tc:opendocument:xmlns:style:1.0" xmlns:text="urn:oasis:names:tc:opendocument:xmlns:text:1.0" xmlns:table="urn:oasis:names:tc:opendocument:xmlns:table:1.0" xmlns:draw="urn:oasis:names:tc:opendocument:xmlns:drawing:1.0" xmlns:fo="urn:oasis:names:tc:opendocument:xmlns:xsl-fo-compatible:1.0" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:meta="urn:oasis:names:tc:opendocument:xmlns:meta:1.0" xmlns:number="urn:oasis:names:tc:opendocument:xmlns:datastyle:1.0" xmlns:svg="urn:oasis:names:tc:opendocument:xmlns:svg-compatible:1.0" xmlns:chart="urn:oasis:names:tc:opendocument:xmlns:chart:1.0" xmlns:dr3d="urn:oasis:names:tc:opendocument:xmlns:dr3d:1.0" xmlns:math="http://www.w3.org/1998/Math/MathML" xmlns:form="urn:oasis:names:tc:opendocument:xmlns:form:1.0" xmlns:script="urn:oasis:names:tc:opendocument:xmlns:script:1.0" xmlns:ooo="http://openoffice.org/2004/office" xmlns:ooow="http://openoffice.org/2004/writer" xmlns:oooc="http://openoffice.org/2004/calc" xmlns:dom="http://www.w3.org/2001/xml-events" xmlns:rpt="http://openoffice.org/2005/report" xmlns:of="urn:oasis:names:tc:opendocument:xmlns:of:1.2" xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:grddl="http://www.w3.org/2003/g/data-view#" office:version="1.2">
+ <office:font-face-decls>
+  <style:font-face style:name="OpenSymbol" svg:font-family="OpenSymbol"/>
+  <style:font-face style:name="Tahoma1" svg:font-family="Tahoma"/>
+  <style:font-face style:name="Courier New" svg:font-family="&apos;Courier New&apos;" style:font-family-generic="modern" style:font-pitch="fixed"/>
+  <style:font-face style:name="NSimSun" svg:font-family="NSimSun" style:font-family-generic="modern" style:font-pitch="fixed"/>
+  <style:font-face style:name="Times New Roman" svg:font-family="&apos;Times New Roman&apos;" style:font-family-generic="roman" style:font-pitch="variable"/>
+  <style:font-face style:name="Arial" svg:font-family="Arial" style:font-family-generic="swiss" style:font-pitch="variable"/>
+  <style:font-face style:name="SimSun" svg:font-family="SimSun" style:font-family-generic="system" style:font-pitch="variable"/>
+  <style:font-face style:name="Tahoma" svg:font-family="Tahoma" style:font-family-generic="system" style:font-pitch="variable"/>
+ </office:font-face-decls>
+ <office:styles>
+  <style:default-style style:family="graphic">
+   <style:graphic-properties draw:shadow-offset-x="0.3cm" draw:shadow-offset-y="0.3cm" draw:start-line-spacing-horizontal="0.283cm" draw:start-line-spacing-vertical="0.283cm" draw:end-line-spacing-horizontal="0.283cm" draw:end-line-spacing-vertical="0.283cm" style:flow-with-text="false"/>
+   <style:paragraph-properties style:text-autospace="ideograph-alpha" style:line-break="strict" style:writing-mode="lr-tb" style:font-independent-line-spacing="false">
+    <style:tab-stops/>
+   </style:paragraph-properties>
+   <style:text-properties style:use-window-font-color="true" fo:font-size="12pt" fo:language="en" fo:country="GB" style:letter-kerning="true" style:font-size-asian="12pt" style:language-asian="zh" style:country-asian="CN" style:font-size-complex="12pt" style:language-complex="hi" style:country-complex="IN"/>
+  </style:default-style>
+  <style:default-style style:family="paragraph">
+   <style:paragraph-properties fo:hyphenation-ladder-count="no-limit" style:text-autospace="ideograph-alpha" style:punctuation-wrap="hanging" style:line-break="strict" style:tab-stop-distance="1.251cm" style:writing-mode="page"/>
+   <style:text-properties style:use-window-font-color="true" style:font-name="Times New Roman" fo:font-size="12pt" fo:language="en" fo:country="GB" style:letter-kerning="true" style:font-name-asian="SimSun" style:font-size-asian="12pt" style:language-asian="zh" style:country-asian="CN" style:font-name-complex="Tahoma" style:font-size-complex="12pt" style:language-complex="hi" style:country-complex="IN" fo:hyphenate="false" fo:hyphenation-remain-char-count="2" fo:hyphenation-push-char-count="2"/>
+  </style:default-style>
+  <style:default-style style:family="table">
+   <style:table-properties table:border-model="collapsing"/>
+  </style:default-style>
+  <style:default-style style:family="table-row">
+   <style:table-row-properties fo:keep-together="auto"/>
+  </style:default-style>
+
+  <!-- Outline numbering -->
+  <text:outline-style>
+   <text:outline-level-style text:level="1" style:num-suffix=". " style:num-format="1">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="nothing" fo:text-indent="-0.762cm" fo:margin-left="0.762cm"/>
+    </style:list-level-properties>
+   </text:outline-level-style>
+   <text:outline-level-style text:level="2" style:num-suffix=". " style:num-format="1" text:display-levels="2">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="nothing" fo:text-indent="-1.016cm" fo:margin-left="1.016cm"/>
+    </style:list-level-properties>
+   </text:outline-level-style>
+   <text:outline-level-style text:level="3" style:num-suffix=". " style:num-format="1" text:display-levels="3">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="nothing" fo:text-indent="-1.27cm" fo:margin-left="1.27cm"/>
+    </style:list-level-properties>
+   </text:outline-level-style>
+   <text:outline-level-style text:level="4" style:num-suffix=". " style:num-format="1" text:display-levels="4">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="nothing" fo:text-indent="-1.524cm" fo:margin-left="1.524cm"/>
+    </style:list-level-properties>
+   </text:outline-level-style>
+   <text:outline-level-style text:level="5" style:num-suffix=". " style:num-format="1" text:display-levels="5">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="nothing" fo:text-indent="-1.778cm" fo:margin-left="1.778cm"/>
+    </style:list-level-properties>
+   </text:outline-level-style>
+   <text:outline-level-style text:level="6" style:num-suffix=". " style:num-format="1" text:display-levels="6">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="nothing" fo:text-indent="-2.032cm" fo:margin-left="2.032cm"/>
+    </style:list-level-properties>
+   </text:outline-level-style>
+   <text:outline-level-style text:level="7" style:num-suffix=". " style:num-format="1" text:display-levels="7">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="nothing" fo:text-indent="-2.286cm" fo:margin-left="2.286cm"/>
+    </style:list-level-properties>
+   </text:outline-level-style>
+   <text:outline-level-style text:level="8" style:num-suffix=". " style:num-format="1" text:display-levels="8">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="nothing" fo:text-indent="-2.54cm" fo:margin-left="2.54cm"/>
+    </style:list-level-properties>
+   </text:outline-level-style>
+   <text:outline-level-style text:level="9" style:num-suffix=". " style:num-format="1" text:display-levels="9">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="nothing" fo:text-indent="-2.794cm" fo:margin-left="2.794cm"/>
+    </style:list-level-properties>
+   </text:outline-level-style>
+   <text:outline-level-style text:level="10" style:num-suffix=". " style:num-format="1" text:display-levels="10">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="nothing" fo:text-indent="-3.048cm" fo:margin-left="3.048cm"/>
+    </style:list-level-properties>
+   </text:outline-level-style>
+  </text:outline-style>
+
+  <style:style style:name="Standard" style:family="paragraph" style:class="text"/>
+  <style:style style:name="Heading" style:family="paragraph" style:parent-style-name="Standard" style:next-style-name="Text_20_body" style:class="text">
+   <style:paragraph-properties fo:margin-top="0.423cm" fo:margin-bottom="0.212cm" fo:keep-with-next="always"/>
+   <style:text-properties style:font-name="Arial" fo:font-size="14pt" style:font-name-asian="SimSun" style:font-size-asian="14pt" style:font-name-complex="Tahoma" style:font-size-complex="14pt"/>
+  </style:style>
+  <style:style style:name="Text_20_body" style:display-name="Text body" style:family="paragraph" style:parent-style-name="Standard" style:class="text">
+   <style:paragraph-properties fo:margin-top="0cm" fo:margin-bottom="0.212cm"/>
+  </style:style>
+  <style:style style:name="List" style:family="paragraph" style:parent-style-name="Text_20_body" style:class="list">
+   <style:text-properties style:font-name-complex="Tahoma1"/>
+  </style:style>
+  <style:style style:name="Caption" style:family="paragraph" style:parent-style-name="Standard" style:class="extra">
+   <style:paragraph-properties fo:margin-top="0.212cm" fo:margin-bottom="0.212cm" text:number-lines="false" text:line-number="0"/>
+   <style:text-properties fo:font-size="12pt" fo:font-style="italic" style:font-size-asian="12pt" style:font-style-asian="italic" style:font-name-complex="Tahoma1" style:font-size-complex="12pt" style:font-style-complex="italic"/>
+  </style:style>
+  <style:style style:name="Index" style:family="paragraph" style:parent-style-name="Standard" style:class="index">
+   <style:paragraph-properties text:number-lines="false" text:line-number="0"/>
+   <style:text-properties style:font-name-complex="Tahoma1"/>
+  </style:style>
+  <style:style style:name="Heading_20_1" style:display-name="Heading 1" style:family="paragraph" style:parent-style-name="Heading" style:next-style-name="Text_20_body" style:default-outline-level="1" style:class="text">
+   <style:text-properties fo:font-size="115%" fo:font-weight="bold" style:font-size-asian="115%" style:font-weight-asian="bold" style:font-size-complex="115%" style:font-weight-complex="bold"/>
+  </style:style>
+  <style:style style:name="Heading_20_2" style:display-name="Heading 2" style:family="paragraph" style:parent-style-name="Heading" style:next-style-name="Text_20_body" style:default-outline-level="2" style:class="text">
+   <style:text-properties fo:font-size="14pt" fo:font-style="italic" fo:font-weight="bold" style:font-size-asian="14pt" style:font-style-asian="italic" style:font-weight-asian="bold" style:font-size-complex="14pt" style:font-style-complex="italic" style:font-weight-complex="bold"/>
+  </style:style>
+  <style:style style:name="Heading_20_3" style:display-name="Heading 3" style:family="paragraph" style:parent-style-name="Heading" style:next-style-name="Text_20_body" style:default-outline-level="3" style:class="text">
+   <style:text-properties fo:font-size="14pt" fo:font-weight="bold" style:font-size-asian="14pt" style:font-weight-asian="bold" style:font-size-complex="14pt" style:font-weight-complex="bold"/>
+  </style:style>
+  <style:style style:name="Heading_20_4" style:display-name="Heading 4" style:family="paragraph" style:parent-style-name="Heading" style:next-style-name="Text_20_body" style:default-outline-level="4" style:class="text">
+   <style:text-properties fo:font-size="85%" fo:font-style="italic" fo:font-weight="bold" style:font-size-asian="85%" style:font-style-asian="italic" style:font-weight-asian="bold" style:font-size-complex="85%" style:font-style-complex="italic" style:font-weight-complex="bold"/>
+  </style:style>
+  <style:style style:name="Heading_20_5" style:display-name="Heading 5" style:family="paragraph" style:parent-style-name="Heading" style:next-style-name="Text_20_body" style:default-outline-level="5" style:class="text">
+   <style:text-properties fo:font-size="85%" fo:font-weight="bold" style:font-size-asian="85%" style:font-weight-asian="bold" style:font-size-complex="85%" style:font-weight-complex="bold"/>
+  </style:style>
+  <style:style style:name="Heading_20_6" style:display-name="Heading 6" style:family="paragraph" style:parent-style-name="Heading" style:next-style-name="Text_20_body" style:default-outline-level="6" style:class="text">
+   <style:text-properties fo:font-size="75%" fo:font-weight="bold" style:font-size-asian="75%" style:font-weight-asian="bold" style:font-size-complex="75%" style:font-weight-complex="bold"/>
+  </style:style>
+  <style:style style:name="Heading_20_7" style:display-name="Heading 7" style:family="paragraph" style:parent-style-name="Heading" style:next-style-name="Text_20_body" style:default-outline-level="7" style:class="text">
+   <style:text-properties fo:font-size="75%" fo:font-weight="bold" style:font-size-asian="75%" style:font-weight-asian="bold" style:font-size-complex="75%" style:font-weight-complex="bold"/>
+  </style:style>
+  <style:style style:name="Heading_20_8" style:display-name="Heading 8" style:family="paragraph" style:parent-style-name="Heading" style:next-style-name="Text_20_body" style:default-outline-level="8" style:class="text">
+   <style:text-properties fo:font-size="75%" fo:font-weight="bold" style:font-size-asian="75%" style:font-weight-asian="bold" style:font-size-complex="75%" style:font-weight-complex="bold"/>
+  </style:style>
+  <style:style style:name="Heading_20_9" style:display-name="Heading 9" style:family="paragraph" style:parent-style-name="Heading" style:next-style-name="Text_20_body" style:default-outline-level="9" style:class="text">
+   <style:text-properties fo:font-size="75%" fo:font-weight="bold" style:font-size-asian="75%" style:font-weight-asian="bold" style:font-size-complex="75%" style:font-weight-complex="bold"/>
+  </style:style>
+  <style:style style:name="Heading_20_10" style:display-name="Heading 10" style:family="paragraph" style:parent-style-name="Heading" style:next-style-name="Text_20_body" style:default-outline-level="10" style:class="text">
+   <style:text-properties fo:font-size="75%" fo:font-weight="bold" style:font-size-asian="75%" style:font-weight-asian="bold" style:font-size-complex="75%" style:font-weight-complex="bold"/>
+  </style:style>
+  <style:style style:name="Heading_20_1.title" style:display-name="Heading 1.title" style:family="paragraph" style:parent-style-name="Heading_20_1">
+   <style:paragraph-properties fo:text-align="center" style:justify-single-word="false"/>
+  </style:style>
+  <style:style style:name="Text_20_body_20_indent" style:display-name="Text body indent" style:family="paragraph" style:parent-style-name="Text_20_body" style:class="text">
+   <style:paragraph-properties fo:margin-left="0.499cm" fo:margin-right="0cm" fo:text-indent="0cm" style:auto-text-indent="false"/>
+  </style:style>
+  <style:style style:name="List_20_Indent" style:display-name="List Indent" style:family="paragraph" style:parent-style-name="Text_20_body" style:class="text">
+   <style:paragraph-properties fo:margin-left="5.001cm" fo:margin-right="0cm" fo:text-indent="-4.5cm" style:auto-text-indent="false">
+    <style:tab-stops>
+     <style:tab-stop style:position="0cm"/>
+    </style:tab-stops>
+   </style:paragraph-properties>
+  </style:style>
+  <style:style style:name="First_20_line_20_indent" style:display-name="First line indent" style:family="paragraph" style:parent-style-name="Text_20_body" style:class="text">
+   <style:paragraph-properties fo:margin-left="0cm" fo:margin-right="0cm" fo:text-indent="0.499cm" style:auto-text-indent="false"/>
+  </style:style>
+  <style:style style:name="Hanging_20_indent" style:display-name="Hanging indent" style:family="paragraph" style:parent-style-name="Text_20_body" style:class="text">
+   <style:paragraph-properties fo:margin-left="1cm" fo:margin-right="0cm" fo:text-indent="-0.499cm" style:auto-text-indent="false">
+    <style:tab-stops>
+     <style:tab-stop style:position="0cm"/>
+    </style:tab-stops>
+   </style:paragraph-properties>
+  </style:style>
+  <style:style style:name="Salutation" style:family="paragraph" style:parent-style-name="Standard" style:class="text">
+   <style:paragraph-properties text:number-lines="false" text:line-number="0"/>
+  </style:style>
+  <style:style style:name="Contents_20_Heading" style:display-name="Contents Heading" style:family="paragraph" style:parent-style-name="Heading" style:class="index">
+   <style:paragraph-properties fo:margin-left="0cm" fo:margin-right="0cm" fo:text-indent="0cm" style:auto-text-indent="false" text:number-lines="false" text:line-number="0"/>
+   <style:text-properties fo:font-size="16pt" fo:font-weight="bold" style:font-size-asian="16pt" style:font-weight-asian="bold" style:font-size-complex="16pt" style:font-weight-complex="bold"/>
+  </style:style>
+  <style:style style:name="Contents_20_1" style:display-name="Contents 1" style:family="paragraph" style:parent-style-name="Index" style:class="index">
+   <style:paragraph-properties fo:margin-left="0cm" fo:margin-right="0cm" fo:text-indent="0cm" style:auto-text-indent="false">
+    <style:tab-stops>
+     <style:tab-stop style:position="17cm" style:type="right" style:leader-style="dotted" style:leader-text="."/>
+    </style:tab-stops>
+   </style:paragraph-properties>
+  </style:style>
+  <style:style style:name="Contents_20_2" style:display-name="Contents 2" style:family="paragraph" style:parent-style-name="Index" style:class="index">
+   <style:paragraph-properties fo:margin-left="0.499cm" fo:margin-right="0cm" fo:text-indent="0cm" style:auto-text-indent="false">
+    <style:tab-stops>
+     <style:tab-stop style:position="16.501cm" style:type="right" style:leader-style="dotted" style:leader-text="."/>
+    </style:tab-stops>
+   </style:paragraph-properties>
+  </style:style>
+  <style:style style:name="Contents_20_3" style:display-name="Contents 3" style:family="paragraph" style:parent-style-name="Index" style:class="index">
+   <style:paragraph-properties fo:margin-left="0.998cm" fo:margin-right="0cm" fo:text-indent="0cm" style:auto-text-indent="false">
+    <style:tab-stops>
+     <style:tab-stop style:position="16.002cm" style:type="right" style:leader-style="dotted" style:leader-text="."/>
+    </style:tab-stops>
+   </style:paragraph-properties>
+  </style:style>
+  <style:style style:name="Contents_20_4" style:display-name="Contents 4" style:family="paragraph" style:parent-style-name="Index" style:class="index">
+   <style:paragraph-properties fo:margin-left="1.498cm" fo:margin-right="0cm" fo:text-indent="0cm" style:auto-text-indent="false">
+    <style:tab-stops>
+     <style:tab-stop style:position="15.503cm" style:type="right" style:leader-style="dotted" style:leader-text="."/>
+    </style:tab-stops>
+   </style:paragraph-properties>
+  </style:style>
+  <style:style style:name="Contents_20_5" style:display-name="Contents 5" style:family="paragraph" style:parent-style-name="Index" style:class="index">
+   <style:paragraph-properties fo:margin-left="1.997cm" fo:margin-right="0cm" fo:text-indent="0cm" style:auto-text-indent="false">
+    <style:tab-stops>
+     <style:tab-stop style:position="15.004cm" style:type="right" style:leader-style="dotted" style:leader-text="."/>
+    </style:tab-stops>
+   </style:paragraph-properties>
+  </style:style>
+  <style:style style:name="Contents_20_6" style:display-name="Contents 6" style:family="paragraph" style:parent-style-name="Index" style:class="index">
+   <style:paragraph-properties fo:margin-left="2.496cm" fo:margin-right="0cm" fo:text-indent="0cm" style:auto-text-indent="false">
+    <style:tab-stops>
+     <style:tab-stop style:position="14.504cm" style:type="right" style:leader-style="dotted" style:leader-text="."/>
+    </style:tab-stops>
+   </style:paragraph-properties>
+  </style:style>
+  <style:style style:name="Contents_20_7" style:display-name="Contents 7" style:family="paragraph" style:parent-style-name="Index" style:class="index">
+   <style:paragraph-properties fo:margin-left="2.995cm" fo:margin-right="0cm" fo:text-indent="0cm" style:auto-text-indent="false">
+    <style:tab-stops>
+     <style:tab-stop style:position="14.005cm" style:type="right" style:leader-style="dotted" style:leader-text="."/>
+    </style:tab-stops>
+   </style:paragraph-properties>
+  </style:style>
+  <style:style style:name="Contents_20_8" style:display-name="Contents 8" style:family="paragraph" style:parent-style-name="Index" style:class="index">
+   <style:paragraph-properties fo:margin-left="3.494cm" fo:margin-right="0cm" fo:text-indent="0cm" style:auto-text-indent="false">
+    <style:tab-stops>
+     <style:tab-stop style:position="13.506cm" style:type="right" style:leader-style="dotted" style:leader-text="."/>
+    </style:tab-stops>
+   </style:paragraph-properties>
+  </style:style>
+  <style:style style:name="Contents_20_9" style:display-name="Contents 9" style:family="paragraph" style:parent-style-name="Index" style:class="index">
+   <style:paragraph-properties fo:margin-left="3.993cm" fo:margin-right="0cm" fo:text-indent="0cm" style:auto-text-indent="false">
+    <style:tab-stops>
+     <style:tab-stop style:position="13.007cm" style:type="right" style:leader-style="dotted" style:leader-text="."/>
+    </style:tab-stops>
+   </style:paragraph-properties>
+  </style:style>
+  <style:style style:name="Contents_20_10" style:display-name="Contents 10" style:family="paragraph" style:parent-style-name="Index" style:class="index">
+   <style:paragraph-properties fo:margin-left="4.493cm" fo:margin-right="0cm" fo:text-indent="0cm" style:auto-text-indent="false">
+    <style:tab-stops>
+     <style:tab-stop style:position="12.508cm" style:type="right" style:leader-style="dotted" style:leader-text="."/>
+    </style:tab-stops>
+   </style:paragraph-properties>
+  </style:style>
+  <style:style style:name="Quotations" style:family="paragraph" style:parent-style-name="Standard" style:class="html">
+   <style:paragraph-properties fo:margin-left="1cm" fo:margin-right="1cm" fo:margin-top="0cm" fo:margin-bottom="0.499cm" fo:text-indent="0cm" style:auto-text-indent="false"/>
+  </style:style>
+  <style:style style:name="Preformatted_20_Text" style:display-name="Preformatted Text" style:family="paragraph" style:parent-style-name="Standard" style:class="html">
+   <style:paragraph-properties fo:margin-top="0cm" fo:margin-bottom="0cm"/>
+   <style:text-properties style:font-name="Courier New" fo:font-size="10pt" style:font-name-asian="NSimSun" style:font-size-asian="10pt" style:font-name-complex="Courier New" style:font-size-complex="10pt"/>
+  </style:style>
+  <style:style style:name="OrgVerse" style:family="paragraph" style:parent-style-name="Preformatted_20_Text">
+   <style:paragraph-properties fo:background-color="#c0c0c0" fo:padding="0.049cm" fo:border="0.018cm solid #000000" style:shadow="none">
+    <style:background-image/>
+   </style:paragraph-properties>
+  </style:style>
+  <style:style style:name="OrgSourceBlock" style:family="paragraph" style:parent-style-name="Preformatted_20_Text">
+   <style:paragraph-properties fo:background-color="#c0c0c0" fo:padding="0.049cm" fo:border="0.018cm solid #000000" style:shadow="none">
+    <style:background-image/>
+   </style:paragraph-properties>
+  </style:style>
+  <style:style style:name="OrgCenter" style:family="paragraph" style:parent-style-name="Text_20_body">
+   <style:paragraph-properties fo:text-align="center" style:justify-single-word="false"/>
+  </style:style>
+  <style:style style:name="OrgTableContents" style:family="paragraph" style:parent-style-name="Text_20_body"/>
+  <style:style style:name="OrgTableHeading" style:family="paragraph" style:parent-style-name="OrgTableContents" style:class="extra">
+    <style:paragraph-properties fo:text-align="center" style:justify-single-word="false" text:number-lines="false" text:line-number="0"/>
+    <style:text-properties fo:font-weight="bold" style:font-weight-asian="bold" style:font-weight-complex="bold"/>
+  </style:style>
+
+  <style:style style:name="OrgTableHeadingLeft" style:family="paragraph" style:parent-style-name="OrgTableHeading">
+    <style:paragraph-properties fo:text-align="left" style:justify-single-word="false"/>
+  </style:style>
+  <style:style style:name="OrgTableHeadingRight" style:family="paragraph" style:parent-style-name="OrgTableHeading">
+    <style:paragraph-properties fo:text-align="right" style:justify-single-word="false"/>
+  </style:style>
+  <style:style style:name="OrgTableHeadingCenter" style:family="paragraph" style:parent-style-name="OrgTableHeading">
+    <style:paragraph-properties fo:text-align="center" style:justify-single-word="false"/>
+  </style:style>
+  
+  <style:style style:name="OrgTableContentsLeft" style:family="paragraph" style:parent-style-name="OrgTableContents">
+    <style:paragraph-properties fo:text-align="left" style:justify-single-word="false"/>
+  </style:style>
+  <style:style style:name="OrgTableContentsRight" style:family="paragraph" style:parent-style-name="OrgTableContents">
+    <style:paragraph-properties fo:text-align="right" style:justify-single-word="false"/>
+  </style:style>
+  <style:style style:name="OrgTableContentsCenter" style:family="paragraph" style:parent-style-name="OrgTableContents">
+    <style:paragraph-properties fo:text-align="center" style:justify-single-word="false"/>
+  </style:style>
+  <style:style style:name="Text_20_body_20_bold" style:display-name="Text body bold" style:family="paragraph" style:parent-style-name="Text_20_body" style:next-style-name="Text_20_body">
+   <style:text-properties fo:font-weight="bold"/>
+  </style:style>
+  <style:style style:name="Footnote" style:family="paragraph" style:parent-style-name="Standard" style:class="extra">
+   <style:paragraph-properties fo:margin-left="0.499cm" fo:margin-right="0cm" fo:text-indent="-0.499cm" style:auto-text-indent="false" text:number-lines="false" text:line-number="0"/>
+   <style:text-properties fo:font-size="10pt" style:font-size-asian="10pt" style:font-size-complex="10pt"/>
+  </style:style>
+  <style:style style:name="Figure" style:family="paragraph" style:parent-style-name="Caption"/>
+  <style:style style:name="Illustration_20_Index_20_Heading" style:display-name="Illustration Index Heading" style:family="paragraph" style:parent-style-name="Heading" style:class="index">
+   <style:paragraph-properties fo:margin-left="0cm" fo:margin-right="0cm" fo:text-indent="0cm" style:auto-text-indent="false" text:number-lines="false" text:line-number="0"/>
+   <style:text-properties fo:font-size="16pt" fo:font-weight="bold" style:font-size-asian="16pt" style:font-weight-asian="bold" style:font-size-complex="16pt" style:font-weight-complex="bold"/>
+  </style:style>
+  <style:style style:name="Table" style:family="paragraph" style:parent-style-name="Caption" style:class="extra">
+   <style:paragraph-properties fo:text-align="center" style:justify-single-word="false"/>
+  </style:style>
+  <style:style style:name="Horizontal_20_Line" style:display-name="Horizontal Line" style:family="paragraph" style:parent-style-name="Standard" style:next-style-name="Text_20_body" style:class="html">
+   <style:paragraph-properties fo:margin-top="0cm" fo:margin-bottom="0.499cm" style:border-line-width-bottom="0.002cm 0.035cm 0.002cm" fo:padding="0cm" fo:border-left="none" fo:border-right="none" fo:border-top="none" fo:border-bottom="0.039cm double #808080" text:number-lines="false" text:line-number="0" style:join-border="false"/>
+   <style:text-properties fo:font-size="6pt" style:font-size-asian="6pt" style:font-size-complex="6pt"/>
+  </style:style>
+  <style:style style:name="Emphasis" style:family="text">
+   <style:text-properties fo:font-style="italic" style:font-style-asian="italic" style:font-style-complex="italic"/>
+  </style:style>
+  <style:style style:name="Underline" style:family="text">
+   <style:text-properties style:text-underline-style="solid" style:text-underline-width="auto" style:text-underline-color="font-color" fo:background-color="transparent"/>
+  </style:style>
+  <style:style style:name="Strikethrough" style:family="text">
+   <style:text-properties style:text-line-through-style="solid"/>
+  </style:style>
+  <style:style style:name="Source_20_Text" style:display-name="Source Text" style:family="text">
+   <style:text-properties style:font-name="Courier New" fo:background-color="transparent" style:font-name-asian="NSimSun" style:font-name-complex="Courier New"/>
+  </style:style>
+  <style:style style:name="Citation" style:family="text">
+   <style:text-properties fo:font-style="italic" style:font-style-asian="italic" style:font-style-complex="italic"/>
+  </style:style>
+  <style:style style:name="Example" style:family="text">
+   <style:text-properties style:font-name="Courier New" fo:background-color="transparent" style:font-name-asian="NSimSun" style:font-name-complex="Courier New"/>
+  </style:style>
+  <style:style style:name="OrgCode" style:family="text" style:parent-style-name="Source_20_Text"/>
+
+  <!-- BEGIN: Org Agenda Styles -->
+  <style:style style:name="OrgTodo" style:family="text">
+   <style:text-properties fo:color="#ff0000"/>
+  </style:style>
+  <style:style style:name="OrgDone" style:family="text">
+   <style:text-properties fo:color="#008000"/>
+  </style:style>
+  <style:style style:name="OrgTag" style:family="text">
+   <style:text-properties fo:background-color="#add8e6"/>
+  </style:style>
+  <style:style style:name="OrgTimestamp" style:family="text">
+   <style:text-properties fo:color="#bebebe"/>
+  </style:style>
+  <style:style style:name="OrgTimestampKeyword" style:family="text">
+   <style:text-properties fo:color="#5f9ea0"/>
+  </style:style>
+  <style:style style:name="OrgTimestampWrapper" style:family="text"/>
+  <style:style style:name="OrgTarget" style:family="text"/>
+  <!-- END: Org Agenda Styles -->
+
+  <style:style style:name="Bold" style:family="text">
+   <style:text-properties fo:font-weight="bold"/>
+  </style:style>
+  <style:style style:name="Numbering_20_Symbols" style:display-name="Numbering Symbols" style:family="text"/>
+  <style:style style:name="Footnote_20_Symbol" style:display-name="Footnote Symbol" style:family="text"/>
+  <style:style style:name="Footnote_20_anchor" style:display-name="Footnote anchor" style:family="text">
+   <style:text-properties style:text-position="super 58%"/>
+  </style:style>
+  <style:style style:name="OrgSuperscript" style:family="text">
+   <style:text-properties style:text-position="super 58%"/>
+  </style:style>
+  <style:style style:name="OrgSubscript" style:family="text">
+   <style:text-properties style:text-position="sub 58%"/>
+  </style:style>
+  <style:style style:name="Internet_20_link" style:display-name="Internet link" style:family="text">
+   <style:text-properties fo:color="#000080" fo:language="zxx" fo:country="none" style:text-underline-style="solid" style:text-underline-width="auto" style:text-underline-color="font-color" style:language-asian="zxx" style:country-asian="none" style:language-complex="zxx" style:country-complex="none"/>
+  </style:style>
+  <style:style style:name="Graphics" style:family="graphic">
+   <style:graphic-properties text:anchor-type="paragraph" svg:x="0cm" svg:y="0cm" style:wrap="none" style:vertical-pos="top" style:vertical-rel="paragraph" style:horizontal-pos="center" style:horizontal-rel="paragraph"/>
+  </style:style>
+  <style:style style:name="Frame" style:family="graphic">
+   <style:graphic-properties text:anchor-type="paragraph" svg:x="0cm" svg:y="0cm" fo:margin-left="0.201cm" fo:margin-right="0.201cm" fo:margin-top="0.201cm" fo:margin-bottom="0.201cm" style:wrap="parallel" style:number-wrapped-paragraphs="no-limit" style:wrap-contour="false" style:vertical-pos="top" style:vertical-rel="paragraph-content" style:horizontal-pos="center" style:horizontal-rel="paragraph-content" fo:padding="0.15cm" fo:border="0.002cm solid #000000"/>
+  </style:style>
+  <text:list-style style:name="Numbering_20_1" style:display-name="Numbering 1">
+   <text:list-level-style-number text:level="1" text:style-name="Numbering_20_Symbols" style:num-suffix="." style:num-format="1">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="0.499cm" fo:text-indent="-0.499cm" fo:margin-left="0.499cm"/>
+    </style:list-level-properties>
+   </text:list-level-style-number>
+   <text:list-level-style-number text:level="2" text:style-name="Numbering_20_Symbols" style:num-suffix="." style:num-format="1">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="1cm" fo:text-indent="-0.499cm" fo:margin-left="1cm"/>
+    </style:list-level-properties>
+   </text:list-level-style-number>
+   <text:list-level-style-number text:level="3" text:style-name="Numbering_20_Symbols" style:num-suffix="." style:num-format="1">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="1.499cm" fo:text-indent="-0.499cm" fo:margin-left="1.499cm"/>
+    </style:list-level-properties>
+   </text:list-level-style-number>
+   <text:list-level-style-number text:level="4" text:style-name="Numbering_20_Symbols" style:num-suffix="." style:num-format="1">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="2cm" fo:text-indent="-0.499cm" fo:margin-left="2cm"/>
+    </style:list-level-properties>
+   </text:list-level-style-number>
+   <text:list-level-style-number text:level="5" text:style-name="Numbering_20_Symbols" style:num-suffix="." style:num-format="1">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="2.499cm" fo:text-indent="-0.499cm" fo:margin-left="2.499cm"/>
+    </style:list-level-properties>
+   </text:list-level-style-number>
+   <text:list-level-style-number text:level="6" text:style-name="Numbering_20_Symbols" style:num-suffix="." style:num-format="1">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="3cm" fo:text-indent="-0.499cm" fo:margin-left="3cm"/>
+    </style:list-level-properties>
+   </text:list-level-style-number>
+   <text:list-level-style-number text:level="7" text:style-name="Numbering_20_Symbols" style:num-suffix="." style:num-format="1">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="3.5cm" fo:text-indent="-0.499cm" fo:margin-left="3.5cm"/>
+    </style:list-level-properties>
+   </text:list-level-style-number>
+   <text:list-level-style-number text:level="8" text:style-name="Numbering_20_Symbols" style:num-suffix="." style:num-format="1">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="4.001cm" fo:text-indent="-0.499cm" fo:margin-left="4.001cm"/>
+    </style:list-level-properties>
+   </text:list-level-style-number>
+   <text:list-level-style-number text:level="9" text:style-name="Numbering_20_Symbols" style:num-suffix="." style:num-format="1">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="4.5cm" fo:text-indent="-0.499cm" fo:margin-left="4.5cm"/>
+    </style:list-level-properties>
+   </text:list-level-style-number>
+   <text:list-level-style-number text:level="10" text:style-name="Numbering_20_Symbols" style:num-suffix="." style:num-format="1">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="5.001cm" fo:text-indent="-0.499cm" fo:margin-left="5.001cm"/>
+    </style:list-level-properties>
+   </text:list-level-style-number>
+  </text:list-style>
+  <text:list-style style:name="List_20_1" style:display-name="List 1">
+   <text:list-level-style-bullet text:level="1" text:style-name="Numbering_20_Symbols" text:bullet-char="•">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="0.4cm" fo:text-indent="-0.4cm" fo:margin-left="0.4cm"/>
+    </style:list-level-properties>
+    <style:text-properties style:font-name="OpenSymbol"/>
+   </text:list-level-style-bullet>
+   <text:list-level-style-bullet text:level="2" text:style-name="Numbering_20_Symbols" text:bullet-char="•">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="0.801cm" fo:text-indent="-0.4cm" fo:margin-left="0.801cm"/>
+    </style:list-level-properties>
+    <style:text-properties style:font-name="OpenSymbol"/>
+   </text:list-level-style-bullet>
+   <text:list-level-style-bullet text:level="3" text:style-name="Numbering_20_Symbols" text:bullet-char="•">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="1.199cm" fo:text-indent="-0.4cm" fo:margin-left="1.199cm"/>
+    </style:list-level-properties>
+    <style:text-properties style:font-name="OpenSymbol"/>
+   </text:list-level-style-bullet>
+   <text:list-level-style-bullet text:level="4" text:style-name="Numbering_20_Symbols" text:bullet-char="•">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="1.6cm" fo:text-indent="-0.4cm" fo:margin-left="1.6cm"/>
+    </style:list-level-properties>
+    <style:text-properties style:font-name="OpenSymbol"/>
+   </text:list-level-style-bullet>
+   <text:list-level-style-bullet text:level="5" text:style-name="Numbering_20_Symbols" text:bullet-char="•">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="2cm" fo:text-indent="-0.4cm" fo:margin-left="2cm"/>
+    </style:list-level-properties>
+    <style:text-properties style:font-name="OpenSymbol"/>
+   </text:list-level-style-bullet>
+   <text:list-level-style-bullet text:level="6" text:style-name="Numbering_20_Symbols" text:bullet-char="•">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="2.401cm" fo:text-indent="-0.4cm" fo:margin-left="2.401cm"/>
+    </style:list-level-properties>
+    <style:text-properties style:font-name="OpenSymbol"/>
+   </text:list-level-style-bullet>
+   <text:list-level-style-bullet text:level="7" text:style-name="Numbering_20_Symbols" text:bullet-char="•">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="2.799cm" fo:text-indent="-0.4cm" fo:margin-left="2.799cm"/>
+    </style:list-level-properties>
+    <style:text-properties style:font-name="OpenSymbol"/>
+   </text:list-level-style-bullet>
+   <text:list-level-style-bullet text:level="8" text:style-name="Numbering_20_Symbols" text:bullet-char="•">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="3.2cm" fo:text-indent="-0.4cm" fo:margin-left="3.2cm"/>
+    </style:list-level-properties>
+    <style:text-properties style:font-name="OpenSymbol"/>
+   </text:list-level-style-bullet>
+   <text:list-level-style-bullet text:level="9" text:style-name="Numbering_20_Symbols" text:bullet-char="•">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="3.6cm" fo:text-indent="-0.4cm" fo:margin-left="3.6cm"/>
+    </style:list-level-properties>
+    <style:text-properties style:font-name="OpenSymbol"/>
+   </text:list-level-style-bullet>
+   <text:list-level-style-bullet text:level="10" text:style-name="Numbering_20_Symbols" text:bullet-char="•">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="4.001cm" fo:text-indent="-0.4cm" fo:margin-left="4.001cm"/>
+    </style:list-level-properties>
+    <style:text-properties style:font-name="OpenSymbol"/>
+   </text:list-level-style-bullet>
+  </text:list-style>
+  <text:list-style style:name="OrgBulletedList">
+   <text:list-level-style-bullet text:level="1" text:style-name="Bullet_20_Symbols" style:num-suffix="." text:bullet-char="•">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="1.27cm" fo:text-indent="-0.635cm" fo:margin-left="1.27cm"/>
+    </style:list-level-properties>
+    <style:text-properties style:font-name="StarSymbol"/>
+   </text:list-level-style-bullet>
+   <text:list-level-style-bullet text:level="2" text:style-name="Bullet_20_Symbols" style:num-suffix="." text:bullet-char="•">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="1.905cm" fo:text-indent="-0.635cm" fo:margin-left="1.905cm"/>
+    </style:list-level-properties>
+    <style:text-properties style:font-name="StarSymbol"/>
+   </text:list-level-style-bullet>
+   <text:list-level-style-bullet text:level="3" text:style-name="Bullet_20_Symbols" style:num-suffix="." text:bullet-char="•">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="2.54cm" fo:text-indent="-0.635cm" fo:margin-left="2.54cm"/>
+    </style:list-level-properties>
+    <style:text-properties style:font-name="StarSymbol"/>
+   </text:list-level-style-bullet>
+   <text:list-level-style-bullet text:level="4" text:style-name="Bullet_20_Symbols" style:num-suffix="." text:bullet-char="•">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="3.175cm" fo:text-indent="-0.635cm" fo:margin-left="3.175cm"/>
+    </style:list-level-properties>
+    <style:text-properties style:font-name="StarSymbol"/>
+   </text:list-level-style-bullet>
+   <text:list-level-style-bullet text:level="5" text:style-name="Bullet_20_Symbols" style:num-suffix="." text:bullet-char="•">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="3.81cm" fo:text-indent="-0.635cm" fo:margin-left="3.81cm"/>
+    </style:list-level-properties>
+    <style:text-properties style:font-name="StarSymbol"/>
+   </text:list-level-style-bullet>
+   <text:list-level-style-bullet text:level="6" text:style-name="Bullet_20_Symbols" style:num-suffix="." text:bullet-char="•">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="4.445cm" fo:text-indent="-0.635cm" fo:margin-left="4.445cm"/>
+    </style:list-level-properties>
+    <style:text-properties style:font-name="StarSymbol"/>
+   </text:list-level-style-bullet>
+   <text:list-level-style-bullet text:level="7" text:style-name="Bullet_20_Symbols" style:num-suffix="." text:bullet-char="•">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="5.08cm" fo:text-indent="-0.635cm" fo:margin-left="5.08cm"/>
+    </style:list-level-properties>
+    <style:text-properties style:font-name="StarSymbol"/>
+   </text:list-level-style-bullet>
+   <text:list-level-style-bullet text:level="8" text:style-name="Bullet_20_Symbols" style:num-suffix="." text:bullet-char="•">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="5.715cm" fo:text-indent="-0.635cm" fo:margin-left="5.715cm"/>
+    </style:list-level-properties>
+    <style:text-properties style:font-name="StarSymbol"/>
+   </text:list-level-style-bullet>
+   <text:list-level-style-bullet text:level="9" text:style-name="Bullet_20_Symbols" style:num-suffix="." text:bullet-char="•">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="6.35cm" fo:text-indent="-0.635cm" fo:margin-left="6.35cm"/>
+    </style:list-level-properties>
+    <style:text-properties style:font-name="StarSymbol"/>
+   </text:list-level-style-bullet>
+   <text:list-level-style-bullet text:level="10" text:style-name="Bullet_20_Symbols" style:num-suffix="." text:bullet-char="•">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="6.985cm" fo:text-indent="-0.635cm" fo:margin-left="6.985cm"/>
+    </style:list-level-properties>
+    <style:text-properties style:font-name="StarSymbol"/>
+   </text:list-level-style-bullet>
+  </text:list-style>
+  <text:list-style style:name="OrgNumberedList">
+   <text:list-level-style-number text:level="1" style:num-suffix="." style:num-format="1">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="1.27cm" fo:text-indent="-0.635cm" fo:margin-left="1.27cm"/>
+    </style:list-level-properties>
+   </text:list-level-style-number>
+   <text:list-level-style-number text:level="2" style:num-suffix="." style:num-format="1">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="1.905cm" fo:text-indent="-0.635cm" fo:margin-left="1.905cm"/>
+    </style:list-level-properties>
+   </text:list-level-style-number>
+   <text:list-level-style-number text:level="3" style:num-suffix="." style:num-format="1">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="2.54cm" fo:text-indent="-0.635cm" fo:margin-left="2.54cm"/>
+    </style:list-level-properties>
+   </text:list-level-style-number>
+   <text:list-level-style-number text:level="4" style:num-suffix="." style:num-format="1">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="3.175cm" fo:text-indent="-0.635cm" fo:margin-left="3.175cm"/>
+    </style:list-level-properties>
+   </text:list-level-style-number>
+   <text:list-level-style-number text:level="5" style:num-suffix="." style:num-format="1">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="3.81cm" fo:text-indent="-0.635cm" fo:margin-left="3.81cm"/>
+    </style:list-level-properties>
+   </text:list-level-style-number>
+   <text:list-level-style-number text:level="6" style:num-suffix="." style:num-format="1">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="4.445cm" fo:text-indent="-0.635cm" fo:margin-left="4.445cm"/>
+    </style:list-level-properties>
+   </text:list-level-style-number>
+   <text:list-level-style-number text:level="7" style:num-suffix="." style:num-format="1">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="5.08cm" fo:text-indent="-0.635cm" fo:margin-left="5.08cm"/>
+    </style:list-level-properties>
+   </text:list-level-style-number>
+   <text:list-level-style-number text:level="8" style:num-suffix="." style:num-format="1">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="5.715cm" fo:text-indent="-0.635cm" fo:margin-left="5.715cm"/>
+    </style:list-level-properties>
+   </text:list-level-style-number>
+   <text:list-level-style-number text:level="9" style:num-suffix="." style:num-format="1">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="6.35cm" fo:text-indent="-0.635cm" fo:margin-left="6.35cm"/>
+    </style:list-level-properties>
+   </text:list-level-style-number>
+   <text:list-level-style-number text:level="10" style:num-suffix="." style:num-format="1">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="6.985cm" fo:text-indent="-0.635cm" fo:margin-left="6.985cm"/>
+    </style:list-level-properties>
+   </text:list-level-style-number>
+  </text:list-style>
+  <text:list-style style:name="OrgDescriptionList">
+   <text:list-level-style-bullet text:level="1" text:style-name="Bullet_20_Symbols" style:num-suffix="." text:bullet-char=" ">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="1.27cm" fo:text-indent="-0.635cm" fo:margin-left="1.27cm"/>
+    </style:list-level-properties>
+    <style:text-properties style:font-name="Tahoma"/>
+   </text:list-level-style-bullet>
+   <text:list-level-style-bullet text:level="2" text:style-name="Bullet_20_Symbols" style:num-suffix="." text:bullet-char=" ">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="1.905cm" fo:text-indent="-0.635cm" fo:margin-left="1.905cm"/>
+    </style:list-level-properties>
+    <style:text-properties style:font-name="Tahoma"/>
+   </text:list-level-style-bullet>
+   <text:list-level-style-bullet text:level="3" text:style-name="Bullet_20_Symbols" style:num-suffix="." text:bullet-char=" ">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="2.54cm" fo:text-indent="-0.635cm" fo:margin-left="2.54cm"/>
+    </style:list-level-properties>
+    <style:text-properties style:font-name="Tahoma"/>
+   </text:list-level-style-bullet>
+   <text:list-level-style-bullet text:level="4" text:style-name="Bullet_20_Symbols" style:num-suffix="." text:bullet-char=" ">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="3.175cm" fo:text-indent="-0.635cm" fo:margin-left="3.175cm"/>
+    </style:list-level-properties>
+    <style:text-properties style:font-name="Tahoma"/>
+   </text:list-level-style-bullet>
+   <text:list-level-style-bullet text:level="5" text:style-name="Bullet_20_Symbols" style:num-suffix="." text:bullet-char=" ">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="3.81cm" fo:text-indent="-0.635cm" fo:margin-left="3.81cm"/>
+    </style:list-level-properties>
+    <style:text-properties style:font-name="Tahoma"/>
+   </text:list-level-style-bullet>
+   <text:list-level-style-bullet text:level="6" text:style-name="Bullet_20_Symbols" style:num-suffix="." text:bullet-char=" ">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="4.445cm" fo:text-indent="-0.635cm" fo:margin-left="4.445cm"/>
+    </style:list-level-properties>
+    <style:text-properties style:font-name="Tahoma"/>
+   </text:list-level-style-bullet>
+   <text:list-level-style-bullet text:level="7" text:style-name="Bullet_20_Symbols" style:num-suffix="." text:bullet-char=" ">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="5.08cm" fo:text-indent="-0.635cm" fo:margin-left="5.08cm"/>
+    </style:list-level-properties>
+    <style:text-properties style:font-name="Tahoma"/>
+   </text:list-level-style-bullet>
+   <text:list-level-style-bullet text:level="8" text:style-name="Bullet_20_Symbols" style:num-suffix="." text:bullet-char=" ">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="5.715cm" fo:text-indent="-0.635cm" fo:margin-left="5.715cm"/>
+    </style:list-level-properties>
+    <style:text-properties style:font-name="Tahoma"/>
+   </text:list-level-style-bullet>
+   <text:list-level-style-bullet text:level="9" text:style-name="Bullet_20_Symbols" style:num-suffix="." text:bullet-char=" ">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="6.35cm" fo:text-indent="-0.635cm" fo:margin-left="6.35cm"/>
+    </style:list-level-properties>
+    <style:text-properties style:font-name="Tahoma"/>
+   </text:list-level-style-bullet>
+   <text:list-level-style-bullet text:level="10" text:style-name="Bullet_20_Symbols" style:num-suffix="." text:bullet-char=" ">
+    <style:list-level-properties text:list-level-position-and-space-mode="label-alignment">
+     <style:list-level-label-alignment text:label-followed-by="listtab" text:list-tab-stop-position="6.985cm" fo:text-indent="-0.635cm" fo:margin-left="6.985cm"/>
+    </style:list-level-properties>
+    <style:text-properties style:font-name="Tahoma"/>
+   </text:list-level-style-bullet>
+  </text:list-style>
+  <text:notes-configuration text:note-class="footnote" text:citation-style-name="Footnote_20_Symbol" text:citation-body-style-name="Footnote_20_anchor" style:num-format="1" text:start-value="0" text:footnotes-position="page" text:start-numbering-at="document"/>
+  <text:notes-configuration text:note-class="endnote" style:num-format="i" text:start-value="0"/>
+  <text:linenumbering-configuration text:number-lines="false" text:offset="0.499cm" style:num-format="1" text:number-position="left" text:increment="5"/>
+ </office:styles>
+ <office:automatic-styles>
+  <style:page-layout style:name="Mpm1">
+   <style:page-layout-properties fo:page-width="21.001cm" fo:page-height="29.7cm" style:num-format="1" style:print-orientation="portrait" fo:margin-top="2cm" fo:margin-bottom="2cm" fo:margin-left="2cm" fo:margin-right="2cm" style:writing-mode="lr-tb" style:footnote-max-height="0cm">
+    <style:footnote-sep style:width="0.018cm" style:distance-before-sep="0.101cm" style:distance-after-sep="0.101cm" style:adjustment="left" style:rel-width="25%" style:color="#000000"/>
+   </style:page-layout-properties>
+   <style:header-style/>
+   <style:footer-style/>
+  </style:page-layout>
+ </office:automatic-styles>
+ <office:master-styles>
+  <style:master-page style:name="Standard" style:page-layout-name="Mpm1"/>
+ </office:master-styles>
+</office:document-styles>