1 namespace a = "http://relaxng.org/ns/compatibility/annotations/1.0"
2 namespace rng = "http://relaxng.org/ns/structure/1.0"
4 # Emacs Muse RELAX NG Schema v. 1.2
5 # Copyright (C) 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
7 # Author: Brad Collins (brad AT chenla DOT org)
8 # Maintainer: Michael Olson <mwolson@gnu.org>
10 # This is free software; you can redistribute it and/or modify it
11 # under the terms of the GNU General Public License as published by
12 # the Free Software Foundation; either version 3 of the License, or
13 # (at your option) any later version. This material is distributed in
14 # the hope that it will be useful, but WITHOUT ANY WARRANTY; without
15 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
16 # PARTICULAR PURPOSE. See the GNU General Public License for more
17 # details.You should have received a copy of the GNU General Public
18 # License along with this file; if not, write to the Free Software
19 # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
24 # RelaxNG Compact syntax can be converted into RelaxNG XML Syntax,
25 # DTD format and XML Schema language using free tools.
27 # Emacs users are encouraged to use James Clarke's nxml-mode for
28 # editing and validating XML files. If you are in nxml-mode use the
29 # command C-c C-s C-f to point to this schema file, say yes if you
30 # are asked if you want to copy the file to your location, and then
31 # C-c C-s C-a can be used to reload the schema if you make changes
37 # - Original version by Brad Collins.
40 # - Hacked it to the point of working with Muse's QuickStart
44 # - Permit lists to be nested.
47 # - Permit paragraph-level markup, such as links, to appear in
49 # - Support multiple definitions in a definition list.
50 # - Permit a list to be nested inside of a definition.
51 # - Permit a link to be inside of a title.
52 # - Permit emphasis to be inside of other emphasis.
55 # - Add the <cite> tag.
59 # - Don't allow <cite> tags inside of format elements.
70 muse.element.pageinfo?
71 & muse.element.section*
73 & muse.element.blockquote*
78 & muse.element.example*
82 # ------------------------------------------------
84 # ------------------------------------------------
85 ## pageinfo element used for metadata
87 muse.element.pageinfo = element pageinfo {
89 & muse.element.author?
90 & muse.element.maintainer?
91 & muse.element.pubdate? }?
94 muse.element.title = element title {
98 ## page author element
99 muse.element.author = element author { text }?
101 ## page maintainer element
102 muse.element.maintainer = element maintainer { text }?
104 ## page publication date element
105 muse.element.pubdate = element pubdate { text }?
107 # ------------------------------------------------
109 # ------------------------------------------------
111 muse.element.section = element section {
113 & muse.attribute.level?
114 & muse.element.section*
115 & muse.element.title*
117 & muse.element.blockquote*
118 & muse.element.table*
121 & muse.element.image*
122 & muse.element.example*
123 & muse.element.verse*
126 ## blockquote element
127 muse.element.blockquote = element blockquote {
132 muse.element.p = element p {
136 & muse.element.format*
137 & muse.element.image*
139 & muse.element.image*
140 & muse.element.anchor*
141 & muse.element.footnote*
145 muse.element.example = element example { text }?
148 muse.element.verse = element verse {
149 muse.element.line* }?
151 ## verse line element
152 muse.element.line = element line {
156 & muse.element.format*
157 & muse.element.image*
159 & muse.element.image*
160 & muse.element.anchor*
161 & muse.element.footnote*
164 # ------------------------------------------------
165 # Unordered list elements
166 # ------------------------------------------------
168 muse.element.list = element list {
170 & muse.element.item* }?
172 muse.element.item = element item {
174 & muse.element.definition*
178 & muse.element.format*
179 & muse.element.image*
182 & muse.element.blockquote*
183 & muse.element.table*
184 & muse.element.example*
185 & muse.element.verse*
189 # ------------------------------------------------
190 # Definition list elements
191 # ------------------------------------------------
193 muse.element.term = element term {
197 & muse.element.format*
198 & muse.element.image*
200 & muse.element.image*
204 muse.element.definition = element definition {
208 & muse.element.format*
209 & muse.element.image*
211 & muse.element.image*
215 # ------------------------------------------------
217 # ------------------------------------------------
220 ## used for emphasis, underlining, and centering paragraphs
221 muse.element.format = element format {
223 & muse.attribute.level?
225 & muse.element.format*
229 ## used for citing sources
230 muse.element.cite = element cite {
235 ## used for small pieces of monospace text, like commands
236 muse.element.code = element code { text }?
238 muse.element.image = element image { muse.attribute.href? }?
240 ## horizontal rule element
241 muse.element.hr = element hr { empty }?
244 muse.element.footnote = element footnote { text }?
247 muse.element.anchor = element anchor { muse.attribute.id }?
250 muse.element.link = element link {
252 & muse.attribute.href
255 # ------------------------------------------------
257 # ------------------------------------------------
260 muse.attribute.type = attribute type { text }?
263 muse.attribute.level = attribute level { text }?
265 ## href attribute -- must have valid URI
266 muse.attribute.href = attribute href { xsd:anyURI }?
269 muse.attribute.id = attribute id { text }?
271 # ------------------------------------------------
273 # ------------------------------------------------
276 muse.element.table = element table {
278 & muse.element.thead*
279 & muse.element.tfoot* }?
281 ## table body element
282 muse.element.tbody = element tbody { muse.element.tr* }?
284 ## table header element
285 muse.element.thead = element thead { muse.element.tr* }?
287 ## table footer element
288 muse.element.tfoot = element tfoot { muse.element.tr* }?
291 muse.element.tr = element tr {
293 & muse.element.th* }?
296 muse.element.td = element td {
300 & muse.element.format*
301 & muse.element.image*
303 & muse.element.image*
304 & muse.element.anchor*
305 & muse.element.footnote*
309 muse.element.th = element th {
313 & muse.element.format*
314 & muse.element.image*
316 & muse.element.image*
317 & muse.element.anchor*
318 & muse.element.footnote*