This file is indexed.

/usr/share/mozart/doc/ozdoc/node5.html is in mozart-doc 1.4.0-8ubuntu1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

1
2
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD><TITLE>5 Description of all elements</TITLE><LINK href="ozdoc.css" rel="stylesheet" type="text/css"></HEAD><BODY><TABLE align="center" border="0" cellpadding="6" cellspacing="6" class="nav"><TR bgcolor="#DDDDDD"><TD><A href="node4.html#chapter.principles">&lt;&lt; Prev</A></TD><TD><A href="index.html">- Up -</A></TD><TD><A href="node6.html#chapter.extending">Next &gt;&gt;</A></TD></TR></TABLE><DIV id="chapter.description"><H1><A name="chapter.description">5 Description of all elements</A></H1><P>Since the content models are already provided by the BNF grammar above, they will not be repeated here.</P><P></P><DL class="tags"><DT><CODE>BOOK</CODE> </DT><DD><P></P></DD><DT><CODE>FRONT</CODE> </DT><DD><P>This is a container for descriptive information about the document. Beside title, author and abstract, you may also have <CODE>META</CODE> elements that make (property) statements about the document. </P><BLOCKQUOTE class="code"><CODE>&lt;<SPAN class="functionname">META</SPAN>&nbsp;<SPAN class="variablename">name</SPAN>=<SPAN class="string">&quot;ozversion&quot;</SPAN>&nbsp;<SPAN class="variablename">value</SPAN>=<SPAN class="string">&quot;3.0&quot;</SPAN>&gt;</CODE></BLOCKQUOTE><P> </P></DD><DT><CODE>TITLE</CODE> </DT><DD><P>This is used by <CODE>FRONT</CODE>, sectioning elements such as <CODE>CHAPTER</CODE>, <CODE>FIGURE</CODE>, <CODE>TABLE</CODE>. </P></DD><DT><CODE>AUTHOR</CODE> </DT><DT><CODE>AUTHOR.EXTERN</CODE> </DT><DD><P><CODE>AUTHOR</CODE> currently does not have internal structure. It simply contains the name of an author of the current document. It is recommended to use <CODE>AUTHOR.EXTERN</CODE> instead, which allows to refer to an entry in an external author database: </P><DL class="attribs"><DT><CODE>TO</CODE> </DT><DD><P>denotes the external author database </P></DD><DT><CODE>KEY</CODE> </DT><DD><P>denotes the entry in that database </P></DD></DL><P> </P></DD><DT><CODE>META</CODE> </DT><DD><P>Makes a (property) statement about the document. </P><BLOCKQUOTE class="code"><CODE>&lt;<SPAN class="functionname">META</SPAN>&nbsp;<SPAN class="variablename">name</SPAN>=<SPAN class="string">&quot;ozversion&quot;</SPAN>&nbsp;<SPAN class="variablename">value</SPAN>=<SPAN class="string">&quot;3.0&quot;</SPAN>&gt;</CODE></BLOCKQUOTE><P> A possible application is to state at what elements the document should be split into different HTML files. </P><BLOCKQUOTE class="code"><CODE>&lt;<SPAN class="functionname">META</SPAN>&nbsp;<SPAN class="variablename">name</SPAN>=<SPAN class="string">&quot;html.split&quot;</SPAN>&nbsp;<SPAN class="variablename">value</SPAN>=<SPAN class="string">&quot;chapter.foo&quot;</SPAN>&gt;</CODE></BLOCKQUOTE><P> where <CODE>chapter.foo</CODE> would probably be the ID of a chapter in the document. Arbitrary such statements can be made. Neither the name nor the value attribute is restricted. </P></DD><DT><CODE>ABSTRACT</CODE> </DT><DD><P></P></DD><DT><CODE>BODY</CODE> </DT><DD><P></P></DD><DT><CODE>CHAPTER</CODE> </DT><DD><P></P></DD><DT><CODE>SECTION</CODE> </DT><DD><P>can also be called <CODE>SECT1</CODE> </P></DD><DT><CODE>SUBSECTION</CODE> </DT><DD><P>can also be called <CODE>SECT2</CODE> </P></DD><DT><CODE>SUBSUBSECTION</CODE> </DT><DD><P>can also be called <CODE>SECT3</CODE> </P></DD><DT><CODE>P</CODE> </DT><DD><P>the usual container for text and phrase elements </P></DD><DT><CODE>PARA</CODE> </DT><DD><P>like <CODE>P</CODE>, but requires a <CODE>TITLE</CODE>. Thus: </P><BLOCKQUOTE class="code"><CODE>&lt;<SPAN class="functionname">PARA</SPAN>&gt;&lt;<SPAN class="functionname">TITLE</SPAN>&gt;Invoking&nbsp;the&nbsp;zapper&lt;/<SPAN class="functionname">TITLE</SPAN>&gt;...&lt;/<SPAN class="functionname">PARA</SPAN>&gt;</CODE></BLOCKQUOTE><P> might be rendered with an inline title in bold face. In the Oz documentation, there many paragraphs which are ``about'' a topic. This is typically rendered as a normal paragraph, but with the topic mentioned in the margin. Such paragraphs could be coded as follows: </P><BLOCKQUOTE class="code"><CODE>&lt;<SPAN class="functionname">PARA</SPAN>&nbsp;CLASS=APROPOS&gt;&lt;<SPAN class="functionname">TITLE</SPAN>&gt;Kinded&nbsp;variables&lt;/<SPAN class="functionname">TITLE</SPAN>&gt;...&lt;/<SPAN class="functionname">PARA</SPAN>&gt;</CODE></BLOCKQUOTE><P> Where <CODE>CLASS=APROPOS</CODE> is intended to indicate that the <CODE>TITLE</CODE> should be interpreted as the topic of the paragraph. </P></DD><DT><CODE>DIV</CODE> </DT><DD><P>its purpose is to group together paragraphs. For example: </P><BLOCKQUOTE class="code"><CODE>&lt;<SPAN class="functionname">DIV</SPAN>&nbsp;CLASS=WARNING&gt;&lt;<SPAN class="functionname">P</SPAN>&gt;...&lt;<SPAN class="functionname">P</SPAN>&gt;...&lt;<SPAN class="functionname">P</SPAN>&gt;...&lt;/<SPAN class="functionname">DIV</SPAN>&gt;</CODE></BLOCKQUOTE><P> could be used to markup an extended warning. This might be rendered with a colored background and heading saying ``Warning!''. </P></DD><DT><CODE>LIST</CODE> </DT><DD><P>flexible element for marking up lists of all kinds. A LaTeX-like <SPAN class="LATEX.ENV">itemize</SPAN> is simply: </P><BLOCKQUOTE class="code"><CODE>&lt;<SPAN class="functionname">LIST</SPAN>&gt;<BR>&nbsp;&nbsp;&lt;<SPAN class="functionname">ITEM</SPAN>&gt;...<BR>&nbsp;&nbsp;&lt;<SPAN class="functionname">ITEM</SPAN>&gt;...<BR>&lt;/<SPAN class="functionname">LIST</SPAN>&gt;</CODE></BLOCKQUOTE><P> a LaTeX-like <SPAN class="LATEX.ENV">enumerate</SPAN> is obtained through attribute <CODE>ENUM</CODE>: </P><BLOCKQUOTE class="code"><CODE>&lt;<SPAN class="functionname">LIST</SPAN>&nbsp;ENUM&gt;<BR>&nbsp;&nbsp;&lt;<SPAN class="functionname">ITEM</SPAN>&gt;...<BR>&nbsp;&nbsp;&lt;<SPAN class="functionname">ITEM</SPAN>&gt;...<BR>&lt;/<SPAN class="functionname">LIST</SPAN>&gt;</CODE></BLOCKQUOTE><P> a LaTeX-like <SPAN class="LATEX.ENV">description</SPAN> can be obtained by having one or more <CODE>ENTRY</CODE> elements before an <CODE>ITEM</CODE>: </P><BLOCKQUOTE class="code"><CODE>&lt;<SPAN class="functionname">LIST</SPAN>&gt;<BR>&nbsp;&nbsp;&lt;<SPAN class="functionname">ENTRY</SPAN>&gt;...<BR>&nbsp;&nbsp;&lt;<SPAN class="functionname">ENTRY</SPAN>&gt;...<BR>&nbsp;&nbsp;&lt;<SPAN class="functionname">ITEM</SPAN>&gt;...<BR>&nbsp;&nbsp;&lt;<SPAN class="functionname">ENTRY</SPAN>&gt;...<BR>&nbsp;&nbsp;&lt;<SPAN class="functionname">ITEM</SPAN>&gt;&lt;<SPAN class="functionname">P.SILENT</SPAN>//<BR>&lt;/<SPAN class="functionname">LIST</SPAN>&gt;</CODE></BLOCKQUOTE><P> For describing such things as procedures, a <CODE>SYNOPSIS</CODE> element may optionally follow an <CODE>ENTRY</CODE> and is intended to show how the procedure is to be invoked (typically with parameters annotated with modes): </P><BLOCKQUOTE class="code"><CODE>&lt;<SPAN class="functionname">LIST</SPAN>&nbsp;CLASS=EXPORTS&gt;<BR>&nbsp;&nbsp;&lt;<SPAN class="functionname">ENTRY</SPAN>&gt;&lt;&lt;<SPAN class="functionname">Map</SPAN>&gt;&gt;<BR>&nbsp;&nbsp;&lt;<SPAN class="functionname">SYNOPSIS</SPAN>&gt;&lt;&lt;{Map&nbsp;?+{L1}&nbsp;?+{F}&nbsp;??{L2}}&gt;&gt;<BR>&nbsp;&nbsp;&lt;<SPAN class="functionname">ITEM</SPAN>&gt;...<BR>&lt;/<SPAN class="functionname">LIST</SPAN>&gt;</CODE></BLOCKQUOTE><P> Note the use of <CODE>CLASS=EXPORTS</CODE> to suggest that the list is describing the exports of a module. </P></DD><DT><CODE>MATH</CODE> </DT><DT><CODE>MATH.EXTERN</CODE> </DT><DT><CODE>MATH.CHOICE</CODE> </DT><DD><P>the Oz Documentation DTD does not prescribe a specific marking scheme for math. Instead it lets the author pick an arbitrary notation. This notation is selected by the <CODE>TYPE</CODE> attribute (default is LaTeX). </P><BLOCKQUOTE class="code"><CODE>&lt;<SPAN class="functionname">MATH</SPAN>&gt;x^2+y^2=z^2&lt;/<SPAN class="functionname">MATH</SPAN>&gt;</CODE></BLOCKQUOTE><P> since rendering math on different media can be tricky, the author may also supply a choice of alternative notations: </P><BLOCKQUOTE class="code"><CODE>&lt;<SPAN class="functionname">MATH.CHOICE</SPAN>&gt;<BR>&nbsp;&nbsp;&lt;<SPAN class="functionname">MATH</SPAN>&nbsp;LATEX&gt;x^2+y^2=z^2&lt;/<SPAN class="functionname">MATH</SPAN>&gt;<BR>&nbsp;&nbsp;&lt;<SPAN class="functionname">MATH</SPAN>&nbsp;HTML&gt;&lt;![&nbsp;RCDATA&nbsp;[X&lt;<SPAN class="functionname">SUP</SPAN>&gt;2&lt;/<SPAN class="functionname">SUP</SPAN>&gt;+Y&lt;<SPAN class="functionname">SUP</SPAN>&gt;2&lt;/<SPAN class="functionname">SUP</SPAN>&gt;=Z&lt;<SPAN class="functionname">SUP</SPAN>&gt;2&lt;/<SPAN class="functionname">SUP</SPAN>&gt;&lt;/<SPAN class="functionname">MATH</SPAN>&gt;]]&gt;<BR>&nbsp;&nbsp;&lt;<SPAN class="functionname">MATH.EXTERN</SPAN>&nbsp;<SPAN class="variablename">TO</SPAN>=<SPAN class="string">&quot;file:fermat.gif&quot;</SPAN>&nbsp;TYPE=gif&gt;<BR>&lt;/<SPAN class="functionname">MATH.CHOICE</SPAN>&gt;</CODE></BLOCKQUOTE><P> Here the same math material is coded using three different notations. The last one refers to an external resource: the gif file <CODE>fermat.gif</CODE>. Note that <CODE>MATH</CODE> has content, but MATH.EXTERN is empty. </P></DD><DT><CODE>PICTURE</CODE> </DT><DT><CODE>PICTURE.EXTERN</CODE> </DT><DT><CODE>PICTURE.CHOICE</CODE> </DT><DD><P>this is similar in design to the <CODE>MATH</CODE> elements. </P></DD><DT><CODE>CODE</CODE> </DT><DT><CODE>CODE.EXTERN</CODE> </DT><DD><P><CODE>CODE</CODE> contains program code in a programming language; which programming language may be specified using the <CODE>PROGLANG</CODE> attribute. All elements accept the <CODE>PROGLANG</CODE> attribute: it indicates the default programming language in <CODE>CODE</CODE>-like elements whithin its scope. Thus, a document starting with: </P><BLOCKQUOTE class="code"><CODE>&lt;<SPAN class="functionname">BOOK</SPAN>&nbsp;PROGLANG=C&gt;</CODE></BLOCKQUOTE><P> would normally assume that the programming language is <SPAN class="PROG.LANG">C</SPAN>, unless this is overriden by an element with an explicit <CODE>PROGLANG</CODE> attribute. The choice of programming language may serve to obtain appropriate highlighting of code. </P><P><CODE>CODE</CODE> contains mostly raw program text. Sometimes, however, it is desirable to annotate variables within the code, for example with mode specifications, or simply to indicate a meta-variable (as opposed to a language level variable). For this reason occurrences of <CODE>VAR</CODE> and <CODE>SPAN</CODE> are also permitted. </P><P class="margin">Code Abbreviations</P><P> For convenience, the Oz Documentation DTD supports the following abbreviations: </P><TABLE align="center" bgcolor="#f0f0e0"><TR valign="top"><TD><P><CODE>&lt;&lt;...&gt;&gt;</CODE> </P></TD><TD><P><CODE>&lt;<SPAN class="functionname">CODE</SPAN>&gt;...&lt;/<SPAN class="functionname">CODE</SPAN>&gt;</CODE> </P></TD></TR><TR valign="top"><TD><P><CODE>&lt;&lt;&lt;...&gt;&gt;&gt;</CODE> </P></TD><TD><P><CODE>&lt;<SPAN class="functionname">CODE</SPAN>&nbsp;DISPLAY&gt;...&lt;/<SPAN class="functionname">CODE</SPAN>&gt;</CODE> </P></TD></TR><TR valign="top"><TD><P><CODE>?+{X}</CODE> </P></TD><TD><P><CODE>&lt;<SPAN class="functionname">VAR</SPAN>&nbsp;MODE=IN&nbsp;&nbsp;&gt;X&lt;/<SPAN class="functionname">VAR</SPAN>&gt;</CODE> </P></TD></TR><TR valign="top"><TD><P><CODE>??{X}</CODE> </P></TD><TD><P><CODE>&lt;<SPAN class="functionname">VAR</SPAN>&nbsp;MODE=OUT&nbsp;&gt;X&lt;/<SPAN class="functionname">VAR</SPAN>&gt;</CODE> </P></TD></TR><TR valign="top"><TD><P><CODE>?*{X}</CODE> </P></TD><TD><P><CODE>&lt;<SPAN class="functionname">VAR</SPAN>&nbsp;MODE=CIN&nbsp;&gt;X&lt;/<SPAN class="functionname">VAR</SPAN>&gt;</CODE> </P></TD></TR><TR valign="top"><TD><P><CODE>?@{X}</CODE> </P></TD><TD><P><CODE>&lt;<SPAN class="functionname">VAR</SPAN>&nbsp;MODE=CNIN&gt;X&lt;/<SPAN class="functionname">VAR</SPAN>&gt;</CODE> </P></TD></TR><TR valign="top"><TD><P><CODE>?_{X}</CODE> </P></TD><TD><P><CODE>&lt;<SPAN class="functionname">VAR</SPAN>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&gt;X&lt;/<SPAN class="functionname">VAR</SPAN>&gt;</CODE> </P></TD></TR><TR valign="top"><TD><P><CODE>?{X}</CODE> </P></TD><TD><P><CODE>&lt;<SPAN class="functionname">VAR</SPAN>&nbsp;TYPE=META&gt;X&lt;/<SPAN class="functionname">VAR</SPAN>&gt;</CODE> </P></TD></TR></TABLE><P> Thus you can write: <CODE>&lt;&lt;{List.map&nbsp;?+{L1}&nbsp;?+{F}&nbsp;??{L2}}&gt;&gt;</CODE> </P></DD><DT><CODE>VAR</CODE> </DT><DD><P>may occur in ordinary text and also in <CODE>CODE</CODE> elements. <CODE>VAR</CODE> serves to identify </P><OL type="1"><LI><P>programming language variables </P></LI><LI><P>meta variables </P></LI><LI><P>environment variables </P></LI><LI><P>non-terminal symbols in a grammar</P></LI></OL><P>. The choice is determined by attribute <CODE>TYPE</CODE>. </P><DL class="attribs"><DT><CODE>TYPE</CODE> </DT><DD><P>indicates the type of object represented by the <CODE>VAR</CODE> element. </P><DL><DT><SPAN class="SGML.IDENT">PROG</SPAN> </DT><DD><P>programming language variable </P></DD><DT><SPAN class="SGML.IDENT">META</SPAN> </DT><DD><P>meta variable </P></DD><DT><SPAN class="SGML.IDENT">ENV</SPAN> </DT><DD><P>environment variable </P></DD><DT><SPAN class="SGML.IDENT">GRAMMAR</SPAN> </DT><DD><P>grammar non-terminal </P></DD></DL><P> </P></DD><DT><CODE>MODE</CODE> </DT><DD><P>The <CODE>MODE</CODE> attribute further describes the expected modes of parameters to builtins and library procedures. </P><DL><DT><SPAN class="SGML.IDENT">IN</SPAN> </DT><DD><P>input (determined) </P></DD><DT><SPAN class="SGML.IDENT">OUT</SPAN> </DT><DD><P>output (usually free) </P></DD><DT><SPAN class="SGML.IDENT">CIN</SPAN> </DT><DD><P></P></DD><DT><SPAN class="SGML.IDENT">CNIN</SPAN> </DT><DD><P></P></DD></DL><P> </P></DD></DL><P> </P></DD><DT><CODE>PTR</CODE> </DT><DT><CODE>REF</CODE> </DT><DT><CODE>PTR.EXTERN</CODE> </DT><DT><CODE>REF.EXTERN</CODE> </DT><DD><P>serve for cross-references. For cross-references within the same document, use <CODE>PTR</CODE> or <CODE>REF</CODE>. <CODE>PTR</CODE> is empty and <CODE>REF</CODE> has content. </P><BLOCKQUOTE class="code"><CODE>&lt;<SPAN class="functionname">REF</SPAN>&nbsp;TO=FOO&gt;The&nbsp;definition&nbsp;of&nbsp;foo&lt;/<SPAN class="functionname">REF</SPAN>&gt;</CODE></BLOCKQUOTE><P> might produce a hyperlink in HTML and insert reference text like ``Definition 3.2, page 17'' in LaTeX. </P><BLOCKQUOTE class="code"><CODE>&lt;<SPAN class="functionname">PTR</SPAN>&nbsp;TO=FOO&gt;</CODE></BLOCKQUOTE><P> might insert a hyperlink with content ``Definition 3.2'' in HTML and again insert ``Definition 3.2, page 17'' in LaTeX. <CODE>FOO</CODE> is the ID of the element containing the definition of interest. Somewhere else in the document there would be an element like: </P><BLOCKQUOTE class="code"><CODE>&lt;<SPAN class="functionname">PARA</SPAN>&nbsp;CLASS=DEFINITION&nbsp;ID=FOO&gt;<BR>&nbsp;&nbsp;&lt;<SPAN class="functionname">TITLE</SPAN>&gt;Procedure&nbsp;&lt;&lt;<SPAN class="functionname">Foo</SPAN>&gt;&gt;&lt;/<SPAN class="functionname">TITLE</SPAN>&gt;<BR>&nbsp;&nbsp;...<BR>&lt;/<SPAN class="functionname">PARA</SPAN>&gt;</CODE></BLOCKQUOTE><P> If the element pointed to is a <CODE>NOTE</CODE>, then in HTML, <CODE>PTR</CODE> might be replaced by an hyperlinked-icon, and in LaTeX it could be replaced by an integer refering to the note by number. The cross-reference may be further specified using attribute <CODE>CLASS</CODE>, but often it is sufficient for the processing system to look at the element that is pointed to to determine what kind of reference is intended. </P><P>When the object that needs to be referenced does not reside within the current document, we must make an ``external'' reference. Such references cannot take advantage of the ID mechanism of SGML. Instead, the <CODE>TO</CODE> attribute contains data which it is up to the processing system to properly interpret, perhaps aided by a <CODE>CLASS</CODE> attribute. Often, <CODE>TO</CODE> will contain a url: </P><BLOCKQUOTE class="code"><CODE>Visit&nbsp;&lt;<SPAN class="functionname">REF.EXTERN</SPAN>&nbsp;<SPAN class="variablename">TO</SPAN>=<SPAN class="string">&quot;http://www.ps.uni-sb.de/oz/&quot;</SPAN>&gt;the&nbsp;Oz&nbsp;home<BR>page&lt;/<SPAN class="functionname">REF.EXTERN</SPAN>&gt;</CODE></BLOCKQUOTE><P> But it can contain other data for which a conventional interpretation has been assigned in the processing system. Thus, we might refer to the <SPAN class="TITLE">Open Programming Manual</SPAN> as follows: </P><BLOCKQUOTE class="code"><CODE>For&nbsp;details&nbsp;about&nbsp;IO&nbsp;programming,&nbsp;see&nbsp;&lt;<SPAN class="functionname">PTR.EXTERN</SPAN>&nbsp;<BR><SPAN class="variablename">TO</SPAN>=<SPAN class="string">&quot;ozdoc:open&quot;</SPAN>&gt;.</CODE></BLOCKQUOTE><P> </P></DD><DT><CODE>FILE</CODE> </DT><DD><P>borrowed from <SPAN class="TOOL">Texinfo</SPAN>. marks up a file name: </P><BLOCKQUOTE class="code"><CODE>&lt;<SPAN class="functionname">FILE</SPAN>&gt;/usr/local/oz/README&lt;/<SPAN class="functionname">FILE</SPAN>&gt;</CODE></BLOCKQUOTE><P> </P></DD><DT><CODE>KBD</CODE> </DT><DD><P>borrowed from <SPAN class="TOOL">Texinfo</SPAN>. marks up keyboard input: </P><BLOCKQUOTE class="code"><CODE>&lt;<SPAN class="functionname">KBD</SPAN>&gt;M-a&lt;/<SPAN class="functionname">KBD</SPAN>&gt;</CODE></BLOCKQUOTE><P> </P></DD><DT><CODE>KEY</CODE> </DT><DD><P>borrowed from <SPAN class="TOOL">Texinfo</SPAN>. marks up the conventional name for a key on a keyboard: </P><BLOCKQUOTE class="code"><CODE>&lt;<SPAN class="functionname">KEY</SPAN>&gt;RET&lt;/<SPAN class="functionname">KEY</SPAN>&gt;</CODE></BLOCKQUOTE><P> However, this can also be marked up using <CODE>NAME</CODE>: </P><BLOCKQUOTE class="code"><CODE>&lt;<SPAN class="functionname">NAME</SPAN>&nbsp;TYPE=KEY&gt;RET&lt;/<SPAN class="functionname">NAME</SPAN>&gt;</CODE></BLOCKQUOTE><P> </P></DD><DT><CODE>SAMP</CODE> </DT><DD><P>borrowed from <SPAN class="TOOL">Texinfo</SPAN>. marks up a literal example of a sequence of characters: </P><BLOCKQUOTE class="code"><CODE>&lt;<SPAN class="functionname">SAMP</SPAN>&gt;foo&lt;/<SPAN class="functionname">SAMP</SPAN>&gt;</CODE></BLOCKQUOTE><P> </P></DD><DT><CODE>NAME</CODE> </DT><DD><P>marks text that names an object; which kind of object should be indicated using the <CODE>TYPE</CODE> attribute: </P><TABLE align="center" bgcolor="#f0f0e0"><TR><TD><P align="center"><B>Examples uses of the <CODE>TYPE</CODE> attribute</B></P></TD></TR><TR valign="top"><TD><P><CODE>&lt;<SPAN class="functionname">NAME</SPAN>&nbsp;TYPE=FICTIONAL.CREATURE&gt;Gump&lt;/&gt;</CODE> </P></TD></TR><TR valign="top"><TD><P><CODE>&lt;<SPAN class="functionname">NAME</SPAN>&nbsp;TYPE=TOOL&gt;Gump&lt;/&gt;</CODE> </P></TD></TR><TR valign="top"><TD><P><CODE>&lt;<SPAN class="functionname">NAME</SPAN>&nbsp;TYPE=CHAR&gt;NUL&lt;/&gt;</CODE> </P></TD></TR><TR valign="top"><TD><P><CODE>&lt;<SPAN class="functionname">NAME</SPAN>&nbsp;TYPE=PERSON&gt;Denys&nbsp;Duchier&lt;/&gt;</CODE> </P></TD></TR><TR valign="top"><TD><P><CODE>&lt;<SPAN class="functionname">NAME</SPAN>&nbsp;TYPE=KEY&gt;RET&lt;/&gt;</CODE> </P></TD></TR><TR valign="top"><TD><P><CODE>&lt;<SPAN class="functionname">NAME</SPAN>&nbsp;TYPE=OS&gt;Linux&lt;/&gt;</CODE> </P></TD></TR></TABLE><P> </P></DD><DT><CODE>Q</CODE> </DT><DD><P>marks quoted phrases: </P><BLOCKQUOTE class="code"><CODE>Man,&nbsp;I&nbsp;hated&nbsp;that&nbsp;book!&nbsp;&nbsp;You&nbsp;hang&nbsp;in&nbsp;there&nbsp;through&nbsp;all&nbsp;that<BR>dreary&nbsp;prose&nbsp;and&nbsp;for&nbsp;his&nbsp;big&nbsp;finale,&nbsp;his&nbsp;major&nbsp;piece&nbsp;of&nbsp;bloody<BR>wisdom,&nbsp;all&nbsp;he's&nbsp;got&nbsp;to&nbsp;tell&nbsp;you&nbsp;is&nbsp;&lt;<SPAN class="functionname">Q</SPAN>&nbsp;LANG=FR&gt;La&nbsp;vie,&nbsp;ça&nbsp;n'est<BR>jamais&nbsp;si&nbsp;bon&nbsp;ni&nbsp;si&nbsp;mauvais&nbsp;qu'on&nbsp;croit&lt;/<SPAN class="functionname">Q</SPAN>&gt;.&nbsp;&nbsp;Bummer,&nbsp;man!<BR>What&nbsp;a&nbsp;let&nbsp;down!</CODE></BLOCKQUOTE><P> or </P><BLOCKQUOTE class="code"><CODE>Here&nbsp;goes&nbsp;another&nbsp;one&nbsp;of&nbsp;Microsoft's&nbsp;&lt;<SPAN class="functionname">Q</SPAN>&nbsp;<BR>CLASS=SOCALLED&gt;upgrades&lt;/<SPAN class="functionname">Q</SPAN>&gt;;&nbsp;down&nbsp;the&nbsp;drain,&nbsp;where&nbsp;it&nbsp;belongs!</CODE></BLOCKQUOTE><P> </P></DD><DT><CODE>SPAN</CODE> </DT><DD><P>this element has no particular semantics but serves mainly to mark an otherwise undistinguished piece of text so that it can be assigned an ID (e.&nbsp;g. for cross reference purposes) or a <CODE>CLASS</CODE> for whatever purpose was not anticipated by the DTD. </P><BLOCKQUOTE class="code"><CODE>&lt;<SPAN class="functionname">SPAN</SPAN>&nbsp;ID=FOO&gt;...&lt;/&gt;&nbsp;...&nbsp;&lt;<SPAN class="functionname">PTR</SPAN>&nbsp;TO=FOO&gt;&nbsp;...</CODE></BLOCKQUOTE><P> </P></DD><DT><CODE>DEF</CODE> </DT><DD><P>marks the defining occurrence of a term or phrase. It would probably be used to contribute an entry in a glossary section. It should probably be further specified using the <CODE>CLASS</CODE> attribute to indicate what kind of term is being defined. </P></DD><DT><CODE>FIGURE</CODE> </DT><DD><P>a figure contains displayed material. It may have an optional <CODE>TITLE</CODE>, and an optional <CODE>CAPTION</CODE> containing a longer description. Here is an example adapted from the TEI DTD documentation: </P><BLOCKQUOTE class="code"><CODE>&lt;<SPAN class="functionname">FIGURE</SPAN>&gt;<BR>&nbsp;&nbsp;&lt;<SPAN class="functionname">TITLE</SPAN>&gt;Mr&nbsp;Fezziwig's&nbsp;Ball&lt;/<SPAN class="functionname">TITLE</SPAN>&gt;<BR>&nbsp;&nbsp;&lt;<SPAN class="functionname">CAPTION</SPAN>&gt;A&nbsp;Cruikshank&nbsp;engraving&nbsp;showing&nbsp;Mr&nbsp;Fezziwig&nbsp;leading<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;a&nbsp;group&nbsp;of&nbsp;revellers&lt;/<SPAN class="functionname">CAPTION</SPAN>&gt;<BR>&nbsp;&nbsp;&lt;<SPAN class="functionname">PICTURE.EXTERN</SPAN>&nbsp;<SPAN class="variablename">TO</SPAN>=<SPAN class="string">&quot;fezziwig.jpg&quot;</SPAN>&gt;<BR>&lt;/<SPAN class="functionname">FIGURE</SPAN>&gt;</CODE></BLOCKQUOTE><P> </P><DL class="attribs"><DT><CODE>FLOAT</CODE> </DT><DD><P>A <CODE>FIGURE</CODE> may also float outside of the main flow of the document. This can be indicated by attribute <CODE>FLOAT</CODE>: </P><BLOCKQUOTE class="code"><CODE>&lt;<SPAN class="functionname">FIGURE</SPAN>&nbsp;FLOAT&gt;...&lt;/<SPAN class="functionname">FIGURE</SPAN>&gt;</CODE></BLOCKQUOTE><P> </P></DD><DT><CODE>CLASS</CODE> </DT><DD><P>The <CODE>CLASS</CODE> attribute should be used to indicate what kind of a figure it is: </P><BLOCKQUOTE class="code"><CODE>&lt;<SPAN class="functionname">FIGURE</SPAN>&nbsp;FLOAT&nbsp;CLASS=PICTURE&gt;...&lt;/<SPAN class="functionname">FIGURE</SPAN>&gt;</CODE></BLOCKQUOTE><P> Such an indication makes it possible to automatically generate a caption label that indicates this type and to cross-reference the figure in the appropriate list (e.&nbsp;g. here: a list of pictures). </P></DD></DL><P> </P></DD><DT><CODE>NOTE</CODE> </DT><DD><P>another kind of normally floating material. The difference between a floating figure and a note is that the latter usually leaves a trace in the main flow of the document. For example, footnotes typically leave a superscripted integer behind. The attribute <CODE>CLASS</CODE> should be used to indicate what kind of <CODE>NOTE</CODE> is intended. </P><DL class="attribs"><DT><CODE>FOOT</CODE> </DT><DD><P>since footnotes are a major application of <CODE>NOTE</CODE>s, the attribute <CODE>FOOT</CODE> can be used instead of <CODE>CLASS=FOOT</CODE>: </P><BLOCKQUOTE class="code"><CODE>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;<SPAN class="functionname">NOTE</SPAN>&nbsp;FOOT&gt;...&lt;/<SPAN class="functionname">NOTE</SPAN>&gt;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;<SPAN class="functionname">NOTE</SPAN>&nbsp;CLASS=FOOT&gt;...&lt;/<SPAN class="functionname">NOTE</SPAN>&gt;</CODE></BLOCKQUOTE><P> </P></DD></DL><P> </P></DD><DT><CODE>INDEX</CODE> </DT><DD><P><CODE>INDEX</CODE> is allowed everywhere in the scope of the <CODE>BOOK</CODE> element. </P><BLOCKQUOTE class="code"><CODE>&lt;<SPAN class="functionname">INDEX</SPAN>&gt;foo&lt;/<SPAN class="functionname">INDEX</SPAN>&gt;</CODE></BLOCKQUOTE><P> When several levels of indexing are required, they can be entered separated by <CODE>&lt;<SPAN class="functionname">AND</SPAN>&gt;</CODE>: </P><BLOCKQUOTE class="code"><CODE>&lt;<SPAN class="functionname">INDEX</SPAN>&gt;foo&lt;<SPAN class="functionname">AND</SPAN>&gt;bar&lt;<SPAN class="functionname">AND</SPAN>&gt;baz&lt;/<SPAN class="functionname">INDEX</SPAN>&gt;</CODE></BLOCKQUOTE><P> The <CODE>CLASS</CODE> attribute can be used to support multiple kinds of indexes: </P><BLOCKQUOTE class="code"><CODE>&lt;<SPAN class="functionname">INDEX</SPAN>&nbsp;CLASS=PERSON&gt;Maupassant&lt;/<SPAN class="functionname">INDEX</SPAN>&gt;<BR>&lt;<SPAN class="functionname">INDEX</SPAN>&nbsp;CLASS=PROCEDURE&gt;FoldL&lt;/<SPAN class="functionname">INDEX</SPAN>&gt;</CODE></BLOCKQUOTE><P> </P><DL class="attribs"><DT><CODE>SEE</CODE> </DT><DD><P>allows one index to refer to another by ID, and is a way to mark up a ``see'' reference: </P><BLOCKQUOTE class="code"><CODE>&lt;<SPAN class="functionname">INDEX</SPAN>&nbsp;ID=one.two.fr&gt;one&lt;<SPAN class="functionname">AND</SPAN>&gt;two&lt;<SPAN class="functionname">AND</SPAN>&gt;french&lt;/<SPAN class="functionname">INDEX</SPAN>&gt;<BR>...<BR>&lt;<SPAN class="functionname">INDEX</SPAN>&nbsp;SEE=one.two.fr&gt;un&lt;<SPAN class="functionname">AND</SPAN>&gt;deux&lt;/<SPAN class="functionname">INDEX</SPAN>&gt;</CODE></BLOCKQUOTE><P> </P></DD><DT><CODE>SORT.AS</CODE> </DT><DD><P>For each level of indexing, it may be necessary to distinguish between the text used as the content of the entry and the text used to perform sorting on the labels. The <CODE>SORT.AS</CODE> attribute is intended to supply text to use for sorting instead of the contents. </P></DD><DT><CODE>SCOPE</CODE> </DT><DD><P>To index a range of pages, you may supply one or more element IDs as the value of the <CODE>SCOPE</CODE> attribute. </P><BLOCKQUOTE class="code"><CODE>&lt;<SPAN class="functionname">INDEX</SPAN>&nbsp;SCOPE=section.bar&gt;foo&lt;<SPAN class="functionname">AND</SPAN>&gt;bar&lt;/<SPAN class="functionname">INDEX</SPAN>&gt;</CODE></BLOCKQUOTE><P> would associate to this index entry the range of pages covered by the element whose ID is <CODE>section.bar</CODE>. </P><BLOCKQUOTE class="code"><CODE>&lt;<SPAN class="functionname">INDEX</SPAN>&nbsp;<SPAN class="variablename">SCOPE</SPAN>=<SPAN class="string">&quot;par.bar1&nbsp;par.bar2&quot;</SPAN>&gt;foo&lt;<SPAN class="functionname">AND</SPAN>&gt;bar&lt;/<SPAN class="functionname">INDEX</SPAN>&gt;</CODE></BLOCKQUOTE><P> would associate with the entry the range of pages covered by the two elements with ID <CODE>par.bar1</CODE> and <CODE>par.bar2</CODE> (presumably consecutive). </P></DD></DL><P> </P></DD><DT><CODE>GRAMMAR</CODE> </DT><DT><CODE>GRAMMAR.RULE</CODE> </DT><DT><CODE>GRAMMAR.ALT</CODE> </DT><DT><CODE>GRAMMAR.NOTE</CODE> </DT><DD><P>formal syntactic definitions often make use of BNF-like notation. A <CODE>GRAMMAR.RULE</CODE> marks up a grammatical production. The body of the rule consists of a sequence of <CODE>GRAMMAR.ALT</CODE> elements. Each <CODE>GRAMMAR.ALT</CODE> element may end with a <CODE>GRAMMAR.NOTE</CODE> element that provides an inline comment for the element. <CODE>GRAMMAR</CODE> contains a sequence of <CODE>GRAMMAR.RULE</CODE> elements that belong together: it could provide the additional service of ensuring pleasant vertical alignment. </P><DL class="attribs"><DT><CODE>TYPE</CODE> </DT><DD><P><CODE>GRAMMAR.ALT</CODE> can be further specified using attribute TYPE </P><DL class="attrib.values"><DT><SPAN class="SGML.IDENT">DEF</SPAN> </DT><DD><P>indicates that this element begins a new rule body. Usually this is rendered with an initial symbol like <CODE>::=</CODE> </P></DD><DT><SPAN class="SGML.IDENT">ADD</SPAN> </DT><DD><P>indicates that this element begins a new rule body to be added as an additional alternative to the alternatives previously defined for the head non-terminal. Usually this is rendered with an initial symbol like <CODE>+=</CODE> </P></DD><DT><SPAN class="SGML.IDENT">OR</SPAN> </DT><DD><P>indicates the start of the next alternative rewriting. Usually this is rendered with initial symbol <CODE>|</CODE> </P></DD><DT><SPAN class="SGML.IDENT">SPACE</SPAN> </DT><DD><P>indicates the continuation of the previous <CODE>GRAMMAR.ALT</CODE> element. Usually this is rendered by breaking to a newline but omitting any initial symbol </P></DD></DL><P> </P></DD></DL><P> </P></DD><DT><CODE>TABLE</CODE> </DT><DT><CODE>TR</CODE> </DT><DT><CODE>TD</CODE> </DT><DT><CODE>TH</CODE> </DT><DD><P>a <CODE>TABLE</CODE> consist of rows marked with <CODE>TR</CODE>. A row consists of a sequence of data <CODE>TD</CODE> and header <CODE>TH</CODE> cells, each of which may span several columns as specified by attribute <CODE>COLSPAN</CODE>. </P><DL class="attribs"><DT><CODE>COLSPAN</CODE> </DT><DD><P>for <CODE>TH</CODE> and <CODE>TD</CODE>, indicates the number of column spanned by the element. When omitted, the cell spans exactly one column. </P></DD></DL><P> </P></DD><DT><CODE>BACK</CODE> </DT><DD><P>container for back-matter material, such as <CODE>BIB.EXTERN</CODE> for bibliographic entries. </P></DD><DT><CODE>BIB.EXTERN</CODE> </DT><DD><P>refers to a specific entry denoted by attribute <CODE>KEY</CODE> in an external bibliographic database denoted by <CODE>TO</CODE>. </P><BLOCKQUOTE class="code"><CODE>&lt;<SPAN class="functionname">BIB.EXTERN</SPAN>&nbsp;ID=ZIPPY&nbsp;<SPAN class="variablename">TO</SPAN>=<SPAN class="string">&quot;weirdo.bib&quot;</SPAN>&nbsp;<SPAN class="variablename">KEY</SPAN>=<SPAN class="string">&quot;elzippo91&quot;</SPAN>&gt;</CODE></BLOCKQUOTE><P> </P><DL class="attribs"><DT><CODE>ID</CODE> </DT><DD><P>the <CODE>ID</CODE> makes it possible to ``cite'' the entry: </P><BLOCKQUOTE class="code"><CODE>&lt;<SPAN class="functionname">PTR</SPAN>&nbsp;TO=ZIPPY&gt;</CODE></BLOCKQUOTE><P> </P></DD><DT><CODE>TO</CODE> </DT><DD><P>denotes an external bibliographic database from which the actual contents of the bibliographic entry will have to be extracted. </P></DD><DT><CODE>KEY</CODE> </DT><DD><P>denotes the desired entry in the external bibliographic database. </P></DD></DL><P> </P></DD><DT><CODE>CHUNK</CODE> </DT><DD><P>provides literate programming support. A chunk of code is named by its <CODE>title</CODE>. There may be several chunks with the same title: their code is concatenated. A chunk may be used as a macro to insert code into another chunk: this is effected by <CODE>CHUNK.REF</CODE>. </P></DD><DT><CODE>CHUNK.REF</CODE> </DT><DD><P>Its content is (the text of) the title of a chunk. It is intended to denote the concatenated code of all chunks with this title. </P></DD></DL><P></P></DIV><TABLE align="center" border="0" cellpadding="6" cellspacing="6" class="nav"><TR bgcolor="#DDDDDD"><TD><A href="node4.html#chapter.principles">&lt;&lt; Prev</A></TD><TD><A href="index.html">- Up -</A></TD><TD><A href="node6.html#chapter.extending">Next &gt;&gt;</A></TD></TR></TABLE><HR><ADDRESS><A href="http://www.ps.uni-sb.de/~duchier/">Denys&nbsp;Duchier</A><BR><SPAN class="version">Version 1.4.0 (20110908185330)</SPAN></ADDRESS></BODY></HTML>