Fix kldstat option.
[dragonfly.git] / contrib / groff-1.19 / tmac / doc.tmac
1 .\" Copyright (c) 1991, 1993
2 .\"     The Regents of the University of California.  All rights reserved.
3 .\"
4 .\" Redistribution and use in source and binary forms, with or without
5 .\" modification, are permitted provided that the following conditions
6 .\" are met:
7 .\" 1. Redistributions of source code must retain the above copyright
8 .\"    notice, this list of conditions and the following disclaimer.
9 .\" 2. Redistributions in binary form must reproduce the above copyright
10 .\"    notice, this list of conditions and the following disclaimer in the
11 .\"    documentation and/or other materials provided with the distribution.
12 .\" 3. [Deleted.  See
13 .\"     ftp://ftp.cs.berkeley.edu/pub/4bsd/README.Impt.License.Change]
14 .\" 4. Neither the name of the University nor the names of its contributors
15 .\"    may be used to endorse or promote products derived from this software
16 .\"    without specific prior written permission.
17 .\"
18 .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
19 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
20 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
21 .\" ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
22 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
23 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
24 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
25 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
26 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
27 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
28 .\" SUCH DAMAGE.
29 .\"
30 .\"     @(#)doc 8.1 (Berkeley) 06/08/93
31 .\"
32 .\" Modified by jjc@jclark.com as follows: the doc-* files are assumed to be
33 .\" installed as mdoc/doc-* rather than tmac.doc-* (the filename
34 .\" `tmac.doc-common' would be too long); when using groff, the doc-* files
35 .\" are loaded using the `mso' request.
36 .\"
37 .\" Modified by
38 .\"
39 .\"   Werner LEMBERG <wl@gnu.org>      and
40 .\"   Ruslan Ermilov <ru@freebsd.org>
41 .\"
42 .\" to make it more readable: using long names and many groff features,
43 .\" updating and extending documentation, etc.
44 .\"
45 .\" %beginstrip%
46 .
47 .
48 .if !\n(.g \
49 .  ab This version of mdoc can be run with GNU troff only!
50 .
51 .
52 .do if d Dd .nx
53 .
54 .
55 .cp 0
56 .
57 .
58 .if (\n[.x]\n[.y] < 118) \
59 .  ab You need GNU troff version 1.18 or higher to run this version of mdoc!
60 .
61 .
62 .\" Load start-up files
63 .ie t \
64 .  mso mdoc/doc-ditroff
65 .el \
66 .  mso mdoc/doc-nroff
67 .
68 .mso mdoc/doc-common
69 .mso mdoc/doc-syms
70 .
71 .
72 .eo
73 .
74 .
75 .\" NS doc-macro-name global string
76 .\" NS   name of calling request (set in each user-requestable macro)
77 .
78 .ds doc-macro-name
79 .als doc-arg0 doc-macro-name
80 .
81 .
82 .\" NS doc-arg-limit global register
83 .\" NS   total number of arguments
84 .
85 .nr doc-arg-limit 0
86 .
87 .
88 .\" NS doc-num-args global register
89 .\" NS   number of arguments to handle (must be set to \n[.$] prior to
90 .\" NS   `doc-parse-arg-vector' request)
91 .
92 .nr doc-num-args 0
93 .
94 .
95 .\" NS doc-arg-ptr global register
96 .\" NS   argument pointer
97 .
98 .nr doc-arg-ptr 0
99 .
100 .
101 .\" NS doc-argXXX global string
102 .\" NS   argument vector
103 .\" NS
104 .\" NS limit:
105 .\" NS   doc-arg-limit
106 .
107 .ds doc-arg1
108 .
109 .
110 .\" NS doc-typeXXX global register
111 .\" NS   argument type vector (macro=1, string=2, punctuation suffix=3,
112 .\" NS   punctuation prefix=4)
113 .\" NS
114 .\" NS limit:
115 .\" NS   doc-arg-limit
116 .
117 .nr doc-type1 0
118 .
119 .
120 .\" NS doc-spaceXXX global string
121 .\" NS   space vector
122 .\" NS
123 .\" NS limit:
124 .\" NS   doc-arg-limit
125 .
126 .ds doc-space1
127 .
128 .
129 .\" NS doc-parse-args macro
130 .\" NS   parse arguments (recursively) (`.doc-parse-args arg ...')
131 .\" NS
132 .\" NS modifies:
133 .\" NS   doc-arg-limit
134 .\" NS   doc-arg-ptr
135 .\" NS   doc-argXXX
136 .\" NS   doc-spaceXXX
137 .\" NS   doc-typeXXX
138 .\" NS   doc-arg-ptr
139 .\" NS   doc-have-space
140 .\" NS
141 .\" NS local variables:
142 .\" NS   doc-reg-dpa
143 .\" NS   doc-reg-dpa1
144 .\" NS   doc-str-dpa
145 .
146 .de doc-parse-args
147 .  if !\n[doc-arg-limit] \
148 .    doc-set-spacing-1
149 .
150 .  nr doc-have-space 0
151 .
152 .  if !\n[.$] \
153 .    return
154 .
155 .  nr doc-arg-limit +1
156 .
157 .  \" handle `|' and `...' specially
158 .  ie        "\$1"|" \
159 .    ds doc-arg\n[doc-arg-limit] \f[R]|\f[]
160 .  el \{ .ie "\$1"..." \
161 .    ds doc-arg\n[doc-arg-limit] \|.\|.\|.
162 .  el \
163 .    ds doc-arg\n[doc-arg-limit] "\$1
164 .  \}
165 .
166 .  \" get argument type and set spacing
167 .  doc-get-arg-type* \n[doc-arg-limit]
168 .  nr doc-type\n[doc-arg-limit] \n[doc-arg-type]
169 .  doc-set-spacing-\n[doc-arg-type]
170 .
171 .  \" check whether we have processed the last parameter
172 .  ie (\n[.$] == 1) \
173 .    nr doc-arg-ptr 0
174 .  el \{\
175 .    shift
176 .    doc-parse-args \$@
177 .  \}
178 .
179 .  nh
180 ..
181 .
182 .
183 .\" NS doc-parse-arg-vector macro
184 .\" NS   parse argument vector (recursive)
185 .\" NS
186 .\" NS   cf. comments in doc-parse-args
187 .\" NS
188 .\" NS modifies:
189 .\" NS   doc-arg-limit
190 .\" NS   doc-arg-ptr
191 .\" NS   doc-argXXX
192 .\" NS   doc-num-args
193 .\" NS   doc-spaceXXX
194 .\" NS   doc-typeXXX
195 .\" NS
196 .\" NS local variables:
197 .\" NS   doc-reg-dpav
198 .\" NS   doc-reg-dpav1
199 .\" NS   doc-str-dpav
200 .
201 .de doc-parse-arg-vector
202 .  if !\n[doc-arg-limit] \
203 .    doc-set-spacing-1
204 .
205 .  nr doc-arg-limit +1
206 .
207 .  ie        "\*[doc-arg\n[doc-arg-limit]]"|" \
208 .    ds doc-arg\n[doc-arg-limit] \f[R]|\f[]
209 .  el \{ .if "\*[doc-arg\n[doc-arg-limit]]"..." \
210 .    ds doc-arg\n[doc-arg-limit] \|.\|.\|.
211 .  \}
212 .
213 .  doc-get-arg-type* \n[doc-arg-limit]
214 .  nr doc-type\n[doc-arg-limit] \n[doc-arg-type]
215 .  doc-set-spacing-\n[doc-arg-type]
216 .
217 .  ie (\n[doc-num-args] == 1) \{\
218 .    nr doc-arg-ptr 0
219 .    nr doc-num-args 0
220 .  \}
221 .  el \{\
222 .    nr doc-num-args -1
223 .    doc-parse-arg-vector
224 .  \}
225 .
226 .  nh
227 ..
228 .
229 .
230 .\" NS doc-parse-space-vector macro
231 .\" NS   parse space vector (recursive)
232 .\" NS
233 .\" NS modifies:
234 .\" NS   doc-arg-limit
235 .\" NS   doc-num-args
236 .\" NS   doc-spaceXXX
237 .
238 .de doc-parse-space-vector
239 .  nr doc-arg-limit +1
240 .
241 .  doc-set-spacing-\n[doc-type\n[doc-arg-limit]]
242 .
243 .  ie (\n[doc-num-args] == 1) \
244 .    nr doc-num-args 0
245 .  el \{\
246 .    nr doc-num-args -1
247 .    doc-parse-space-vector
248 .  \}
249 ..
250 .
251 .
252 .\" NS doc-remaining-args macro
253 .\" NS   output remaining arguments as-is, separated by spaces (until
254 .\" NS   `doc-num-args' is exhausted)
255 .\" NS
256 .\" NS modifies:
257 .\" NS   doc-arg-ptr
258 .\" NS   doc-num-args
259 .
260 .de doc-remaining-args
261 .  nr doc-arg-ptr +1
262 .  nop \)\*[doc-arg\n[doc-arg-ptr]]\c
263 .
264 .  ie (\n[doc-num-args] == 1) \{\
265 .    nr doc-arg-ptr 0
266 .    nr doc-num-args 0
267 .  \}
268 .  el \{\
269 .    nop \)\*[doc-space]\c
270 .    nr doc-num-args -1
271 .    doc-remaining-args
272 .  \}
273 ..
274 .
275 .
276 .\" NS doc-append-arg macro
277 .\" NS   append one argument to argument vector:
278 .\" NS   `.doc-append-arg [arg] [type]'
279 .\" NS
280 .\" NS modifies:
281 .\" NS   doc-arg-limit
282 .\" NS   doc-argXXX
283 .\" NS   doc-typeXXX
284 .
285 .de doc-append-arg
286 .  nr doc-arg-limit +1
287 .  ds doc-arg\n[doc-arg-limit] "\$1
288 .  nr doc-type\n[doc-arg-limit] \$2
289 .  doc-set-spacing-\$2
290 ..
291 .
292 .
293 .\" NS doc-print-and-reset macro
294 .\" NS   finish input line and clean up argument vectors
295 .
296 .de doc-print-and-reset
297 .  if \n[doc-space-mode] \
298 .    nop \)
299 .  doc-reset-args
300 ..
301 .
302 .
303 .\" NS doc-reset-args macro
304 .\" NS   reset argument counters
305 .\" NS
306 .\" NS modifies:
307 .\" NS   doc-arg-limit
308 .\" NS   doc-arg-ptr
309 .\" NS   doc-have-slot
310 .
311 .de doc-reset-args
312 .  nr doc-arg-limit 0
313 .  nr doc-arg-ptr 0
314 .  nr doc-have-slot 0
315 .
316 .  hy \n[doc-hyphen-flags]
317 ..
318 .
319 .
320 .ec
321 .
322 .\" NS doc-curr-font global register
323 .\" NS   saved current font
324 .
325 .nr doc-curr-font \n[.f]
326 .
327 .
328 .\" NS doc-curr-size global register
329 .\" NS   saved current font size
330 .
331 .nr doc-curr-size \n[.ps]
332 .
333 .eo
334 .
335 .
336 .\" NS Fl user macro
337 .\" NS   handle flags (appends `-' and prints flags): `.Fl [arg ...]'
338 .\" NS
339 .\" NS modifies:
340 .\" NS   doc-arg-ptr
341 .\" NS   doc-curr-font
342 .\" NS   doc-curr-size
343 .\" NS   doc-macro-name
344 .\" NS
345 .\" NS local variables:
346 .\" NS   doc-reg-Fl (for communication with doc-flag-recursion)
347 .\" NS
348 .\" NS width register `Fl' set in doc-common
349 .
350 .de Fl
351 .  nr doc-curr-font \n[.f]
352 .  nr doc-curr-size \n[.ps]
353 .  nop \*[doc-Fl-font]\c
354 .
355 .  if !\n[doc-arg-limit] \{\
356 .    ds doc-macro-name Fl
357 .    doc-parse-args \$@
358 .
359 .    if !\n[.$] \{\
360 .      \" no arguments
361 .      nop \|\-\|\f[]\s[0]
362 .  \}\}
363 .
364 .  if !\n[doc-arg-limit] \
365 .    return
366 .
367 .  nr doc-arg-ptr +1
368 .  ie (\n[doc-arg-limit] < \n[doc-arg-ptr]) \{\
369 .    \" last argument
370 .    nop \|\-\f[]\s[0]\c
371 .    doc-print-and-reset
372 .  \}
373 .  el \{\
374 .    ie (\n[doc-type\n[doc-arg-ptr]] == 1) \{\
375 .      nop \|\-\f[]\s[0]\c
376 .      \*[doc-arg\n[doc-arg-ptr]]
377 .    \}
378 .    el \{\
379 .      if (\n[doc-type\n[doc-arg-ptr]] == 3) \
380 .        nop \|\-\|\c
381 .
382 .      nr doc-reg-Fl 1
383 .      doc-flag-recursion
384 .  \}\}
385 ..
386 .
387 .
388 .\" NS doc-flag-recursion macro
389 .\" NS   `Fl' flag recursion routine (special handling)
390 .\" NS
391 .\" NS modifies:
392 .\" NS   doc-arg-ptr
393 .\" NS
394 .\" NS local variables:
395 .\" NS   doc-reg-dfr
396 .\" NS   doc-reg-dfr1
397 .\" NS   doc-str-dfr
398 .
399 .de doc-flag-recursion
400 .  nr doc-reg-dfr1 \n[doc-type\n[doc-arg-ptr]]
401 .  ds doc-str-dfr "\*[doc-arg\n[doc-arg-ptr]]
402 .
403 .  ie (\n[doc-reg-dfr1] == 1) \{\
404 .    nop \f[]\s[0]\c
405 .    \*[doc-str-dfr]
406 .  \}
407 .  el \{\
408 .    nr doc-reg-dfr \n[doc-arg-ptr]
409 .
410 .    ie (\n[doc-reg-dfr1] == 2) \{\
411 .      \" handle vertical bar -- doc-reg-Fl is set for the first call of
412 .      \" doc-flag-recursion only; we need this to make `.Fl | ...' work
413 .      \" correctly
414 .      ie "\*[doc-str-dfr]"\*[Ba]" \{\
415 .        if \n[doc-reg-Fl] \
416 .          nop \|\-\*[doc-space]\c
417 .        nop \)\*[Ba]\c
418 .      \}
419 .      el \{\
420 .        ie "\*[doc-str-dfr]"\f[R]|\f[]" \{\
421 .          if \n[doc-reg-Fl] \
422 .            nop \|\-\*[doc-space]\c
423 .          nop \f[R]|\f[]\c
424 .        \}
425 .        el \{\
426 .          \" two consecutive hyphen characters?
427 .          ie "\*[doc-str-dfr]"-" \
428 .            nop \|\-\^\-\|\c
429 .          el \
430 .            nop \|\%\-\*[doc-str-dfr]\&\c
431 .    \}\}\}
432 .    el \{\
433 .      nop \f[\n[doc-curr-font]]\s[\n[doc-curr-size]u]\c
434 .      nop \)\*[doc-str-dfr]\f[]\s[0]\c
435 .    \}
436 .
437 .    ie (\n[doc-arg-limit] == \n[doc-arg-ptr]) \{\
438 .      \" last argument
439 .      if (\n[doc-reg-dfr1] == 4) \
440 .        nop \|\-\c
441 .      nop \f[]\s[0]\c
442 .      doc-print-and-reset
443 .    \}
444 .    el \{\
445 .      nr doc-arg-ptr +1
446 .      ie (\n[doc-type\n[doc-arg-ptr]] == 3) \{\
447 .        ie (\n[doc-type\n[doc-reg-dfr]] == 4) \
448 .          nop \|\-\c
449 .        el \
450 .          nop \)\*[doc-space\n[doc-reg-dfr]]\c
451 .      \}
452 .      el \
453 .        nop \)\*[doc-space\n[doc-reg-dfr]]\c
454 .
455 .      shift
456 .      nr doc-reg-Fl 0
457 .      doc-flag-recursion \$@
458 .  \}\}
459 ..
460 .
461 .
462 .\" NS doc-print-recursive macro
463 .\" NS   general name recursion routine (print remaining arguments)
464 .\" NS
465 .\" NS modifies:
466 .\" NS   doc-arg-ptr
467 .\" NS
468 .\" NS local variables:
469 .\" NS   doc-reg-dpr
470 .\" NS   doc-reg-dpr1
471 .\" NS   doc-str-dpr
472 .
473 .de doc-print-recursive
474 .  nr doc-reg-dpr1 \n[doc-type\n[doc-arg-ptr]]
475 .  ds doc-str-dpr "\*[doc-arg\n[doc-arg-ptr]]
476 .
477 .  ie (\n[doc-reg-dpr1] == 1) \{\
478 .    nop \f[\n[doc-curr-font]]\s[\n[doc-curr-size]u]\c
479 .    \*[doc-str-dpr]
480 .  \}
481 .  el \{\
482 .    nr doc-reg-dpr \n[doc-arg-ptr]
483 .
484 .    ie (\n[doc-reg-dpr1] == 2) \
485 .      \" the `\%' prevents hyphenation on a dash (`-')
486 .      nop \%\*[doc-str-dpr]\&\c
487 .    el \{\
488 .      \" punctuation character
489 .      nop \f[\n[doc-curr-font]]\s[\n[doc-curr-size]u]\c
490 .      nop \)\*[doc-str-dpr]\f[]\s[0]\c
491 .    \}
492 .
493 .    nr doc-arg-ptr +1
494 .    ie (\n[doc-arg-limit] < \n[doc-arg-ptr]) \{\
495 .      \" last argument
496 .      nop \f[\n[doc-curr-font]]\s[\n[doc-curr-size]u]\c
497 .      doc-print-and-reset
498 .    \}
499 .    el \{\
500 .      nop \)\*[doc-space\n[doc-reg-dpr]]\c
501 .      doc-print-recursive
502 .  \}\}
503 ..
504 .
505 .
506 .\" NS doc-print-prefixes macro
507 .\" NS   print leading prefixes
508 .\" NS
509 .\" NS modifies:
510 .\" NS   doc-arg-ptr
511 .
512 .de doc-print-prefixes
513 .  while (\n[doc-arg-limit] >= \n[doc-arg-ptr]) \{\
514 .    if !(\n[doc-type\n[doc-arg-ptr]] == 4) \
515 .      break
516 .    nop \f[\n[doc-curr-font]]\s[\n[doc-curr-size]u]\c
517 .    nop \)\*[doc-arg\n[doc-arg-ptr]]\f[]\s[0]\c
518 .    nr doc-arg-ptr +1
519 .  \}
520 ..
521 .
522 .
523 .\" NS doc-generic-macro macro
524 .\" NS   this is the skeleton for most simple macros
525 .\" NS
526 .\" NS modifies:
527 .\" NS   doc-arg-ptr
528 .\" NS   doc-curr-font
529 .\" NS   doc-curr-size
530 .\" NS   doc-macro-name
531 .
532 .de doc-generic-macro
533 .  if !\n[doc-arg-limit] \{\
534 .    ie \n[.$] \{\
535 .      ds doc-macro-name \$0
536 .      doc-parse-args \$@
537 .    \}
538 .    el \
539 .      tm Usage: .\$0 \*[doc-\$0-usage] ... (#\n[.c])
540 .  \}
541 .
542 .  if !\n[doc-arg-limit] \
543 .    return
544 .
545 .  nr doc-arg-ptr +1
546 .  ie (\n[doc-arg-limit] >= \n[doc-arg-ptr]) \{\
547 .    if (\n[doc-type\n[doc-arg-ptr]] == 1) \{\
548 .      tmc mdoc warning: Using a macro as first argument
549 .      tm1 " cancels effect of .\$0 (#\n[.c])
550 .
551 .      \" the right action here would be to reset the argument counters
552 .      \" and bail out -- unfortunately, a small number of manual pages
553 .      \" (less than 2% for FreeBSD which has been used for testing)
554 .      \" relied on the old behaviour (silently ignore this error),
555 .      \" so it is commented out
556 .
557 .\"    doc-reset-args
558 .    \}
559 .\"  el \{\
560 .      nr doc-curr-font \n[.f]
561 .      nr doc-curr-size \n[.ps]
562 .      nop \*[doc-\$0-font]\c
563 .      doc-print-recursive
564 .\"  \}
565 .  \}
566 .  el \{\
567 .    tm Usage: .\$0 \*[doc-\$0-usage] ... (#\n[.c])
568 .    doc-reset-args
569 .  \}
570 ..
571 .
572 .
573 .\" NS Ar user macro
574 .\" NS   command line `argument' macro: `.Ar [args ...]'
575 .\" NS
576 .\" NS modifies:
577 .\" NS   doc-arg-ptr
578 .\" NS   doc-curr-font
579 .\" NS   doc-curr-size
580 .\" NS   doc-macro-name
581 .\" NS
582 .\" NS local variable:
583 .\" NS   doc-str-Ar-default
584 .\" NS
585 .\" NS width register `Ar' set in doc-common
586 .
587 .ds doc-str-Ar-default "file\ .\|.\|.
588 .
589 .de Ar
590 .  nr doc-curr-font \n[.f]
591 .  nr doc-curr-size \n[.ps]
592 .  nop \*[doc-Ar-font]\c
593 .
594 .  if !\n[doc-arg-limit] \{\
595 .    ds doc-macro-name Ar
596 .    doc-parse-args \$@
597 .
598 .    if !\n[.$] \{\
599 .      \" no argument
600 .      nop \)\*[doc-str-Ar-default]\&\f[]\s[0]
601 .  \}\}
602 .
603 .  if !\n[doc-arg-limit] \
604 .    return
605 .
606 .  nr doc-arg-ptr +1
607 .  doc-print-prefixes
608 .  ie (\n[doc-arg-limit] < \n[doc-arg-ptr]) \{\
609 .    nop \)\*[doc-str-Ar-default]\&\f[]\s[0]\c
610 .    doc-print-and-reset
611 .  \}
612 .  el \{\
613 .    if !(\n[doc-type\n[doc-arg-ptr]] == 2) \{\
614 .      \" replace previous argument (Ar) with default value
615 .      nr doc-arg-ptr -1
616 .      ds doc-arg\n[doc-arg-ptr] "\*[doc-str-Ar-default]
617 .      nr doc-type\n[doc-arg-ptr] 2
618 .      ds doc-space\n[doc-arg-ptr] "\*[doc-space]
619 .
620 .      \" recompute space vector for remaining arguments
621 .      nr doc-num-args (\n[doc-arg-limit] - \n[doc-arg-ptr])
622 .      nr doc-arg-limit \n[doc-arg-ptr]
623 .      doc-parse-space-vector
624 .    \}
625 .    doc-print-recursive
626 .  \}
627 ..
628 .
629 .
630 .\" NS Ad user macro
631 .\" NS   Addresses
632 .\" NS
633 .\" NS width register `Ad' set in doc-common
634 .
635 .als Ad doc-generic-macro
636 .ds doc-Ad-usage address
637 .
638 .
639 .\" NS doc-indent-synopsis global register
640 .\" NS   indentation in synopsis
641 .
642 .nr doc-indent-synopsis 0
643 .
644 .
645 .\" NS doc-indent-synopsis-active global register (bool)
646 .\" NS   indentation in synopsis active
647 .
648 .nr doc-indent-synopsis-active 0
649 .
650 .
651 .\" NS Cd user macro
652 .\" NS   config declaration (for section 4 SYNOPSIS)
653 .\" NS
654 .\" NS   this function causes a break; it uses the `Nm' font
655 .\" NS
656 .\" NS modifies:
657 .\" NS   doc-arg-ptr
658 .\" NS   doc-curr-font
659 .\" NS   doc-curr-size
660 .\" NS   doc-indent-synopsis
661 .\" NS   doc-macro-name
662 .\" NS
663 .\" NS width register `Cd' set in doc-common
664 .
665 .de Cd
666 .  if !\n[doc-arg-limit] \{\
667 .    ie \n[.$] \{\
668 .      ds doc-macro-name Cd
669 .      doc-parse-args \$@
670 .    \}
671 .    el \
672 .      tm Usage: .Cd configuration_file_declaration ... (#\n[.c])
673 .  \}
674 .
675 .  if !\n[doc-arg-limit] \
676 .    return
677 .
678 .  nr doc-arg-ptr +1
679 .  ie (\n[doc-arg-limit] >= \n[doc-arg-ptr]) \{\
680 .    nr doc-curr-font \n[.f]
681 .    nr doc-curr-size \n[.ps]
682 .
683 .    ie \n[doc-in-synopsis-section] \{\
684 .      ie "\*[doc-macro-name]"Cd" \{\
685 .        br
686 .        if !\n[doc-indent-synopsis] \
687 .          nr doc-indent-synopsis \n[doc-display-indent]u
688 .        if !\n[doc-indent-synopsis-active] \
689 .          in +\n[doc-indent-synopsis]u
690 .        ti -\n[doc-indent-synopsis]u
691 .        nop \*[doc-Nm-font]\c
692 .        doc-print-recursive
693 .        if !\n[doc-indent-synopsis-active] \
694 .          in -\n[doc-indent-synopsis]u
695 .      \}
696 .      el \{\
697 .        nop \*[doc-Nm-font]\c
698 .        doc-print-recursive
699 .    \}\}
700 .    el \{\
701 .      nop \*[doc-Nm-font]\c
702 .      doc-print-recursive
703 .  \}\}
704 .  el \{\
705 .    tm Usage: .Cd configuration_file_declaration ... (#\n[.c])
706 .    doc-reset-args
707 .  \}
708 ..
709 .
710 .
711 .\" NS Cm user macro
712 .\" NS   interactive command modifier (flag)
713 .\" NS
714 .\" NS width register `Cm' set in doc-common
715 .
716 .als Cm doc-generic-macro
717 .ds doc-Cm-usage interactive_command_modifier
718 .
719 .
720 .\" NS Dv user macro
721 .\" NS   defined variable
722 .\" NS
723 .\" NS   this function uses the `Er' font
724 .\" NS
725 .\" NS width register `Dv' set in doc-common
726 .
727 .als Dv doc-generic-macro
728 .ds doc-Dv-usage defined_variable
729 .als doc-Dv-font doc-Er-font
730 .
731 .
732 .\" NS Em user macro
733 .\" NS   emphasis
734 .\" NS
735 .\" NS width register `Em' set in doc-common
736 .
737 .als Em doc-generic-macro
738 .ds doc-Em-usage text
739 .
740 .
741 .\" NS Er user macro
742 .\" NS   errno type
743 .\" NS
744 .\" NS width register `Er' set in doc-common
745 .
746 .als Er doc-generic-macro
747 .ds doc-Er-usage text
748 .
749 .
750 .\" NS Ev user macro
751 .\" NS   environment variable
752 .\" NS
753 .\" NS width register `Ev' set in doc-common
754 .
755 .als Ev doc-generic-macro
756 .ds doc-Ev-usage text
757 .
758 .
759 .\" NS doc-have-decl global register (bool)
760 .\" NS   subroutine test (in synopsis only)
761 .
762 .nr doc-have-decl 0
763 .
764 .
765 .\" NS doc-have-var global register (bool)
766 .\" NS   whether last type is a variable type
767 .
768 .nr doc-have-var 0
769 .
770 .
771 .\" NS doc-do-func-decl macro
772 .\" NS   do something special while in SYNOPSIS
773 .\" NS
774 .\" NS modifies:
775 .\" NS   doc-curr-font
776 .\" NS   doc-curr-size
777 .\" NS   doc-have-decl
778 .\" NS   doc-have-var
779 .
780 .de doc-do-func-decl
781 .  if \n[doc-in-synopsis-section] \{\
782 .    \" if a variable type was the last thing given, want vertical space
783 .    if \n[doc-have-var] \{\
784 .      doc-paragraph
785 .      nr doc-have-var 0
786 .    \}
787 .    \" if a subroutine was the last thing given, want vertical space
788 .    if \n[doc-have-func] \{\
789 .      ie \n[doc-have-decl] \
790 .        br
791 .      el \
792 .        doc-paragraph
793 .    \}
794 .    nr doc-have-decl 1
795 .  \}
796 .
797 .  nr doc-curr-font \n[.f]
798 .  nr doc-curr-size \n[.ps]
799 ..
800 .
801 .
802 .\" NS Fd user macro
803 .\" NS   function declaration -- not callable
804 .\" NS
805 .\" NS   this function causes a break
806 .\" NS
807 .\" NS width register `Fd' set in doc-common
808 .
809 .de Fd
810 .  ie ((\n[.$] >= 1) & (\n[doc-arg-limit] == 0)) \{\
811 .    doc-do-func-decl
812 .    nop \*[doc-Fd-font]\$*
813 .    br
814 .    ft \n[doc-curr-font]
815 .    ps \n[doc-curr-size]u
816 .  \}
817 .  el \{\
818 .    tm Usage: .Fd function_declaration -- Fd is not callable (#\n[.c])
819 .    doc-reset-args
820 .  \}
821 ..
822 .
823 .
824 .\" NS In user macro
825 .\" NS   #include statement in SYNOPSIS
826 .\" NS   <header.h> if not in SYNOPSIS
827 .\" NS
828 .\" NS   this function causes a break; it uses the `Fd' font
829 .\" NS
830 .\" NS modifies:
831 .\" NS   doc-arg-ptr
832 .\" NS   doc-curr-font
833 .\" NS   doc-curr-size
834 .\" NS   doc-indent-synopsis
835 .\" NS   doc-macro-name
836 .\" NS
837 .\" NS width register `In' set in doc-common
838 .
839 .de In
840 .  if !\n[doc-arg-limit] \{\
841 .    ie \n[.$] \{\
842 .      ds doc-macro-name In
843 .      doc-parse-args \$@
844 .    \}
845 .    el \
846 .      tm Usage: .In include_file ... (#\n[.c])
847 .  \}
848 .
849 .  if !\n[doc-arg-limit] \
850 .    return
851 .
852 .  nr doc-arg-ptr +1
853 .  doc-print-prefixes
854 .  ie ((\n[doc-arg-limit] >= \n[doc-arg-ptr]) & (\n[doc-type\n[doc-arg-ptr]] == 2)) \{\
855 .    nr doc-curr-font \n[.f]
856 .    nr doc-curr-size \n[.ps]
857 .
858 .    ie \n[doc-in-synopsis-section] \{\
859 .      ie "\*[doc-macro-name]"In" \{\
860 .        doc-do-func-decl
861 .        nop \*[doc-Fd-font]#include <\*[doc-arg\n[doc-arg-ptr]]>
862 .        ft \n[doc-curr-font]
863 .        ps \n[doc-curr-size]u
864 .        br
865 .        nr doc-arg-ptr +1
866 .        ie (\n[doc-arg-limit] >= \n[doc-arg-ptr]) \
867 .          doc-print-recursive
868 .        el \
869 .          doc-reset-args
870 .      \}
871 .      el \{\
872 .        ds doc-arg\n[doc-arg-ptr] "<\*[doc-Pa-font]\*[doc-arg\n[doc-arg-ptr]]
873 .        as doc-arg\n[doc-arg-ptr] \f[\n[doc-curr-font]]\s[\n[doc-curr-size]u]>
874 .        doc-print-recursive
875 .    \}\}
876 .    el \{\
877 .      ds doc-arg\n[doc-arg-ptr] "<\*[doc-Pa-font]\*[doc-arg\n[doc-arg-ptr]]
878 .      as doc-arg\n[doc-arg-ptr] \f[\n[doc-curr-font]]\s[\n[doc-curr-size]u]>
879 .      doc-print-recursive
880 .  \}\}
881 .  el \{\
882 .    tm Usage: .In include_file ... (#\n[.c])
883 .    doc-reset-args
884 .  \}
885 ..
886 .
887 .
888 .\" NS Fr user macro
889 .\" NS   function return value
890 .\" NS
891 .\" NS   this function uses the `Ar' font
892 .\" NS
893 .\" NS width register `Fr' set in doc-common
894 .
895 .als Fr doc-generic-macro
896 .ds doc-Fr-usage function_return_value
897 .als doc-Fr-font doc-Ar-font
898 .
899 .
900 .\" NS Ic user macro
901 .\" NS   interactive command
902 .\" NS
903 .\" NS width register `Ic' set in doc-common
904 .
905 .als Ic doc-generic-macro
906 .ds doc-Ic-usage interactive_command
907 .
908 .
909 .\" NS Li user macro
910 .\" NS   literals
911 .\" NS
912 .\" NS width register `Li' set in doc-common
913 .
914 .als Li doc-generic-macro
915 .ds doc-Li-usage argument
916 .
917 .
918 .\" NS Ms user macro
919 .\" NS   math symbol
920 .\" NS
921 .\" NS   this function uses the `Sy' font
922 .\" NS
923 .\" NS width register `Ms' set in doc-common
924 .
925 .als Ms doc-generic-macro
926 .ds doc-Ms-usage math_symbol
927 .als doc-Ms-font doc-Sy-font
928 .
929 .
930 .\" NS doc-command-name global string
931 .\" NS   save first invocation of .Nm
932 .
933 .ds doc-command-name
934 .
935 .
936 .\" NS Nm user macro
937 .\" NS   name of command or page topic
938 .\" NS
939 .\" NS modifies:
940 .\" NS   doc-arg-ptr
941 .\" NS   doc-command-name
942 .\" NS   doc-curr-font
943 .\" NS   doc-curr-size
944 .\" NS   doc-indent-synopsis
945 .\" NS   doc-indent-synopsis-active
946 .\" NS   doc-macro-name
947 .\" NS
948 .\" NS width register `Nm' set in doc-common
949 .
950 .de Nm
951 .  if !\n[doc-arg-limit] \{\
952 .    ds doc-macro-name Nm
953 .    ie \n[.$] \
954 .      doc-parse-args \$@
955 .    el \{\
956 .      ie "\*[doc-command-name]"" \
957 .        tm Usage: .Nm name ... (#\n[.c])
958 .      el \
959 .        doc-parse-args \*[doc-command-name]
960 .  \}\}
961 .
962 .  if !\n[doc-arg-limit] \
963 .    return
964 .
965 .  nr doc-arg-ptr +1
966 .  doc-print-prefixes
967 .  ie (\n[doc-arg-limit] < \n[doc-arg-ptr]) \{\
968 .    \" last argument
969 .    ie "\*[doc-command-name]"" \{\
970 .      tm Usage: .Nm name ... (#\n[.c])
971 .      doc-reset-args
972 .    \}
973 .    el \{\
974 .      nop \*[doc-Nm-font]\*[doc-command-name]\f[]\s[0]\c
975 .      doc-print-and-reset
976 .  \}\}
977 .  el \{\
978 .    nr doc-curr-font \n[.f]
979 .    nr doc-curr-size \n[.ps]
980 .
981 .    ie !(\n[doc-type\n[doc-arg-ptr]] == 2) \{\
982 .      ie "\*[doc-command-name]"" \
983 .        tm Usage: .Nm name ... (#\n[.c])
984 .      el \{\
985 .        \" replace previous argument (Nm) with default value
986 .        nr doc-arg-ptr -1
987 .        ds doc-arg\n[doc-arg-ptr] "\*[doc-Nm-font]\*[doc-command-name]\f[]\s[0]
988 .        nr doc-type\n[doc-arg-ptr] 2
989 .        ds doc-space\n[doc-arg-ptr] "\*[doc-space]
990 .
991 .        \" recompute space vector for remaining arguments
992 .        nr doc-num-args (\n[doc-arg-limit] - \n[doc-arg-ptr])
993 .        nr doc-arg-limit \n[doc-arg-ptr]
994 .        doc-parse-space-vector
995 .    \}\}
996 .    el \{\
997 .      \" handle `.Nm ...' in SYNOPSIS
998 .      if \n[doc-in-synopsis-section] \{\
999 .        if "\*[doc-macro-name]"Nm" \{\
1000 .          br
1001 .          if !\n[doc-indent-synopsis] \{\
1002 .            doc-get-width "\*[doc-arg\n[doc-arg-ptr]]"
1003 .            nr doc-indent-synopsis ((\n[doc-width]u + 1u) * \n[doc-fixed-width]u)
1004 .          \}
1005 .          if !\n[doc-indent-synopsis-active] \{\
1006 .            in +\n[doc-indent-synopsis]u
1007 .            nr doc-indent-synopsis-active 1
1008 .          \}
1009 .          ti -\n[doc-indent-synopsis]u
1010 .      \}\}
1011 .      if "\*[doc-command-name]"" \
1012 .        ds doc-command-name "\*[doc-arg\n[doc-arg-ptr]]
1013 .
1014 .      nop \*[doc-Nm-font]\c
1015 .    \}
1016 .    doc-print-recursive
1017 .  \}
1018 ..
1019 .
1020 .
1021 .\" NS Pa user macro
1022 .\" NS   pathname: `.Pa [arg ...]'
1023 .\" NS
1024 .\" NS modifies:
1025 .\" NS   doc-arg-ptr
1026 .\" NS   doc-curr-font
1027 .\" NS   doc-curr-size
1028 .\" NS   doc-macro-name
1029 .\" NS
1030 .\" NS width register `Pa' set in doc-common
1031 .
1032 .de Pa
1033 .  if !\n[doc-arg-limit] \{\
1034 .    ds doc-macro-name Pa
1035 .    doc-parse-args \$@
1036 .
1037 .    if !\n[.$] \{\
1038 .      \" default value
1039 .      nop \*[doc-Pa-font]~\f[]\s[0]
1040 .  \}\}
1041 .
1042 .  if !\n[doc-arg-limit] \
1043 .    return
1044 .
1045 .  nr doc-arg-ptr +1
1046 .  doc-print-prefixes
1047 .  ie (\n[doc-arg-limit] >= \n[doc-arg-ptr]) \{\
1048 .    nr doc-curr-font \n[.f]
1049 .    nr doc-curr-size \n[.ps]
1050 .    nop \*[doc-Pa-font]\c
1051 .    if !(\n[doc-type\n[doc-arg-ptr]] == 2) \{\
1052 .      \" replace previous argument (Pa) with default value
1053 .      nr doc-arg-ptr -1
1054 .      ds doc-arg\n[doc-arg-ptr] ~
1055 .      nr doc-type\n[doc-arg-ptr] 2
1056 .      ds doc-space\n[doc-arg-ptr] "\*[doc-space]
1057 .
1058 .      \" recompute space vector for remaining arguments
1059 .      nr doc-num-args (\n[doc-arg-limit] - \n[doc-arg-ptr])
1060 .      nr doc-arg-limit \n[doc-arg-ptr]
1061 .      doc-parse-space-vector
1062 .    \}
1063 .    doc-print-recursive
1064 .  \}
1065 .  el \{\
1066 .    nop \*[doc-Pa-font]~\f[]\s[0]\c
1067 .    doc-print-and-reset
1068 .  \}
1069 ..
1070 .
1071 .
1072 .\" NS Sy user macro
1073 .\" NS   symbolics
1074 .\" NS
1075 .\" NS width register `Sy' set in doc-common
1076 .
1077 .als Sy doc-generic-macro
1078 .ds doc-Sy-usage symbolic_text
1079 .
1080 .
1081 .\" NS Me user macro
1082 .\" NS   menu entries
1083 .\" NS
1084 .\" NS width register `Me' set in doc-common
1085 .
1086 .als Me doc-generic-macro
1087 .ds doc-Me-usage menu_entry
1088 .
1089 .
1090 .\" NS Tn user macro
1091 .\" NS   trade name
1092 .\" NS
1093 .\" NS modifies:
1094 .\" NS   doc-arg-ptr
1095 .\" NS   doc-curr-font
1096 .\" NS   doc-curr-size
1097 .\" NS   doc-macro-name
1098 .\" NS
1099 .\" NS width register `Tn' set in doc-common
1100 .
1101 .de Tn
1102 .  if !\n[doc-arg-limit] \{\
1103 .    ie \n[.$] \{\
1104 .      ds doc-macro-name Tn
1105 .      doc-parse-args \$@
1106 .    \}
1107 .    el \
1108 .      tm Usage: .Tn trade_name ... (#\n[.c])
1109 .  \}
1110 .
1111 .  if !\n[doc-arg-limit] \
1112 .    return
1113 .
1114 .  nr doc-arg-ptr +1
1115 .  ie (\n[doc-arg-limit] >= \n[doc-arg-ptr]) \{\
1116 .    nr doc-curr-font \n[.f]
1117 .    nr doc-curr-size \n[.ps]
1118 .    nop \)\*[doc-Tn-font-size]\c
1119 .    ie !\n[doc-is-reference] \{\
1120 .      nop \)\*[doc-Tn-font-shape]\c
1121 .      doc-print-recursive
1122 .    \}
1123 .    el \
1124 .      doc-do-references
1125 .  \}
1126 .  el \{\
1127 .    tm Usage: .Tn trade_name ... (#\n[.c])
1128 .    doc-reset-args
1129 .  \}
1130 ..
1131 .
1132 .
1133 .\" NS Va user macro
1134 .\" NS   variable name
1135 .\" NS
1136 .\" NS width register `Va' set in doc-common
1137 .
1138 .als Va doc-generic-macro
1139 .ds doc-Va-usage variable_name
1140 .
1141 .
1142 .\" NS No user macro
1143 .\" NS   normal text macro (default text style if mess up)
1144 .\" NS
1145 .\" NS width register `No' set in doc-common
1146 .
1147 .als No doc-generic-macro
1148 .ds doc-No-usage normal_text
1149 .
1150 .
1151 .\" NS doc-quote-left global string
1152 .\" NS   left quotation character for `doc-enclose-string' and
1153 .\" NS   `doc-enclose-open'
1154 .
1155 .ds doc-quote-left
1156 .
1157 .
1158 .\" NS doc-quote-right global string
1159 .\" NS   right quotation character for `doc-enclose-string' and
1160 .\" NS   `doc-enclose-close'
1161 .
1162 .ds doc-quote-right
1163 .
1164 .
1165 .\" NS Op user macro
1166 .\" NS   option expression (i.e., enclose string in square brackets)
1167 .\" NS
1168 .\" NS modifies:
1169 .\" NS   doc-macro-name
1170 .\" NS   doc-quote-left
1171 .\" NS   doc-quote-right
1172 .\" NS
1173 .\" NS width register `Op' set in doc-common
1174 .
1175 .de Op
1176 .  if !\n[doc-arg-limit] \
1177 .    ds doc-macro-name Op
1178 .
1179 .  ds doc-quote-left "\*[doc-left-bracket]
1180 .  ds doc-quote-right "\*[doc-right-bracket]
1181 .
1182 .  doc-enclose-string \$@
1183 ..
1184 .
1185 .
1186 .\" NS Aq user macro
1187 .\" NS   enclose string in angle brackets
1188 .\" NS
1189 .\" NS modifies:
1190 .\" NS   doc-macro-name
1191 .\" NS   doc-quote-left
1192 .\" NS   doc-quote-right
1193 .\" NS
1194 .\" NS width register `Aq' set in doc-common
1195 .
1196 .de Aq
1197 .  if !\n[doc-arg-limit] \
1198 .    ds doc-macro-name Aq
1199 .
1200 .  ds doc-quote-left \[la]
1201 .  ds doc-quote-right \[ra]
1202 .
1203 .  doc-enclose-string \$@
1204 ..
1205 .
1206 .
1207 .\" NS Bq user macro
1208 .\" NS   enclose string in square brackets
1209 .\" NS
1210 .\" NS modifies:
1211 .\" NS   doc-macro-name
1212 .\" NS   doc-quote-left
1213 .\" NS   doc-quote-right
1214 .\" NS
1215 .\" NS width register `Bq' set in doc-common
1216 .
1217 .de Bq
1218 .  if !\n[doc-arg-limit] \
1219 .    ds doc-macro-name Bq
1220 .
1221 .  ds doc-quote-left "\*[doc-left-bracket]
1222 .  ds doc-quote-right "\*[doc-right-bracket]
1223 .
1224 .  doc-enclose-string \$@
1225 ..
1226 .
1227 .
1228 .\" NS Brq user macro
1229 .\" NS   enclose string in braces
1230 .\" NS
1231 .\" NS modifies:
1232 .\" NS   doc-macro-name
1233 .\" NS   doc-quote-left
1234 .\" NS   doc-quote-right
1235 .\" NS
1236 .\" NS width register `Brq' set in doc-common
1237 .
1238 .de Brq
1239 .  if !\n[doc-arg-limit] \
1240 .    ds doc-macro-name Brq
1241 .
1242 .  ds doc-quote-left {
1243 .  ds doc-quote-right }
1244 .
1245 .  doc-enclose-string \$@
1246 ..
1247 .
1248 .
1249 .\" NS Dq user macro
1250 .\" NS   enclose string in double quotes
1251 .\" NS
1252 .\" NS modifies:
1253 .\" NS   doc-macro-name
1254 .\" NS   doc-quote-left
1255 .\" NS   doc-quote-right
1256 .\" NS
1257 .\" NS width register `Dq' set in doc-common
1258 .
1259 .de Dq
1260 .  if !\n[doc-arg-limit] \
1261 .    ds doc-macro-name Dq
1262 .
1263 .  ds doc-quote-left "\*[Lq]
1264 .  ds doc-quote-right "\*[Rq]
1265 .
1266 .  doc-enclose-string \$@
1267 ..
1268 .
1269 .
1270 .\" NS Eq user macro
1271 .\" NS   enclose string in user-defined quotes (args 1 and 2)
1272 .\" NS
1273 .\" NS modifies:
1274 .\" NS   doc-macro-name
1275 .\" NS   doc-quote-left
1276 .\" NS   doc-quote-right
1277 .\" NS
1278 .\" NS width register `Eq' set in doc-common
1279 .
1280 .de Eq
1281 .  if !\n[doc-arg-limit] \
1282 .    ds doc-macro-name Eq
1283 .
1284 .  ds doc-quote-left "\$1
1285 .  ds doc-quote-right "\$2
1286 .
1287 .  shift 2
1288 .  doc-enclose-string \$@
1289 ..
1290 .
1291 .
1292 .\" NS Pq user macro
1293 .\" NS   enclose string in parentheses
1294 .\" NS
1295 .\" NS modifies:
1296 .\" NS   doc-macro-name
1297 .\" NS   doc-quote-left
1298 .\" NS   doc-quote-right
1299 .\" NS
1300 .\" NS width register `Pq' set in doc-common
1301 .
1302 .de Pq
1303 .  if !\n[doc-arg-limit] \
1304 .    ds doc-macro-name Pq
1305 .
1306 .  ds doc-quote-left "\*[doc-left-parenthesis]
1307 .  ds doc-quote-right "\*[doc-right-parenthesis]
1308 .
1309 .  doc-enclose-string \$@
1310 ..
1311 .
1312 .
1313 .\" NS Ql user macro
1314 .\" NS   quoted literal
1315 .\"
1316 .\"   is in file doc-[dit|n]roff
1317 .
1318 .
1319 .\" NS Qq user macro
1320 .\" NS   enclose string in straight double quotes
1321 .\" NS
1322 .\" NS modifies:
1323 .\" NS   doc-macro-name
1324 .\" NS   doc-quote-left
1325 .\" NS   doc-quote-right
1326 .\" NS
1327 .\" NS width register `Qq' set in doc-common
1328 .
1329 .de Qq
1330 .  if !\n[doc-arg-limit] \
1331 .    ds doc-macro-name Qq
1332 .
1333 .  ds doc-quote-left "\*[q]
1334 .  ds doc-quote-right "\*[q]
1335 .
1336 .  doc-enclose-string \$@
1337 ..
1338 .
1339 .
1340 .\" NS Sq user macro
1341 .\" NS   enclose string in single quotes
1342 .\" NS
1343 .\" NS modifies:
1344 .\" NS   doc-macro-name
1345 .\" NS   doc-quote-left
1346 .\" NS   doc-quote-right
1347 .\" NS
1348 .\" NS width register `Sq' set in doc-common
1349 .
1350 .de Sq
1351 .  if !\n[doc-arg-limit] \
1352 .    ds doc-macro-name Sq
1353 .
1354 .  ds doc-quote-left "\*[doc-left-singlequote]
1355 .  ds doc-quote-right "\*[doc-right-singlequote]
1356 .
1357 .  doc-enclose-string \$@
1358 ..
1359 .
1360 .
1361 .\" NS Es user macro
1362 .\" NS   set up arguments (i.e., the left and right quotation character as
1363 .\" NS   first and second argument) for .En call
1364 .\" NS
1365 .\" NS modifies:
1366 .\" NS   doc-arg-ptr
1367 .\" NS   doc-macro-name
1368 .\" NS   doc-quote-left
1369 .\" NS   doc-quote-right
1370 .
1371 .de Es
1372 .  if !\n[doc-arg-limit] \{\
1373 .    ie (\n[.$] > 2) \{\
1374 .      ds doc-macro-name Es
1375 .      doc-parse-args \$@
1376 .    \}
1377 .    el \{\
1378 .      ds doc-quote-left "\$1
1379 .      ds doc-quote-right "\$2
1380 .  \}\}
1381 .
1382 .  if !\n[doc-arg-limit] \
1383 .    return
1384 .
1385 .  nr doc-arg-ptr +1
1386 .  ds doc-quote-left "\*[doc-arg\n[doc-arg-ptr]]
1387 .  nr doc-arg-ptr +1
1388 .  ds doc-quote-right "\*[doc-arg\n[doc-arg-ptr]]
1389 .  nr doc-arg-ptr +1
1390 .  ie (\n[doc-arg-limit] >= \n[doc-arg-ptr]) \
1391 .    doc-do-\n[doc-type\n[doc-arg-ptr]]
1392 .  el \
1393 .    doc-print-and-reset
1394 ..
1395 .
1396 .
1397 .\" NS doc-have-slot global register (bool)
1398 .\" NS   set if `doc-enclose-string' has created a slot for closing
1399 .\" NS   delimiter
1400 .
1401 .nr doc-have-slot 0
1402 .
1403 .
1404 .\" NS doc-enclose-string macro
1405 .\" NS   enclose string with given args (e.g. [ and ])
1406 .\" NS
1407 .\" NS modifies:
1408 .\" NS   doc-arg-ptr
1409 .\" NS   doc-argXXX
1410 .\" NS   doc-have-slot
1411 .\" NS
1412 .\" NS local variables:
1413 .\" NS   doc-reg-des
1414 .\" NS   doc-reg-des1
1415 .\" NS   doc-reg-des2
1416 .\" NS
1417 .\" NS requires:
1418 .\" NS   doc-quote-left
1419 .\" NS   doc-quote-right
1420 .
1421 .de doc-enclose-string
1422 .  if \n[doc-in-synopsis-section] \
1423 .    doc-set-hard-space
1424 .
1425 .  if !\n[doc-arg-limit] \{\
1426 .    ie \n[.$] \
1427 .      doc-parse-args \$@
1428 .    el \{\
1429 .      nop \)\*[doc-quote-left]\*[doc-quote-right]
1430 .  \}\}
1431 .
1432 .  if !\n[doc-arg-limit] \
1433 .    return
1434 .
1435 .  nr doc-curr-font \n[.f]
1436 .  nr doc-curr-size \n[.ps]
1437 .
1438 .  nr doc-arg-ptr +1
1439 .  doc-print-prefixes
1440 .  \" the final `\)' prevents hyphenation in case the next character is `\%'
1441 .  nop \)\*[doc-quote-left]\)\c
1442 .  ie (\n[doc-arg-limit] < \n[doc-arg-ptr]) \{\
1443 .    \" last argument
1444 .    nop \)\*[doc-quote-right]\)\c
1445 .    doc-print-and-reset
1446 .  \}
1447 .  el \{\
1448 .    \" test whether last arguments are of type closing punctuation
1449 .    \" resp. suffix
1450 .    ie (\n[doc-type\n[doc-arg-limit]] == 3) \{\
1451 .      nr doc-reg-des (\n[doc-arg-limit] - 1)
1452 .      while (\n[doc-type\n[doc-reg-des]] == 3) \
1453 .        nr doc-reg-des -1
1454 .
1455 .      \" prepend closing delimiter
1456 .      nr doc-reg-des +1
1457 .      ds doc-arg\n[doc-reg-des] "\*[doc-quote-right]\)\*[doc-arg\n[doc-reg-des]]
1458 .    \}
1459 .    el \{\
1460 .      \" test whether last arguments are macros which continue the line
1461 .      \" logically
1462 .      nr doc-reg-des \n[doc-arg-limit]
1463 .      while (\n[doc-reg-des] >= \n[doc-arg-ptr]) \{\
1464 .        if !\A\a\*[doc-arg\n[doc-reg-des]]\a \
1465 .          break
1466 .        if !d doc-after-\*[doc-arg\n[doc-reg-des]] \
1467 .          break
1468 .        nr doc-reg-des -1
1469 .      \}
1470 .
1471 .      \" if there are no trailing macros to be skipped, append argument
1472 .      ie (\n[doc-reg-des] == \n[doc-arg-limit]) \
1473 .        doc-append-arg "\)\*[doc-quote-right]\)" 3
1474 .      el \{\
1475 .        \" if a previous call to `doc-enclose-string' has already created
1476 .        \" a slot, prepend argument
1477 .        ie \n[doc-have-slot] \
1478 .          ds doc-arg\n[doc-reg-des] "\*[doc-quote-right]\)\*[doc-arg\n[doc-reg-des]]
1479 .        el \{\
1480 .          \" we have to shift all arguments to the right
1481 .          nr doc-reg-des +1
1482 .          nr doc-reg-des1 \n[doc-arg-limit]
1483 .          nr doc-reg-des2 (\n[doc-arg-limit] + 1)
1484 .          while (\n[doc-reg-des1] >= \n[doc-reg-des]) \{\
1485 .            rn doc-arg\n[doc-reg-des1] doc-arg\n[doc-reg-des2]
1486 .            rnn doc-type\n[doc-reg-des1] doc-type\n[doc-reg-des2]
1487 .            rn doc-space\n[doc-reg-des1] doc-space\n[doc-reg-des2]
1488 .            nr doc-reg-des1 -1
1489 .            nr doc-reg-des2 -1
1490 .          \}
1491 .          nr doc-arg-limit +1
1492 .
1493 .          \" finally, insert closing delimiter into the freed slot and
1494 .          \" recompute spacing vector
1495 .          ds doc-arg\n[doc-reg-des] "\)\*[doc-quote-right]\)
1496 .          nr doc-type\n[doc-reg-des] 3
1497 .          nr doc-num-args (\n[doc-arg-limit] - \n[doc-reg-des] + 1)
1498 .          nr doc-arg-limit (\n[doc-reg-des] - 1)
1499 .          doc-parse-space-vector
1500 .          nr doc-have-slot 1
1501 .    \}\}\}
1502 .
1503 .    doc-do-\n[doc-type\n[doc-arg-ptr]]
1504 .  \}
1505 .
1506 .  if \n[doc-in-synopsis-section] \
1507 .    doc-set-soft-space
1508 ..
1509 .
1510 .
1511 .\" NS En user macro
1512 .\" NS   enclose arguments with quotation characters set up with `.Es'
1513 .
1514 .als En doc-enclose-string
1515 .
1516 .
1517 .\" NS Ao user macro
1518 .\" NS   angle open
1519 .\" NS
1520 .\" NS modifies:
1521 .\" NS   doc-macro-name
1522 .\" NS   doc-quote-left
1523 .\" NS
1524 .\" NS width register `Ao' set in doc-common
1525 .
1526 .de Ao
1527 .  if !\n[doc-arg-limit] \
1528 .    ds doc-macro-name Ao
1529 .
1530 .  ds doc-quote-left \[la]
1531 .
1532 .  doc-enclose-open \$@
1533 ..
1534 .
1535 .
1536 .\" NS Ac user macro
1537 .\" NS   angle close
1538 .\" NS
1539 .\" NS modifies:
1540 .\" NS   doc-macro-name
1541 .\" NS   doc-quote-right
1542 .\" NS
1543 .\" NS width register `Ac' set in doc-common
1544 .
1545 .de Ac
1546 .  if !\n[doc-arg-limit] \
1547 .    ds doc-macro-name Ac
1548 .
1549 .  ds doc-quote-right \[ra]
1550 .
1551 .  doc-enclose-close \$@
1552 ..
1553 .
1554 .
1555 .\" NS Bo user macro
1556 .\" NS   bracket open
1557 .\" NS
1558 .\" NS modifies:
1559 .\" NS   doc-macro-name
1560 .\" NS   doc-quote-left
1561 .\" NS
1562 .\" NS width register `Bo' set in doc-common
1563 .
1564 .de Bo
1565 .  if !\n[doc-arg-limit] \
1566 .    ds doc-macro-name Bo
1567 .
1568 .  ds doc-quote-left "\*[doc-left-bracket]
1569 .
1570 .  doc-enclose-open \$@
1571 ..
1572 .
1573 .
1574 .\" NS Bc user macro
1575 .\" NS   bracket close
1576 .\" NS
1577 .\" NS modifies:
1578 .\" NS   doc-macro-name
1579 .\" NS   doc-quote-right
1580 .\" NS
1581 .\" NS width register `Bc' set in doc-common
1582 .
1583 .de Bc
1584 .  if !\n[doc-arg-limit] \
1585 .    ds doc-macro-name Bc
1586 .
1587 .  ds doc-quote-right "\*[doc-right-bracket]
1588 .
1589 .  doc-enclose-close \$@
1590 ..
1591 .
1592 .
1593 .\" NS Bro user macro
1594 .\" NS   brace open
1595 .\" NS
1596 .\" NS modifies:
1597 .\" NS   doc-macro-name
1598 .\" NS   doc-quote-left
1599 .\" NS
1600 .\" NS width register `Bro' set in doc-common
1601 .
1602 .de Bro
1603 .  if !\n[doc-arg-limit] \
1604 .    ds doc-macro-name Bo
1605 .
1606 .  ds doc-quote-left {
1607 .
1608 .  doc-enclose-open \$@
1609 ..
1610 .
1611 .
1612 .\" NS Brc user macro
1613 .\" NS   brace close
1614 .\" NS
1615 .\" NS modifies:
1616 .\" NS   doc-macro-name
1617 .\" NS   doc-quote-right
1618 .\" NS
1619 .\" NS width register `Brc' set in doc-common
1620 .
1621 .de Brc
1622 .  if !\n[doc-arg-limit] \
1623 .    ds doc-macro-name Bc
1624 .
1625 .  ds doc-quote-right }
1626 .
1627 .  doc-enclose-close \$@
1628 ..
1629 .
1630 .
1631 .\" NS Do user macro
1632 .\" NS   double quote open
1633 .\" NS
1634 .\" NS modifies:
1635 .\" NS   doc-macro-name
1636 .\" NS   doc-quote-left
1637 .\" NS
1638 .\" NS width register `Do' set in doc-common
1639 .
1640 .de Do
1641 .  if !\n[doc-arg-limit] \
1642 .    ds doc-macro-name Do
1643 .
1644 .  ds doc-quote-left "\*[Lq]
1645 .
1646 .  doc-enclose-open \$@
1647 ..
1648 .
1649 .
1650 .\" NS Dc user macro
1651 .\" NS   double quote close
1652 .\" NS
1653 .\" NS modifies:
1654 .\" NS   doc-macro-name
1655 .\" NS   doc-quote-right
1656 .\" NS
1657 .\" NS width register `Dc' set in doc-common
1658 .
1659 .de Dc
1660 .  if !\n[doc-arg-limit] \
1661 .    ds doc-macro-name Dc
1662 .
1663 .  ds doc-quote-right "\*[Rq]
1664 .
1665 .  doc-enclose-close \$@
1666 ..
1667 .
1668 .
1669 .\" NS Eo user macro
1670 .\" NS   enclose open (using first argument as beginning of enclosure)
1671 .\" NS
1672 .\" NS modifies:
1673 .\" NS   doc-macro-name
1674 .\" NS   doc-quote-left
1675 .\" NS
1676 .\" NS width register `Eo' set in doc-common
1677 .
1678 .de Eo
1679 .  if !\n[doc-arg-limit] \
1680 .    ds doc-macro-name Eo
1681 .
1682 .  ds doc-quote-left "\$1
1683 .
1684 .  shift
1685 .  doc-enclose-open \$@
1686 ..
1687 .
1688 .
1689 .\" NS Ec user macro
1690 .\" NS   enclose close (using first argument as end of enclosure)
1691 .\" NS
1692 .\" NS modifies:
1693 .\" NS   doc-macro-name
1694 .\" NS   doc-quote-right
1695 .\" NS
1696 .\" NS width register `Ec' set in doc-common
1697 .
1698 .de Ec
1699 .  if !\n[doc-arg-limit] \
1700 .    ds doc-macro-name Ec
1701 .
1702 .  ds doc-quote-right "\$1
1703 .
1704 .  shift
1705 .  doc-enclose-close \$@
1706 ..
1707 .
1708 .
1709 .\" NS Oo user macro
1710 .\" NS   option open
1711 .\" NS
1712 .\" NS modifies:
1713 .\" NS   doc-macro-name
1714 .\" NS   doc-quote-left
1715 .\" NS
1716 .\" NS width register `Oo' set in doc-common
1717 .
1718 .de Oo
1719 .  if !\n[doc-arg-limit] \
1720 .    ds doc-macro-name Oo
1721 .
1722 .  ds doc-quote-left [
1723 .
1724 .  doc-enclose-open \$@
1725 ..
1726 .
1727 .
1728 .\" NS Oc user macro
1729 .\" NS   option close
1730 .\" NS
1731 .\" NS modifies:
1732 .\" NS   doc-macro-name
1733 .\" NS   doc-quote-right
1734 .\" NS
1735 .\" NS width register `Oc' set in doc-common
1736 .
1737 .de Oc
1738 .  if !\n[doc-arg-limit] \
1739 .    ds doc-macro-name Oc
1740 .
1741 .  ds doc-quote-right ]
1742 .
1743 .  doc-enclose-close \$@
1744 ..
1745 .
1746 .
1747 .\" NS Po user macro
1748 .\" NS   parenthesis open
1749 .\" NS
1750 .\" NS modifies:
1751 .\" NS   doc-macro-name
1752 .\" NS   doc-quote-left
1753 .\" NS
1754 .\" NS width register `Po' set in doc-common
1755 .
1756 .de Po
1757 .  if !\n[doc-arg-limit] \
1758 .    ds doc-macro-name Po
1759 .
1760 .  ds doc-quote-left "\*[doc-left-parenthesis]
1761 .
1762 .  doc-enclose-open \$@
1763 ..
1764 .
1765 .
1766 .\" NS Pc user macro
1767 .\" NS   parenthesis close
1768 .\" NS
1769 .\" NS modifies:
1770 .\" NS   doc-macro-name
1771 .\" NS   doc-quote-right
1772 .\" NS
1773 .\" NS width register `Pc' set in doc-common
1774 .
1775 .de Pc
1776 .  if !\n[doc-arg-limit] \
1777 .    ds doc-macro-name Pc
1778 .
1779 .  ds doc-quote-right "\*[doc-right-parenthesis]
1780 .
1781 .  doc-enclose-close \$@
1782 ..
1783 .
1784 .
1785 .\" NS Qo user macro
1786 .\" NS   straight double quote open
1787 .\" NS
1788 .\" NS modifies:
1789 .\" NS   doc-macro-name
1790 .\" NS   doc-quote-left
1791 .\" NS
1792 .\" NS width register `Qo' set in doc-common
1793 .
1794 .de Qo
1795 .  if !\n[doc-arg-limit] \
1796 .    ds doc-macro-name Qo
1797 .
1798 .  ds doc-quote-left "\*[q]
1799 .
1800 .  doc-enclose-open \$@
1801 ..
1802 .
1803 .
1804 .\" NS Qc user macro
1805 .\" NS   straight double quote close
1806 .\" NS
1807 .\" NS modifies:
1808 .\" NS   doc-macro-name
1809 .\" NS   doc-quote-right
1810 .\" NS
1811 .\" NS width register `Qc' set in doc-common
1812 .
1813 .de Qc
1814 .  if !\n[doc-arg-limit] \
1815 .    ds doc-macro-name Qc
1816 .
1817 .  ds doc-quote-right "\*[q]
1818 .
1819 .  doc-enclose-close \$@
1820 ..
1821 .
1822 .
1823 .\" NS So user macro
1824 .\" NS   single quote open
1825 .\" NS
1826 .\" NS modifies:
1827 .\" NS   doc-macro-name
1828 .\" NS   doc-quote-left
1829 .\" NS
1830 .\" NS width register `So' set in doc-common
1831 .
1832 .de So
1833 .  if !\n[doc-arg-limit] \
1834 .    ds doc-macro-name So
1835 .
1836 .  ds doc-quote-left "\*[doc-left-singlequote]
1837 .
1838 .  doc-enclose-open \$@
1839 ..
1840 .
1841 .
1842 .\" NS Sc user macro
1843 .\" NS   single quote close
1844 .\" NS
1845 .\" NS modifies:
1846 .\" NS   doc-macro-name
1847 .\" NS   doc-quote-right
1848 .\" NS
1849 .\" NS width register `Sc' set in doc-common
1850 .
1851 .de Sc
1852 .  if !\n[doc-arg-limit] \
1853 .    ds doc-macro-name Sc
1854 .
1855 .  ds doc-quote-right "\*[doc-right-singlequote]
1856 .
1857 .  doc-enclose-close \$@
1858 ..
1859 .
1860 .
1861 .\" NS Xo user macro
1862 .\" NS   extend open
1863 .\" NS
1864 .\" NS modifies:
1865 .\" NS   doc-macro-name
1866 .\" NS   doc-quote-left
1867 .\" NS
1868 .\" NS width register `Xo' set in doc-common
1869 .
1870 .de Xo
1871 .  if !\n[doc-arg-limit] \
1872 .    ds doc-macro-name Xo
1873 .
1874 .  ds doc-quote-left
1875 .
1876 .  doc-enclose-open \$@
1877 ..
1878 .
1879 .
1880 .\" NS Xc user macro
1881 .\" NS   extend close
1882 .\" NS
1883 .\" NS modifies:
1884 .\" NS   doc-macro-name
1885 .\" NS   doc-quote-right
1886 .\" NS
1887 .\" NS width register `Xc' set in doc-common
1888 .
1889 .de Xc
1890 .  if !\n[doc-arg-limit] \
1891 .    ds doc-macro-name Xc
1892 .
1893 .  ds doc-quote-right
1894 .
1895 .  doc-enclose-close \$@
1896 ..
1897 .
1898 .
1899 .\" NS doc-nesting-level global register
1900 .\" NS   used by `doc-enclose-open' and `doc-enclose-close'
1901 .
1902 .nr doc-nesting-level 0
1903 .
1904 .
1905 .\" NS doc-in-list global register (bool)
1906 .\" NS   whether we are in (logical) .It
1907 .
1908 .nr doc-in-list 0
1909 .
1910 .
1911 .\" NS doc-enclose-open macro
1912 .\" NS   enclose string open
1913 .\" NS
1914 .\" NS modifies:
1915 .\" NS   doc-arg-ptr
1916 .\" NS   doc-nesting-level
1917 .
1918 .de doc-enclose-open
1919 .  if !\n[doc-arg-limit] \
1920 .    doc-parse-args \$@
1921 .
1922 .  nr doc-arg-ptr +1
1923 .  doc-print-prefixes
1924 .  nr doc-arg-ptr -1
1925 .
1926 .  nop \)\*[doc-quote-left]\)\c
1927 .
1928 .  \" start enclosure box
1929 .  box doc-enclosure-box\n[doc-nesting-level]
1930 .  ev doc-enclosure-env\n[doc-nesting-level]
1931 .  evc 0
1932 .  in 0
1933 .  nf
1934 .  \" we insert something to make .chop always work
1935 .  nop \&\c
1936 .
1937 .  \" increase nesting level *after* parsing of arguments
1938 .  nr doc-nesting-level +1
1939 .
1940 .  if \n[doc-arg-limit] \{\
1941 .    nr doc-arg-ptr +1
1942 .    ie (\n[doc-arg-limit] >= \n[doc-arg-ptr]) \
1943 .      doc-print-recursive
1944 .    el \
1945 .      doc-reset-args
1946 .  \}
1947 ..
1948 .
1949 .
1950 .\" NS doc-enclose-close macro
1951 .\" NS   enclose string close
1952 .\" NS
1953 .\" NS modifies:
1954 .\" NS   doc-nesting-level
1955 .
1956 .de doc-enclose-close
1957 .  nr doc-nesting-level -1
1958 .
1959 .  \" finish enclosure box
1960 .  br
1961 .  ev
1962 .  box
1963 .  chop doc-enclosure-box\n[doc-nesting-level]
1964 .  unformat doc-enclosure-box\n[doc-nesting-level]
1965 .
1966 .  nh
1967 .  nop \*[doc-enclosure-box\n[doc-nesting-level]]\c
1968 .  nop \)\*[doc-quote-right]\)\c
1969 .
1970 .  if !\n[doc-arg-limit] \{\
1971 .    doc-parse-args \$@
1972 .
1973 .    if !\n[.$] \
1974 .      doc-print-and-reset
1975 .  \}
1976 .
1977 .  if \n[doc-arg-limit] \{\
1978 .    ie (\n[doc-arg-limit] > \n[doc-arg-ptr]) \{\
1979 .      nop \)\*[doc-space\n[doc-arg-ptr]]\c
1980 .      nr doc-arg-ptr +1
1981 .      doc-print-recursive
1982 .    \}
1983 .    el \
1984 .      doc-print-and-reset
1985 .  \}
1986 .
1987 .  \" shall we finish .It macro?
1988 .  if !"\*[doc-macro-name]"It" \
1989 .    if \n[doc-in-list] \
1990 .      if !\n[doc-nesting-level] \
1991 .        doc-\*[doc-list-type-stack\n[doc-list-depth]]
1992 ..
1993 .
1994 .
1995 .\" NS Pf user macro
1996 .\" NS   prefix: `.Pf prefix arg ...'
1997 .\" NS
1998 .\" NS modifies:
1999 .\" NS   doc-arg-ptr
2000 .\" NS   doc-macro-name
2001 .\" NS   doc-quote-left
2002 .\" NS
2003 .\" NS width register `Pf' set in doc-common
2004 .
2005 .de Pf
2006 .  if !\n[doc-arg-limit] \
2007 .    ds doc-macro-name Pf
2008 .
2009 .  ie \n[doc-arg-limit] \{\
2010 .    ie ((\n[doc-arg-limit] - \n[doc-arg-ptr]) > 1) \{\
2011 .      nr doc-arg-ptr +1
2012 .      nop \)\*[doc-arg\n[doc-arg-ptr]]\c
2013 .    \}
2014 .    el \
2015 .      tm mdoc warning: .Pf: trailing prefix (#\n[.c])
2016 .  \}
2017 .  el \{\
2018 .    nop \)\$1\)\c
2019 .    shift
2020 .    ie \n[.$] \
2021 .      doc-parse-args \$@
2022 .    el \{\
2023 .      tm mdoc warning: .Pf: missing arguments (#\n[.c])
2024 .      nop \)
2025 .  \}\}
2026 .
2027 .  if \n[doc-arg-limit] \{\
2028 .    nr doc-arg-ptr +1
2029 .    ie (\n[doc-arg-limit] < \n[doc-arg-ptr]) \
2030 .      doc-print-and-reset
2031 .    el \
2032 .      doc-do-\n[doc-type\n[doc-arg-ptr]]
2033 .  \}
2034 ..
2035 .
2036 .
2037 .\" NS Ns user macro
2038 .\" NS   remove space (space removal done by `doc-parse-args')
2039 .\" NS
2040 .\" NS modifies:
2041 .\" NS   doc-argXXX
2042 .\" NS   doc-macro-name
2043 .\" NS
2044 .\" NS width register `Ns' set in doc-common
2045 .
2046 .de Ns
2047 .  if !\n[doc-arg-limit] \{\
2048 .    ie \n[.$] \{\
2049 .      ds doc-macro-name Ns
2050 .      doc-parse-args \$@
2051 .    \}
2052 .    el \
2053 .      tm Usage: .Ns must be called with arguments (#\n[.c])
2054 .  \}
2055 .
2056 .  if \n[doc-arg-limit] \{\
2057 .    nr doc-arg-ptr +1
2058 .    ie (\n[doc-arg-limit] >= \n[doc-arg-ptr]) \
2059 .      doc-print-recursive
2060 .    el \
2061 .      doc-reset-args
2062 .  \}
2063 ..
2064 .
2065 .
2066 .\" NS Ap user macro
2067 .\" NS   append an apostrophe
2068 .\" NS
2069 .\" NS width register `Ap' set in doc-common
2070 .
2071 .de Ap
2072 .  ie !\n[doc-arg-limit] \
2073 .    tm Usage: `Ap' cannot be first macro on a line (no `.Ap') (#\n[.c])
2074 .  el \{\
2075 .    nop \)'\)\c
2076 .    nr doc-arg-ptr +1
2077 .    ie (\n[doc-arg-limit] >= \n[doc-arg-ptr]) \
2078 .      doc-print-recursive
2079 .    el \
2080 .      doc-reset-args
2081 .  \}
2082 ..
2083 .
2084 .
2085 .\" NS doc-space global string
2086 .\" NS   current inter-argument space
2087 .
2088 .ds doc-space "\*[doc-soft-space]
2089 .
2090 .
2091 .\" NS doc-soft-space constant string
2092 .\" NS   soft (stretchable) space (defined in doc-common)
2093 .
2094 .
2095 .\" NS doc-hard-space constant string
2096 .\" NS   hard (unpaddable) space (defined in doc-common)
2097 .
2098 .
2099 .\" NS doc-set-hard-space macro
2100 .\" NS   set current space string to hard (unpaddable) space.
2101 .\" NS
2102 .\" NS modifies:
2103 .\" NS   doc-saved-space
2104 .\" NS   doc-space
2105 .
2106 .de doc-set-hard-space
2107 .  ie "\*[doc-space]"" \
2108 .    ds doc-saved-space "\*[doc-hard-space]
2109 .  el \
2110 .    ds doc-space "\*[doc-hard-space]
2111 ..
2112 .
2113 .
2114 .\" NS doc-set-soft-space macro
2115 .\" NS   set current space string to soft space
2116 .\" NS
2117 .\" NS modifies:
2118 .\" NS   doc-saved-space
2119 .\" NS   doc-space
2120 .
2121 .de doc-set-soft-space
2122 .  ie "\*[doc-space]"" \
2123 .    ds doc-saved-space "\*[doc-soft-space]
2124 .  el \
2125 .    ds doc-space "\*[doc-soft-space]
2126 ..
2127 .
2128 .
2129 .\" NS doc-space-mode global register (bool)
2130 .\" NS   default is one (space mode on)
2131 .
2132 .nr doc-space-mode 1
2133 .
2134 .
2135 .\" NS doc-saved-space global string
2136 .\" NS   saved value of `doc-space'
2137 .
2138 .ds doc-saved-space "\*[doc-space]
2139 .
2140 .
2141 .\" NS doc-have-space global register (bool)
2142 .\" NS   set if last command was horizontal space
2143 .
2144 .nr doc-have-space 0
2145 .
2146 .
2147 .\" NS Sm user macro
2148 .\" NS   space mode (`.Sm'/`.Sm on'/`.Sm off')
2149 .\" NS
2150 .\" NS   without argument, toggle space mode
2151 .\" NS
2152 .\" NS modifies:
2153 .\" NS   doc-arg-limit
2154 .\" NS   doc-arg-ptr
2155 .\" NS   doc-argXXX
2156 .\" NS   doc-macro-name
2157 .\" NS   doc-num-args
2158 .\" NS   doc-saved-space
2159 .\" NS   doc-space
2160 .\" NS   doc-space-mode
2161 .\" NS   doc-spaceXXX
2162 .\" NS
2163 .\" NS local variables:
2164 .\" NS   doc-reg-Sm
2165 .\" NS
2166 .\" NS width register `Sm' set in doc-common
2167 .
2168 .de Sm
2169 .  ie \n[doc-have-space] \
2170 .    nr doc-reg-Sm 0
2171 .  el \
2172 .    nr doc-reg-Sm 1
2173 .
2174 .  if !\n[doc-arg-limit] \{\
2175 .    ie \n[.$] \{\
2176 .      ds doc-macro-name Sm
2177 .      doc-parse-args \$@
2178 .    \}
2179 .    el \{\
2180 .      ie \n[doc-space-mode] \{\
2181 .        ds doc-saved-space "\*[doc-space]
2182 .        ds doc-space
2183 .        nr doc-space-mode 0
2184 .      \}
2185 .      el \{\
2186 .        ds doc-space "\*[doc-saved-space]
2187 .        nr doc-space-mode 1
2188 .
2189 .        \" finish line only if it is interrupted and `doc-have-space'
2190 .        \" isn't set
2191 .        if \n[doc-reg-Sm] \
2192 .          if \n[.int] \
2193 .            nop \)
2194 .      \}
2195 .  \}\}
2196 .
2197 .  if !\n[doc-arg-limit] \
2198 .    return
2199 .
2200 .  nr doc-arg-ptr +1
2201 .
2202 .  \" avoid a warning message in case `Sm' is the last parameter
2203 .  if !d doc-arg\n[doc-arg-ptr] \
2204 .    ds doc-arg\n[doc-arg-ptr]
2205 .
2206 .  ie "\*[doc-arg\n[doc-arg-ptr]]"on" \{\
2207 .    ds doc-space "\*[doc-saved-space]
2208 .    nr doc-space-mode 1
2209 .  \}
2210 .  el \{\
2211 .    ie "\*[doc-arg\n[doc-arg-ptr]]"off" \{\
2212 .      ds doc-saved-space "\*[doc-space]
2213 .      ds doc-space
2214 .      nr doc-space-mode 0
2215 .    \}
2216 .    el \{\
2217 .      \" no argument for Sm
2218 .      nr doc-arg-ptr -1
2219 .      ie \n[doc-space-mode] \{\
2220 .        ds doc-saved-space "\*[doc-space]
2221 .        ds doc-space
2222 .        nr doc-space-mode 0
2223 .      \}
2224 .      el \{\
2225 .        ds doc-space "\*[doc-saved-space]
2226 .        nr doc-space-mode 1
2227 .      \}
2228 .  \}\}
2229 .
2230 .  ie \n[doc-space-mode] \{\
2231 .    \" recompute space vector for remaining arguments
2232 .    nr doc-num-args (\n[doc-arg-limit] - \n[doc-arg-ptr])
2233 .    nr doc-arg-limit \n[doc-arg-ptr]
2234 .    if \n[doc-num-args] \
2235 .      doc-parse-space-vector
2236 .
2237 .    \" finish line only if it is interrupted and `doc-have-space'
2238 .    \" isn't set
2239 .    if \n[doc-reg-Sm] \
2240 .      if \n[.int] \
2241 .        nop \)
2242 .  \}
2243 .  el \{\
2244 .    \" reset remaining space vector elements
2245 .    nr doc-reg-Sm (\n[doc-arg-ptr] + 1)
2246 .    while (\n[doc-reg-Sm] <= \n[doc-arg-limit]) \{\
2247 .      ds doc-space\n[doc-reg-Sm]
2248 .      nr doc-reg-Sm +1
2249 .      \" the body of a `while' request must end with the fitting `\}'!
2250 .    \}
2251 .  \}
2252 .
2253 .  \" do we have parameters to print?
2254 .  ie (\n[doc-arg-limit] > \n[doc-arg-ptr]) \{\
2255 .    \" skip `Sm' argument
2256 .    nr doc-arg-ptr +1
2257 .    doc-print-recursive
2258 .  \}
2259 .  el \
2260 .    doc-reset-args
2261 ..
2262 .
2263 .
2264 .\" NS doc-arg-type immediate register
2265 .\" NS   argument type (macro=1, string=2, punctuation suffix=3,
2266 .\" NS   punctuation prefix=4)
2267 .
2268 .nr doc-arg-type 0
2269 .
2270 .
2271 .\" NS doc-get-arg-type macro
2272 .\" NS   get argument type
2273 .\" NS
2274 .\" NS   this macro expects the width of the argument in `doc-width'
2275 .\" NS
2276 .\" NS modifies:
2277 .\" NS   doc-arg-type
2278 .
2279 .de doc-get-arg-type
2280 .  nr doc-arg-type 2
2281 .
2282 .  if ((\n[doc-width] < 4) & \A\a\$1\a) \{\
2283 .    ie (\n[doc-width] == 1) \{\
2284 .      if r doc-punct\$1 \
2285 .        nr doc-arg-type \n[doc-punct\$1]
2286 .    \}
2287 .    el \
2288 .      if r \$1 \
2289 .        if d \$1 \
2290 .          nr doc-arg-type 1
2291 .  \}
2292 ..
2293 .
2294 .
2295 .\" NS doc-get-arg-type* macro
2296 .\" NS   similar to as `doc-get-arg-type' but uses doc-argXXX strings
2297 .\" NS
2298 .\" NS   this macro sets the `doc-width' register using the `length' request
2299 .\" NS   to get the number of characters in a string literally
2300 .\" NS
2301 .\" NS modifies:
2302 .\" NS   doc-arg-type
2303 .\" NS   doc-width
2304 .
2305 .de doc-get-arg-type*
2306 .  nr doc-arg-type 2
2307 .  length doc-width "\*[doc-arg\$1]
2308 .
2309 .  if ((\n[doc-width] < 4) & \A\a\*[doc-arg\$1]\a) \{\
2310 .    ie (\n[doc-width] == 1) \{\
2311 .      if r doc-punct\*[doc-arg\$1] \
2312 .        nr doc-arg-type \n[doc-punct\*[doc-arg\$1]]
2313 .    \}
2314 .    el \
2315 .      if r \*[doc-arg\$1] \
2316 .        if d \*[doc-arg\$1] \
2317 .          nr doc-arg-type 1
2318 .  \}
2319 ..
2320 .
2321 .
2322 .\" NS doc-set-spacing-1 macro
2323 .\" NS   set spacing for macros
2324 .\" NS
2325 .\" NS modifies:
2326 .\" NS   doc-spaceXXX
2327 .\" NS
2328 .\" NS local variables:
2329 .\" NS   doc-reg-dssfm
2330 .\" NS   doc-reg-dssfm1
2331 .
2332 .de doc-set-spacing-1
2333 .  nr doc-reg-dssfm1 \n[\*[doc-arg\n[doc-arg-limit]]]
2334 .
2335 .  \" closing macros like .Ac, Bc., etc. have value 3 (remove space before
2336 .  \" argument)
2337 .  ie (\n[doc-reg-dssfm1] == 3) \{\
2338 .    if \n[doc-arg-limit] \{\
2339 .      nr doc-reg-dssfm (\n[doc-arg-limit] - 1)
2340 .      ds doc-space\n[doc-reg-dssfm]
2341 .    \}
2342 .    ds doc-space\n[doc-arg-limit] "\*[doc-space]
2343 .  \}
2344 .  el \{\
2345 .    \" macros like .Ap and .Ns have value 2 (remove space before and after
2346 .    \" argument)
2347 .    ie (\n[doc-reg-dssfm1] == 2) \{\
2348 .      if \n[doc-arg-limit] \{\
2349 .        nr doc-reg-dssfm (\n[doc-arg-limit] - 1)
2350 .        ds doc-space\n[doc-reg-dssfm]
2351 .      \}
2352 .      ds doc-space\n[doc-arg-limit]
2353 .    \}
2354 .    el \
2355 .      ds doc-space\n[doc-arg-limit]
2356 .  \}
2357 ..
2358 .
2359 .
2360 .\" NS doc-set-spacing-2 macro
2361 .\" NS   set spacing for strings
2362 .\" NS
2363 .\" NS modifies:
2364 .\" NS   doc-spaceXXX
2365 .
2366 .de doc-set-spacing-2
2367 .  ds doc-space\n[doc-arg-limit] "\*[doc-space]
2368 ..
2369 .
2370 .
2371 .\" NS doc-set-spacing-3 macro
2372 .\" NS   set spacing for punctuation suffixes
2373 .\" NS
2374 .\" NS modifies:
2375 .\" NS   doc-spaceXXX
2376 .\" NS
2377 .\" NS local variables:
2378 .\" NS   doc-reg-dssfps
2379 .
2380 .de doc-set-spacing-3
2381 .  if \n[doc-arg-limit] \{\
2382 .    nr doc-reg-dssfps (\n[doc-arg-limit] - 1)
2383 .    ds doc-space\n[doc-reg-dssfps]
2384 .  \}
2385 .
2386 .  ds doc-space\n[doc-arg-limit] "\*[doc-space]
2387 ..
2388 .
2389 .
2390 .\" NS doc-set-spacing-4 macro
2391 .\" NS   set spacing for punctuation prefixes
2392 .\" NS
2393 .\" NS modifies:
2394 .\" NS   doc-spaceXXX
2395 .
2396 .de doc-set-spacing-4
2397 .  ds doc-space\n[doc-arg-limit]
2398 ..
2399 .
2400 .
2401 .\" type switches (on current argument doc-arg-ptr)
2402 .
2403 .
2404 .\" NS doc-do-1 macro
2405 .\" NS   call request if macro
2406 .
2407 .de doc-do-1
2408 .  \*[doc-arg\n[doc-arg-ptr]]
2409 ..
2410 .
2411 .
2412 .\" NS doc-do-2 macro
2413 .\" NS   call .doc-print-recursive if string
2414 .
2415 .als doc-do-2 doc-print-recursive
2416 .
2417 .
2418 .\" NS doc-do-3 macro
2419 .\" NS   call .doc-print-recursive if punctuation suffix
2420 .
2421 .als doc-do-3 doc-print-recursive
2422 .
2423 .
2424 .\" NS doc-do-4 macro
2425 .\" NS   call .doc-print-recursive if punctuation prefix
2426 .
2427 .als doc-do-4 doc-print-recursive
2428 .
2429 .
2430 .\" NS doc-fontmode-depth global register
2431 .\" NS   font mode level
2432 .
2433 .nr doc-fontmode-depth 0
2434 .
2435 .
2436 .\" NS doc-fontmode-font-stackXXX global register
2437 .\" NS   stack of saved current font values from `Bf' macro
2438 .\" NS
2439 .\" NS limit:
2440 .\" NS   doc-fontmode-depth
2441 .
2442 .nr doc-fontmode-font-stack0 0
2443 .
2444 .
2445 .\" NS doc-fontmode-size-stackXXX global register
2446 .\" NS   stack of saved current size values from `Bf' macro
2447 .\" NS
2448 .\" NS limit:
2449 .\" NS   doc-fontmode-depth
2450 .
2451 .nr doc-fontmode-size-stack0 0
2452 .
2453 .
2454 .\" NS Bf user macro
2455 .\" NS   begin font mode (will be begin-mode/end-mode in groff & TeX)
2456 .\" NS
2457 .\" NS modifies:
2458 .\" NS   doc-fontmode-depth
2459 .\" NS   doc-fontmode-font-stackXXX
2460 .\" NS   doc-fontmode-size-stackXXX
2461 .\" NS   doc-macro-name
2462 .\" NS
2463 .\" NS width register `Bf' set in doc-common
2464 .
2465 .de Bf
2466 .  ds doc-macro-name Bf
2467 .
2468 .  ie \n[.$] \{\
2469 .    nr doc-fontmode-depth +1
2470 .
2471 .    \" save current font and size
2472 .    nr doc-fontmode-font-stack\n[doc-fontmode-depth] \n[.f]
2473 .    nr doc-fontmode-size-stack\n[doc-fontmode-depth] \n[.ps]
2474 .
2475 .    ie        "\$1"Em" \
2476 .      nop \*[doc-Em-font]\c
2477 .    el \{ .ie "\$1"Li" \
2478 .      nop \*[doc-Li-font]\c
2479 .    el \{ .ie "\$1"Sy" \
2480 .      nop \*[doc-Sy-font]\c
2481 .    el \{ .ie "\$1"-emphasis" \
2482 .      nop \*[doc-Em-font]\c
2483 .    el \{ .ie "\$1"-literal" \
2484 .      nop \*[doc-Li-font]\c
2485 .    el \{ .ie "\$1"-symbolic" \
2486 .      nop \*[doc-Sy-font]\c
2487 .    el \{\
2488 .      tmc mdoc warning: Unknown keyword `\$1' in .Bf macro
2489 .      tm1 " (#\n[.c])
2490 .  \}\}\}\}\}\}\}
2491 .  el \
2492 .    tm Usage: .Bf [Em | -emphasis | Li | -literal | Sy | -symbolic] (#\n[.c])
2493 ..
2494 .
2495 .
2496 .\" NS Ef user macro
2497 .\" NS   end font mode
2498 .\" NS
2499 .\" NS modifies:
2500 .\" NS   doc-macro-name
2501 .\" NS
2502 .\" NS width register `Ef' set in doc-common
2503 .
2504 .de Ef
2505 .  ds doc-macro-name Ef
2506 .
2507 .  ie \n[doc-fontmode-depth] \{\
2508 .    \" restore saved font and size
2509 .    nop \)\f[\n[doc-fontmode-font-stack\n[doc-fontmode-depth]]]\c
2510 .    nop \)\s[\n[doc-fontmode-size-stack\n[doc-fontmode-depth]]u]\c
2511 .
2512 .    nr doc-fontmode-font-stack\n[doc-fontmode-depth] 0
2513 .    nr doc-curr-font \n[.f]
2514 .    nr doc-fontmode-size-stack\n[doc-fontmode-depth] 0
2515 .    nr doc-curr-size \n[.ps]
2516 .    nr doc-fontmode-depth -1
2517 .  \}
2518 .  el \
2519 .    tm mdoc warning: Extraneous .Ef (#\n[.c])
2520 ..
2521 .
2522 .
2523 .\" NS doc-keep-type global register
2524 .\" NS   current keep type; 1 is `-words', 2 is `-lines', 3 is unknown
2525 .
2526 .nr doc-keep-type 0
2527 .
2528 .
2529 .\" NS Bk user macro
2530 .\" NS   begin keep
2531 .\" NS
2532 .\" NS modifies:
2533 .\" NS   doc-keep-type
2534 .\" NS   doc-macro-name
2535 .\" NS
2536 .\" NS width register `Bk' set in doc-common
2537 .
2538 .de Bk
2539 .  ds doc-macro-name Bk
2540 .
2541 .  if \n[doc-keep-type] \
2542 .    tm .Bk: nesting keeps not implemented yet. (#\n[.c])
2543 .
2544 .  ie        "\$1"-lines" \{\
2545 .    nr doc-keep-type 2
2546 .    tm .Bk -lines: Not implemented yet. (#\n[.c])
2547 .  \}
2548 .  el \{ .ie "\$1"-words" \{\
2549 .    nr doc-keep-type 1
2550 .    doc-set-hard-space
2551 .  \}
2552 .  el \{ .ie "\$1"" \{\
2553 .    \" default
2554 .    nr doc-keep-type 1
2555 .    doc-set-hard-space
2556 .  \}
2557 .  el \{\
2558 .    tm mdoc warning: Unknown keyword `\$1' in .Bk macro (#\n[.c])
2559 .    nr doc-keep-type 3
2560 .  \}\}\}
2561 .
2562 \#.  nr doc-nesting-level +1
2563 ..
2564 .
2565 .
2566 .\" NS Ek user macro
2567 .\" NS   end keep
2568 .\" NS
2569 .\" NS modifies:
2570 .\" NS   doc-keep-type
2571 .\" NS   doc-macro-name
2572 .\" NS
2573 .\" NS width register `Ek' set in doc-common
2574 .
2575 .de Ek
2576 .  ds doc-macro-name Ek
2577 .
2578 \#.  nr doc-nesting-level -1
2579 .
2580 .  ie \n[.$] \
2581 .    tm Usage: .Ek (does not take arguments) (#\n[.c])
2582 .  el \{\
2583 .    if !\n[doc-keep-type] \
2584 .      tm mdoc warning: .Ek found without .Bk before (#\n[.c])
2585 .
2586 .    ie        (\n[doc-keep-type] == 1) \
2587 .      doc-set-soft-space
2588 .    el \{ .if (\n[doc-keep-type] == 2) \
2589 .      tm .Bk -lines: Not implemented yet. (#\n[.c])
2590 .  \}\}
2591 .
2592 .  nr doc-keep-type 0
2593 .
2594 \#.  if !"\*[doc-out-string]"" \
2595 \#.    doc-print-out-string
2596 ..
2597 .
2598 .
2599 .\" NS doc-display-depth global register
2600 .\" NS   display level
2601 .
2602 .nr doc-display-depth 0
2603 .
2604 .
2605 .\" NS doc-is-compact global register (bool)
2606 .\" NS   set if the `compact' keyword is given
2607 .
2608 .nr doc-is-compact 0
2609 .
2610 .
2611 .\" NS doc-display-type-stackXXX global string
2612 .\" NS   the display type stack
2613 .\" NS
2614 .\" NS limit:
2615 .\" NS   doc-display-depth
2616 .
2617 .ds doc-display-type-stack0
2618 .
2619 .
2620 .\" NS doc-display-indent-stackXXX global register
2621 .\" NS   stack of display indentation values
2622 .\" NS
2623 .\" NS limit:
2624 .\" NS   doc-display-depth
2625 .
2626 .nr doc-display-indent-stack0 0
2627 .
2628 .
2629 .\" NS doc-display-ad-stackXXX global register
2630 .\" NS   stack of saved adjustment modes
2631 .\" NS
2632 .\" NS limit:
2633 .\" NS   doc-display-depth
2634 .
2635 .nr doc-display-ad-stack0 0
2636 .
2637 .
2638 .\" NS doc-display-fi-stackXXX global register
2639 .\" NS   stack of saved fill modes
2640 .\" NS
2641 .\" NS limit:
2642 .\" NS   doc-display-depth
2643 .
2644 .nr doc-display-fi-stack0 0
2645 .
2646 .
2647 .\" NS doc-display-ft-stackXXX global register
2648 .\" NS   stack of saved fonts
2649 .\" NS
2650 .\" NS limit:
2651 .\" NS   doc-display-depth
2652 .
2653 .nr doc-display-ft-stack0 0
2654 .
2655 .
2656 .\" NS doc-display-ps-stackXXX global register
2657 .\" NS   stack of saved font sizes
2658 .\" NS
2659 .\" NS limit:
2660 .\" NS   doc-display-depth
2661 .
2662 .nr doc-display-ps-stack0 0
2663 .
2664 .
2665 .\" NS Bd user macro
2666 .\" NS   begin display
2667 .\" NS
2668 .\" NS width register `Bd' set in doc-common
2669 .\" NS
2670 .\" NS modifies:
2671 .\" NS   doc-curr-font
2672 .\" NS   doc-curr-size
2673 .\" NS   doc-display-depth
2674 .\" NS   doc-display-ad-stackXXX
2675 .\" NS   doc-display-fi-stackXXX
2676 .\" NS   doc-display-ft-stackXXX
2677 .\" NS   doc-display-ps-stackXXX
2678 .\" NS   doc-display-file
2679 .\" NS   doc-display-indent-stackXXX
2680 .\" NS   doc-display-type-stackXXX
2681 .\" NS   doc-is-compact
2682 .\" NS   doc-macro-name
2683 .\" NS
2684 .\" NS local variables:
2685 .\" NS   doc-reg-Bd
2686 .
2687 .de Bd
2688 .  ds doc-macro-name Bd
2689 .
2690 .  if !\n[.$] \{\
2691 .    tm1 "Usage: .Bd {-literal | -filled | -ragged | -centered | -unfilled}
2692 .    tm1 "           [-offset [string]] [-compact] [-file name] (#\n[.c])
2693 .    return
2694 .  \}
2695 .
2696 .  nr doc-is-compact 0
2697 .  ds doc-display-file
2698 .  nr doc-reg-Bd 1
2699 .  nr doc-display-depth +1
2700 .
2701 .  \" save current adjustment and fill modes
2702 .  nr doc-display-ad-stack\n[doc-display-depth] \n[.j]
2703 .  nr doc-display-fi-stack\n[doc-display-depth] \n[.u]
2704 .
2705 .  ie        "\$1"-literal" \{\
2706 .    ds doc-display-type-stack\n[doc-display-depth] literal
2707 .    nr doc-display-ft-stack\n[doc-display-depth] \n[.f]
2708 .    nr doc-display-ps-stack\n[doc-display-depth] \n[.ps]
2709 .
2710 .    ie t \
2711 .      ta T 9n
2712 .    el \
2713 .      ta T 8n
2714 .    nf
2715 .  \}
2716 .  el \{ .ie "\$1"-filled" \{\
2717 .    ds doc-display-type-stack\n[doc-display-depth] filled
2718 .    ad b
2719 .    fi
2720 .  \}
2721 .  el \{ .ie "\$1"-ragged" \{\
2722 .    ds doc-display-type-stack\n[doc-display-depth] ragged
2723 .    na
2724 .    fi
2725 .  \}
2726 .  el \{ .ie "\$1"-centered" \{\
2727 .    ds doc-display-type-stack\n[doc-display-depth] centered
2728 .    ad c
2729 .    fi
2730 .  \}
2731 .  el \{ .ie "\$1"-unfilled" \{\
2732 .    ds doc-display-type-stack\n[doc-display-depth] unfilled
2733 .    nf
2734 .  \}
2735 .  el \{\
2736 .    tm1 "mdoc warning: Unknown keyword `\$1' (or missing display type)
2737 .    tm1 "              in .Bd macro (#\n[.c])
2738 .    nr doc-reg-Bd 0
2739 .  \}\}\}\}\}
2740 .
2741 .  \" have we seen an argument?
2742 .  if \n[doc-reg-Bd] \{\
2743 .    shift
2744 .    \" check other arguments
2745 .    if \n[.$] \
2746 .      doc-do-Bd-args \$@
2747 .  \}
2748 .
2749 .  \" avoid warning about non-existent register
2750 .  if !r doc-display-indent-stack\n[doc-display-depth] \
2751 .    nr doc-display-indent-stack\n[doc-display-depth] 0
2752 .
2753 .  if \n[doc-display-indent-stack\n[doc-display-depth]] \
2754 .    in +\n[doc-display-indent-stack\n[doc-display-depth]]u
2755 .
2756 .  if !\n[doc-is-compact] \
2757 .    sp \n[doc-display-vertical]u
2758 .
2759 .  if "\*[doc-display-type-stack\n[doc-display-depth]]"literal" \
2760 .    if t \
2761 .      nop \*[doc-Li-font]\c
2762 .
2763 .  if !\n[cR] \
2764 .    ne 2v
2765 .
2766 .  if !"\*[doc-display-file]"" \
2767 .    so \*[doc-display-file]
2768 .
2769 .  nr doc-is-compact 0
2770 .  ds doc-display-file
2771 ..
2772 .
2773 .
2774 .\" NS doc-do-Bd-args macro
2775 .\" NS   resolve remaining .Bd arguments
2776 .\" NS
2777 .\" NS modifies:
2778 .\" NS   doc-display-file
2779 .\" NS   doc-display-indent-stackXXX
2780 .\" NS   doc-is-compact
2781 .\" NS
2782 .\" NS local variables:
2783 .\" NS   doc-reg-ddBa
2784 .\" NS   doc-reg-ddBa1
2785 .\" NS   doc-reg-ddBa2
2786 .\" NS   doc-reg-ddBa3
2787 .\" NS   doc-reg-ddBa4
2788 .\" NS   doc-str-ddBa
2789 .
2790 .de doc-do-Bd-args
2791 .  nr doc-reg-ddBa 1
2792 .
2793 .  ie        "\$1"-offset" \{\
2794 .    nr doc-reg-ddBa 2
2795 .
2796 .    ie        "\$2"left" \
2797 .      nr doc-display-indent-stack\n[doc-display-depth] 0
2798 .    el \{ .ie "\$2"right" \
2799 .      nr doc-display-indent-stack\n[doc-display-depth] (\n[.l]u / 3u)
2800 .    el \{ .ie "\$2"center" \
2801 .      nr doc-display-indent-stack\n[doc-display-depth] ((\n[.l]u - \n[.i]u) / 4u)
2802 .    el \{ .ie "\$2"indent" \
2803 .      nr doc-display-indent-stack\n[doc-display-depth] \n[doc-display-indent]u
2804 .    el \{ .ie "\$2"indent-two" \
2805 .      nr doc-display-indent-stack\n[doc-display-depth] (\n[doc-display-indent]u + \n[doc-display-indent]u)
2806 .    el \
2807 .      nr doc-reg-ddBa 1
2808 .    \}\}\}\}
2809 .
2810 .    \" not a known keyword
2811 .    if (\n[doc-reg-ddBa] == 1) \{\
2812 .      nr doc-reg-ddBa 2
2813 .
2814 .      nr doc-reg-ddBa1 0
2815 .      if \B\a(\$2)\a \{\
2816 .        \" disable warnings related to scaling indicators (32)
2817 .        nr doc-reg-ddBa2 \n[.warn]
2818 .        warn (\n[.warn] - (\n[.warn] / 32 % 2 * 32))
2819 .
2820 .        \" values without a scaling indicator are taken as strings;
2821 .        \" we test whether the parameter string with and without the last
2822 .        \" character yields identical numerical results (ignoring the
2823 .        \" scaling indicator)
2824 .        ds doc-str-ddBa "\$2
2825 .        substring doc-str-ddBa 0 -2
2826 .        if \B\a(\*[doc-str-ddBa])\a \{\
2827 .          nr doc-reg-ddBa3 (;(\$2))
2828 .          nr doc-reg-ddBa4 (\*[doc-str-ddBa])
2829 .          if (\n[doc-reg-ddBa3] == \n[doc-reg-ddBa4]) \
2830 .            nr doc-reg-ddBa1 1
2831 .        \}
2832 .
2833 .        \" enable all warnings again
2834 .        warn \n[doc-reg-ddBa2]
2835 .      \}
2836 .
2837 .      ie \n[doc-reg-ddBa1] \
2838 .        nr doc-display-indent-stack\n[doc-display-depth] \$2
2839 .      el \{\
2840 .        doc-get-width "\$2"
2841 .        ie (\n[doc-width] <= 3) \{\
2842 .          \" if the offset parameter is a macro, use the macro's
2843 .          \" width as specified in doc-common
2844 .          doc-get-arg-type "\$2"
2845 .          ie (\n[doc-arg-type] == 1) \
2846 .            nr doc-display-indent-stack\n[doc-display-depth] \n[\$2]
2847 .          el \
2848 .            nr doc-display-indent-stack\n[doc-display-depth] (\n[doc-width]u * \n[doc-fixed-width]u)
2849 .        \}
2850 .        el \
2851 .          nr doc-display-indent-stack\n[doc-display-depth] (\n[doc-width]u * \n[doc-fixed-width]u)
2852 .    \}\}
2853 .  \}
2854 .  el \{ .ie "\$1"-compact" \
2855 .    nr doc-is-compact 1
2856 .  el \{ .ie "\$1"-file" \{\
2857 .    ie !"\$2"" \{\
2858 .      ds doc-display-file "\$2
2859 .      nr doc-reg-ddBa 2
2860 .    \}
2861 .    el \
2862 .      tm mdoc warning: .Bd `-file' keyword requires argument (#\n[.c])
2863 .  \}
2864 .  el \
2865 .      tm mdoc warning: Unknown keyword `\$1' in .Bd macro (#\n[.c])
2866 .  \}\}
2867 .
2868 .  if (\n[doc-reg-ddBa] < \n[.$]) \{\
2869 .    shift \n[doc-reg-ddBa]
2870 .    doc-do-Bd-args \$@
2871 .  \}
2872 ..
2873 .
2874 .
2875 .\" NS Ed user macro
2876 .\" NS   end display
2877 .\" NS
2878 .\" NS modifies:
2879 .\" NS   doc-display-depth
2880 .\" NS   doc-display-indent-stackXXX
2881 .\" NS   doc-display-type-stackXXX
2882 .\" NS   doc-macro-name
2883 .\" NS
2884 .\" NS width register `Ed' set in doc-common
2885 .
2886 .de Ed
2887 .  ds doc-macro-name Ed
2888 .
2889 .  br
2890 .
2891 .  if !\n[doc-display-depth] \{\
2892 .    tm mdoc warning: Extraneous .Ed (#\n[.c])
2893 .    nr doc-display-depth 1
2894 .  \}
2895 .
2896 .  if "\*[doc-display-type-stack\n[doc-display-depth]]"literal" \{\
2897 .    ft \n[doc-display-ft-stack\n[doc-display-depth]]
2898 .    ps \n[doc-display-ps-stack\n[doc-display-depth]]u
2899 .  \}
2900 .
2901 .  in -\n[doc-display-indent-stack\n[doc-display-depth]]u
2902 .
2903 .  \" restore saved adjustment and fill modes
2904 .  ie \n[doc-display-fi-stack\n[doc-display-depth]] \
2905 .    fi
2906 .  el \
2907 .    nf
2908 .  ad \n[doc-display-ad-stack\n[doc-display-depth]]
2909 .
2910 .  nr doc-display-indent-stack\n[doc-display-depth] 0
2911 .  ds doc-display-type-stack\n[doc-display-depth]
2912 .  nr doc-display-depth -1
2913 ..
2914 .
2915 .
2916 .\" NS doc-list-type-stackXXX global string
2917 .\" NS   stack of list types
2918 .\" NS
2919 .\" NS limit:
2920 .\" NS   doc-list-depth
2921 .
2922 .ds doc-list-type-stack1
2923 .
2924 .
2925 .\" NS doc-list-indent-stackXXX global register
2926 .\" NS   stack of list indentation values
2927 .\" NS
2928 .\" NS limit:
2929 .\" NS   doc-list-depth
2930 .
2931 .nr doc-list-indent-stack1 0
2932 .
2933 .
2934 .\" NS doc-list-have-indent-stackXXX global register (bool)
2935 .\" NS   an indentation value is active
2936 .\" NS
2937 .\" NS limit:
2938 .\" NS   doc-list-depth
2939 .
2940 .nr doc-list-have-indent-stack1 0
2941 .
2942 .
2943 .\" NS Bl user macro
2944 .\" NS   begin list
2945 .\" NS
2946 .\" NS width register `Bl' set in doc-common
2947 .\" NS
2948 .\" NS modifies:
2949 .\" NS   doc-arg-ptr
2950 .\" NS   doc-argXXX
2951 .\" NS   doc-list-depth
2952 .\" NS   doc-list-have-indent-stackXXX
2953 .\" NS   doc-list-indent-stackXXX
2954 .\" NS   doc-list-type-stackXXX
2955 .\" NS   doc-macro-name
2956 .\" NS   doc-num-args
2957 .\" NS   doc-num-columns
2958 .\" NS
2959 .\" NS local variables:
2960 .\" NS   doc-reg-Bl
2961 .
2962 .de Bl
2963 .  if !\n[.$] \{\
2964 .    doc-Bl-usage
2965 .    return
2966 .  \}
2967 .
2968 .  ds doc-macro-name Bl
2969 .  nr doc-list-depth +1
2970 .  nr doc-arg-ptr 1
2971 .
2972 .  ie        "\$1"-hang" \{\
2973 .    ds doc-list-type-stack\n[doc-list-depth] hang-list
2974 .    nr doc-list-indent-stack\n[doc-list-depth] 6n
2975 .    nr doc-list-have-indent-stack\n[doc-list-depth] 1
2976 .  \}
2977 .  el \{ .ie "\$1"-tag" \{\
2978 .    ds doc-list-type-stack\n[doc-list-depth] tag-list
2979 .    nr doc-list-have-indent-stack\n[doc-list-depth] 1
2980 .  \}
2981 .  el \{ .ie "\$1"-item" \{\
2982 .    ds doc-list-type-stack\n[doc-list-depth] item-list
2983 .    nr doc-list-have-indent-stack\n[doc-list-depth] 1
2984 .  \}
2985 .  el \{ .ie "\$1"-enum" \{\
2986 .    ds doc-list-type-stack\n[doc-list-depth] enum-list
2987 .    nr doc-list-indent-stack\n[doc-list-depth] 3n
2988 .    nr doc-list-have-indent-stack\n[doc-list-depth] 1
2989 .  \}
2990 .  el \{ .ie "\$1"-bullet" \{\
2991 .    ds doc-list-type-stack\n[doc-list-depth] bullet-list
2992 .    nr doc-list-indent-stack\n[doc-list-depth] 2n
2993 .    nr doc-list-have-indent-stack\n[doc-list-depth] 1
2994 .  \}
2995 .  el \{ .ie "\$1"-dash" \{\
2996 .    ds doc-list-type-stack\n[doc-list-depth] dash-list
2997 .    nr doc-list-indent-stack\n[doc-list-depth] 2n
2998 .    nr doc-list-have-indent-stack\n[doc-list-depth] 1
2999 .  \}
3000 .  el \{ .ie "\$1"-hyphen" \{\
3001 .    ds doc-list-type-stack\n[doc-list-depth] dash-list
3002 .    nr doc-list-indent-stack\n[doc-list-depth] 2n
3003 .    nr doc-list-have-indent-stack\n[doc-list-depth] 1
3004 .  \}
3005 .  el \{ .ie "\$1"-inset" \{\
3006 .    ds doc-list-type-stack\n[doc-list-depth] inset-list
3007 .    nr doc-list-have-indent-stack\n[doc-list-depth] 1
3008 .  \}
3009 .  el \{ .ie "\$1"-diag" \{\
3010 .    ds doc-list-type-stack\n[doc-list-depth] diag-list
3011 .  \}
3012 .  el \{ .ie "\$1"-ohang" \{\
3013 .    ds doc-list-type-stack\n[doc-list-depth] ohang-list
3014 .    nr doc-list-have-indent-stack\n[doc-list-depth] 1
3015 .  \}
3016 .  el \{ .ie "\$1"-column" \{\
3017 .    ds doc-list-type-stack\n[doc-list-depth] column-list
3018 .    linetabs 1
3019 .  \}
3020 .  el \{\
3021 .    tm1 "mdoc warning: Unknown list type `\$1' (or missing list type)
3022 .    tm1 "              in .Bl macro
3023 .    tm
3024 .    nr doc-arg-ptr 0
3025 .  \}\}\}\}\}\}\}\}\}\}\}
3026 .
3027 .  \" we have seen a list type
3028 .  if !\n[doc-arg-ptr] \{\
3029 .    doc-Bl-usage
3030 .    doc-reset-args
3031 .    nr doc-list-depth -1
3032 .    return
3033 .  \}
3034 .
3035 .  shift
3036 .
3037 .  \" fill argument vector
3038 .  nr doc-reg-Bl 1
3039 .  while (\n[doc-reg-Bl] <= \n[.$]) \{\
3040 .    ds doc-arg\n[doc-reg-Bl] "\$[\n[doc-reg-Bl]]
3041 .    \" dummy type and space so that doc-save-global-vars() doesn't warn
3042 .    nr doc-type\n[doc-reg-Bl] 0
3043 .    ds doc-space\n[doc-reg-Bl]
3044 .    nr doc-reg-Bl +1
3045 .  \}
3046 .
3047 .  doc-increment-list-stack
3048 .
3049 .  if \n[.$] \{\
3050 .    nr doc-arg-limit \n[.$]
3051 .    nr doc-arg-ptr 0
3052 .    doc-do-Bl-args
3053 .
3054 .    in +\n[doc-list-offset-stack\n[doc-list-depth]]u
3055 .
3056 .    \" initialize column list
3057 .    if "\*[doc-list-type-stack\n[doc-list-depth]]"column-list" \{\
3058 .      doc-set-column-tab \n[doc-num-columns]
3059 '      in -\n[doc-column-indent-width]u
3060 .      if !\n[doc-compact-list-stack\n[doc-list-depth]] \
3061 .        sp \n[doc-display-vertical]u
3062 .
3063 .      nf
3064 .      nr doc-num-columns 0
3065 .  \}\}
3066 .
3067 .  doc-reset-args
3068 ..
3069 .
3070 .
3071 .\" NS doc-Bl-usage macro
3072 .
3073 .de doc-Bl-usage
3074 .  tm1 "Usage: .Bl {-hang | -ohang | -tag | -diag | -inset}
3075 .  tm1 "             [-width <string>]
3076 .  tm1 "             [-offset <string>] [-compact]
3077 .  tm1 "       .Bl -column [-offset <string>] <string1> <string2> ...
3078 .  tm1 "       .Bl {-item | -enum [-nested] | -bullet | -hyphen | -dash}
3079 .  tm1 "             [-offset <string>] [-compact] (#\n[.c])
3080 ..
3081 .
3082 .
3083 .\" NS doc-do-Bl-args macro
3084 .\" NS   resolve remaining .Bl arguments
3085 .\" NS
3086 .\" NS modifies:
3087 .\" NS   doc-arg-ptr
3088 .\" NS   doc-argXXX
3089 .\" NS   doc-compact-list-stackXXX
3090 .\" NS   doc-list-indent-stackXXX
3091 .\" NS   doc-list-offset-stackXXX
3092 .\" NS   doc-num-columns
3093 .\" NS   doc-tag-prefix-stackXXX
3094 .\" NS   doc-tag-width-stackXXX
3095 .\" NS
3096 .\" NS local variables:
3097 .\" NS   doc-box-dBla
3098 .\" NS   doc-env-dBla
3099 .\" NS   doc-reg-dBla
3100 .\" NS   doc-reg-dBla1
3101 .\" NS   doc-reg-dBla2
3102 .\" NS   doc-reg-dBla3
3103 .\" NS   doc-reg-dBla4
3104 .\" NS   doc-str-dBla
3105 .\" NS   doc-str-dBla1
3106 .
3107 .de doc-do-Bl-args
3108 .  nr doc-arg-ptr +1
3109 .
3110 .  if (\n[doc-arg-limit] < \n[doc-arg-ptr]) \
3111 .    return
3112 .
3113 .  \" avoid a warning message in case e.g. `-offset' has no parameter
3114 .  nr doc-reg-dBla (\n[doc-arg-ptr] + 1)
3115 .  if !d doc-arg\n[doc-reg-dBla] \
3116 .    ds doc-arg\n[doc-reg-dBla]
3117 .
3118 .  nr doc-reg-dBla 1
3119 .
3120 .  ie        "\*[doc-arg\n[doc-arg-ptr]]"-compact" \
3121 .    nr doc-compact-list-stack\n[doc-list-depth] 1
3122 .
3123 .  el \{ .ie "\*[doc-arg\n[doc-arg-ptr]]"-nested" \{\
3124 .    ie (\n[doc-list-depth] > 1) \{\
3125 .      nr doc-reg-dBla1 (\n[doc-list-depth] - 1)
3126 .      ds doc-tag-prefix-stack\n[doc-list-depth] "\*[doc-tag-prefix-stack\n[doc-reg-dBla1]]
3127 .      as doc-tag-prefix-stack\n[doc-list-depth] \n[doc-enum-list-count-stack\n[doc-reg-dBla1]].
3128 .      length doc-reg-dBla1 "\*[doc-tag-prefix-stack\n[doc-list-depth]]
3129 .      nr doc-list-indent-stack\n[doc-list-depth] +\n[doc-reg-dBla1]n
3130 .    \}
3131 .    el \
3132 .      tm mdoc warning: `-nested' allowed with nested .Bl macros only (#\n[.c])
3133 .  \}
3134 .
3135 .  el \{ .ie "\*[doc-arg\n[doc-arg-ptr]]"-width" \{\
3136 .    nr doc-arg-ptr +1
3137 .    ds doc-tag-width-stack\n[doc-list-depth] TagwidtH
3138 .
3139 .    ds doc-str-dBla "\*[doc-arg\n[doc-arg-ptr]]
3140 .    substring doc-str-dBla 0 0
3141 .    ie \a.\a\*[doc-str-dBla]\a \{\
3142 .      ds doc-str-dBla "\*[doc-arg\n[doc-arg-ptr]]
3143 .      substring doc-str-dBla 1
3144 .      doc-first-parameter \*[doc-str-dBla]
3145 .      doc-get-width "\*[doc-str-dfp]
3146 .      doc-get-arg-type "\*[doc-str-dfp]
3147 .      ie (\n[doc-arg-type] == 1) \
3148 .        nr doc-reg-dBla1 1
3149 .      el \
3150 .        nr doc-reg-dBla1 0
3151 .    \}
3152 .    el \
3153 .      nr doc-reg-dBla1 0
3154 .    ds doc-str-dBla "\*[doc-arg\n[doc-arg-ptr]]
3155 .
3156 .    ie \n[doc-reg-dBla1] \{\
3157 .      \" execute string in a box to get the width of the diversion
3158 .      ds doc-str-dBla \*[doc-arg\n[doc-arg-ptr]]
3159 .      doc-save-global-vars
3160 .      doc-reset-args
3161 .      box doc-box-dBla
3162 .      ev doc-env-dBla
3163 .      evc 0
3164 .      in 0
3165 .      nf
3166 .      nop \*[doc-str-dBla]
3167 .      br
3168 .      ev
3169 .      box
3170 .      doc-restore-global-vars
3171 .      doc-get-width \h'\n[dl]u'
3172 .      nr doc-list-indent-stack\n[doc-list-depth] (\n[doc-width]u * \n[doc-fixed-width]u)
3173 .    \}
3174 .    el \{\
3175 .      \" test whether argument is a valid numeric expression
3176 .      nr doc-reg-dBla1 0
3177 .      if \B\a(\*[doc-str-dBla])\a \{\
3178 .        \" disable warnings related to scaling indicators (32)
3179 .        nr doc-reg-dBla2 \n[.warn]
3180 .        warn (\n[.warn] - (\n[.warn] / 32 % 2 * 32))
3181 .
3182 .        \" values without a scaling indicator are taken as strings;
3183 .        \" we test whether the parameter string with and without the last
3184 .        \" character yields identical numerical results (ignoring the
3185 .        \" scaling indicator)
3186 .        ds doc-str-dBla1 "\*[doc-str-dBla]
3187 .        substring doc-str-dBla1 0 -2
3188 .        if \B\a(\*[doc-str-dBla1])\a \{\
3189 .          nr doc-reg-dBla3 (;(\*[doc-str-dBla]))
3190 .          nr doc-reg-dBla4 (\*[doc-str-dBla1])
3191 .          if (\n[doc-reg-dBla3] == \n[doc-reg-dBla4]) \
3192 .            nr doc-reg-dBla1 1
3193 .        \}
3194 .
3195 .        \" enable all warnings again
3196 .        warn \n[doc-reg-dBla2]
3197 .      \}
3198 .
3199 .      ie \n[doc-reg-dBla1] \
3200 .        nr doc-list-indent-stack\n[doc-list-depth] (\*[doc-str-dBla])
3201 .      el \{\
3202 .        doc-get-arg-width \n[doc-arg-ptr]
3203 .        ie (\n[doc-width] == 2) \{\
3204 .          \" if the width parameter is a macro, use the macro's
3205 .          \" width as specified in doc-common
3206 .          doc-get-arg-type \*[doc-str-dBla]
3207 .          ie (\n[doc-arg-type] == 1) \
3208 .            nr doc-list-indent-stack\n[doc-list-depth] \n[\*[doc-str-dBla]]
3209 .          el \
3210 .            nr doc-list-indent-stack\n[doc-list-depth] (\n[doc-width]u * \n[doc-fixed-width]u)
3211 .        \}
3212 .        el \
3213 .          nr doc-list-indent-stack\n[doc-list-depth] (\n[doc-width]u * \n[doc-fixed-width]u)
3214 .  \}\}\}
3215 .
3216 .  el \{ .ie "\*[doc-arg\n[doc-arg-ptr]]"-offset" \{\
3217 .    nr doc-arg-ptr +1
3218 .
3219 .    ie "\*[doc-arg\n[doc-arg-ptr]]"indent" \
3220 .      nr doc-list-offset-stack\n[doc-list-depth] \n[doc-display-indent]u
3221 .    el \{\
3222 .      ds doc-str-dBla "\*[doc-arg\n[doc-arg-ptr]]
3223 .      nr doc-reg-dBla1 0
3224 .      if \B\a(\*[doc-str-dBla])\a \{\
3225 .        nr doc-reg-dBla2 \n[.warn]
3226 .        warn (\n[.warn] - (\n[.warn] / 32 % 2 * 32))
3227 .
3228 .        ds doc-str-dBla1 "\*[doc-str-dBla]
3229 .        substring doc-str-dBla1 0 -2
3230 .        if \B\a(\*[doc-str-dBla1])\a \{\
3231 .          nr doc-reg-dBla3 (;(\*[doc-str-dBla]))
3232 .          nr doc-reg-dBla4 (\*[doc-str-dBla1])
3233 .          if (\n[doc-reg-dBla3] == \n[doc-reg-dBla4]) \
3234 .            nr doc-reg-dBla1 1
3235 .        \}
3236 .
3237 .        warn \n[doc-reg-dBla2]
3238 .      \}
3239 .
3240 .      ie \n[doc-reg-dBla1] \
3241 .        nr doc-list-offset-stack\n[doc-list-depth] \*[doc-str-dBla]
3242 .      el \{\
3243 .        doc-get-arg-width \n[doc-arg-ptr]
3244 .        ie (\n[doc-width] <= 3) \{\
3245 .          \" if the offset parameter is a macro, use the macro's
3246 .          \" width as specified in doc-common
3247 .          doc-get-arg-type \*[doc-str-dBla]
3248 .          ie (\n[doc-arg-type] == 1) \
3249 .            nr doc-list-offset-stack\n[doc-list-depth] \n[\*[doc-str-dBla]]
3250 .          el \
3251 .            nr doc-list-offset-stack\n[doc-list-depth] (\n[doc-width]u * \n[doc-fixed-width]u)
3252 .        \}
3253 .        el \
3254 .          nr doc-list-offset-stack\n[doc-list-depth] (\n[doc-width]u * \n[doc-fixed-width]u)
3255 .  \}\}\}
3256 .  el \
3257 .    nr doc-reg-dBla 0
3258 .  \}\}\}
3259 .
3260 .  \" not a known keyword, so it specifies the width of the next column
3261 .  \" (if it is a column list)
3262 .  if !\n[doc-reg-dBla] \{\
3263 .    ie "\*[doc-list-type-stack\n[doc-list-depth]]"column-list" \{\
3264 .      nr doc-num-columns +1
3265 .      ds doc-str-dBla \*[doc-arg\n[doc-arg-ptr]]
3266 .      substring doc-str-dBla 0 0
3267 .      ie \a.\a\*[doc-str-dBla]\a \{\
3268 .        ds doc-str-dBla "\*[doc-arg\n[doc-arg-ptr]]
3269 .        substring doc-str-dBla 1
3270 .        doc-first-parameter \*[doc-str-dBla]
3271 .        doc-get-width "\*[doc-str-dfp]
3272 .        doc-get-arg-type "\*[doc-str-dfp]
3273 .        ie (\n[doc-arg-type] == 1) \
3274 .          nr doc-reg-dBla1 1
3275 .        el \
3276 .          nr doc-reg-dBla1 0
3277 .      \}
3278 .      el \
3279 .        nr doc-reg-dBla1 0
3280 .      ds doc-str-dBla "\*[doc-arg\n[doc-arg-ptr]]
3281 .
3282 .      ie \n[doc-reg-dBla1] \{\
3283 .        \" execute string in a box to get the width of the diversion
3284 .        ds doc-str-dBla \*[doc-arg\n[doc-arg-ptr]]
3285 .        doc-save-global-vars
3286 .        doc-reset-args
3287 .        box doc-box-dBla
3288 .        ev doc-env-dBla
3289 .        evc 0
3290 .        in 0
3291 .        nf
3292 .        nop \*[doc-str-dBla]
3293 .        br
3294 .        ev
3295 .        box
3296 .        doc-restore-global-vars
3297 .        ds doc-arg\n[doc-num-columns] "\h'\n[dl]u'
3298 .      \}
3299 .      el \
3300 .        ds doc-arg\n[doc-num-columns] "\*[doc-arg\n[doc-arg-ptr]]
3301 .    \}
3302 .    el \{\
3303 .      tmc mdoc warning: Unknown keyword `\*[doc-arg\n[doc-arg-ptr]]'
3304 .      tm1 " in .Bl macro (#\n[.c])
3305 .  \}\}
3306 .
3307 .  if (\n[doc-arg-limit] > \n[doc-arg-ptr]) \
3308 .    doc-do-Bl-args
3309 ..
3310 .
3311 .
3312 .\" NS doc-save-global-vars macro
3313 .\" NS   save all global variables
3314 .\" NS
3315 .\" NS local variables:
3316 .\" NS   doc-reg-dsgv
3317 .
3318 .de doc-save-global-vars
3319 .  ds doc-macro-name-saved "\*[doc-macro-name]
3320 .  nr doc-arg-limit-saved \n[doc-arg-limit]
3321 .  nr doc-num-args-saved \n[doc-num-args]
3322 .  nr doc-arg-ptr-saved \n[doc-arg-ptr]
3323 .
3324 .  nr doc-reg-dsgv 1
3325 .  while (\n[doc-reg-dsgv] <= \n[doc-arg-limit]) \{\
3326 .    ds doc-arg\n[doc-reg-dsgv]-saved "\*[doc-arg\n[doc-reg-dsgv]]
3327 .    nr doc-type\n[doc-reg-dsgv]-saved \n[doc-type\n[doc-reg-dsgv]]
3328 .    ds doc-space\n[doc-reg-dsgv]-saved "\*[doc-space\n[doc-reg-dsgv]]
3329 .    nr doc-reg-dsgv +1
3330 .  \}
3331 .
3332 .  nr doc-curr-font-saved \n[doc-curr-font]
3333 .  nr doc-curr-size-saved \n[doc-curr-size]
3334 .  nr doc-in-synopsis-section-saved \n[doc-in-synopsis-section]
3335 .  nr doc-in-library-section-saved \n[doc-in-library-section]
3336 .  nr doc-indent-synopsis-saved \n[doc-indent-synopsis]
3337 .  nr doc-indent-synopsis-active-saved \n[doc-indent-synopsis-active]
3338 .  nr doc-have-decl-saved \n[doc-have-decl]
3339 .  nr doc-have-var-saved \n[doc-have-var]
3340 .  ds doc-command-name-saved "\*[doc-command-name]
3341 .  ds doc-quote-left-saved "\*[doc-quote-left]
3342 .  ds doc-quote-right-saved "\*[doc-quote-right]
3343 .  nr doc-nesting-level-saved \n[doc-nesting-level]
3344 .  nr doc-in-list-saved \n[doc-in-list]
3345 .  ds doc-space-saved "\*[doc-space]
3346 .  ds doc-saved-space-saved "\*[doc-saved-space]
3347 .  nr doc-space-mode-saved \n[doc-space-mode]
3348 .  nr doc-have-space-saved \n[doc-have-space]
3349 .  nr doc-have-slot-saved \n[doc-have-slot]
3350 .  nr doc-keep-type-saved \n[doc-keep-type]
3351 .  nr doc-display-depth-saved \n[doc-display-depth]
3352 .  nr doc-is-compact-saved \n[doc-is-compact]
3353 .
3354 .  nr doc-reg-dsgv 0
3355 .  while (\n[doc-reg-dsgv] <= \n[doc-display-depth]) \{\
3356 .    ds doc-display-type-stack\n[doc-reg-dsgv]-saved "\*[doc-display-type-stack\n[doc-reg-dsgv]]
3357 .    nr doc-display-indent-stack\n[doc-reg-dsgv]-saved \n[doc-display-indent-stack\n[doc-reg-dsgv]]
3358 .    nr doc-display-ad-stack\n[doc-reg-dsgv]-saved \n[doc-display-ad-stack\n[doc-reg-dsgv]]
3359 .    nr doc-display-fi-stack\n[doc-reg-dsgv]-saved \n[doc-display-fi-stack\n[doc-reg-dsgv]]
3360 .    nr doc-display-ft-stack\n[doc-reg-dsgv]-saved \n[doc-display-ft-stack\n[doc-reg-dsgv]]
3361 .    nr doc-display-ps-stack\n[doc-reg-dsgv]-saved \n[doc-display-ps-stack\n[doc-reg-dsgv]]
3362 .    nr doc-reg-dsgv +1
3363 .  \}
3364 .
3365 .  nr doc-fontmode-depth-saved \n[doc-fontmode-depth]
3366 .
3367 .  nr doc-reg-dsgv 1
3368 .  while (\n[doc-reg-dsgv] <= \n[doc-fontmode-depth]) \{\
3369 .    nr doc-fontmode-font-stack\n[doc-reg-dsgv]-saved \n[doc-fontmode-font-stack\n[doc-reg-dsgv]]
3370 .    nr doc-fontmode-size-stack\n[doc-reg-dsgv]-saved \n[doc-fontmode-size-stack\n[doc-reg-dsgv]]
3371 .    nr doc-reg-dsgv +1
3372 .  \}
3373 .
3374 .  nr doc-list-depth-saved \n[doc-list-depth]
3375 .
3376 .  nr doc-reg-dsgv 1
3377 .  while (\n[doc-reg-dsgv] <= \n[doc-list-depth]) \{\
3378 .    ds doc-list-type-stack\n[doc-reg-dsgv]-saved "\*[doc-list-type-stack\n[doc-reg-dsgv]]
3379 .    nr doc-list-have-indent-stack\n[doc-reg-dsgv]-saved \n[doc-list-have-indent-stack\n[doc-reg-dsgv]]
3380 .    nr doc-list-indent-stack\n[doc-reg-dsgv]-saved \n[doc-list-indent-stack\n[doc-reg-dsgv]]
3381 .    nr doc-compact-list-stack\n[doc-reg-dsgv]-saved \n[doc-compact-list-stack\n[doc-reg-dsgv]]
3382 .    ds doc-tag-prefix-stack\n[doc-reg-dsgv]-saved "\*[doc-tag-prefix-stack\n[doc-reg-dsgv]]
3383 .    ds doc-tag-width-stack\n[doc-reg-dsgv]-saved "\*[doc-tag-width-stack\n[doc-reg-dsgv]]
3384 .    nr doc-list-offset-stack\n[doc-reg-dsgv]-saved \n[doc-list-offset-stack\n[doc-reg-dsgv]]
3385 .    nr doc-enum-list-count-stack\n[doc-reg-dsgv]-saved \n[doc-enum-list-count-stack\n[doc-reg-dsgv]]
3386 .    nr doc-reg-dsgv +1
3387 .  \}
3388 .
3389 .  ds doc-saved-Pa-font-saved "\*[doc-saved-Pa-font]
3390 .  nr doc-curr-type-saved \n[doc-curr-type]
3391 .  ds doc-curr-arg-saved "\*[doc-curr-arg]
3392 .  nr doc-diag-list-input-line-count-saved \n[doc-diag-list-input-line-count]
3393 .  nr doc-num-columns-saved \n[doc-num-columns]
3394 .  nr doc-column-indent-width-saved \n[doc-column-indent-width]
3395 .  nr doc-is-func-saved \n[doc-is-func]
3396 .  nr doc-have-old-func-saved \n[doc-have-old-func]
3397 .  nr doc-func-arg-count-saved \n[doc-func-arg-count]
3398 .  ds doc-func-arg-saved "\*[doc-func-arg]
3399 .  nr doc-num-func-args-saved \n[doc-num-func-args]
3400 .  nr doc-func-args-processed-saved \n[doc-func-args-processed]
3401 .  nr doc-have-func-saved \n[doc-have-func]
3402 .  nr doc-is-reference-saved \n[doc-is-reference]
3403 .  nr doc-reference-count-saved \n[doc-reference-count]
3404 .  nr doc-author-count-saved \n[doc-author-count]
3405 .
3406 .  nr doc-reg-dsgv 0
3407 .  while (\n[doc-reg-dsgv] <= \n[doc-author-count]) \{\
3408 .    ds doc-author-name\n[doc-reg-dsgv]-saved "\*[doc-author-name\n[doc-reg-dsgv]]
3409 .    nr doc-reg-dsgv +1
3410 .  \}
3411 .
3412 .  nr doc-book-count-saved \n[doc-book-count]
3413 .  ds doc-book-name-saved "\*[doc-book-name]
3414 .  nr doc-date-count-saved \n[doc-date-count]
3415 .  ds doc-date-saved "\*[doc-date]
3416 .  nr doc-publisher-count-saved \n[doc-publisher-count]
3417 .  ds doc-publisher-name-saved "\*[doc-publisher-name]
3418 .  nr doc-journal-count-saved \n[doc-journal-count]
3419 .  ds doc-journal-name-saved "\*[doc-journal-name]
3420 .  nr doc-issue-count-saved \n[doc-issue-count]
3421 .  ds doc-issue-name-saved "\*[doc-issue-name]
3422 .  nr doc-optional-count-saved \n[doc-optional-count]
3423 .  ds doc-optional-string-saved "\*[doc-optional-string]
3424 .  nr doc-page-number-count-saved \n[doc-page-number-count]
3425 .  ds doc-page-number-string-saved "\*[doc-page-number-string]
3426 .  nr doc-corporate-count-saved \n[doc-corporate-count]
3427 .  ds doc-corporate-name-saved "\*[doc-corporate-name]
3428 .  nr doc-report-count-saved \n[doc-report-count]
3429 .  ds doc-report-name-saved "\*[doc-report-name]
3430 .  nr doc-reference-title-count-saved \n[doc-reference-title-count]
3431 .  ds doc-reference-title-name-saved "\*[doc-reference-title-name]
3432 .  ds doc-reference-title-name-for-book-saved "\*[doc-reference-title-name-for-book]
3433 .  nr doc-volume-count-saved \n[doc-volume-count]
3434 .  ds doc-volume-name-saved "\*[doc-volume-name]
3435 .  nr doc-have-author-saved \n[doc-have-author]
3436 .
3437 .  ds doc-document-title-saved "\*[doc-document-title]
3438 .  ds doc-volume-saved "\*[doc-volume]
3439 .  ds doc-section-saved "\*[doc-section]
3440 .  ds doc-operating-system-saved "\*[doc-operating-system]
3441 .  ds doc-date-string-saved "\*[doc-date-string]
3442 .  nr doc-header-space-saved \n[doc-header-space]
3443 .  nr doc-footer-space-saved \n[doc-footer-space]
3444 .  nr doc-display-vertical-saved \n[doc-display-vertical]
3445 .  ds doc-header-string-saved "\*[doc-header-string]
3446 .  nr doc-in-see-also-section-saved \n[doc-in-see-also-section]
3447 .  nr doc-in-files-section-saved \n[doc-in-files-section]
3448 .  nr doc-in-authors-section-saved \n[doc-in-authors-section]
3449 ..
3450 .
3451 .
3452 .\" NS doc-restore-global-vars macro
3453 .\" NS   restore all global variables
3454 .\" NS
3455 .\" NS local variables:
3456 .\" NS   doc-reg-drgv
3457 .
3458 .de doc-restore-global-vars
3459 .  ds doc-macro-name "\*[doc-macro-name-saved]
3460 .  nr doc-arg-limit \n[doc-arg-limit-saved]
3461 .  nr doc-num-args \n[doc-num-args-saved]
3462 .  nr doc-arg-ptr \n[doc-arg-ptr-saved]
3463 .
3464 .  nr doc-reg-drgv 1
3465 .  while (\n[doc-reg-drgv] <= \n[doc-arg-limit]) \{\
3466 .    ds doc-arg\n[doc-reg-drgv] "\*[doc-arg\n[doc-reg-drgv]-saved]
3467 .    nr doc-type\n[doc-reg-drgv] \n[doc-type\n[doc-reg-drgv]-saved]
3468 .    ds doc-space\n[doc-reg-drgv] "\*[doc-space\n[doc-reg-drgv]-saved]
3469 .    nr doc-reg-drgv +1
3470 .  \}
3471 .
3472 .  nr doc-curr-font \n[doc-curr-font-saved]
3473 .  nr doc-curr-size \n[doc-curr-size-saved]
3474 .  nr doc-in-synopsis-section \n[doc-in-synopsis-section-saved]
3475 .  nr doc-in-library-section \n[doc-in-library-section-saved]
3476 .  nr doc-indent-synopsis \n[doc-indent-synopsis-saved]
3477 .  nr doc-indent-synopsis-active \n[doc-indent-synopsis-active-saved]
3478 .  nr doc-have-decl \n[doc-have-decl-saved]
3479 .  nr doc-have-var \n[doc-have-var-saved]
3480 .  ds doc-command-name "\*[doc-command-name-saved]
3481 .  ds doc-quote-left "\*[doc-quote-left-saved]
3482 .  ds doc-quote-right "\*[doc-quote-right-saved]
3483 .  nr doc-nesting-level \n[doc-nesting-level-saved]
3484 .  nr doc-in-list \n[doc-in-list-saved]
3485 .  ds doc-space "\*[doc-space-saved]
3486 .  ds doc-saved-space "\*[doc-saved-space-saved]
3487 .  nr doc-space-mode \n[doc-space-mode-saved]
3488 .  nr doc-have-space \n[doc-have-space-saved]
3489 .  nr doc-have-slot \n[doc-have-slot-saved]
3490 .  nr doc-keep-type \n[doc-keep-type-saved]
3491 .  nr doc-display-depth \n[doc-display-depth-saved]
3492 .  nr doc-is-compact \n[doc-is-compact-saved]
3493 .
3494 .  nr doc-reg-drgv 0
3495 .  while (\n[doc-reg-drgv] <= \n[doc-display-depth]) \{\
3496 .    ds doc-display-type-stack\n[doc-reg-drgv] "\*[doc-display-type-stack\n[doc-reg-drgv]-saved]
3497 .    nr doc-display-indent-stack\n[doc-reg-drgv] \n[doc-display-indent-stack\n[doc-reg-drgv]-saved]
3498 .    nr doc-display-ad-stack\n[doc-reg-drgv] \n[doc-display-ad-stack\n[doc-reg-drgv]-saved]
3499 .    nr doc-display-fi-stack\n[doc-reg-drgv] \n[doc-display-fi-stack\n[doc-reg-drgv]-saved]
3500 .    nr doc-display-ft-stack\n[doc-reg-drgv] \n[doc-display-ft-stack\n[doc-reg-drgv]-saved]
3501 .    nr doc-display-ps-stack\n[doc-reg-drgv] \n[doc-display-ps-stack\n[doc-reg-drgv]-saved]
3502 .    nr doc-reg-drgv +1
3503 .  \}
3504 .
3505 .  nr doc-fontmode-depth \n[doc-fontmode-depth-saved]
3506 .
3507 .  nr doc-reg-drgv 1
3508 .  while (\n[doc-reg-drgv] <= \n[doc-fontmode-depth]) \{\
3509 .    nr doc-fontmode-font-stack\n[doc-reg-drgv] \n[doc-fontmode-font-stack\n[doc-reg-drgv]]-saved
3510 .    nr doc-fontmode-size-stack\n[doc-reg-drgv] \n[doc-fontmode-size-stack\n[doc-reg-drgv]]-saved
3511 .    nr doc-reg-drgv +1
3512 .  \}
3513 .
3514 .  nr doc-list-depth \n[doc-list-depth-saved]
3515 .
3516 .  nr doc-reg-drgv 1
3517 .  while (\n[doc-reg-drgv] <= \n[doc-list-depth]) \{\
3518 .    ds doc-list-type-stack\n[doc-reg-drgv] "\*[doc-list-type-stack\n[doc-reg-drgv]-saved]
3519 .    nr doc-list-have-indent-stack\n[doc-reg-drgv] \n[doc-list-have-indent-stack\n[doc-reg-drgv]-saved]
3520 .    nr doc-list-indent-stack\n[doc-reg-drgv] \n[doc-list-indent-stack\n[doc-reg-drgv]-saved]
3521 .    nr doc-compact-list-stack\n[doc-reg-drgv] \n[doc-compact-list-stack\n[doc-reg-drgv]-saved]
3522 .    ds doc-tag-prefix-stack\n[doc-reg-drgv] "\*[doc-tag-prefix-stack\n[doc-reg-drgv]-saved]
3523 .    ds doc-tag-width-stack\n[doc-reg-drgv] "\*[doc-tag-width-stack\n[doc-reg-drgv]-saved]
3524 .    nr doc-list-offset-stack\n[doc-reg-drgv] \n[doc-list-offset-stack\n[doc-reg-drgv]-saved]
3525 .    nr doc-enum-list-count-stack\n[doc-reg-drgv] \n[doc-enum-list-count-stack\n[doc-reg-drgv]-saved]
3526 .    nr doc-reg-drgv +1
3527 .  \}
3528 .
3529 .  ds doc-saved-Pa-font "\*[doc-saved-Pa-font-saved]
3530 .  nr doc-curr-type \n[doc-curr-type-saved]
3531 .  ds doc-curr-arg "\*[doc-curr-arg-saved]
3532 .  nr doc-diag-list-input-line-count \n[doc-diag-list-input-line-count-saved]
3533 .  nr doc-num-columns \n[doc-num-columns-saved]
3534 .  nr doc-column-indent-width \n[doc-column-indent-width-saved]
3535 .  nr doc-is-func \n[doc-is-func-saved]
3536 .  nr doc-have-old-func \n[doc-have-old-func-saved]
3537 .  nr doc-func-arg-count \n[doc-func-arg-count-saved]
3538 .  ds doc-func-arg "\*[doc-func-arg-saved]
3539 .  nr doc-num-func-args \n[doc-num-func-args-saved]
3540 .  nr doc-func-args-processed \n[doc-func-args-processed-saved]
3541 .  nr doc-have-func \n[doc-have-func-saved]
3542 .  nr doc-is-reference \n[doc-is-reference-saved]
3543 .  nr doc-reference-count \n[doc-reference-count-saved]
3544 .  nr doc-author-count \n[doc-author-count-saved]
3545 .
3546 .  nr doc-reg-drgv 0
3547 .  while (\n[doc-reg-drgv] <= \n[doc-author-count]) \{\
3548 .    ds doc-author-name\n[doc-reg-drgv] "\*[doc-author-name\n[doc-reg-drgv]-saved]
3549 .    nr doc-reg-drgv +1
3550 .  \}
3551 .
3552 .  nr doc-book-count \n[doc-book-count-saved]
3553 .  ds doc-book-name "\*[doc-book-name-saved]
3554 .  nr doc-date-count \n[doc-date-count-saved]
3555 .  ds doc-date "\*[doc-date-saved]
3556 .  nr doc-publisher-count \n[doc-publisher-count-saved]
3557 .  ds doc-publisher-name "\*[doc-publisher-name-saved]
3558 .  nr doc-journal-count \n[doc-journal-count-saved]
3559 .  ds doc-journal-name "\*[doc-journal-name-saved]
3560 .  nr doc-issue-count \n[doc-issue-count-saved]
3561 .  ds doc-issue-name "\*[doc-issue-name-saved]
3562 .  nr doc-optional-count \n[doc-optional-count-saved]
3563 .  ds doc-optional-string "\*[doc-optional-string-saved]
3564 .  nr doc-page-number-count \n[doc-page-number-count-saved]
3565 .  ds doc-page-number-string "\*[doc-page-number-string-saved]
3566 .  nr doc-corporate-count \n[doc-corporate-count-saved]
3567 .  ds doc-corporate-name "\*[doc-corporate-name-saved]
3568 .  nr doc-report-count \n[doc-report-count-saved]
3569 .  ds doc-report-name "\*[doc-report-name-saved]
3570 .  nr doc-reference-title-count \n[doc-reference-title-count-saved]
3571 .  ds doc-reference-title-name "\*[doc-reference-title-name-saved]
3572 .  ds doc-reference-title-name-for-book "\*[doc-reference-title-name-for-book-saved]
3573 .  nr doc-volume-count \n[doc-volume-count-saved]
3574 .  ds doc-volume-name "\*[doc-volume-name-saved]
3575 .  nr doc-have-author \n[doc-have-author-saved]
3576 .
3577 .  ds doc-document-title "\*[doc-document-title-saved]
3578 .  ds doc-volume "\*[doc-volume-saved]
3579 .  ds doc-section "\*[doc-section-saved]
3580 .  ds doc-operating-system "\*[doc-operating-system-saved]
3581 .  ds doc-date-string "\*[doc-date-string-saved]
3582 .  nr doc-header-space \n[doc-header-space-saved]
3583 .  nr doc-footer-space \n[doc-footer-space-saved]
3584 .  nr doc-display-vertical \n[doc-display-vertical-saved]
3585 .  ds doc-header-string "\*[doc-header-string-saved]
3586 .  nr doc-in-see-also-section \n[doc-in-see-also-section-saved]
3587 .  nr doc-in-files-section \n[doc-in-files-section-saved]
3588 .  nr doc-in-authors-section \n[doc-in-authors-section-saved]
3589 ..
3590 .
3591 .
3592 .\" NS El user macro
3593 .\" NS   end list
3594 .\" NS
3595 .\" NS modifies:
3596 .\" NS   doc-list-depth
3597 .\" NS   doc-macro-name
3598 .\" NS
3599 .\" NS local variables:
3600 .\" NS   doc-str-El
3601 .\" NS
3602 .\" NS width register `El' set in doc-common
3603 .
3604 .de El
3605 .  if \n[.$] \{\
3606 .    tm Usage: .El (does not take arguments) (#\n[.c])
3607 .    return
3608 .  \}
3609 .
3610 .  ds doc-macro-name El
3611 .  ds doc-str-El \*[doc-list-type-stack\n[doc-list-depth]]
3612 .
3613 .  ie        "\*[doc-str-El]"diag-list" \
3614 .    doc-end-list 0
3615 .  el \{ .ie "\*[doc-str-El]"column-list" \
3616 .    doc-end-column-list
3617 .  el \{ .ie "\*[doc-str-El]"item-list" \
3618 .    doc-end-list 0
3619 .  el \{ .ie "\*[doc-str-El]"ohang-list" \
3620 .    doc-end-list 0
3621 .  el \{ .ie "\*[doc-str-El]"inset-list" \
3622 .    doc-end-list 0
3623 .  el \
3624 .    doc-end-list 1
3625 .  \}\}\}\}
3626 .
3627 .  br
3628 ..
3629 .
3630 .
3631 .\" NS doc-saved-Pa-font global string
3632 .\" NS   saved doc-Pa-font string for section FILES (no underline if
3633 .\" NS   nroff)
3634 .
3635 .ds doc-saved-Pa-font
3636 .
3637 .
3638 .\" NS doc-curr-type global register
3639 .\" NS   current argument type
3640 .
3641 .nr doc-curr-type 0
3642 .
3643 .
3644 .\" NS doc-curr-arg global string
3645 .\" NS   current argument
3646 .
3647 .ds doc-curr-arg
3648 .
3649 .
3650 .\" NS doc-item-boxXXX global box
3651 .\" NS   item boxes associated list depth
3652 .\" NS
3653 .\" NS limit:
3654 .\" NS   doc-list-depth
3655 .
3656 .
3657 .\" NS It user macro
3658 .\" NS   list item
3659 .\" NS
3660 .\" NS modifies:
3661 .\" NS   doc-arg-ptr
3662 .\" NS   doc-argXXX
3663 .\" NS   doc-curr-arg
3664 .\" NS   doc-curr-type
3665 .\" NS   doc-in-list
3666 .\" NS   doc-macro-name
3667 .\" NS   doc-num-args
3668 .\" NS   doc-saved-Pa-font
3669 .\" NS
3670 .\" NS local variables:
3671 .\" NS   doc-reg-It
3672 .\" NS   doc-str-It
3673 .\" NS   doc-XXX-list-type
3674 .\" NS
3675 .\" NS width register `It' set in doc-common
3676 .
3677 .nr doc-bullet-list-type 1
3678 .nr doc-column-list-type 0
3679 .nr doc-dash-list-type 1
3680 .nr doc-diag-list-type 0
3681 .nr doc-enum-list-type 1
3682 .nr doc-hang-list-type 2
3683 .nr doc-inset-list-type 2
3684 .nr doc-item-list-type 1
3685 .nr doc-ohang-list-type 2
3686 .nr doc-tag-list-type 2
3687 .
3688 .de It
3689 .  ds doc-str-It \*[doc-list-type-stack\n[doc-list-depth]]
3690 .
3691 .  if "\*[doc-str-It]"" \
3692 .    tm mdoc error: .It without preceding .Bl (#\n[.c])
3693 .
3694 .  if \n[doc-nesting-level] \{\
3695 .    tmc "mdoc error: .It found in enclosing (e.g. .Ac ... .It ... .Ao)
3696 .    tm1 " (#\n[.c])
3697 .  \}
3698 .
3699 .  br
3700 .  if !\n[cR] \
3701 .    ne 3v
3702 .
3703 .  if \n[.$] \{\
3704 .    ds doc-macro-name It
3705 .
3706 .    \" fill argument vector
3707 .    nr doc-reg-It 1
3708 .    while (\n[doc-reg-It] <= \n[.$]) \{\
3709 .      ds doc-arg\n[doc-reg-It] "\$[\n[doc-reg-It]]
3710 .      nr doc-reg-It +1
3711 .    \}
3712 .
3713 .    nr doc-num-args \n[.$]
3714 .    nr doc-arg-ptr 0
3715 .  \}
3716 .
3717 .  nr doc-reg-It \n[doc-\*[doc-str-It]-type]
3718 .
3719 .  if \n[doc-reg-It] \{\
3720 .    \" start item box
3721 .    box doc-item-box\n[doc-list-depth]
3722 .    ev doc-item-env\n[doc-list-depth]
3723 .    evc 0
3724 .    in 0
3725 .    nf
3726 .  \}
3727 .
3728 .  ie (\n[doc-reg-It] == 1) \{\
3729 .    if \n[.$] \{\
3730 .      tm1 "mdoc warning: .It macros in lists of type `\*[doc-str-It]'
3731 .      tm1 "              don't take arguments (#\n[.c])
3732 .  \}\}
3733 .  el \{\
3734 .    ie \n[.$] \{\
3735 .      if (\n[doc-reg-It] == 2) \{\
3736 .        \" handle list types with arguments
3737 .        doc-parse-arg-vector
3738 .
3739 .        nr doc-in-list 1
3740 .        nr doc-arg-ptr 1
3741 .        nr doc-curr-type \n[doc-type1]
3742 .        ds doc-curr-arg "\*[doc-arg1]
3743 .
3744 .        if \n[doc-in-files-section] \{\
3745 .          ds doc-saved-Pa-font "\*[doc-Pa-font]
3746 .          if n \
3747 .            ds doc-Pa-font "\*[doc-No-font]
3748 .        \}
3749 .
3750 .        ie (\n[doc-type1] == 1) \
3751 .          \*[doc-arg1]
3752 .        el \{\
3753 .          nr doc-arg-ptr 1
3754 .          doc-print-recursive
3755 .    \}\}\}
3756 .    el \{\
3757 .      tm1 "mdoc warning: .It macros in lists of type `\*[doc-str-It]'
3758 .      tm1 "              require arguments (#\n[.c])
3759 .    \}
3760 .  \}
3761 .
3762 .  \" the previous call of `.doc-print-recursive' can contain calls to
3763 .  \" opening macros like `.Ao'; we then defer the call of `doc-xxx-list'
3764 .  if !\n[doc-nesting-level] \
3765 .    doc-\*[doc-str-It]
3766 ..
3767 .
3768 .
3769 .\" NS doc-inset-list macro
3770 .\" NS   .It item of list-type inset
3771 .\" NS
3772 .\" NS modifies:
3773 .\" NS   doc-in-list
3774 .
3775 .de doc-inset-list
3776 .  \" finish item box
3777 .  br
3778 .  ev
3779 .  box
3780 .  unformat doc-item-box\n[doc-list-depth]
3781 .
3782 .  doc-set-vertical-and-indent 0
3783 .  br
3784 .
3785 .  nh
3786 .  doc-item-box\n[doc-list-depth]
3787 .
3788 .  if \n[doc-in-files-section] \
3789 .    if n \
3790 .      ds doc-Pa-font "\*[doc-saved-Pa-font]
3791 .
3792 .  nr doc-in-list 0
3793 .  doc-reset-args
3794 ..
3795 .
3796 .
3797 .\" NS doc-hang-list macro
3798 .\" NS   .It item of list-type hanging tag (as opposed to tagged)
3799 .\" NS
3800 .\" NS modifies:
3801 .\" NS   doc-have-space
3802 .\" NS   doc-in-list
3803 .\" NS
3804 .\" NS local variables:
3805 .\" NS   doc-reg-dhl
3806 .\" NS   doc-reg-dhl1
3807 .
3808 .de doc-hang-list
3809 .  \" finish item box
3810 .  br
3811 .  ev
3812 .  box
3813 .  unformat doc-item-box\n[doc-list-depth]
3814 .
3815 .  doc-set-vertical-and-indent 1
3816 .  nr doc-reg-dhl (\n[doc-list-indent-stack\n[doc-list-depth]]u + \n[doc-digit-width]u)
3817 .  ti -\n[doc-reg-dhl]u
3818 .
3819 .  nh
3820 .  ie (\n[dl]u > \n[doc-list-indent-stack\n[doc-list-depth]]u) \
3821 .    doc-item-box\n[doc-list-depth]
3822 .  el \{\
3823 .    chop doc-item-box\n[doc-list-depth]
3824 .    nr doc-reg-dhl1 \n[.k]u
3825 .    nop \*[doc-item-box\n[doc-list-depth]]\c
3826 .    nop \h'|(\n[doc-reg-dhl1]u - \n[.k]u + \n[doc-reg-dhl]u)'\c
3827 .    nr doc-have-space 1
3828 .  \}
3829 .
3830 .  if \n[doc-in-files-section] \
3831 .    if n \
3832 .      ds doc-Pa-font "\*[doc-saved-Pa-font]
3833 .
3834 .  nr doc-in-list 0
3835 .  doc-reset-args
3836 ..
3837 .
3838 .
3839 .\" NS doc-ohang-list macro
3840 .\" NS   .It item of list-type overhanging tag
3841 .\" NS
3842 .\" NS modifies:
3843 .\" NS   doc-in-list
3844 .
3845 .de doc-ohang-list
3846 .  \" finish item box
3847 .  br
3848 .  ev
3849 .  box
3850 .  unformat doc-item-box\n[doc-list-depth]
3851 .
3852 .  doc-set-vertical-and-indent 0
3853 .  nh
3854 .  doc-item-box\n[doc-list-depth]
3855 .  br
3856 .
3857 .  if \n[doc-in-files-section] \
3858 .    if n \
3859 .      ds doc-Pa-font "\*[doc-saved-Pa-font]
3860 .
3861 .  nr doc-in-list 0
3862 .  doc-reset-args
3863 ..
3864 .
3865 .
3866 .\" NS doc-item-list macro
3867 .\" NS   .It item of list-type [empty tag]
3868 .
3869 .de doc-item-list
3870 .  \" finish (dummy) item box
3871 .  br
3872 .  ev
3873 .  box
3874 .
3875 .  doc-set-vertical-and-indent 0
3876 .  br
3877 .
3878 .  doc-reset-args
3879 ..
3880 .
3881 .
3882 .\" NS doc-enum-list-count-stackXXX global register
3883 .\" NS   stack of current enum count values
3884 .\" NS
3885 .\" NS limit:
3886 .\" NS   doc-list-depth
3887 .
3888 .nr doc-enum-list-count-stack1 0
3889 .
3890 .
3891 .\" NS doc-enum-list macro
3892 .\" NS   enumerated list
3893 .\" NS
3894 .\" NS modifies:
3895 .\" NS   doc-enum-list-count-stackXXX
3896 .\" NS   doc-in-list
3897 .
3898 .de doc-enum-list
3899 .  nr doc-in-list 1
3900 .  nr doc-enum-list-count-stack\n[doc-list-depth] +1
3901 \# XXX
3902 \#.ll \n[doc-list-indent-stack\n[doc-list-depth]]u
3903 \#.rj
3904 .  nop \*[doc-tag-prefix-stack\n[doc-list-depth]]\c
3905 .  nop \n[doc-enum-list-count-stack\n[doc-list-depth]].\&
3906 .  doc-do-list
3907 ..
3908 .
3909 .
3910 .\" NS doc-bullet-list macro
3911 .\" NS   bullet paragraph list
3912 .\" NS
3913 .\" NS modifies:
3914 .\" NS   doc-in-list
3915 .
3916 .de doc-bullet-list
3917 .  nr doc-in-list 1
3918 .  nop \)\*[doc-Sy-font]\[bu]\f[]
3919 .  doc-do-list
3920 ..
3921 .
3922 .
3923 .\" NS doc-dash-list macro
3924 .\" NS   hyphen paragraph list (sub bullet list)
3925 .\" NS
3926 .\" NS modifies:
3927 .\" NS   doc-in-list
3928 .
3929 .de doc-dash-list
3930 .  nr doc-in-list 1
3931 .  nop \)\*[doc-Sy-font]\-\f[]
3932 .  doc-do-list
3933 ..
3934 .
3935 .
3936 .\" NS doc-do-list macro
3937 .\" NS   .It item of list-type enum/bullet/hyphen
3938 .
3939 .als doc-do-list doc-hang-list
3940 .
3941 .
3942 .\" NS doc-diag-list-input-line-count global register
3943 .\" NS   saved line number to be checked in next diag-list item
3944 .
3945 .nr doc-diag-list-input-line-count 0
3946 .
3947 .
3948 .\" NS doc-diag-list macro
3949 .\" NS   .It item of list-type diagnostic-message
3950 .\" NS
3951 .\" NS modifies:
3952 .\" NS   doc-curr-font
3953 .\" NS   doc-curr-size
3954 .\" NS   doc-diag-list-input-line-count
3955 .
3956 .de doc-diag-list
3957 .  nr doc-curr-font \n[.f]
3958 .  nr doc-curr-size \n[.ps]
3959 .
3960 .  ie ((\n[.c] - \n[doc-diag-list-input-line-count]) > 1) \{\
3961 .    ie !\n[doc-compact-list-stack\n[doc-list-depth]] \
3962 .      doc-paragraph
3963 .    el \
3964 .      br
3965 .  \}
3966 .  el \
3967 .    br
3968 .  nr doc-diag-list-input-line-count \n[.c]
3969 .
3970 .  nh
3971 .  nop \*[doc-Sy-font]\c
3972 .  if \n[doc-num-args] \
3973 .    doc-remaining-args
3974 .  nop \f[\n[doc-curr-font]]\s[\n[doc-curr-size]u]\*[doc-hard-space]\c
3975 .
3976 .  doc-print-and-reset
3977 ..
3978 .
3979 .
3980 .\" NS doc-tag-list macro
3981 .\" NS   .It item of list-type `tag'
3982 .\" NS
3983 .\" NS modifies:
3984 .\" NS   doc-have-space
3985 .\" NS   doc-in-list
3986 .\" NS
3987 .\" NS local variables:
3988 .\" NS   doc-box-dtl
3989 .\" NS   doc-reg-dtl
3990 .\" NS   doc-reg-dtl1
3991 .
3992 .de doc-tag-list
3993 .  \" finish item box
3994 .  br
3995 .  ev
3996 .  box
3997 .  unformat doc-item-box\n[doc-list-depth]
3998 .
3999 .  \" we use a box without `.nf' to compute the tag width (via `dl' register)
4000 .  box doc-box-dtl
4001 .  ev doc-env-dtl
4002 .  evc 0
4003 .  fi
4004 .  ad 0
4005 .  in 0
4006 .  doc-item-box\n[doc-list-depth]
4007 .  br
4008 .  ev
4009 .  box
4010 .
4011 .  if !"TagwidtH"\*[doc-tag-width-stack\n[doc-list-depth]]" \{\
4012 .    if !\n[doc-list-have-indent-stack\n[doc-list-depth]] \{\
4013 .      in -(\n[doc-list-indent-stack\n[doc-list-depth]]u + \n[doc-digit-width]u)
4014 .      nr doc-list-have-indent-stack\n[doc-list-depth] 1
4015 .    \}
4016 .    doc-get-tag-width
4017 .  \}
4018 .  doc-set-vertical-and-indent 1
4019 .  nr doc-reg-dtl (\n[doc-list-indent-stack\n[doc-list-depth]]u + \n[doc-digit-width]u)
4020 .  ti -\n[doc-reg-dtl]u
4021 .
4022 .  nh
4023 .  doc-item-box\n[doc-list-depth]
4024 .  ie (\n[dl]u > \n[doc-list-indent-stack\n[doc-list-depth]]u) \
4025 .    br
4026 .  el \{\
4027 .    \" format the tag separately to prevent stretching of spaces
4028 .    vpt 0
4029 .    br
4030 .    sp -1
4031 .    vpt 1
4032 .    nop \&\c
4033 .    nr doc-have-space 1
4034 .  \}
4035 .
4036 .  if \n[doc-in-files-section] \
4037 .    if n \
4038 .      ds doc-Pa-font "\*[doc-saved-Pa-font]
4039 .
4040 .  nr doc-in-list 0
4041 .  doc-reset-args
4042 ..
4043 .
4044 .
4045 .\" NS doc-get-tag-width macro
4046 .\" NS   resolve unknown tag width (`tag' list-type only)
4047 .\" NS
4048 .\" NS modifies:
4049 .\" NS   doc-list-indent-stackXXX
4050 .\" NS   doc-tag-width-stackXXX
4051 .\" NS
4052 .\" NS requires:
4053 .\" NS   doc-curr-arg
4054 .\" NS   doc-curr-type
4055 .
4056 .de doc-get-tag-width
4057 .  ie (\n[doc-curr-type] == 1) \{\
4058 .    ds doc-tag-width-stack\n[doc-list-depth] \*[doc-curr-arg]
4059 .    nr doc-list-indent-stack\n[doc-list-depth] \n[\*[doc-curr-arg]]
4060 .  \}
4061 .  el \{\
4062 .    ds doc-tag-width-stack\n[doc-list-depth] No
4063 .    nr doc-list-indent-stack\n[doc-list-depth] \n[No]
4064 .  \}
4065 ..
4066 .
4067 .
4068 .\" NS doc-set-vertical-and-indent macro
4069 .\" NS   set up vertical spacing (if not compact) and indentation (with
4070 .\" NS   offset if argument is non-zero)
4071 .\" NS
4072 .\" NS modifies:
4073 .\" NS   doc-list-have-indent-stackXXX
4074 .
4075 .de doc-set-vertical-and-indent
4076 .  if !\n[doc-compact-list-stack\n[doc-list-depth]] \
4077 .    sp \n[doc-display-vertical]u
4078 .
4079 .  if \n[doc-list-have-indent-stack\n[doc-list-depth]] \{\
4080 .    nr doc-list-have-indent-stack\n[doc-list-depth] 0
4081 .    if \$1 \
4082 .      in +(\n[doc-list-indent-stack\n[doc-list-depth]]u + \n[doc-digit-width]u)
4083 .  \}
4084 .
4085 .  if !\n[cR] \
4086 .    ne 2v
4087 ..
4088 .
4089 .
4090 .\" NS doc-list-depth global register
4091 .\" NS   list type stack counter
4092 .
4093 .nr doc-list-depth 0
4094 .
4095 .
4096 .\" NS doc-num-columns global register
4097 .\" NS   number of columns
4098 .
4099 .nr doc-num-columns 0
4100 .
4101 .
4102 .\" NS doc-compact-list-stackXXX global register (bool)
4103 .\" NS   stack of flags to indicate whether a particular list is compact
4104 .\" NS
4105 .\" NS limit:
4106 .\" NS   doc-list-depth
4107 .
4108 .nr doc-compact-list-stack1 0
4109 .
4110 .
4111 .\" NS doc-tag-prefix-stackXXX global string
4112 .\" NS   stack of tag prefixes (currently used for -nested -enum lists)
4113 .\" NS
4114 .\" NS limit:
4115 .\" NS   doc-list-depth
4116 .
4117 .ds doc-tag-prefix-stack1
4118 .
4119 .
4120 .\" NS doc-tag-width-stackXXX global string
4121 .\" NS   stack of strings indicating how to set up current element of
4122 .\" NS   doc-list-indent-stackXXX -- if set to TagwidtH, user has set it
4123 .\" NS   directly; if it is a macro name, use the macro's width value;
4124 .\" NS   otherwise, `doc-get-tag-width' uses width value of `No'.
4125 .\" NS
4126 .\" NS limit:
4127 .\" NS   doc-list-depth
4128 .
4129 .ds doc-tag-width-stack0
4130 .ds doc-tag-width-stack1
4131 .
4132 .
4133 .\" NS doc-list-offset-stackXXX global register
4134 .\" NS   stack of list offsets
4135 .\" NS
4136 .\" NS limit:
4137 .\" NS   doc-list-depth
4138 .
4139 .nr doc-list-offset-stack1 0
4140 .
4141 .
4142 .\" NS doc-end-list macro
4143 .\" NS   list end function; resets indentation (and offset if argument is
4144 .\" NS   non-zero)
4145 .\" NS
4146 .\" NS modifies:
4147 .\" NS   doc-list-depth
4148 .\" NS   doc-list-offset-stackXXX
4149 .
4150 .de doc-end-list
4151 .  if \$1 \
4152 '    in -(\n[doc-list-indent-stack\n[doc-list-depth]]u + \n[doc-digit-width]u)
4153 .
4154 '  in -\n[doc-list-offset-stack\n[doc-list-depth]]u
4155 .
4156 .  if (\n[doc-list-depth] <= 0) \
4157 .    tm mdoc warning: extraneous .El call (#\n[.c])
4158 .
4159 .  doc-decrement-list-stack
4160 .  nr doc-list-depth -1
4161 ..
4162 .
4163 .
4164 .\" NS doc-increment-list-stack macro
4165 .\" NS   set up next block for list
4166 .\" NS
4167 .\" NS modifies:
4168 .\" NS   doc-compact-list-stackXXX
4169 .\" NS   doc-list-have-indent-stackXXX
4170 .\" NS   doc-list-indent-stackXXX
4171 .\" NS   doc-list-offset-stackXXX
4172 .\" NS   doc-list-type-stackXXX
4173 .\" NS   doc-tag-prefix-stackXXX
4174 .\" NS   doc-tag-width-stackXXX
4175 .\" NS   doc-enum-list-count-stackXXX
4176 .\" NS
4177 .\" NS local variables:
4178 .\" NS   doc-reg-dils
4179 .
4180 .de doc-increment-list-stack
4181 .  nr doc-reg-dils (\n[doc-list-depth] + 1)
4182 .  nr doc-list-have-indent-stack\n[doc-reg-dils] 0
4183 .  nr doc-list-indent-stack\n[doc-reg-dils] 0
4184 .  nr doc-list-offset-stack\n[doc-reg-dils] 0
4185 .  ds doc-tag-prefix-stack\n[doc-reg-dils]
4186 .  ds doc-tag-width-stack\n[doc-reg-dils] \*[doc-tag-width-stack\n[doc-list-depth]]
4187 .  ds doc-list-type-stack\n[doc-reg-dils]
4188 .  nr doc-compact-list-stack\n[doc-reg-dils] 0
4189 .  nr doc-enum-list-count-stack\n[doc-reg-dils] 0
4190 ..
4191 .
4192 .
4193 .\" NS doc-decrement-list-stack macro
4194 .\" NS   decrement stack
4195 .\" NS
4196 .\" NS modifies:
4197 .\" NS   doc-compact-list-stackXXX
4198 .\" NS   doc-list-have-indent-stackXXX
4199 .\" NS   doc-list-indent-stackXXX
4200 .\" NS   doc-list-offset-stackXXX
4201 .\" NS   doc-list-type-stackXXX
4202 .\" NS   doc-tag-prefix-stackXXX
4203 .\" NS   doc-tag-width-stackXXX
4204 .\" NS   doc-enum-list-count-stackXXX
4205 .
4206 .de doc-decrement-list-stack
4207 .  ds doc-list-type-stack\n[doc-list-depth]
4208 .  nr doc-list-have-indent-stack\n[doc-list-depth] 0
4209 .  nr doc-list-indent-stack\n[doc-list-depth] 0
4210 .  nr doc-list-offset-stack\n[doc-list-depth] 0
4211 .  ds doc-tag-prefix-stack\n[doc-list-depth]
4212 .  ds doc-tag-width-stack\n[doc-list-depth]
4213 .  nr doc-compact-list-stack\n[doc-list-depth] 0
4214 .  nr doc-enum-list-count-stack\n[doc-list-depth] 0
4215 ..
4216 .
4217 .
4218 .\" NS Xr user macro
4219 .\" NS   cross reference (for man pages only)
4220 .\" NS
4221 .\" NS modifies:
4222 .\" NS   doc-arg-ptr
4223 .\" NS   doc-macro-name
4224 .\" NS
4225 .\" NS local variables:
4226 .\" NS   doc-reg-Xr
4227 .\" NS
4228 .\" NS width register `Xr' set in doc-common
4229 .
4230 .de Xr
4231 .  if !\n[doc-arg-limit] \{\
4232 .    ie \n[.$] \{\
4233 .      ds doc-macro-name Xr
4234 .      doc-parse-args \$@
4235 .    \}
4236 .    el \
4237 .      doc-Xr-usage
4238 .  \}
4239 .
4240 .  if !\n[doc-arg-limit] \
4241 .    return
4242 .
4243 .  nr doc-arg-ptr +1
4244 .  doc-print-prefixes
4245 .  ie (\n[doc-arg-limit] >= \n[doc-arg-ptr]) \{\
4246 .    \" first argument must be a string
4247 .    ie (\n[doc-type\n[doc-arg-ptr]] == 2) \{\
4248 .      nr doc-curr-font \n[.f]
4249 .      nr doc-curr-size \n[.ps]
4250 .      ds doc-arg\n[doc-arg-ptr] \*[doc-Xr-font]\*[doc-arg\n[doc-arg-ptr]]\f[]\s[0]
4251 .
4252 .      if (\n[doc-arg-limit] > \n[doc-arg-ptr]) \{\
4253 .        nr doc-reg-Xr (\n[doc-arg-ptr] + 1)
4254 .        \" modify second argument if it is a string and
4255 .        \" remove space inbetween
4256 .        if (\n[doc-type\n[doc-reg-Xr]] == 2) \{\
4257 .          ds doc-arg\n[doc-reg-Xr] \*[lp]\*[doc-arg\n[doc-reg-Xr]]\*[rp]
4258 .          ds doc-space\n[doc-arg-ptr]
4259 .        \}
4260 .      \}
4261 .      doc-print-recursive
4262 .    \}
4263 .    el \
4264 .      doc-Xr-usage
4265 .  \}
4266 .  el \
4267 .    doc-Xr-usage
4268 ..
4269 .
4270 .
4271 .\" NS doc-Xr-usage macro
4272 .
4273 .de doc-Xr-usage
4274 .  tm Usage: .Xr manpage_name [section#] ... (#\n[.c])
4275 .  doc-reset-args
4276 ..
4277 .
4278 .
4279 .\" NS Sx user macro
4280 .\" NS   cross section reference
4281 .\" NS
4282 .\" NS width register `Sx' set in doc-common
4283 .
4284 .als Sx doc-generic-macro
4285 .ds doc-Sx-usage section_header
4286 .
4287 .
4288 .\" NS doc-end-column-list macro
4289 .\" NS   column-list end-list
4290 .\" NS
4291 .\" NS modifies:
4292 .\" NS   doc-list-depth
4293 .
4294 .de doc-end-column-list
4295 .  linetabs 0
4296 '  in -(\n[doc-list-offset-stack\n[doc-list-depth]]u + \n[doc-list-indent-stack\n[doc-list-depth]]u)
4297 .  ta T .5i
4298 .  fi
4299 .  doc-decrement-list-stack
4300 .  nr doc-list-depth -1
4301 ..
4302 .
4303 .
4304 .\" NS doc-column-indent-width global register
4305 .\" NS   holds the indent width for a column list
4306 .
4307 .nr doc-column-indent-width 0
4308 .
4309 .
4310 .\" NS doc-set-column-tab macro
4311 .\" NS   establish tabs for list-type column: `.doc-set-column-tab num_cols'
4312 .\" NS
4313 .\" NS modifies:
4314 .\" NS   doc-column-indent-width
4315 .\" NS
4316 .\" NS local variables:
4317 .\" NS   doc-reg-dsct
4318 .\" NS   doc-str-dsct
4319 .\" NS   doc-str-dsct1
4320 .
4321 .de doc-set-column-tab
4322 .  ds doc-str-dsct
4323 .  nr doc-reg-dsct 1
4324 .  nr doc-column-indent-width 0
4325 .
4326 .  ie (\$1 < 5) \
4327 .    ds doc-str-dsct1 "    \"
4328 .  el \{\
4329 .    ie (\$1 == 5) \
4330 .      ds doc-str-dsct1 "   \"
4331 .    el \{\
4332 .      \" XXX: this is packed abnormally close -- intercolumn width
4333 .      \"      should be configurable
4334 .      ds doc-str-dsct1 " \"
4335 .  \}\}
4336 .
4337 .  while (\n[doc-reg-dsct] <= \$1) \{\
4338 .    as doc-str-dsct " +\w\a\*[doc-arg\n[doc-reg-dsct]]\*[doc-str-dsct1]\au
4339 .    nr doc-column-indent-width +\w\a\*[doc-arg\n[doc-reg-dsct]]\*[doc-str-dsct1]\au
4340 .    nr doc-reg-dsct +1
4341 .  \}
4342 .
4343 .  ta \*[doc-str-dsct]
4344 '  in +\n[doc-column-indent-width]u
4345 ..
4346 .
4347 .
4348 .\" NS doc-column-list macro
4349 .\" NS   column items
4350 .\" NS
4351 .\" NS modifies:
4352 .\" NS   doc-arg-ptr
4353 .\" NS   doc-list-indent-stackXXX
4354 .\" NS   doc-spaceXXX
4355 .\" NS
4356 .\" NS local variables:
4357 .\" NS   doc-reg-dcl
4358 .
4359 .de doc-column-list
4360 .  if \n[doc-num-args] \
4361 .    doc-parse-arg-vector
4362 .  nr doc-arg-ptr +1
4363 .
4364 .  if (\n[doc-arg-limit] < \n[doc-arg-ptr]) \{\
4365 .    tm Usage: .It column_string [Ta [column_string ...] ] (#\n[.c])
4366 .    return
4367 .  \}
4368 .
4369 .  if "\*[doc-arg\n[doc-arg-ptr]]"Ta" \{\
4370 .    nr doc-reg-dcl (\n[doc-arg-ptr] - 1)
4371 .    ds doc-space\n[doc-reg-dcl]
4372 .  \}
4373 .
4374 .  if !\n[doc-list-indent-stack\n[doc-list-depth]] \
4375 .    nr doc-list-indent-stack\n[doc-list-depth] \n[doc-column-indent-width]u
4376 .  if !\n[.u] \{\
4377 .    fi
4378 .    in +\n[doc-column-indent-width]u
4379 .  \}
4380 .  ti -\n[doc-column-indent-width]u
4381 .
4382 .  doc-do-\n[doc-type\n[doc-arg-ptr]]
4383 ..
4384 .
4385 .
4386 .\" NS Ta user macro
4387 .\" NS   append tab (\t)
4388 .\" NS
4389 .\" NS modifies:
4390 .\" NS   doc-arg-ptr
4391 .\" NS
4392 .\" NS width register `Ta' set in doc-common
4393 .
4394 .de Ta
4395 .  ie \n[doc-arg-limit] \{\
4396 .    nr doc-arg-ptr +1
4397 .    nop \*[doc-tab]\c
4398 .    ie (\n[doc-arg-limit] >= \n[doc-arg-ptr]) \
4399 .      doc-do-\n[doc-type\n[doc-arg-ptr]]
4400 .    el \
4401 .      doc-reset-args
4402 .  \}
4403 .  el \{\
4404 .    tm1 "Usage: Ta must follow column entry: e.g.
4405 .    tm1 "         .It column_string [Ta [column_string ...]] (#\n[.c])
4406 .  \}
4407 ..
4408 .
4409 .
4410 .\" NS Dl user macro
4411 .\" NS   display (one line) literal
4412 .\" NS
4413 .\" NS   this function uses the `Li' font
4414 .\" NS
4415 .\" NS modifies:
4416 .\" NS   doc-arg-ptr
4417 .\" NS   doc-curr-font
4418 .\" NS   doc-curr-size
4419 .\" NS   doc-macro-name
4420 .\" NS
4421 .\" NS width register `Dl' set in doc-common
4422 .
4423 .de Dl
4424 .  ta T .5i
4425 .  in +\n[doc-display-indent]u
4426 .
4427 .  ie \n[doc-arg-limit] \{\
4428 .    tm Usage: .Dl not callable by other macros (#\n[.c])
4429 .    doc-reset-args
4430 .  \}
4431 .  el \{\
4432 .    ie \n[.$] \{\
4433 .      ds doc-macro-name Dl
4434 .      doc-parse-args \$@
4435 .      nr doc-arg-ptr 1
4436 .      nr doc-curr-font \n[.f]
4437 .      nr doc-curr-size \n[.ps]
4438 .      nop \*[doc-Li-font]\c
4439 .      doc-print-recursive
4440 .    \}
4441 .    el \
4442 .      tm Usage: .Dl argument ... (#\n[.c])
4443 .  \}
4444 .
4445 .  in -\n[doc-display-indent]u
4446 ..
4447 .
4448 .
4449 .\" NS D1 user macro
4450 .\" NS   display (one line)
4451 .\" NS
4452 .\" NS modifies:
4453 .\" NS   doc-arg-ptr
4454 .\" NS   doc-macro-name
4455 .\" NS
4456 .\" NS width register `D1' set in doc-common
4457 .
4458 .de D1
4459 .  ta T .5i
4460 .  in +\n[doc-display-indent]u
4461 .
4462 .  ie \n[doc-arg-limit] \{\
4463 .    tm Usage: .D1 not callable by other macros (#\n[.c])
4464 .    doc-reset-args
4465 .  \}
4466 .  el \{\
4467 .    ie \n[.$] \{\
4468 .      ds doc-macro-name D1
4469 .      doc-parse-args \$@
4470 .      nr doc-arg-ptr 1
4471 .      doc-print-recursive
4472 .    \}
4473 .    el \
4474 .      tm Usage: .D1 argument ... (#\n[.c])
4475 .  \}
4476 .
4477 .  in -\n[doc-display-indent]u
4478 ..
4479 .
4480 .
4481 .\" NS Vt user macro
4482 .\" NS   variable type (for forcing old style variable declarations);
4483 .\" NS   this is not done in the same manner as .Ot for fortrash --
4484 .\" NS   clean up later
4485 .\" NS
4486 .\" NS modifies:
4487 .\" NS   doc-curr-font
4488 .\" NS   doc-curr-size
4489 .\" NS   doc-have-decl
4490 .\" NS   doc-have-var
4491 .\" NS   doc-macro-name
4492 .\" NS
4493 .\" NS width register `Vt' set in doc-common
4494 .
4495 .de Vt
4496 .  if !\n[doc-arg-limit] \{\
4497 .    ie \n[.$] \{\
4498 .      ds doc-macro-name Vt
4499 .      doc-parse-args \$@
4500 .    \}
4501 .    el \
4502 .      tm Usage: .Vt variable_type ... (#\n[.c])
4503 .  \}
4504 .
4505 .  if !\n[doc-arg-limit] \
4506 .    return
4507 .
4508 .  nr doc-arg-ptr +1
4509 .  if (\n[doc-arg-limit] < \n[doc-arg-ptr]) \{\
4510 .    tm Usage: .Vt variable_type ... (#\n[.c])
4511 .    doc-reset-args
4512 .    return
4513 .  \}
4514 .
4515 .  if \n[doc-in-synopsis-section] \{\
4516 .    \" if a function declaration was the last thing given,
4517 .    \" want vertical space
4518 .    if \n[doc-have-decl] \{\
4519 .      doc-paragraph
4520 .      nr doc-have-decl 0
4521 .    \}
4522 .
4523 .    \" if a subroutine was the last thing given, want vertical space
4524 .    if \n[doc-have-func] \{\
4525 .      ie \n[doc-have-var] \
4526 .        br
4527 .      el \
4528 .        doc-paragraph
4529 .    \}
4530 .
4531 .    nr doc-have-var 1
4532 .  \}
4533 .
4534 .  nr doc-curr-font \n[.f]
4535 .  nr doc-curr-size \n[.ps]
4536 .  nop \*[doc-Ft-font]\c
4537 .  doc-print-recursive
4538 .
4539 .  if \n[doc-in-synopsis-section] \{\
4540 .    ie \n[doc-have-old-func] \
4541 .      nop \*[doc-soft-space]\c
4542 .    el \
4543 .      br
4544 .  \}
4545 ..
4546 .
4547 .
4548 .\" NS doc-is-func global register (bool)
4549 .\" NS   set if subroutine (in synopsis only) (fortran only)
4550 .
4551 .nr doc-is-func 0
4552 .
4553 .
4554 .\" NS Ft user macro
4555 .\" NS   function type
4556 .\" NS
4557 .\" NS modifies:
4558 .\" NS   doc-curr-font
4559 .\" NS   doc-curr-size
4560 .\" NS   doc-have-decl
4561 .\" NS   doc-have-var
4562 .\" NS   doc-is-func
4563 .\" NS   doc-macro-name
4564 .\" NS
4565 .\" NS width register `Ft' set in doc-common
4566 .
4567 .de Ft
4568 .  if !\n[doc-arg-limit] \{\
4569 .    ie \n[.$] \{\
4570 .      ds doc-macro-name Ft
4571 .      doc-parse-args \$@
4572 .    \}
4573 .    el \
4574 .      tm Usage: .Ft function_type ... (#\n[.c])
4575 .  \}
4576 .
4577 .  if !\n[doc-arg-limit] \
4578 .    return
4579 .
4580 .  nr doc-arg-ptr +1
4581 .  if (\n[doc-arg-limit] < \n[doc-arg-ptr]) \{\
4582 .    tm Usage: .Ft function_type ... (#\n[.c])
4583 .    doc-reset-args
4584 .    return
4585 .  \}
4586 .
4587 .  if \n[doc-in-synopsis-section] \{\
4588 .    if (\n[doc-have-func] : \n[doc-have-decl]) \{\
4589 .      doc-paragraph
4590 .      nr doc-have-decl 0
4591 .      nr doc-have-var 0
4592 .    \}
4593 .
4594 .    if \n[doc-have-var] \{\
4595 .      doc-paragraph
4596 .      nr doc-have-var 0
4597 .    \}
4598 .
4599 .    nr doc-is-func 1
4600 .  \}
4601 .
4602 .  nr doc-curr-font \n[.f]
4603 .  nr doc-curr-size \n[.ps]
4604 .  nop \*[doc-Ft-font]\c
4605 .  doc-print-recursive
4606 ..
4607 .
4608 .
4609 .\" NS doc-have-old-func global register (bool)
4610 .\" NS   set if `Ot' has been called
4611 .
4612 .nr doc-have-old-func 0
4613 .
4614 .
4615 .\" NS Ot user macro
4616 .\" NS   old function type (fortran -- no newline)
4617 .\" NS
4618 .\" NS modifies:
4619 .\" NS   doc-have-decl
4620 .\" NS   doc-have-old-func
4621 .\" NS   doc-have-var
4622 .\" NS   doc-is-func
4623 .\" NS
4624 .\" NS width register `Ot' set in doc-common
4625 .
4626 .de Ot
4627 .  nr doc-have-old-func 1
4628 .
4629 .  if \n[doc-in-synopsis-section] \{\
4630 .    if (\n[doc-have-func] : \n[doc-have-decl]) \{\
4631 .      doc-paragraph
4632 .      nr doc-have-decl 0
4633 .      nr doc-have-var 0
4634 .    \}
4635 .
4636 .    if \n[doc-have-var] \{\
4637 .      doc-paragraph
4638 .      nr doc-have-var 0
4639 .    \}
4640 .
4641 .    nr doc-is-func 1
4642 .  \}
4643 .
4644 .  if \n[.$] \
4645 .    nop \*[doc-Ft-font]\$*\c
4646 .  nop \ \f[]\c
4647 ..
4648 .
4649 .
4650 .\" NS Fa user macro
4651 .\" NS   function arguments
4652 .\" NS
4653 .\" NS modifies:
4654 .\" NS   doc-arg-ptr
4655 .\" NS   doc-curr-font
4656 .\" NS   doc-curr-size
4657 .\" NS   doc-macro-name
4658 .\" NS
4659 .\" NS width register `Fa' set in doc-common
4660 .
4661 .de Fa
4662 .  if !\n[doc-arg-limit] \{\
4663 .    ie \n[.$] \{\
4664 .      ds doc-macro-name Fa
4665 .      doc-parse-args \$@
4666 .    \}
4667 .    el \
4668 .      tm Usage: .Fa function_arguments ... (#\n[.c])
4669 .  \}
4670 .
4671 .  ie \n[doc-func-arg-count] \
4672 .    doc-do-func
4673 .  el \{\
4674 .    nr doc-arg-ptr +1
4675 .    if (\n[doc-arg-limit] >= \n[doc-arg-ptr]) \{\
4676 .      nr doc-curr-font \n[.f]
4677 .      nr doc-curr-size \n[.ps]
4678 .      nop \*[doc-Fa-font]\c
4679 .      doc-print-recursive
4680 .
4681 .      if \n[doc-in-synopsis-section] \
4682 .        if \n[doc-have-func] \
4683 .          br
4684 .  \}\}
4685 ..
4686 .
4687 .
4688 .\" NS doc-func-arg-count global register
4689 .\" NS   how many function arguments have been processed so far
4690 .
4691 .nr doc-func-arg-count 0
4692 .
4693 .
4694 .\" NS doc-func-arg global string
4695 .\" NS   work buffer for function name strings
4696 .
4697 .ds doc-func-arg
4698 .
4699 .
4700 .\" NS doc-num-func-args global register
4701 .\" NS   number of function arguments
4702 .
4703 .nr doc-num-func-args 0
4704 .
4705 .
4706 .\" NS doc-func-args-processed global register
4707 .\" NS   function arguments processed so far
4708 .
4709 .nr doc-func-args-processed 0
4710 .
4711 .
4712 .\" NS doc-do-func macro
4713 .\" NS   internal .Fa for .Fc
4714 .\" NS
4715 .\" NS modifies:
4716 .\" NS   doc-arg-ptr
4717 .\" NS   doc-argXXX
4718 .\" NS   doc-func-arg
4719 .\" NS   doc-func-arg-count
4720 .\" NS   doc-func-args-processed
4721 .\" NS   doc-num-func-args
4722 .
4723 .de doc-do-func
4724 .  if (\n[doc-arg-limit] <= \n[doc-arg-ptr]) \{\
4725 .    doc-reset-args
4726 .    return
4727 .  \}
4728 .
4729 .  nr doc-arg-ptr +1
4730 .
4731 .  ds doc-func-arg
4732 .  nr doc-num-func-args 0
4733 .  nr doc-func-args-processed 0
4734 .
4735 .  doc-build-func-string \*[doc-arg\n[doc-arg-ptr]]
4736 .  if (\n[doc-num-func-args] > 1) \
4737 .    ds doc-arg\n[doc-arg-ptr] "\*[doc-func-arg]
4738 .
4739 .  if (\n[doc-func-arg-count] > 1) \{\
4740 .    nop \f[\n[doc-curr-font]]\s[\n[doc-curr-size]u]\|\c
4741 .    if !"\*[doc-arg\n[doc-arg-ptr]]"/*" \
4742 .      if !"\*[doc-arg\n[doc-arg-ptr]]"*/" \
4743 .        nop ,\)\c
4744 .    nop \)\*[doc-space\n[doc-arg-ptr]]\*[doc-Fa-font]\c
4745 .    nop \)\*[doc-arg\n[doc-arg-ptr]]\f[]\s[0]\c
4746 .  \}
4747 .
4748 .  if (\n[doc-func-arg-count] == 1) \{\
4749 .    nop \)\*[doc-Fa-font]\*[doc-arg\n[doc-arg-ptr]]\c
4750 .    nop \f[]\s[0]\c
4751 .  \}
4752 .  nr doc-func-arg-count +1
4753 .  doc-do-func
4754 ..
4755 .
4756 .
4757 .\" NS doc-have-func global register (bool)
4758 .\" NS   whether we have more than one function in synopsis
4759 .
4760 .nr doc-have-func 0
4761 .
4762 .
4763 .\" NS Fn user macro
4764 .\" NS   functions
4765 .\" NS
4766 .\" NS modifies:
4767 .\" NS   doc-arg-ptr
4768 .\" NS   doc-curr-font
4769 .\" NS   doc-curr-size
4770 .\" NS   doc-have-decl
4771 .\" NS   doc-have-func
4772 .\" NS   doc-have-var
4773 .\" NS   doc-indent-synopsis
4774 .\" NS   doc-is-func
4775 .\" NS   doc-macro-name
4776 .\" NS
4777 .\" NS width register `Fn' set in doc-common
4778 .
4779 .de Fn
4780 .  if !\n[doc-arg-limit] \{\
4781 .    ie \n[.$] \{\
4782 .      ds doc-macro-name Fn
4783 .      doc-parse-args \$@
4784 .    \}
4785 .    el \
4786 .      tm Usage: .Fn function_name [function_arg] ... (#\n[.c])
4787 .  \}
4788 .
4789 .  if !\n[doc-arg-limit] \
4790 .    return
4791 .
4792 .  if \n[doc-in-synopsis-section] \{\
4793 .    \" if there is/has been more than one subroutine declaration
4794 .    ie \n[doc-is-func] \{\
4795 .      br
4796 .      nr doc-have-var 0
4797 .      nr doc-have-decl 0
4798 .      nr doc-is-func 0
4799 .    \}
4800 .    el \{\
4801 .      if \n[doc-have-func] \{\
4802 .        doc-paragraph
4803 .        nr doc-have-var 0
4804 .        nr doc-have-decl 0
4805 .    \}\}
4806 .
4807 .    if \n[doc-have-decl] \{\
4808 .      doc-paragraph
4809 .      nr doc-have-var 0
4810 .    \}
4811 .
4812 .    if \n[doc-have-var] \{\
4813 .      doc-paragraph
4814 .      nr doc-have-decl 0
4815 .    \}
4816 .
4817 .    nr doc-have-func 1
4818 .    nr doc-is-func 0
4819 .
4820 .    br
4821 .    if !\n[doc-indent-synopsis] \
4822 .      nr doc-indent-synopsis (4u * \n[doc-fixed-width]u)
4823 .    if !\n[doc-indent-synopsis-active] \
4824 .      in +\n[doc-indent-synopsis]u
4825 .    ti -\n[doc-indent-synopsis]u
4826 .  \}
4827 .
4828 .  nr doc-arg-ptr +1
4829 .  doc-print-prefixes
4830 .  if (\n[doc-arg-limit] < \n[doc-arg-ptr]) \{\
4831 .    tm Usage: .Fn function_name [function_arg] ... (#\n[.c])
4832 .    doc-reset-args
4833 .    return
4834 .  \}
4835 .
4836 .  nr doc-curr-font \n[.f]
4837 .  nr doc-curr-size \n[.ps]
4838 .  nop \*[doc-Fn-font]\*[doc-arg\n[doc-arg-ptr]]\c
4839 .  nop \f[]\s[0]\*[lp]\)\c
4840 .
4841 .  nr doc-arg-ptr +1
4842 .  if (\n[doc-arg-limit] >= \n[doc-arg-ptr]) \{\
4843 .    if (\n[doc-type\n[doc-arg-ptr]] == 2) \{\
4844 .      nop \*[doc-Fa-font]\c
4845 .      doc-do-func-args
4846 .      nop \f[\n[doc-curr-font]]\s[\n[doc-curr-size]u]\c
4847 .  \}\}
4848 .
4849 .  nop \)\*[rp]\)\c
4850 .  if \n[doc-in-synopsis-section] \
4851 .    nop \);\)\c
4852 .
4853 .  ie (\n[doc-arg-limit] >= \n[doc-arg-ptr]) \{\
4854 .    \" output the space (if needed)
4855 .    nr doc-arg-ptr -1
4856 .    nop \)\*[doc-space\n[doc-arg-ptr]]\c
4857 .    nr doc-arg-ptr +1
4858 .
4859 .    doc-print-recursive
4860 .  \}
4861 .  el \
4862 .    doc-print-and-reset
4863 .
4864 .  if \n[doc-in-synopsis-section] \
4865 .    if !\n[doc-indent-synopsis-active] \
4866 .      in -\n[doc-indent-synopsis]u
4867 ..
4868 .
4869 .
4870 .\" NS doc-do-func-args macro
4871 .\" NS   handle function arguments
4872 .\" NS
4873 .\" NS modifies:
4874 .\" NS   doc-arg-ptr
4875 .\" NS   doc-argXXX
4876 .\" NS   doc-func-arg
4877 .\" NS   doc-func-args-processed
4878 .\" NS   doc-num-func-args
4879 .\" NS
4880 .\" NS local variables:
4881 .\" NS   doc-reg-ddfa
4882 .
4883 .de doc-do-func-args
4884 .  if \n[doc-in-synopsis-section] \{\
4885 .    ds doc-func-arg
4886 .    nr doc-num-func-args 0
4887 .    nr doc-func-args-processed 0
4888 .
4889 .    doc-build-func-string \*[doc-arg\n[doc-arg-ptr]]
4890 .    if (\n[doc-num-func-args] > 1) \
4891 .      ds doc-arg\n[doc-arg-ptr] "\*[doc-func-arg]
4892 .  \}
4893 .
4894 .  nop \)\*[doc-arg\n[doc-arg-ptr]]\c
4895 .  nr doc-arg-ptr +1
4896 .
4897 .  if (\n[doc-arg-limit] >= \n[doc-arg-ptr]) \{\
4898 .    if (\n[doc-type\n[doc-arg-ptr]] == 2) \{\
4899 .      nr doc-reg-ddfa (\n[doc-arg-ptr] - 1)
4900 .      nop \f[\n[doc-curr-font]]\s[\n[doc-curr-size]u]\|\c
4901 .      if !"\*[doc-arg\n[doc-arg-ptr]]"/*" \
4902 .        if !"\*[doc-arg\n[doc-arg-ptr]]"*/" \
4903 .          nop ,\)\c
4904 .      nop \)\*[doc-space\n[doc-reg-ddfa]]\f[]\s[0]\|\c
4905 .      doc-do-func-args
4906 .  \}\}
4907 ..
4908 .
4909 .
4910 .\" NS doc-saved-nesting-level global register
4911 .
4912 .nr doc-saved-nesting-level 0
4913 .
4914 .
4915 .\" NS doc-in-func-enclosure global register (bool)
4916 .
4917 .nr doc-in-func-enclosure 0
4918 .
4919 .
4920 .\" NS Fo user macro
4921 .\" NS   function open
4922 .\" NS
4923 .\" NS modifies:
4924 .\" NS   doc-arg-ptr
4925 .\" NS   doc-curr-font
4926 .\" NS   doc-curr-size
4927 .\" NS   doc-func-arg-count
4928 .\" NS   doc-have-decl
4929 .\" NS   doc-have-func
4930 .\" NS   doc-have-var
4931 .\" NS   doc-in-func-enclosure
4932 .\" NS   doc-indent-synopsis
4933 .\" NS   doc-is-func
4934 .\" NS   doc-macro-name
4935 .\" NS   doc-saved-nesting-level
4936 .\" NS
4937 .\" NS width register `Fo' set in doc-common
4938 .
4939 .de Fo
4940 .  if (\n[doc-in-func-enclosure]) \{\
4941 .    tm mdoc error: .Fo/.Fc can't be nested (#\n[.c])
4942 .    return
4943 .  \}
4944 .
4945 .  nr doc-saved-nesting-level \n[doc-nesting-level]
4946 .  nr doc-in-func-enclosure 1
4947 .
4948 .  if !\n[doc-arg-limit] \{\
4949 .    ie \n[.$] \{\
4950 .      ds doc-macro-name Fo
4951 .      doc-parse-args \$@
4952 .    \}
4953 .    el \
4954 .      tm Usage: .Fo function_name (#\n[.c])
4955 .  \}
4956 .
4957 .  if \n[doc-in-synopsis-section] \{\
4958 .    \" if there is/has been more than one subroutine declaration
4959 .    ie \n[doc-is-func] \{\
4960 .      br
4961 .      nr doc-have-var 0
4962 .      nr doc-have-decl 0
4963 .      nr doc-is-func 0
4964 .    \}
4965 .    el \{\
4966 .      if \n[doc-have-func] \{\
4967 .        doc-paragraph
4968 .        nr doc-have-var 0
4969 .        nr doc-have-decl 0
4970 .    \}\}
4971 .
4972 .    if \n[doc-have-decl] \{\
4973 .      doc-paragraph
4974 .      nr doc-have-var 0
4975 .    \}
4976 .
4977 .    if \n[doc-have-var] \{\
4978 .      doc-paragraph
4979 .      nr doc-have-decl 0
4980 .    \}
4981 .
4982 .    nr doc-have-func 1
4983 .    nr doc-is-func 0
4984 .
4985 .    br
4986 .    if !\n[doc-indent-synopsis] \
4987 .      nr doc-indent-synopsis (4u * \n[doc-fixed-width]u)
4988 .  \}
4989 .
4990 .  \" start function box
4991 .  box doc-func-box
4992 .  ev doc-func-env
4993 .  evc 0
4994 .  in 0
4995 .  nf
4996 .
4997 .  nr doc-arg-ptr +1
4998 .  doc-print-prefixes
4999 .  if (\n[doc-arg-limit] >= \n[doc-arg-ptr]) \{\
5000 .    nr doc-func-arg-count 1
5001 .    nr doc-curr-font \n[.f]
5002 .    nr doc-curr-size \n[.ps]
5003 .
5004 .    nop \*[doc-Fn-font]\*[doc-arg\n[doc-arg-ptr]]\c
5005 .    nop \f[]\s[0]\*[lp]\)\c
5006 .    doc-reset-args
5007 .  \}
5008 ..
5009 .
5010 .
5011 .\" NS Fc user macro
5012 .\" NS   function close
5013 .\" NS
5014 .\" NS modifies:
5015 .\" NS   doc-arg-ptr
5016 .\" NS   doc-func-arg-count
5017 .\" NS   doc-in-func-enclosure
5018 .\" NS   doc-saved-nesting-level
5019 .\" NS   doc-macro-name
5020 .\" NS
5021 .\" NS width register `Fc' set in doc-common
5022 .
5023 .de Fc
5024 .  if !\n[doc-in-func-enclosure] \{\
5025 .    tm mdoc warning: Extraneous .Fc (#\n[.c])
5026 .    return
5027 .  \}
5028 .
5029 .  if \n[.$] \{\
5030 .    ds doc-macro-name Fc
5031 .    \" the first (dummy) argument is used to get the correct spacing
5032 .    doc-parse-args \) \$@
5033 .  \}
5034 .
5035 .  if !(\n[doc-saved-nesting-level] == \n[doc-nesting-level]) \
5036 .    tm mdoc warning: Unbalanced enclosure commands within .Fo/.Fc
5037 .
5038 .  nr doc-func-arg-count 0
5039 .  nr doc-in-func-enclosure 0
5040 .
5041 .  ie \n[doc-in-synopsis-section] \
5042 .    nop \|\*[rp];\)
5043 .  el \
5044 .    nop \|\*[rp]\)
5045 .
5046 .  \" finish function box
5047 .  br
5048 .  ev
5049 .  box
5050 .  chop doc-func-box
5051 .  unformat doc-func-box
5052 .
5053 .  if \n[doc-in-synopsis-section] \{\
5054 .    if !\n[doc-indent-synopsis-active] \
5055 .      in +\n[doc-indent-synopsis]u
5056 .    ti -\n[doc-indent-synopsis]u
5057 .  \}
5058 .
5059 .  nh
5060 .  nop \*[doc-func-box]\c
5061 .
5062 .  nr doc-arg-ptr +1
5063 .  ie (\n[doc-arg-limit] >= \n[doc-arg-ptr]) \{\
5064 .    nr doc-curr-font \n[.f]
5065 .    nr doc-curr-size \n[.ps]
5066 .    doc-print-recursive
5067 .  \}
5068 .  el \
5069 .    doc-print-and-reset
5070 .
5071 .  if \n[doc-in-synopsis-section] \
5072 .    if !\n[doc-indent-synopsis-active] \
5073 .      in -\n[doc-indent-synopsis]u
5074 ..
5075 .
5076 .
5077 .\" NS doc-build-func-string macro
5078 .\" NS   collect function arguments and set hard spaces inbetween
5079 .\" NS
5080 .\" NS modifies:
5081 .\" NS   doc-func-arg
5082 .\" NS   doc-func-args-processed
5083 .\" NS   doc-num-func-args
5084 .
5085 .de doc-build-func-string
5086 .  if !\n[doc-num-func-args] \{\
5087 .    nr doc-num-func-args \n[.$]
5088 .    nr doc-func-args-processed 0
5089 .    ds doc-func-arg
5090 .  \}
5091 .
5092 .  nr doc-func-args-processed +1
5093 .  as doc-func-arg "\$1
5094 .
5095 .  if (\n[doc-func-args-processed] < \n[doc-num-func-args]) \{\
5096 .    as doc-func-arg "\*[doc-hard-space]
5097 .
5098 .    shift
5099 .    doc-build-func-string \$@
5100 .  \}
5101 ..
5102 .
5103 .
5104 .\" Very crude references: Stash all reference info into boxes, print out
5105 .\" reference on .Re macro and clean up.  Ordering very limited, no fancy
5106 .\" citations, but can do articles, journals, and books -- need to add
5107 .\" several missing options (like city etc).  Should be able to grab a refer
5108 .\" entry, massage it a wee bit (prefix a `.' to the %[A-Z]) and not worry
5109 .\" (ha!).
5110 .
5111 .
5112 .\" NS doc-is-reference global register (bool)
5113 .\" NS   set if in reference
5114 .
5115 .nr doc-is-reference 0
5116 .
5117 .
5118 .\" NS doc-reference-count global register
5119 .\" NS   reference element counter
5120 .
5121 .nr doc-reference-count 0
5122 .
5123 .
5124 .\" NS Rs user macro
5125 .\" NS   reference start
5126 .\" NS
5127 .\" NS modifies:
5128 .\" NS   doc-is-reference
5129 .\" NS   doc-reference-count
5130 .\" NS
5131 .\" NS width register `Rs' set in doc-common
5132 .
5133 .de Rs
5134 .  ie \n[.$] \
5135 .    tm Usage: .Rs (does not take arguments) (#\n[.c])
5136 .  el \{\
5137 .    nr doc-is-reference 1
5138 .    doc-reset-reference
5139 .    if \n[doc-in-see-also-section] \
5140 .      doc-paragraph
5141 .    nr doc-reference-count 0
5142 .  \}
5143 ..
5144 .
5145 .
5146 .\" NS Re user macro
5147 .\" NS   reference end
5148 .\" NS
5149 .\" NS modifies:
5150 .\" NS   doc-is-reference
5151 .\" NS
5152 .\" NS width register `Re' set in doc-common
5153 .
5154 .de Re
5155 .  ie \n[.$] \
5156 .    tm Usage: .Re (does not take arguments) (#\n[.c])
5157 .  el \{\
5158 .    if !\n[doc-is-reference] \{\
5159 .      tm mdoc warning: Extraneous .Re (#\n[.c])
5160 .      return
5161 .    \}
5162 .    doc-print-reference
5163 .    doc-reset-reference
5164 .    nr doc-is-reference 0
5165 .  \}
5166 ..
5167 .
5168 .
5169 .\" NS doc-reset-reference macro
5170 .\" NS   reference cleanup
5171 .\" NS
5172 .\" NS modifies:
5173 .\" NS   doc-author-count
5174 .\" NS   doc-author-nameXXX
5175 .\" NS   doc-book-count
5176 .\" NS   doc-book-name
5177 .\" NS   doc-corporate-count
5178 .\" NS   doc-corporate-name
5179 .\" NS   doc-date
5180 .\" NS   doc-date-count
5181 .\" NS   doc-issue-count
5182 .\" NS   doc-issue-name
5183 .\" NS   doc-journal-count
5184 .\" NS   doc-journal-name
5185 .\" NS   doc-optional-count
5186 .\" NS   doc-optional-string
5187 .\" NS   doc-page-number-count
5188 .\" NS   doc-page-number-string
5189 .\" NS   doc-publisher-count
5190 .\" NS   doc-publisher-name
5191 .\" NS   doc-reference-count
5192 .\" NS   doc-reference-title-count
5193 .\" NS   doc-reference-title-name
5194 .\" NS   doc-reference-title-name-for-book
5195 .\" NS   doc-report-count
5196 .\" NS   doc-report-name
5197 .\" NS   doc-volume-count
5198 .\" NS   doc-volume-name
5199 .
5200 .de doc-reset-reference
5201 .  while (\n[doc-author-count]) \{\
5202 .    ds doc-author-name\n[doc-author-count]
5203 .    nr doc-author-count -1
5204 .  \}
5205 .  nr doc-journal-count 0
5206 .  nr doc-issue-count 0
5207 .  nr doc-optional-count 0
5208 .  nr doc-corporate-count 0
5209 .  nr doc-report-count 0
5210 .  nr doc-reference-title-count 0
5211 .  nr doc-volume-count 0
5212 .  nr doc-date-count 0
5213 .  nr doc-page-number-count 0
5214 .  nr doc-book-count 0
5215 .  nr doc-publisher-count 0
5216 .  nr doc-reference-count 0
5217 .
5218 .  ds doc-journal-name
5219 .  ds doc-issue-name
5220 .  ds doc-optional-string
5221 .  ds doc-corporate-name
5222 .  ds doc-report-name
5223 .  ds doc-reference-title-name
5224 .  ds doc-reference-title-name-for-book
5225 .  ds doc-volume-name
5226 .  ds doc-date
5227 .  ds doc-page-number-string
5228 .  ds doc-book-name
5229 .  ds doc-publisher-name
5230 ..
5231 .
5232 .
5233 .\" NS doc-finish-reference macro
5234 .\" NS   auxiliary macro for doc-print-reference
5235 .\" NS
5236 .\" NS modifies:
5237 .\" NS   doc-reference-count
5238 .
5239 .de doc-finish-reference
5240 .  nr doc-reference-count -\$1
5241 .  ie \n[doc-reference-count] \
5242 .    nop \),
5243 .  el \
5244 .    nop \).
5245 ..
5246 .
5247 .
5248 .\" NS doc-print-reference macro
5249 .\" NS   reference print
5250 .\" NS
5251 .\" NS modifies:
5252 .\" NS   doc-reference-count
5253 .
5254 .de doc-print-reference
5255 .
5256 .  nh
5257 .
5258 .  if \n[doc-author-count] \{\
5259 .    doc-print-reference-authors
5260 .    nr doc-reference-count -\n[doc-author-count]
5261 .  \}
5262 .
5263 .  if \n[doc-reference-title-count] \{\
5264 .    unformat doc-reference-title-name
5265 .    chop doc-reference-title-name
5266 .    unformat doc-reference-title-name-for-book
5267 .    chop doc-reference-title-name-for-book
5268 .    ie ((\n[doc-journal-count] == 1) : (\n[doc-book-count] == 1)) \{\
5269 .      nop \)\*[q]\)\*[doc-reference-title-name-for-book]\)\*[q]\c
5270 .      doc-finish-reference \n[doc-reference-title-count]
5271 .    \}
5272 .    el \{\
5273 .      nop \*[doc-reference-title-name]\c
5274 .      doc-finish-reference \n[doc-reference-title-count]
5275 .  \}\}
5276 .
5277 .  if \n[doc-book-count] \{\
5278 .    unformat doc-book-name
5279 .    chop doc-book-name
5280 .    nop \*[doc-book-name]\c
5281 .    doc-finish-reference \n[doc-book-count]
5282 .  \}
5283 .
5284 .  if \n[doc-publisher-count] \{\
5285 .    unformat doc-publisher-name
5286 .    chop doc-publisher-name
5287 .    nop \*[doc-publisher-name]\c
5288 .    doc-finish-reference \n[doc-publisher-count]
5289 .  \}
5290 .
5291 .  if \n[doc-journal-count] \{\
5292 .    unformat doc-journal-name
5293 .    chop doc-journal-name
5294 .    nop \*[doc-journal-name]\c
5295 .    doc-finish-reference \n[doc-journal-count]
5296 .  \}
5297 .
5298 .  if \n[doc-report-count] \{\
5299 .    unformat doc-report-name
5300 .    chop doc-report-name
5301 .    nop \*[doc-report-name]\c
5302 .    doc-finish-reference \n[doc-report-count]
5303 .  \}
5304 .
5305 .  if \n[doc-issue-count] \{\
5306 .    unformat doc-issue-name
5307 .    chop doc-issue-name
5308 .    nop \*[doc-issue-name]\c
5309 .    doc-finish-reference \n[doc-issue-count]
5310 .  \}
5311 .
5312 .  if \n[doc-volume-count] \{\
5313 .    unformat doc-volume-name
5314 .    chop doc-volume-name
5315 .    nop \*[doc-volume-name]\c
5316 .    doc-finish-reference \n[doc-volume-count]
5317 .  \}
5318 .
5319 .  if \n[doc-page-number-count] \{\
5320 .    unformat doc-page-number-string
5321 .    chop doc-page-number-string
5322 .    nop \*[doc-page-number-string]\c
5323 .    doc-finish-reference \n[doc-page-number-count]
5324 .  \}
5325 .
5326 .  if \n[doc-corporate-count] \{\
5327 .    unformat doc-corporate-name
5328 .    chop doc-corporate-name
5329 .    nop \*[doc-corporate-name]\c
5330 .    doc-finish-reference \n[doc-corporate-count]
5331 .  \}
5332 .
5333 .  if \n[doc-date-count] \{\
5334 .    unformat doc-date
5335 .    chop doc-date
5336 .    nop \*[doc-date]\c
5337 .    doc-finish-reference \n[doc-date-count]
5338 .  \}
5339 .
5340 .  if \n[doc-optional-count] \{\
5341 .    unformat doc-optional-string
5342 .    chop doc-optional-string
5343 .    nop \*[doc-optional-string]\c
5344 .    doc-finish-reference \n[doc-optional-count]
5345 .  \}
5346 .
5347 .  if \n[doc-reference-count] \
5348 .    tm mdoc warning: unresolved reference problem
5349 .
5350 .  hy \n[doc-hyphen-flags]
5351 ..
5352 .
5353 .
5354 .\" NS doc-print-reference-authors macro
5355 .\" NS   print out reference authors
5356 .\" NS
5357 .\" NS local variables:
5358 .\" NS   doc-reg-dpra
5359 .\" NS   doc-str-dpra
5360 .
5361 .ds doc-str-dpra "and
5362 .
5363 .de doc-print-reference-authors
5364 .  nr doc-reg-dpra 1
5365 .
5366 .  while (\n[doc-reg-dpra] < \n[doc-author-count]) \{\
5367 .    unformat doc-author-name\n[doc-reg-dpra]
5368 .    chop doc-author-name\n[doc-reg-dpra]
5369 .    ie (\n[doc-author-count] > 2) \
5370 .      nop \)\*[doc-author-name\n[doc-reg-dpra]],
5371 .    el \
5372 .      nop \)\*[doc-author-name\n[doc-reg-dpra]]
5373 .    nr doc-reg-dpra +1
5374 .  \}
5375 .
5376 .  unformat doc-author-name\n[doc-reg-dpra]
5377 .  chop doc-author-name\n[doc-reg-dpra]
5378 .  if (\n[doc-author-count] > 1) \
5379 .    nop \)\*[doc-str-dpra]
5380 .  nop \)\*[doc-author-name\n[doc-reg-dpra]],
5381 ..
5382 .
5383 .
5384 .\" NS doc-author-count global register
5385 .\" NS   counter of author references
5386 .
5387 .nr doc-author-count 0
5388 .
5389 .
5390 .\" NS doc-author-nameXXX global box
5391 .\" NS   array of author names
5392 .\" NS
5393 .\" NS limit:
5394 .\" NS   doc-author-count
5395 .
5396 .ds doc-author-name0
5397 .
5398 .
5399 .\" NS %A user macro
5400 .\" NS   reference author(s)
5401 .\" NS
5402 .\" NS modifies:
5403 .\" NS   doc-arg-ptr
5404 .\" NS   doc-author-count
5405 .\" NS   doc-curr-font
5406 .\" NS   doc-curr-size
5407 .\" NS   doc-macro-name
5408 .\" NS   doc-reference-count
5409 .\" NS
5410 .\" NS local variables:
5411 .\" NS   doc-env-%A
5412 .\" NS
5413 .\" NS width register `%A' set in doc-common
5414 .
5415 .de %A
5416 .  if (\n[doc-arg-limit] : (\n[.$] == 0)) \{\
5417 .    tm Usage: .%A author_name ... (#\n[.c])
5418 .    return
5419 .  \}
5420 .
5421 .  nr doc-author-count +1
5422 .  nr doc-reference-count +1
5423 .
5424 .  ds doc-macro-name %A
5425 .  doc-parse-args \$@
5426 .
5427 .  nr doc-arg-ptr +1
5428 .  nr doc-curr-font \n[.f]
5429 .  nr doc-curr-size \n[.ps]
5430 .
5431 .  \" save to reference box
5432 .  box doc-author-name\n[doc-author-count]
5433 .  ev doc-env-%A
5434 .  evc 0
5435 .  in 0
5436 .  nf
5437 .  doc-do-references
5438 ..
5439 .
5440 .
5441 .\" NS doc-book-count global register
5442 .\" NS   counter of book references
5443 .
5444 .nr doc-book-count 0
5445 .
5446 .
5447 .\" NS doc-book-name global box
5448 .\" NS   string of collected book references
5449 .
5450 .ds doc-book-name
5451 .
5452 .
5453 .\" NS %B user macro
5454 .\" NS   [reference] book name
5455 .\" NS
5456 .\" NS modifies:
5457 .\" NS   doc-arg-ptr
5458 .\" NS   doc-book-count
5459 .\" NS   doc-curr-font
5460 .\" NS   doc-curr-size
5461 .\" NS   doc-macro-name
5462 .\" NS   doc-reference-count
5463 .\" NS
5464 .\" NS local variables:
5465 .\" NS   doc-env-%B
5466 .\" NS
5467 .\" NS width register `%B' set in doc-common
5468 .
5469 .de %B
5470 .  if (\n[doc-arg-limit] : (\n[.$] == 0)) \{\
5471 .    tm Usage: .%B book_name ... (#\n[.c])
5472 .    return
5473 .  \}
5474 .
5475 .  if \n[doc-is-reference] \{\
5476 .    nr doc-book-count +1
5477 .    nr doc-reference-count +1
5478 .  \}
5479 .
5480 .  ds doc-macro-name %B
5481 .  doc-parse-args \$@
5482 .
5483 .  nr doc-arg-ptr +1
5484 .  nr doc-curr-font \n[.f]
5485 .  nr doc-curr-size \n[.ps]
5486 .
5487 .  ie \n[doc-is-reference] \{\
5488 .    \" append to reference box
5489 .    boxa doc-book-name
5490 .    ev doc-env-%B
5491 .    evc 0
5492 .    in 0
5493 .    nf
5494 .    nop \*[doc-Em-font]\c
5495 .    doc-do-references
5496 .  \}
5497 .  el \{\
5498 .    nop \*[doc-Em-font]\c
5499 .    doc-print-recursive
5500 .  \}
5501 ..
5502 .
5503 .
5504 .\" NS doc-date-count global register
5505 .\" NS   counter of date references
5506 .
5507 .nr doc-date-count 0
5508 .
5509 .
5510 .\" NS doc-date global box
5511 .\" NS   string of collected date references
5512 .
5513 .ds doc-date
5514 .
5515 .
5516 .\" NS %D user macro
5517 .\" NS   [reference] date
5518 .\" NS
5519 .\" NS modifies:
5520 .\" NS   doc-arg-ptr
5521 .\" NS   doc-curr-font
5522 .\" NS   doc-curr-size
5523 .\" NS   doc-date-count
5524 .\" NS   doc-macro-name
5525 .\" NS   doc-reference-count
5526 .\" NS
5527 .\" NS local variables:
5528 .\" NS   doc-env-%D
5529 .\" NS
5530 .\" NS width register `%D' set in doc-common
5531 .
5532 .de %D
5533 .  if (\n[doc-arg-limit] : (\n[.$] == 0)) \{\
5534 .    tm Usage: .%D date ... (#\n[.c])
5535 .    return
5536 .  \}
5537 .
5538 .  nr doc-date-count +1
5539 .  nr doc-reference-count +1
5540 .
5541 .  ds doc-macro-name %D
5542 .  doc-parse-args \$@
5543 .
5544 .  nr doc-arg-ptr +1
5545 .  nr doc-curr-font \n[.f]
5546 .  nr doc-curr-size \n[.ps]
5547 .
5548 .  \" append to reference box
5549 .  boxa doc-date
5550 .  ev doc-env-%D
5551 .  evc 0
5552 .  in 0
5553 .  nf
5554 .  doc-do-references
5555 ..
5556 .
5557 .
5558 .\" NS doc-publisher-count global register
5559 .\" NS   counter of publisher references
5560 .
5561 .nr doc-publisher-count 0
5562 .
5563 .
5564 .\" NS doc-publisher-name global box
5565 .\" NS   string of collected publisher references
5566 .
5567 .ds doc-publisher-name
5568 .
5569 .
5570 .\" NS %I user macro
5571 .\" NS   [reference] issuer/publisher name
5572 .\" NS
5573 .\" NS modifies:
5574 .\" NS   doc-arg-ptr
5575 .\" NS   doc-curr-font
5576 .\" NS   doc-curr-size
5577 .\" NS   doc-macro-name
5578 .\" NS   doc-publisher-count
5579 .\" NS   doc-reference-count
5580 .\" NS
5581 .\" NS local variables:
5582 .\" NS   doc-env-%I
5583 .\" NS
5584 .\" NS width register `%I' set in doc-common
5585 .
5586 .de %I
5587 .  if (\n[doc-arg-limit] : (\n[.$] == 0)) \{\
5588 .    tm Usage: .%I issuer/publisher_name ... (#\n[.c])
5589 .    return
5590 .  \}
5591 .
5592 .  nr doc-publisher-count +1
5593 .  nr doc-reference-count +1
5594 .
5595 .  ds doc-macro-name %I
5596 .  doc-parse-args \$@
5597 .
5598 .  nr doc-arg-ptr +1
5599 .  nr doc-curr-font \n[.f]
5600 .  nr doc-curr-size \n[.ps]
5601 .
5602 .  \" append to reference box
5603 .  boxa doc-publisher-name
5604 .  ev doc-env-%I
5605 .  evc 0
5606 .  in 0
5607 .  nf
5608 .  nop \*[doc-Em-font]\c
5609 .  doc-do-references
5610 ..
5611 .
5612 .
5613 .\" NS doc-journal-count global register
5614 .\" NS   counter of journal references
5615 .
5616 .nr doc-journal-count 0
5617 .
5618 .
5619 .\" NS doc-journal-name global box
5620 .\" NS   string of collected journal references
5621 .
5622 .ds doc-journal-name
5623 .
5624 .
5625 .\" NS %J user macro
5626 .\" NS   [reference] Journal Name
5627 .\" NS
5628 .\" NS modifies:
5629 .\" NS   doc-arg-ptr
5630 .\" NS   doc-curr-font
5631 .\" NS   doc-curr-size
5632 .\" NS   doc-journal-count
5633 .\" NS   doc-macro-name
5634 .\" NS   doc-reference-count
5635 .\" NS
5636 .\" NS local variables:
5637 .\" NS   doc-env-%J
5638 .\" NS
5639 .\" NS width register `%J' set in doc-common
5640 .
5641 .de %J
5642 .  if (\n[doc-arg-limit] : (\n[.$] == 0)) \{\
5643 .    tm Usage: .%J journal_name ... (#\n[.c])
5644 .    return
5645 .  \}
5646 .
5647 .  nr doc-journal-count +1
5648 .  nr doc-reference-count +1
5649 .
5650 .  ds doc-macro-name %J
5651 .  doc-parse-args \$@
5652 .
5653 .  nr doc-arg-ptr +1
5654 .  nr doc-curr-font \n[.f]
5655 .  nr doc-curr-size \n[.ps]
5656 .
5657 .  \" append to reference box
5658 .  boxa doc-journal-name
5659 .  ev doc-env-%J
5660 .  evc 0
5661 .  in 0
5662 .  nf
5663 .  nop \*[doc-Em-font]\c
5664 .  doc-do-references
5665 ..
5666 .
5667 .
5668 .\" NS doc-issue-count global register
5669 .\" NS   counter of issue number references
5670 .
5671 .nr doc-issue-count 0
5672 .
5673 .
5674 .\" NS doc-issue-name global box
5675 .\" NS   string of collected issue number references
5676 .
5677 .ds doc-issue-name
5678 .
5679 .
5680 .\" NS %N user macro
5681 .\" NS   [reference] issue number
5682 .\" NS
5683 .\" NS modifies:
5684 .\" NS   doc-arg-ptr
5685 .\" NS   doc-curr-font
5686 .\" NS   doc-curr-size
5687 .\" NS   doc-issue-count
5688 .\" NS   doc-macro-name
5689 .\" NS   doc-reference-count
5690 .\" NS
5691 .\" NS local variables:
5692 .\" NS   doc-env-%N
5693 .\" NS
5694 .\" NS width register `%N' set in doc-common
5695 .
5696 .de %N
5697 .  if (\n[doc-arg-limit] : (\n[.$] == 0)) \{\
5698 .    tm Usage: .%N issue_number ... (#\n[.c])
5699 .    return
5700 .  \}
5701 .
5702 .  nr doc-issue-count +1
5703 .  nr doc-reference-count +1
5704 .
5705 .  ds doc-macro-name %N
5706 .  doc-parse-args \$@
5707 .
5708 .  nr doc-arg-ptr +1
5709 .  nr doc-curr-font \n[.f]
5710 .  nr doc-curr-size \n[.ps]
5711 .
5712 .  \" append to reference box
5713 .  boxa doc-issue-name
5714 .  ev doc-env-%N
5715 .  evc 0
5716 .  in 0
5717 .  nf
5718 .  doc-do-references
5719 ..
5720 .
5721 .
5722 .\" NS doc-optional-count global register
5723 .\" NS   counter of optional information references
5724 .
5725 .nr doc-optional-count 0
5726 .
5727 .
5728 .\" NS doc-optional-string global box
5729 .\" NS   string of collected optional information references
5730 .
5731 .ds doc-optional-string
5732 .
5733 .
5734 .\" NS %O user macro
5735 .\" NS   [reference] optional information
5736 .\" NS
5737 .\" NS modifies:
5738 .\" NS   doc-arg-ptr
5739 .\" NS   doc-curr-font
5740 .\" NS   doc-curr-size
5741 .\" NS   doc-macro-name
5742 .\" NS   doc-optional-count
5743 .\" NS   doc-reference-count
5744 .\" NS
5745 .\" NS local variables:
5746 .\" NS   doc-env-%O
5747 .\" NS
5748 .\" NS width register `%O' set in doc-common
5749 .
5750 .de %O
5751 .  if (\n[doc-arg-limit] : (\n[.$] == 0)) \{\
5752 .    tm Usage: .%O optional_information ... (#\n[.c])
5753 .    return
5754 .  \}
5755 .
5756 .  nr doc-optional-count +1
5757 .  nr doc-reference-count +1
5758 .
5759 .  ds doc-macro-name %O
5760 .  doc-parse-args \$@
5761 .
5762 .  nr doc-arg-ptr +1
5763 .  nr doc-curr-font \n[.f]
5764 .  nr doc-curr-size \n[.ps]
5765 .
5766 .  \" append to reference box
5767 .  boxa doc-optional-string
5768 .  ev doc-env-%O
5769 .  evc 0
5770 .  in 0
5771 .  nf
5772 .  doc-do-references
5773 ..
5774 .
5775 .
5776 .\" NS doc-page-number-count global register
5777 .\" NS   counter of page number references
5778 .
5779 .nr doc-page-number-count 0
5780 .
5781 .
5782 .\" NS doc-page-number-string global box
5783 .\" NS   string of collected page number references
5784 .
5785 .ds doc-page-number-string
5786 .
5787 .
5788 .\" NS %P user macro
5789 .\" NS   [reference] page numbers
5790 .\" NS
5791 .\" NS modifies:
5792 .\" NS   doc-arg-ptr
5793 .\" NS   doc-curr-font
5794 .\" NS   doc-curr-size
5795 .\" NS   doc-macro-name
5796 .\" NS   doc-page-number-count
5797 .\" NS   doc-reference-count
5798 .\" NS
5799 .\" NS local variables:
5800 .\" NS   doc-env-%P
5801 .\" NS
5802 .\" NS width register `%P' set in doc-common
5803 .
5804 .de %P
5805 .  if (\n[doc-arg-limit] : (\n[.$] == 0)) \{\
5806 .    tm Usage: .%P page_number ... (#\n[.c])
5807 .    return
5808 .  \}
5809 .
5810 .  nr doc-page-number-count +1
5811 .  nr doc-reference-count +1
5812 .
5813 .  ds doc-macro-name %P
5814 .  doc-parse-args \$@
5815 .
5816 .  nr doc-arg-ptr +1
5817 .  nr doc-curr-font \n[.f]
5818 .  nr doc-curr-size \n[.ps]
5819 .
5820 .  \" append to reference box
5821 .  boxa doc-page-number-string
5822 .  ev doc-env-%P
5823 .  evc 0
5824 .  in 0
5825 .  nf
5826 .  doc-do-references
5827 ..
5828 .
5829 .
5830 .\" NS doc-corporate-count global register
5831 .\" NS   counter of corporate references
5832 .
5833 .nr doc-corporate-count 0
5834 .
5835 .
5836 .\" NS doc-corporate-name global box
5837 .\" NS   string of collected corporate references
5838 .
5839 .ds doc-corporate-name
5840 .
5841 .
5842 .\" NS %Q user macro
5843 .\" NS   corporate or foreign author
5844 .\" NS
5845 .\" NS modifies:
5846 .\" NS   doc-arg-ptr
5847 .\" NS   doc-corporate-count
5848 .\" NS   doc-curr-font
5849 .\" NS   doc-curr-size
5850 .\" NS   doc-macro-name
5851 .\" NS   doc-reference-count
5852 .\" NS
5853 .\" NS local variables:
5854 .\" NS   doc-env-%Q
5855 .\" NS
5856 .\" NS width register `%Q' set in doc-common
5857 .
5858 .de %Q
5859 .  if (\n[doc-arg-limit] : (\n[.$] == 0)) \{\
5860 .    tm Usage: .%Q corporate_or_foreign_author ... (#\n[.c])
5861 .    return
5862 .  \}
5863 .
5864 .  nr doc-corporate-count +1
5865 .  nr doc-reference-count +1
5866 .
5867 .  ds doc-macro-name %Q
5868 .  doc-parse-args \$@
5869 .
5870 .  nr doc-arg-ptr +1
5871 .  nr doc-curr-font \n[.f]
5872 .  nr doc-curr-size \n[.ps]
5873 .
5874 .  \" append to reference box
5875 .  boxa doc-corporate-name
5876 .  ev doc-env-%Q
5877 .  evc 0
5878 .  in 0
5879 .  nf
5880 .  doc-do-references
5881 ..
5882 .
5883 .
5884 .\" NS doc-report-count global register
5885 .\" NS   counter of report references
5886 .
5887 .nr doc-report-count 0
5888 .
5889 .
5890 .\" NS doc-report-name global box
5891 .\" NS   string of collected report references
5892 .
5893 .ds doc-report-name
5894 .
5895 .
5896 .\" NS %R user macro
5897 .\" NS   [reference] report name
5898 .\" NS
5899 .\" NS modifies:
5900 .\" NS   doc-arg-ptr
5901 .\" NS   doc-curr-font
5902 .\" NS   doc-curr-size
5903 .\" NS   doc-macro-name
5904 .\" NS   doc-reference-count
5905 .\" NS   doc-report-count
5906 .\" NS
5907 .\" NS local variables:
5908 .\" NS   doc-env-%R
5909 .\" NS
5910 .\" NS width register `%R' set in doc-common
5911 .
5912 .de %R
5913 .  if (\n[doc-arg-limit] : (\n[.$] == 0)) \{\
5914 .    tm Usage: .%R reference_report ... (#\n[.c])
5915 .    return
5916 .  \}
5917 .
5918 .  nr doc-report-count +1
5919 .  nr doc-reference-count +1
5920 .
5921 .  ds doc-macro-name %R
5922 .  doc-parse-args \$@
5923 .
5924 .  nr doc-arg-ptr +1
5925 .  nr doc-curr-font \n[.f]
5926 .  nr doc-curr-size \n[.ps]
5927 .
5928 .  \" append to reference box
5929 .  boxa doc-report-name
5930 .  ev doc-env-%R
5931 .  evc 0
5932 .  in 0
5933 .  nf
5934 .  doc-do-references
5935 ..
5936 .
5937 .
5938 .\" NS doc-reference-title-count global register
5939 .\" NS   counter of reference title references
5940 .
5941 .nr doc-reference-title-count 0
5942 .
5943 .
5944 .\" NS doc-reference-title-name global box
5945 .\" NS   string of collected reference title references
5946 .
5947 .ds doc-reference-title-name
5948 .
5949 .
5950 .\" NS doc-reference-title-name-for-book global box
5951 .\" NS   string of collected reference title references
5952 .\" NS   (saved with another font; this is a shortcoming of groff)
5953 .
5954 .ds doc-reference-title-name-for-book
5955 .
5956 .
5957 .\" NS %T user macro
5958 .\" NS   reference title
5959 .\" NS
5960 .\" NS modifies:
5961 .\" NS   doc-arg-ptr
5962 .\" NS   doc-curr-font
5963 .\" NS   doc-curr-size
5964 .\" NS   doc-macro-name
5965 .\" NS   doc-reference-title-count
5966 .\" NS   doc-report-count
5967 .\" NS
5968 .\" NS local variables:
5969 .\" NS   doc-env-%T
5970 .\" NS
5971 .\" NS width register `%T' set in doc-common
5972 .
5973 .de %T
5974 .  if (\n[doc-arg-limit] : (\n[.$] == 0)) \{\
5975 .    tm Usage: .%T reference_title ... (#\n[.c])
5976 .    return
5977 .  \}
5978 .
5979 .  if \n[doc-is-reference] \{\
5980 .    nr doc-reference-title-count +1
5981 .    nr doc-reference-count +1
5982 .  \}
5983 .
5984 .  ds doc-macro-name %T
5985 .  doc-parse-args \$@
5986 .
5987 .  nr doc-arg-ptr +1
5988 .  nr doc-curr-font \n[.f]
5989 .  nr doc-curr-size \n[.ps]
5990 .  ie \n[doc-is-reference] \{\
5991 .    \" append to reference box
5992 .    boxa doc-reference-title-name-for-book
5993 .    ev doc-env-%T
5994 .    evc 0
5995 .    in 0
5996 .    nf
5997 .    nop \*[doc-No-font]\c
5998 .    doc-do-references
5999 .
6000 .    \" do it a second time with another font
6001 .    ds doc-macro-name %T
6002 .    doc-parse-args \$@
6003 .
6004 .    nr doc-arg-ptr +1
6005 .    nr doc-curr-font \n[.f]
6006 .    nr doc-curr-size \n[.ps]
6007 .    boxa doc-reference-title-name
6008 .    ev doc-env-%T
6009 .    evc 0
6010 .    in 0
6011 .    nf
6012 .    nop \*[doc-Em-font]\c
6013 .    doc-do-references
6014 .  \}
6015 .  el \{\
6016 .    nop \*[doc-Em-font]\c
6017 .    doc-print-recursive
6018 .  \}
6019 ..
6020 .
6021 .
6022 .\" NS doc-volume-count global register
6023 .\" NS   counter of reference title references
6024 .
6025 .nr doc-volume-count 0
6026 .
6027 .
6028 .\" NS doc-volume-name global box
6029 .\" NS   string of collected volume references
6030 .
6031 .ds doc-volume-name
6032 .
6033 .
6034 .\" NS %V user macro
6035 .\" NS   reference volume
6036 .\" NS
6037 .\" NS modifies:
6038 .\" NS   doc-arg-ptr
6039 .\" NS   doc-curr-font
6040 .\" NS   doc-curr-size
6041 .\" NS   doc-macro-name
6042 .\" NS   doc-reference-title-count
6043 .\" NS   doc-volume-count
6044 .\" NS
6045 .\" NS local variables:
6046 .\" NS   doc-env-%V
6047 .\" NS
6048 .\" NS width register `%V' set in doc-common
6049 .
6050 .de %V
6051 .  if (\n[doc-arg-limit] : (\n[.$] == 0)) \{\
6052 .    tm Usage: .%V volume ... (#\n[.c])
6053 .    return
6054 .  \}
6055 .
6056 .  nr doc-volume-count +1
6057 .  nr doc-reference-count +1
6058 .
6059 .  ds doc-macro-name %V
6060 .  doc-parse-args \$@
6061 .
6062 .  nr doc-arg-ptr +1
6063 .  nr doc-curr-font \n[.f]
6064 .  nr doc-curr-size \n[.ps]
6065 .
6066 .  \" append to reference box
6067 .  boxa doc-volume-name
6068 .  ev doc-env-%V
6069 .  evc 0
6070 .  in 0
6071 .  nf
6072 .  doc-do-references
6073 ..
6074 .
6075 .
6076 .\" NS doc-do-references macro
6077 .\" NS   reference recursion routine
6078 .\" NS
6079 .\" NS modifies:
6080 .\" NS   doc-arg-ptr
6081 .\" NS
6082 .\" NS local variables:
6083 .\" NS   doc-reg-ddr
6084 .\" NS   doc-reg-ddr1
6085 .
6086 .de doc-do-references
6087 .  if !\n[doc-is-reference] \
6088 .    tm mdoc error: .\*[doc-macro-name] found outside of .Rs ... .Re (#\n[.c])
6089 .
6090 .  nr doc-reg-ddr1 \n[doc-type\n[doc-arg-ptr]]
6091 .
6092 .  ie (\n[doc-reg-ddr1] == 1) \{\
6093 .    \" .nop \f[\n[doc-curr-font]]\s[\n[doc-curr-size]u]\c
6094 .    doc-append-arg \c 3
6095 .    \*[doc-arg\n[doc-arg-ptr]]
6096 .  \}
6097 .  el \{\
6098 .    nop \)\*[doc-arg\n[doc-arg-ptr]]\c
6099 .
6100 .    ie (\n[doc-arg-limit] == \n[doc-arg-ptr]) \{\
6101 .      \" finish reference box
6102 .      br
6103 .      ev
6104 .      boxa
6105 .
6106 .      doc-reset-args
6107 .    \}
6108 .    el \{\
6109 .      nr doc-reg-ddr \n[doc-arg-ptr]
6110 .      nr doc-arg-ptr +1
6111 .      nop \)\*[doc-space\n[doc-reg-ddr]]\c
6112 .      doc-do-references
6113 .  \}\}
6114 ..
6115 .
6116 .
6117 .\" NS Hf user macro
6118 .\" NS   source include header files.
6119 .\" NS
6120 .\" NS modifies:
6121 .\" NS   doc-curr-font
6122 .\" NS   doc-curr-size
6123 .\" NS
6124 .\" NS width register `Hf' set in doc-common
6125 .
6126 .de Hf
6127 .  ie ((\n[.$] == 1) & (\n[doc-arg-limit] == 0)) \{\
6128 .    doc-paragraph
6129 .    nop File:
6130 .    Pa \$1
6131 .
6132 .    Bd -literal
6133 .    so \$1
6134 .    Ed
6135 .
6136 .    doc-paragraph
6137 .  \}
6138 .  el \
6139 .    Usage: .Hf file (#\n[.c])
6140 ..
6141 .
6142 .
6143 .\" NS doc-have-author global register (bool)
6144 .\" NS   set in `An'
6145 .
6146 .nr doc-have-author 0
6147 .
6148 .
6149 .\" NS An user macro
6150 .\" NS   author name
6151 .\" NS
6152 .\" NS modifies:
6153 .\" NS   doc-arg-ptr
6154 .\" NS   doc-curr-font
6155 .\" NS   doc-curr-size
6156 .\" NS   doc-have-author
6157 .\" NS   doc-macro-name
6158 .\" NS
6159 .\" NS width register `An' set in doc-common
6160 .
6161 .de An
6162 .  if !\n[doc-arg-limit] \{\
6163 .    ie \n[.$] \{\
6164 .      ie        "\$1"-nosplit" \
6165 .        nr doc-in-authors-section 0
6166 .      el \{ .ie "\$1"-split" \
6167 .        nr doc-in-authors-section 1
6168 .      el \{\
6169 .        ds doc-macro-name An
6170 .        doc-parse-args \$@
6171 .    \}\}\}
6172 .    el \{\
6173 .      tm1 "Usage: .An {-nosplit | -split}
6174 .      tm1 "       .An author_name ... (#\n[.c])
6175 .  \}\}
6176 .
6177 .  if \n[doc-in-authors-section] \{\
6178 .    ie \n[doc-have-author] \
6179 .      br
6180 .    el \
6181 .      nr doc-have-author 1
6182 .  \}
6183 .
6184 .  if \n[doc-arg-limit] \{\
6185 .    nr doc-arg-ptr +1
6186 .    ie (\n[doc-arg-limit] >= \n[doc-arg-ptr]) \{\
6187 .      nr doc-curr-font \n[.f]
6188 .      nr doc-curr-size \n[.ps]
6189 .      doc-print-recursive
6190 .    \}
6191 .    el \{\
6192 .      tm Usage: .An author_name ... (#\n[.c])
6193 .      doc-reset-args
6194 .  \}\}
6195 ..
6196 .
6197 .
6198 .\" NS Rv user macro
6199 .\" NS   return values
6200 .\" NS
6201 .\" NS width register `Rv' set in doc-common
6202 .\" NS
6203 .\" NS local variables:
6204 .\" NS   doc-str-Rv-std-prefix
6205 .\" NS   doc-str-Rv-std-suffix
6206 .\" NS   doc-str-Rv-stds-prefix
6207 .\" NS   doc-str-Rv-stds-and
6208 .\" NS   doc-str-Rv-stds-suffix
6209 .\" NS   doc-str-Rv-std0
6210 .
6211 .ds doc-str-Rv-std-prefix "The
6212 .ds doc-str-Rv-std-suffix "function returns the value\~0 if successful;
6213 .as doc-str-Rv-std-suffix " otherwise the value\~\-1 is returned and
6214 .as doc-str-Rv-std-suffix " the global variable \*[doc-Va-font]errno\f[]
6215 .as doc-str-Rv-std-suffix " is set to indicate the error.
6216 .
6217 .ds doc-str-Rv-stds-prefix "The
6218 .ds doc-str-Rv-stds-and    "and
6219 .ds doc-str-Rv-stds-suffix "functions return the value\~0 if successful;
6220 .as doc-str-Rv-stds-suffix " otherwise the value\~\-1 is returned and
6221 .as doc-str-Rv-stds-suffix " the global variable \*[doc-Va-font]errno\f[]
6222 .as doc-str-Rv-stds-suffix " is set to indicate the error.
6223 .
6224 .ds doc-str-Rv-std0 "Upon successful completion, the value\~0 is returned;
6225 .as doc-str-Rv-std0 " otherwise the value\~\-1 is returned and
6226 .as doc-str-Rv-std0 " the global variable \*[doc-Va-font]errno\f[]
6227 .as doc-str-Rv-std0 " is set to indicate the error.
6228 .
6229 .de Rv
6230 .
6231 .\" XXX: what does this function without `-std'?
6232 .
6233 .  if \n[doc-arg-limit] \{\
6234 .    tm Usage: .Rv not callable by other macros (#\n[.c])
6235 .    doc-reset-args
6236 .    return
6237 .  \}
6238 .
6239 .  if !\n[.$] \{\
6240 .    tm Usage: .Rv [-std] [<function> ...] (#\n[.c])
6241 .    return
6242 .  \}
6243 .
6244 .  if "\$1"-std" \{\
6245 .    nr doc-reg-Rv \*[doc-section]
6246 .    if ((\n[doc-reg-Rv] < 2) : (\n[doc-reg-Rv] > 3)) \
6247 .      tm Usage: .Rv -std in sections 2 and 3 only (#\n[.c])
6248 .    br
6249 .    shift
6250 .    ie (\n[.$] > 1) \{\
6251 .      nop \)\*[doc-str-Rv-stds-prefix]
6252 .      nr doc-reg-Rv 1
6253 .      while (\n[doc-reg-Rv] < \n[.$]) \{\
6254 .        ie (\n[.$] > 2) \
6255 .          Fn \$\n[doc-reg-Rv] ,
6256 .        el \
6257 .          Fn \$\n[doc-reg-Rv]
6258 .        nr doc-reg-Rv +1
6259 .      \}
6260 .      nop \)\*[doc-str-Rv-stds-and]
6261 .      Fn \$\n[.$]
6262 .      nop \)\*[doc-str-Rv-stds-suffix]
6263 .    \}
6264 .    el \{ .ie (\n[.$] == 1) \{\
6265 .      nop \)\*[doc-str-Rv-std-prefix]
6266 .      Fn \$1
6267 .      nop \)\*[doc-str-Rv-std-suffix]
6268 .    \}
6269 .    el \{\
6270 .      nop \)\*[doc-str-Rv-std0]
6271 .  \}\}\}
6272 ..
6273 .
6274 .
6275 .\" NS Ex user macro
6276 .\" NS   exit status
6277 .\" NS
6278 .\" NS width register `Ex' set in doc-common
6279 .\" NS
6280 .\" NS local variables:
6281 .\" NS   doc-str-Ex-std-prefix
6282 .\" NS   doc-str-Ex-std-suffix
6283 .
6284 .ds doc-str-Ex-std-prefix "The
6285 .ds doc-str-Ex-std-suffix "utility exits\~0 on success,
6286 .as doc-str-Ex-std-suffix " and\~>0 if an error occurs.
6287 .
6288 .ds doc-str-Ex-stds-prefix "The
6289 .als doc-str-Ex-stds-and doc-str-Rv-stds-and
6290 .ds doc-str-Ex-stds-suffix "utilities exit\~0 on success,
6291 .as doc-str-Ex-stds-suffix " and\~>0 if an error occurs.
6292 .
6293 .de Ex
6294 .
6295 .\" XXX: what does this function without `-std'?
6296 .
6297 .  if \n[doc-arg-limit] \{\
6298 .    tm Usage: .Ex not callable by other macros (#\n[.c])
6299 .    doc-reset-args
6300 .    return
6301 .  \}
6302 .
6303 .  if !\n[.$] \{\
6304 .    tm Usage: .Ex [-std] [<utility> ...] (#\n[.c])
6305 .    return
6306 .  \}
6307 .
6308 .  if "\$1"-std" \{\
6309 .    nr doc-reg-Ex \*[doc-section]
6310 .    if !((\n[doc-reg-Ex] == 1) : (\n[doc-reg-Ex] == 6) : (\n[doc-reg-Ex] == 8)) \
6311 .      tm Usage: .Ex -std in sections 1, 6 and 8 only (#\n[.c])
6312 .    br
6313 .    shift
6314 .    ie (\n[.$] > 1) \{\
6315 .      nop \)\*[doc-str-Ex-stds-prefix]
6316 .      nr doc-reg-Ex 1
6317 .      while (\n[doc-reg-Ex] < \n[.$]) \{\
6318 .        ie (\n[.$] > 2) \
6319 .          Nm \$\n[doc-reg-Ex] ,
6320 .        el \
6321 .          Nm \$\n[doc-reg-Ex]
6322 .        nr doc-reg-Ex +1
6323 .      \}
6324 .      nop \)\*[doc-str-Ex-stds-and]
6325 .      Nm \$\n[.$]
6326 .      nop \)\*[doc-str-Ex-stds-suffix]
6327 .    \}
6328 .    el \{\
6329 .      nop \)\*[doc-str-Ex-std-prefix]
6330 .      Nm \$1
6331 .      nop \)\*[doc-str-Ex-std-suffix]
6332 .  \}\}
6333 ..
6334 .
6335 .
6336 .\" NS Mt user macro
6337 .\" NS   mailto (for conversion to HTML)
6338 .
6339 .de Mt
6340 .  \" XXX: error handling missing
6341 .  Pa \$@
6342 ..
6343 .
6344 .
6345 .\" NS Lk user macro
6346 .\" NS   link (for conversion to HTML)
6347 .\" NS
6348 .\" NS local variables:
6349 .\" NS   doc-reg-Lk
6350 .\" NS   doc-str-Lk
6351 .
6352 .de Lk
6353 .  ds doc-str-Lk Sy \$@
6354 .
6355 .  ie (\n[.$] > 1) \{\
6356 .    doc-get-arg-type \$2
6357 .    ie (\n[doc-arg-type] < 3) \{\
6358 .      Em \)\$2:
6359 .      ds doc-str-Lk Sy "\$1"
6360 .      doc-get-width "\$1"
6361 .      shift 2
6362 .      if \n[.$] \
6363 .        as doc-str-Lk " \$@
6364 .    \}
6365 .    el \
6366 .      doc-get-width "\$1"
6367 .  \}
6368 .  el \
6369 .    doc-get-width "\$1"
6370 .
6371 .  ie n \
6372 .    nr doc-reg-Lk 26
6373 .  el \
6374 .    nr doc-reg-Lk 38
6375 .  ie (\n[doc-width] >= \n[doc-reg-Lk]) \
6376 .    D1 \*[doc-str-Lk]
6377 .  el \
6378 .    \*[doc-str-Lk]
6379 ..
6380 .
6381 .
6382 .\" NS doc-defunct-macro macro
6383 .\" NS   this is the skeleton for defunct macros
6384 .\" NS
6385 .
6386 .de doc-defunct-macro
6387 .  tmc mdoc error: .\$0 defunct
6388 .  if d doc-\$0-usage \
6389 .    tmc , \*[doc-\$0-usage]
6390 .  tm1 " (#\n[.c])
6391 ..
6392 .
6393 .
6394 .\" obsolete macros
6395 .
6396 .als Db doc-defunct-macro
6397 .
6398 .als Ds doc-defunct-macro
6399 .
6400 .als Or doc-defunct-macro
6401 .ds doc-Or-usage use `|'
6402 .
6403 .als Sf doc-defunct-macro
6404 .ds doc-Sf-usage use .Pf or .Ns
6405 .
6406 .
6407 .rn em e@
6408 .
6409 .de em
6410 .  tm1 "mdoc error: end-macro (.em) respecification is not allowed. (#\n[.c])
6411 .  tm1 "            Should this have been `.Em ...'?
6412 .  ab
6413 ..
6414 .
6415 .
6416 .\" NS doc-empty-line macro
6417 .\" NS   emit warning and print empty line
6418 .
6419 .de doc-empty-line
6420 .  if !\n[doc-display-depth] \
6421 .    tm mdoc warning: Empty input line #\n[.c]
6422 .  sp
6423 ..
6424 .
6425 .blm doc-empty-line
6426 .
6427 .
6428 .ec
6429 .
6430 .
6431 .\" load local modifications
6432 .mso mdoc.local
6433 .
6434 .\" EOF