Next Up Previous Contents
Next: 4.2 Sectioning
Up: 4 The structure of the document
Previous: 4 The structure of the document
[ID index][Keyword index]

4.1 Overall structure

Includes sun (or whatever top-level element is appropriate for the document type), which contains docinfo and docbody. The former contains abstract, author, authorlist, copyright, coverimage, docnumber, editors, keyword, manualtype, otherauthors, softwareversion, mapidlist, mapid, title; and the latter contains the body text, the backmatter, and the appendices.

An SGML document always starts with a doctype declaration. There are seven document types defined at present:

<!DOCTYPE sug PUBLIC "-//Starlink//DTD Starlink SUG//EN">
<!DOCTYPE sun PUBLIC "-//Starlink//DTD Starlink SUN//EN">
<!DOCTYPE ssn PUBLIC "-//Starlink//DTD Starlink SSN//EN">
<!DOCTYPE sgp PUBLIC "-//Starlink//DTD Starlink SGP//EN">
<!DOCTYPE sc  PUBLIC "-//Starlink//DTD Starlink SC//EN">
<!DOCTYPE sg  PUBLIC "-//Starlink//DTD Starlink SG//EN">
<!DOCTYPE mud PUBLIC "-//Starlink//DTD Starlink MUD//EN">
These cover, respectively, the Starlink User Guide, Starlink user notes, system notes, general papers, cookbooks, and guides, and Miscellaneous User Documents. These document types are broadly the same (there is a single DTD underlying them all), but the different types have different features, summarised in Table 3.

DTDAbstractVersioningDocnumberRoutinelistEnforceLinkPolicy
sugyesyesnonoyes
sunyesyesyesyesyes
ssnyesyesyesnoyes
sgpyesyesyesnoyes
scyesyesyesnoyes
sgyesyesyesnoyes
mudopt'lnoyesnono

Table 3

Starlink DTD feature summary

The table headings in Table 3 are as follows:

Abstract
Is an abstract required or optional.
Versioning
Is the history mechanism, described in Section 4.5 required? If not, the docdate element is required.
Docnumber
Is a document number required?
Routinelist
Are the code-documentation elements, described in Section 4.4 available?
EnforceLinkPolicy
Is the link policy enforced? See Section 4.6.

These defaults are generally appropriate for the type of document. If you need to change them for a particular document, however, you can. The only case where you are likely to need to change the default is in in the case of the routine-list feature, if you wish to add it to a document type which does not have it by default, and you do this by invoking the SSN DTD (for example) as follows

<!DOCTYPE ssn PUBLIC "-//Starlink//DTD Starlink SSN//EN" [
  <!ENTITY % Feature.Routinelist 'INCLUDE'>
]>
Note that the entity names are case-sensitive, and note the space after the `%' sign.

The top-level element in the document contains two elements, docinfo and docbody. The second contains all the text of the document, and the first all the `meta-information' - the author, title, keywords, and so on, which are important for identifying and indexing the document. The docinfo elements should be self-explanatory, with the exception of the history element, which is discussed in Section 4.5.

The docbody element contains all the text of the document. Any document appendices are gathered together in a single appendices element, with each appendix in a sect element.

Material such as a bibliography and endnotes do not go in an appendix, but in a separate backmatter element (see Section 4.3).


Next Up Previous Contents
Next: 4.2 Sectioning
Up: 4 The structure of the document
Previous: 4 The structure of the document
[ID index][Keyword index]
The Starlink SGML Set
Starlink System Note 70
Norman Gray, Mark Taylor
21 April 1999. Release DR-0.7-13. Last updated 24 August 2001