Imported Upstream version 1.22.4
[platform/upstream/groff.git] / contrib / mom / momdoc / docprocessing.html
1 <?xml version="1.0" encoding="utf-8"?>
2 <!--
3 This file is part of groff, the GNU roff type-setting system.
4
5 Copyright (C) 2004-2018 Free Software Foundation, Inc.
6 Written by Peter Schaffter (peter@schaffter.ca).
7
8 Permission is granted to copy, distribute and/or modify this document
9 under the terms of the GNU Free Documentation License, Version 1.3 or
10 any later version published by the Free Software Foundation; with no
11 Invariant Sections, with no Front-Cover Texts, and with no Back-Cover
12 Texts.
13
14 A copy of the Free Documentation License is included as a file called
15 FDL in the main directory of the groff source package.
16 -->
17
18 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
19 <html xmlns="http://www.w3.org/1999/xhtml">
20
21 <head>
22   <meta http-equiv="content-type" content="text/html;charset=utf-8"/>
23   <title>Mom -- Document Processing, Introduction and Setup</title>
24   <link rel="stylesheet" type="text/css" href="stylesheet.css" />
25 </head>
26
27 <body style="background-color: #f5faff;">
28
29 <!-- ==================================================================== -->
30
31 <div id="top" class="page">
32
33 <!-- Navigation links -->
34 <table style="width: 100%;">
35 <tr>
36   <td><a href="toc.html">Back to Table of Contents</a></td>
37   <td style="text-align: right;"><a href="docelement.html#top">Next: The document element tags</a></td>
38 </tr>
39 </table>
40
41 <h1 class="docs">Document processing with mom</h1>
42
43 <h2 id="toc-doc-processing" class="docs" style="text-align: center;">Table of contents</h2>
44
45 <div id="docprocessing-mini-toc" style="font-size: 90%; line-height: 150%; margin-top: .5em;">
46 <div class="mini-toc-col-1" style="margin-left: 0;">
47 <h3 class="toc toc-docproc-header" style="margin-top: 1em;"><a class="header-link" href="#docprocessing-intro">Introduction to document processing</a></h3>
48 <h3 class="toc toc-docproc-header" style="margin-top: .5em;"><a class="header-link" href="#defaults">Document defaults</a></h3>
49 <h3 class="toc toc-docproc-header" style="margin-top: .5em;"><a class="header-link" href="#vertical-whitespace-management">Vertical whitespace management</a></h3>
50 <h3 class="toc toc-docproc-header" style="margin-top: .5em;"><a class="header-link" href="#setup">Preliminary document setup</a></h3>
51 <ul class="toc-docproc" style="margin-top: .5em;">
52   <li><a href="#docprocessing-tut"><b>Tutorial &ndash; Setting up a mom document</b></a></li>
53   <li><a href="#reference-macros"><b>The reference macros (metadata)</b></a>
54   <ul class="toc-docproc">
55     <li><a href="#title">TITLE</a></li>
56     <li><a href="#doc-title">DOCTITLE</a></li>
57     <li><a href="#subtitle">SUBTITLE</a></li>
58     <li><a href="#author">AUTHOR</a></li>
59     <li><a href="#chapter">CHAPTER</a></li>
60     <li><a href="#chapter-title">CHAPTER_TITLE</a></li>
61     <li><a href="#draft">DRAFT</a></li>
62     <li><a href="#revision">REVISION</a></li>
63     <li><a href="#copyright">COPYRIGHT</a></li>
64     <li><a href="#misc">MISC</a></li>
65     <li><a href="#covertitle">COVERTITLE</a></li>
66     <li><a href="#doc-covertitle">DOC_COVERTITLE</a></li>
67     <li><a href="#pdftitle">PDF_TITLE</a></li>
68   </ul></li>
69   <li><a href="#docstyle-macros"><b>The docstyle macros (templates)</b></a>
70   <ul class="toc-docproc">
71     <li><a href="#doctype">DOCTYPE (default, chapter, letter, named, slides)</a></li>
72     <li><a href="#slides">DOCTYPE SLIDES</a></li>
73     <ul class="toc-docproc">
74     <li><a href="#newslide">NEWSLIDE</a></li>
75       <li><a href="#pause">PAUSE</a></li>
76       <li><a href="#transition">TRANSITION</a></li>
77     </ul>
78     <li><a href="#printstyle">PRINTSTYLE</a></li>
79     <li><a href="#copystyle">COPYSTYLE</a></li>
80   </ul></li>
81   <li><a href="cover.html"><b>Cover pages</b></a>
82   <li><a href="#docheader"><b>Managing the document header</b></a>
83   <ul class="toc-docproc">
84     <li><a href="#docheader">DOCHEADER</a></li>
85     <li><a href="#docheader-control">Docheader control</a>
86     <ul class="toc-docproc">
87       <li><a href="#docheader-desc">Docheader description</a></li>
88       <li><a href="#index-docheader-control">Macro list</a></li>
89     </ul></li>
90   </ul></li>
91 </ul>
92 <h3 class="toc toc-docproc-header"><a class="header-link" href="#start-macro">Initiate document processing</a></h3>
93 <ul class="toc-docproc" style="margin-top: .5em;">
94   <li><a href="#start"><b>The START macro</b></a></li>
95 </ul>
96 </div>
97 <div class="mini-toc-col-2">
98 <br/>
99 <h3 class="toc toc-docproc-header"><a class="header-link" href="#style-before-start">Establishing type and formatting<br/><span style="display: block; margin-top: -.3em;">parameters before START</span></a></h3>
100 <ul class="toc-docproc" style="margin-top: .5em;">
101   <li><a href="#type-before-start"><b>Behaviour of the typesetting macros before START</b></a>
102   <ul class="toc-docproc">
103     <li><a href="docprocessing.html#include">Including (sourcing) style sheets and files</a></li>
104     <li><a href="#color">Initializing colours</a></li>
105   </ul></li>
106 </ul>
107 <ul class="toc-docproc" style="margin-top: -1em">
108   <li><a href="#doc-lead-adjust"><b>Adjust linespacing to fill pages</b></a>
109   <ul class="toc-docproc">
110     <li><a href="#doc-lead-adjust">DOC_LEAD_ADJUST</a></li>
111     <li><a href="#shim">SHIM</a> &ndash; get document leading back on track
112     <ul class="toc-docproc">
113       <li><a href="#automatic-shimming">Automatic shimming (headings, etc)</a></li>
114     </ul></li>
115   </ul></li>
116   <li><a href="#columns-intro"><b>Setting documents in columns</b></a>
117   <ul class="toc-docproc">
118     <li><a href="#columns">COLUMNS</a></li>
119     <li><a href="#marking-col-start">Marking the first page column start position</a>
120     <ul class="toc-docproc">
121       <li><a href="#col-mark">COL_MARK</a></li>
122     </ul></li>
123     <li><a href="#breaking-columns">Breaking columns manually</a>
124     <ul class="toc-docproc">
125       <li><a href="#col-next">COL_NEXT</a> and <a href="#col-break">COL_BREAK</a></li>
126     </ul></li>
127   </ul></li>
128 </ul>
129 <h3 class="toc toc-docproc-header"><a class="header-link" href="#style-after-start">Changing basic type and formatting<br/><span style="display: block; margin-top: -.3em;">parameters after START</span></a></h3>
130 <ul class="toc-docproc" style="margin-top: .5em;">
131   <li><a href="#behaviour"><b>Behaviour of the typesetting macros during document processing</b></a></li>
132   <li><a href="docprocessing.html#intro-doc-param"><b>Changing document-wide style parameters after START</b></a>
133   <ul class="toc-docproc">
134     <li><a href="docprocessing.html#index-doc-param">Post-START global style change macros</a>
135     <ul class="toc-docproc">
136      <li><a href="#doc-left-margin">DOC_LEFT_MARGIN</a></li>
137      <li><a href="#doc-right-margin">DOC_RIGHT_MARGIN</a></li>
138      <li><a href="#doc-line-length">DOC_LINE_LENGTH</a></li>
139      <li><a href="#doc-family">DOC_FAMILY</a></li>
140      <li><a href="#doc-pt-size">DOC_PT_SIZE</a></li>
141      <li><a href="#doc-lead">DOC_LEAD</a></li>
142      <li><a href="#doc-lead-adjust">DOC_LEAD_ADJUST</a></li>
143      <li><a href="#doc-quad">DOC_QUAD</a></li>
144     </ul></li>
145   </ul></li>
146 </ul>
147 <h3 class="toc toc-docproc-header"><a class="header-link" href="#terminating">Terminating a document</a></h3>
148 </div>
149 </div>
150
151 <div class="rule-short" style="margin-top: -1.75em"><br/><hr/></div>
152
153 <!-- ==================================================================== -->
154
155 <h2 id="docprocessing-intro" class="docs" style="margin-top: 1em">Introduction to document processing</h2>
156
157 <p>
158 Document processing with mom uses markup tags to identify document elements
159 such as headings, paragraphs, blockquotes, and so on.  The tags are, of course,
160 macros, but with sensible, readable names that make them easy
161 to grasp and easy to remember.  (And don&#8217;t forget: if you
162 don&#8217;t like the &#8220;official&#8221; name of a tag &mdash;
163 too long, cumbersome to type in, not &#8220;intuitive&#8221; enough
164 &mdash; you can change it with the
165 <a href="goodies.html#alias">ALIAS</a>
166 macro.)
167 </p>
168
169 <p>
170 In addition to the tags themselves, mom has an extensive array of
171 macros that control how they look and behave.
172 </p>
173
174 <p>
175 Setting up a mom doc is a simple, four-part procedure.  You
176 begin by entering metadata about the document itself (title,
177 subtitle, author, etc.).  Next, you tell mom what kind of document
178 you&#8217;re creating (e.g., chapter, letter, abstract, etc...) and
179 what kind of output you want (typeset, typewritten, draft-style,
180 etc) &mdash; essentially, templates.  Thirdly, you make as many
181 or as few changes to the templates as you wish; in other words,
182 create a style sheet.  Lastly, you invoke the
183 <kbd><a href="#start">START</a></kbd>
184 macro.  Voilà!  You&#8217;re ready to write.
185 </p>
186
187 <!-- ==================================================================== -->
188
189 <h2 id="defaults" class="docs">Document defaults</h2>
190
191 <p>
192 As is to be expected, mom has defaults for everything.  If you want
193 to know a particular default, read about it in the description of
194 the pertinent tag.
195 </p>
196
197 <p>
198 I fear the following may not be adequately covered in the
199 documentation, so just in case:
200 </p>
201 <ul style="margin-top: -.5em; margin-bottom: .5em;">
202   <li>the paper size is 8.5x11 inches</li>
203   <li>the left and right margins are 1-inch</li>
204   <li>the top and bottom margins for document text are plus/minus
205       visually 1-inch
206   </li>
207   <li>pages are numbered; the number appears centred, at the
208       bottom, surrounded by hyphens ( e.g., -6- )
209   </li>
210   <li>the first page of a document begins with a
211       <a href="definitions.html#docheader">document header</a>
212   </li>
213   <li>subsequent pages have
214       <a href="definitions.html#header">page headers</a>
215       with a rule underneath
216   </li>
217 </ul>
218
219 <!-- ==================================================================== -->
220
221 <h2 id="vertical-whitespace-management" class="macro-group">Vertical whitespace management</h2>
222
223 <ul style="margin-left: -.5em;">
224   <li><a href="#shim">Macro: SHIM</a></li>
225   <li><a href="#no-shim">Macro: NO_SHIM</a></li>
226   <li><a href="#flex">Macro: FLEX</a></li>
227   <li><a href="#no-flex">Macro: NO_FLEX</a></li>
228 </ul>
229
230
231 <p>
232 Mom takes evenly-aligned bottom margins in
233 <a href="definitions.html#running">running text</a>
234 very seriously.  Only under a very few, exceptional circumstances
235 will she allow a bottom margin to &#8220;hang&#8221; (ie to fall
236 short).
237 </p>
238
239 <p>
240 Mom offers two modes of operation for ensuring flush bottom margins:
241 shimming and flex-spacing.  Shimming means that mom nudges the
242 next line after a significant break in running text back onto the
243 <a href="definitions.html#baseline-grid">baseline grid</a>
244 (e.g., after the insertion of a graphic).  Flex-spacing means that any
245 vertical whitespace remaining between the end of running text and
246 the bottom margin is distributed equally at logical points on the
247 page.
248 </p>
249
250 <p>
251 Mom uses the
252 <a href="definitions.html#leading">leading</a>
253 of running text (the &#8220;document leading&#8221;) that&#8217;s in effect
254 <i>at the start of running text on each page</i>
255 to establish the grid and space document elements such as heads or
256 blockquotes so that they adhere to it.  (Prior to invoking
257 <a href="#start">START</a>,
258 the document leading is set with the
259 <a href="typesetting.html#macros-typesetting">typesetting macro</a>
260 <a href="typesetting.html#leading">LS</a>,
261 afterwards with the document
262 <a href="definitions.html#controlmacro">control macro</a>
263 <a href="#doc-lead">DOC_LEAD</a>.)
264 </p>
265
266 <p>
267 What this means is that documents whose paragraphs are not separated
268 by whitepace and which do not contain graphics or
269 <a href="definitions.html#pre-processor">pre-processor material</a>
270 will fill the page completely to the bottom margin.
271 However, if your paragraphs are spaced, or if there are any leading
272 changes on a page, or if graphics or pre-processor material are
273 inserted, it&#8217;s very likely the bottom margins will hang
274 unless shimming or flex-spacing is enabled.
275 </p>
276
277 <h3 id="shim-vs-flex" class="docs">Shimming <span style="text-transform: none">vs.</span> flex-spacing</h3>
278
279 <p>
280 <b>Shimming</b> is mom's default mode of operation.  She applies it
281 automatically before headings, around quotes and blockquotes, and
282 beneath
283 <a href="definitions.html#float">floats</a>
284 and
285 <a href="definitions.html#preprocessor">pre-processor material</a>.
286 In addition, the
287 <a href="#shim">SHIM</a>
288 macro can be inserted into a document to make sure that the
289 text following falls on the baseline grid.
290 </p>
291
292 <p>
293 This mode of operation works well in documents whose paragraphs are
294 not spaced.  Deviations from the baseline grid, usually
295 caused by floats or pre-processor material, are corrected
296 immediately.  If the shimming results in slightly unbalanced
297 whitespace around them, it can easily be remedied by passing the
298 <kbd>ADJUST</kbd> argument to the appropriate macro.
299 </p>
300
301 <p>
302 If you do not want mom shimming automatically,
303 <a href="#no-shim">NO_SHIM</a>
304 turns shimming off globally and suppresses the SHIM macro.  If you
305 want to disable shimming only for a particular float or
306 pre-processor, the <kbd>NO_SHIM</kbd> argument may be given to the
307 appropriate macro.
308 </p>
309
310 <p>
311 <b>Flex-spacing</b> kicks in automatically whenever you turn shimming
312 off.  In other words, if you want a document flex-spaced,
313 <kbd>.NO_SHIM</kbd> is how you achieve it.  If, in addition to not
314 shimming, you don&#8217;t want mom flex-spacing either,
315 <a href="#no-flex">NO_FLEX</a>
316 lets you disable it, too.
317 </p>
318
319 <p>
320 Flex-spacing differs from shimming in that mom doesn&#8217;t
321 correct deviations from the baseline grid.  Rather, she distributes
322 whitespace left at the bottom of the page equally in appropriate
323 places.  Like shimming, flex-spacing is automatically applied
324 before heads, after floats and pre-processor material, and around
325 quotes and blockquotes.  Like shimming, flex-spacing can be
326 disabled for individual floats or pre-processor material with the
327 <kbd>NO_FLEX</kbd> flag.
328 </p>
329
330 <p>
331 In addition, you can use the
332 <a href="#flex">FLEX</a>
333 macro to insert flex-spacing yourself into the document, which you
334 will almost certainly want to do if your paragraphs are spaced.
335 This is because paragraphs are not flex-spaced.  Typographically,
336 the ideal for spaced paragraphs is that the space between them
337 remain constant.  Paradoxically, the only way to achieve flush
338 bottom margins, or to correct excessive flex-spacing before a
339 heading, is by adding flex-space between paragraphs.  This requires
340 human judgment, and mom does not presume to decide for you.
341 </p>
342
343 <p>
344 Shimming and flex-spacing are mutually exclusive.  If the one is
345 active, the other isn&#8217;t unless you have disabled both.  This means
346 that you cannot use the FLEX macro when shimming is enabled, or the
347 SHIM macro when flex-spacing is enabled.  Mom will issue a warning
348 if you do.
349 </p>
350
351 <p>
352 The choice of whether to use shimming or flex-spacing depends on
353 whether or not your paragraphs are spaced.  In a document with
354 indented, non-spaced paragraphs, shimming and flex-spacing produce
355 nearly the same result, with shimming winning by an aesthetic hair.
356 In documents with spaced paragraphs, flex-spacing is the only way to
357 achieve flush bottom margins.
358 </p>
359
360 <!-- -SHIM- -->
361
362 <div class="macro-id-overline">
363 <h3 id="shim" class="macro-id">SHIM</h3>
364 </div>
365
366 <div class="box-macro-args">
367 Macro: <b>SHIM</b>
368 </div>
369
370 <p>
371 When shimming is enabled, which it is by default, the SHIM macro
372 allows you to nudge the line following it back onto the baseline
373 grid.  In documents with non-spaced paragraphs, this prevents
374 the bottom margins from hanging.
375 </p>
376
377 <p style="margin-bottom: -1em">
378 Mom herself automatically applies shimming
379 </p>
380 <ul>
381   <li><i>before</i> headings</li>
382   <li><i>around</i> quotes and blockquotes</li>
383   <li><i>after</i> PDF images, tables, pic diagrams, equations, and floats</li>
384 </ul>
385
386 <p>
387 You may sometimes find the amount of space generated by
388 <kbd>SHIM</kbd> looks too big, whether inserted manually into a
389 document or as a result of automatic shimming.
390 The situation occurs when the amount of shimming applied
391 comes close to the leading currently in effect, making it seem as if
392 there&#8217;s one linespace too much whitespace.
393 </p>
394
395 <p>
396 The solution is simply to add <kbd>.SPACE&nbsp;-1v</kbd> or
397 <kbd>.RLD&nbsp;1v</kbd> to the document immediately after
398 <kbd>.SHIM</kbd>.  (Both <kbd>.SPACE&nbsp;-1v</kbd> and
399 <kbd>.RLD&nbsp;1v</kbd> back up by one linespace.)
400 </p>
401
402 <div class="macro-id-overline">
403 <h3 id="no-shim" class="macro-id">NO_SHIM</h3>
404 </div>
405
406 <div class="box-macro-args">
407 Macro: <b>NO_SHIM</b> <kbd class="macro-args">&lt;none&gt; | &lt;anything&gt;
408 </div>
409
410 <p>
411 NO_SHIM, without an argument, disables automatic shimming,
412 suppresses the SHIM macro, and enables flex-spacing.
413 </p>
414
415 <p>
416 NO_SHIM with any argument (e.g., <b>OFF, QUIT, END, X</b>, etc)
417 re-enables shimming if it has been disabled and disables
418 flex-spacing.
419 </p>
420
421 <!-- -FLEX- -->
422
423 <div class="macro-id-overline">
424 <h3 id="flex" class="macro-id">FLEX</h3>
425 </div>
426
427 <div class="box-macro-args">
428 Macro: <b>FLEX</b> <kbd class="macro-args">[ FORCE ]</kbd>
429 </div>
430
431 <p>
432 When flex-spacing is enabled, the FLEX macro inserts flexible
433 vertical whitespace into a document.  The amount of flex-space is
434 determined from any extra whitespace at the bottom of a page divided
435 by the number of flex points on the same page.
436 </p>
437
438 <p style="margin-bottom: -1em">
439 If flex-spacing is enabled, mom herself automatically applies
440 flex-spacing
441 </p>
442 <ul style="margin-bottom: -.5em">
443   <li><i>before</i> headings</li>
444   <li><i>around</i> quotes and blockquotes</li>
445   <li><i>after</i> PDF images, tables, pic diagrams, equations, and floats</li>
446 </ul>
447
448 <p>
449 Near the bottom of some pages, you may find that
450 <a href="definitions.html#float">floated</a>
451 or
452 <a href="definitions.html#preprocessor">pre-proccesor material</a>,
453 including images, or a single line of text afterward, is not flush
454 with the bottom margin.  This is a result of mom flex-spacing
455 <i>after</i> such material but not before.  The solution to is
456 insert <kbd>.FLEX</kbd> immediately beforehand.
457 </p>
458
459 <p>
460 There are some instances where mom inhibits flex-spacing, notably
461 after outputting deferred floats and pre-processor material.
462 Introducing FLEX by itself in these instances&mdash;say, before a head
463 or paragraph&mdash;will not have any effect; you must pass FLEX the
464 <kbd>FORCE</kbd> argument.
465 </p>
466
467 <div class="box-tip">
468 <p class="tip">
469 <span class="important">Important note on flex-spacing policy:</span><br/>
470 Mom disables flex-spacing on
471 </p>
472 <ul style="margin-top: -1em; margin-bottom: -.5em">
473   <li>the last page or column of a document, before the Table of Contents,
474       Endnotes, Bibliography, and/or any &#8220;Lists of...&#8221;
475   </li>
476   <li>the page preceding a
477       <a href="rectoverso.html#collate">COLLATE</a>
478   </li>
479   <li>the page preceding a
480       <a href="typesetting.html#NEWPAGE">NEWPAGE</a>
481       or
482       <a href="headfootpage.html#blankpage">BLANKPAGE</a>
483   </li>
484   <li>the column preceding a
485       <a href="#col-next">COL_NEXT</a>
486       or
487       <a href="#col-break">COL_BREAK</a>
488   </li>
489 </ul>
490
491 <p>
492 If this is not what you want, insert
493 <a href="#no-flex"><kbd>.NO_FLEX&nbsp;OFF</kbd></a>
494 before the first flex-space point on the affected page or in the
495 affected column.
496 </p>
497
498 <p>
499 Flex-spacing is also disabled for any page or column where
500 insufficient room at or near the bottom causes a
501 <a href="docelement.html#heading">HEADING</a>
502 or
503 <a href="images.html#tbl">table</a>
504 to be moved to the top of the next page.  These situations cannot
505 be harmonized with flex-spacing except by adjusting your layout
506 to prevent them.  You may try re-enabling flex-spacing for the
507 page (<kbd>.NO_FLEX&nbsp;OFF</kbd>) and manually inserting
508 flex-spaces at appropriate points, but the original whitespace is
509 usually large enough that re-distributing it merely changes
510 one layout gaffe into another.
511 </p>
512
513 <p>
514 Very occasionally you may notice that a document element (spaced
515 paragraph, floated material, pre-processor material, or a PDF image)
516 near the bottom of page has also caused mom to disable flex-spacing
517 for that page.  This occurs when the document element following it
518 is a
519 <a href="docelement.html#pp-space">spaced paragraph</a>.
520 </p>
521
522 <p>
523 It is typographically acceptable for there to be space between
524 insertions in running text (e.g., an image) and the bottom margin when
525 the next page begins with a paragraph.  If you&#8217;d like to
526 nudge the insertion a little closer to the bottom margin&mdash;not
527 all the way; that isn&#8217;t possible without pushing it to the
528 next page and disrupting subsequent flex-spacing&mdash;insert a
529 small amount of space beforehand with
530 <a href="typesetting.html#sp">SP</a>.
531 Do not, in these cases, use the <kbd>ADJUST</kbd>
532 argument (for example to
533 <a href="images.html#pdf-image">PDF_IMAGE</a>.)
534 </p>
535
536 <p class="tip-bottom">
537 In the case of a spaced paragraph itself near the bottom of the page
538 causing a break, re-enabling flex-spacing
539 (<kbd>.NO_FLEX&nbsp;OFF</kbd>) at an appropriate place in your input
540 file will resolve the issue, provided there is at least one
541 flex-point on the page.  If not, add one or more.
542 </p>
543 </div>
544
545 <div class="macro-id-overline">
546 <h3 id="no-flex" class="macro-id">NO_FLEX</h3>
547 </div>
548
549 <div class="box-macro-args">
550 Macro: <b>NO_FLEX</b> <kbd class="macro-args">&lt;none&gt; | &lt;anything&gt;</kbd>
551 </div>
552
553 <p>
554 NO_FLEX, without an argument, disables automatic flex-spacing
555 and suppresses the FLEX macro.  If, in addition to NO_FLEX, NO_SHIM
556 has also been given, your document will be neither flex-spaced nor
557 shimmed.
558 </p>
559
560 <p>
561 NO_FLEX with any argument (e.g., <b>OFF, QUIT, END, X</b>, etc)
562 re-enables flex-spacing if it has been disabled.
563 </p>
564
565 <div class="rule-short"><hr/></div>
566
567 <!-- ==================================================================== -->
568
569 <h2 id="setup" class="docs" style="margin-bottom: .5em;">Preliminary document setup</h2>
570
571 <div class="examples-container" style="margin-bottom: 1.5em;">
572 <h3 id="docprocessing-tut" class="docs">Tutorial &ndash; Setting up a mom document</h3>
573
574 <p style="margin-top: 1em;">
575 There are four parts to setting up a mom doc (three, actually,
576 with one optional).  Before we proceed, though, be reassured that
577 something as simple as
578 <br/>
579 <span class="pre-in-pp">
580   .TITLE     "By the Shores of Lake Attica"
581   .AUTHOR    "Rosemary Winspeare"
582   .PRINTSTYLE TYPESET
583   .START
584 </span>
585 produces a beautifully typeset 8.5x11 document, with a
586 <a href="definitions.html#docheader">docheader</a>
587 at the top of page 1,
588 <a href="definitions.html#header">page headers</a>
589 with the title and author on subsequent pages, and page numbers at
590 the bottom of each page.  In the course of the document, headings,
591 citations, quotes, epigraphs, and so on, all come out looking neat,
592 trim, and professional.
593 </p>
594
595 <p>
596 For the purposes of this tutorial, we&#8217;re going to set up
597 a short story&mdash;<i>My Pulitzer Winner</i>&mdash;by Joe Blow.
598 Thankfully, we don&#8217;t have to look at story itself, just the
599 setup.  Joe wants the document
600 </p>
601 <ul style="margin-top: -.5em; margin-bottom: -.5em;">
602   <li>to be draft 7, revision 39;</li>
603   <li>to use the DEFAULT template;</li>
604   <li>to print as draft-style output (instead of final-copy output);</li>
605   <li>to be typeset, in Helvetica, 12 on 14,
606       <a href="definitions.html#rag">rag-right</a>;
607   </li>
608   <li>to have <a href="definitions.html#footer">footers</a>
609       instead of
610       <a href="definitions.html#header">headers</a>;
611   </li>
612   <li>to use a single asterisk for
613       <a href="definitions.html#linebreak">author linebreaks</a>.
614   </li>
615 </ul>
616
617 <p>
618 Joe Blow has no taste in typography.  His draft won&#8217;t look
619 pretty, but this is, after all, a tutorial; we&#8217;re after
620 examples, not beauty.
621 </p>
622
623 <h4 class="docs" style="margin-top: -.5em;">Step 1</h4>
624
625 <p style="margin-bottom: -.5em;">
626 The first step in setting up any document is giving mom some
627 reference information (metadata).  The reference macros are:
628 </p>
629 <div style="width: 50%; float: left;">
630 <ul>
631   <li>TITLE</li>
632   <li>SUBTITLE</li>
633   <li>AUTHOR</li>
634   <li>CHAPTER &ndash; chapter number</li>
635   <li>CHAPTER_TITLE &ndash; chapter name</li>
636   <li>DRAFT &ndash; the draft number</li>
637   <li>REVISION &ndash; the revision number</li>
638 </ul>
639 </div>
640 <div>
641 <ul>
642   <li>COPYRIGHT &ndash; only used on cover pages</li>
643   <li>MISC &ndash; only used on cover pages</li>
644   <li>DOCTITLE</li>
645   <li>COVERTITLE</li>
646   <li>DOC_COVERTITLE</li>
647   <li>PDF_TITLE</li>
648 </ul>
649 </div>
650
651 <p style="margin-top: -.5em; clear: both;">
652 You can use as many or as few as you wish, although at a minimum,
653 you&#8217;ll probably fill in TITLE (unless the document&#8217;s a
654 letter) and AUTHOR.  Order doesn&#8217;t matter.  You can separate
655 the
656 <a href="definitions.html#arguments">arguments</a>
657 from the macros by any number of spaces.  The following are what
658 you&#8217;d need to start Joe Blow&#8217;s story.
659 <br/>
660 <span class="pre-in-pp">
661   .TITLE    "My Pulitzer Winner"
662   .AUTHOR   "Joe Blow"
663   .DRAFT     7
664   .REVISION  39
665 </span>
666 </p>
667
668 <h4 class="docs" style="margin-top: -1.5em;">Step 2</h4>
669
670 <p>
671 Once you&#8217;ve given mom the reference information she needs, you
672 tell her how you want your document formatted.  What kind of
673 document is it?  Should it be typeset or typewritten?  Is this a
674 final copy (for the world to see) or just a draft?  Mom calls
675 the macros that answer these questions &#8220;the docstyle
676 macros&#8221;, and they're essentially templates.
677 </p>
678 <ul style="margin-top: -.5em; margin-bottom: -.5em;">
679   <li>PRINTSTYLE&mdash;typeset or typewritten</li>
680   <li>DOCTYPE&mdash;the type of document (default, chapter, user-defined, letter)</li>
681   <li>COPYSTYLE &mdash;draft or final copy</li>
682 </ul>
683
684 <p>
685 Mom has defaults for DOCTYPE and COPYSTYLE; if they&#8217;re what
686 you want, you don&#8217;t need to include them.  However,
687 PRINTSTYLE has no default and must be present in every formatted
688 document.  If you omit it, mom won&#8217;t process the document
689 AND she&#8217;ll complain (both to stderr and as a single printed
690 sheet with a warning).  Moms&mdash;they can be so annoying
691 sometimes. &lt;sigh&gt;
692 </p>
693
694 <p>
695 Adding to what we already have, the next bit of setup for Joe
696 Blow&#8217;s story looks like this:
697 <br/>
698 <span class="pre-in-pp">
699     .TITLE    "My Pulitzer Winner"
700     .AUTHOR   "Joe Blow"
701     .DRAFT     7
702     .REVISION  39
703     \#
704     .DOCTYPE     DEFAULT \"Superfluous; mom uses DOCTYPE DEFAULT by default
705     .PRINTSTYLE  TYPESET
706     .COPYSTYLE   DRAFT
707 </span>
708 Notice the use of the
709 <a href="definitions.html#commentlines">comment line</a>
710 ( <kbd>\#</kbd> ), a handy way to keep groups of macros visually
711 separated for easy reading in a text editor.
712 </p>
713
714 <h4 class="docs" style="margin-top: -.5em; margin-bottom: -.5em;">Step 3</h4>
715
716 <p>
717 This step&mdash;completely optional&mdash;is where you, the user,
718 take charge.  Mom has reasonable defaults for every document element
719 and tag, but who&#8217;s ever satisfied with defaults?  Use any of
720 the
721 <a href="typesetting.html#macros-typesetting">typesetting macros</a>
722 here to change mom&#8217;s document defaults (paper size, margins,
723 family, point size, line space, rag, etc), or any of the document
724 processing
725 <a href="definitions.html#controlmacro">control macros</a>.
726 This is the style-sheet section of a document, and
727 must come after the
728 <a href="#printstyle">PRINTSTYLE</a>
729 directive.  Failure to observe this condition will result in
730 PRINTSTYLE overriding your changes.
731 </p>
732
733 <p>
734 Joe Blow wants his story printed in Helvetica, 12 on 14, rag right,
735 with
736 <a href="definitions.html#footer">page footers</a>
737 instead of
738 <a href="definitions.html#header">page headers</a>
739 and a single asterisk for the
740 <a href="definitions.html#linebreak">linebreak</a>
741 character.  None of these requirements conforms to mom&#8217;s
742 defaults for the chosen PRINTSTYLE (TYPESET), so we change them
743 here.  The setup for Joe Blow&#8217;s story now looks like this:
744 <br/>
745 <span class="pre-in-pp">
746   .TITLE    "My Pulitzer Winner"
747   .AUTHOR   "Joe Blow"
748   .DRAFT     7
749   .REVISION  39
750   \#
751   .DOCTYPE     DEFAULT
752   .PRINTSTYLE  TYPESET
753   .COPYSTYLE   DRAFT
754   \#
755   .FAMILY  H
756   .PT_SIZE 12
757   .LS      14
758   .QUAD    LEFT    \"ie rag right
759   .FOOTERS
760   .LINEBREAK_CHAR *
761 </span>
762 </p>
763
764 <h4 class="docs" style="margin-top: -1.5em; margin-bottom: -.5em;">Step 4</h4>
765
766 <p>
767 The final step in setting up a document is telling mom to start
768 document processing.  It&#8217;s a no-brainer, just the single
769 macro START.  Other than PRINTSTYLE, it&#8217;s the only macro
770 required for document processing.
771 </p>
772
773 <p>
774 Here&#8217;s the complete setup for <i>My Pulitzer Winner</i>:
775 <br/>
776 <span class="pre-in-pp">
777   .TITLE    "My Pulitzer Winner"
778   .AUTHOR   "Joe Blow"
779   .DRAFT     7
780   .REVISION  39
781   \#
782   .DOCTYPE     DEFAULT
783   .PRINTSTYLE  TYPESET
784   .COPYSTYLE   DRAFT
785   \#
786   .FAMILY   H
787   .PT_SIZE  12
788   .LS       14
789   .QUAD     LEFT    \"ie rag right
790   .FOOTERS
791   .LINEBREAK_CHAR *
792   \#
793   .START
794 </span>
795 As pointed out earlier, Joe Blow is no typographer.  Given that all he
796 needs is a printed draft of his work, a simpler setup would have been:
797 <br/>
798 <span class="pre-in-pp">
799   .TITLE    "My Pulitzer Winner"
800   .AUTHOR   "Joe Blow"
801   .DRAFT     7
802   .REVISION  39
803   \#
804   .PRINTSTYLE  TYPEWRITE
805   .COPYSTYLE   DRAFT
806   \#
807   .START
808 </span>
809 <kbd>.PRINTSTYLE&nbsp;TYPEWRITE</kbd>, above, means that Joe&#8217;s
810 work will come out &#8220;typewritten, double-spaced&#8221;,
811 making the blue-pencilling he (or someone else) is sure to do much
812 easier (which is why many publishers and agents still insist on
813 typewritten, double-spaced copy).
814 </p>
815
816 <p>
817 When J. Blow stops re-writing and decides to print off a final,
818 typeset copy of his work for the world to see, he need only make two
819 changes to the (simplified) setup:
820 <br/>
821 <span class="pre-in-pp">
822   .TITLE    "My Pulitzer Winner"
823   .AUTHOR   "Joe Blow"
824   .DRAFT     7
825   .REVISION  39
826   \#
827   .PRINTSTYLE  TYPESET  \"first change
828   .COPYSTYLE   FINAL    \"second change
829   \#
830   .START
831 </span>
832 In the above, <kbd>.DRAFT&nbsp;7,&nbsp;.REVISION 39,</kbd> and
833 <kbd>.COPYSTYLE FINAL</kbd> are actually superfluous.  The draft
834 and revision numbers aren&#8217;t used when COPYSTYLE is FINAL,
835 and <b>COPYSTYLE FINAL</b> is mom&#8217;s default unless you tell
836 her otherwise.
837 </p>
838
839 <p>
840 But... to judge from the number of drafts already,
841 J. Blow may very well decide his &#8220;final&#8221; version still
842 isn&#8217;t up to snuff.  Hence, he might as well leave in the
843 superfluous macros.  That way, when draft 7, rev. 62 becomes draft
844 8, rev. 1, he&#8217;ll be ready to tackle his Pulitzer winner again.
845 </p>
846 </div>
847
848 <div class="rule-short"><hr/></div>
849
850 <!-- ======================================================================== -->
851
852 <h2 id="reference-macros" class="macro-group">The reference macros (metadata)</h2>
853
854 <p>
855 The reference macros give mom the metadata she needs to generate
856 <a href="definitions.html#docheader">docheaders</a>,
857 <a href="definitions.html#header">page headers</a>,
858 and
859 <a href="cover.html#cover-top">covers</a>.
860 They must go at the top of any file that uses mom&#8217;s document
861 processing macros.
862 </p>
863
864 <div class="macro-list-container">
865 <h3 id="index-reference" class="macro-list">Reference macros</h3>
866
867 <ul class="macro-list">
868   <li><a href="#title">TITLE</a> &ndash; title of a story, article, etc</li>
869   <li><a href="#doc-title">DOCTITLE</a> &ndash; title of a book, or any collated document</li>
870   <li><a href="#subtitle">SUBTITLE</a></li>
871   <li><a href="#author">AUTHOR</a></li>
872   <li><a href="#chapter">CHAPTER</a> &ndash; the chapter number
873   <ul>
874     <li class="sublist"><a href="#chapter-string">CHAPTER_STRING</a> &ndash; &#8220;Chapter&#8221;, &#8220;CHAPTER&#8221;, &#8220;Chapître&#8221;, etc</li>
875   </ul></li>
876   <li><a href="#chapter-title">CHAPTER_TITLE</a></li>
877   <li><a href="#draft">DRAFT</a>
878   <ul>
879     <li class="sublist"><a href="#draft-string">DRAFT_STRING</a> &ndash; &#8220;Draft&#8221;, &#8220;DRAFT&#8221;, &#8220;Jet&#8221;, etc</li>
880   </ul></li>
881   <li><a href="#revision">REVISION</a>
882   <ul>
883     <li class="sublist"><a href="#revision-string">REVISION_STRING</a> &ndash; &#8220;Revision&#8221;, &#8220;Rev.&#8221;, &#8220;Révision&#8221;, etc</li>
884   </ul></li>
885   <li><a href="#copyright">COPYRIGHT</a></li>
886   <li><a href="#misc">MISC</a></li>
887   <li><a href="#covertitle">COVERTITLE</a> &ndash; frontispiece, title page, etc</li>
888   <li><a href="#doc-covertitle">DOC_COVERTITLE</a> &ndash; book cover, collated document cover, etc</li>
889   <li><a href="#pdftitle">PDF_TITLE</a> &ndash; window title for PDF viewers</li>
890 </ul>
891 </div>
892
893 <!-- -TITLE- -->
894
895 <div class="macro-id-overline">
896 <h3 id="title" class="macro-id">TITLE</h3>
897 </div>
898
899 <div class="box-macro-args">
900 Macro: <b>TITLE</b> <kbd>&quot;&lt;title string&gt;&quot; [&quot;&lt;2nd line&gt;&quot; [&quot;&lt;3rd line&gt;&quot; ... ] ]</kbd> 
901 </div>
902 <p class="requires">
903 &bull;&nbsp;Arguments must be enclosed in double-quotes
904 </p>
905
906 <p>
907 The title string can be caps or caps/lower-case; it&#8217;s up to you.  In
908 <a href="#printstyle">PRINTSTYLE TYPESET</a>,
909 the title will appear in the
910 <a href="definitions.html#docheader">docheader</a>
911 exactly as you typed it.  However, mom converts the title to all
912 caps in
913 <a href="definitions.html#header">page headers</a>
914 unless you turn that feature off (see
915 <a href="headfootpage.html#_caps">HEADER_&lt;POSITION&gt;_CAPS</a>).
916 In
917 <a href="#printstyle">PRINTSTYLE TYPEWRITE</a>,
918 the title always gets converted to caps.
919 </p>
920
921 <p>
922 TITLE accepts multiple arguments, each surrounded by double-quotes.
923 Each argument is printed on a separate line, permitting you to
924 create multi-line titles in your docheaders.
925 </p>
926
927 <div class="box-tip">
928 <p class="tip">
929 <span class="note">Note:</span>
930 If your <kbd><a href="#doctype">DOCTYPE</a></kbd> is CHAPTER, TITLE
931 should be the title of the opus, not &#8220;CHAPTER whatever&#8221;.
932 </p>
933 </div>
934
935 <!-- -DOCTITLE- -->
936
937 <div class="macro-id-overline">
938 <h3 id="doc-title" class="macro-id">DOCUMENT TITLE</h3>
939 </div>
940
941 <div class="box-macro-args">
942 Macro: <b>DOCTITLE</b> <kbd class="macro-args">&quot;&lt;overall document title&gt;&quot; [&quot;&lt;2nd line&gt;&quot; [&quot;&lt;3rd line&gt;&quot; ... ] ]</kbd> 
943 </div>
944 <p class="requires">
945 &bull;&nbsp;Arguments must be enclosed in double-quotes
946 </p>
947
948 <div class="box-tip">
949 <p class="tip">
950 <span class="note">Note:</span>
951 This macro should be used only if your <a
952 href="#doctype">DOCTYPE</a> is <kbd>DEFAULT</kbd> (which is
953 mom&#8217;s default).  If your DOCTYPE is CHAPTER, use
954 <a href="#title">TITLE</a>
955 to set the overall document title for cover pages, document cover
956 pages, and page headers or footers.
957 </p>
958 </div>
959
960 <p style="margin-top: -.5em;">
961 When you&#8217;re creating a single document, say, an essay or a
962 short story, you have no need of this macro.
963 <a href="#title">TITLE</a>
964 takes care of all your title needs.
965 </p>
966
967 <p>
968 However if you&#8217;re 
969 <a href="rectoverso.html#collate">collating</a>
970 a bunch of documents together, say, to print out a report containing
971 many articles with different titles, or a book of short stories with
972 different authors, you need DOCTITLE.
973 </p>
974
975 <p>
976 DOCTITLE tells mom the title of the complete document (as opposed to
977 the title of each article or entitled section), and appears
978 </p>
979
980 <ol style="list-style-type: lower-alpha">
981   <li>as the window title in PDF viewers (e.g., Okular or Evince)</li>
982   <li>in the initial rightmost position of page headers in the document</li>
983 </ol>
984
985 <p>
986 Moreover, DOCTITLE does not appear in the
987 <a href="definitions.html#pdfoutline">PDF outline</a>,
988 as its presence in window title would make it redundant.
989 </p>
990
991 <p>
992 The doctitle string can be caps or caps/lower-case; it&#8217;s up to
993 you.  In
994 <a href="#printstyle">PRINTSTYLE TYPESET</a>,
995 by default, the doctitle in
996 <a href="definitions.html#header">page headers</a>
997 is all in caps, unless you turn that feature off (see
998 <a href="headfootpage.html#_caps">HEADER_&lt;POSITION&gt;_CAPS</a>).
999 In
1000 <a href="#printstyle">PRINTSTYLE TYPEWRITE</a>,
1001 the doctitle always gets converted to caps.
1002 </p>
1003
1004 <p>
1005 DOCTITLE accepts multiple arguments, each surrounded
1006 by double-quotes.  Each argument is printed on a separate line,
1007 permitting you to create multi-line document titles for use on
1008 <a href="cover.html#cover">Covers</a>
1009 and/or
1010 <a href="cover.html#doc-cover">Doc covers</a>.
1011 </p>
1012
1013 <div class="box-tip">
1014 <p class="tip">
1015 <span class="note">Note:</span>
1016 If your
1017 <a href="#doctype">DOCTYPE</a>
1018 is CHAPTER, you don&#8217;t need DOCTITLE.  TITLE takes care of
1019 everything.
1020 </p>
1021 </div>
1022
1023 <!-- -SUBTITLE- -->
1024
1025 <div class="macro-id-overline">
1026 <h3 id="subtitle" class="macro-id">SUBTITLE</h3>
1027 </div>
1028
1029 <div class="box-macro-args">
1030 Macro: <b>SUBTITLE</b> <kbd class="macro-args">[COVER | DOC_COVER] &quot;&lt;subtitle&gt;&quot; [&quot;&lt;2nd line&gt;&quot; [&quot;&lt;3rd line&gt;&quot; ... ] ]</kbd> 
1031 </div>
1032 <p class="requires">
1033 &bull;&nbsp;String arguments must be enclosed in double-quotes
1034 </p>
1035
1036 <p>
1037 The subtitle string can be caps or caps/lower-case.  I recommend
1038 caps/lower case.
1039 </p>
1040
1041 <p>
1042 SUBTITLE accepts multiple arguments, each surrounded
1043 by double-quotes.  Each argument is printed on a separate line,
1044 permitting you to create multi-line subtitles.
1045 </p>
1046
1047 <p>
1048 If the optional argument, <kbd>COVER</kbd> or <kbd>DOC_COVER</kbd>,
1049 is given to SUBTITLE, the remaining string
1050 arguments represent the subtitle that will appear on cover or
1051 document cover pages (see the
1052 <a href="cover.html#cover-intro">Introduction to cover pages</a>
1053 for a description of the difference between &#8220;document
1054 covers&#8221; and &#8220;covers&#8221;).  Thus, it is possible to have
1055 differing subtitles appear on the document cover, the cover
1056 (&#8220;title&#8221;) page, and in the document header.  An extreme
1057 example would be:
1058 <br/>
1059 <span class="pre-in-pp">
1060   .SUBTITLE "The Docheader Subtitle"
1061   .SUBTITLE DOC_COVER "The Document Cover Subtitle"
1062   .SUBTITLE COVER "The Cover Subtitle"
1063 </span>
1064 The first invocation of <kbd>.SUBTITLE</kbd> establishes the
1065 subtitle that appears in the docheader at the top of the first page
1066 of a document.  The second invocation establishes the subtitle that
1067 appears on the document cover; the third establishes the subtitle
1068 that appears on the cover (&#8220;title&#8221;) page.
1069 </p>
1070
1071 <p>
1072 If you don&#8217;t require differing subtitles for doc cover and cover
1073 pages, <kbd>.SUBTITLE</kbd>, without the optional first argument, is
1074 sufficient, provided you give the word, <kbd>SUBTITLE</kbd>, as an
1075 argument to the macro
1076 <a href="cover.html#doc-cover">DOC_COVER</a>
1077 or
1078 <a href="cover.html#cover">COVER</a>
1079 </p>
1080
1081 <!-- -AUTHOR- -->
1082
1083 <div class="macro-id-overline">
1084 <h3 id="author" class="macro-id">AUTHOR</h3>
1085 </div>
1086
1087 <div class="box-macro-args">
1088 Macro: <b>AUTHOR</b> <kbd class="macro-args">[COVER | DOC_COVER] &quot;&lt;author&gt;&quot; [ &quot;&lt;author2&gt;&quot; [&quot;&lt;author3&gt;&quot; ... ] ]</kbd>
1089 </div>
1090
1091 <p class="alias" style="margin-bottom: 0;">
1092 <i>Alias:</i> <b>EDITOR</b>
1093 </p>
1094 <p class="requires">
1095 &bull;&nbsp;String arguments must be enclosed in double-quotes
1096 </p>
1097
1098 <p>
1099 Each author string can hold as many names as you like, e.g.,
1100 <br/>
1101 <span class="pre-in-pp" style="margin-bottom: -1em;">
1102   .AUTHOR "Joe Blow"
1103 </span>
1104 or
1105 <br/>
1106 <span class="pre-in-pp" style="margin-top: -.5em;">
1107   .AUTHOR "Joe Blow, Jane Doe" "John Hancock"
1108 </span>
1109 Mom prints each string that&#8217;s enclosed in double-quotes on a
1110 separate line in the
1111 <a href="definitions.html#docheader">docheader</a>,
1112 however only the first string appears in
1113 <a href="definitions.html#header">page headers</a>.
1114 If you want mom to put something else in the author part of page
1115 headers (say, just the last names of a document&#8217;s two
1116 authors), redefine the appropriate part of the header (see
1117 <a href="headfootpage.html#header-control">header/footer control</a>).
1118 </p>
1119
1120 <p>
1121 The strings can be caps or caps/lower-case.  I recommend caps/lower
1122 case.
1123 </p>
1124
1125 <p>
1126 If the optional argument, <kbd>COVER</kbd> or <kbd>DOC_COVER</kbd>,
1127 is given to AUTHOR, the remaining string arguments represent the
1128 author(s) that will appear on cover or document cover pages (see the
1129 <a href="cover.html#cover-intro">Introduction to cover pages</a>
1130 for a description of the difference between &#8220;document
1131 covers&#8221; and &#8220;covers&#8221;).  Thus, it is possible
1132 to have differing authors on the document cover, the cover
1133 (&#8220;title&#8221;) page, in the document first-page header and
1134 subsequent page headers/footers.  An example might be:
1135 <br/>
1136 <span class="pre-in-pp">
1137   .AUTHOR "Joe Blow"
1138   .EDITOR DOC_COVER "John Smith" "and" "Jane Doe"  \" EDITOR is an alias for AUTHOR
1139   .AUTHOR COVER "Joe Blow" "(assisted by Jane Doe)"
1140 </span>
1141 The first invocation of <kbd>.AUTHOR</kbd> establishes the author
1142 that appears in the docheader at the top of the first page of
1143 a document and in subsequent page headers/footers.  The second
1144 invocation establishes the authors (editors, in this instance) that
1145 appear on the document cover; the third establishes the author(s)
1146 that appear(s) on the cover (&#8220;title&#8221;) page.
1147 </p>
1148
1149 <p>
1150 If you don&#8217;t require differing authors for doc cover and cover
1151 pages, <kbd>.AUTHOR</kbd>, without the optional first argument, is
1152 sufficient, provided you give the word, <kbd>AUTHOR</kbd> as an
1153 argument to the macro
1154 <a href="cover.html#doc-cover">DOC_COVER</a>
1155 or
1156 <a href="cover.html#cover">COVER</a>
1157 </p>
1158
1159 <!-- -CHAPTER- -->
1160
1161 <div class="macro-id-overline">
1162 <h3 id="chapter" class="macro-id">CHAPTER</h3>
1163 </div>
1164
1165 <div class="box-macro-args">
1166 Macro: <b>CHAPTER</b> <kbd class="macro-args">&lt;chapter number&gt;</kbd>
1167 </div>
1168
1169 <p>
1170 The chapter number can be in any form you like&mdash;a digit, a roman
1171 numeral, a word.  If you choose
1172 <a href="#doctype">DOCTYPE CHAPTER</a>,
1173 mom prints whatever argument you pass CHAPTER beside the word,
1174 &#8220;Chapter&#8221;, as a single line
1175 <a href="definitions.html#docheader">docheader</a>.
1176 She also puts the same thing in the middle of
1177 <a href="definitions.html#header">page headers</a>.
1178 </p>
1179
1180 <p>
1181 Please note that if your argument to CHAPTER runs to more than one
1182 word, you must enclose the argument in double-quotes.
1183 </p>
1184
1185 <p>
1186 If you&#8217;re not using DOCTYPE CHAPTER, the macro can
1187 be used to identify any document as a chapter <i>for the purpose of
1188 prepending a chapter number to numbered head elements</i>, provided
1189 you pass it a
1190 <a href="definitions.html#numericargument">numeric argument</a>.
1191 See
1192 <a href="docelement.html#prefix-chapter-number">PREFIX_CHAPTER_NUMBER</a>.
1193 </p>
1194
1195 <!-- -CHAPTER_STRING- -->
1196
1197 <h3 id="chapter-string" class="docs">Chapter string</h3>
1198
1199 <p>
1200 If you&#8217;re not writing in English, you can ask mom to use the
1201 word for &#8220;chapter&#8221; in your own language by telling her
1202 what it is with the CHAPTER_STRING macro, like this:
1203 <br/>
1204 <span class="pre">
1205   .CHAPTER_STRING "Chapître"
1206 </span>
1207 </p>
1208
1209 <p>
1210 If you would like a blank chapter string, ie you&#8217;d like
1211 the chapter number to appear without &#8220;Chapter&#8221;
1212 beforehand, enter <kbd>.CHAPTER_STRING "\&"</kbd>.
1213 </p>
1214
1215 <!-- -CHAPTER_TITLE- -->
1216
1217 <div class="macro-id-overline">
1218 <h3 id="chapter-title" class="macro-id">CHAPTER_TITLE</h3>
1219 </div>
1220
1221 <div class="box-macro-args">
1222 Macro: <b>CHAPTER_TITLE</b>  <kbd class="macro-args">&quot;&lt;chapter title&gt;&quot; [&quot;&lt;2nd line&gt;&quot; [&quot;&lt;3rd line&gt;&quot; ... ] ]</kbd> 
1223 </div>
1224 <p class="requires">
1225 &bull;&nbsp;Arguments must be enclosed in double-quotes
1226 </p>
1227
1228 <p>
1229 If, either in addition to or instead of &#8220;Chapter
1230 &lt;n&gt;&#8221; appearing at the top of chapters, you want your
1231 chapter to have a title, use CHAPTER_TITLE, with your title enclosed
1232 in double-quotes, like this:
1233 <br/>
1234 <span class="pre">
1235   .CHAPTER_TITLE "The DMCA Nazis"
1236 </span>
1237 </p>
1238
1239 <p>
1240 CHAPTER_TITLE accepts multiple arguments, each surrounded by
1241 double-quotes.  Each argument is printed on a separate line,
1242 permitting you to create multi-line chapter titles in your
1243 docheaders.
1244 </p>
1245
1246 <p>
1247 If you&#8217;ve used
1248 <a href="#chapter">CHAPTER</a>
1249 to give the chapter a number, both &#8220;Chapter &lt;n&gt;&#8221;
1250 and the chapter title will appear at the top of the chapter, like
1251 this:
1252 <br/>
1253 <span class="pre-in-pp">
1254        Chapter 1
1255     The DMCA Nazis
1256 </span>
1257 In such a case, by default, only the chapter&#8217;s title will appear in
1258 the
1259 <a href="definitions.html#header">page headers</a>,
1260 not &#8220;Chapter &lt;n&gt;&#8221;.
1261 </p>
1262
1263 <p>
1264 If you omit CHAPTER when setting up your reference macros, only the
1265 title will appear, both at the top of page one and in subsequent
1266 page headers.
1267 </p>
1268
1269 <p>
1270 The style of the chapter title can be altered by
1271 <a href="docelement.html#docelement-control">control macros</a>,
1272 e.g., CHAPTER_TITLE_FAMILY, CHAPTER_TITLE_FONT, etc.  The default
1273 family, font and point size are Times Roman, Bold Italic, 4 points
1274 larger than
1275 <a href="definitions.html#running">running text</a>.
1276 </p>
1277
1278 <!-- -DRAFT- -->
1279
1280 <div class="macro-id-overline">
1281 <h3 id="draft" class="macro-id">DRAFT</h3>
1282 </div>
1283
1284 <div class="box-macro-args">
1285 Macro: <b>DRAFT</b> <kbd class="macro-args">&lt;draft number&gt;</kbd>
1286 </div>
1287
1288 <p>
1289 DRAFT only gets used with
1290 <a href="#copystyle">COPYSTYLE&nbsp;DRAFT</a>.
1291 If the COPYSTYLE is FINAL (the default), mom ignores DRAFT.  DRAFT
1292 accepts both alphabetic and numeric arguments, hence it&#8217;s
1293 possible to do either
1294 <br/>
1295 <span class="pre">
1296   .DRAFT 2
1297      or
1298   .DRAFT Two
1299 </span>
1300 </p>
1301
1302 <p>
1303 Mom prints the argument to <kbd>.DRAFT</kbd> (ie the draft number)
1304 beside the word &#8220;Draft&#8221; in the middle part of
1305 <a href="definitions.html#header">page headers</a>.
1306 </p>
1307
1308 <div class="box-tip">
1309 <p class="tip">
1310 <span class="note">A small word of caution:</span>
1311 If your argument to <kbd>.DRAFT</kbd> is more than one word long,
1312 you must enclose the argument in double-quotes.
1313 </p>
1314 </div>
1315
1316 <p>
1317 You may, if you wish, invoke <kbd>.DRAFT</kbd> without an
1318 argument, in which case, no draft number will be printed beside
1319 &#8220;Draft&#8221; in headers or footers.
1320 </p>
1321
1322 <!-- -DRAFT_STRING- -->
1323
1324 <h3 id="draft-string" class="docs">The draft string</h3>
1325
1326 <p>
1327 If you&#8217;re not writing in English, you can ask mom
1328 to use the word for &#8220;draft&#8221; in your own language by
1329 telling her what it is with the DRAFT_STRING macro,
1330 like this:
1331 <br/>
1332 <span class="pre">
1333   .DRAFT_STRING "Jet"
1334 </span>
1335 </p>
1336
1337 <p>
1338 Equally, DRAFT_STRING can be used to roll your own solution to
1339 something other than the word &#8220;Draft.&#8221; For example, you
1340 might want &#8220;Trial run alpha-three&#8221; to appear in the
1341 headers of a draft version.  You&#8217;d accomplish this by doing
1342 <br/>
1343 <span class="pre">
1344   .DRAFT alpha-three
1345   .DRAFT_STRING "Trial run"
1346 </span>
1347 </p>
1348
1349 <p>
1350 If you wanted only &#8220;Trial run&#8221; to appear, entering
1351 <kbd>.DRAFT</kbd> without an argument as well as
1352 <kbd>.DRAFT_STRING&nbsp;"Trial&nbsp;run"</kbd> is how you&#8217;d do it.
1353 </p>
1354
1355 <div class="box-tip">
1356 <p class="tip">
1357 <span class="note">Note:</span>
1358 If you define both a blank <kbd>.DRAFT</kbd> and a blank
1359 <kbd>.DRAFT_STRING</kbd>, mom skips the draft field in headers
1360 entirely.  If this is what you want, this is also the only way
1361 to do it.  Simply omitting invocations of <kbd>.DRAFT</kbd> and
1362 <kbd>.DRAFT_STRING</kbd> will result in mom using her default, which
1363 is to print &#8220;Draft &lt;number&gt;&#8221;.
1364 </p>
1365 </div>
1366
1367 <!-- -REVISION- -->
1368
1369 <div class="macro-id-overline">
1370 <h3 id="revision" class="macro-id">REVISION</h3>
1371 </div>
1372
1373 <div class="box-macro-args">
1374 Macro: <b>REVISION</b> <kbd class="macro-args">&lt;revision number&gt;</kbd>
1375 </div>
1376
1377 <p>
1378 REVISION only gets used with
1379 <a href="#copystyle">COPYSTYLE DRAFT</a>.
1380 If the COPYSTYLE is FINAL (the default), mom ignores the REVISION
1381 macro. REVISION accepts both alphabetic and numeric arguments, hence
1382 it&#8217;s possible to do either
1383 <br/>
1384 <span class="pre" style="margin-bottom: -1em;">
1385   .REVISION 2
1386 </span>
1387 or
1388 <span class="pre" style="margin-top: -.5em;">
1389   .REVISION Two
1390 </span>
1391 </p>
1392
1393 <p>
1394 Mom prints the revision number beside the shortform
1395 &#8220;Rev.&#8221; in the middle part of
1396 <a href="definitions.html#header">page headers</a>.
1397 </p>
1398
1399 <div class="box-tip">
1400 <p class="tip">
1401 <span class="note">A small word of caution:</span>
1402 If your argument to <kbd>.REVISION</kbd> is more than one word long,
1403 you must enclose the argument in double-quotes.
1404 </p>
1405 </div>
1406
1407 <p>
1408 You may, if you wish, invoke <kbd>.REVISION</kbd> without an
1409 argument, in which case, no revision number will be printed beside
1410 &#8220;Rev.&#8221; in headers or footers.
1411 </p>
1412
1413 <!-- -REVISION_STRING- -->
1414
1415 <h3 id="revision-string" class="docs">The revision string</h3>
1416
1417 <p>
1418 If you&#8217;re not writing in English, you can ask mom
1419 to use the word for &#8220;revision,&#8221; or a shortform
1420 thereof, in your own language by telling her what it is with the
1421 REVISION_STRING macro, like this:
1422 <br/>
1423 <span class="pre">
1424   .REVISION_STRING "Rév."
1425 </span>
1426 </p>
1427
1428 <p>
1429 Additionally, you may sometimes want to make use of mom&#8217;s
1430 <a href="#copystyle">COPYSTYLE DRAFT</a>
1431 but not actually require any draft information.  For example,
1432 you might like mom to indicate only the revision number of
1433 your document.  The way to do that is to define an empty
1434 <kbd>.DRAFT</kbd> and <kbd>.DRAFT_STRING</kbd> in addition to
1435 <kbd>.REVISION</kbd>, like this:
1436 <br/>
1437 <span class="pre">
1438   .DRAFT
1439   .DRAFT_STRING
1440   .REVISION 2
1441 </span>
1442 </p>
1443
1444 <p>
1445 Equally, if you want to roll your own solution to what revision
1446 information appears in headers, you could do something like this:
1447 <br/>
1448 <span class="pre">
1449   .DRAFT
1450   .DRAFT_STRING
1451   .REVISION "two-twenty-two"
1452   .REVISION_STRING "Revision"
1453 </span>
1454 </p>
1455
1456 <p>
1457 The above, naturally, has no draft information.  If you want to roll
1458 your own <kbd>.DRAFT</kbd> and/or <kbd>.DRAFT_STRING</kbd> as well,
1459 simply supply arguments to either or both.
1460 </p>
1461
1462 <!-- -COPYRIGHT- -->
1463
1464 <div class="macro-id-overline">
1465 <h3 id="copyright" class="macro-id">COPYRIGHT</h3>
1466 </div>
1467
1468 <div class="box-macro-args">
1469 Macro: <b>COPYRIGHT</b> <kbd class="macro-args">[COVER | DOC_COVER] &quot;&lt;copyright info&gt;&quot;</kbd>
1470 </div>
1471
1472 <p class="requires">
1473 &bull;&nbsp;Argument must be enclosed in double-quotes
1474 </p>
1475
1476 <p>
1477 The argument passed to COPYRIGHT is only used on cover or doc cover
1478 pages, and then only if the argument COPYRIGHT is passed to
1479 <a href="cover.html#cover">COVER</a>
1480 or
1481 <a href="cover.html#doc-cover">DOC_COVER</a>.
1482 Do not include the copyright symbol in the argument passed to
1483 COPYRIGHT; mom puts it in for you.
1484 </p>
1485
1486 <p>
1487 If the optional argument, <kbd>COVER</kbd> or <kbd>DOC_COVER</kbd>,
1488 is given to COPYRIGHT, the string argument represents the copyright
1489 information that will appear on cover or document cover pages (see
1490 the
1491 <a href="cover.html#cover-intro">Introduction to cover pages</a>
1492 for a description of the difference between &#8220;document
1493 covers&#8221; and &#8220;covers&#8221;).  Thus, it is possible to
1494 have differing copyright information on the document cover and on
1495 the cover (&#8220;title&#8221;) page.  An example might be:
1496 <br/>
1497 <span class="pre-in-pp">
1498   .COPYRIGHT DOC_COVER "2010 John Smith and Jane Doe"
1499   .COPYRIGHT COVER "2008 Joe Blow"
1500 </span>
1501 The first invocation of <kbd>.COPYRIGHT</kbd> establishes the
1502 copyright information that appears on the document cover; the second
1503 establishes the copyright information that appears on the cover
1504 (&#8220;title&#8221;) page.
1505 </p>
1506
1507 <p>
1508 If you don&#8217;t require differing copyright information for
1509 doc cover and cover pages, <kbd>.COPYRIGHT</kbd>, without the
1510 optional first argument, is sufficient, provided you give the word,
1511 <kbd>COPYRIGHT</kbd>, as an argument to the macro
1512 <a href="cover.html#doc-cover">DOC_COVER</a>
1513 or
1514 <a href="cover.html#cover">COVER</a>
1515 </p>
1516
1517 <p>
1518 Style parameters for the copyright line may be
1519 entered as individual macros or
1520 <a href="docelement.html#grouping">grouped</a>,
1521 e.g.,
1522 <br/>
1523 <span class="pre-in-pp">
1524   .COPYRIGHT_FAMILY H
1525   .COPYRIGHT_FONT   R
1526   .COPYRIGHT_SIZE   -2
1527 </span>
1528 or
1529 <br/>
1530 <span class="pre-in-pp">
1531   .COPYRIGHT_STYLE \
1532   FAMILY H \
1533   FONT   R \
1534   SIZE   -2
1535 </span>
1536 The vertical position of the copyright line may be raised (-) or
1537 lowered (+) with the macro COPYRIGHT_V_ADJUST.  For example, to
1538 raise the copyright line by 3
1539 <a href="definitions.html#picaspoints">points</a>, you&#8217;d do
1540 <br/>
1541 <span class="pre-in-pp">
1542   .COPYRIGHT_V_ADJUST -3p
1543 </span>
1544 Alternatively, the COPYRIGHT_STYLE macro may be used with the
1545 argument <kbd>V_ADJUST</kbd>:
1546 <span class="pre-in-pp">
1547   .COPYRIGHT_STYLE \
1548   FAMILY    H \
1549   FONT      R \
1550   SIZE     -2 \
1551   V_ADJUST -3p
1552 </span>
1553 </p>
1554
1555 <!-- -MISC- -->
1556
1557 <div class="macro-id-overline">
1558 <h3 id="misc" class="macro-id">MISC</h3>
1559 </div>
1560
1561 <div class="box-macro-args">
1562 Macro: <b>MISC</b> <kbd class="macro-args">[COVER | DOC_COVER] &quot;&lt;argument 1&gt;&quot; [&quot;&lt;argument 2&gt;&quot; &quot;&lt;argument 3&gt;&quot; ...]</kbd>
1563 </div>
1564
1565 <p class="requires">
1566 &bull;&nbsp;String arguments must be enclosed in double-quotes
1567 </p>
1568
1569 <p>
1570 The argument(s) passed to MISC are only used on cover or doc cover
1571 pages, and then only if the argument <kbd>MISC</kbd> is passed to
1572 <a href="cover.html#cover">COVER</a>
1573 or
1574 <a href="cover.html#doc-cover">DOC_COVER</a>.
1575 MISC can contain any information you like.  Each argument appears on
1576 a separate line at the bottom of the cover or doc cover page.
1577 </p>
1578
1579 <p>
1580 For example, if you&#8217;re submitting an essay where the prof has
1581 requested that you include the course number, his name and the date,
1582 you could do
1583 <br/>
1584 <span class="pre-in-pp">
1585   .MISC "Music History 101" "Professor Hasbeen" "Dec. 24, 2010"
1586 </span>
1587 and the information would appear on the essay&#8217;s cover page.
1588 </p>
1589
1590 <p>
1591 If the optional argument, <kbd>COVER</kbd> or <kbd>DOC_COVER</kbd>,
1592 is given to MISC, the string arguments represent the miscellaneous
1593 information that will appear on cover or document cover pages (see
1594 the
1595 <a href="cover.html#cover-intro">Introduction to cover pages</a>
1596 for a description of the difference between &#8220;document
1597 covers&#8221; and &#8220;covers&#8221;).  Thus, it is possible to
1598 have differing miscellaneous information on the document cover and
1599 on the cover (&#8220;title&#8221;) page.  An example might be:
1600 <br/>
1601 <span class="pre">
1602   .MISC DOC_COVER "Music History 101" "Professor Hasbeen"
1603   .MISC COVER "Spring Term Paper"
1604 </span>
1605 </p>
1606
1607 <p>
1608 The first invocation of <kbd>.MISC</kbd> establishes the
1609 miscellaneous information that appears on the document cover; the
1610 second establishes the miscellaneous information that appears on the
1611 cover (&#8220;title&#8221;) page.
1612 </p>
1613
1614 <p>
1615 If you don&#8217;t require differing miscellaneous information
1616 for doc cover and cover pages, <kbd>.MISC</kbd>, without the
1617 optional first argument, is sufficient, provided you give the word
1618 &#8220;MISC&#8221; as an argument to the macro
1619 <a href="cover.html#doc-cover">DOC_COVER</a>
1620 or
1621 <a href="cover.html#cover">COVER</a>
1622 </p>
1623
1624 <!-- -COVER_TITLE- -->
1625
1626 <div class="macro-id-overline">
1627 <h3 class="macro-id">COVERTITLE &amp; DOC_COVERTITLE</h3>
1628 </div>
1629
1630 <div id="covertitle" class="box-macro-args">
1631 Macro: <b>COVERTITLE</b> <kbd class="macro-args">&quot;&lt;user defined cover page title&gt;&quot; [&quot;&lt;2nd line&gt;&quot; [&quot;&lt;3rd line&gt;&quot; ... ] ]</kbd> 
1632 </div>
1633 <p class="requires">
1634 &bull;&nbsp;Arguments must be enclosed in double-quotes
1635 </p>
1636
1637 <div id="doc-covertitle" class="box-macro-args">
1638 Macro: <b>DOC_COVERTITLE</b> <kbd class="macro-args">&quot;&lt;user defined document cover page title&gt;&quot; [&quot;&lt;2nd line&gt;&quot; [&quot;&lt;3rd line&gt;&quot; ... ] ]</kbd> 
1639 </div>
1640 <p class="requires">
1641 &bull;&nbsp;Arguments must be enclosed in double-quotes
1642 </p>
1643
1644 <p>
1645 The arguments passed to COVERTITLE or DOC_COVERTITLE are only
1646 used on cover or doc cover pages, and then only if the argument
1647 COVERTITLE or DOC_COVERTITLE is passed to
1648 <a href="cover.html#cover">COVER</a>
1649 or
1650 <a href="cover.html#doc-cover">DOC_COVER</a>.
1651 </p>
1652
1653 <p>
1654 The only time you require a COVERTITLE or DOC_COVERTITLE is when
1655 none of the required first arguments to COVER or DOC_COVER fits
1656 your needs for the title you want to appear on cover (or doc cover)
1657 pages.
1658 </p>
1659
1660 <p>
1661 COVERTITLE and DOC_COVERTITLE accept multiple arguments, each
1662 surrounded by double-quotes.  Each argument is printed on a separate
1663 line, permitting you to create multi-line titles on your cover
1664 and/or doc cover pages.
1665 </p>
1666
1667 <div class="macro-id-overline">
1668 <h3 class="macro-id">PDF Title</h3>
1669 </div>
1670
1671 <div id="pdftitle" class="box-macro-args">
1672 Macro: <b>PDF_TITLE</b> <kbd class="macro-args">&quot;&lt;pdf viewer window title&gt;&quot; </kbd> 
1673 </div>
1674 <p class="requires">
1675 &bull;&nbsp;Arguments must be enclosed in double-quotes
1676 </p>
1677
1678 <p>
1679 Except for
1680 <a href="#doc-title">DOCTITLE</a>,
1681 mom does not, by default, provide PDF viewers with a document title.
1682 You may set one, if you like, with PDF_TITLE.
1683 </p>
1684
1685 <div class="rule-short"><hr/></div>
1686
1687 <!-- ======================================================================== -->
1688
1689 <h2 id="docstyle-macros" class="macro-group">The docstyle macros</h2>
1690
1691 <p>
1692 The docstyle macros tell mom what type of document you&#8217;re
1693 writing, whether you want the output typeset or &#8220;typewritten,
1694 double-spaced&#8221;, and whether you want a draft copy (with draft
1695 and revision information in the headers) or a final copy.
1696 </p>
1697
1698 <div class="macro-list-container">
1699 <h3 id="index-docstyle" class="macro-list">Docstyle macros</h3>
1700 <ul class="macro-list">
1701   <li><a href="#doctype">DOCTYPE</a>
1702   <li><a href="#printstyle">PRINTSTYLE</a> &ndash; non-optional macro required for document processing
1703   <ul style="margin-left: -.5em; list-style-type: disc;">
1704     <li><a href="#typeset-defaults">Defaults for PRINTSTYLE TYPESET</a></li>
1705     <li><a href="#typewrite-defaults">Defaults for PRINTSTYLE TYPEWRITE</a>
1706     <ul style="margin-left: -.5em; list-style-type: circle;">
1707       <li><a href="#typewrite-control">PRINTSTYLE TYPEWRITE control macros</a>
1708       <ul style="margin-left: -1.5em; list-style-type: square;">
1709         <li><a href="#typewriter-family">Family</a></li>
1710         <li><a href="#typewriter-size">Point size</a></li>
1711         <li><a href="#typewriter-underlining">Underlining of italics</a></li>
1712       </ul></li>
1713     </ul></li>
1714   </ul></li>
1715   <li><a href="#copystyle">COPYSTYLE</a></li>
1716 </ul>
1717 </div>
1718
1719 <!-- -DOCTYPE- -->
1720
1721 <div class="macro-id-overline">
1722 <h3 id="doctype" class="macro-id">DOCTYPE</h3>
1723 </div>
1724
1725 <div class="box-macro-args">
1726 Macro: <b>DOCTYPE</b> <kbd class="macro-args">DEFAULT | CHAPTER | NAMED &quot;&lt;name&gt;&quot; | LETTER | SLIDES</kbd>
1727 </div>
1728
1729 <p>
1730 The arguments <kbd>DEFAULT,</kbd> <kbd>CHAPTER</kbd> and
1731 <kbd>NAMED</kbd> tell mom what to put in the
1732 <a href="definitions.html#docheader">docheader</a>
1733 and
1734 <a href="definitions.html#header">page headers</a>.
1735 <kbd>LETTER</kbd> and <kbd>SLIDES</kbd> tells her you want to write
1736 a letter or create slides.
1737 </p>
1738
1739 <p>
1740 Mom&#8217;s default DOCTYPE is <kbd>DEFAULT</kbd>.  If that&#8217;s
1741 what you want, you don&#8217;t have to give a DOCTYPE command.
1742 </p>
1743
1744 <p id="default-doctype">
1745 <kbd>DEFAULT</kbd> prints a
1746 <a href="definitions.html#docheader">docheader</a>
1747 containing the title, subtitle and author information given to the
1748 <a href="#reference-macros">reference macros</a>,
1749 and page headers with the author and title.  (See
1750 <a href="headfootpage.html#header-style">Default specs for headers</a>
1751 for how mom outputs each part of the page header.)
1752 </p>
1753
1754 <p>
1755 <kbd>CHAPTER</kbd> prints &#8220;Chapter &lt;n&gt;&#8221; in place
1756 of a
1757 <a href="definitions.html#docheader">docheader</a>
1758 (&lt;n&gt; is what you gave to the
1759 <a href="#reference-macros">reference macro</a>,
1760 <kbd><a href="#chapter">CHAPTER</a></kbd>).
1761 If you give the chapter a title with
1762 <a href="#chapter-title">CHAPTER_TITLE</a>,
1763 mom prints &#8220;Chapter &lt;n&gt;&#8221; and the
1764 title underneath.  If you omit the
1765 <a href="#chapter">CHAPTER</a>
1766 reference macro but supply a
1767 <a href="#chapter-title">CHAPTER_TITLE</a>,
1768 mom prints only the chapter title.
1769 </p>
1770
1771 <p>
1772 The page headers in DOCTYPE <kbd>CHAPTER</kbd> contain the author,
1773 the title of the book (which you gave with
1774 <a href="#title">TITLE</a>),
1775 and &#8220;Chapter &lt;n&gt;&#8221; (or the chapter title).  See
1776 <a href="headfootpage.html#header-style">Default Specs for Headers</a>
1777 for mom&#8217;s default type parameters for each part of
1778 the page header.
1779 </p>
1780
1781 <p>
1782 <kbd>NAMED</kbd> takes an additional argument: a name for this
1783 particular kind of document (e.g., outline, synopsis, abstract,
1784 memorandum), enclosed in double-quotes. <kbd>NAMED</kbd> is
1785 identical to <kbd>DEFAULT</kbd> except that mom prints the argument
1786 to <kbd>NAMED</kbd> beneath the
1787 <a href="definitions.html#docheader">docheader</a>,
1788 as well as in page headers.
1789 (See
1790 <a href="headfootpage.html#header-style">Default specs for headers</a>
1791 for how mom outputs each part of the page header.)
1792 </p>
1793
1794 <div class="box-tip">
1795 <p id="copystyle-note" class="tip">
1796 <span class="note">Note: version 2.1 change</span>
1797 <br/>
1798 <kbd>DOCTYPE NAMED "string"</kbd> no longer accepts a color argument
1799 after <kbd>"string"</kbd>.  Setting the color of the string is now
1800 done with <kbd>DOCTYPE_COLOR &lt;color&gt;</kbd>.  Default
1801 underscoring of <kbd>"string"</kbd> in the docheader and on covers
1802 has been removed.  Use <kbd>DOCTYPE_UNDERLINE</kbd>,
1803 <kbd>DOC_COVER_DOCTYPE_UNDERLINE</kbd> and/or
1804 <kbd>COVER_DOCTYPE_UNDERLINE</kbd> to re-enable it.  All three
1805 take the same arguments listed in the
1806 <a href="docelement.html#underline">Underline style, rule weight</a>
1807 section of
1808 <a href="docelement.html#control-macro-args">Arguments to the control macros</a>.
1809 </p>
1810 </div>
1811
1812 <p>
1813 <kbd>LETTER</kbd> tells mom you&#8217;re writing a letter.  See the
1814 section
1815 <a href="letters.html#letters">Writing Letters</a>
1816 for instructions on using mom to format letters.
1817 </p>
1818
1819 <h4 id="slides" class="docs" style="font-size: 100%; text-transform: uppercase">Slides</h4>
1820
1821 <p>
1822 PDF slides are a special kind of mom document, formatted for viewing
1823 in a PDF reader&#8217;s presentation mode.  In most respects, they
1824 behave identically to the other document types.  Key differences
1825 are:
1826 </p>
1827 <ul style="margin-top: -.5em">
1828 <li>headers, footers, and pagination are disabled by default</li>
1829 <li>type is set
1830 <a href="typesetting.html#quad">QUAD CENTER</a>
1831 by default</li>
1832 <li>
1833 <a href="#flex">flex-spacing</a>
1834 and
1835 <a href="#shim">shimming</a>
1836 are disabled by default; shimming may
1837 be re-enabled (with <kbd>NO_SHIM OFF</kbd>), but not flex-spacing</li>
1838 <li>there&#8217;s no need for
1839 <a href="#printstyle">PRINTSTYLE</a></li>
1840 </ul>
1841
1842 <p>
1843 DOCTYPE SLIDES takes up to five optional arguments, which come
1844 immediately after SLIDES. They may be entered in any order.
1845 <br/>
1846 <span class="pre-in-pp">
1847   DOCTYPE SLIDES \
1848    ASPECT 4:3 | 16:9 \
1849    HEADER "left" "centre" "right" \
1850    FOOTER  "left" "centre" "right" \
1851    TRANSITION "&lt;slide transition effect&gt;" (mode + parameters) \
1852    PAUSE "&lt;text reveal effect&gt;" (mode + parameters)
1853 </span>
1854 For convenience, you many want to enter each argument on a single
1855 line as shown above; all but the last must be terminated by a
1856 backslash.
1857 </p>
1858
1859 <h5 class="docs" style="margin-top: .5em">Aspect</h5>
1860
1861 <p>
1862 Slides can be formatted for one of two aspect ratios common to
1863 monitors and screens: 4:3 and 16:9.  The default is 16:9.
1864 <span class="pre-in-pp">
1865  4:3                              16:9
1866  media size: 11" x 8.25"          media size: 11" x 8.1875"
1867  left/right margins: 36 points    left/right margins: 36 points
1868  top margin: 90 points            top margin: 80 points
1869  bottom margin: 84 points         bottom margin: 72 points
1870  base text size: 16 points        base text size: 14 points
1871  autoleading: 6 points, adjusted  autoleading: 4 points, adjusted
1872  (header/footer size: -3 points)  (header/footer size: -2 points)
1873 </span>
1874 Note that both media sizes fit on either A4 or US LETTER papersizes.
1875 </p>
1876
1877 <h5 class="docs" style="margin-top: .5em">Headers, footers, and pagination</h5>
1878
1879 <p>
1880 If you want a header, footer, or both for your slides, pass SLIDES
1881 the <kbd>HEADER</kbd> and/or <kbd>FOOTER</kbd> argument(s).  Both
1882 take three additional
1883 <a href="definitions.html#stringargument">string arguments</a>,
1884 which must be enclosed in double-quotes, defining the left, centre,
1885 and right parts of the header/footer.  Any parts you want left blank
1886 should be entered as two double-quotes.  For example,
1887 <span class="pre-in-pp">
1888   HEADER "" "My slide presentation" ""  
1889 </span>
1890 will result in a header with only the centre part.
1891 </p>
1892
1893 <p>
1894 Normal pagination is disabled for slides.  If you want your slides
1895 numbered, the slide number must be given to one of the header/footer
1896 parts with the
1897 <a href="definitions.html#inlines">inline escape</a>
1898 <br/>
1899 <kbd>\*[SLIDE#]</kbd>.  For example:
1900 <span class="pre-in-pp">
1901   HEADER "" "My slide presentation" "" \
1902   FOOTER "" "" "\*[SLIDE#]"
1903 </span>
1904 will give you a centred header with numbering at the bottom right of
1905 the slide.
1906 </p>
1907
1908 <p>
1909 The overall family, size, and colour of headers may be set with
1910 HEADER_FAMILY, HEADER_SIZE, and HEADER_COLOR.  If you request
1911 FOOTERS, you may use the FOOTER_ equivalent of these macros.
1912 If you request both headers and footers, use one or the other but
1913 not both.  For example, in a header/footer situation, HEADER_FAMILY
1914 would determine the family for both headers and footers, but if you
1915 attempted to do this
1916 <span class="pre-in-pp">
1917   .HEADER_FAMILY T
1918   .FOOTER_FAMILY H
1919 </span>
1920 FOOTER_FAMILY would take precedence, and your header family would be
1921 &#8220;<kbd>H</kbd>&#8221;.
1922 </p>
1923
1924 <p>
1925 All other formatting of individual header/footer parts must be
1926 entered as inline escapes inside the double-quotes.  If you want,
1927 say, your headers to be red but your footer page numbering to be
1928 black and two points larger, this is how you&#8217;d do it:
1929 <span class="pre-in-pp">
1930   .HEADER_COLOR red
1931   .DOCTYPE SLIDES \
1932     HEADER "" "My slide presentation" "" \
1933     FOOTER "" "" "\*[black]\*S[+2]\*[SLIDE#]\*S[-2]"
1934 </span>
1935 </p>
1936
1937 <div class="box-tip">
1938 <p class="tip">
1939 <span class="note">Note:</span>
1940 Do not use mom&#8217;s
1941 <a href="inlines.html#inline-size-mom"><kbd>\*[SIZE &plusmn;n]</kbd></a>
1942 inline escape to change point size in the strings passed to HEADER
1943 or FOOTER.  Prefer either mom&#8217;s <kbd>\*S[&plusmn;n]</kbd> or
1944 groff's <kbd>\s[&plusmn;n]</kbd>.
1945 </span>
1946 </p>
1947 </div>
1948
1949 <h5 class="docs" style="margin-top: .5em">Transition</h5>
1950
1951 <p>
1952 &#8220;Transition&#8221; refers to how new slides appear during a
1953 presentation.  The official PDF specification lists a number of modes,
1954 each with a choice of configurable parameters.  Modes include Box,
1955 Blinds, Wipe, Fade, and several others.  Parameters include things
1956 like duration, dimension, and direction.  There are a total of
1957 twelve modes; for each one there are from one to six configurable
1958 parameters.  Consult <kbd>man gropdf(1)</kbd> for a complete listing
1959 of modes and parameters.
1960 </p>
1961
1962 <p>
1963 If you pass SLIDES the <kbd>TRANSTION</kbd> argument, you must
1964 at a minimum follow it with a mode.  Afterwards, you may give as
1965 many or as few parameters as you wish.  Parameters are, in order,
1966 <span class="pre-in-pp">
1967   1. duration
1968   2. dimension
1969   3. motion
1970   4. direction
1971   5. scale
1972   6. bool
1973 </span>
1974 You don't have to fill them all out.  If you only need the first
1975 three, that's all you need to input.  If you need the first and
1976 third, enter the second as a period (dot), which is used any time
1977 you want to leave a parameter at its current default or when it
1978 isn&#8217;t applicable.  For example, if you want a Box transition
1979 that lasts 1 second, filling the screen from the centre outwards,
1980 you'd enter
1981 <span class="pre-in-pp">
1982   TRANSITION "Box 1 . O"
1983 </span>
1984 because Box does not take a &#8220;dimension&#8221; parameter but it
1985 does take a motion parameter.
1986 </p>
1987
1988 <p>
1989 Notice that the entire string (mode+parameters) must be enclosed in
1990 double-quotes.
1991 </p>
1992
1993 <div class="box-tip">
1994 <p class="tip">
1995 <span class="note">Note:</span>
1996 Not all PDF viewers support all modes.  Any that are not supported
1997 are replaced by the &#8220;R&#8221; mode, which simply replaces one
1998 slide with the next unless the PDF viewer has a different default
1999 transition mode.
2000 </span>
2001 </p>
2002 </div>
2003
2004 <h5 class="docs" style="margin-top: .5em">Pause</h5>
2005
2006 <p>
2007 A &#8220;pause&#8221; occurs when material on a slide is halted (see
2008 <a href="#pause">PAUSE</a>),
2009 awaiting a mouse click, PgDown, Next, or the spacebar to reveal 
2010 subsequent material.  All the same modes and parameters as
2011 <kbd>TRANSITION</kbd> may be used.  The manner of entering them is
2012 is identical, including that the entire mode+parameter string must
2013 be enclosed in double-quotes.
2014 </p>
2015
2016 <div class="macro-id-overline">
2017 <h3 id="slide-macros" class="macro-id">SLIDE MACROS</h3>
2018 </div>
2019
2020 <div id="newslide" class="box-macro-args">
2021 Macro: <b>NEWSLIDE</b> <kbd class="macro-args">["&lt;transition mode and parameters&gt;"]</kbd>
2022 </div>
2023
2024 <p>
2025 Unless you want material from one slide to flow onto the next, you
2026 need to tell mom when to start a new slide with the macro NEWSLIDE.
2027 Without any arguments, the new slide will appear with the default
2028 TRANSTION you gave to DOCTYPE SLIDES.
2029 </p>
2030
2031 <p>
2032 If you would like a different transition, you may pass NEWSLIDE a
2033 new mode and associated parameters, following the same rules as the
2034 TRANSITION argument to DOCTYPE.  Note that the new effect becomes
2035 the default.  If you wish to return to the original transition, you
2036 must give it explicitly to the appropriate NEWSLIDE.
2037 </p>
2038
2039 <div id="pause" class="box-macro-args">
2040 Macro: <b>PAUSE</b> <kbd class="macro-args">["&lt;pause mode and parameters&gt;"]</kbd>
2041 </div>
2042
2043 <p>
2044 Pauses in slides are accomplished by entering the macro PAUSE at
2045 desired locations in your input file.  Subsequent material will be
2046 revealed using the pause mode given to DOCTYPE SLIDES.
2047 </p>
2048
2049 <p>
2050 If you would like a different mode, you may pass PAUSE a
2051 new mode and associated parameters, following the same rules as the
2052 PAUSE argument to DOCTYPE.
2053 </p>
2054
2055 <div id="transition" class="box-macro-args">
2056 Macro: <b>TRANSITION</b> <kbd class="macro-args">["&lt;transition mode and parameters&gt;"]</kbd>
2057 </div>
2058
2059 <p>
2060 If for some reason you have material that flows from one slide to
2061 the next <i>and</i> you want the next slide to have a transition
2062 different from the current one, you can tell mom about the new
2063 transition with the macro TRANSITION anywhere prior to the break to
2064 the next slide.
2065 </p>
2066
2067 <h4 id="slide-printing" class="docs" style="font-size: 100%; text-transform: uppercase">Printing slides</h4>
2068
2069 <p>
2070 If you want to print slides as handouts, you have to tell
2071 <kbd>pdfmom</kbd> or <kbd>gropdf</kbd>, otherwise printing will
2072 stop at the first pause.  Simply precede <kbd>pdfmom</kbd> or
2073 <kbd>gropdf</kbd> with GROPDF_NOSLIDE=1, like this:
2074 <br/>
2075 <span class="pre-in-pp">
2076  GROPDF_NOSLIDE=1 pdfmom &lt;options&gt; slidefile.mom &gt; slidefile.pdf
2077 </span>
2078
2079 </p>
2080
2081 <!-- -PRINTSTYLE- -->
2082
2083 <div class="macro-id-overline">
2084 <h3 id="printstyle" class="macro-id">PRINTSTYLE</h3>
2085 </div>
2086
2087 <div class="box-macro-args">
2088 Macro: <b>PRINTSTYLE</b> <kbd class="macro-args">TYPESET | TYPEWRITE [ SINGLESPACE ]</kbd>
2089 </div>
2090
2091 <p class="requires">
2092 &bull;&nbsp;Required for document processing, except in the case of
2093 slides
2094 <br/>
2095 Must come before any changes to default document style
2096 </p>
2097
2098 <p>
2099 PRINTSTYLE tells mom whether to typeset a document, or to print it
2100 out &#8220;typewritten, doubled-spaced&#8221;.
2101 </p>
2102
2103 <div class="box-important">
2104 <p class="tip-top">
2105 <span class="important">Important:</span>
2106 <b>This macro may not be omitted.</b> In order for document
2107 processing to take place, mom requires a PRINTSTYLE.  If you
2108 don&#8217;t give one, mom will warn you on stderr and print a single
2109 page with a nasty message.
2110 </p>
2111
2112 <p class="tip-bottom">
2113 <span class="important">Just as important:</span>
2114 PRINTSTYLE <b>must precede any and all page and style
2115 parameters associated with a document</b> with the exception of
2116 <kbd>PAPER</kbd>, <kbd>PAGEWIDTH</kbd>, and/or
2117 <kbd>PAGELENGTH</kbd>, which should be placed at the top of your
2118 file.  PRINTSTYLE sets up complete templates that include default
2119 margins, family, fonts, point sizes, and so on.  Therefore, changes
2120 to any aspect of document style must come afterwards.  For example,
2121 <br/>
2122 <span class="pre-in-pp">
2123   .PAPER A4
2124   .LS 14
2125   .QUAD LEFT
2126   .PRINTSTYLE TYPESET
2127 </span>
2128 will not change mom&#8217;s default document leading to 14 points,
2129 nor the default justification style (fully justified) to left
2130 justified, whereas
2131 <br/>
2132 <span class="pre-in-pp">
2133   .PAPER A4
2134   .PRINTSTYLE TYPESET
2135   .LS 14
2136   .QUAD LEFT
2137 </span>
2138 will.
2139 </p>
2140
2141 </div>
2142
2143 <p>
2144 <kbd>TYPESET</kbd>, as the argument implies, typesets
2145 documents (by default in Times Roman; see
2146 <a href="#typeset-defaults">TYPESET defaults</a>).
2147 You have full access to all the
2148 <a href="typesetting.html#macros-typesetting">typesetting macros</a>
2149 as well as the
2150 <a href="definitions.html#style-control">style control macros</a>
2151 of document processing.
2152 </p>
2153
2154 <p>
2155 With <kbd>TYPEWRITE</kbd>, mom does her best to reproduce the look
2156 and feel of typewritten, double-spaced copy (see
2157 <a href="#typewrite-defaults">TYPEWRITE defaults</a>).
2158 <a href="docelement.html#docelement-control">Control macros</a>
2159 and
2160 <a href="typesetting.html#intro-macros-typesetting">typesetting macros</a>
2161 that alter family, font, point size, and
2162 <a href="definitions.html#leading">leading</a>
2163 are (mostly) ignored.  An important exception is
2164 <a href="headfootpage.html#hdrftr-global-size">HEADER_SIZE</a>
2165 (and, by extension, FOOTER_SIZE), which allows you to reduce the
2166 point size of headers/footers should they become too crowded.  Most
2167 of mom&#8217;s inlines affecting the appearance of type are also
2168 ignored
2169 (<kbd><a href="inlines.html#inline-size-mom">\*S[&lt;size&gt;]</a></kbd>
2170 is an exception; there may be a few others).
2171 </p>
2172
2173 <p>
2174 In short, <kbd>TYPEWRITE</kbd> never produces effects
2175 other than those available on a typewriter.  Don&#8217;t be fooled
2176 by how brainless this sounds; mom is remarkably sophisticated when
2177 it comes to conveying the typographic sense of a document within the
2178 confines of <kbd>TYPEWRITE</kbd>.
2179 </p>
2180
2181 <p>
2182 The primary uses of <kbd>TYPEWRITE</kbd> are: outputting hard
2183 copy drafts of your work (for editing) and producing documents
2184 for submission to publishers and agents who (wisely) insist on
2185 typewritten, double-spaced copy.  To get a nicely typeset version of
2186 work that&#8217;s in the submission phase of its life (say, to show
2187 fellow writers for critiquing), simply change <kbd>TYPEWRITE</kbd>
2188 to <kbd>TYPESET</kbd> and print out a copy.
2189 </p>
2190
2191 <p>
2192 If, for some reason, you would prefer the output of
2193 <kbd>TYPEWRITE</kbd> single-spaced, pass PRINTSTYLE
2194 <kbd>TYPEWRITE</kbd> the optional argument, <kbd>SINGLESPACE</kbd>.
2195 </p>
2196
2197 <div class="defaults-container">
2198 <h3 id="typeset-defaults" class="docs defaults" style="margin-top: 0;">PRINTSTYLE TYPESET defaults</h3>
2199 <span class="pre defaults">
2200   Family            = Times Roman
2201   Point size        = 12.5
2202   Paragraph leading = 16 points, adjusted
2203   Fill mode         = justified
2204   Hyphenation       = enabled
2205                       max. lines = 2
2206                       margin = 36 points
2207                       interword adjustment = 1 point
2208   Kerning           = enabled
2209   Ligatures         = enabled
2210   Smartquotes       = enabled
2211   Word space        = groff default
2212   Sentence space    = 0
2213 </span>
2214 </div>
2215
2216 <div class="defaults-container">
2217 <h3 id="typewrite-defaults" class="docs defaults" style="margin-top: 0;">PRINTSTYLE TYPEWRITE defaults</h3>
2218 <span class="pre defaults">
2219   Family            = Courier
2220   Italics           = underlined
2221   Point size        = 12
2222   Paragraph leading = 24 points, adjusted; 12 points for SINGLESPACE
2223   Fill mode         = left
2224   Hyphenation       = disabled
2225   Kerning           = disabled
2226   Ligatures         = disabled
2227   Smartquotes       = disabled
2228   Word space        = groff default
2229   Sentence space    = groff default
2230   Columns           = ignored
2231 </span>
2232 </div>
2233
2234 <div class="box-tip" style="margin-top: 1.5em;">
2235 <h3 id="typewrite-control" class="docs control">PRINTSTYLE TYPEWRITE control macros</h3>
2236
2237 <h4 id="typewriter-family" class="docs">Family</h4>
2238
2239 <p style="margin-top: .5em;">
2240 If you&#8217;d prefer a monospace
2241 <a href="definitions.html#family">family</a>
2242 for PRINTSTYLE <kbd>TYPEWRITE</kbd> other than than mom's default,
2243 Courier, you can change it with
2244 <kbd>.TYPEWRITER_FAMILY&nbsp;&lt;family&gt;</kbd> (or
2245 <kbd>.TYPEWRITER_FAM</kbd>).  Since groff ships with only the
2246 Courier family, you will have to install any other monospace family
2247 yourself.  See
2248 <a href="appendices.html#fonts">Adding fonts to
2249 groff</a>.
2250 </p>
2251
2252 <h4 id="typewriter-size" class="docs">Point size</h4>
2253
2254 <p style="margin-top: .5em;">
2255 If you&#8217;d like a smaller or larger point size for
2256 for PRINTSTYLE <kbd>TYPEWRITE</kbd> (mom&#8217;s default is 12-point),
2257 you can change it with
2258 <kbd>.TYPEWRITER_SIZE&nbsp;&lt;size&gt;</kbd>.  There&#8217;s no need to
2259 add a
2260 <a href="definitions.html#unitofmeasure">unit of measure</a>
2261 to the <kbd>&lt;size&gt;</kbd> argument; points is assumed.  Be
2262 aware, however, that regardless of point size, mom&#8217;s
2263 leading/linespacing for <kbd>TYPEWRITE</kbd> is fixed at 24-point
2264 for double-spaced, and 12-point for single-spaced.
2265 </p>
2266
2267 <h4 id="typewriter-underlining" class="docs">Underlining of italics</h4>
2268
2269 <p>
2270 In PRINTSTYLE <kbd>TYPEWRITE</kbd>, mom, by default, underlines
2271 anything that looks like italics.  This includes the
2272 <a href="typesetting.html#slant-inline"><kbd>\*[SLANT]</kbd></a>
2273 <a href="definitions.html#inlines">inline escape</a>
2274 for pseudo-italics.
2275 </p>
2276
2277 <p id="printstyle-italics">
2278 If you&#8217;d prefer that mom were less bloody-minded
2279 about pretending to be a typewriter (ie you&#8217;d like italics and
2280 pseudo-italics to come out as italics), use the control macros
2281 <br/>
2282 <span class="pre-in-pp">
2283   .ITALIC_MEANS_ITALIC
2284 </span>
2285 and
2286 <span class="pre-in-pp">
2287   .SLANT_MEANS_SLANT
2288 </span>
2289 Neither requires an argument.
2290 </p>
2291
2292 <p>
2293 Although it&#8217;s unlikely, should you wish to reverse
2294 the sense of these macros in the midst of a document,
2295 <kbd>.UNDERLINE_ITALIC</kbd> and <kbd>.UNDERLINE_SLANT</kbd> restore
2296 underlining of italics and pseudo-italics.
2297 </p>
2298
2299 <p id="underline-quotes">
2300 Additionally, by default, mom underlines
2301 <a href="definitions.html#quotes">quotes</a>
2302 (but not
2303 <a href="definitions.html#blockquotes">blockquotes</a>)
2304 in PRINTSTYLE <kbd>TYPEWRITE</kbd>.  If you don&#8217;t like this
2305 behaviour, turn it off with
2306 <br/>
2307 <span class="pre">
2308   .UNDERLINE_QUOTES OFF
2309 </span>
2310 </p>
2311
2312 <p>
2313 To turn underlining of quotes back on, use UNDERLINE_QUOTES without
2314 an argument.
2315 </p>
2316
2317 <p class="tip-bottom">
2318 While most of the
2319 <a href="docelement.html#docelement-control">control macros</a>
2320 have no effect on <b>PRINTSTYLE TYPEWRITE</b>, there
2321 is an important exception:
2322 <a href="headfootpage.html#hdrftr-global-size">HEADER_SIZE</a>
2323 (and by extension, FOOTER_SIZE).  This is
2324 particularly useful for reducing the point size of
2325 headers/footers should they become crowded (quite likely to
2326 happen if the title of your document is long and your
2327 <kbd><a href="#copystyle">COPYSTYLE</a></kbd>
2328 is DRAFT).
2329 </p>
2330 </div>
2331
2332 <!-- -COPYSTYLE- -->
2333
2334 <div class="macro-id-overline">
2335 <h3 id="copystyle" class="macro-id">COPYSTYLE</h3>
2336 </div>
2337
2338 <div class="box-macro-args">
2339 Macro: <b>COPYSTYLE</b> <kbd class="macro-args">DRAFT | FINAL</kbd>
2340 </div>
2341
2342 <p>
2343 Mom&#8217;s default COPYSTYLE is <kbd>FINAL</kbd>, so you
2344 don&#8217;t have to use this macro unless you want to.
2345 </p>
2346
2347 <p>
2348 COPYSTYLE <kbd>DRAFT</kbd> exhibits the following behaviour:
2349 </p>
2350 <ol style="margin-top: -.5em;">
2351   <li>Documents start on page 1, whether or not you
2352       request a different starting page number with
2353       <a href="headfootpage.html#pagenumber">PAGENUMBER</a>.
2354   </li>
2355   <li>Page numbers are set in lower case roman numerals.</li>
2356   <li>The draft number supplied by 
2357       <a href="#draft">DRAFT</a>
2358       and a revision number, if supplied with 
2359       <a href="#revision">REVISION</a>
2360       (see
2361       <a href="#reference-macros">reference macros</a>),
2362       appear in the centre part of
2363       <a href="definitions.html#header">page headers</a>
2364       (or footers, depending on which you&#8217;ve selected) along with
2365       any other information that normally appears there.
2366   </li>
2367 </ol>
2368
2369 <div class="box-important">
2370 <p class="tip">
2371 <span class="important">Important:</span>
2372 If you define your own centre part for page headers with
2373 <a href="headfootpage.html#hdrftr-center">HEADER_CENTER</a>,
2374 no draft and/or revision number will appear there.  If you want
2375 draft and revision information in this circumstance, use
2376 <a href="headfootpage.html#draft-with-pagenumber">DRAFT_WITH_PAGENUMBER</a>.
2377 </p>
2378 </div>
2379
2380 <p>
2381 COPYSTYLE <kbd>FINAL</kbd> differs from <kbd>DRAFT</kbd> in that:
2382 </p>
2383 <ol style="margin-top: -.5em;">
2384   <li>It respects the starting page number you give the document.</li>
2385   <li>Page numbers are set in normal (Arabic) digits.</li>
2386   <li>No draft or revision number appears in the page headers.</li>
2387 </ol>
2388
2389 <div class="box-tip">
2390 <p id="copystyle-note" class="tip">
2391 <span class="note">Note:</span>
2392 The centre part of page headers can get crowded, especially with
2393 <a href="docprocessing.html#doctype">DOCTYPE <kbd>CHAPTER</kbd></a>
2394 and
2395 <a href="docprocessing.html#doctype">DOCTYPE <kbd>NAMED</kbd></a>,
2396 when the COPYSTYLE is <kbd>DRAFT</kbd>.  Three mechanisms are
2397 available to overcome this problem.  One is to reduce the overall
2398 size of headers (with
2399 <a href="headfootpage.html#hdrftr-global-size">HEADER_SIZE</a>).
2400 Another, which only works with
2401 <a href="docprocessing.html#printstyle">PRINTSTYLE <kbd>TYPESET</kbd></a>,
2402 is to reduce the size of the header&#8217;s centre part only (with
2403 <a href="headfootpage.html#_size">HEADER_CENTER_SIZE</a>).
2404 And finally, you can elect to have the draft/revision information
2405 attached to page numbers instead of having it appear in the centre
2406 of page headers (see
2407 <a href="headfootpage.html#draft-with-pagenumber">DRAFT_WITH_PAGENUMBER</a>).
2408 </p>
2409 </div>
2410
2411 <div class="rule-short"><hr/></div>
2412
2413 <!-- ======================================================================== -->
2414
2415 <h2 id="start-macro" class="macro-group">Initiate document processing</h2>
2416
2417 <p>
2418 In order to use mom&#8217;s document element macros (tags), you have
2419 to tell her you want them.  The macro to do this is
2420 <a href="#start">START</a>.
2421 </p>
2422
2423 <p>
2424 START collects the information you gave mom in the setup section at
2425 the top of your file (see
2426 <a href="#docprocessing-tut">Tutorial &ndash; Setting up a mom document</a>),
2427 merges it with her defaults, sets up headers and page numbering,
2428 and prepares mom to process your document using the document
2429 element tags.  No document processing takes place until you invoke
2430 <kbd>.START</kbd>.
2431 </p>
2432
2433 <!-- -START- -->
2434
2435 <div class="macro-id-overline">
2436 <h3 id="start" class="macro-id">START</h3>
2437 </div>
2438
2439 <div class="box-macro-args">
2440 Macro: <b>START</b>
2441 </div>
2442 <p class="requires">
2443 &bull;&nbsp;Required for document processing
2444 </p>
2445
2446 <p>
2447 START takes no arguments.  It simply instructs mom to begin document
2448 processing.  If you don&#8217;t want document processing (ie you
2449 only want the
2450 <a href="typesetting.html#macros-typesetting">typesetting macros</a>),
2451 don&#8217;t use START.
2452 </p>
2453
2454 <p>
2455 At a barest minimum before START, you must enter a
2456 <a href="#printstyle">PRINTSTYLE</a>
2457 command.
2458 </p>
2459
2460 <div class="rule-short"><hr/></div>
2461
2462 <!-- ======================================================================== -->
2463
2464 <h2 id="style-before-start" class="macro-group">Establishing typestyle and formatting parameters before START</h2>
2465
2466 <p>
2467 In the third (optional) part of setting up a document (the
2468 stylesheet; see
2469 <a href="#docprocessing-tut">Tutorial &ndash; Setting up a mom document</a>),
2470 you can use the
2471 <a href="typesetting.html">typesetting macros</a>
2472 to change mom&#8217;s document-wide defaults for margins,
2473 line length, family, base point size,
2474 <a href="definitions.html#leading">leading</a>,
2475 and justification style.
2476 </p>
2477
2478 <p>
2479 Two additional style concerns have to be addressed here (ie in
2480 macros before
2481 <a href="#start">START</a>):
2482 changes to the
2483 <a href="definitions.html#docheader">docheader</a>,
2484 and whether you want you want the document&#8217;s nominal leading
2485 adjusted to fill pages fully to the bottom margin.
2486 </p>
2487
2488 <div class="macro-list-container" style="margin-top: 2em;">
2489 <h3 id="index-style-before-start" class="macro-list">Type &amp; formatting parameters before START</h3>
2490 <ul class="macro-list">
2491   <li><a href="#type-before-start">Behaviour of the typesetting macros before START</a>
2492   <ul class="sublist" style="line-height: 120%; margin-bottom: .25em;">
2493     <li><a href="#meanings">List of meanings</a></li>
2494     <li><a href="#lrc-note">Special note on LEFT, RIGHT and CENTER</a></li>
2495     <li><a href="#include">Including (sourcing) style sheets and files</a></li>
2496     <li><a href="#color">Initializing colors</a></li>
2497   </ul></li>
2498   <li><a href="#doc-lead-adjust">DOC_LEAD_ADJUST</a> &ndash; adjust linespacing to fill pages and align bottom margins</li>
2499   <li><a href="#docheader">DOCHEADER</a>
2500   <ul class="sublist" style="line-height: 120%;">
2501     <li><a href="#docheader-control">Docheader control</a></li>
2502   </ul></li>
2503   <li><a href="#columns">COLUMNS</a>
2504   <ul class="sublist" style="line-height: 120%;">
2505     <li><a href="#col-next">COL_NEXT</a></li>
2506     <li><a href="#col-break">COL_BREAK</a></li>
2507   </ul></li>
2508 </ul>
2509 </div>
2510
2511 <h3 id="type-before-start" class="docs">Behaviour of the typesetting macros before START</h3>
2512
2513 <p>
2514 From time to time (or maybe frequently), you&#8217;ll want the
2515 overall look of a document to differ from mom&#8217;s defaults.
2516 Perhaps you&#8217;d like her to use a different
2517 <a href="definitions.html#family">family</a>,
2518 or a different overall
2519 <a href="definitions.html#leading">leading</a>,
2520 or have different left and/or right page margins.
2521 </p>
2522
2523 <p>
2524 To accomplish such alterations, use the appropriate
2525 <a href="typesetting.html#macros-typesetting">typesetting macros</a>
2526 (listed below) after
2527 <a href="#printstyle">PRINTSTYLE</a>
2528 and before
2529 <a href="#start">START</a>.
2530 </p>
2531
2532 <p>
2533 More than one user has, quite understandably, not fully grasped the
2534 significance of the preceding sentence.  The part they&#8217;ve missed is
2535 <i>after</i> PRINTSTYLE.
2536 </p>
2537
2538 <p>
2539 Changes to any aspect of the default look and/or formatting of a mom
2540 document must come after PRINTSTYLE.  For example, it might seem
2541 natural to set up page margins at the very top of a document with
2542 <br/>
2543 <span class="pre-in-pp">
2544   .L_MARGIN 1i
2545   .R_MARGIN 1.5i
2546 </span>
2547 However, when you invoke <kbd>.PRINTSTYLE</kbd>, those margins
2548 will be overridden.  The correct place to set margins&mdash;and
2549 all other changes to the look of a document&mdash;is <i>after</i>
2550 PRINTSTYLE.
2551 </p>
2552
2553 <div class="box-tip">
2554 <p class="tip">
2555 <span class="important">Important:</span>
2556 Do not use the macros listed in
2557 <a href="#doc-param-macros">Changing document-wide typesetting parameters after START</a>
2558 prior to START; they are exclusively for use afterwards.
2559 </p>
2560 </div>
2561
2562 <div id="meanings" class="defaults-container">
2563 <h3 class="docs defaults" style="margin-top: 0;">Meanings</h3>
2564 <p style="margin-left: 9px; margin-top: -.25em;">
2565 When used before START, the
2566 <a href="typesetting.html#macros-typesetting">typesetting macros</a>,
2567 below have the following meanings:
2568 <br/>
2569 <span class="pre">
2570   L_MARGIN       Left margin of pages, including headers/footers
2571   R_MARGIN       Right margin of pages, including headers/footers
2572   T_MARGIN       The point at which running text (ie not
2573                  headers/footers or page numbers) starts on each
2574                  page
2575   B_MARGIN*      The point at which running text (ie not
2576   (see note)     headers/footers or page numbers) ends on each page
2577
2578   PAGE           If you use PAGE, its final four arguments have the
2579                  same meaning as L_ R_ T_ and B_MARGIN (above).
2580
2581   LL             The line length for everything on the page;
2582                  equivalent to setting the right margin with
2583                  R_MARGIN
2584   FAMILY         The family of all type in the document
2585   PT_SIZE        The point size of type in paragraphs; mom uses
2586                  this to calculate automatic point size changes
2587                  (e.g., for heads, footnotes, quotes, headers, etc)
2588   LS/AUTOLEAD**  The leading used in paragraphs; all leading and
2589                  spacing of running text is calculated from this
2590
2591   QUAD/JUSTIFY   Affects paragraphs only
2592   LEFT***        No effect
2593   RIGHT***       No effect
2594   CENTER***      No effect
2595
2596 ------
2597   *See <a href="headfootpage.html#footer-margin">FOOTER MARGIN AND BOTTOM MARGIN</a> for an important warning
2598  **See <kbd><a href="#doc-lead-adjust">DOC_LEAD_ADJUST</a></kbd>
2599 ***See <a href="#lrc-note">Special note</a>
2600 </span>
2601 </p>
2602 </div>
2603
2604 <p style="margin-top: -.75em;">
2605 Other macros that deal with type style, or refinements thereof
2606 (<b>KERN, LIGATURES, HY, WS, SS,</b> etc.), behave normally.
2607 It is not recommended that you set up tabs or indents prior to
2608 START.
2609 </p>
2610
2611 <p>
2612 If you want to change any of the basic parameters (above)
2613 <i>after</i> START and have them affect a document globally (as if
2614 you&#8217;d entered them <i>before</i> START), you must use the macros
2615 listed in
2616 <a href="#doc-param-macros">Changing document-wide style parameters after START</a>.
2617 </p>
2618
2619 <h4 id="lrc-note" class="docs">Special note on LEFT, RIGHT and CENTER prior to START</h4>
2620
2621 <p>
2622 In a word, these three macros have no effect on document processing
2623 when invoked prior to START.
2624 </p>
2625
2626 <p>
2627 All mom&#8217;s document element tags (PP, HEAD, BLOCKQUOTE,
2628 FOOTNOTE, etc.) except
2629 <a href="docelement.html#quote">QUOTE</a>
2630 set a
2631 <a href="definitions.html#filled">fill mode</a>
2632 as soon as they&#8217;re invoked.  If you wish to turn fill mode off
2633 for the duration of any tag (with
2634 <a href="typesetting.html#lrc">LEFT, RIGHT or CENTER</a>)
2635 you must do so immediately after invoking the tag.  Furthermore,
2636 the change affects <i>only</i> the current invocation of the tag.
2637 Subsequent invocations of the same tag for which you want the same
2638 change require that you invoke <kbd>.LEFT</kbd>, <kbd>.RIGHT</kbd>
2639 or <kbd>.CENTER</kbd> immediately after every invocation of the tag.
2640 </p>
2641
2642 <!-- -INCLUDE- -->
2643
2644 <h4 id="include" class="docs">Including (sourcing) style sheets and files</h4>
2645
2646 <p>
2647 If you routinely make the same changes to mom&#8217;s defaults in
2648 order to create similar documents in a similar style&mdash;in other
2649 words, you need a template&mdash; you can create style-sheet files
2650 and include, or "source", them into your mom documents with the
2651 macro INCLUDE.  The right place for such style sheets is after
2652 <a href="#printstyle">PRINTSTYLE</a>
2653 and before
2654 <a href="#start">START</a>.
2655 </p>
2656
2657 <p>
2658 Say, for example, in a particular kind of document, you always
2659 want main heads set in Helvetica Bold Italic, flush left,
2660 with no underscore.  You&#8217;d create a file, let&#8217;s call it
2661 <kbd>head-template</kbd>, in which you&#8217;d place the pertinent HEAD
2662 control macros.
2663 <br/>
2664 <span class="pre-in-pp">
2665   .HEADING_STYLE 1 \
2666   FAMILY    H \
2667   FONT      BI \
2668   QUAD      L \
2669   NO_UNDERSCORE
2670 </span>
2671 Then, in the preliminary document set-up section of your main file,
2672 you&#8217;d include the style sheet, or template, like this:
2673 <br/>
2674 <span class="pre-in-pp">
2675   .TITLE      "Sample Document
2676   .AUTHOR     "Joe Blow
2677   .PRINTSTYLE TYPESET
2678   \#
2679   .INCLUDE    head-template
2680   \#
2681   .START
2682 </span>
2683
2684 The blank comment lines ( <kbd>\#</kbd> ) aren&#8217;t required, but
2685 they do make your file(s) easier to read.
2686 </p>
2687
2688 <p>
2689 If the file to be included is in the same directory as the file
2690 you&#8217;re working, you simply enter the filename after
2691 <kbd>.INCLUDE</kbd>.  If the file&#8217;s in another directory, you must
2692 provide a full path name to it.  For example, if you&#8217;re working in
2693 a directory called <kbd>/home/joe/stories</kbd> and your
2694 style-sheet is in <kbd>/home/joe/style-sheets</kbd>, the above
2695 example would have to look like this:
2696 <br/>
2697 <span class="pre-in-pp">
2698   .TITLE      "Sample Document
2699   .AUTHOR     "Joe Blow
2700   .PRINTSTYLE TYPESET
2701   \#
2702   .INCLUDE    /home/joe/style-sheets/head-template
2703   \#
2704   .START
2705 </span>
2706 </p>
2707
2708 <p>
2709 INCLUDE is not restricted to style sheets or templates.  You can
2710 include any file at any point into a document, provided the file
2711 contains only text and valid groff or mom formatting commands.
2712 Neither is INCLUDE restricted to use with mom&#8217;s document
2713 processing macros.  You can use it in plain typeset documents as
2714 well.
2715 </p>
2716
2717 <div class="box-tip">
2718 <p class="tip">
2719 <span class="experts">Experts:</span>
2720 INCLUDE is an alias for the groff request, <kbd>.so</kbd>.  Mix 'n'
2721 match with impunity.
2722 </p>
2723 </div>
2724
2725 <!-- -COLOUR- -->
2726
2727 <h4 id="color" class="docs">Initializing colours</h4>
2728
2729 <p>
2730 Although it doesn&#8217;t really matter where you define/initialize
2731 colours for use in document processing (see
2732 <a href="color.html#newcolor">NEWCOLOR</a>
2733 and
2734 <a href="color.html#xcolor">XCOLOR</a>
2735 in the section
2736 <a href="color.html#color-intro">Coloured text</a>),
2737 I recommend doing so before you begin document processing with
2738 <kbd><a href="#start">START</a></kbd>.
2739 </p>
2740
2741 <p>
2742 The macro
2743 <a href="color.html#color">COLOR</a>
2744 and the
2745 <a href="definitions.html#inlines">inline escape</a>,
2746 <a href="color.html#color-inline"><kbd>\*[&lt;colorname&gt;]</kbd></a>
2747 can be used at any time during document processing for occasional
2748 colour effects.  However, consistent and reliable colourizing of
2749 various document elements (the docheader, heads, linebreaks,
2750 footnotes, pagenumbers, and so on) must be managed through the use
2751 of the
2752 <a href="docelement.html#docelement-control">document element control macros</a>.
2753 </p>
2754
2755 <div class="box-tip">
2756 <p class="tip">
2757 <span class="note">Note:</span>
2758 If you plan to have mom generate a
2759 <a href="docelement.html#toc">table of contents</a>,
2760 do not embed colour
2761 <a href="definitions.html#inlines">inline escapes</a>
2762 (<a href="color.html#color-inline"><kbd>\*[&lt;colorname&gt;]</kbd></a>)
2763 in the
2764 <a href="definitions.html#stringargument">string arguments</a>
2765 given to any of the
2766 <a href="docprocessing.html#reference-macros">reference macros</a>,
2767 nor in the string arguments given to
2768 <a href="docelement.html#heading">HEADING</a>.
2769 Use, rather, the
2770 <a href="definitions.html#controlmacro">control macros</a>
2771 mom provides to automatically colourize these elements.
2772 </p>
2773 </div>
2774
2775 <!-- -DOC LEAD ADJUST- -->
2776
2777 <div class="macro-id-overline">
2778 <h3 id="doc-lead-adjust" class="macro-id">Adjust linespacing to fill pages and align bottom margins</h3>
2779 </div>
2780
2781 <div class="box-macro-args">
2782 Macro: <b>DOC_LEAD_ADJUST</b> <kbd class="macro-args">toggle</kbd>
2783 </div>
2784
2785 <p class="requires">
2786 &bull;&nbsp;Must come after
2787 <a href="typesetting.html#ls"><span class="normal">LS</span></a>
2788 or
2789 <a href="typesetting.html.#autoloead"><span class="normal">AUTOLEAD</span></a>
2790 and before
2791 <a href="#start"><span class="normal">START</span></a>
2792 </p>
2793
2794 <p>
2795 DOC_LEAD_ADJUST is a special macro to adjust document
2796 <a href="definitions.html#leading">leading</a>
2797 so that bottom margins fall precisely where you expect.
2798 </p>
2799
2800 <p>
2801 When you invoke <kbd>.DOC_LEAD_ADJUST</kbd>, mom takes the number
2802 of lines that fit on the page at your requested leading, then
2803 incrementally adds
2804 <a href="definitions.html#units">machine units</a>
2805 to the leading until the maximum number of lines at the new leading
2806 that fit on the page coincides perfectly with the bottom margin of
2807 <a href="definitions.html#running">running text</a>.
2808 </p>
2809
2810 <p>
2811 In most instances, the difference between the requested lead and
2812 the adjusted lead is unnoticeable, and since in almost all cases
2813 adjusted leading is what you want, it&#8217;s mom&#8217;s default
2814 and you don't have to invoke it explicitly.
2815 </p>
2816
2817 <p>
2818 However, should you not want adjusted document leading, you must
2819 turn it off manually, like this:
2820 <br/>
2821 <span class="pre">
2822   .DOC_LEAD_ADJUST OFF
2823 </span>
2824 </p>
2825
2826 <p>
2827 If you set the document leading prior to START with
2828 <a href="typesetting.html#leading">LS</a>
2829 or
2830 <a href="typesetting.html#autolead">AUTOLEAD</a>,
2831 DOC_LEAD_ADJUST&nbsp;<kbd>OFF</kbd> must come afterwards, like
2832 this:
2833 <br/>
2834 <span class="pre-in-pp">
2835   .LS 12
2836   .DOC_LEAD_ADJUST OFF
2837 </span>
2838 In this scenario, the maximum number of lines that fit on a page at
2839 a
2840 <a href="definitions.html#leading">leading</a>
2841 of 12
2842 <a href="definitions.html#picaspoints">points</a>
2843 determine where mom ends a page.  The effect will be that last lines
2844 usually fall (slightly) short of the &#8220;official&#8221; bottom
2845 margin.
2846 </p>
2847
2848 <p>
2849 In
2850 <a href="docprocessing.html#printstyle">PRINTSTYLE</a>&nbsp;<kbd>TYPEWRITE</kbd>,
2851 the leading is always adjusted and can&#8217;t be turned off.
2852 </p>
2853
2854 <div class="box-tip">
2855 <p class="tip-top">
2856 <span class="note">Note:</span>
2857 DOC_LEAD_ADJUST, if used, must be invoked after
2858 <a href="typesetting.html#leading">LS</a>
2859 or
2860 <a href="typesetting.html#autolead">AUTOLEAD</a>
2861 and before
2862 <a href="#start">START</a>.
2863 </p>
2864
2865 <p class="tip-bottom">
2866 <span class="additional-note">Additional note:</span>
2867 Even if you disable DOC_LEAD_ADJUST, mom will still adjust the
2868 leading of endnotes pages and toc pages.  See
2869 <a href="docelement.html#endnote-lead">ENDNOTE_LEAD</a>
2870 and
2871 <a href="docelement.html#toc-lead">TOC_LEAD</a>
2872 for an explanation of how to disable this default behaviour.
2873 </p>
2874 </div>
2875
2876 <!-- -DOCHEADER- -->
2877
2878 <div class="macro-id-overline">
2879 <h3 id="docheader" class="macro-id">Managing the docheader</h3>
2880 </div>
2881
2882 <div class="box-macro-args">
2883 Macro: <b>DOCHEADER</b> <kbd class="macro-args">&lt;toggle&gt; [ distance to advance from top of page ] [ NO_SHIM ]</kbd>
2884 </div>
2885
2886 <p class="requires">
2887 &bull;&nbsp;Must come before
2888 <a href="#start"><span class="normal">START</span></a>; <kbd><span class="normal">distance</span></kbd> requires a <a href="definitions.html#unitofmeasure">unit of measure</a>
2889 </p>
2890
2891 <p>
2892 By default, mom prints a
2893 <a href="definitions.html#docheader">docheader</a>
2894 on the first page of any document (see
2895 <a href="#docheader-desc">below</a>
2896 for a description of the docheader).  If you don&#8217;t want a docheader,
2897 turn it off with
2898 <br/>
2899 <span class="pre-in-pp">
2900   .DOCHEADER OFF
2901 </span> 
2902 DOCHEADER is a toggle macro, so the argument doesn&#8217;t
2903 have to be OFF; it can be anything you like.
2904 </p>
2905
2906 <p>
2907 If you turn the docheader off, mom, by default, starts
2908 the running text of your document on the same top
2909 <a href="definitions.html#baseline">baseline</a>
2910 as all subsequent pages.  If you&#8217;d like her to start at a different
2911 vertical position, give her the distance you&#8217;d like as a second
2912 argument.
2913 <br/>
2914 <span class="pre-in-pp">
2915   .DOCHEADER OFF 1.5i
2916 </span>
2917 This starts the document 1.5 inches from the top of the page PLUS
2918 whatever spacing adjustment mom has to make in order to ensure that
2919 the first baseline of running text falls on a &#8220;valid&#8221;
2920 baseline (ie one that ensures that the bottom margin of the first
2921 page falls where it should).  The distance is measured from the top
2922 edge of the paper to the
2923 <a href="definitions.html#baseline">baseline</a>
2924 of the first line of type.
2925 </p>
2926
2927 <p>
2928 With <kbd>DOCHEADER OFF</kbd>, it is possible to create your own
2929 custom docheaders (after
2930 <a href="#start">START</a>)
2931 using mom&#8217;s typesetting macros.  It is recommended that if you
2932 do create a custom docheader, you make
2933 <a href="docprocessing.html#shim"><kbd>.SHIM</kbd></a>
2934 the last macro before the first item of your document (for
2935 example, <kbd>PP</kbd> or <kbd>HEADING&nbsp;1</kbd>.
2936 </p>
2937
2938 <div class="box-tip">
2939 <p class="tip">
2940 <span class="note">Note:</span>
2941 You may have tried <kbd>DOCHEAHER&nbsp;OFF</kbd> with a distance argument
2942 and discovered that mom will not budge the starting position of the document
2943 from her chosen default location.  This is byproduct of
2944 <a href="#shim">shimming</a>,
2945 which mom always applies before the first line of running text after
2946 the docheader, regardless of which
2947 <a href="#vertical-whitespace-management">vertical whitespace management</a>
2948 strategy is in effect.  If you encounter the problem, pass
2949 <kbd>DOCHEADER&nbsp;OFF&nbsp;&lt;distance&gt;</kbd>
2950 the additional final argument, <kbd>NO_SHIM</kbd>.
2951 </p>
2952 </div>
2953
2954 <!-- DOCHEADER CONTROL -->
2955
2956 <h3 id="docheader-control" class="docs">Docheader control: How to change the look of docheaders</h3>
2957
2958 <p>
2959 In
2960 <a href="#printstyle">PRINTSTYLE <kbd>TYPEWRITE</kbd></a>,
2961 the look of docheaders is carved in stone.  In
2962 <a href="#printstyle">PRINTSTYLE <kbd>TYPESET</kbd></a>,
2963 however, you can make a lot of changes.  Macros that alter
2964 docheaders must come before
2965 <a href="#start">START</a>.
2966 </p>
2967
2968 <h4 id="docheader-desc" class="docs">Docheader description</h4>
2969
2970 <p>
2971 A typeset docheader has the following characteristics:
2972 </p>
2973 <div class="box-code" style="margin-left: 24px;">
2974 <span class="pre" style="color: #302419;">
2975     TITLE       bold, 3.5 points larger than running text (not necessarily caps)
2976    Subtitle     medium, same size as running text
2977       by        medium italic, same size as running text
2978    Author(s)    medium italic, same size as running text
2979
2980 (Document type) bold italic, 3 points larger than running text
2981 </span>
2982 </div>
2983
2984 <p>
2985 Or, if the
2986 <a href="#doctype">DOCTYPE</a>
2987 is <kbd>CHAPTER</kbd>,
2988 </p>
2989 <div class="box-code" style="margin-left: 24px;">
2990 <span class="pre" style="color: #302419;">
2991  Chapter &lt;n&gt;   bold, 4 points larger than running text
2992 Chapter Title  bold italic, 4 points larger than running text
2993 </span>
2994 </div>
2995
2996 <p>
2997 The
2998 <a href="definitions.html#family">family</a>
2999 is the prevailing family of the whole document.  Title, subtitle,
3000 author and document type are what you supply with the
3001 <a href="#reference-macros">reference macros</a>.
3002 Any you leave out will not appear; mom will compensate:
3003 </p>
3004
3005 <div class="box-tip">
3006 <p class="tip">
3007 <span class="note">Note:</span>
3008 If your DOCTYPE is <kbd>CHAPTER</kbd> and you have both &#8220;Chapter
3009 &lt;n&gt;&#8221; and a &#8220;Chapter Title&#8221; (as above), mom
3010 inserts a small amount of whitespace between them, equal to
3011 one-quarter of the
3012 <a href="definitions.html#leading">leading</a>
3013 in effect.  If this doesn&#8217;t suit you, you can remove or alter
3014 the space with
3015 <a href="#space-before">CHAPTER_TITLE_SPACE_BEFORE</a>.
3016 </p>
3017 </div>
3018
3019 <div class="macro-list-container">
3020 <h3 id="index-docheader-control" class="macro-list">Docheader control</h3>
3021
3022 <p style="margin-top: -1.5em; margin-left: .5em; margin-right: .5em">
3023 With the docheader control macros, you can change the family,
3024 colour, leading and quad direction of the entire docheader.  You can
3025 also set the style parameters for each part individually.  Style
3026 parameters include family, font, size, colour, lead, space before,
3027 caps, smallcaps and underscoring.
3028 </p>
3029
3030 <ul class="macro-list" style="margin-top: -.5em">
3031   <li><a href="#change-whole-docheader">1. Changes to the whole docheader</a>
3032   <ul style="list-style-type: disc">
3033     <li><a href="#change-start">Change the starting position of the docheader</a></li>
3034     <li><a href="#docheader-family">Change the family of the whole docheader</a></li>
3035     <li><a href="#docheader-color">Change the colour of the whole docheader</a></li>
3036     <li><a href="#docheader-lead">Change the leading of the whole docheader</a></li>
3037     <li><a href="#docheader-quad">Change the quad direction of the docheader</a></li>
3038   </ul>
3039   </li>
3040   <li><a href="#part-by-part">2. Part by part changes</a>
3041   <ul style="list-style-type: disc">
3042     <li><a href="#list-of-params">List of parameters and arguments</a></li>
3043     <li><a href="#grouping">Grouping part/parameter changes</a> &ndash; very handy</li>
3044   </ul>
3045   </li>
3046   <li><a href="#change-attribute">3. Changing or removing the attribution string (&#8220;by&#8221;)</a></li>
3047 </ul>
3048 </div>
3049
3050 <h4 id="change-whole-docheader" class="docs" style="font-size: 100%">1. Changes to the whole docheader</h4>
3051
3052 <h5 id="change-start" class="docs">Change the starting position of the docheader</h5>
3053
3054 <p>
3055 By default, a docheader starts on the same
3056 <a href="definitions.html#baseline">baseline</a>
3057 as
3058 <a href="definitions.html#running">running text</a>.
3059 If you&#8217;d like it to start somewhere else, use the macro
3060 DOCHEADER_ADVANCE and give it the distance you want (measured from
3061 the top edge of the paper to the first baseline of the docheader),
3062 like this:
3063 <br/>
3064 <span class="pre-in-pp">
3065     .DOCHEADER_ADVANCE 4P
3066 </span>
3067 A
3068 <a href="definitions.html#unitofmeasure">unit of measure</a>
3069 is required.
3070 </p>
3071
3072 <div class="box-tip">
3073 <p class="tip">
3074 <span class="note">Note:</span>
3075 If
3076 <a href="headfootpage.html#headers">HEADERS</a>
3077 are <kbd>OFF</kbd>, mom&#8217;s normal top margin for
3078 <a href="definitions.html#running">running text</a>
3079 (7.5
3080 <a href="definitions.html#picaspoints">picas</a>)
3081 changes to 6 picas (visually approx. 1 inch).  Since the first
3082 baseline of the docheader falls on the same baseline as the first
3083 line of running text (on pages after page 1), you might find the
3084 docheaders a bit high when headers are off.  Use DOCHEADER_ADVANCE
3085 to place them where you want.
3086 </p>
3087 </div>
3088
3089 <h5 id="docheader-quad" class="docs">Change the quad direction of the docheader</h5>
3090
3091 <p>
3092 By default, mom centres the docheader.  If you&#8217;d prefer to
3093 have your docheaders set flush left or right, or need to restore
3094 the default centreing, invoke <kbd>.DOCHEADER_QUAD</kbd> with the
3095 quad direction you want, either <kbd>LEFT</kbd> (or <kbd>L</kbd>),
3096 <kbd>RIGHT</kbd> (or <kbd>R</kbd>) or <kbd>CENTER</kbd> (or
3097 <kbd>C</kbd>).
3098 </p>
3099
3100 <h5 id="docheader-family" class="docs">Change the family of the entire docheader</h5>
3101
3102 <p>
3103 By default, mom sets the docheader in the same
3104 family used for 
3105 <a href="definitions.html#running">running text</a>.
3106 If you&#8217;d prefer to have your docheaders set in a different
3107 family, invoke <kbd>.DOCHEADER_FAMILY</kbd> with the family you
3108 want.  The argument to DOCHEADER_FAMILY is the same as for
3109 <a href="typesetting.html#family">FAMILY</a>.
3110 </p>
3111
3112 <p>
3113 For example, mom&#8217;s default family for running text is Times
3114 Roman.  If you&#8217;d like to keep that default, but have the
3115 docheaders set entirely in Helvetica,
3116 <br/>
3117 <span class="pre-in-pp">
3118   .DOCHEADER_FAMILY H
3119 </span>
3120 is how you&#8217;d do it.
3121 </p>
3122
3123 <p>
3124 Please note that if you use DOCHEADER_FAMILY, you can still alter
3125 the family of individual parts of the docheader.
3126 </p>
3127
3128 <h5 id="docheader-color" class="docs">Change the color of the entire docheader</h5>
3129
3130 <p>
3131 The default color for docheaders is black, as you&#8217;d expect.
3132 If you wish to change it, use
3133 <kbd>.DOCHEADER_COLOR&nbsp;&lt;color&gt;</kbd>, where
3134 <kbd>&nbsp;&lt;color&gt;</kbd> is a color pre-initialized with
3135 <a href="color.html#xcolor">XCOLOR</a>
3136 or
3137 <a href="color.html#newcolor">NEWCOLOR</a>.
3138 </p>
3139
3140 <h5 id="docheader-lead" class="docs">Change the leading of the entire docheader</h5>
3141
3142 <p>
3143 By default, mom uses the leading in effect for
3144 <a href="definitions.html#running">running text</a>
3145 for docheaders.  If you want to increase or
3146 decrease the overall docheader leading, use
3147 <kbd>.DOCHEADER_LEAD&nbsp;+|-&lt;amount&gt;</kbd>, where
3148 <kbd>&lt;amount&gt;</kbd> is the number of
3149 <a href="definitions.html#picaspoints">points</a>
3150 by which to make the adjustment.  
3151 </p>
3152
3153 <h4 id="part-by-part" class="docs" style="font-size: 100%">2. Part by part changes</h4>
3154
3155 <p>
3156 Whenever you want to change the style parameters for any part of
3157 the docheader, simply join the name of the part to the parameter
3158 you wish to change using an underscore, then supply any necessary
3159 arguments.  The subitle double-underlined?  No problem.
3160 <br/>
3161 <span class="pre-in-pp">
3162   .SUBTITLE_UNDERLINE DOUBLE
3163 </span>
3164 Author in red?
3165 <br/>
3166 <span class="pre-in-pp">
3167   .AUTHOR_COLOR red
3168 </span>
3169 Title in smallcaps?
3170 <span class="pre-in-pp">
3171   .TITLE_SMALLCAPS
3172 </span>
3173 </p>
3174
3175 <div class="box-tip" style="margin-top: -1em;">
3176 <p class="tip">
3177 <span class="note">Note:</span>
3178 Use <kbd>ATTRIBUTE</kbd> as the part name for the attribution string
3179 (&#8220;by&#8221;) that precedes the author, and <kbd>DOCTYPE</kbd>
3180 as the name for the string passed to <kbd>DOCTYPE NAMED&nbsp;"string"</kbd>.
3181 </p>
3182 </div>
3183
3184 <h5 id="list-of-params" class="docs">List of parameters with arguments</h5>
3185
3186 <dl>
3187   <dt class="params">_FAMILY</dt>
3188     <dd>
3189       Takes the same argument as <a href="typesetting.html#family">FAMILY</a>.
3190     </dd>
3191   <dt class="params">_FONT</dt>
3192     <dd>
3193       Takes the same argument as <a href="typesetting.html#font">FT</a>.
3194     </dd>
3195   <dt class="params">_SIZE</dt>
3196     <dd>
3197       Takes a <kbd>+</kbd> or <kbd>-</kbd> value relative to the size of
3198       <a href="definitions.html#running">running text</a>.
3199     </dd>
3200   <dt class="params">_COLOR</dt>
3201     <dd>
3202       Takes the same argument as <a href="color.html#color">COLOR</a>.
3203       Colors should be pre-initialized with
3204       <a href="color.html#xcolor">XCOLOR</a>
3205       or
3206       <a href="color.html#newcolor">NEWCOLOR</a>.
3207     </dd>
3208   <dt class="params">_LEAD</dt>
3209     <dd>
3210       Takes an absolute leading value, i.e. not relative to the
3211       overall leading of the docheader.  The leading applies to
3212       multiple lines of type within the same docheader part, e.g.
3213       several authors or a long title that must be split over two
3214       lines.  No
3215       <a href="definitions.html#unitofmeasure">unit of measure</a>
3216       is required;
3217       <a href="definitions.html#picaspoints">points</a>
3218       is assumed.
3219     </dd>
3220   <dt id="space-before" class="params">_SPACE</dt>
3221     <dd>
3222       Takes a numeric value with a
3223       <a href="definitions.html#unitofmeasure">unit of measure</a>
3224       appended to it.  The value may be negative.  This allows you
3225       to adjust the whitespace before a docheader part, for example
3226       if you want more whitespace between the title and the author.
3227       <span style="display: block; margin-top: .5em">
3228       Note that <kbd>TITLE</kbd> does not have a <kbd>_SPACE</kbd>
3229       parameter; use
3230       <a href="#change-start">DOCHEADER_ADVANCE</a>
3231       to move the title further down on the page.
3232       </span>
3233     </dd>
3234   <dt class="params">_CAPS</dt>
3235     <dd>
3236       Capitalizes the entire docheader part.  No argument is
3237       required.
3238     </dd>
3239   <dt class="params">_NO_CAPS</dt>
3240     <dd>
3241       Only used if you need to reverse the sense of <kbd>_CAPS</kbd>, as
3242       can sometimes happen when
3243       <a href="rectoverso.html#collate">collating</a>
3244       documents that have differing docheader style requirements.
3245     </dd>
3246   <dt class="params">_SMALLCAPS</dt>
3247     <dd>
3248       Set the entire docheader part in smallcaps.  No argument is
3249       required.
3250     </dd>
3251   <dt class="params">_NO_SMALLCAPS</dt>
3252     <dd>
3253       Only used if you need to reverse the sense of
3254       <kbd>_SMALLCAPS</kbd>, as can sometimes happen when
3255       <a href="rectoverso.html#collate">collating</a>
3256       documents that have differing docheader style requirements.
3257     </dd>
3258   <dt class="params">_UNDERSCORE</dt>
3259     <dd>
3260       With no argument, underscores the docheader part.  With a
3261       single, possibly decimal numeric argument, sets the weight of
3262       the underscore.  A second numeric argument to which a
3263       <a href="definitions.html#unitofmeasure">unit of measure</a>
3264       is appended (most likely <kbd>p</kbd>) sets the distance
3265       between the baseline and the underscore.
3266       <span style="display: block; margin-top: .5em">
3267       If the argument <kbd>DOUBLE</kbd> is given, double underscores
3268       the docheader part.  With a single, possibly decimal numeric
3269       argument afterwards, sets the weight of the underscore rules.
3270       A third numeric argument to which a
3271       <a href="definitions.html#unitofmeasure">unit of measure</a>
3272       is appended (most likely <kbd>p</kbd>) sets the distance
3273       between the baseline and the first underscore rule.  A fourth
3274       numeric argument to which a unit of measure is appended sets
3275       the distance between the two underscore rules.
3276       </span>
3277       <span style="display: block; margin-top: .5em">
3278       You may give <kbd>_UNDERLINE</kbd> as the parameter instead of
3279       <kbd>_UNDERSCORE</kbd> if you prefer.
3280       </span>
3281     </dd>
3282   <dt class="params">NO_UNDERSCORE</dt>
3283     <dd>
3284       Only used if you need to reverse the sense of
3285       <kbd>_UNDERSCORE</kbd>, as can sometimes happen when
3286       <a href="rectoverso.html#collate">collating</a>
3287       documents that have differing docheader style requirements.
3288     </dd>
3289 </dl>
3290
3291 <h5 id="grouping" class="docs">Grouping part/parameter changes</h5>
3292
3293 <p>
3294 If you want to change several parameters for a particular docheader
3295 part, you may group the changes together in a single macro by
3296 joining the name of the part to <kbd>STYLE</kbd> with an underscore,
3297 for example <kbd>TITLE_STYLE</kbd> or <kbd>AUTHOR_STYLE</kbd>.
3298 The following demonstrates:
3299 <span class="pre-in-pp">
3300   .CHAPTER_TITLE_STYLE \
3301   FAMILY T \
3302   SIZE +4 \
3303   UNDERSCORE 2 \
3304   SMALLCAPS
3305 </span>
3306 Notice the use of the backslash character, which is required after
3307 the macro name and all parameters except the last.  Grouping reduces
3308 clutter and the finger fatigue caused by entering
3309 <span class="pre-in-pp">
3310    .CHAPTER_TITLE_FAMILY T
3311    .CHAPTER_TITLE_SIZE +4
3312    .CHAPTER_TITLE_UNDERSCORE 2
3313    .CHAPTER_TITLE_SMALLCAPS
3314 </span>
3315 </p>
3316
3317 <h4 id="change-attribute" class="docs" style="font-size: 100%">3. Changing or removing the attribution string (&#8220;by&#8221;)</h4>
3318
3319 <p>
3320 If you&#8217;re not writing in English, you can change what mom
3321 prints where &#8220;by&#8221; appears in docheaders.  For example,
3322 <br/>
3323 <span class="pre-in-pp">
3324   .ATTRIBUTE_STRING "par"
3325 </span>
3326 changes &#8220;by&#8221; to &#8220;par&#8221;.  ATTRIBUTE_STRING
3327 can also be used, for example, to make the attribution read
3328 &#8220;Edited by&#8221;.
3329 </p>
3330
3331 <p>
3332 If you don&#8217;t want an attribution string at all, simply pass
3333 ATTRIBUTE_STRING an empty argument, like this:
3334 <br/>
3335 <span class="pre-in-pp">
3336   .ATTRIBUTE_STRING ""
3337 </span>
3338 Mom will deposit a blank line where the attribution string normally
3339 appears.
3340 </p>
3341
3342 <p>
3343 If the optional argument, <kbd>COVER</kbd> or <kbd>DOC_COVER</kbd>,
3344 is given to ATTRIBUTE_STRING, the string argument represents the
3345 attribution string that will appear on cover or document cover pages
3346 (see the
3347 <a href="cover.html#cover-intro">Introduction to cover pages</a>
3348 for a description of the difference between &#8220;document
3349 covers&#8221; and &#8220;covers&#8221;).  Thus, it is possible to
3350 have different attribution strings on the document cover page, the
3351 cover (&#8220;title&#8221;) page, and in the first-page docheader.
3352 An extreme example would be:
3353 <br/>
3354 <span class="pre-in-pp">
3355   .ATTRIBUTE_STRING ""
3356   .ATTRIBUTE_STRING DOC_COVER "Edited by"
3357   .ATTRIBUTE_STRING COVER "by"
3358 </span>
3359 The first invocation of <kbd>.ATTRIBUTE_STRING</kbd> establishes a
3360 blank attribution string that will be incorporated in the first-page
3361 docheader.  The second will print &#8220;Edited by&#8221; on the
3362 document cover; the third will print &#8220;by&#8221; on the cover
3363 (&#8220;title&#8221;) page.
3364 </p>
3365
3366 <p>
3367 If you don&#8217;t require differing attribute strings for
3368 doc cover pages, cover pages, or the first-page docheader,
3369 <kbd>.ATTRIBUTE_STRING</kbd>, without either of the optional first
3370 arguments, is sufficient.
3371 </p>
3372
3373 <div class="rule-short"><hr/></div>
3374
3375 <!-- -COLUMNS- -->
3376
3377 <h2 id="columns-intro" class="docs">Setting documents in columns</h2>
3378
3379 <p>
3380 Setting documents in columns is easy with mom.  All you have to do
3381 is is say how many columns you want and how much space you want
3382 between them (the
3383 <a href="definitions.html#gutter">gutters</a>).
3384 That&#8217;s it. Mom takes care of everything else, from soup to
3385 nuts.
3386 </p>
3387
3388 <h3 class="docs">Some words of advice</h3>
3389
3390 <p>
3391 If you want your type to achieve a pleasing
3392 <a href="definitions.html#just">justification</a>
3393 or
3394 <a href="definitions.html#rag">rag</a>
3395 in columns, reduce the point size of type (and probably the
3396 <a href="definitions.html#leading">leading</a>
3397 as well).  Mom&#8217;s default document point size is 12.5, which
3398 works well across her default 39
3399 <a href="definitions.html#picaspoints">pica</a>
3400 full page line length, but with even just two columns on a page, the
3401 default point size is awkward to work with.
3402 </p>
3403
3404 <p>
3405 Furthermore, you&#8217;ll absolutely need to reduce the indents for
3406 <a href="docelement.html#epigraph-control">epigraphs</a>,
3407 <a href="docelement.html#quote-general">quotes</a>,
3408 and
3409 <a href="docelement.html#blockquote-general">blockquotes</a>
3410 (and probably the
3411 <a href="docelement.html#para-indent">paragraph first-line indent</a>
3412 as well).
3413 </p>
3414
3415 <!-- -COLUMN- -->
3416
3417 <div class="macro-id-overline">
3418 <h3 id="columns" class="macro-id">COLUMNS</h3>
3419 </div>
3420
3421 <div class="box-macro-args">
3422 Macro: <b>COLUMNS</b> <kbd class="macro-args">&lt;number of columns&gt; &lt;width of gutters&gt;</kbd>
3423 </div>
3424
3425 <p class="requires">
3426 &bull;&nbsp;Should be the last macro before START
3427 <br/>
3428
3429 <i>The second argument requires a <a href="definitions.html#unitofmeasure">unit of measure</a></i>
3430 </p>
3431
3432 <p>
3433 COLUMNS takes two arguments: the number of columns you want on
3434 document pages, and the width of the
3435 <a href="definitions.html#gutter">gutter</a>
3436 between them.  For example, to set up a page with two columns
3437 separated by an 18 point gutter, you&#8217;d do
3438 <br/>
3439 <span class="pre-in-pp">
3440   .COLUMNS 2 18p
3441 </span>
3442 Nothing to it, really.  However, as noted above, COLUMNS should
3443 always be the last document setup macro prior to
3444 <a href="#start">START</a>.
3445 </p>
3446
3447 <div class="box-tip">
3448 <p class="tip">
3449 <span class="note">Note:</span>
3450 Mom ignores columns completely when the
3451 <a href="#printstyle">PRINTSTYLE</a>
3452 is <kbd>TYPEWRITE</kbd>.  The notion of typewriter-style
3453 output in columns is just too ghastly for her to bear.
3454 </p>
3455 </div>
3456
3457 <h3 class="docs" id="marking-col-start">Marking the first page column start position</h3>
3458
3459 <p>
3460 If you insert or remove space after the docheader, i.e. immediately after
3461 <a href="#start">START</a>
3462 in your input file, mom needs to know where your first column begins
3463 in order to align subsequent columns on the first page.
3464 </p>
3465
3466 <div id="col-mark" class="box-macro-args">
3467 Macro: <b>COL_MARK</b>
3468 </div>
3469
3470 <p>
3471 <kbd>COL_MARK</kbd> tells mom where the first column after the
3472 docheader begins, in order for the top of subsequent columns on the
3473 first page to be aligned.  Note that if you do not manually add
3474 or remove space after the docheader, there is no need to invoke
3475 <kbd>COL_MARK</kbd>.
3476 </p>
3477
3478 <div class="box-tip">
3479 <p class="tip">
3480 <span class="note">Note:</span>
3481 If you do add or subtract space after the docheader, e.g. with
3482 <a href="typesetting.html#ald">ALD</a>
3483 or
3484 <a href="typesetting.html#SP">SP</a>,
3485 and your
3486 <a href="definitions.html#unitofmeasure">unit of measure</a>
3487 is something other than a multiple of &#8220;<kbd>v</kbd>&#8221;, be
3488 sure to follow the spacing command with
3489 <a href="docprocessing.html#shim">SHIM</a>
3490 before entering <kbd>.COL_MARK</kbd> unless shimming has been
3491 disabled with
3492 <a href="#no-shim">NO_SHIM</a>.
3493 If your document is being flex-spaced, do not use
3494 <a href="docprocessing.html#flex">FLEX</a>.
3495 Rather, disable flex-spacing temporarily with
3496 <br/>
3497 <span class="pre-in-pp">
3498   .NO_FLEX
3499   .NO_SHIM off
3500   .SHIM
3501   .COL_MARK
3502 </span>
3503 and re-enable it afterwards with
3504 <span class="pre-in-pp">
3505   .NO_SHIM
3506   .NO_FLEX off
3507 </span>
3508 </p>
3509 </div>
3510
3511 <h3 class="docs">Using tabs when COLUMNS are enabled</h3>
3512
3513 <p>
3514 Mom&#8217;s tabs (both
3515 <a href="typesetting.html#typesetting-tabs">typesetting tabs</a>
3516 and
3517 <a href="typesetting.html#string-tabs">string tabs</a>)
3518 behave as you&#8217;d expect during document processing, even
3519 when COLUMNS are enabled.  Tab structures set up during document
3520 processing carry over from page to page and column to column.
3521 </p>
3522
3523 <!-- -BREAKING COLUMNS- -->
3524
3525 <h3 id="breaking-columns" class="docs">Breaking columns manually</h3>
3526
3527 <p>
3528 Mom takes care of breaking columns when they reach the bottom
3529 margin of a page.  However, there may be times you want to break
3530 the columns yourself.  There are two macros for breaking columns
3531 manually: COL_NEXT and COL_BREAK.
3532 </p>
3533
3534 <div id="col-next" class="box-macro-args">
3535 Macro: <b>COL_NEXT</b>
3536 </div>
3537
3538 <p>
3539 <kbd>.COL_NEXT</kbd> breaks the line just before it,
3540 <a href="definitions.html#quad">quads</a>
3541 it left (assuming the type is justified or quad left), and moves over
3542 to the top of the next column.  If the column happens to be the last
3543 (rightmost) one on the page, mom starts a new page
3544 at the &#8220;column 1&#8221; position.  This is the macro to use when
3545 you want to start a new column after the end of a paragraph.
3546 </p>
3547
3548 <div id="col-break" class="box-macro-args">
3549 Macro: <b>COL_BREAK</b>
3550 </div>
3551
3552 <p>
3553 <kbd>.COL_BREAK</kbd> is almost the same as <kbd>.COL_NEXT</kbd>,
3554 except that instead of breaking and quadding the line preceding it,
3555 mom breaks and spreads it (see
3556 <a href="typesetting.html#spread">SPREAD</a>).
3557 Use this macro whenever you need to start a new column in the middle
3558 of a paragraph.
3559 </p>
3560
3561 <div class="box-important">
3562 <p class="tip">
3563 <span class="important">Warning:</span>
3564 If you need COL_BREAK in the middle of a blockquote or (god help
3565 you) an epigraph, you must do the following in order for COL_BREAK
3566 to work:
3567 <br/>
3568 <span class="pre-in-pp">
3569   .SPREAD
3570   \!.COL_BREAK
3571 </span>
3572 </p>
3573 </div>
3574
3575 <div class="rule-short"><hr/></div>
3576
3577 <!-- ======================================================================== -->
3578
3579 <!-- *** -->
3580
3581
3582 <h2 id="style-after-start" class="macro-group">Changing basic type and formatting parameters after START</h2>
3583
3584 <ul id="changing-basic-type">
3585   <li><a href="#behaviour">Behaviour of the typesetting macros during document processing</a>
3586   <ul style="margin-left: -.5em;">
3587     <li><a href="#behaviour-specific">Effect of specific typesetting macros</a></li>
3588   </ul></li>
3589   <li><a href="#tb-margins">Top and bottom margins in document processing</a></li>
3590   <li><a href="#space">Inserting space at the top of a new page</a>
3591   <ul style="margin-left: -.5em;">
3592     <li><a href="#add-space">ADD_SPACE</a></li>
3593   </ul></li>
3594 </ul>
3595
3596 <div class="rule-medium"><hr/></div>
3597
3598 <h3 id="behaviour" class="docs">Behaviour of the typesetting macros during document processing</h3>
3599
3600 <p>
3601 During document processing, most of the
3602 <a href="typesetting.html#macros-typesetting">typesetting macros</a>
3603 affect type in the document globally.  For example, if you turn
3604 kerning off, pairwise kerning is disabled not only in paragraphs,
3605 but also in headers, footers, quotes, and so on.
3606 </p>
3607
3608 <p>
3609 Typesetting macros that alter margins and line lengths affect
3610 <a href="definitions.html#running">running text</a>
3611 globally (or at least try to), but leave headers/footers and
3612 footnotes alone.  (To indent footnotes, see the full explanation of
3613 the
3614 <a href="docelement.html#footnote">FOOTNOTE</a>
3615 macro.)
3616 </p>
3617
3618 <p>
3619 Mom&#8217;s tabs (both
3620 <a href="typesetting.html#typesetting-tabs">typesetting tabs</a>
3621 and
3622 <a href="typesetting.html#string-tabs">string tabs</a>)
3623 behave as expected in running text during document processing.  Tab
3624 structures that do not exceed the line length of running text are
3625 preserved sensibly from page to page, and, if
3626 <a href="docprocessing.html#columns">COLUMNS</a>
3627 are enabled, from column to column.
3628 </p>
3629
3630 <p>
3631 Some typesetting macros, however, when used during document
3632 processing, behave in special ways.  These are the macros that deal
3633 with the basic parameters of type style: horizontal and vertical
3634 margins, line length,
3635 <a href="definitions.html#family">family</a>,
3636 <a href="definitions.html#font">font</a>,
3637 <a href="definitions.html#ps">point size</a>,
3638 <a href="definitions.html#leading">leading</a>,
3639 and
3640 <a href="definitions.html#quad">quad</a>.
3641 </p>
3642
3643 <p>
3644 Mom assumes that any changes to these parameters stem from a
3645 temporary need to set type in a style different from that provided
3646 by mom&#8217;s
3647 <a href="docelement.html#index-docelement">document element tags</a>.
3648 In other words, you need to do a bit of creative typesetting in the
3649 middle of a document.
3650 </p>
3651
3652 <p>
3653 The following lists those typesetting macros whose behaviour during
3654 document processing requires some explanation.
3655 (Please refer to
3656 <a href="#tb-margins">Top and bottom margins in document processing</a>
3657 for information on how mom interprets
3658 <a href="typesetting.html#t-margin">T_MARGIN</a>
3659 and
3660 <a href="typesetting.html#b-margin">B_MARGIN</a>
3661 in document processing.  Additionally, see
3662 <a href="#add-space">ADD_SPACE</a>
3663 if you encounter the problem of trying to get mom to put space at
3664 the tops of pages after the first.)
3665 </p>
3666 <div id="behaviour-specific" class="box-code" style="margin-left: 24px;">
3667 <span class="pre" style="color: #302419;">
3668   MACRO       EFFECT DURING DOCUMENT PROCESSING
3669   -----       ---------------------------------
3670
3671   L_MARGIN    &bull;The left margin of all running text
3672                assumes the new value.
3673
3674               &bull;The line length remains unaltered.
3675
3676               &bull;The header and footer left margin
3677                remain at the current document default.
3678
3679               (You won&#8217;t use this often by itself.  Most
3680                likely, you&#8217;ll use it in combination with
3681                R_MARGIN or LL.)
3682
3683   R_MARGIN    &bull;The right margin of all running text
3684                assumes the new value.  In other words,
3685                the line length is altered.
3686
3687               &bull;The header and footer right margin
3688                remain at the current document default.
3689
3690   LL          &bull;The line length of all running text
3691                is set to the new value.
3692
3693               &bull;The header and footer line length remain
3694                at the current document default.
3695
3696   FAMILY      &bull;Changes family for the duration of the
3697                current tag only.  As soon as another document
3698                element tag is invoked, the family reverts to
3699                the current default for the new tag.
3700
3701   FT          &bull;Changes font for the duration of the
3702                current tag only.  As soon as another document
3703                element tag is entered, the font reverts
3704                to the current default for the new tag.
3705
3706                N.B. &mdash; \*[SLANT] and \*[BOLDER] affect
3707                paragraph text, and remain in effect for all
3708                paragraphs until turned off.  If you want to
3709                use them in a macro that takes a string
3710                argument, include the escape in the string.
3711                \*[COND] and \*[EXT] behave similarly.
3712
3713   PT_SIZE     &bull;Changes point size for the duration of the
3714                current tag only.  As soon as another document
3715                element tag is entered, the point size reverts
3716                to the current document default for the new
3717                tag.
3718
3719   LS          &bull;Changes line space for the duration of the
3720                current tag only.  As soon as another document
3721                element tag is entered, the line space reverts
3722                to the current document default for the new
3723                tag.
3724
3725                Using LS to temporarily change leading within
3726                a document will almost certainly result in a
3727                bottom margin that doesn&#8217;t align with the
3728                bottom margin of subsequent pages.  You&#8217;ll
3729                need to use the SHIM or FLEX macro to get mom back
3730                on track when you&#8217;re ready to return to the
3731                document&#8217;s default leading.
3732
3733   <a id="autolead" style="margin-top: -1em">AUTOLEAD</a>   &bull;Invoked before START, sets the overall document
3734               leading as a function of the overall document
3735               point size (ie the point size used in paragraphs);
3736               subsequently disabled after START, except for calls
3737               to DOC_PT_SIZE
3738
3739              &bull;DOC_LEAD before DOC_PT_SIZE cancels the AUTOLEAD
3740               set before START
3741
3742              &bull;Invoked after START, remains in effect for all
3743               subsequent point size changes made with PT_SIZE,
3744               but does not affect the leading of the document
3745               element tags (e.g., HEADING, PP, QUOTE...), or calls
3746               to DOC_PT_SIZE
3747
3748   QUAD        &bull;Changes quad for the duration of the
3749                current tag only.  As soon as another document
3750                element tag is entered, the quad reverts to
3751                the current document default for the new
3752                tag.
3753
3754                N.B. &mdash; Line-for-line quadding macros
3755                (LEFT, CENTER, RIGHT) are also temporary,
3756                overridden by the QUAD value of any subsequent
3757                document element tag.
3758 </span>
3759 </div>
3760
3761 <h3 id="tb-margins" class="docs" style="margin-top: 1.5em;">Top and bottom margins in document processing</h3>
3762
3763 <p>
3764 Normally, mom establishes the top and bottom
3765 margins of
3766 <a href="definitions.html#running">running text</a>
3767 in documents from the values of <b>HEADER_MARGIN +
3768 HEADER_GAP</b> and <b>FOOTER_MARGIN + FOOTER_GAP</b>
3769 respectively.  However, if you invoke
3770 <a href="typesetting.html#t-margin">T_MARGIN</a>
3771 or
3772 <a href="typesetting.html#b-margin">B_MARGIN</a>
3773 either before or after
3774 <a href="docelement.html#start">START</a>,
3775 they set the top and bottom margins of running text irrespective of
3776 HEADER_GAP and FOOTER_GAP.
3777 </p>
3778
3779 <p>
3780 Put another way, in document processing, T_MARGIN
3781 and B_MARGIN set the top and bottom margins of
3782 running text, but have no effect on the placement of
3783 <a href="definitions.html#header">headers</a>,
3784 <a href="definitions.html#footer">footers</a>,
3785 or page numbers.
3786 </p>
3787
3788 <!-- ==================================================================== -->
3789
3790 <h3 id="space" class="docs">Inserting space at the top of a new page</h3>
3791
3792 <p>
3793 Occasionally, you may want to insert space before the start of
3794 <a href="definitions.html#running">running text</a>
3795 on pages after the first.
3796 </p>
3797
3798 <p>
3799 You might have tried using
3800 <a href="typesetting.html#ald">ALD</a>
3801 or
3802 <a href="typesetting.html#space">SPACE</a>
3803 and found it did nothing.  This is because mom normally inhibits
3804 any extra space before the start of running text on pages after the
3805 first.
3806 </p>
3807
3808 <p>
3809 If you need the space, you must use the macro ADD_SPACE in
3810 conjunction with
3811 <a href="typesetting.html#newpage">NEWPAGE</a>.
3812 </p>
3813
3814 <!-- -ADD_SPACE- -->
3815
3816 <div class="macro-id-overline">
3817 <h3 id="add-space" class= "macro-id">ADD_SPACE/RESTORE_SPACE</h3>
3818 </div>
3819
3820 <div class="box-macro-args">
3821 Macro: <b>ADD_SPACE</b> <kbd class="macro-args">&lt;amount of space&gt;</kbd>
3822 <br/>
3823 Macro: <b>RESTORE_SPACE</b>
3824 </div>
3825
3826 <p class="requires">
3827 &bull;&nbsp;Requires a <a href="definitions.html#unitofmeasure">unit of measure</a>
3828 </p>
3829
3830 <p>
3831 If your
3832 <a href="#doctype">DOCTYPE</a>
3833 is DEFAULT, CHAPTER, NAMED, or LETTER, ADD_SPACE takes as its
3834 single argument the distance you want mom to advance from the normal
3835 baseline position at the top of any page <i>after the first</i> (ie
3836 the one on which the docheader is normally printed).  A
3837 <a href="definitions.html#unitofmeasure">unit of measure</a> is
3838 required.
3839 </p>
3840
3841 <p>
3842 For example, say you wanted to insert 2 inches of space before the
3843 start of
3844 <a href="definitions.html#running">running text</a>
3845 on a page other than the first.  You&#8217;d accomplish it with
3846 <br/>
3847 <span class="pre-in-pp">
3848   .NEWPAGE
3849   .ADD_SPACE 2i
3850 </span>
3851 which would terminate your current page, break to a new page, print
3852 the header (assuming headers are on) and insert 2 inches of space
3853 before the start of running text.
3854 </p>
3855
3856 <p>
3857 Since adding space in this way is almost sure to disrupt mom&#8217;s
3858 ability to guarantee perfectly flush bottom margins, I highly
3859 recommend using the
3860 <a href="docprocessing.html#shim">SHIM</a>
3861 or
3862 <a href="docprocessing.html#flex">FLEX</a>
3863 macro immediately after ADD_SPACE, which will add the space plus
3864 whatever correction is required by the
3865 <a href="docprocessing.html#vertical-whitespace-management">vertical whitespace management</a>
3866 strategy in effect.
3867 </p>
3868
3869 <p>
3870 If your
3871 <a href="#doctype">DOCTYPE</a>
3872 is SLIDES, ADD_SPACE may be used on any slide <i>including the
3873 first</i> to introduce additional white space at the top.
3874 </p>
3875
3876 <h4 class="docs doc-param-macros" style="margin-top: .5em">RESTORE_SPACE</h4>
3877
3878 <p style="margin-top: .5em">
3879 You may sometimes find that mom refuses to respect
3880 <a href="typesetting.html#space">SP</a>,
3881 <a href="typesetting.html#index-aldrld">ALD/RLD</a>,
3882 <a href="docprocessing.html#shim">SHIM</a>,
3883 or
3884 <a href="docprocessing.html#flex">FLEX</a>
3885 after the first element (line of text, floated material) output
3886 at the top of a page.  Should this happen, insert the macro
3887 RESTORE_SPACE before issuing the spacing command.
3888 </p>
3889
3890 <!-- *** -->
3891
3892 <h2 id="intro-doc-param" class="macro-group">Changing document-wide style parameters after START</h2>
3893
3894 <p>
3895 In the normal course of things, you establish the basic type style
3896 parameters of a document prior to invoking
3897 <a href="#start">START</a>,
3898 using the
3899 <a href="typesetting.html#macros-typesetting">typesetting macros</a>
3900 (<b>L_MARGIN, FAMILY, PT_SIZE, LS,</b> etc).  After START, you must
3901 use the following macros if you wish to make global changes to the
3902 basic type style parameters, for example changing the overall leading or
3903 the justification style.
3904 </p>
3905
3906 <div class="box-important">
3907 <p class="tip">
3908 <span class="important">Important:</span>
3909 Because these macros globally update the chosen parameter, they
3910 should only be used immediately prior to
3911 <a href="rectoverso.html#collate">COLLATE</a>
3912 or, if an occasional effect is desired,
3913 <a href="typesetting.html#newpage">NEWPAGE</a>.
3914 <a href="#doc-pt-size">DOC_PT_SIZE</a>,
3915 for example, updates the point size of every page element, including
3916 headers, footers, page numbers, and so on, which is almost certainly
3917 not what you want in the middle of a page.
3918 </p>
3919 </div>
3920
3921 <div class="macro-list-container">
3922 <h3 id="index-doc-param" class="macro-list">Post-START global style change macros</h3>
3923 <ul class="macro-list">
3924   <li><a href="#doc-left-margin">DOC_LEFT_MARGIN</a></li>
3925   <li><a href="#doc-right-margin">DOC_RIGHT_MARGIN</a></li>
3926   <li><a href="#doc-line-length">DOC_LINE_LENGTH</a></li>
3927   <li><a href="#doc-family">DOC_FAMILY</a></li>
3928   <li><a href="#doc-pt-size">DOC_PT_SIZE</a></li>
3929   <li><a href="#doc-lead">DOC_LEAD</a></li>
3930   <li><a href="#doc-lead-adjust">DOC_LEAD_ADJUST</a></li>
3931   <li><a href="#doc-quad">DOC_QUAD</a></li>
3932 </ul>
3933 </div>
3934
3935 <!-- -DOC_LEFT_MARGIN -->
3936
3937 <div class="macro-id-overline">
3938 <h3 id="doc-left-margin" class="macro-id">DOC_LEFT_MARGIN</h3>
3939 </div>
3940
3941 <div class="box-macro-args">
3942 Macro: <b>DOC_LEFT_MARGIN</b> <kbd class="macro-args">&lt;left margin&gt;</kbd>
3943 </div>
3944
3945 <p class="requires">
3946 &bull;&nbsp;Requires a <a href="definitions.html#unitofmeasure">unit of measure</a>
3947 </p>
3948
3949 <h4 class="docs doc-param-macros">Arguments and behaviour</h4>
3950
3951 <ul class="doc-param-macros">
3952   <li>the argument is the same as for
3953       <a href="typesetting.html#l-margin">L_MARGIN</a>
3954   </li>
3955   <li>changes all left margins, including headers, footers, and page
3956       numbers to the new value
3957   </li>
3958   <li>any document elements that use a left indent calculate
3959       the indent from the new value
3960   </li>
3961   <li>the line length remains the same (ie the right margin
3962       shifts when you change the left margin)
3963   </li>
3964 </ul>
3965
3966 <!-- -DOC_RIGHT_MARGIN -->
3967
3968 <div class="macro-id-overline">
3969 <h3 id="doc-right-margin" class="macro-id">DOC_RIGHT_MARGIN</h3>
3970 </div>
3971
3972 <div class="box-macro-args">
3973 Macro: <b>DOC_RIGHT_MARGIN</b> <kbd class="macro-args">&lt;right margin&gt;</kbd>
3974 </div>
3975
3976 <p class="requires">
3977 &bull;&nbsp;Requires a <a href="definitions.html#unitofmeasure">unit of measure</a>
3978 </p>
3979
3980 <h4 class="docs doc-param-macros">Arguments and behaviour</h4>
3981
3982 <ul class="doc-param-macros">
3983   <li>the argument is the same as for
3984       <a href="typesetting.html#r-margin">R_MARGIN</a>
3985   </li>
3986   <li>changes all right margins, including headers, footers, and
3987       page numbers to the new value;
3988   </li>
3989   <li>any document elements that use a right indent calculate
3990       the indent from the new value
3991   </li>
3992 </ul>
3993
3994 <!-- -DOC_RIGHT_MARGIN -->
3995
3996 <div class="macro-id-overline">
3997 <h3 id="doc-line-length" class="macro-id">DOC_LINE_LENGTH</h3>
3998 </div>
3999
4000 <div class="box-macro-args">
4001 Macro: <b>DOC_LINE_LENGTH</b> <kbd class="macro-args">&lt;length&gt;</kbd>
4002 </div>
4003
4004 <p class="requires">
4005 &bull;&nbsp;Requires a <a href="definitions.html#unitofmeasure">unit of measure</a>
4006 </p>
4007
4008 <h4 class="docs doc-param-macros">Arguments and behaviour</h4>
4009
4010 <ul class="doc-param-macros">
4011   <li>the argument is the same as for
4012       <a href="typesetting.html#linelength">LL</a>
4013   </li>
4014   <li>exactly equivalent to changing the right margin with
4015       DOC_RIGHT_MARGIN (see
4016       <a href="#doc-right-margin">above</a>);
4017   </li>
4018 </ul>
4019
4020 <!-- -DOC_FAMILY- -->
4021
4022 <div class="macro-id-overline">
4023 <h3 id="doc-family" class="macro-id">DOC_FAMILY</h3>
4024 </div>
4025
4026 <div class="box-macro-args">
4027 Macro: <b>DOC_FAMILY</b> <kbd class="macro-args">&lt;family&gt;</kbd>
4028 </div>
4029
4030 <h4 class="docs doc-param-macros" style="margin-top: 1em;">Arguments and behaviour</h4>
4031
4032 <ul class="doc-param-macros">
4033   <li>the argument is the same as for
4034       <a href="typesetting.html#family">FAMILY</a>
4035   </li>
4036   <li>globally changes the type family for
4037   <ul>
4038     <li style="margin-left: -.5em;">the <a href="definitions.html#docheader">docheader</a></li>
4039     <li style="margin-left: -.5em;">all <a href="docelement.html#index-docelement">document element tags</a>, including footnotes</li>
4040     <li style="margin-left: -.5em;"><a href="definitions.html#header">headers and/or footers</a></li>
4041     <li style="margin-left: -.5em;"><a href="docelement.html#number-lines-intro">line numbering</a></li>
4042     <li style="margin-left: -.5em;"><a href="headfootpage.html#pagination">page numbering</a></li>
4043   </ul></li>
4044   <li>does <i>not</i> change the family of
4045   <ul>
4046       <li><a href="cover.html#doc-cover">document cover pages</a></li>
4047       <li><a href="cover.html#cover">cover pages</a></li>
4048       <li><a href="docelement.html#endnote-intro">endnotes pages</a></li>
4049       <li><a href="docelement.html#toc-intro">table of contents</a></li>
4050   </ul></li>
4051   <li>any page elements (e.g., headers page numbers, footnotes) whose
4052       families you wish to remain at their old values must be
4053       reset with the appropriate
4054       <a href="docelement.html#docelement-control">control macros</a>
4055   </li>
4056 </ul>
4057
4058 <!-- -DOC_PT_SIZE- -->
4059
4060 <div class="macro-id-overline">
4061 <h3 id="doc-pt-size" class="macro-id">DOC_PT_SIZE</h3>
4062 </div>
4063
4064 <div class="box-macro-args">
4065 Macro: <b>DOC_PT_SIZE</b> <kbd class="macro-args">&lt;point size&gt;</kbd>
4066 </div>
4067
4068 <p class="requires">
4069 &bull;&nbsp;Does not require a <a href="definitions.html#unitofmeasure">unit of measure</a>; points is assumed
4070 </p>
4071
4072 <h4 class="docs doc-param-macros">Arguments and behaviour</h4>
4073
4074 <ul class="doc-param-macros">
4075   <li>the argument is the same as for
4076       <a href="typesetting.html#ps">PT_SIZE</a>,
4077       and refers to the point size of type in paragraphs
4078   </li>
4079   <li>all automatic point size changes (heads, quotes,
4080       footnotes, headers, etc.) are affected by the new size;
4081       anything you do not want affected must be reset to
4082       its former value (see the Control Macros section of
4083       the pertinent document element for instructions on
4084       how to do this)
4085   </li>
4086   <li>if
4087       <a href="typesetting.html#autolead">AUTOLEAD</a>
4088       was invoked before START; the value of AUTOLEAD will be used
4089       to update the leading of all document element tags except
4090       FOOTNOTE and EPIGRAPH
4091   </li>
4092 </ul>
4093
4094 <!-- -DOC_LEAD- -->
4095
4096 <div class="macro-id-overline">
4097 <h3 id="doc-lead" class="macro-id">DOC_LEAD</h3>
4098 </div>
4099
4100 <div class="box-macro-args">
4101 Macro: <b>DOC_LEAD</b> <kbd class="macro-args">&lt;points&gt; [ ADJUST ]</kbd>
4102 </div>
4103
4104 <p class="requires">
4105 &bull;&nbsp;Does not require a <a href="definitions.html#unitofmeasure">unit of measure</a>; points is assumed
4106 </p>
4107
4108 <h4 class="docs doc-param-macros">Arguments and behaviour</h4>
4109
4110 <ul class="doc-param-macros">
4111   <li>the argument is the same as for
4112       <a href="typesetting.html#leading">LS</a>,
4113       and refers to the
4114       <a href="definitions.html#lead">leading</a>
4115       of paragraphs
4116   </li>
4117   <li>because paragraphs will have a new leading, the leading and
4118       spacing of most running text is influenced by the new value
4119   </li>
4120   <li>epigraphs and footnotes remain unaffected;
4121       if you wish to change their leading, use
4122       <a href="docelement.html#epigraph-autolead">EPIGRAPH_AUTOLEAD</a>
4123       and
4124       <a href="docelement.html#footnote-autolead">FOOTNOTE_AUTOLEAD</a>.
4125   </li>
4126   <li>the optional argument <kbd>ADJUST</kbd> performs
4127       leading adjustment as explained in
4128       <a href="#doc-lead-adjust">DOC_LEAD_ADJUST</a>
4129   </li>
4130   <li>if
4131       <a href="typesetting.html#autolead">AUTOLEAD</a>
4132       was invoked before START; the value of that AUTOLEAD will be
4133       cancelled
4134   </li>
4135 </ul>
4136
4137 <div class="box-tip">
4138 <p class="tip">
4139 <span class="note">Note:</span>
4140 Even if you don&#8217;t pass DOC_LEAD the optional argument
4141 <kbd>ADJUST</kbd>, mom will still adjust the leading of endnotes
4142 pages and toc pages.  See
4143 <a href="docelement.html#endnote-lead">ENDNOTE_LEAD</a>
4144 and
4145 <a href="docelement.html#toc-lead">TOC_LEAD</a>
4146 for an explanation of how to disable this default behaviour.
4147 </p>
4148 </div>
4149
4150 <!-- -DOC_QUAD- -->
4151
4152 <div class="macro-id-overline">
4153 <h3 id="doc-quad" class="macro-id">DOC_QUAD</h3>
4154 </div>
4155
4156 <div class="box-macro-args">
4157 Macro: <b>DOC_QUAD</b> <kbd class="macro-args">L | R | C | J</kbd>
4158 </div>
4159
4160 <h4 class="docs doc-param-macros" style="margin-top: 1em;">Arguments and behaviour</h4>
4161
4162 <ul class="doc-param-macros">
4163   <li>the arguments are the same as for
4164       <a href="typesetting.html#quad">QUAD</a>
4165   </li>
4166   <li>affects paragraphs, epigraphs and footnotes; does not
4167       affect blockquotes
4168   </li>
4169 </ul>
4170
4171 <h2 id="terminating" class="macro-group">Terminating a document</h2>
4172
4173 <p>
4174 You need do nothing special to terminate a document.  When groff
4175 finishes processing the last
4176 <a href="definitions.html#inputline">input line</a>
4177 of a file, the page is ejected, subject to whatever routines are
4178 needed to complete it (e.g., printing footnotes or adding the page
4179 number).
4180 </p>
4181
4182 <p>
4183 It happens sometimes, however, that a last line of
4184 <a href="definitions.html#running">running text</a>,
4185 falling on or very near the bottom of the page, tricks groff into
4186 breaking to a new page before terminating.  The result is a blank
4187 page at the end of the formatted document.
4188 </p>
4189
4190 <p>
4191 The situation is rare, generally occurring only when some additional
4192 macro is required after the input text, e.g., to exit a
4193 <a href="docelement.html#list-intro">list</a>
4194 or terminate a
4195 <a href="docelement.html#quote">quote</a>.
4196 To prevent it from ever happening, I recommend getting into the habit
4197 of following the final input line of all your mom files with
4198 <a href="typesetting.html#el"><kbd>.EL</kbd></a>.
4199 Depending on the
4200 <a href="definitions.html#filled">fill mode</a>
4201 in effect, you may also have to append the &#8220;join line&#8221;
4202 <a href="definitions.html#inlines">escape</a>,
4203 <kbd>\c</kbd>, to the final line.</p>
4204
4205 <p>
4206 Thus, for normal text at the end of a paragraph, which is in fill
4207 mode,
4208 <br/>
4209 <span class="pre-in-pp">
4210   and they all lived happily ever after.
4211   .EL
4212 </span>
4213 or for ending a 
4214 <a href="docelement.html#list-intro">LIST</a>
4215 (also in fill mode)
4216 <span class="pre-in-pp">
4217   .ITEM
4218   peaches, pears, plums
4219   .EL
4220   .LIST OFF
4221 </span>
4222 whereas, at the end of a
4223 <a href="docelement.html#quote-intro">QUOTE</a>
4224 (which is in nofill mode),
4225 <span class="pre-in-pp">
4226   Shall be lifted\[em]nevermore!\c
4227   .EL
4228   .QUOTE OFF
4229 </span>
4230 Notice that the <kbd>.EL</kbd> comes after the last line of input
4231 text, not any macros following.
4232 </p>
4233
4234 <div class="box-tip">
4235 <p class="tip">
4236 <span class="note">Note:</span>
4237 <a href="inlines.html#b"><kbd>\*[B]</kbd></a>
4238 cannot be used as a replacement for <kbd>.EL</kbd> when terminating
4239 a document.
4240 </p>
4241 </div>
4242
4243 <!-- Navigation links -->
4244 <table style="width: 100%; margin-top: 12px;">
4245 <tr>
4246   <td style="width: 33%;"><a href="toc.html">Back to Table of Contents</a></td>
4247   <td style="width: 24%; text-align: center;"><a href="#top">Top</a></td>
4248   <td style="width: 43%; text-align: right;"><a href="docelement.html#top">Next: The document element tags</a></td>
4249 </tr>
4250 </table>
4251
4252 </div>
4253
4254 <div class="bottom-spacer"><br/></div>
4255
4256 </body>
4257 </html>