Commit | Line | Data |
---|---|---|
920dae64 AT |
1 | <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> |
2 | <html> | |
3 | <head> | |
4 | <link rel="STYLESHEET" href="doc.css" type='text/css' /> | |
5 | <link rel="SHORTCUT ICON" href="../icons/pyfav.png" type="image/png" /> | |
6 | <link rel='start' href='../index.html' title='Python Documentation Index' /> | |
7 | <link rel="first" href="doc.html" title='Documenting Python' /> | |
8 | <link rel='contents' href='contents.html' title="Contents" /> | |
9 | <link rel='last' href='about.html' title='About this document...' /> | |
10 | <link rel='help' href='about.html' title='About this document...' /> | |
11 | <link rel="next" href="classes.html" /> | |
12 | <link rel="prev" href="style-guide.html" /> | |
13 | <link rel="parent" href="doc.html" /> | |
14 | <link rel="next" href="latex-syntax.html" /> | |
15 | <meta name='aesop' content='information' /> | |
16 | <title>4 LaTeX Primer </title> | |
17 | </head> | |
18 | <body> | |
19 | <DIV CLASS="navigation"> | |
20 | <div id='top-navigation-panel' xml:id='top-navigation-panel'> | |
21 | <table align="center" width="100%" cellpadding="0" cellspacing="2"> | |
22 | <tr> | |
23 | <td class='online-navigation'><a rel="prev" title="3 Style Guide" | |
24 | href="style-guide.html"><img src='../icons/previous.png' | |
25 | border='0' height='32' alt='Previous Page' width='32' /></A></td> | |
26 | <td class='online-navigation'><a rel="parent" title="Documenting Python" | |
27 | href="doc.html"><img src='../icons/up.png' | |
28 | border='0' height='32' alt='Up One Level' width='32' /></A></td> | |
29 | <td class='online-navigation'><a rel="next" title="4.1 Syntax" | |
30 | href="latex-syntax.html"><img src='../icons/next.png' | |
31 | border='0' height='32' alt='Next Page' width='32' /></A></td> | |
32 | <td align="center" width="100%">Documenting Python</td> | |
33 | <td class='online-navigation'><a rel="contents" title="Table of Contents" | |
34 | href="contents.html"><img src='../icons/contents.png' | |
35 | border='0' height='32' alt='Contents' width='32' /></A></td> | |
36 | <td class='online-navigation'><img src='../icons/blank.png' | |
37 | border='0' height='32' alt='' width='32' /></td> | |
38 | <td class='online-navigation'><img src='../icons/blank.png' | |
39 | border='0' height='32' alt='' width='32' /></td> | |
40 | </tr></table> | |
41 | <div class='online-navigation'> | |
42 | <b class="navlabel">Previous:</b> | |
43 | <a class="sectref" rel="prev" href="style-guide.html">3 Style Guide</A> | |
44 | <b class="navlabel">Up:</b> | |
45 | <a class="sectref" rel="parent" href="doc.html">Documenting Python</A> | |
46 | <b class="navlabel">Next:</b> | |
47 | <a class="sectref" rel="next" href="latex-syntax.html">4.1 Syntax</A> | |
48 | </div> | |
49 | <hr /></div> | |
50 | </DIV> | |
51 | <!--End of Navigation Panel--> | |
52 | ||
53 | <H1><A NAME="SECTION000500000000000000000"></A><A NAME="latex-primer"></A> | |
54 | <BR> | |
55 | 4 <span class="LaTeX">LaTeX</span> Primer | |
56 | </H1> | |
57 | ||
58 | <P> | |
59 | This section is a brief introduction to <span class="LaTeX">LaTeX</span> concepts and | |
60 | syntax, to provide authors enough information to author documents | |
61 | productively without having to become ``<span class="TeX">TeX</span>nicians.'' This does | |
62 | not teach everything needed to know about writing <span class="LaTeX">LaTeX</span> for | |
63 | Python documentation; many of the standard ``environments'' are not | |
64 | described here (though you will learn how to mark something as an | |
65 | environment). | |
66 | ||
67 | <P> | |
68 | Perhaps the most important concept to keep in mind while marking up | |
69 | Python documentation is that while <span class="TeX">TeX</span> is unstructured, <span class="LaTeX">LaTeX</span> was | |
70 | designed as a layer on top of <span class="TeX">TeX</span> which specifically supports | |
71 | structured markup. The Python-specific markup is intended to extend | |
72 | the structure provided by standard <span class="LaTeX">LaTeX</span> document classes to | |
73 | support additional information specific to Python. | |
74 | ||
75 | <P> | |
76 | <span class="LaTeX">LaTeX</span> documents contain two parts: the preamble and the body. | |
77 | The preamble is used to specify certain metadata about the document | |
78 | itself, such as the title, the list of authors, the date, and the | |
79 | <em>class</em> the document belongs to. Additional information used | |
80 | to control index generation and the use of bibliographic databases | |
81 | can also be placed in the preamble. For most authors, the preamble | |
82 | can be most easily created by copying it from an existing document | |
83 | and modifying a few key pieces of information. | |
84 | ||
85 | <P> | |
86 | The <i class="dfn">class</i> of a document is used to place a document within a | |
87 | broad category of documents and set some fundamental formatting | |
88 | properties. For Python documentation, two classes are used: the | |
89 | <code>manual</code> class and the <code>howto</code> class. These classes also | |
90 | define the additional markup used to document Python concepts and | |
91 | structures. Specific information about these classes is provided in | |
92 | section <A href="classes.html#classes">5</A>, ``Document Classes,'' below. The first thing | |
93 | in the preamble is the declaration of the document's class. | |
94 | ||
95 | <P> | |
96 | After the class declaration, a number of <em>macros</em> are used to | |
97 | provide further information about the document and setup any | |
98 | additional markup that is needed. No output is generated from the | |
99 | preamble; it is an error to include free text in the preamble | |
100 | because it would cause output. | |
101 | ||
102 | <P> | |
103 | The document body follows the preamble. This contains all the | |
104 | printed components of the document marked up structurally. Generic | |
105 | <span class="LaTeX">LaTeX</span> structures include hierarchical sections, numbered and | |
106 | bulleted lists, and special structures for the document abstract and | |
107 | indexes. | |
108 | ||
109 | <P> | |
110 | ||
111 | <p><br /></p><hr class='online-navigation' /> | |
112 | <div class='online-navigation'> | |
113 | <!--Table of Child-Links--> | |
114 | <A NAME="CHILD_LINKS"><STRONG>Subsections</STRONG></a> | |
115 | ||
116 | <UL CLASS="ChildLinks"> | |
117 | <LI><A href="latex-syntax.html">4.1 Syntax</a> | |
118 | <LI><A href="latex-structure.html">4.2 Hierarchical Structure</a> | |
119 | <LI><A href="latex-environments.html">4.3 Common Environments</a> | |
120 | </ul> | |
121 | <!--End of Table of Child-Links--> | |
122 | </div> | |
123 | ||
124 | <DIV CLASS="navigation"> | |
125 | <div class='online-navigation'> | |
126 | <p></p><hr /> | |
127 | <table align="center" width="100%" cellpadding="0" cellspacing="2"> | |
128 | <tr> | |
129 | <td class='online-navigation'><a rel="prev" title="3 Style Guide" | |
130 | href="style-guide.html"><img src='../icons/previous.png' | |
131 | border='0' height='32' alt='Previous Page' width='32' /></A></td> | |
132 | <td class='online-navigation'><a rel="parent" title="Documenting Python" | |
133 | href="doc.html"><img src='../icons/up.png' | |
134 | border='0' height='32' alt='Up One Level' width='32' /></A></td> | |
135 | <td class='online-navigation'><a rel="next" title="4.1 Syntax" | |
136 | href="latex-syntax.html"><img src='../icons/next.png' | |
137 | border='0' height='32' alt='Next Page' width='32' /></A></td> | |
138 | <td align="center" width="100%">Documenting Python</td> | |
139 | <td class='online-navigation'><a rel="contents" title="Table of Contents" | |
140 | href="contents.html"><img src='../icons/contents.png' | |
141 | border='0' height='32' alt='Contents' width='32' /></A></td> | |
142 | <td class='online-navigation'><img src='../icons/blank.png' | |
143 | border='0' height='32' alt='' width='32' /></td> | |
144 | <td class='online-navigation'><img src='../icons/blank.png' | |
145 | border='0' height='32' alt='' width='32' /></td> | |
146 | </tr></table> | |
147 | <div class='online-navigation'> | |
148 | <b class="navlabel">Previous:</b> | |
149 | <a class="sectref" rel="prev" href="style-guide.html">3 Style Guide</A> | |
150 | <b class="navlabel">Up:</b> | |
151 | <a class="sectref" rel="parent" href="doc.html">Documenting Python</A> | |
152 | <b class="navlabel">Next:</b> | |
153 | <a class="sectref" rel="next" href="latex-syntax.html">4.1 Syntax</A> | |
154 | </div> | |
155 | </div> | |
156 | <hr /> | |
157 | <span class="release-info">Release 2.4.2, documentation updated on 28 September 2005.</span> | |
158 | </DIV> | |
159 | <!--End of Navigation Panel--> | |
160 | <ADDRESS> | |
161 | See <i><a href="about.html">About this document...</a></i> for information on suggesting changes. | |
162 | </ADDRESS> | |
163 | </BODY> | |
164 | </HTML> |