]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - contrib/groff/tmac/an-old.tmac
This commit was generated by cvs2svn to compensate for changes in r94334,
[FreeBSD/FreeBSD.git] / contrib / groff / tmac / an-old.tmac
1 .\" an-old.tmac
2 .\"
3 .\" Copyright (C) 1989, 1990, 1991, 1992, 2001 Free Software Foundation, Inc.
4 .\"      Written by James Clark (jjc@jclark.com)
5 .\"
6 .\" This file is part of groff.
7 .\"
8 .\" groff is free software; you can redistribute it and/or modify it under
9 .\" the terms of the GNU General Public License as published by the Free
10 .\" Software Foundation; either version 2, or (at your option) any later
11 .\" version.
12 .\"
13 .\" groff is distributed in the hope that it will be useful, but WITHOUT ANY
14 .\" WARRANTY; without even the implied warranty of MERCHANTABILITY or
15 .\" FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
16 .\" for more details.
17 .\"
18 .\" You should have received a copy of the GNU General Public License along
19 .\" with groff; see the file COPYING.  If not, write to the Free Software
20 .\" Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
21 .\"
22 .\"  -rcR=1 => Create a single, very long page instead of multiple pages.
23 .\"            Useful for online display.  Default in nroff mode.
24 .\"            Desactivate with -rcR=0.
25 .\"  -rC1 => Number pages continuously, rather than start each at 1.
26 .\"  -rD1 => Double-sided printing, ie different odd and even page footers.
27 .\"  -rPnnn => Number first page nnn.
28 .\"  -rSxx => Use size `xx'pt (either 10, 11, or 12) for document rather
29 .\"           than the default size of 10pt.
30 .\"  -rXnnn => Number pages after nnn as nnna, nnnb, nnnc, ...
31 .\"
32 .\" The file man.local is loaded at the end.  Put local additions there.
33 .\" If you need to add things to TH, use `.am TH'.
34 .\"
35 .
36 .if !\n(.g .ab These man macros work only with groff.
37 .
38 .nr _C \n(.C
39 .cp 0
40 .
41 .if (\n[.x]\n[.y]\n[.Y] < 1171) \
42 .  ab You need GNU troff version 1.17.1 or higher to run this version of man!
43 .
44 .if !r D .nr D 0
45 .if !r C .nr C 0
46 .if !r S .nr S 10
47 .\" we must use consecutive page numbers when using postscript to generate
48 .\" html images, and we must not reset the page number at the beginning
49 .\" (the `ps4html' register is automatically added to the command line by
50 .\" the pre-html preprocessor)
51 .if !r ps4html \
52 .  if r P .pn 0\n[P]
53 .if !r cR \{\
54 .  ie n .nr cR 1
55 .  el   .nr cR 0
56 .\}
57 .
58 .nr an-html 0
59 .if '\*[.T]'html' .nr an-html 1
60 .if \n[an-html] .nr C 1
61 .if r ps4html .nr C 1
62 .
63 .de set-an-margin
64 .  nr an-margin \\n[IN]
65 ..
66 .
67 .\" .TH title section extra1 extra2 extra3
68 .de1 TH
69 .  if \\n[an-html] \{\
70 .     HTML-TAG ".tl"
71 \\$1
72 .  \}
73 .
74 .  de an-init \" We have to do it like this to get multiple man pages right.
75 .    ds an-title "\\$1
76 .    ds an-section "\\$2
77 .    ds an-extra1 "\\$3
78 .    ie (\\n[.$] > 3) .ds an-extra2 "\\$4
79 .    el               .ds an-extra2 \"Sun Release 4.0
80 .    ie (\\n[.$] > 4) .ds an-extra3 "\\$5
81 .    el               .ds an-extra3 \"System Programmer's Manual
82 .    ds an-init
83 \\..
84 .
85 .  DT
86 .
87 .  nr PS    10z \" default point size
88 .  nr PS-SS 10z
89 .  nr PS-SH 10.95z
90 .  nr VS    12p
91 .
92 .  \" use sizes similar to LaTeX
93 .  if t \{\
94 .    ie (\\n[S] == 11) \{\
95 .      nr PS    10.95z
96 .      nr PS-SS 10.95z
97 .      nr PS-SH 12z
98 .      nr VS    13.6p
99 .    \}
100 .    el \{\
101 .      if (\\n[S] == 12) \{\
102 .        nr PS    12z
103 .        nr PS-SS 12z
104 .        nr PS-SH 14.4z
105 .        nr VS    14.5p
106 .      \}
107 .    \}
108 .  \}
109 .
110 .  ps \\n[PS]u
111 .  vs \\n[VS]u
112 .
113 .  nr IN 7.2n
114 .  PD
115 .  nr SN 3n \" the indentation of sub-sub-headings relative to sub-headings
116 .  nr an-level 1
117 .  set-an-margin
118 .  nr an-prevailing-indent \\n[IN]
119 .  nr an-tag-sep 1n
120 .
121 .  nr an-no-space-flag 0
122 .  nr an-break-flag 0
123 .  nr an-div? 0
124 .
125 .  ie \\n[cR] \
126 .    an-header
127 .  el \{\
128 .    wh 0 an-header
129 .    wh -1i an-footer
130 .    wh -.5i an-p-footer
131 .
132 .    if (\\n[nl] > 0) \{\
133 .      ie \\n[C] .bp (\\n[%] + 1)
134 .      el        .bp 1
135 .    \}
136 .  \}
137 ..
138 .
139 .\" BSD compatibility macros: .AT and .UC
140 .
141 .de1 AT
142 .  ds an-extra2 "7th Edition
143 .  if "\\$1"3" .ds an-extra2 "7th Edition
144 .  if "\\$1"4" .ds an-extra2 "System III
145 .  if "\\$1"5" \{\
146 .    ie "\\$2"" .ds an-extra2 "System V
147 .    el .ds an-extra2 "System V Release \\$2
148 .  \}
149 ..
150 .
151 .de1 UC
152 .  ds an-extra2 "3rd Berkeley Distribution
153 .  if "\\$1"3" .ds an-extra2 "3rd Berkeley Distribution
154 .  if "\\$1"4" .ds an-extra2 "4th Berkeley Distribution
155 .  if "\\$1"5" .ds an-extra2 "4.2 Berkeley Distribution
156 .  if "\\$1"6" .ds an-extra2 "4.3 Berkeley Distribution
157 .  if "\\$1"7" .ds an-extra2 "4.4 Berkeley Distribution
158 ..
159 .
160 .de1 DT
161 .  ta T .5i \" This sets tabs every .5 inches
162 ..
163 .
164 .de1 PD
165 .  ie \\n[.$] .nr PD (v;\\$1)
166 .  el         .nr PD (.4v >? \n[.V])
167 ..
168 .
169 .de1 an-header
170 .  an-init
171 .  ev 1
172 .  ps \\n[PS]u
173 .  vs \\n[VS]u
174 .  ie \\n[an-html] \
175 .    tl ''''
176 .  el \{\
177 .    if !\\n[cR] \
178 .      sp .5i
179 .    tl '\\*[an-title](\\*[an-section])'\\*[an-extra3]'\\*[an-title](\\*[an-section])'
180 .    ie !\\n[cR] \
181 .      sp |1i
182 .    el \
183 .      sp .5i
184 .  \}
185 .  ev
186 .  ns
187 ..
188 .
189 .de1 an-footer
190 '  bp
191 ..
192 .
193 .af an-page-letter a
194 .
195 .de1 an-p-footer
196 .  ev 1
197 .  ps \\n[PS]u
198 .  vs \\n[VS]u
199 .  ie \\n[an-html] \{\
200 .    ds an-page-string
201 .    ds an-extra1
202 .    ds an-extra2
203 .  \}
204 .  el \{\
205 .    ie r X \{\
206 .      if (\\n[%] > \\n[X]) \{\
207 .        nr an-page-letter (\\n[%] - \\n[X])
208 .        ds an-page-string \\n[X]\\n[an-page-letter]
209 .      \}
210 .    \}
211 .    el \{\
212 .      ie \\n[cR] \
213 .        ds an-page-string "\\*[an-title](\\*[an-section])
214 .      el \
215 .        ds an-page-string \\n[%]
216 .    \}
217 .  \}
218 .  ie \\n[D] \{\
219 .    if o .tl '\\*[an-extra2]'\\*[an-extra1]'\\*[an-page-string]'
220 .    if e .tl '\\*[an-page-string]'\\*[an-extra1]'\\*[an-extra2]'
221 .  \}
222 .  el \
223 .    tl '\\*[an-extra2]'\\*[an-extra1]'\\*[an-page-string]'
224 .  ev
225 ..
226 .
227 .de1 an-end
228 .  nr % 1
229 .  pl +3v
230 .  fl
231 .  sp 3
232 .  an-p-footer
233 .  pl \\n[nl]u
234 ..
235 .
236 .if \n[cR] .em an-end
237 .
238 .de1 SH
239 .  sp \\n[PD]u
240 .  nr an-level 1
241 .  set-an-margin
242 .  nr an-prevailing-indent \\n[IN]
243 .  fi
244 .  in \\n[an-margin]u
245 .  ti 0
246 .  HTML-TAG ".NH \\n[an-level]"
247 .  it 1 an-trap
248 .  nr an-no-space-flag 1
249 .  nr an-break-flag 1
250 .  ps \\n[PS-SH]u
251 .  ft B
252 .  if !\\n[cR] .ne (2v + 1u)
253 .  if \\n[.$] \&\\$*
254 ..
255 .
256 .de1 SS
257 .  sp \\n[PD]u
258 .  nr an-level 1
259 .  set-an-margin
260 .  nr an-prevailing-indent \\n[IN]
261 .  fi
262 .  in \\n[IN]u
263 .  ti \\n[SN]u
264 .  it 1 an-trap
265 .  nr an-no-space-flag 1
266 .  nr an-break-flag 1
267 .  ps \\n[PS-SS]u
268 .  ft B
269 .  if !\\n[cR] .ne (2v + 1u)
270 .  if \\n[.$] \&\\$*
271 ..
272 .
273 .de1 B
274 .  it 1 an-trap
275 .  ft B
276 .  if \\n[.$] \&\\$*
277 ..
278 .
279 .de1 I
280 .  it 1 an-trap
281 .  ft I
282 .  if \\n[.$] \&\\$*
283 ..
284 .
285 .de1 SM
286 .  it 1 an-trap
287 .  ps -1
288 .  if \\n[.$] \&\\$*
289 ..
290 .
291 .de1 SB
292 .  it 1 an-trap
293 .  ps -1
294 .  ft B
295 .  if \\n[.$] \&\\$*
296 ..
297 .
298 .de1 TP
299 .  sp \\n[PD]u
300 .  if \\n[.$] .nr an-prevailing-indent (n;\\$1)
301 .  it 1 an-trap
302 .  if !\\n[an-div?] .di an-div
303 .  ie \\n[an-html] .in \\n[an-margin]u
304 .  el \{\
305 .    in 0
306 .    ll -\\n[an-margin]u
307 .  \}
308 .  nr an-div? 1
309 ..
310 .
311 .de1 an-trap
312 .  ft R
313 .  ps \\n[PS]u
314 .  vs \\n[VS]u
315 .  if \\n[an-break-flag] \{\
316 .    br
317 .    nr an-break-flag 0
318 .  \}
319 .  if \\n[an-no-space-flag] \{\
320 .    ns
321 .    nr an-no-space-flag 0
322 .  \}
323 .  if \\n[an-div?] .an-do-tag
324 ..
325 .
326 .de an-do-tag
327 .  nr an-div? 0
328 .  br
329 .  ll
330 .  di
331 .  ie (\\n[dl] + \\n[an-tag-sep] > \\n[an-prevailing-indent]) \{\
332 .    in \\n[an-margin]u
333 .    if !\\n[cR] .ne (2v + 1u)
334 .    an-div
335 .    br
336 .    in (\\n[an-margin]u + \\n[an-prevailing-indent]u)
337 .  \}
338 .  el \{\
339 .    in (\\n[an-margin]u + \\n[an-prevailing-indent]u)
340 .    ti -\\n[an-prevailing-indent]u
341 .    chop an-div
342 .    if !\\n[cR] .ne (1v + 1u)
343 \\*[an-div]\\h'|\\n[an-prevailing-indent]u'\c
344 .  \}
345 ..
346 .
347 .de1 LP
348 .  br
349 .  sp \\n[PD]u
350 .  ps \\n[PS]u
351 .  vs \\n[VS]u
352 .  ft R
353 .  in \\n[an-margin]u
354 .  nr an-prevailing-indent \\n[IN]
355 ..
356 .
357 .als PP LP
358 .als P LP
359 .
360 .de1 IP
361 .  ie !\\n[.$] \{\
362 .    ps \\n[PS]u
363 .    vs \\n[VS]u
364 .    ft R
365 .    sp \\n[PD]u
366 .    if !\\n[cR] .ne (1v + 1u)
367 .    in (\\n[an-margin]u + \\n[an-prevailing-indent]u)
368 .  \}
369 .  el \{\
370 .    ie (\\n[.$] - 1) .TP "\\$2"
371 .    el               .TP
372 \&\\$1
373 .  \}
374 ..
375 .
376 .de1 HP
377 .  ps \\n[PS]u
378 .  vs \\n[VS]u
379 .  ft R
380 .  sp \\n[PD]u
381 .  if !\\n[cR] .ne (1v + 1u)
382 .  if \\n[.$] .nr an-prevailing-indent (n;\\$1)
383 .  in (\\n[an-margin]u + \\n[an-prevailing-indent]u)
384 .  ti \\n[an-margin]u
385 ..
386 .
387 .ds an-empty \" this is referenced to avoid looping on eg .RB ( \\ )
388 .
389 .de1 RI
390 .  if \\n[.$] \{\
391 .    ds an-result \&\\$1
392 .    shift
393 .    while (\\n[.$] >= 2) \{\
394 .      as an-result \,\f[I]\\$1\f[R]\/\\$2\\*[an-empty]
395 .      shift 2
396 .    \}
397 .    if \\n[.$] .as an-result \,\f[I]\\$1\f[R]
398 \\*[an-result]
399 .  \}
400 ..
401 .
402 .de1 IR
403 .  if \\n[.$] \{\
404 .    ds an-result \&\f[I]\\$1\f[R]
405 .    shift
406 .    while (\\n[.$] >= 2) \{\
407 .      as an-result \/\\$1\f[I]\,\\$2\f[R]
408 .      shift 2
409 .    \}
410 .    if \\n[.$] .as an-result \/\\$1
411 \\*[an-result]
412 .  \}
413 ..
414 .
415 .de1 IB
416 .  if \\n[.$] \{\
417 .    ds an-result \&\f[I]\\$1
418 .    shift
419 .    while (\\n[.$] >= 2) \{\
420 .      as an-result \/\f[B]\\$1\f[I]\,\\$2\\*[an-empty]
421 .      shift 2
422 .    \}
423 .    if \\n[.$] .as an-result \/\f[B]\\$1
424 \\*[an-result]
425 .    ft R
426 .  \}
427 ..
428 .
429 .de1 BI
430 .  if \\n[.$] \{\
431 .    ds an-result \&\f[B]\\$1
432 .    shift
433 .    while (\\n[.$] >= 2) \{\
434 .      as an-result \,\f[I]\\$1\f[B]\/\\$2\\*[an-empty]
435 .      shift 2
436 .    \}
437 .    if \\n[.$] .as an-result \,\f[I]\\$1
438 \\*[an-result]
439 .    ft R
440 .  \}
441 ..
442 .
443 .de1 RB
444 .  ds an-result \&
445 .  while (\\n[.$] >= 2) \{\
446 .    as an-result \f[R]\\$1\f[B]\\$2\\*[an-empty]
447 .    shift 2
448 .  \}
449 .  if \\n[.$] .as an-result \f[R]\\$1
450 \\*[an-result]
451 .  ft R
452 ..
453 .
454 .de1 BR
455 .  ds an-result \&
456 .  while (\\n[.$] >= 2) \{\
457 .    as an-result \f[B]\\$1\f[R]\\$2\\*[an-empty]
458 .    shift 2
459 .  \}
460 .  if \\n[.$] .as an-result \f[B]\\$1
461 \\*[an-result]
462 .  ft R
463 ..
464 .
465 .de1 RS
466 .  br
467 .  nr an-saved-margin\\n[an-level] \\n[an-margin]
468 .  nr an-saved-prevailing-indent\\n[an-level] \\n[an-prevailing-indent]
469 .  ie \\n[.$] .nr an-margin +(n;\\$1)
470 .  el         .nr an-margin +\\n[an-prevailing-indent]
471 .  in \\n[an-margin]u
472 .  nr an-prevailing-indent \\n[IN]
473 .  nr an-level +1
474 ..
475 .
476 .de1 RE
477 .  br
478 .  ie \\n[.$] .nr an-level ((;\\$1) <? \\n[an-level])
479 .  el         .nr an-level -1
480 .  nr an-level (1 >? \\n[an-level])
481 .  nr an-margin \\n[an-saved-margin\\n[an-level]]
482 .  nr an-prevailing-indent \\n[an-saved-prevailing-indent\\n[an-level]]
483 .  in \\n[an-margin]u
484 ..
485 .
486 .\" these strings must work in compatibility mode also
487 .
488 .ds S \s(\\n(PS
489 .ie c\[rg] .ds R \(rg
490 .el        .ds R (Reg.)
491 .ie c\[tm] .ds Tm \(tm
492 .el        .ds Tm (TM)
493 .ds lq \(lq
494 .ds rq \(rq
495 .
496 .if !\n[an-html] .hy 14
497 .
498 .\" Load local modifications.
499 .mso man.local
500 .
501 .cp \n[_C]
502 .
503 .\" end of an-old.tmac