Tutorial > Structured Documentation Overview
  
Structured Documentation Overview
Structured documents conform to a set of rules that define and control the structure of a document. XML and HTML are examples of structured documents.
The set of rules that define a document's structure is called its “document type.” When you author a document in Arbortext Editor, the Editor is constantly checking the rules defined in the associated document type and will only let you insert content into the document that conforms to those rules. DocBook and DITA (Darwin Information Typing Architecture) are examples of document types.
A document type defines the following components of a document:
The set of tags that can be used in a document
A tag is the basic building block of a structured document. A tag is a container and has a start tag and an end tag. Tags can contain other tags, attributes, and text. Paragraphs and lists are examples of tags.
The “attributes” associated with each tag
An attribute provides additional information about a tag and is contained inside of the tag. For example, a tag could have an attribute that defines the type of user for whom the information in the tag is intended.
The structure in which the tags can be arranged
Each document type has a single tag that contains all of the other tags defined in the document type. The document type defines the tag hierarchy contained in that outer tag. The document type also defines whether a tag is optional or required and whether it can contain other tags, text, or both.
Following is an example of a document type for writing a letter:
Letter
Date
Greeting
Body
Paragraph or List or Table
Close
The Letter document type contains the following primary tags:
Letter
The Letter tag is the outer tag in the document type and contains seven other tags. Four of those tags (Date, Greeting, Body, and Close) are required and must be in a Letter document in that order.
Date
The Date tag must be the first tag inserted into a Letter document. It can only contain text and is intended to contain a date.
Greeting
The Greeting tag must be the second tag inserted into a Letter document. It can only contain text.
Body
The Body tag must be the third tag inserted into a Letter document. It can only contain other tags, not text. The Body tag can contain one or more Paragraph, List, or Table tags. Body can contain any number of these tags in any order.
Close
The Close tag must be the last tag inserted into a Letter document. It can only contain text.
Stylesheets
The formatting for a structured document is not stored in the document itself. Instead, each document type has one or more stylesheets associated with the document type that controls the appearance of the document through a collection of style settings. Style settings can include basic formatting information such as font size, paragraph spacing, and page layout, or more advanced formatting such as automatic generation of a table of contents and an index.
The appearance of a document in the Arbortext Editor window is controlled by a stylesheet.