<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/css"
   href="/~hammond/gellmu/gellmuart.css"?>
<!DOCTYPE article
  PUBLIC "-//GNU GPL: William F. Hammond//DTD GELLMU XML 0.7.5U//EN"
  "http://www.albany.edu/~hammond/gellmu/xml/uxgellmu.dtd" [
<!ENTITY TableOfContentsFile SYSTEM "gsample2e.xcn">
<!ENTITY % ComputedEntitiesFile SYSTEM "gsample2e.xet">
%ComputedEntitiesFile;
]>
<article stem="gsample2e"
><cw0
/><preamble
><title
>An Example Document</title><cs0
/><author
>Leslie Lamport</author><cs0
/><date
>January 21, 1994</date><cs0
/><nul
/><nogratlinks
/><nul
/><nobanner
/><nul
/><cw0
/><cw0
/><nul
/><cw0
/><cw0
/><nul
/><cm0
/><cs0
/><nul
/><nul
/><nul
/></preamble><body
><cs0
/><maketitle
/><cs0
/><parb
>This is an example input file<eos
/>  Comparing it with
the output it generates can show you how to
produce a simple document of your own<eos
/>
</parb><Section depth="1" seq = "1" sid="1"
><sunit>&SecRef-1;</sunit
><shead
><label lseq="1">SU-1</label
>Ordinary Text</shead><cs0
/><cw0
/><cw0
/><parb
>The ends  of words and sentences are marked
  by   spaces. It  doesn't matter how many
spaces    you type; one is as good as 100<eos
/>  The
end of   a line counts as a space<eos
/></parb><parb
>One   or more   blank lines denote the  end
of  a paragraph<eos
/></parb><parb
>Since any number of consecutive spaces are treated
like a single one, the formatting of the input
file makes no difference to
      <latex
/>,                <cs0
/>
but it makes a difference to you<eos
/>  When you use
<latex
/>, making your input file as easy to read
as possible will be a great help as you write
your document and when you change it<eos
/>  This sample
file shows how you can add comments to your own input
file<eos
/></parb><parb
>Because printing is different from typewriting,
there are a number of things that you have to do
differently when preparing an input file than if
you were just typing the document directly<eos
/>
Quotation marks like
       <quophrase
>this</quophrase>
have to be handled specially, as do quotes within
quotes:
       <quophrase
><hsp
/>`this'            <cs0
/>
        is what I just
        wrote, not  `that'<hsp
/></quophrase><eos
/></parb><parb
>Dashes come in three sizes: an
       intra<hyp
/>word
dash, a medium dash for number ranges like
       1<rdash
/>2,
and a punctuation
       dash<pdash
/>like
this<eos
/></parb><parb
>A sentence<hyp
/>ending space should be larger than the
space between words within a sentence<eos
/>  You
sometimes have to type special commands in
conjunction with punctuation characters to get
this right, as in the following sentence<eos
/>
       Gnats, gnus, etc.<spc
/>all  <cs0
/>
       begin with G<aTs
/><eos
/>         <cs0
/>
You should check the spaces after periods when
reading your output to make sure you haven't
forgotten any special cases<eos
/>  Generating an
ellipsis
       <ldots
/><spc
/>              <cs0
/>
<cw0
/>
<cw0
/>
<cw0
/>
<cw0
/>
<cw0
/>
<cw0
/>
<cw0
/>
with the right spacing around the periods requires
a special command<eos
/></parb><parb
><latex
/><spc
/>interprets some common characters as
commands, so you must type special commands to
generate them<eos
/>  These characters include the
following:
       <dol
/> <amp
/> <pct
/> <hsh
/> <lbr
/> and <rbr
/><eos
/></parb><parb
>In printing, text is usually emphasized with an
       <emph
>italic</emph>
type style<eos
/></parb><parb
><emph
>   A long segment of text can also be emphasized
   in this way<eos
/>  Text within such a segment can be
   given <emph
>additional</emph> emphasis<eos
/></emph></parb><parb
>It is sometimes necessary to prevent <latex
/><spc
/>from
breaking a line where it might otherwise do so<eos
/>
This may be at a space, as between the <quophrase
>Mr.</quophrase> and
<quophrase
>Jones</quophrase> in
       <quophrase
