typo
[s-roff.git] / tmac / an-old.tmac
blob063ebce50d37e78a17a97e7a73f1fe7b2116ef1b
1 .\" an-old.tmac
2 .\"
3 .\" Copyright (C) 1989, 1990, 1991, 1992, 2001, 2002, 2003
4 .\"   Free Software Foundation, Inc.
5 .\"      Written by James Clark (jjc@jclark.com)
6 .\"
7 .\" This file is part of groff.
8 .\"
9 .\" groff is free software; you can redistribute it and/or modify it under
10 .\" the terms of the GNU General Public License as published by the Free
11 .\" Software Foundation; either version 2, or (at your option) any later
12 .\" version.
13 .\"
14 .\" groff is distributed in the hope that it will be useful, but WITHOUT ANY
15 .\" WARRANTY; without even the implied warranty of MERCHANTABILITY or
16 .\" FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
17 .\" for more details.
18 .\"
19 .\" You should have received a copy of the GNU General Public License along
20 .\" with groff; see the file COPYING.  If not, write to the Free Software
21 .\" Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
22 .\"
23 .\"  -rcR=1 => Create a single, very long page instead of multiple pages.
24 .\"            Useful for online display.  Default in nroff mode.
25 .\"            Desactivate with -rcR=0.
26 .\"  -rC1 => Number pages continuously, rather than start each at 1.
27 .\"  -rD1 => Double-sided printing, ie different odd and even page footers.
28 .\"  -rPnnn => Number first page nnn.
29 .\"  -rSxx => Use size `xx'pt (either 10, 11, or 12) for document rather
30 .\"           than the default size of 10pt.
31 .\"  -rXnnn => Number pages after nnn as nnna, nnnb, nnnc, ...
32 .\"
33 .\" The file man.local is loaded at the end.  Put local additions there.
34 .\" If you need to add things to TH, use `.am1 TH'.
35 .\"
37 .if !\n(.g .ab These man macros work only with groff.
39 .do if d RI .nx
41 .nr _C \n(.C
42 .cp 0
44 .if (\n[.x]\n[.y] < 118) \
45 .  ab You need GNU troff version 1.18 or higher to run this version of man!
47 .if !r D .nr D 0
48 .if !r C .nr C 0
49 .if !r S .nr S 10
50 .\" we must use consecutive page numbers when using postscript to generate
51 .\" html images, and we must not reset the page number at the beginning
52 .\" (the `ps4html' register is automatically added to the command line by
53 .\" the pre-html preprocessor)
54 .if !r ps4html \
55 .  if r P .pn 0\n[P]
56 .if !r cR \{\
57 .  ie n .nr cR 1
58 .  el   .nr cR 0
59 .\}
61 .if !r LL \{\
62 .  ie n .nr LL 78n
63 .  el   .nr LL 6.5i
64 .\}
65 .if !r LT \
66 .  nr LT \n[LL]
68 .nr FT -.5i
70 .\" Default heading font
71 .ds HF B
73 .nr an-first 1
75 .nr an-html 0
76 .if '\*[.T]'html' .nr an-html 1
77 .if \n[an-html] .nr C 1
78 .if r ps4html .nr C 1
80 .\" we redefine .ne to avoid page breaks; instead, the page length is
81 .\" increased to the necessary amount (this is needed for tables)
82 .if n \{\
83 .  de1 ne
84 .    ie \\n[.$] \
85 .      nr an-ne \\$*
86 .    el \
87 .      nr an-ne 1v
88 .    if (\\n[an-ne] >= \\n[.t]) \
89 .      pl +(\\n[an-ne]u - \\n[.t]u + 1v)
90 .  .
91 .\}
93 .de set-an-margin
94 .  nr an-margin \\n[IN]
97 .\" .TH title section extra1 extra2 extra3
98 .de1 TH
99 .  if \\n[an-html] \{\
100 .    HTML-TAG-NS ".tl"
101 \\$1
102 .  \}
104 .  de an-init \" We have to do it like this to get multiple man pages right.
105 .    ds an-title "\\$1
106 .    ds an-section "\\$2
107 .    ds an-extra1 "\\$3
108 .    ie (\\n[.$] > 3) .ds an-extra2 "\\$4
109 .    el               .ds an-extra2 \"Sun Release 4.0
110 .    ie (\\n[.$] > 4) .ds an-extra3 "\\$5
111 .    el               .ds an-extra3 \"System Programmer's Manual
112 .    ds an-init
113 \\..
115 .  DT
117 .  nr PS    10z \" default point size
118 .  nr PS-SS 10z
119 .  nr PS-SH 10.95z
120 .  nr VS    12p
122 .  \" use sizes similar to LaTeX
123 .  if t \{\
124 .    ie (\\n[S] == 11) \{\
125 .      nr PS    10.95z
126 .      nr PS-SS 10.95z
127 .      nr PS-SH 12z
128 .      nr VS    13.6p
129 .    \}
130 .    el \{\
131 .      if (\\n[S] == 12) \{\
132 .        nr PS    12z
133 .        nr PS-SS 12z
134 .        nr PS-SH 14.4z
135 .        nr VS    14.5p
136 .      \}
137 .    \}
138 .  \}
140 .  ps \\n[PS]u
141 .  vs \\n[VS]u
142 .  ll \\n[LL]u
144 .\" We must select an integer indentation value for nroff;
145 .\" see comment in an-do-tag.
146 .  if !r IN \{\
147 .    ie t .nr IN 7.2n
148 .    el   .nr IN 7n
149 .  \}
150 .  PD
151 .  if !r SN \
152 .    nr SN 3n \" the indentation of sub-sub-headings relative to sub-headings
153 .  nr an-level 1
154 .  set-an-margin
155 .  nr an-prevailing-indent \\n[IN]
156 .  nr an-tag-sep 1n
158 .  nr an-no-space-flag 0
159 .  nr an-break-flag 0
160 .  nr an-div? 0
162 .  ie \\n[cR] \
163 .    an-header
164 .  el \{\
165 .    wh 0 an-header
166 .    wh -1i an-footer
167 .    wh \\n[FT]u an-p-footer
169 .    if (\\n[nl] > 0) \{\
170 .      ie \\n[C] .bp (\\n[%] + 1)
171 .      el        .bp 1
172 .    \}
173 .  \}
176 .\" BSD compatibility macros: .AT and .UC
178 .de1 AT
179 .  ds an-extra2 "7th Edition
180 .  if "\\$1"3" .ds an-extra2 "7th Edition
181 .  if "\\$1"4" .ds an-extra2 "System III
182 .  if "\\$1"5" \{\
183 .    ie "\\$2"" .ds an-extra2 "System V
184 .    el .ds an-extra2 "System V Release \\$2
185 .  \}
188 .de1 UC
189 .  ds an-extra2 "3rd Berkeley Distribution
190 .  if "\\$1"3" .ds an-extra2 "3rd Berkeley Distribution
191 .  if "\\$1"4" .ds an-extra2 "4th Berkeley Distribution
192 .  if "\\$1"5" .ds an-extra2 "4.2 Berkeley Distribution
193 .  if "\\$1"6" .ds an-extra2 "4.3 Berkeley Distribution
194 .  if "\\$1"7" .ds an-extra2 "4.4 Berkeley Distribution
197 .de1 DT
198 .  ta T .5i \" This sets tabs every .5 inches
201 .de1 PD
202 .  ie \\n[.$] .nr PD (v;\\$1)
203 .  el         .nr PD (.4v >? \n[.V])
206 .\" Redefine these to customize the header & footer
208 .de1 PT
209 .  tl '\\*[an-title](\\*[an-section])'\\*[an-extra3]'\\*[an-title](\\*[an-section])'
212 .de1 BT
213 .  if r ps4html \
214 .    return
215 .  ie \\n[D] \{\
216 .    if o .tl '\\*[an-extra2]'\\*[an-extra1]'\\*[an-page-string]'
217 .    if e .tl '\\*[an-page-string]'\\*[an-extra1]'\\*[an-extra2]'
218 .  \}
219 .  el \
220 .    tl '\\*[an-extra2]'\\*[an-extra1]'\\*[an-page-string]'
223 .de1 an-header
224 .  an-init
225 .  if \\n[cR] \{\
226 .    ie \\n[an-first] \
227 .      nr an-first 0
228 .    el \
229 .      sp .5i
230 .  \}
231 .  ev 1
232 .  ps \\n[PS]u
233 .  vs \\n[VS]u
234 .  lt \\n[LT]u
235 .  ie \\n[an-html] \
236 .    tl ''''
237 .  el \{\
238 .    if !\\n[cR] \
239 .      sp .5i
240 .    PT
241 .    ie !\\n[cR] \
242 .      sp |1i
243 .    el \
244 .      sp .5i
245 .  \}
246 .  ev
247 .  ns
250 .de1 an-footer
251 '  bp
254 .af an-page-letter a
256 .de1 an-p-footer
257 .  ev 1
258 .  ps \\n[PS]u
259 .  vs \\n[VS]u
260 .  lt \\n[LT]u
261 .  ie \\n[an-html] \{\
262 .    ds an-page-string
263 .    ds an-extra1
264 .    ds an-extra2
265 .  \}
266 .  el \{\
267 .    ie r X \{\
268 .      if (\\n[%] > \\n[X]) \{\
269 .        nr an-page-letter (\\n[%] - \\n[X])
270 .        ds an-page-string \\n[X]\\n[an-page-letter]
271 .      \}
272 .    \}
273 .    el \{\
274 .      ie \\n[cR] \
275 .        ds an-page-string "\\*[an-title](\\*[an-section])
276 .      el \
277 .        ds an-page-string \\n[%]
278 .    \}
279 .  \}
280 .  BT
281 .  ev
284 .de1 an-end
285 .  nr % 1
286 .  pl +4v
287 .  fl
288 .  sp 3
289 .  an-p-footer
290 .  pl \\n[nl]u
293 .if \n[cR] .em an-end
295 .de1 SH
296 .  sp \\n[PD]u
297 .  nr an-level 1
298 .  set-an-margin
299 .  nr an-prevailing-indent \\n[IN]
300 .  fi
301 .  in \\n[an-margin]u
302 .  ti 0
303 .  HTML-TAG-NS ".NH \\n[an-level]"
304 .  it 1 an-trap
305 .  nr an-no-space-flag 1
306 .  nr an-break-flag 1
307 .  ps \\n[PS-SH]u
308 .  ft \\*[HF]
309 .  ne (2v + 1u)
310 .  if \\n[.$] \&\\$*
313 .de1 SS
314 .  sp \\n[PD]u
315 .  nr an-level 1
316 .  set-an-margin
317 .  nr an-prevailing-indent \\n[IN]
318 .  fi
319 .  in \\n[IN]u
320 .  ti \\n[SN]u
321 .  it 1 an-trap
322 .  nr an-no-space-flag 1
323 .  nr an-break-flag 1
324 .  ps \\n[PS-SS]u
325 .  ft \\*[HF]
326 .  ne (2v + 1u)
327 .  if \\n[.$] \&\\$*
330 .de1 B
331 .  it 1 an-trap
332 .  ft B
333 .  if \\n[.$] \&\\$*
336 .de1 I
337 .  it 1 an-trap
338 .  ft I
339 .  if \\n[.$] \,\\$*\/
342 .de1 SM
343 .  it 1 an-trap
344 .  ps -1
345 .  if \\n[.$] \&\\$*
348 .de1 SB
349 .  it 1 an-trap
350 .  ps -1
351 .  ft B
352 .  if \\n[.$] \&\\$*
355 .de1 TP
356 .  sp \\n[PD]u
357 .  if \\n[.$] .nr an-prevailing-indent (n;\\$1)
358 .  it 1 an-trap
359 .  in 0
360 .  ll -\\n[an-margin]u
361 .  if !\\n[an-div?] .di an-div
362 .  nr an-div? 1
365 .de1 an-trap
366 .  ft R
367 .  ps \\n[PS]u
368 .  vs \\n[VS]u
369 .  if \\n[an-break-flag] \{\
370 .    br
371 .    nr an-break-flag 0
372 .  \}
373 .  if \\n[an-no-space-flag] \{\
374 .    ns
375 .    nr an-no-space-flag 0
376 .  \}
377 .  if \\n[an-div?] .an-do-tag
380 .de an-do-tag
381 .  br
382 .  di
383 .  nr an-div? 0
384 .  ll
385 .  ie (\\n[dl] + \\n[an-tag-sep] > \\n[an-prevailing-indent]) \{\
386 .    in \\n[an-margin]u
387 .    ne (2v + 1u)
388 .    an-div
389 .    in (\\n[an-margin]u + \\n[an-prevailing-indent]u)
390 .  \}
391 .  el \{\
392 .    \" In nroff mode, if the indentation value is not an integer multiple
393 .    \" of the character cell, it is possible that the following combination
394 .    \" of .in and .ti yields a different result as the .in request in
395 .    \" the .ie part above.
396 .    in (\\n[an-margin]u + \\n[an-prevailing-indent]u)
397 .    ti -\\n[an-prevailing-indent]u
398 .    chop an-div
399 .    ne (1v + 1u)
400 .    HTML-TAG-NS ".col 1"
401 \\*[an-div]\\h'|\\n[an-prevailing-indent]u'\c
402 .    HTML-TAG-NS ".col 2"
403 .  \}
406 .de1 LP
407 .  sp \\n[PD]u
408 .  ps \\n[PS]u
409 .  vs \\n[VS]u
410 .  ft R
411 .  in \\n[an-margin]u
412 .  nr an-prevailing-indent \\n[IN]
415 .als PP LP
416 .als P LP
418 .de1 IP
419 .  ie !\\n[.$] \{\
420 .    ps \\n[PS]u
421 .    vs \\n[VS]u
422 .    ft R
423 .    sp \\n[PD]u
424 .    ne (1v + 1u)
425 .    in (\\n[an-margin]u + \\n[an-prevailing-indent]u)
426 .  \}
427 .  el \{\
428 .    ie (\\n[.$] - 1) .TP "\\$2"
429 .    el               .TP
430 \&\\$1
431 .  \}
434 .de1 HP
435 .  ps \\n[PS]u
436 .  vs \\n[VS]u
437 .  ft R
438 .  sp \\n[PD]u
439 .  ne (1v + 1u)
440 .  if \\n[.$] .nr an-prevailing-indent (n;\\$1)
441 .  in (\\n[an-margin]u + \\n[an-prevailing-indent]u)
442 .  ti \\n[an-margin]u
445 .ds an-empty \" this is referenced to avoid looping on eg .RB ( \\ )
447 .de1 RI
448 .  if \\n[.$] \{\
449 .    ds an-result \&\\$1
450 .    shift
451 .    while (\\n[.$] >= 2) \{\
452 .      as an-result \,\f[I]\\$1\f[R]\/\\$2\\*[an-empty]
453 .      shift 2
454 .    \}
455 .    if \\n[.$] .as an-result \,\f[I]\\$1\f[R]
456 \\*[an-result]
457 .  \}
460 .de1 IR
461 .  if \\n[.$] \{\
462 .    ds an-result \&\f[I]\\$1\f[R]
463 .    shift
464 .    while (\\n[.$] >= 2) \{\
465 .      as an-result \/\\$1\f[I]\,\\$2\f[R]
466 .      shift 2
467 .    \}
468 .    if \\n[.$] .as an-result \/\\$1
469 \\*[an-result]
470 .  \}
473 .de1 IB
474 .  if \\n[.$] \{\
475 .    ds an-result \&\f[I]\\$1
476 .    shift
477 .    while (\\n[.$] >= 2) \{\
478 .      as an-result \/\f[B]\\$1\f[I]\,\\$2\\*[an-empty]
479 .      shift 2
480 .    \}
481 .    if \\n[.$] .as an-result \/\f[B]\\$1
482 \\*[an-result]
483 .    ft R
484 .  \}
487 .de1 BI
488 .  if \\n[.$] \{\
489 .    ds an-result \&\f[B]\\$1
490 .    shift
491 .    while (\\n[.$] >= 2) \{\
492 .      as an-result \,\f[I]\\$1\f[B]\/\\$2\\*[an-empty]
493 .      shift 2
494 .    \}
495 .    if \\n[.$] .as an-result \,\f[I]\\$1
496 \\*[an-result]
497 .    ft R
498 .  \}
501 .de1 RB
502 .  ds an-result \&
503 .  while (\\n[.$] >= 2) \{\
504 .    as an-result \f[R]\\$1\f[B]\\$2\\*[an-empty]
505 .    shift 2
506 .  \}
507 .  if \\n[.$] .as an-result \f[R]\\$1
508 \\*[an-result]
509 .  ft R
512 .de1 BR
513 .  ds an-result \&
514 .  while (\\n[.$] >= 2) \{\
515 .    as an-result \f[B]\\$1\f[R]\\$2\\*[an-empty]
516 .    shift 2
517 .  \}
518 .  if \\n[.$] .as an-result \f[B]\\$1
519 \\*[an-result]
520 .  ft R
523 .de1 RS
524 .  nr an-saved-margin\\n[an-level] \\n[an-margin]
525 .  nr an-saved-prevailing-indent\\n[an-level] \\n[an-prevailing-indent]
526 .  ie \\n[.$] .nr an-margin +(n;\\$1)
527 .  el         .nr an-margin +\\n[an-prevailing-indent]
528 .  in \\n[an-margin]u
529 .  nr an-prevailing-indent \\n[IN]
530 .  nr an-level +1
533 .de1 RE
534 .  ie \\n[.$] .nr an-level ((;\\$1) <? \\n[an-level])
535 .  el         .nr an-level -1
536 .  nr an-level (1 >? \\n[an-level])
537 .  nr an-margin \\n[an-saved-margin\\n[an-level]]
538 .  nr an-prevailing-indent \\n[an-saved-prevailing-indent\\n[an-level]]
539 .  in \\n[an-margin]u
542 .\" table support
544 .de1 TS
545 .  sp \\n[PD]u
546 .  HTML-IMAGE
549 .de1 T&
552 .de1 TE
553 .  HTML-IMAGE-END
556 .\" dummy equation delimiters
557 .de1 EQ
558 .  HTML-IMAGE
560 .de1 EN
561 .  HTML-IMAGE-END
564 .de1 R
566 .  ie \\n[.$] \{\
567 .    tm `R' is a string (producing the registered sign), not a macro.
568 .    nop \\$*
569 .  \}
570 .  el \{\
571 .    ie c\[rg] \
572 .      nop \[rg]\c
573 .    el \
574 .      nop (Reg.)\c
575 .  \}
578 .\" these strings must work in compatibility mode also
580 .ds S \s'\\n(PSu'
581 .ie c\[tm] .ds Tm \(tm
582 .el        .ds Tm (TM)
583 .ds lq \(lq
584 .ds rq \(rq
586 .if !\n[an-html] \{\
587 .  if !rHY \{\
588 .    ie \n[cR] \
589 .      nr HY 12
590 .    el \
591 .      nr HY 14
592 .  \}
593 .  hy \n[HY]
596 .\" Load local modifications.
597 .mso man.local
599 .cp \n[_C]
601 .\" end of an-old.tmac