| 1 |
<!doctype html public "-//W30//DTD W3 HTML 2.0//EN"> |
| 2 |
|
| 3 |
<HTML> |
| 4 |
|
| 5 |
<!-- This file was generated using SDF 2.001 by |
| 6 |
Ian Clatworthy ([email protected]). SDF is freely |
| 7 |
available from http://www.mincom.com/mtr/sdf. --> |
| 8 |
|
| 9 |
<HEAD> |
| 10 |
<TITLE>SDF 2.001: SDF User Guide: A simple example</TITLE> |
| 11 |
<STYLE TYPE="text/css"> |
| 12 |
<!-- |
| 13 |
.changed {background-color: teal} |
| 14 |
.changed {background-color: teal} |
| 15 |
.changed {background-color: teal} |
| 16 |
.changed {background-color: teal} |
| 17 |
.changed {background-color: teal} |
| 18 |
--> |
| 19 |
</STYLE> |
| 20 |
</HEAD> |
| 21 |
<BODY BGCOLOR="ffffff"> |
| 22 |
|
| 23 |
<DIV CLASS="header"> |
| 24 |
<P><IMG SRC="../sdflogo.gif" ALIGN="Right"></P> |
| 25 |
<DIV CLASS="navigate"> |
| 26 |
<P ALIGN="Center"><A HREF="ug_sdf.html">Contents</A> | <A HREF="in_start.html">Parent Topic</A> | <A HREF="in_insta.html">Previous Topic</A> | <A HREF="in_gsgen.html">Next Topic</A> <BR><A HREF="../index.html">Home</A> | <A HREF="../catalog.html">Catalog</A></P> |
| 27 |
</DIV> |
| 28 |
<BR CLEAR="Right"> |
| 29 |
</DIV> |
| 30 |
<DIV CLASS="main"> |
| 31 |
<H1>1.3. A simple example</H1> |
| 32 |
<HR> |
| 33 |
<H2><A NAME="A sample SDF document">1.3.1. A sample SDF document</A></H2> |
| 34 |
<P>A sample SDF document is shown below:</P> |
| 35 |
<PRE> |
| 36 |
# Build the title |
| 37 |
!define DOC_NAME "GalaxyBuilder" |
| 38 |
!define DOC_TYPE "Discussion Paper" |
| 39 |
!define DOC_AUTHOR "Joe Bloggs" |
| 40 |
!build_title |
| 41 |
|
| 42 |
H1: Introduction |
| 43 |
|
| 44 |
After extensive market research, I believe there is |
| 45 |
an excellent opportunity for us to develop software |
| 46 |
for the I<galaxy construction industry>. Potential |
| 47 |
customers include: |
| 48 |
|
| 49 |
* NASA |
| 50 |
* European Community |
| 51 |
* China |
| 52 |
* Japan. |
| 53 |
|
| 54 |
Note: The proposed name of the software package to be |
| 55 |
developed is [[DOC_NAME]]. If you want to suggest a |
| 56 |
better name, send email to {{EMAIL:[email protected]}}. |
| 57 |
|
| 58 |
H2: Software Requirements |
| 59 |
|
| 60 |
The key requirements are: |
| 61 |
|
| 62 |
^ support for the design and simulation of galaxies |
| 63 |
containing up to: |
| 64 |
- 1000 large planets, or |
| 65 |
- 5000 small planets |
| 66 |
+ the package needs to be easy to use |
| 67 |
+ the package needs to be well documented. |
| 68 |
|
| 69 |
H2: Project Team |
| 70 |
|
| 71 |
Exploding galaxies will be B<very> bad for business, |
| 72 |
so we need the best team possible for this project: |
| 73 |
|
| 74 |
!block table |
| 75 |
Person Role |
| 76 |
Mary Jones Project Manager |
| 77 |
Hans Blass Architect |
| 78 |
Bill Smith Software Engineer |
| 79 |
!endblock |
| 80 |
</PRE> |
| 81 |
<P><HR WIDTH="80%" ALIGN="Left"> |
| 82 |
<STRONG>Note: </STRONG>This document (called <TT>mydoc.sdf</TT>) is provided in the <TT>doc/paper</TT> directory of the SDF distribution. |
| 83 |
<HR WIDTH="80%" ALIGN="Left"></P> |
| 84 |
<HR> |
| 85 |
<H2><A NAME="A brief explanation">1.3.2. A brief explanation</A></H2> |
| 86 |
<P>Comments begin with a # character as the first non-whitespace character on a line.</P> |
| 87 |
<P>Macros are embedded commands which begin with a ! as the first non-whitespace character on a line. The <A HREF="../ref/mdefine.html">define</A> macro is used to set variables. The value of a variable can be embedded in paragraph text by using the [[...]] syntax.</P> |
| 88 |
<P>The DOC_NAME and DOC_TYPE variables are used by the <A HREF="../ref/mbuild_t.html">build_title</A> macro which creates:</P> |
| 89 |
<UL> |
| 90 |
<LI>a cover page (or two) for paper-based outputs |
| 91 |
<LI>a title header for online outputs.</UL> |
| 92 |
<P>Paragraphs can be tagged in different ways. For the vast majority of SDF documents, the only tags used are:</P> |
| 93 |
<TABLE CLASS="columns" BORDER> |
| 94 |
<TR CLASS="heading"> |
| 95 |
<TD> |
| 96 |
<STRONG>Tag</STRONG> |
| 97 |
</TD> |
| 98 |
<TD> |
| 99 |
<STRONG>Meaning</STRONG> |
| 100 |
</TD> |
| 101 |
</TR> |
| 102 |
<TR> |
| 103 |
<TD> |
| 104 |
H1: |
| 105 |
</TD> |
| 106 |
<TD> |
| 107 |
level 1 heading |
| 108 |
</TD> |
| 109 |
</TR> |
| 110 |
<TR> |
| 111 |
<TD> |
| 112 |
H2: |
| 113 |
</TD> |
| 114 |
<TD> |
| 115 |
level 2 heading |
| 116 |
</TD> |
| 117 |
</TR> |
| 118 |
<TR> |
| 119 |
<TD> |
| 120 |
* |
| 121 |
</TD> |
| 122 |
<TD> |
| 123 |
item in level 1 bulleted list |
| 124 |
</TD> |
| 125 |
</TR> |
| 126 |
<TR> |
| 127 |
<TD> |
| 128 |
- |
| 129 |
</TD> |
| 130 |
<TD> |
| 131 |
item in level 2 bulleted list |
| 132 |
</TD> |
| 133 |
</TR> |
| 134 |
<TR> |
| 135 |
<TD> |
| 136 |
^ |
| 137 |
</TD> |
| 138 |
<TD> |
| 139 |
first item in level 1 ordered list |
| 140 |
</TD> |
| 141 |
</TR> |
| 142 |
<TR> |
| 143 |
<TD> |
| 144 |
+ |
| 145 |
</TD> |
| 146 |
<TD> |
| 147 |
next item in level 1 ordered list |
| 148 |
</TD> |
| 149 |
</TR> |
| 150 |
<TR> |
| 151 |
<TD> |
| 152 |
> |
| 153 |
</TD> |
| 154 |
<TD> |
| 155 |
fixed-width, verbatim text |
| 156 |
</TD> |
| 157 |
</TR> |
| 158 |
<TR> |
| 159 |
<TD> |
| 160 |
Note: |
| 161 |
</TD> |
| 162 |
<TD> |
| 163 |
note |
| 164 |
</TD> |
| 165 |
</TR> |
| 166 |
</TABLE> |
| 167 |
|
| 168 |
<P>Phrases can also be tagged in several ways. Any phrase can be tagged using the syntax:</P> |
| 169 |
<PRE> |
| 170 |
{{XYZ:...}} |
| 171 |
</PRE> |
| 172 |
<P>where XYZ is the tag. For single, uppercase character tags like I (Italics) and B (Bold), POD-style syntax is also supported:</P> |
| 173 |
<PRE> |
| 174 |
X<...> |
| 175 |
</PRE> |
| 176 |
<P>where X is the tag.</P> |
| 177 |
<P>Tables can be specified using the <A HREF="../ref/ftable.html">table</A> filter, typically in combination with the <A HREF="../ref/mblock.html">block</A> and <A HREF="../ref/mendbloc.html">endblock</A> macros. The first row is the headings. Remaining rows are data.</P> |
| 178 |
</DIV> |
| 179 |
<DIV CLASS="footer"> |
| 180 |
<DIV CLASS="navigate"> |
| 181 |
<P ALIGN="Center"><A HREF="ug_sdf.html">Contents</A> | <A HREF="in_start.html">Parent Topic</A> | <A HREF="in_insta.html">Previous Topic</A> | <A HREF="in_gsgen.html">Next Topic</A> <BR><A HREF="../index.html">Home</A> | <A HREF="../catalog.html">Catalog</A></P> |
| 182 |
</DIV> |
| 183 |
</DIV> |
| 184 |
|
| 185 |
</BODY> |
| 186 |
</HTML> |