>Mr.<nbs
/>Jones</quophrase>,        <cs0
/>
or within a word<pdash
/>especially when the word is a
symbol like
       <emph
>itemnum</emph>
that makes little sense when hyphenated across
lines<eos
/></parb><parb
>Footnotes<footnote
>This is an example of a footnote.</footnote>
pose no problem<eos
/></parb><parb
><latex
/><spc
/>is good at typesetting mathematical formulas
like
       <math
> x<minus
/>3y <plus
/> z <equals
/> 7 </math>
or
       <math
> a<msub
>1</msub> <gtc
/> x<pow
>2n</pow> <plus
/> y<pow
>2n</pow> <gtc
/> x' </math>
or
<nul
/>
       <math
> (A, B) <equals
/> <sum
><msub
>i</msub> a<msub
>i</msub> b<msub
>i</msub> </sum></math><eos
/>
The spaces you type in a formula are
ignored<eos
/>  Remember that a letter like
       <tmath
>x</tmath>                   <cs0
/>
is a formula when it denotes a mathematical
symbol, and it should be typed as one<eos
/>
</parb></Section
><Section depth="1" seq = "2" sid="2"
><sunit>&SecRef-2;</sunit
><shead
><label lseq="2">SU-2</label
>Displayed Text</shead><parb
>Text is displayed by indenting it from the left
margin<eos
/>  Quotations are commonly displayed<eos
/>  There
are short quotations
<quote
><parb
>This is a short a quotation<eos
/>  It consists of a
   single paragraph of text<eos
/>  See how it is formatted<eos
/></parb></quote>
and longer ones<eos
/>
<quotation
><parb
>This is a longer quotation<eos
/>  It consists of two
   paragraphs of text, neither of which are
   particularly interesting<eos
/></parb><parb
>   This is the second paragraph of the quotation<eos
/>  It
   is just as dull as the first paragraph<eos
/></parb></quotation>
Another frequently<hyp
/>displayed structure is a list<eos
/>
The following is an example of an <emph
>itemized</emph>
list<eos
/>
<itemize
><item
><itembody
>This is the first item of an itemized list<eos
/>
         Each item in the list is marked with a <quophrase
>tick</quophrase><eos
/>
         You don't have to worry about what kind of tick
         mark is used<eos
/>

   </itembody></item><item
><itembody
>This is the second item of the list<eos
/>  It
         contains another list nested inside it<eos
/>  The inner
         list is an <emph
>enumerated</emph> list<eos
/>
         <enumerate
><item
><itembody
>This is the first item of an enumerated
                  list that is nested within the itemized list<eos
/>

            </itembody></item><item
><itembody
>This is the second item of the inner list<eos
/>
                  <latex
/><spc
/>allows you to nest lists deeper than
                  you really should<eos
/>
         </itembody></item></enumerate>
         This is the rest of the second item of the outer
         list<eos
/>  It is no more interesting than any other
         part of the item<eos
/>
   </itembody></item><item
><itembody
>This is the third item of the list<eos
/></itembody></item></itemize>
You can even display poetry<eos
/>
<verse
><parb
>There is an environment
    for verse <brk
/> <cs0
/>
   Whose features some poets <cs0
/>
   will curse<eos
/>

<cw0
/></parb><parb
>   For instead of making<brk
/> Them do <emph
>all</emph> line breaking, <brk
/> It allows them to put too many words on a line when they'd rather be
   forced to be terse<eos
/></parb></verse></parb><parb
>Mathematical formulas may also be displayed<eos
/>  A
displayed formula
is
one<hyp
/>line long; multiline
formulas require special formatting instructions<eos
/>
   <displaymath
>  (<Gamma
/>, <psi
/>') <equals
/> x<rdq
/> <plus
/> y<pow
>2</pow> <plus
/> z<msub
>i</msub><pow
>n</pow></displaymath>
Don't start a paragraph with a displayed equation,
nor make one a paragraph by itself<eos
/>
</parb></Section
></body
><cs0
/></article>
