Before going into details I want to show you how an UDO source file may look like. You can use this example to make your own source files if you want to.
######################################## # @(#) An example for UDO # @(#) Dirk Hagedorn, 1996/04/16 ######################################## !raw [stg] @subject "Documentation/Utilities" !docinfo [title] A short example for !docinfo [program] UDO !docinfo [date] (!today) !docinfo [author] Dirk Hagedorn !use_auto_subtocs [info,html,stg,tvh,win,aqv] !use_auto_subsubtocs [info,html,stg,tvh,win,aqv] !no_effects [asc] !use_justification [asc] ######################################## !begin_document !maketitle !tableofcontents !node Automatic layout UDO layouts the source file automatically. You don't have to take care about spaces between two words because UDO enters line breaks on its own. Further more it doesn't make sense but doesn't disturb UDO if you enter more than one empty line between to paragraphs. Paragraphs are split by using empty lines or commands. !node A chapter This is the text of this chapter. Due to the switches inside the preamble it follows a table-of-contents-like list of all sections of this chapter. !subnode A section This is the text of this section. A ""subsubtoc"" will follow due to the switches inside the preamble, too. !subsubnode A subsection This is the text of this subsection. !end_document
At the beginning of this example you can see a comment. A comment
is a line that begins with a #
immediately.
The next line is a special line. This line contains a special command for the ST-Guide. If you don't know the ST-Guide just add this line at the beginning of your source file so that are all the people are able to build a hypertext if they want to.
Now the information for the title page and the headlines are set.
!docinfo [title] and !docinfo [program] should make sense
if you read them one after another. In this example it would be An
example for UDO
. If you look at the line containing
!docinfo [date] you will see the placeholder
(!today) that is replaced by the current system date.
You can set the date to April 16th, 1996 manually, if you want to.
The preamble contains some switches. The first to switches are set
for the output of sub-tables-of-contents
in hypertexts. The
abbreviations of these hypertexts you will see inside the brackets. In
a subtoc
all subnodes of a node are printed like a table of
contents so that readers of a hypertext are enabled to directly switch
to an interesting subnode.
The switch !no_effects [asc] suppresses the usage of Usenet text effect commands like stars for bold and slashes for italic text.
The switch !use_justification [asc] tells UDO to layout the ASCII file with justified text.
The command !begin_document tells UDO that now the main part of the document begins. This command has to be part of any source file!
In first place we output the title page that is built with the information set in the preamble of this example. You should use !maketitle directly after !begin_document if you use it. It is possible to use it later but I don't think that it would work without problems.
Then we want that UDO prints a table of contents. There you can see all chapters, sections and subsections of the source file. Like !maketitle you should use !tableofcontents directly after !begin_document or !maketitle if you use this command.
Now we can enter the first chapter of our text. Chapters are marked with !node. Please read the contents of this chapter that contains additional information.
The following lines demonstrate how to use chapters, sections and subsections. You should also read the text of these chapters to get more information.
Finally we end our text with the command !end_document. This command has to be part of every source file and should be the last command of a source file!