Merge branch 'topic/sync-to-go-2'
[s-roff.git] / man / tmac-mdoc.7.in
blob01281ef52bde758cb32da28ea617f0d64be6b786
1 '\" t -- preprocess: tbl(1)
2 .\"@ @L_ROFF@_mdoc.7
3 .\"
4 .\"   A complete reference of the mdoc macro package for GNU troff.
5 .\"
6 .\" Based on NetBSD's mdoc.samples.7, version 1.21.
7 .\"
8 .\"   Warning: You can't format this file with the old mdoc macros!
9 .\"
10 .\" Copyright (c) 1990, 1993
11 .\"     The Regents of the University of California.  All rights reserved.
12 .\"
13 .\" Redistribution and use in source and binary forms, with or without
14 .\" modification, are permitted provided that the following conditions
15 .\" are met:
16 .\" 1. Redistributions of source code must retain the above copyright
17 .\"    notice, this list of conditions and the following disclaimer.
18 .\" 2. Redistributions in binary form must reproduce the above copyright
19 .\"    notice, this list of conditions and the following disclaimer in the
20 .\"    documentation and/or other materials provided with the distribution.
21 .\" 3. [Deleted.  See
22 .\"     ftp://ftp.cs.berkeley.edu/pub/4bsd/README.Impt.License.Change]
23 .\" 4. Neither the name of the University nor the names of its contributors
24 .\"    may be used to endorse or promote products derived from this software
25 .\"    without specific prior written permission.
26 .\"
27 .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
28 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
29 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
30 .\" ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
31 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
32 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
33 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
34 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
35 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
36 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
37 .\" SUCH DAMAGE.
38 .\"
39 .\"     @(#)mdoc.samples.7 8.2 (Berkeley) 12/30/93
40 .\"
41 .\" This reference invokes every macro in the package several
42 .\" times and is guaranteed to give a worst case performance
43 .\" for an already extremely slow package.
44 .\"
46 .Dd October 6, 2014
47 .Os
48 .Dt @U_ROFF@_MDOC 7
51 .Sh NAME
53 .Nm @L_ROFF@_mdoc
54 .Nd reference for @L_ROFF@'s mdoc implementation
57 .Sh SYNOPSIS
59 .Nm @L_ROFF@ Fl m Ns Cm doc Ar
62 .Sh DESCRIPTION
64 A complete reference for writing
65 .Ux
66 manual pages with the
67 .Nm \-mdoc
68 macro package; a
69 .Em content Ns -based
70 and
71 .Em domain Ns -based
72 formatting package.
73 Its predecessor, the
74 .Xr \-man 7
75 package, addressed page layout leaving the manipulation of fonts and other
76 typesetting details to the individual author.
78 .Nm \-mdoc ,
79 page layout macros make up the
80 .Em "page structure domain"
81 which consists of macros for titles, section headers, displays and lists
82 \(en essentially items which affect the physical position of text on a
83 formatted page.
84 In addition to the page structure domain, there are two more domains, the
85 .Em manual
86 domain and the
87 .Em general
88 text domain.
89 The general text domain is defined as macros which perform tasks such as
90 quoting or emphasizing pieces of text.
91 The manual domain is defined as macros that are a subset of the day to day
92 informal language used to describe commands, routines and related
93 .Ux
94 files.
95 Macros in the manual domain handle command names, command line arguments and
96 options, function names, function parameters, pathnames, variables, cross
97 references to other manual pages, and so on.
98 These domain items have value for both the author and the future user of the
99 manual page.
100 Hopefully, the consistency gained across the manual set will provide easier
101 translation to future documentation tools.
103 Throughout the
105 manual pages, a manual entry is simply referred to as a man page, regardless
106 of actual length and without sexist intention.
109 .Mx -toc -tree html xhtml pdf ps tty
111 .\" XXX
112 .if t \
113 .  ne 7
116 .Sh "TROFF IDIOSYNCRASIES"
119 .Nm \-mdoc
120 package attempts to simplify the process of writing a man page.
121 Theoretically, one should not have to learn the tricky details of
122 .Xr @L_TROFF@ 1
123 to use
124 .Nm \-mdoc ;
125 however, there are a few limitations which are unavoidable and best gotten
126 out of the way.
127 And, too, be forewarned, this package is
128 .Em not
129 fast.
131 .Ss "Macro Usage"
133 As in
134 .Xr @L_TROFF@ 1 ,
135 a macro is called by placing a
136 .Ql .\&
137 (dot character) at the beginning of a line followed by the two-character
138 (or three-character) name for the macro.
139 There can be space or tab characters between the dot and the macro name.
140 Arguments may follow the macro separated by spaces (but
141 .Em no
142 tabs).
143 It is the dot character at the beginning of the line which causes
144 .Xr @L_TROFF@ 1
145 to interpret the next two (or more) characters as a macro name.
146 A single starting dot followed by nothing is ignored.
147 To place a
148 .Ql .\&
149 (dot character) at the beginning of an input line in some context other than
150 a macro invocation, precede the
151 .Ql .\&
152 (dot) with the
153 .Ql \e&
154 escape sequence which translates literally to a zero-width space, and is
155 never displayed in the output.
157 In general,
158 .Xr @L_TROFF@ 1
159 macros accept an unlimited number of arguments (contrary to other versions
160 of troff which can't handle more than nine arguments).
161 In limited cases, arguments may be continued or extended on the next
162 line (See
163 .Sx Extended Arguments
164 below).
165 Almost all macros handle quoted arguments (see
166 .Sx Passing Space Characters in an Argument
167 below).
169 Most of the
170 .Nm \-mdoc
171 general text domain and manual domain macros are special in that their
172 argument lists are
173 .Em parsed
174 for callable macro names.
175 This means an argument on the argument list which matches a general text or
176 manual domain macro name (and which is defined to be callable) will be
177 executed or called when it is processed.
178 In this case the argument, although the name of a macro, is not preceded by
180 .Ql .\&
181 (dot).
182 This makes it possible to nest macros; for example the option macro,
183 .Ql .Op ,
185 .Em call
186 the flag and argument macros,
187 .Ql \&Fl
189 .Ql \&Ar ,
190 to specify an optional flag with an argument:
192 .Bl -tag -width ".Op Fl s Ar bytes" -offset indent
193 .It Op Fl s Ar bytes
194 is produced by
195 .Ql ".Op Fl s Ar bytes"
199 To prevent a string from being interpreted as a macro name, precede the
200 string with the escape sequence
201 .Ql \e& :
203 .Bl -tag -width ".Op \&Fl s \&Ar bytes" -offset indent
204 .It Op \&Fl s \&Ar bytes
205 is produced by
206 .Ql ".Op \e&Fl s \e&Ar bytes"
210 Here the strings
211 .Ql \&Fl
213 .Ql \&Ar
214 are not interpreted as macros.
215 Macros whose argument lists are parsed for callable arguments are referred
216 to as
217 .Em parsed
218 and macros which may be called from an argument list are referred to as
219 .Em callable
220 throughout this document.
221 This is a technical
222 .Em faux pas
223 as almost all of the macros in
224 .Nm \-mdoc
225 are parsed, but as it was cumbersome to constantly refer to macros as
226 being callable and being able to call other macros, the term parsed
227 has been used.
230 In the following, we call an
231 .Nm \-mdoc
232 macro which starts a line (with a leading dot) a
233 .Em command
234 if this distinction is necessary.
236 .Ss "Passing Space Characters in an Argument"
238 Sometimes it is desirable to give as an argument a string containing one or
239 more blank space characters, say, to specify arguments to commands which
240 expect particular arrangement of items in the argument list.
241 Additionally, it makes
242 .Nm \-mdoc
243 working faster.
244 For example, the function command
245 .Ql .Fn
246 expects the first argument to be the name of a function and any remaining
247 arguments to be function parameters.
249 .Tn ANSI\~C
250 stipulates the declaration of function parameters in the parenthesized
251 parameter list, each parameter is guaranteed to be at minimum a two word
252 string.
253 For example,
254 .Fa int foo .
256 There are two possible ways to pass an argument which contains
257 an embedded space.
258 One way of passing a string containing blank spaces is to use the hard or
259 unpaddable space character
260 .Ql \e\  ,
261 that is, a blank space preceded by the escape character
262 .Ql \e .
263 This method may be used with any macro but has the side effect of
264 interfering with the adjustment of text over the length of a line.
265 .Xr @T_TROFF@ 1
266 sees the hard space as if it were any other printable character and cannot
267 split the string into blank or newline separated pieces as one would expect.
268 This method is useful for strings which are not expected to overlap a line
269 boundary.
270 An alternative is to use
271 .Ql \e\[ti] ,
272 a paddable (i.e.\& stretchable), unbreakable space (this is a
273 .Xr @L_TROFF@ 1
274 extension).
275 The second method is to enclose the string with double quotes.
277 For example:
279 .Bl -tag -width ".Fn fetch char\ *str" -offset indent
280 .It Fn fetch char\ *str
281 is created by
282 .Ql ".Fn fetch char\e *str"
283 .It Fn fetch "char *str"
284 can also be created by
285 .Ql ".Fn fetch \*[q]char *str\*[q]"
289 If the
290 .Ql \e
291 before the space in the first example
292 or double quotes in the second example
293 were omitted,
294 .Ql .Fn
295 would see three arguments, and the result would be:
297 .Dl Fn fetch char *str
299 .\" For an example of what happens when the parameter list overlaps a newline
300 .\" boundary, see the
301 .\" .Sx BUGS
302 .\" section.
304 .Ss "Trailing Blank Space Characters"
306 .Xr @T_TROFF@ 1
307 can be confused by blank space characters at the end of a line.
308 It is a wise preventive measure to globally remove all blank spaces
309 from
310 .Ao blank-space Ac Ns Ao end-of-line Ac
311 character sequences.
312 Should the need arise to use a blank character at the end of a line, it
313 may be forced with an unpaddable space and the
314 .Ql \e&
315 escape character.
316 For example,
317 .Ql string\e\ \e& .
319 .Ss "Escaping Special Characters"
321 Special characters like the newline character
322 .Ql \en
323 are handled by replacing the
324 .Ql \e
325 with
326 .Ql \ee
327 (e.g.\&
328 .Ql \een )
329 to preserve the backslash.
331 .Ss "Other Possible Pitfalls"
333 A warning is emitted when an empty input line is found outside of displays
334 (see below).
336 .Ql .sp
337 instead.
338 (Well, it is even better to use
339 .Nm \-mdoc
340 macros to avoid the usage of low-level commands.)
342 Leading spaces will cause a break and are output directly.
343 Avoid this behaviour if possible.
344 Similarly, do not use more than one space character between words in an
345 ordinary text line; contrary to other text formatters, they are
346 .Em not
347 replaced with a single space.
349 You can't pass
350 .Ql \*[q]
351 directly as an argument.
353 .Ql \e*[q]
355 .Ql \e*q )
356 instead.
358 By default,
359 .Xr @L_TROFF@ 1
360 inserts two space characters after a punctuation mark closing a sentence;
361 characters like
362 .Ql \&)
364 .Ql \&'
365 are treated transparently, not influencing the sentence-ending behaviour.
366 To change this, insert
367 .Ql \e&
368 before or after the dot:
370 .Bd -literal -offset indent
372 \&.Ql .
373 character.
374 \&.Pp
376 \&.Ql \e&.
377 character.
378 \&.Pp
379 \&.No test .
380 test
381 \&.Pp
382 \&.No test.
383 test
387 gives
389 .Bd -filled -offset indent
391 .Ql .
392 character
395 .Ql \&.
396 character.
398 .No test .
399 test
401 .No test.
402 test
406 As can be seen in the first and third line,
407 .Nm \-mdoc
408 handles punctuation characters specially in macro arguments.
409 This will be explained in section
410 .Sx General Syntax
411 below.
412 In the same way, you have to protect trailing full stops of abbreviations
413 with a trailing zero-width space:
414 .Ql e.g.\e& .
416 A comment in the source file of a man page can be either started with
417 .Ql .\e"
418 on a single line,
419 .Ql \e"
420 after some input, or
421 .Ql \e#
422 anywhere (the latter is a
423 .Xr @L_TROFF@ 1
424 extension); the rest of such a line is ignored.
427 .Sh "A MANUAL PAGE TEMPLATE"
429 The body of a man page is easily constructed from a basic template:
431 .Bd -literal -offset indent
432 \&.\e" The following commands are required for all man pages.
433 \&.Dd Month day, year
434 \&.Dt DOCUMENT_TITLE [section number] [architecture/volume]
435 \&.Os [OPERATING_SYSTEM] [version/release]
436 \&.Sh NAME
437 \&.Nm name
438 \&.Nd one line description of name
439 \&.\e" This next command is for sections 2 and 3 only.
440 \&.\e" .Sh LIBRARY
441 \&.Sh SYNOPSIS
442 \&.Sh DESCRIPTION
443 \&.\e" The following commands should be uncommented and
444 \&.\e" used where appropriate.
445 \&.\e" .Sh IMPLEMENTATION NOTES
446 \&.\e" This next command is for sections 2, 3, and 9 only
447 \&.\e"     (function return values).
448 \&.\e" .Sh RETURN VALUES
449 \&.\e" This next command is for sections 1, 6, 7, and 8 only.
450 \&.\e" .Sh ENVIRONMENT
451 \&.\e" .Sh FILES
452 \&.\e" This next command is for sections 1, 6, and 8 only
453 \&.\e"     (command return values to the shell).
454 \&.\e" .Sh EXIT STATUS
455 \&.\e" .Sh EXAMPLES
456 \&.\e" This next command is for sections 1, 4, 6, 7, 8, and 9 only
457 \&.\e"     (fprintf/stderr type diagnostics).
458 \&.\e" .Sh DIAGNOSTICS
459 \&.\e" .Sh COMPATIBILITY
460 \&.\e" This next command is for sections 2, 3, 4, and 9 only
461 \&.\e"     (settings of the errno variable).
462 \&.\e" .Sh ERRORS
463 \&.\e" .Sh SEE ALSO
464 \&.\e" .Sh STANDARDS
465 \&.\e" .Sh HISTORY
466 \&.\e" .Sh AUTHORS
467 \&.\e" .Sh CAVEATS
468 \&.\e" .Sh BUGS
472 The first items in the template are the commands
473 .Ql .Dd ,
474 .Ql .Dt ,
476 .Ql .Os ;
477 the document date, the operating system the man page or subject source is
478 developed or modified for, and the man page title (in
479 .Em upper case )
480 along with the section of the manual the page belongs in.
481 These commands identify the page and are discussed below in
482 .Sx TITLE MACROS .
484 The remaining items in the template are section headers
485 .Pf ( Li .Sh ) ;
486 of which
487 .Em NAME ,
488 .Em SYNOPSIS ,
490 .Em DESCRIPTION
491 are mandatory.
492 The headers are discussed in
493 .Sx "PAGE STRUCTURE DOMAIN" ,
494 after presentation of
495 .Sx "MANUAL DOMAIN" .
496 Several content macros are used to demonstrate page layout macros; reading
497 about content macros before page layout macros is recommended.
500 .Sh CONVENTIONS
502 In the description of all macros below, optional arguments are put into
503 brackets.
504 An ellipsis
505 .Pf ( Sq ... )
506 represents zero or more additional arguments.
507 Alternative values for a parameter are separated with
508 .Ql | .
509 If there are alternative values for a mandatory parameter, braces are used
510 (together with
511 .Ql | )
512 to enclose the value set.
513 Meta-variables are specified within angles.
515 Example:
517 .Bl -tag -width 6n -offset indent
518 .It Li .Xx Xo
519 .Aq foo
520 .Brq bar1 | bar2
521 .Op \-test1 Op \-test2 | \-test3
522 .No ...
527 Except stated explicitly, all macros are parsed and callable.
529 Note that a macro takes effect up to the next nested macro.
530 For example,
531 .Ql ".Ic foo Aq bar"
532 doesn't produce
533 .Sq Ic "foo <bar>"
535 .Sq Ic foo Aq bar .
536 Consequently, a warning message is emitted for most commands if the first
537 argument is a macro itself since it cancels the effect of the calling
538 command completely.
539 Another consequence is that quoting macros never insert literal quotes;
540 .Sq Ic "foo <bar>"
541 has been produced by
542 .Ql ".Ic \*[q]foo <bar>\*[q]" .
544 Most macros have a default width value which can be used to specify a label
545 width
546 .Pf ( Fl width )
547 or offset
548 .Pf ( Fl offset )
549 for the
550 .Ql .Bl
552 .Ql .Bd
553 macros.
554 It is recommended not to use this rather obscure feature to avoid
555 dependencies on local modifications of the
556 .Nm \-mdoc
557 package.
560 .Sh "TITLE MACROS"
562 The title macros are part of the page structure domain but are presented
563 first and separately for someone who wishes to start writing a man page
564 yesterday.
565 Three header macros designate the document title or manual page title, the
566 operating system, and the date of authorship.
567 These macros are called once at the very beginning of the document and are
568 used to construct headers and footers only.
570 .Bl -tag -width 6n
571 .It Li .Dt Xo
572 .Op Aq document title
573 .Op Aq section number
574 .Op Aq volume
576 The document title is the subject of the man page and must be in
577 .Tn CAPITALS
578 due to troff limitations.
579 If omitted,
580 .Sq Tn UNTITLED
581 is used.
582 The section number may be a number in the range
583 .No 1,\~ Ns ... Ns ,\~9
585 .Ql unass ,
586 .Ql draft ,
588 .Ql paper .
589 If it is specified, and no volume name is given, a default volume name is
590 used.
593 Under
594 .Tn \*[operating-system] ,
595 the following sections are defined:
598 l l l.
599 1       \*[volume-operating-system] \*[volume-ds-1]
600 2       \*[volume-operating-system] \*[volume-ds-2]
601 3       \*[volume-operating-system] \*[volume-ds-3]
602 4       \*[volume-operating-system] \*[volume-ds-4]
603 5       \*[volume-operating-system] \*[volume-ds-5]
604 6       \*[volume-operating-system] \*[volume-ds-6]
605 7       \*[volume-operating-system] \*[volume-ds-7]
606 8       \*[volume-operating-system] \*[volume-ds-8]
607 9       \*[volume-operating-system] \*[volume-ds-9]
611 A volume name may be arbitrary or one of the following:
615 l l.
616 USD     \*[volume-ds-USD]
617 PS1     \*[volume-ds-PS1]
618 AMD     \*[volume-ds-AMD]
619 SMM     \*[volume-ds-SMM]
620 URM     \*[volume-ds-URM]
621 PRM     \*[volume-ds-PRM]
622 KM      \*[volume-ds-KM]
623 IND     \*[volume-ds-IND]
624 LOCAL   \*[volume-ds-LOCAL]
625 CON     \*[volume-ds-CON]
629 For compatibility,
630 .Ql MMI
631 can be used for
632 .Ql IND ,
634 .Ql LOC
636 .Ql LOCAL .
637 Values from the previous table will specify a new volume name.
638 If the third parameter is a keyword designating a computer architecture,
639 its value is prepended to the default volume name as specified by the
640 second parameter.
641 By default, the following architecture keywords are defined:
643 \# we use `No' to avoid hyphenation
644 .Bd -ragged -offset indent
645 .No acorn26 , acorn32 , algor , alpha , amd64 , amiga , amigappc ,
646 .No arc , arm , arm26 , arm32 , armish , atari , aviion ,
647 .No beagle , bebox , cats , cesfic , cobalt , dreamcast ,
648 .No emips , evbarm , evbmips , evbppc , evbsh3 , ews4800mips ,
649 .No hp300 , hp700 , hpcarm , hpcmips , hpcsh , hppa , hppa64 ,
650 .No i386 , ia64 , ibmnws , iyonix , landisk , loongson , luna68k , luna88k ,
651 .No m68k , mac68k , macppc , mips , mips64 , mipsco , mmeye ,
652 .No mvme68k , mvme88k , mvmeppc , netwinder , news68k , newsmips , next68k ,
653 .No ofppc , palm , pc532 , playstation2 , pmax , pmppc , powerpc , prep ,
654 .No rs6000 , sandpoint , sbmips , sgi , sgimips , sh3 , shark ,
655 .No socppc , solbourne , sparc , sparc64 , sun2 , sun3 ,
656 .No tahoe , vax , x68k , x86_64 , xen , zaurus
660 If the section number is neither a numeric expression in the range 1 to\~9
661 nor one of the above described keywords, the third parameter is used
662 verbatim as the volume name.
664 In the following examples, the left (which is identical to the right) and
665 the middle part of the manual page header strings are shown.
666 Note how
667 .Ql \e&
668 prevents the digit\~7 from being a valid numeric expression.
670 .Bd -ragged
671 .Bl -tag -width ".Li .Dt\ FOO\ 2\ i386" -compact -offset indent
672 .It Li ".Dt FOO 7"
673 .Ql FOO(7)
674 .Ql \*[volume-operating-system] \*[volume-ds-7]
675 .It Li ".Dt FOO 7 bar"
676 .Ql FOO(7)
677 .Ql \*[volume-operating-system] \*[volume-ds-7]
678 .It Li ".Dt FOO \e&7 bar"
679 .Ql FOO(7)
680 .Ql bar
681 .It Li ".Dt FOO 2 i386"
682 .Ql FOO(2)
683 .Ql \*[volume-operating-system]/\*[volume-as-i386] \*[volume-ds-2]
684 .It Li ".Dt FOO \*[q]\*[q] bar"
685 .Ql FOO
686 .Ql bar
691 Local, OS-specific additions might be found in the file
692 .Pa mdoc.local ;
693 look for strings named
694 .Ql volume\-ds\-XXX
695 (for the former type) and
696 .Ql volume\-as\-XXX
697 (for the latter type);
698 .Ql XXX
699 then denotes the keyword to be used with the
700 .Ql .Dt
701 macro.
703 This macro is neither callable nor parsed.
705 .It Li .Os Xo
706 .Op Aq operating system
707 .Op Aq release
709 If the first parameter is empty,
710 the default
711 .Sq Tn "\*[operating-system]"
712 is used.
713 This may be overridden in the local configuration file,
714 .Pa mdoc.local .
715 In general, the name of the operating system should be the common acronym,
716 e.g.\&
717 .Tn BSD
719 .Tn ATT .
720 The release should be the standard release nomenclature for the system
721 specified.
722 In the following table, the possible second arguments for some predefined
723 operating systems are listed.
724 Similar to
725 .Ql .Dt ,
726 local additions might be defined in
727 .Pa mdoc.local ;
728 look for strings named
729 .Ql operating\-system\-XXX\-YYY ,
730 where
731 .Ql XXX
732 is the acronym for the operating system and
733 .Ql YYY
734 the release ID.
736 .Bd -ragged -compact
737 .Bl -tag -width ".No DragonFly" -offset indent
738 .It ATT
739 7th, 7, III, 3, V, V.2, V.3, V.4
740 .It BSD
741 3, 4, 4.1, 4.2, 4.3, 4.3t, 4.3T, 4.3r, 4.3R, 4.4
742 .It NetBSD
743 0.8, 0.8a, 0.9, 0.9a, 1.0, 1.0a, 1.1, 1.2, 1.2a, 1.2b, 1.2c, 1.2d, 1.2e,
744 1.3, 1.3a, 1.4, 1.4.1, 1.4.2, 1.4.3, 1.5, 1.5.1, 1.5.2, 1.5.3, 1.6, 1.6.1,
745 1.6.2, 1.6.3, 2.0, 2.0.1, 2.0.2, 2.0.3, 2.1, 3.0, 3.0.1, 3.0.2, 3.0.3,
746 3.1, 3.1.1, 4.0, 4.0.1, 5.0, 5.0.1, 5.0.2, 5.1, 5.1.2, 5.1.3, 5.1.4,
747 5.2, 5.2.1, 5.2.2, 6.0, 6.0.1, 6.0.2, 6.0.3, 6.0.4, 6.0.5, 6.1, 6.1.1,
748 6.1.2, 6.1.3, 6.1.4
749 .It FreeBSD
750 1.0, 1.1, 1.1.5, 1.1.5.1, 2.0, 2.0.5, 2.1, 2.1.5, 2.1.6, 2.1.7, 2.2, 2.2.1,
751 2.2.2, 2.2.5, 2.2.6, 2.2.7, 2.2.8, 3.0, 3.1, 3.2, 3.3, 3.4, 3.5, 4.0, 4.1,
752 4.1.1, 4.2, 4.3, 4.4, 4.5, 4.6, 4.6.2, 4.7, 4.8, 4.9, 4.10, 4.11, 5.0, 5.1,
753 5.2, 5.2.1, 5.3, 5.4, 5.5, 6.0, 6.1, 6.2, 6.3, 6.4, 7.0, 7.1, 7.2, 7.3, 7.4,
754 8.0, 8.1, 8.2, 8.3, 8.4, 9.0, 9.1, 9.2, 9.3, 10.0
755 .It OpenBSD
756 2.0, 2.1, 2.2, 2.3, 2.4, 2.5, 2.6, 2.7, 2.8, 2.9, 3.0, 3.1, 3.2, 3.3, 3.4,
757 3.5, 3.6, 3.7, 3.8, 3.9, 4.0, 4.1, 4.2, 4.3, 4.4, 4.5, 4.6, 4.7, 4.8, 4.9,
758 5.0, 5.1, 5.2, 5.3, 5.4, 5.5, 5.6
759 .It DragonFly
760 1.0, 1.1, 1.2, 1.3, 1.4, 1.5, 1.6, 1.8, 1.8.1, 1.9, 1.10, 1.12, 1.12.2,
761 1.13, 2.0, 2.2, 2.3, 2.4, 2.5, 2.6, 2.7, 2.8, 2.9, 2.9.1, 2.10, 2.10.1,
762 2.11, 2.12, 2.13, 3.0, 3.1, 3.2, 3.3, 3.4, 3.5, 3.6, 3.7, 3.8
763 .It Darwin
764 8.0.0, 8.1.0, 8.2.0, 8.3.0, 8.4.0, 8.5.0, 8.6.0, 8.7.0, 8.8.0, 8.9.0,
765 8.10.0, 8.11.0, 9.0.0, 9.1.0, 9.2.0, 9.3.0, 9.4.0, 9.5.0, 9.6.0, 9.7.0,
766 9.8.0, 10.1.0, 10.2.0, 10.3.0, 10.4.0, 10.5.0, 10.6.0, 10.7.0, 10.8.0,
767 11.0.0, 11.1.0, 11.2.0, 11.3.0, 11.4.0, 11.5.0, 12.0.0, 12.1.0, 12.2.0,
768 13.0.0, 13.1.0, 13.2.0, 13.3.0, 13.4.0, 14.0.0
774 .Tn ATT ,
775 an unknown second parameter will be replaced with the string
776 .Tn UNIX ;
777 for the other predefined acronyms it will be ignored and a warning message
778 emitted.
779 Unrecognized arguments are displayed as given in the page footer.
780 For instance, a typical footer might be:
782 .Dl .Os BSD 4.3
784 giving
785 .Ql 4.3\~Berkeley Distribution ,
786 or for a locally produced set
788 .Dl .Os CS Department
790 which will produce
791 .Ql CS\~Department .
793 If the
794 .Ql .Os
795 macro is not present, the bottom left corner of the manual page will be
796 ugly.
798 This macro is neither callable nor parsed.
800 .It Li .Dd Oo
801 .Aq month
802 .Aq day ,
803 .Aq year
806 .Ql Dd
807 has no arguments,
808 .Ql Epoch
809 is used for the date string.
810 If it has exactly three arguments, they are concatenated, separated with
811 unbreakable space:
813 .Dl .Dd January 25, 2001
815 The month's name shall not be abbreviated.
817 With any other number of arguments, the current date is used, ignoring
818 the parameters.
820 As a special exception, the format
821 .Bd -filled -offset indent
822 .Li .Dd $Mdocdate:
823 .Aq month
824 .Aq day
825 .Aq year
826 .Li $
829 is also recognized.
830 It is used in
832 manuals to automatically insert the current date when committing.
834 This macro is neither callable nor parsed.
838 .Sh "INTRODUCTION OF MANUAL AND GENERAL TEXT DOMAINS"
840 .Ss "What's in a Name" Ns ...
842 The manual domain macro names are derived from the day to day informal
843 language used to describe commands, subroutines and related files.
844 Slightly different variations of this language are used to describe the
845 three different aspects of writing a man page.
846 First, there is the description of
847 .Nm \-mdoc
848 macro command usage.
849 Second is the description of a
851 command
852 .Em with
853 .Nm \-mdoc
854 macros, and third, the description of a command to a user in the verbal
855 sense; that is, discussion of a command in the text of a man page.
857 In the first case,
858 .Xr @L_TROFF@ 1
859 macros are themselves a type of command; the general syntax for a troff
860 command is:
862 .Bd -filled -offset indent
863 .Li ".Xx argument1 argument2" ...
867 .Ql .Xx
868 is a macro command, and anything following it are arguments to
869 be processed.
870 In the second case, the description of a
872 command using the content macros is a bit more involved; a typical
873 .Sx SYNOPSIS
874 command line might be displayed as:
876 .Bd -filled -offset indent
877 .Nm filter
878 .Op Fl flag
879 .Ao Ar infile Ac Ao Ar outfile Ac
883 Here,
884 .Nm filter
885 is the command name and the
886 bracketed string
887 .Fl flag
888 is a
889 .Em flag
890 argument designated as optional by the option brackets.
892 .Nm \-mdoc
893 terms,
894 .Ao Ar infile Ac
896 .Ao Ar outfile Ac
897 are called
898 .Em meta arguments ;
899 in this example, the user has to replace the meta expressions given in angle
900 brackets with real file names.
901 Note that in this document meta arguments are used to describe
902 .Nm \-mdoc
903 commands; in most man pages, meta variables are not specifically written
904 with angle brackets.
905 The macros which formatted the above example:
907 .Bd -literal -offset indent
908 \&.Nm filter
909 \&.Op Fl flag
910 \&.Ao Ar infile Ac Ao Ar outfile Ac
914 In the third case, discussion of commands and command syntax includes both
915 examples above, but may add more detail.
916 The arguments
917 .Ao Ar infile Ac
919 .Ao Ar outfile Ac
920 from the example above might be referred to as
921 .Em operands
923 .Em file arguments .
924 Some command line argument lists are quite long:
926 .Bd -ragged
927 .Bl -tag -width ".Nm make" -offset indent -compact
928 .It Nm make
929 .Op Fl eiknqrstv
930 .Op Fl D Ar variable
931 .Op Fl d Ar flags
932 .Op Fl f Ar makefile
933 .Op Fl I Ar directory
934 .Op Fl j Ar max_jobs
935 .Op Ar variable Ns = Ns Ar value
937 .Op Ar target ...
943 Here one might talk about the command
944 .Nm make
945 and qualify the argument,
946 .Ar makefile ,
947 as an argument to the flag,
948 .Fl f ,
949 or discuss the optional file operand
950 .Ar target .
951 In the verbal context, such detail can prevent confusion, however the
952 .Nm \-mdoc
953 package does not have a macro for an argument
954 .Em to
955 a flag.
956 Instead the
957 .Ql \&Ar
958 argument macro is used for an operand or file argument like
959 .Ar target
960 as well as an argument to a flag like
961 .Ar variable .
962 The make command line was produced from:
964 .Bd -literal -offset indent
965 \&.Nm make
966 \&.Op Fl eiknqrstv
967 \&.Op Fl D Ar variable
968 \&.Op Fl d Ar flags
969 \&.Op Fl f Ar makefile
970 \&.Op Fl I Ar directory
971 \&.Op Fl j Ar max_jobs
972 \&.Op Ar variable Ns = Ns Ar value
973 \&.Bk
974 \&.Op Ar target ...
975 \&.Ek
980 .Ql .Bk
982 .Ql .Ek
983 macros are explained in
984 .Sx Keeps .
986 .Ss "General Syntax"
988 The manual domain and general text domain macros share a similar syntax with
989 a few minor deviations; most notably,
990 .Ql .Ar ,
991 .Ql .Fl ,
992 .Ql .Nm ,
994 .Ql .Pa
995 differ only when called without arguments; and
996 .Ql .Fn
998 .Ql .Xr
999 impose an order on their argument lists.
1000 All content macros are capable of recognizing and properly handling
1001 punctuation, provided each punctuation character is separated by a leading
1002 space.
1003 If a command is given:
1005 .Dl \&.Ar sptr, ptr),
1007 The result is:
1009 .Dl Ar sptr, ptr),
1011 The punctuation is not recognized and all is output in the
1012 font used by
1013 .Ql .Ar .
1014 If the punctuation is separated by a leading white space:
1016 .Dl \&.Ar "sptr , ptr ) ,"
1018 The result is:
1020 .Dl Ar sptr , ptr ) ,
1022 The punctuation is now recognized and output in the default font
1023 distinguishing it from the argument strings.
1024 To remove the special meaning from a punctuation character escape it with
1025 .Ql \e& .
1027 The following punctuation characters are recognized by
1028 .Nm \-mdoc :
1030 .Bl -column -offset indent-two XXXXXX XXXXXX XXXXXX XXXXXX
1031 .It Li .\& Ta Li ,\& Ta Li :\& Ta Li ;\& Ta Li (\&
1032 .It Li )\& Ta Li [\& Ta Li ]\& Ta Li ?\& Ta Li !\&
1036 .Xr @T_TROFF 1
1037 is limited as a macro language, and has difficulty when presented with a
1038 string containing a member of the mathematical, logical or quotation set:
1040 .Bd -literal -offset indent-two
1041 {+,\-,/,*,%,<,>,<=,>=,=,==,&,`,',"}
1045 The problem is that
1046 .Xr @L_TROFF@ 1
1047 may assume it is supposed to actually perform the operation or evaluation
1048 suggested by the characters.
1049 To prevent the accidental evaluation of these characters, escape them with
1050 .Ql \e& .
1051 Typical syntax is shown in the first content macro displayed below,
1052 .Ql .Ad .
1055 .Sh "MANUAL DOMAIN"
1057 .Ss Addresses
1059 The address macro identifies an address construct.
1061 .Dl Usage: .Ad Ao address Ac ...
1063 .Bl -tag -width ".Li .Ad\ f1\ ,\ f2\ ,\ f3\ :" -compact -offset 15n
1064 .It Li ".Ad addr1"
1065 .Ad addr1
1066 .It Li ".Ad addr1 ."
1067 .Ad addr1 .
1068 .It Li ".Ad addr1 , file2"
1069 .Ad addr1 , file2
1070 .It Li ".Ad f1 , f2 , f3 :"
1071 .Ad f1 , f2 , f3 :
1072 .It Li ".Ad addr ) ) ,"
1073 .Ad addr ) ) ,
1077 The default width is 12n.
1079 .Ss "Author Name"
1082 .Ql .An
1083 macro is used to specify the name of the author of the item being
1084 documented, or the name of the author of the actual manual page.
1086 .Dl Usage: .An Ao author name Ac ...
1088 .Bl -tag -width ".Li .An\ \*[q]Joe\ Author\*[q]\ )\ )\ ," -offset 15n
1089 .It Li ".An \*[q]Joe Author\*[q]"
1090 .An "Joe Author"
1091 .It Li ".An \*[q]Joe Author\*[q] ,"
1092 .An "Joe Author" ,
1093 .It Li ".An \*[q]Joe Author\*[q] Aq nobody@FreeBSD.org"
1094 .An "Joe Author" Aq nobody@FreeBSD.org
1095 .It Li ".An \*[q]Joe Author\*[q] ) ) ,"
1096 .An "Joe Author" ) ) ,
1100 The default width is 12n.
1102 In the
1103 .Em AUTHORS
1104 section, the
1105 .Ql .An
1106 command causes a line break allowing each new name to appear on its own
1107 line.
1108 If this is not desirable,
1110 .Bd -literal -offset indent
1111 \&.An \-nosplit
1115 call will turn this off.
1116 To turn splitting back on, write
1118 .Bd -literal -offset indent
1119 \&.An \-split
1122 .Ss "Arguments"
1125 .Li .Ar
1126 argument macro may be used whenever an argument is referenced.
1127 If called without arguments, the
1128 .Sq Ar
1129 string is output.
1131 .Dl Usage: .Ar Oo Ao argument Ac Oc ...
1133 .Bl -tag -width ".Li .Ar\ file1\ file2" -compact -offset 15n
1134 .It Li .Ar
1136 .It Li ".Ar file1"
1137 .Ar file1
1138 .It Li ".Ar file1 ."
1139 .Ar file1 .
1140 .It Li ".Ar file1 file2"
1141 .Ar file1 file2
1142 .It Li ".Ar f1 f2 f3 :"
1143 .Ar f1 f2 f3 :
1144 .It Li ".Ar file ) ) ,"
1145 .Ar file ) ) ,
1149 The default width is 12n.
1151 .Ss "Configuration Declaration (Section Four Only)"
1154 .Ql .Cd
1155 macro is used to demonstrate a
1156 .Xr config 8
1157 declaration for a device interface in a section four manual.
1159 .Dl Usage: .Cd Ao argument Ac ...
1161 .Bl -tag -width ".Li .Cd\ Xdevice\ le0\ at\ scode?X" -offset 15n
1162 .It Li ".Cd \*[q]device le0 at scode?\*[q]"
1163 .Cd "device le0 at scode?"
1166 In the
1167 .Sx SYNOPSIS
1168 section a
1169 .Ql .Cd
1170 command causes a line break before and after its arguments are printed.
1173 The default width is 12n.
1175 .Ss "Command Modifiers"
1177 The command modifier is identical to the
1178 .Ql .Fl
1179 (flag) command with the exception that the
1180 .Ql .Cm
1181 macro does not assert a dash in front of every argument.
1182 Traditionally flags are marked by the preceding dash, however, some commands
1183 or subsets of commands do not use them.
1184 Command modifiers may also be specified in conjunction with interactive
1185 commands such as editor commands.
1187 .Sx Flags .
1189 The default width is 10n.
1191 .Ss "Defined Variables"
1193 A variable (or constant) which is defined in an include file
1194 is specified by the macro
1195 .Ql .Dv .
1197 .Dl Usage: .Dv Ao defined variable Ac ...
1199 .Bl -tag -width ".Li .Dv\ MAXHOSTNAMELEN" -compact -offset 15n
1200 .It Li ".Dv MAXHOSTNAMELEN"
1201 .Dv MAXHOSTNAMELEN
1202 .It Li ".Dv TIOCGPGRP )"
1203 .Dv TIOCGPGRP )
1206 The default width is 12n.
1208 .Ss Errno's
1211 .Ql .Er
1212 errno macro specifies the error return value for section 2, 3, and\~9 library
1213 routines.
1214 The second example below shows
1215 .Ql .Er
1216 used with the
1217 .Ql .Bq
1218 general text domain macro, as it would be used in a section two manual page.
1220 .Dl Usage: .Er Ao errno type Ac ...
1222 .Bl -tag -width ".Li .Bq\ Er\ ENOTDIR" -compact -offset 15n
1223 .It Li ".Er ENOENT"
1224 .Er ENOENT
1225 .It Li ".Er ENOENT ) ;"
1226 .Er ENOENT ) ;
1227 .It Li ".Bq Er ENOTDIR"
1228 .Bq Er ENOTDIR
1232 The default width is 17n.
1234 .Ss "Environment Variables"
1237 .Ql .Ev
1238 macro specifies an environment variable.
1240 .Dl Usage: .Ev Ao argument Ac ...
1242 .Bl -tag -width ".Li .Ev\ PRINTER\ )\ )\ ," -compact -offset 15n
1243 .It Li ".Ev DISPLAY"
1244 .Ev DISPLAY
1245 .It Li ".Ev PATH ."
1246 .Ev PATH .
1247 .It Li ".Ev PRINTER ) ) ,"
1248 .Ev PRINTER ) ) ,
1251 The default width is 15n.
1253 .Ss Flags
1256 .Ql .Fl
1257 macro handles command line flags.
1258 It prepends a dash,
1259 .Ql \- ,
1260 to the flag.
1261 For interactive command flags, which are not prepended with a dash, the
1262 .Ql .Cm
1263 (command modifier)
1264 macro is identical, but without the dash.
1266 .Dl Usage: .Fl Ao argument Ac ...
1268 .Bl -tag -width ".Li .Fl\ xyz\ )\ ," -compact -offset 15n
1269 .It Li .Fl
1271 .It Li ".Fl cfv"
1272 .Fl cfv
1273 .It Li ".Fl cfv ."
1274 .Fl cfv .
1275 .It Li ".Cm cfv ."
1276 .Cm cfv .
1277 .It Li ".Fl s v t"
1278 .Fl s v t
1279 .It Li ".Fl \- ,"
1280 .Fl \- ,
1281 .It Li ".Fl xyz ) ,"
1282 .Fl xyz ) ,
1283 .It Li ".Fl |"
1284 .Fl |
1288 .Ql .Fl
1289 macro without any arguments results in a dash representing stdin/stdout.
1290 Note that giving
1291 .Ql .Fl
1292 a single dash will result in two dashes.
1294 The default width is 12n.
1296 .Ss "Function Declarations"
1299 .Ql .Fd
1300 macro is used in the
1301 .Sx SYNOPSIS
1302 section with section two or three functions.
1303 It is neither callable nor parsed.
1305 .Dl Usage: .Fd Ao argument Ac ...
1307 .Bl -tag -width ".Li .Fd\ X#include\ <sys/types.h>X" -compact -offset 15n
1308 .It Li ".Fd \*[q]#include <sys/types.h>\*[q]"
1309 .Fd "#include <sys/types.h>"
1312 In the
1313 .Sx SYNOPSIS
1314 section a
1315 .Ql .Fd
1316 command causes a line break if a function has already been presented and a
1317 break has not occurred.
1318 This leaves a nice vertical space in between the previous function call and
1319 the declaration for the next function.
1323 .Ql .In
1324 macro, while in the
1325 .Sx SYNOPSIS
1326 section, represents the
1327 .Li #include
1328 statement, and is the short form of the above example.
1329 It specifies the C\~header file as being included in a C\~program.
1330 It also causes a line break.
1332 While not in the
1333 .Sx SYNOPSIS
1334 section, it represents the header file enclosed in angle brackets.
1336 .Dl Usage: .In Ao header file Ac
1338 .Bl -tag -width ".Li .In\ stdio.h" -compact -offset 15n
1339 .nr in-synopsis-section 1
1340 .It Li ".In stdio.h"
1341 .In stdio.h
1342 .nr in-synopsis-section 0
1343 .It Li ".In stdio.h"
1344 .In stdio.h
1347 .Ss "Function Types"
1349 This macro is intended for the
1350 .Sx SYNOPSIS
1351 section.
1352 It may be used anywhere else in the man page without problems, but its main
1353 purpose is to present the function type in kernel normal form for the
1354 .Sx SYNOPSIS
1355 of sections two and three (it causes a line break, allowing the function
1356 name to appear on the next line).
1358 .Dl Usage: .Ft Ao type Ac ...
1360 .Bl -tag -width ".Li .Ft\ struct\ stat" -compact -offset 15n
1361 .It Li ".Ft struct stat"
1362 .Ft struct stat
1365 .Ss "Functions (Library Routines)"
1368 .Ql .Fn
1369 macro is modeled on
1370 .Tn ANSI\~C
1371 conventions.
1373 .Dl Usage: .Fn Ao function Ac Oo Ao parameter Ac Oc ...
1375 .Bl -tag -width ".Li .Fn\ align\ Xchar\ *ptrX\ ," -compact -offset 15n
1376 .It Li ".Fn getchar"
1377 .Fn getchar
1378 .It Li ".Fn strlen ) ,"
1379 .Fn strlen ) ,
1380 .It Li ".Fn align \*[q]char *ptr\*[q] ,"
1381 .Fn align "char *ptr" ,
1384 Note that any call to another macro signals the end of the
1385 .Ql .Fn
1386 call (it will insert a closing parenthesis at that point).
1388 For functions with many parameters (which is rare), the macros
1389 .Ql .Fo
1390 (function open)
1392 .Ql .Fc
1393 (function close)
1394 may be used with
1395 .Ql .Fa
1396 (function argument).
1398 Example:
1400 .Bd -literal -offset indent
1401 \&.Ft int
1402 \&.Fo res_mkquery
1403 \&.Fa "int op"
1404 \&.Fa "char *dname"
1405 \&.Fa "int class"
1406 \&.Fa "int type"
1407 \&.Fa "char *data"
1408 \&.Fa "int datalen"
1409 \&.Fa "struct rrec *newrr"
1410 \&.Fa "char *buf"
1411 \&.Fa "int buflen"
1412 \&.Fc
1415 Produces:
1417 .Bd -ragged -offset indent
1418 .Ft int
1419 .Fo res_mkquery
1420 .Fa "int op"
1421 .Fa "char *dname"
1422 .Fa "int class"
1423 .Fa "int type"
1424 .Fa "char *data"
1425 .Fa "int datalen"
1426 .Fa "struct rrec *newrr"
1427 .Fa "char *buf"
1428 .Fa "int buflen"
1433 In the
1434 .Sx SYNOPSIS
1435 section, the function will always begin at the beginning of line.
1436 If there is more than one function presented in the
1437 .Sx SYNOPSIS
1438 section and a function type has not been given, a line break will occur,
1439 leaving a nice vertical space between the current function name and the one
1440 prior.
1442 The default width values of
1443 .Ql .Fn
1445 .Ql .Fo
1446 are 12n and 16n, respectively.
1448 .Ss "Function Arguments"
1451 .Ql .Fa
1452 macro is used to refer to function arguments (parameters) outside of the
1453 .Sx SYNOPSIS
1454 section of the manual or inside the
1455 .Sx SYNOPSIS
1456 section if the enclosure macros
1457 .Ql .Fo
1459 .Ql .Fc
1460 instead of
1461 .Ql .Fn
1462 are used.
1463 .Ql .Fa
1464 may also be used to refer to structure members.
1466 .Dl Usage: .Fa Ao function argument Ac ...
1468 .Bl -tag -width ".Li .Fa\ d_namlen\ )\ )\ ," -compact -offset 15n
1469 .It Li ".Fa d_namlen ) ) ,"
1470 .Fa d_namlen ) ) ,
1471 .It Li ".Fa iov_len"
1472 .Fa iov_len
1475 The default width is 12n.
1477 .Ss "Return Values"
1480 .Ql .Rv
1481 macro generates text for use in the
1482 .Sx RETURN VALUES
1483 section.
1485 .Dl Usage: .Rv Oo \-std Oc Op Ao function Ac ...
1487 For example,
1488 .Ql ".Rv \-std atexit"
1489 produces:
1491 .Bd -ragged -offset indent
1492 \# a small hack to suppress a warning message
1493 .ds section-old "\*[section]
1494 .ds section 3
1495 .Rv -std atexit
1496 .ds section "\*[section-old]
1500 .Fl std
1501 option is valid only for manual page sections\~2 and\~3.
1502 Currently, this macro does nothing if used without the
1503 .Fl std
1504 flag.
1506 .Ss "Exit Status"
1509 .Ql .Ex
1510 macro generates text for use in the
1511 .Sx DIAGNOSTICS
1512 section.
1514 .Dl Usage: .Ex Oo \-std Oc Op Ao utility Ac ...
1516 For example,
1517 .Ql ".Ex \-std cat"
1518 produces:
1520 .Bd -ragged -offset indent
1521 \# a small hack to suppress a warning message
1522 .ds section-old "\*[section]
1523 .ds section 1
1524 .Ex -std cat
1525 .ds section "\*[section-old]
1529 .Fl std
1530 option is valid only for manual page sections 1, 6 and\~8.
1531 Currently, this macro does nothing if used without the
1532 .Fl std
1533 flag.
1535 .Ss "Interactive Commands"
1538 .Ql .Ic
1539 macro designates an interactive or internal command.
1541 .Dl Usage: .Ic Ao argument Ac ...
1543 .Bl -tag -width ".Li .Ic\ setenv\ ,\ unsetenv" -compact -offset 15n
1544 .It Li ".Ic :wq"
1545 .Ic :wq
1546 .It Li ".Ic \*[q]do while {...}\*[q]"
1547 .Ic "do while {...}"
1548 .It Li ".Ic setenv , unsetenv"
1549 .Ic setenv , unsetenv
1552 The default width is 12n.
1554 .Ss "Library Names"
1557 .Ql .Lb
1558 macro is used to specify the library where a particular function is compiled
1561 .Dl Usage: .Lb Ao argument Ac ...
1563 Available arguments to
1564 .Ql .Lb
1565 and their results are:
1568 .Bl -tag -width ".Li librpcsec_gss" -compact -offset indent
1569 .It Li libarchive
1570 .Lb libarchive
1571 .It Li libarm
1572 .Lb libarm
1573 .It Li libarm32
1574 .Lb libarm32
1575 .It Li libbluetooth
1576 .Lb libbluetooth
1577 .It Li libbsm
1578 .Lb libbsm
1579 .It Li libc
1580 .Lb libc
1581 .It Li libc_r
1582 .Lb libc_r
1583 .It Li libcalendar
1584 .Lb libcalendar
1585 .It Li libcam
1586 .Lb libcam
1587 .It Li libcdk
1588 .Lb libcdk
1589 .It Li libcipher
1590 .Lb libcipher
1591 .It Li libcompat
1592 .Lb libcompat
1593 .It Li libcrypt
1594 .Lb libcrypt
1595 .It Li libcurses
1596 .Lb libcurses
1597 .It Li libdevinfo
1598 .Lb libdevinfo
1599 .It Li libdevstat
1600 .Lb libdevstat
1601 .It Li libdisk
1602 .Lb libdisk
1603 .It Li libdwarf
1604 .Lb libdwarf
1605 .It Li libedit
1606 .Lb libedit
1607 .It Li libelf
1608 .Lb libelf
1609 .It Li libevent
1610 .Lb libevent
1611 .It Li libfetch
1612 .Lb libfetch
1613 .It Li libform
1614 .Lb libform
1615 .It Li libgeom
1616 .Lb libgeom
1617 .It Li libgpib
1618 .Lb libgpib
1619 .It Li libi386
1620 .Lb libi386
1621 .It Li libintl
1622 .Lb libintl
1623 .It Li libipsec
1624 .Lb libipsec
1625 .It Li libipx
1626 .Lb libipx
1627 .It Li libiscsi
1628 .Lb libiscsi
1629 .It Li libjail
1630 .Lb libjail
1631 .It Li libkiconv
1632 .Lb libkiconv
1633 .It Li libkse
1634 .Lb libkse
1635 .It Li libkvm
1636 .Lb libkvm
1637 .It Li libm
1638 .Lb libm
1639 .It Li libm68k
1640 .Lb libm68k
1641 .It Li libmagic
1642 .Lb libmagic
1643 .It Li libmd
1644 .Lb libmd
1645 .It Li libmemstat
1646 .Lb libmemstat
1647 .It Li libmenu
1648 .Lb libmenu
1649 .It Li libnetgraph
1650 .Lb libnetgraph
1651 .It Li libnetpgp
1652 .Lb libnetpgp
1653 .It Li libossaudio
1654 .Lb libossaudio
1655 .It Li libpam
1656 .Lb libpam
1657 .It Li libpcap
1658 .Lb libpcap
1659 .It Li libpci
1660 .Lb libpci
1661 .It Li libpmc
1662 .Lb libpmc
1663 .It Li libposix
1664 .Lb libposix
1665 .It Li libprop
1666 .Lb libprop
1667 .It Li libpthread
1668 .Lb libpthread
1669 .It Li libpuffs
1670 .Lb libpuffs
1671 .It Li librefuse
1672 .Lb librefuse
1673 .It Li libresolv
1674 .Lb libresolv
1675 .It Li librpcsec_gss
1676 .Lb librpcsec_gss
1677 .It Li librpcsvc
1678 .Lb librpcsvc
1679 .It Li librt
1680 .Lb librt
1681 .It Li libsdp
1682 .Lb libsdp
1683 .It Li libssp
1684 .Lb libssp
1685 .It Li libSystem
1686 .Lb libSystem
1687 .It Li libtermcap
1688 .Lb libtermcap
1689 .It Li libterminfo
1690 .Lb libterminfo
1691 .It Li libthr
1692 .Lb libthr
1693 .It Li libufs
1694 .Lb libufs
1695 .It Li libugidfw
1696 .Lb libugidfw
1697 .It Li libulog
1698 .Lb libulog
1699 .It Li libusbhid
1700 .Lb libusbhid
1701 .It Li libutil
1702 .Lb libutil
1703 .It Li libvgl
1704 .Lb libvgl
1705 .It Li libx86_64
1706 .Lb libx86_64
1707 .It Li libz
1708 .Lb libz
1711 Local, OS-specific additions might be found in the file
1712 .Pa mdoc.local ;
1713 look for strings named
1714 .Ql str\-Lb\-XXX .
1715 .Ql XXX
1716 then denotes the keyword to be used with the
1717 .Ql .Lb
1718 macro.
1720 In the
1721 .Em LIBRARY
1722 section an
1723 .Ql .Lb
1724 command causes a line break before and after its arguments are printed.
1727 .Ss Literals
1730 .Ql .Li
1731 literal macro may be used for special characters, variable constants, etc.\&
1732 \- anything which should be displayed as it would be typed.
1734 .Dl Usage: .Li Ao argument Ac ...
1736 .Bl -tag -width ".Li .Li\ cntrl\-D\ )\ ,"  -compact -offset 15n
1737 .It Li ".Li \een"
1738 .Li \en
1739 .It Li ".Li M1 M2 M3 ;"
1740 .Li M1 M2 M3 ;
1741 .It Li ".Li cntrl\-D ) ,"
1742 .Li cntrl-D ) ,
1743 .It Li ".Li 1024 ..."
1744 .Li 1024 ...
1747 The default width is 16n.
1749 .Ss Names
1752 .Ql .Nm
1753 macro is used for the document title or subject name.
1754 It has the peculiarity of remembering the first argument it was called with,
1755 which should always be the subject name of the page.
1756 When called without arguments,
1757 .Ql .Nm
1758 regurgitates this initial name for the sole purpose of making less work for
1759 the author.
1760 .Ql .Nm
1761 causes a line break within the
1762 .Sx SYNOPSIS
1763 section.
1765 Note: A section two or three document function name is addressed with the
1766 .Ql .Nm
1767 in the
1768 .Em NAME
1769 section, and with
1770 .Ql .Fn
1771 in the
1772 .Sx SYNOPSIS
1773 and remaining sections.
1774 For interactive commands, such as the
1775 .Ql while
1776 command keyword in
1777 .Xr csh 1 ,
1779 .Ql .Ic
1780 macro should be used.
1781 While
1782 .Ql .Ic
1783 is nearly identical
1785 .Ql .Nm ,
1786 it can not recall the first argument it was invoked with.
1788 .Dl Usage: .Nm Oo Ao argument Ac Oc ...
1790 .Bl -tag -width ".Li .Nm\ groff_mdoc" -compact -offset 15n
1791 .It Li ".Nm groff_mdoc"
1792 .Nm groff_mdoc
1793 .It Li ".Nm \e\-mdoc"
1794 .Nm \-mdoc
1795 .It Li ".Nm foo ) ) ,"
1796 .Nm foo ) ) ,
1797 .It Li ".Nm :"
1798 .Nm :
1801 The default width is 10n.
1803 .Ss Options
1806 .Ql .Op
1807 macro places option brackets around any remaining arguments on the
1808 command line, and places any trailing punctuation outside the brackets.
1809 The macros
1810 .Ql .Oo
1812 .Ql .Oc
1813 (which produce an opening and a closing option bracket respectively) may be used
1814 across one or more lines or to specify the exact position of the closing
1815 parenthesis.
1817 .Dl Usage: .Op Oo Ao option Ac Oc ...
1819 .Bl -tag -width ".Li .Op\ Fl\ c\ Ar\ objfil\ Op\ Ar\ corfil\ ," -compact -offset 15n
1820 .It Li .Op
1822 .It Li ".Op Fl k"
1823 .Op Fl k
1824 .It Li ".Op Fl k ) ."
1825 .Op Fl k ) .
1826 .It Li ".Op Fl k Ar kookfile"
1827 .Op Fl k Ar kookfile
1828 .It Li ".Op Fl k Ar kookfile ,"
1829 .Op Fl k Ar kookfile ,
1830 .It Li ".Op Ar objfil Op Ar corfil"
1831 .Op Ar objfil Op Ar corfil
1832 .It Li ".Op Fl c Ar objfil Op Ar corfil ,"
1833 .Op Fl c Ar objfil Op Ar corfil ,
1834 .It Li ".Op word1 word2"
1835 .Op word1 word2
1836 .It Li ".Li .Op Oo Ao option Ac Oc ..."
1837 .Li .Op Oo Ao option Ac Oc ...
1840 Here a typical example of the
1841 .Ql .Oo
1843 .Ql .Oc
1844 macros:
1846 .Bd -literal -offset indent
1847 \&.Oo
1848 \&.Op Fl k Ar kilobytes
1849 \&.Op Fl i Ar interval
1850 \&.Op Fl c Ar count
1851 \&.Oc
1854 Produces:
1856 .Bd -filled -offset indent
1858 .Op Fl k Ar kilobytes
1859 .Op Fl i Ar interval
1860 .Op Fl c Ar count
1864 The default width values of
1865 .Ql .Op
1867 .Ql .Oo
1868 are 14n and 10n, respectively.
1870 .Ss Pathnames
1873 .Ql .Pa
1874 macro formats path or file names.
1875 If called without arguments, the
1876 .Sq Pa
1877 string is output, which represents the current user's home directory.
1879 .Dl Usage: .Pa Oo Ao pathname Ac Oc ...
1881 .Bl -tag -width ".Li .Pa\ /tmp/fooXXXXX\ )\ ." -compact -offset 15n
1882 .It Li .Pa
1884 .It Li ".Pa /usr/share"
1885 .Pa /usr/share
1886 .It Li ".Pa /tmp/fooXXXXX ) ."
1887 .Pa /tmp/fooXXXXX ) .
1890 The default width is 32n.
1892 .Ss Standards
1895 .Ql .St
1896 macro replaces standard abbreviations with their formal names.
1898 .Dl Usage: .St Ao abbreviation Ac ...
1900 Available pairs for
1901 .Dq Abbreviation/Formal Name
1902 are:
1905 .Tn ANSI/ISO C
1907 .Bl -tag -width ".Li \-p1003.1g\-2000" -compact -offset indent
1908 .It Li \-ansiC
1909 .St -ansiC
1910 .It Li \-ansiC\-89
1911 .St -ansiC-89
1912 .It Li \-isoC
1913 .St -isoC
1914 .It Li \-isoC\-90
1915 .St -isoC-90
1916 .It Li \-isoC\-99
1917 .St -isoC-99
1918 .It Li \-isoC\-2011
1919 .St -isoC-2011
1922 .Tn POSIX
1923 Part 1: System API
1925 .Bl -tag -width ".Li \-p1003.1g\-2000" -compact -offset indent
1926 .It Li \-iso9945\-1\-90
1927 .St -iso9945-1-90
1928 .It Li \-iso9945\-1\-96
1929 .St -iso9945-1-96
1930 .It Li \-p1003.1
1931 .St -p1003.1
1932 .It Li \-p1003.1\-88
1933 .St -p1003.1-88
1934 .It Li \-p1003.1\-90
1935 .St -p1003.1-90
1936 .It Li \-p1003.1\-96
1937 .St -p1003.1-96
1938 .It Li \-p1003.1b\-93
1939 .St -p1003.1b-93
1940 .It Li \-p1003.1c\-95
1941 .St -p1003.1c-95
1942 .It Li \-p1003.1g\-2000
1943 .St -p1003.1g-2000
1944 .It Li \-p1003.1i\-95
1945 .St -p1003.1i-95
1946 .It Li \-p1003.1\-2001
1947 .St -p1003.1-2001
1948 .It Li \-p1003.1\-2004
1949 .St -p1003.1-2004
1950 .It Li \-p1003.1\-2008
1951 .St -p1003.1-2008
1954 .Tn POSIX
1955 Part 2: Shell and Utilities
1957 .Bl -tag -width ".Li \-p1003.1g\-2000" -compact -offset indent
1958 .It Li \-iso9945\-2\-93
1959 .St -iso9945-2-93
1960 .It Li \-p1003.2
1961 .St -p1003.2
1962 .It Li \-p1003.2\-92
1963 .St -p1003.2-92
1964 .It Li \-p1003.2a\-92
1965 .St -p1003.2a-92
1968 X/Open
1970 .Bl -tag -width ".Li \-p1003.1g\-2000" -compact -offset indent
1971 .It Li \-susv2
1972 .St -susv2
1973 .It Li \-susv3
1974 .St -susv3
1975 .It Li \-svid4
1976 .St -svid4
1977 .It Li \-xbd5
1978 .St -xbd5
1979 .It Li \-xcu5
1980 .St -xcu5
1981 .It Li \-xcurses4.2
1982 .St -xcurses4.2
1983 .It Li \-xns5
1984 .St -xns5
1985 .It Li \-xns5.2
1986 .St -xns5.2
1987 .It Li \-xpg3
1988 .St -xpg3
1989 .It Li \-xpg4
1990 .St -xpg4
1991 .It Li \-xpg4.2
1992 .St -xpg4.2
1993 .It Li \-xsh5
1994 .St -xsh5
1997 Miscellaneous
1999 .Bl -tag -width ".Li \-p1003.1g\-2000" -compact -offset indent
2000 .It Li \-ieee754
2001 .St -ieee754
2002 .It Li \-iso8601
2003 .St -iso8601
2004 .It Li \-iso8802\-3
2005 .St -iso8802-3
2008 .Ss "Variable Types"
2011 .Ql .Vt
2012 macro may be used whenever a type is referenced.
2013 In the
2014 .Sx SYNOPSIS
2015 section, it causes a line break (useful for old style variable declarations).
2017 .Dl Usage: .Vt Ao type Ac ...
2019 .Bl -tag -width ".Li .Vt\ extern\ char\ *optarg\ ;" -compact -offset 15n
2020 .It Li ".Vt extern char *optarg ;"
2021 .Vt extern char *optarg ;
2022 .It Li ".Vt FILE *"
2023 .Vt FILE *
2026 .Ss Variables
2028 Generic variable reference.
2030 .Dl Usage: .Va Ao variable Ac ...
2032 .Bl -tag -width ".Li .Va\ Xchar\ sX\ ]\ )\ )\ ," -compact -offset 15n
2033 .It Li ".Va count"
2034 .Va count
2035 .It Li ".Va settimer ,"
2036 .Va settimer ,
2037 .It Li ".Va \*[q]int *prt\*[q] ) :"
2038 .Va "int *prt" ) :
2039 .It Li ".Va \*[q]char s\*[q] ] ) ) ,"
2040 .Va "char s" ] ) ) ,
2043 The default width is 12n.
2045 .Ss "Manual Page Cross References"
2048 .Ql .Xr
2049 macro expects the first argument to be a manual page name.
2050 The optional second argument, if a string (defining the manual section), is
2051 put into parentheses.
2053 .Dl Usage: .Xr Ao man page name Ac Oo Ao section Ac Oc ...
2055 .Bl -tag -width ".Li .Xr\ xinit\ 1x\ ;" -compact -offset 15n
2056 .It Li ".Xr mdoc"
2057 .Xr mdoc
2058 .It Li ".Xr mdoc ,"
2059 .Xr mdoc ,
2060 .It Li ".Xr mdoc 7"
2061 .Xr mdoc 7
2062 .It Li ".Xr xinit 1x ;"
2063 .Xr xinit 1x ;
2066 The default width is 10n.
2069 .Sh "GENERAL TEXT DOMAIN"
2071 .Ss "AT&T Macro"
2074 .Dl Usage: .At Oo Ao version Ac Oc ...
2076 .Bl -tag -width ".Li .At\ v6\ ." -compact -offset 15n
2077 .It Li .At
2079 .It Li ".At v6 ."
2080 .At v6 .
2083 The following values for
2084 .Ao version Ac
2085 are possible:
2087 .Dl 32v, v1, v2, v3, v4, v5, v6, v7, III, V, V.1, V.2, V.3, V.4
2089 .Ss "BSD Macro"
2092 .Dl "Usage: .Bx" Bro \-alpha | \-beta | \-devel Brc ...
2093 .Dl "       .Bx" Oo Ao version Ac Oo Ao release Ac Oc Oc ...
2095 .Bl -tag -width ".Li .Bx\ -devel" -compact -offset 15n
2096 .It Li .Bx
2098 .It Li ".Bx 4.3 ."
2099 .Bx 4.3 .
2100 .It Li ".Bx \-devel"
2101 .Bx -devel
2104 .Ao version Ac
2105 will be prepended to the string
2106 .Sq Bx .
2107 The following values for
2108 .Ao release Ac
2109 are possible:
2111 .Dl Reno, reno, Tahoe, tahoe, Lite, lite, Lite2, lite2
2113 .Ss "NetBSD Macro"
2116 .Dl Usage: .Nx Oo Ao version Ac Oc ...
2118 .Bl -tag -width ".Li .Nx\ 1.4\ ." -compact -offset 15n
2119 .It Li .Nx
2121 .It Li ".Nx 1.4 ."
2122 .Nx 1.4 .
2125 For possible values of
2126 .Ao version Ac
2127 see the description of the
2128 .Ql .Os
2129 command above in section
2130 .Sx "TITLE MACROS" .
2132 .Ss "FreeBSD Macro"
2135 .Dl Usage: .Fx Oo Ao version Ac Oc ...
2137 .Bl -tag -width ".Li .Fx\ 2.2\ ." -compact -offset 15n
2138 .It Li .Fx
2140 .It Li ".Fx 2.2 ."
2141 .Fx 2.2 .
2144 For possible values of
2145 .Ao version Ac
2146 see the description of the
2147 .Ql .Os
2148 command above in section
2149 .Sx "TITLE MACROS" .
2151 .Ss "DragonFly Macro"
2154 .Dl Usage: .Dx Oo Ao version Ac Oc ...
2156 .Bl -tag -width ".Li .Dx\ 1.4\ ." -compact -offset 15n
2157 .It Li .Dx
2159 .It Li ".Dx 1.4 ."
2160 .Dx 1.4 .
2163 For possible values of
2164 .Ao version Ac
2165 see the description of the
2166 .Ql .Os
2167 command above in section
2168 .Sx "TITLE MACROS" .
2170 .Ss "OpenBSD Macro"
2173 .Dl Usage: .Ox Oo Ao version Ac Oc ...
2175 .Bl -tag -width ".Li .Ox\ 1.0" -compact -offset 15n
2176 .It Li ".Ox 1.0"
2177 .Ox 1.0
2180 .Ss "BSD/OS Macro"
2183 .Dl Usage: .Bsx Oo Ao version Ac Oc ...
2185 .Bl -tag -width ".Li .Bsx\ 1.0" -compact -offset 15n
2186 .It Li ".Bsx 1.0"
2187 .Bsx 1.0
2190 .Ss "UNIX Macro"
2193 .Dl Usage: .Ux ...
2195 .Bl -tag -width ".Li .Ux" -compact -offset 15n
2196 .It Li .Ux
2200 .Ss "Emphasis Macro"
2202 Text may be stressed or emphasized with the
2203 .Ql .Em
2204 macro.
2205 The usual font for emphasis is italic.
2207 .Dl Usage: .Em Ao argument Ac ...
2209 .Bl -tag -width ".Li .Em\ vide\ infra\ )\ )\ ," -compact -offset 15n
2210 .It Li ".Em does not"
2211 .Em does not
2212 .It Li ".Em exceed 1024 ."
2213 .Em exceed 1024 .
2214 .It Li ".Em vide infra ) ) ,"
2215 .Em vide infra ) ) ,
2218 The default width is 10n.
2220 .Ss "Font Mode"
2223 .Ql .Bf
2224 font mode must be ended with the
2225 .Ql .Ef
2226 macro (the latter takes no arguments).
2227 Font modes may be nested within other font modes.
2229 .Ql .Bf
2230 has the following syntax:
2232 .Dl .Bf Ao font mode Ac
2234 .Ao font mode Ac
2235 must be one of the following three types:
2237 .Bl -tag -width ".Sy \&Sy | Fl symbolic" -compact -offset indent
2238 .It Sy \&Em | Fl emphasis
2239 Same as if the
2240 .Ql .Em
2241 macro was used for the entire block of text.
2242 .It Sy \&Li | Fl literal
2243 Same as if the
2244 .Ql .Li
2245 macro was used for the entire block of text.
2246 .It Sy \&Sy | Fl symbolic
2247 Same as if the
2248 .Ql .Sy
2249 macro was used for the entire block of text.
2252 Both macros are neither callable nor parsed.
2254 .Ss "Enclosure and Quoting Macros"
2256 The concept of enclosure is similar to quoting.
2257 The object being to enclose one or more strings between a pair of characters
2258 like quotes or parentheses.
2259 The terms quoting and enclosure are used interchangeably throughout this
2260 document.
2261 Most of the one-line enclosure macros end in small letter
2262 .Ql q
2263 to give a hint of quoting, but there are a few irregularities.
2264 For each enclosure macro there is also a pair of open and close macros which
2265 end in small letters
2266 .Ql o
2268 .Ql c
2269 respectively.
2271 \# XXX
2272 .if t \
2273 .  ne 10
2276 lb lb lb lb lb
2277 l l l l l.
2278 Quote   Open    Close   Function        Result
2279 \&.Aq   .Ao     .Ac     Angle Bracket Enclosure <string>
2280 \&.Bq   .Bo     .Bc     Bracket Enclosure       [string]
2281 \&.Brq  .Bro    .Brc    Brace Enclosure {string}
2282 \&.Dq   .Do     .Dc     Double Quote    "string"
2283 \&.Eq   .Eo     .Ec     Enclose String (in XX)  XXstring
2284 \&.Pq   .Po     .Pc     Parenthesis Enclosure   (string)
2285 \&.Ql                   Quoted Literal  \*[Lq]string\*[Rq] or string
2286 \&.Qq   .Qo     .Qc     Straight Double Quote   "string"
2287 \&.Sq   .So     .Sc     Single Quote    'string'
2290 All macros ending with
2291 .Sq q
2293 .Sq o
2294 have a default width value of 12n.
2296 .Bl -tag -width ".Li .Ec , .Eo"
2297 .It Li .Eo , .Ec
2298 These macros expect the first argument to be the opening and closing strings
2299 respectively.
2300 .It Li .Es , .En
2301 Due to the nine-argument limit in the original troff program two other
2302 macros have been implemented which are now rather obsolete:
2303 .Ql .Es
2304 takes the first and second parameter as the left and right enclosure string,
2305 which are then used to enclose the arguments of
2306 .Ql .En .
2307 The default width value is 12n for both macros.
2308 .It Li .Eq
2309 The first and second arguments of this macro are the opening and
2310 closing strings respectively, followed by the arguments to be enclosed.
2311 .It Li .Ql
2312 The quoted literal macro behaves differently in troff and nroff mode.
2313 If formatted with
2314 .Xr @L_NROFF@ 1 ,
2315 a quoted literal is always quoted.
2316 If formatted with troff, an item is only quoted if the width of the item is
2317 less than three constant width characters.
2318 This is to make short strings more visible where the font change to literal
2319 (constant width) is less noticeable.
2321 The default width is 16n.
2322 .It Li .Pf
2323 The prefix macro suppresses the whitespace between its first and second
2324 argument:
2326 .Bl -tag -width ".Li .Pf\ (\ Fa\ name2" -offset indent
2327 .It Li ".Pf ( Fa name2"
2328 .Pf ( Fa name2
2331 The default width is 12n.
2334 .Ql .Ns
2335 macro (see below) performs the analogous suffix function.
2336 .It Li .Ap
2338 .Ql .Ap
2339 macro inserts an apostrophe and exits any special text modes, continuing in
2340 .Ql .No
2341 mode.
2345 Examples of quoting:
2348 .Bl -tag -width ".Li .Bq\ Em\ Greek\ ,\ French\ ." -compact -offset indent
2349 .It Li .Aq
2351 .It Li ".Aq Pa ctype.h ) ,"
2352 .Aq Pa ctype.h ) ,
2353 .It Li .Bq
2355 .It Li ".Bq Em Greek , French ."
2356 .Bq Em Greek , French .
2357 .It Li .Dq
2359 .It Li ".Dq string abc ."
2360 .Dq string abc .
2361 .It Li ".Dq \'^[A\-Z]\'"
2362 .Dq \'^[A-Z]\'
2363 .It Li ".Ql man mdoc"
2364 .Ql man mdoc
2365 .It Li .Qq
2367 .It Li ".Qq string ) ,"
2368 .Qq string ) ,
2369 .It Li ".Qq string Ns ),"
2370 .Qq string Ns ),
2371 .It Li .Sq
2373 .It Li ".Sq string"
2374 .Sq string
2375 .It Li ".Em or Ap ing"
2376 .Em or Ap ing
2379 For a good example of nested enclosure macros, see the
2380 .Ql .Op
2381 option macro.
2382 It was created from the same underlying enclosure macros as those presented
2383 in the list above.
2385 .Ql .Xo
2387 .Ql .Xc
2388 extended argument list macros are discussed below.
2390 .Ss "No-Op or Normal Text Macro"
2393 .Ql .No
2394 macro can be used in a macro command line for parameters which should
2395 .Em not
2396 be formatted.
2397 Be careful to add
2398 .Ql \e&
2399 to the word
2400 .Ql \&No
2401 if you really want that English word (and not the macro) as a parameter.
2403 .Dl Usage: .No Ao argument Ac ...
2405 .Bl -tag -width ".Li .No\ test\ Ta\ with\ Ta\ tabs" -compact -offset 15n
2406 .It Li ".No test Ta with Ta tabs"
2407 .No test Ta with Ta tabs
2410 The default width is 12n.
2412 .Ss "No-Space Macro"
2415 .Ql .Ns
2416 macro suppresses insertion of a space between the current position and its
2417 first parameter.
2418 For example, it is useful for old style argument lists where there is no
2419 space between the flag and argument:
2421 .Dl "Usage:" ... Ao argument Ac \&Ns Oo Ao argument Ac Oc ...
2422 .Dl "      " .Ns Ao argument Ac ...
2424 .Bl -tag -width ".Li .Op\ Fl\ I\ Ns\ Ar\ directory" -compact -offset 15n
2425 .It Li ".Op Fl I Ns Ar directory"
2426 .Op Fl I Ns Ar directory
2429 Note: The
2430 .Ql .Ns
2431 macro always invokes the
2432 .Ql .No
2433 macro after eliminating the space unless another macro name follows it.
2434 If used as a command (i.e., the second form above in the
2435 .Sq Usage
2436 line),
2437 .Ql .Ns
2438 is identical to
2439 .Ql .No .
2441 .Ss "Section Cross References"
2444 .Ql .Sx
2445 macro designates a reference to a section header within the same document.
2447 .Dl Usage: .Sx Ao section reference Ac ...
2449 .Bl -tag -width ".Li .Sx\ FILES" -offset 15n
2450 .It Li ".Sx FILES"
2451 .Sx FILES
2454 The default width is 16n.
2456 .Ss Symbolics
2458 The symbolic emphasis macro is generally a boldface macro in either the
2459 symbolic sense or the traditional English usage.
2461 .Dl Usage: .Sy Ao symbol Ac ...
2463 .Bl -tag -width ".Li .Sy\ Important\ Notice" -compact -offset 15n
2464 .It Li ".Sy Important Notice"
2465 .Sy Important Notice
2468 The default width is 6n.
2470 .Ss Mathematical Symbols
2472 Use this macro for mathematical symbols and similar things.
2474 .Dl Usage: .Ms Ao math symbol Ac ...
2476 .Bl -tag -width ".Li .Ms\ sigma" -compact -offset 15n
2477 .It Li ".Ms sigma"
2478 .Ms sigma
2481 The default width is 6n.
2483 .Ss "References and Citations"
2485 The following macros make a modest attempt to handle references.
2486 At best, the macros make it convenient to manually drop in a subset of
2487 .Xr @L_P_REFER@ 1
2488 style references.
2490 .Bl -tag -width 6n -offset indent -compact
2491 .It Li .Rs
2492 Reference start (does not take arguments).
2493 Causes a line break in the
2494 .Sx "SEE ALSO"
2495 section and begins collection of reference information until the reference
2496 end macro is read.
2497 .It Li .Re
2498 Reference end (does not take arguments).
2499 The reference is printed.
2500 .It Li .%A
2501 Reference author name; one name per invocation.
2502 .It Li .%B
2503 Book title.
2504 .It Li .%C
2505 City/place.
2506 .It Li .%D
2507 Date.
2508 .It Li .%I
2509 Issuer/publisher name.
2510 .It Li .%J
2511 Journal name.
2512 .It Li .%N
2513 Issue number.
2514 .It Li .%O
2515 Optional information.
2516 .It Li .%P
2517 Page number.
2518 .It Li .%Q
2519 Corporate or foreign author.
2520 .It Li .%R
2521 Report name.
2522 .It Li .%T
2523 Title of article.
2524 .It Li .%U
2525 Optional hypertext reference.
2526 .It Li .%V
2527 Volume.
2530 Macros beginning with
2531 .Ql %
2532 are not callable but accept multiple arguments in the usual way.
2533 Only the
2534 .Ql .Tn
2535 macro is handled properly as a parameter; other macros will cause strange
2536 output.
2537 .Ql .%B
2539 .Ql .%T
2540 can be used outside of the
2541 .Ql .Rs/.Re
2542 environment.
2544 Example:
2546 .Bd -literal -offset indent
2547 \&.Rs
2548 \&.%A "Matthew Bar"
2549 \&.%A "John Foo"
2550 \&.%T "Implementation Notes on foobar(1)"
2551 \&.%R "Technical Report ABC\-DE\-12\-345"
2552 \&.%Q "Drofnats College"
2553 \&.%C "Nowhere"
2554 \&.%D "April 1991"
2555 \&.Re
2558 produces
2560 .Bd -ragged -offset indent
2562 .%A "Matthew Bar"
2563 .%A "John Foo"
2564 .%T "Implementation Notes on foobar(1)"
2565 .%R "Technical Report ABC-DE-12-345"
2566 .%Q "Drofnats College"
2567 .%C "Nowhere"
2568 .%D "April 1991"
2572 .Ss "Trade Names (or Acronyms and Type Names)"
2574 The trade name macro prints its arguments in a smaller font.
2575 Its intended use is to imitate a small caps fonts for uppercase acronyms.
2577 .Dl Usage: .Tn Ao symbol Ac ...
2579 .Bl -tag -width ".Li .Tn\ ASCII" -compact -offset 15n
2580 .It Li ".Tn DEC"
2581 .Tn DEC
2582 .It Li ".Tn ASCII"
2583 .Tn ASCII
2586 The default width is 10n.
2588 .Ss "Extended Arguments"
2591 .Li .Xo
2593 .Li .Xc
2594 macros allow one to extend an argument list on a macro boundary for the
2595 .Ql .It
2596 macro (see below).
2597 Note that
2598 .Li .Xo
2600 .Li .Xc
2601 are implemented similarly to all other macros opening and closing an
2602 enclosure (without inserting characters, of course).
2603 This means that the following is true for those macros also.
2605 Here is an example of
2606 .Ql .Xo
2607 using the space mode macro to turn spacing off:
2609 .Bd -literal -offset indent
2610 \&.Sm off
2611 \&.It Xo Sy I Ar operation
2612 \&.No \een Ar count No \een
2613 \&.Xc
2614 \&.Sm on
2617 produces
2619 .Bd -filled -offset indent
2620 .Bl -tag -compact
2621 .Sm off
2622 .It Xo Sy I Ar operation
2623 .No \en Ar count No \en
2625 .Sm on
2630 Another one:
2632 .Bd -literal -offset indent
2633 \&.Sm off
2634 \&.It Cm S No / Ar old_pattern Xo
2635 \&.No / Ar new_pattern
2636 \&.No / Op Cm g
2637 \&.Xc
2638 \&.Sm on
2641 produces
2643 .Bd -filled -offset indent
2644 .Bl -tag -compact
2645 .Sm off
2646 .It Cm S No \&/ Ar old_pattern Xo
2647 .No \&/ Ar new_pattern
2648 .No \&/ Op Cm g
2650 .Sm on
2654 Another example of
2655 .Ql .Xo
2656 and enclosure macros: Test the value of a variable.
2658 .Bd -literal -offset indent
2659 \&.It Xo
2660 \&.Ic .ifndef
2661 \&.Oo \e&! Oc Ns Ar variable Oo
2662 \&.Ar operator variable ...
2663 \&.Oc Xc
2666 produces
2668 .Bd -filled -offset indent
2669 .Bl -tag -width flag -compact
2670 .It Xo
2671 .Ic .ifndef
2672 .Oo \&! Oc Ns Ar variable Oo
2673 .Ar operator variable ...
2674 .Oc Xc
2679 .Sh "PAGE STRUCTURE DOMAIN"
2681 .Ss "Section Headers"
2683 The following
2684 .Ql .Sh
2685 section header macros are required in every man page.
2686 The remaining section headers are recommended at the discretion of the
2687 author writing the manual page.
2689 .Ql .Sh
2690 macro is parsed but not generally callable.
2691 It can be used as an argument in a call to
2692 .Ql .Sh
2693 only; it then reactivates the default font for
2694 .Ql .Sh .
2696 The default width is 8n.
2698 .Bl -tag -width ".Li .Sh\ RETURN\ VALUES"
2699 .It Li ".Sh NAME"
2701 .Ql ".Sh NAME"
2702 macro is mandatory.
2703 If not specified, headers, footers and page layout defaults will not be set
2704 and things will be rather unpleasant.
2706 .Em NAME
2707 section consists of at least three items.
2708 The first is the
2709 .Ql .Nm
2710 name macro naming the subject of the man page.
2711 The second is the name description macro,
2712 .Ql .Nd ,
2713 which separates the subject name from the third item, which is the
2714 description.
2715 The description should be the most terse and lucid possible, as the space
2716 available is small.
2718 .Ql .Nd
2719 first prints
2720 .Ql \- ,
2721 then all its arguments.
2723 .It Li ".Sh LIBRARY"
2724 This section is for section two and three function calls.
2725 It should consist of a single
2726 .Ql .Lb
2727 macro call;
2729 .Sx "Library Names" .
2731 .It Li ".Sh SYNOPSIS"
2733 .Sx SYNOPSIS
2734 section describes the typical usage of the subject of a man page.
2735 The macros required are either
2736 .Ql .Nm ,
2737 .Ql .Cd ,
2739 .Ql .Fn
2740 (and possibly
2741 .Ql .Fo ,
2742 .Ql .Fc ,
2743 .Ql .Fd ,
2745 .Ql .Ft ) .
2746 The function name macro
2747 .Ql .Fn
2748 is required for manual page sections\~2 and\~3; the command and general name
2749 macro
2750 .Ql .Nm
2751 is required for sections 1, 5, 6, 7, and\~8.
2752 Section\~4 manuals require a
2753 .Ql .Nm ,
2754 .Ql .Fd
2755 or a
2756 .Ql .Cd
2757 configuration device usage macro.
2758 Several other macros may be necessary to produce the synopsis line as shown
2759 below:
2761 .Bd -filled -offset indent
2762 .Nm cat
2763 .Op Fl benstuv
2764 .Op Fl
2768 The following macros were used:
2770 .Dl ".Nm cat"
2771 .Dl ".Op Fl benstuv"
2772 .Dl ".Op Fl"
2773 .Dl .Ar
2775 .It Li ".Sh DESCRIPTION"
2776 In most cases the first text in the
2777 .Sx DESCRIPTION
2778 section is a brief paragraph on the command, function or file, followed by a
2779 lexical list of options and respective explanations.
2780 To create such a list, the
2781 .Ql .Bl
2782 (begin list),
2783 .Ql .It
2784 (list item) and
2785 .Ql .El
2786 (end list)
2787 macros are used (see
2788 .Sx Lists and Columns
2789 below).
2791 .It Li ".Sh IMPLEMENTATION NOTES"
2792 Implementation specific information should be placed here.
2794 .It Li ".Sh RETURN VALUES"
2795 Sections 2, 3 and\~9 function return values should go here.
2797 .Ql .Rv
2798 macro may be used to generate text for use in the
2799 .Sx RETURN VALUES
2800 section for most section 2 and 3 library functions;
2802 .Sx "Return Values" .
2805 The following
2806 .Ql .Sh
2807 section headers are part of the preferred manual page layout and must be
2808 used appropriately to maintain consistency.
2809 They are listed in the order in which they would be used.
2811 .Bl -tag -width ".Li .Sh\ COMPATIBILITY"
2812 .It Li ".Sh ENVIRONMENT"
2814 .Em ENVIRONMENT
2815 section should reveal any related environment variables and clues to their
2816 behavior and/or usage.
2818 .It Li ".Sh FILES"
2819 Files which are used or created by the man page subject should be listed via
2821 .Ql .Pa
2822 macro in the
2823 .Sx FILES
2824 section.
2826 .It Li ".Sh EXAMPLES"
2827 There are several ways to create examples.
2828 See the
2829 .Em EXAMPLES
2830 section below for details.
2832 .It Li ".Sh DIAGNOSTICS"
2833 Diagnostic messages from a command should be placed in this section.
2835 .Ql .Ex
2836 macro may be used to generate text for use in the
2837 .Sx DIAGNOSTICS
2838 section for most section 1, 6 and\~8 commands;
2840 .Sx "Exit Status" .
2842 .It Li ".Sh COMPATIBILITY"
2843 Known compatibility issues (e.g.\& deprecated options or parameters)
2844 should be listed here.
2846 .It Li ".Sh ERRORS"
2847 Specific error handling, especially from library functions (man page
2848 sections 2, 3, and\~9) should go here.
2850 .Ql .Er
2851 macro is used to specify an error (errno).
2853 .It Li ".Sh SEE ALSO"
2854 References to other material on the man page topic and cross references to
2855 other relevant man pages should be placed in the
2856 .Sx "SEE ALSO"
2857 section.
2858 Cross references are specified using the
2859 .Ql .Xr
2860 macro.
2861 Currently
2862 .Xr @L_P_REFER@ 1
2863 style references are not accommodated.
2865 It is recommended that the cross references are sorted on the section
2866 number, then alphabetically on the names within a section, and placed
2867 in that order and comma separated.
2868 Example:
2870 .Xr ls 1 ,
2871 .Xr ps 1 ,
2872 .Xr group 5 ,
2873 .Xr passwd 5
2875 .It Li ".Sh STANDARDS"
2876 If the command, library function or file adheres to a specific
2877 implementation such as
2878 .St -p1003.2
2880 .St -ansiC
2881 this should be noted here.
2882 If the command does not adhere to any standard, its history should be noted
2883 in the
2884 .Em HISTORY
2885 section.
2887 .It Li ".Sh HISTORY"
2888 Any command which does not adhere to any specific standards should be
2889 outlined historically in this section.
2891 .It Li ".Sh AUTHORS"
2892 Credits should be placed here.
2893 Use the
2894 .Ql .An
2895 macro for names and the
2896 .Ql .Aq
2897 macro for e-mail addresses within optional contact information.
2898 Explicitly indicate whether the person authored the initial manual page
2899 or the software or whatever the person is being credited for.
2900 .It Li ".Sh BUGS"
2901 Blatant problems with the topic go here.
2904 User-specified
2905 .Ql .Sh
2906 sections may be added; for example, this section was set with:
2908 .Bd -literal -offset 15n
2909 \&.Sh "PAGE STRUCTURE DOMAIN"
2912 .Ss "Subsection Headers"
2914 Subsection headers have exactly the same syntax as section headers:
2915 .Ql .Ss
2916 is parsed but not generally callable.
2917 It can be used as an argument in a call to
2918 .Ql .Ss
2919 only; it then reactivates the default font for
2920 .Ql .Ss .
2922 The default width is 8n.
2924 .Ss "Paragraphs and Line Spacing"
2926 .Bl -tag -width ".Li .Pp"
2927 .It Li .Pp
2929 .Ql .Pp
2930 paragraph command may be used to specify a line space where necessary.
2931 The macro is not necessary after a
2932 .Ql .Sh
2934 .Ql .Ss
2935 macro or before a
2936 .Ql .Bl
2938 .Ql .Bd
2939 macro (which both assert a vertical distance unless the
2940 .Fl compact
2941 flag is given).
2943 The macro is neither callable nor parsed and takes no arguments; an
2944 alternative name is
2945 .Ql .Lp .
2948 .\" XXX
2950 .\" This worked with version one, need to redo for version three
2951 .\" .Pp
2952 .\" .Ds I
2953 .\" .Cw (ax+bx+c) \ is\ produced\ by\ \&
2954 .\" .\".Cw (ax+bx+c) \&.Va_by_) \&_and_\& \&[?/]m_b1_e1_f1[?/]\&
2955 .\" .Cl Cx \t\t
2956 .\" .Li \&.Cx\ (
2957 .\" .Cx
2958 .\" .Cl Cx \t\t
2959 .\" .Li \&.Va ax
2960 .\" .Cx
2961 .\" .Cl Cx \t\t
2962 .\" .Li \&.Sy \+
2963 .\" .Cx
2964 .\" .Cl Cx \&(\&
2965 .\" .Va ax
2966 .\" .Cx +
2967 .\" .Va by
2968 .\" .Cx +
2969 .\" .Va c )
2970 .\" .Cx \t
2971 .\" .Em is produced by
2972 .\" .Cx \t
2973 .\" .Li \&.Va by
2974 .\" .Cx
2975 .\" .Cl Cx \t\t
2976 .\" .Li \&.Sy \+
2977 .\" .Cx
2978 .\" .Cl Cx \t\t
2979 .\" .Li \&.Va c )
2980 .\" .Cx
2981 .\" .Cl Cx \t\t
2982 .\" .Li \&.Cx
2983 .\" .Cx
2984 .\" .Cw
2985 .\" .De
2986 .\" .Pp
2987 .\" This example shows the same equation in a different format.
2988 .\" The spaces
2989 .\" around the
2990 .\" .Li \&+
2991 .\" signs were forced with
2992 .\" .Li \e :
2993 .\" .Pp
2994 .\" .Ds I
2995 .\" .Cw (ax\ +\ bx\ +\ c) \ is\ produced\ by\ \&
2996 .\" .\".Cw (ax+bx+c) \&.Va_by_) \&_and_\& \&[?/]m_b1_e1_f1[?/]\&
2997 .\" .Cl Cx \t\t
2998 .\" .Li \&.Cx\ (
2999 .\" .Cx
3000 .\" .Cl Cx \t\t
3001 .\" .Li \&.Va a
3002 .\" .Cx
3003 .\" .Cl Cx \t\t
3004 .\" .Li \&.Sy x
3005 .\" .Cx
3006 .\" .Cl Cx \t\t
3007 .\" .Li \&.Cx \e\ +\e\ \e&
3008 .\" .Cx
3009 .\" .Cl Cx \&(\&
3010 .\" .Va a
3011 .\" .Sy x
3012 .\" .Cx \ +\ \&
3013 .\" .Va b
3014 .\" .Sy y
3015 .\" .Cx \ +\ \&
3016 .\" .Va c )
3017 .\" .Cx \t
3018 .\" .Em is produced by
3019 .\" .Cl Cx \t\t
3020 .\" .Li \&.Va b
3021 .\" .Cx
3022 .\" .Cl Cx \t\t
3023 .\" .Li \&.Sy y
3024 .\" .Cx
3025 .\" .Cl Cx \t\t
3026 .\" .Li \&.Cx \e\ +\e\ \e&
3027 .\" .Cx
3028 .\" .Cl Cx \t\t
3029 .\" .Li \&.Va c )
3030 .\" .Cx
3031 .\" .Cl Cx \t\t
3032 .\" .Li \&.Cx
3033 .\" .Cx
3034 .\" .Cw
3035 .\" .De
3036 .\" .Pp
3037 .\" The incantation below was
3038 .\" lifted from the
3039 .\" .Xr adb 1
3040 .\" manual page:
3041 .\" .Pp
3042 .\" .Ds I
3043 .\" .Cw \&[?/]m_b1_e1_f1[?/]\& is\ produced\ by
3044 .\" .Cl Cx \t\t
3045 .\" .Li \&.Cx Op Sy ?/
3046 .\" .Cx
3047 .\" .Cl Cx \t\t
3048 .\" .Li \&.Nm m
3049 .\" .Cx
3050 .\" .Cl Cx Op Sy ?/
3051 .\" .Nm m
3052 .\" .Ad \ b1 e1 f1
3053 .\" .Op Sy ?/
3054 .\" .Cx \t
3055 .\" .Em is produced by
3056 .\" .Cx \t
3057 .\" .Li \&.Ar \e\ b1 e1 f1
3058 .\" .Cx
3059 .\" .Cl Cx \t\t
3060 .\" .Li \&.Op Sy ?/
3061 .\" .Cx
3062 .\" .Cl Cx \t\t
3063 .\" .Li \&.Cx
3064 .\" .Cx
3065 .\" .Cw
3066 .\" .De
3067 .\" .Pp
3069 .Ss Keeps
3071 The only keep that is implemented at this time is for words.
3072 The macros are
3073 .Ql .Bk
3074 (begin keep)
3076 .Ql .Ek
3077 (end keep).
3078 The only option that
3079 .Ql .Bk
3080 accepts currently is
3081 .Fl words
3082 (this is also the default if no option is given) which is useful for
3083 preventing line breaks in the middle of options.
3084 In the example for the make command line arguments (see
3085 .Sx What's in a Name ) ,
3086 the keep prevented
3087 .Xr @L_NROFF@ 1
3088 from placing up the flag and the argument on separate lines.
3090 Both macros are neither callable nor parsed.
3092 More work needs to be done with the keep macros; specifically, a
3093 .Fl line
3094 option should be added.
3096 .Ss "Examples and Displays"
3098 There are seven types of displays.
3100 .Bl -tag -width ".Li .D1"
3101 .It Li .D1
3102 (This is D-one.)
3103 Display one line of indented text.
3104 This macro is parsed but not callable.
3106 .D1 Fl ldghfstru
3108 The above was produced by:
3109 .Li ".D1 Fl ldghfstru" .
3111 .It Li .Dl
3112 (This is D-ell.)
3113 Display one line of indented
3114 .Em literal
3115 text.
3117 .Ql .Dl
3118 example macro has been used throughout this file.
3119 It allows the indentation (display) of one line of text.
3120 Its default font is set to constant width (literal).
3121 .Ql .Dl
3122 is parsed but not callable.
3124 .Dl % ls \-ldg /usr/local/bin
3126 The above was produced by:
3127 .Li ".Dl % ls \e\-ldg /usr/local/bin" .
3129 .It Li .Bd
3130 Begin display.
3132 .Ql .Bd
3133 display must be ended with the
3134 .Ql .Ed
3135 macro.
3136 It has the following syntax:
3138 .Bd -ragged -compact
3139 .Bl -tag -width ".Li .Bd" -offset indent
3140 .It Li .Bd Xo
3141 .Bro \-literal | \-filled | \-unfilled | \-ragged | \-centered Brc
3142 .Oo \-offset Ao string Ac Oc Oo \-file Ao file name Ac Oc Oo \-compact Oc Xc
3146 .Bl -tag -width ".Fl file Ao Ar file name Ac " -compact
3147 .It Fl ragged
3148 Fill, but do not adjust the right margin (only left-justify).
3149 .It Fl centered
3150 Center lines between the current left and right margin.
3151 Note that each single line is centered.
3152 .It Fl unfilled
3153 Do not fill; display a block of text as typed, using line breaks as
3154 specified by the user.
3155 This can produce overlong lines without warning messages.
3156 .It Fl filled
3157 Display a filled block.
3158 The block of text is formatted (i.e., the text is justified on both the left
3159 and right side).
3160 .It Fl literal
3161 Display block with literal font (usually fixed-width).
3162 Useful for source code or simple tabbed or spaced text.
3163 .It Fl file Ao Ar file name Ac
3164 The file whose name follows the
3165 .Fl file
3166 flag is read and displayed before any data enclosed with
3167 .Ql .Bd
3169 .Ql .Ed ,
3170 using the selected display type.
3172 .Xr troff/ Ns Nm \-mdoc
3173 commands in the file will be processed.
3174 .It Fl offset Ao Ar string Ac
3176 .Fl offset
3177 is specified with one of the following strings, the string is interpreted to
3178 indicate the level of indentation for the forthcoming block of text:
3181 .Bl -tag -width ".Ar indent-two" -compact
3182 .It Ar left
3183 Align block on the current left margin; this is the default mode of
3184 .Ql .Bd .
3185 .It Ar center
3186 Supposedly center the block.
3187 At this time unfortunately, the block merely gets left aligned about an
3188 imaginary center margin.
3189 .It Ar indent
3190 Indent by one default indent value or tab.
3191 The default indent value is also used for the
3192 .Ql .D1
3194 .Ql .Dl
3195 macros, so one is guaranteed the two types of displays will line up.
3196 The indentation value is normally set to\~6n or about two thirds of an inch
3197 (six constant width characters).
3198 .It Ar indent\-two
3199 Indent two times the default indent value.
3200 .It Ar right
3201 This
3202 .Em left
3203 aligns the block about two inches from the right side of the page.
3204 This macro needs work and perhaps may never do the right thing within
3205 .Xr @L_TROFF@ 1 .
3209 .Ao string Ac
3210 is a valid numeric expression instead
3211 .Pf ( Em with a scale indicator other than
3212 .Sq Em u ) ,
3213 use that value for indentation.
3214 The most useful scale indicators are
3215 .Sq m
3217 .Sq n ,
3218 specifying the so-called
3219 .Em \&Em
3221 .Em "En square" .
3222 This is approximately the width of the letters
3223 .Sq m
3225 .Sq n
3226 respectively
3227 of the current font (for nroff output, both scale indicators give the same
3228 values).
3230 .Ao string Ac
3231 isn't a numeric expression, it is tested whether it is an
3232 .Nm \-mdoc
3233 macro name, and the default offset value associated with this macro is used.
3234 Finally, if all tests fail,
3235 the width of
3236 .Ao string Ac
3237 (typeset with a fixed-width font) is taken as the offset.
3238 .It Fl compact
3239 Suppress insertion of vertical space before begin of display.
3242 .It Li .Ed
3243 End display (takes no arguments).
3246 .Ss "Lists and Columns"
3248 There are several types of lists which may be initiated with the
3249 .Ql .Bl
3250 begin-list macro.
3251 Items within the list are specified with the
3252 .Ql .It
3253 item macro, and each list must end with the
3254 .Ql .El
3255 macro.
3256 Lists may be nested within themselves and within displays.
3257 The use of columns inside of lists or lists inside of columns is unproven.
3259 In addition, several list attributes may be specified such as the width of a
3260 tag, the list offset, and compactness (blank lines between items allowed or
3261 disallowed).
3262 Most of this document has been formatted with a tag style list
3263 .Pf ( Fl tag ) .
3265 It has the following syntax forms:
3267 .Bd -ragged -compact
3268 .Bl -tag -width ".Li .Bl" -offset indent -compact
3269 .It Li .Bl Xo
3270 .Bro \-hang | \-ohang | \-tag | \-diag | \-inset Brc
3271 .Oo \-width Ao string Ac Oc
3272 .Oo \-offset Ao string Ac Oc Oo \-compact Oc Xc
3273 .It Li .Bl Xo
3274 .No \-column Oo \-offset Ao string Ac Oc
3275 .Ao string1 Ac Ao string2 Ac ... Xc
3276 .It Li .Bl Xo
3277 .Bro \-item | \-enum Oo \-nested Oc | \-bullet | \-hyphen | \-dash Brc
3278 .Oo \-offset Ao string Ac Oc Oo \-compact Oc Xc
3282 And now a detailed description of the list types.
3284 .Bl -tag -width ".Fl column" -compact
3285 .It Fl bullet
3286 A bullet list.
3288 .Bd -literal -offset indent
3289 \&.Bl \-bullet \-offset indent \-compact
3290 \&.It
3291 Bullet one goes here.
3292 \&.It
3293 Bullet two here.
3294 \&.El
3297 Produces:
3299 .Bl -bullet -offset indent -compact
3301 Bullet one goes here.
3303 Bullet two here.
3306 .It Fl dash No ( or Fl hyphen )
3307 A dash list.
3309 .Bd -literal -offset indent
3310 \&.Bl \-dash \-offset indent \-compact
3311 \&.It
3312 Dash one goes here.
3313 \&.It
3314 Dash two here.
3315 \&.El
3318 Produces:
3320 .Bl -dash -offset indent -compact
3322 Dash one goes here.
3324 Dash two here.
3327 .It Fl enum
3328 An enumerated list.
3330 .Bd -literal -offset indent
3331 \&.Bl \-enum \-offset indent \-compact
3332 \&.It
3333 Item one goes here.
3334 \&.It
3335 And item two here.
3336 \&.El
3339 The result:
3341 .Bl -enum -offset indent -compact
3343 Item one goes here.
3345 And item two here.
3348 If you want to nest enumerated lists, use the
3349 .Fl nested
3350 flag (starting with the second-level list):
3352 .Bd -literal -offset indent
3353 \&.Bl \-enum \-offset indent \-compact
3354 \&.It
3355 Item one goes here
3356 \&.Bl \-enum \-nested \-compact
3357 \&.It
3358 Item two goes here.
3359 \&.It
3360 And item three here.
3361 \&.El
3362 \&.It
3363 And item four here.
3364 \&.El
3367 Result:
3369 .Bl -enum -offset indent -compact
3371 Item one goes here.
3372 .Bl -enum -nested -compact
3374 Item two goes here.
3376 And item three here.
3379 And item four here.
3382 .It Fl item
3383 A list of type
3384 .Fl item
3385 without list markers.
3387 .Bd -literal -offset indent
3388 \&.Bl \-item \-offset indent
3389 \&.It
3390 Item one goes here.
3391 Item one goes here.
3392 Item one goes here.
3393 \&.It
3394 Item two here.
3395 Item two here.
3396 Item two here.
3397 \&.El
3400 Produces:
3402 .Bl -item -offset indent
3404 Item one goes here.
3405 Item one goes here.
3406 Item one goes here.
3408 Item two here.
3409 Item two here.
3410 Item two here.
3413 .It Fl tag
3414 A list with tags.
3416 .Fl width
3417 to specify the tag width.
3419 .Bl -tag -width "PPID" -compact -offset indent
3420 .It SL
3421 sleep time of the process (seconds blocked)
3422 .It PAGEIN
3423 number of disk
3424 .Tn I/O Ns 's
3425 resulting from references by the process
3426 to pages not loaded in core.
3427 .It UID
3428 numerical user-id of process owner
3429 .It PPID
3430 numerical id of parent of process priority
3431 (non-positive when in non-interruptible wait)
3434 The raw text:
3436 .Bd -literal -offset indent
3437 \&.Bl \-tag \-width "PPID" \-compact \-offset indent
3438 \&.It SL
3439 sleep time of the process (seconds blocked)
3440 \&.It PAGEIN
3441 number of disk
3442 \&.Tn I/O Ns 's
3443 resulting from references by the process
3444 to pages not loaded in core.
3445 \&.It UID
3446 numerical user\-id of process owner
3447 \&.It PPID
3448 numerical id of parent of process priority
3449 (non\-positive when in non\-interruptible wait)
3450 \&.El
3453 .It Fl diag
3454 Diag lists create section four diagnostic lists and are similar to inset
3455 lists except callable macros are ignored.
3457 .Fl width
3458 flag is not meaningful in this context.
3460 Example:
3462 .Bd -literal -offset indent
3463 \&.Bl \-diag
3464 \&.It You can't use Sy here.
3465 The message says all.
3466 \&.El
3469 produces
3471 .Bl -diag
3472 .It You can't use Sy here.
3473 The message says all.
3476 .It Fl hang
3477 A list with hanging tags.
3479 .Bl -hang -offset indent
3480 .It Em Hanged
3481 labels appear similar to tagged lists when the
3482 label is smaller than the label width.
3483 .It Em Longer hanged list labels
3484 blend into the paragraph unlike
3485 tagged paragraph labels.
3488 And the unformatted text which created it:
3490 .Bd -literal -offset indent
3491 \&.Bl \-hang \-offset indent
3492 \&.It Em Hanged
3493 labels appear similar to tagged lists when the
3494 label is smaller than the label width.
3495 \&.It Em Longer hanged list labels
3496 blend into the paragraph unlike
3497 tagged paragraph labels.
3498 \&.El
3501 .It Fl ohang
3502 Lists with overhanging tags do not use indentation for the items; tags are
3503 written to a separate line.
3505 .Bl -ohang -offset indent
3506 .It Sy SL
3507 sleep time of the process (seconds blocked)
3508 .It Sy PAGEIN
3509 number of disk
3510 .Tn I/O Ns 's
3511 resulting from references by the process
3512 to pages not loaded in core.
3513 .It Sy UID
3514 numerical user-id of process owner
3515 .It Sy PPID
3516 numerical id of parent of process priority
3517 (non-positive when in non-interruptible wait)
3520 The raw text:
3522 .Bd -literal -offset indent
3523 \&.Bl \-ohang \-offset indent
3524 \&.It Sy SL
3525 sleep time of the process (seconds blocked)
3526 \&.It Sy PAGEIN
3527 number of disk
3528 \&.Tn I/O Ns 's
3529 resulting from references by the process
3530 to pages not loaded in core.
3531 \&.It Sy UID
3532 numerical user\-id of process owner
3533 \&.It Sy PPID
3534 numerical id of parent of process priority
3535 (non\-positive when in non\-interruptible wait)
3536 \&.El
3539 .It Fl inset
3540 Here is an example of inset labels:
3542 .Bl -inset -offset indent
3543 .It Em Tag
3544 The tagged list (also called a tagged paragraph)
3545 is the most common type of list used in the
3546 Berkeley manuals.
3547 Use a
3548 .Fl width
3549 attribute as described below.
3550 .It Em Diag
3551 Diag lists create section four diagnostic lists
3552 and are similar to inset lists except callable
3553 macros are ignored.
3554 .It Em Hang
3555 Hanged labels are a matter of taste.
3556 .It Em Ohang
3557 Overhanging labels are nice when space is constrained.
3558 .It Em Inset
3559 Inset labels are useful for controlling blocks of
3560 paragraphs and are valuable for converting
3561 .Nm \-mdoc
3562 manuals to other formats.
3565 Here is the source text which produced the above example:
3567 .Bd -literal -offset indent
3568 \&.Bl \-inset \-offset indent
3569 \&.It Em Tag
3570 The tagged list (also called a tagged paragraph)
3571 is the most common type of list used in the
3572 Berkeley manuals.
3573 \&.It Em Diag
3574 Diag lists create section four diagnostic lists
3575 and are similar to inset lists except callable
3576 macros are ignored.
3577 \&.It Em Hang
3578 Hanged labels are a matter of taste.
3579 \&.It Em Ohang
3580 Overhanging labels are nice when space is constrained.
3581 \&.It Em Inset
3582 Inset labels are useful for controlling blocks of
3583 paragraphs and are valuable for converting
3584 \&.Nm \-mdoc
3585 manuals to other formats.
3586 \&.El
3589 .It Fl column
3590 This list type generates multiple columns.
3591 The number of columns and the width of each column is determined by the
3592 arguments to the
3593 .Fl column
3594 list,
3595 .Aq Ar string1 ,
3596 .Aq Ar string2 ,
3597 etc.
3599 .Aq Ar stringN
3600 starts with a
3601 .Ql .\&
3602 (dot) immediately followed by a valid
3603 .Nm \-mdoc
3604 macro name, interpret
3605 .Aq Ar stringN
3606 and use the width of the result.
3607 Otherwise, the width of
3608 .Aq Ar stringN
3609 (typeset with a fixed-width font) is taken as the
3610 .Ar N Ns th
3611 column width.
3613 Each
3614 .Ql .It
3615 argument is parsed to make a row, each column within the row is a separate
3616 argument separated by a tab or the
3617 .Ql .Ta
3618 macro.
3620 The table:
3622 .Bl -column -offset indent ".Sy String" ".Sy Nroff" ".Sy Troff"
3623 .It Sy String Ta Sy Nroff Ta Sy Troff
3624 .It Li <= Ta <= Ta \*(<=
3625 .It Li >= Ta >= Ta \*(>=
3628 was produced by:
3630 .Bd -literal
3631 \&.Bl \-column \-offset indent ".Sy String" ".Sy Nroff" ".Sy Troff"
3632 \&.It Sy String Ta Sy Nroff Ta Sy Troff
3633 \&.It Li <= Ta <= Ta \e*(<=
3634 \&.It Li >= Ta >= Ta \e*(>=
3635 \&.El
3638 Don't abuse this list type!
3639 For more complicated cases it might be far better and easier to use
3640 .Xr @L_P_TBL@ 1 ,
3641 the table preprocessor.
3644 Other keywords:
3646 .Bl -tag -width ".Fl indent Ao Ar string Ac"
3647 .It Fl width Ao Ar string Ac
3649 .Aq Ar string
3650 starts with a
3651 .Ql .\&
3652 (dot) immediately followed by a valid
3653 .Nm \-mdoc
3654 macro name, interpret
3655 .Aq Ar string
3656 and use the width of the result.
3657 Almost all lists in this document use this option.
3659 Example:
3661 .Bd -literal -offset indent
3662 \&.Bl \-tag \-width ".Fl test Ao Ar string Ac"
3663 \&.It Fl test Ao Ar string Ac
3664 This is a longer sentence to show how the
3665 \&.Fl width
3666 flag works in combination with a tag list.
3667 \&.El
3670 gives:
3672 .Bl -tag -width ".Fl test Ao Ar string Ac"
3673 .It Fl test Ao Ar string Ac
3674 This is a longer sentence to show how the
3675 .Fl width
3676 flag works in combination with a tag list.
3679 (Note that the current state of
3680 .Nm \-mdoc
3681 is saved before
3682 .Aq Ar string
3683 is interpreted; afterwards, all variables are restored again.
3684 However, boxes (used for enclosures) can't be saved in
3685 .Xr @L_TROFF@ 1 ;
3686 as a consequence, arguments must always be
3687 .Em balanced
3688 to avoid nasty errors.
3689 For example, do not write
3690 .Ql ".Ao Ar string"
3692 .Ql ".Ao Ar string Xc"
3693 instead if you really need only an opening angle bracket.)
3695 Otherwise, if
3696 .Aq Ar string
3697 is a valid numeric expression
3698 .Em ( with a scale indicator other than
3699 .Sq Em u ) ,
3700 use that value for indentation.
3701 The most useful scale indicators are
3702 .Sq m
3704 .Sq n ,
3705 specifying the so-called
3706 .Em \&Em
3708 .Em "En square" .
3709 This is approximately the width of the letters
3710 .Sq m
3712 .Sq n
3713 respectively
3714 of the current font (for nroff output, both scale indicators give the same
3715 values).
3717 .Aq Ar string
3718 isn't a numeric expression, it is tested whether it is an
3719 .Nm \-mdoc
3720 macro name, and the default width value associated with this macro is used.
3721 Finally, if all tests fail,
3722 the width of
3723 .Aq Ar string
3724 (typeset with a fixed-width font) is taken as the width.
3726 If a width is not specified for the tag list type, every time
3727 .Ql .It
3728 is invoked, an attempt is made to determine an appropriate width.
3729 If the first argument to
3730 .Ql .It
3731 is a callable macro, the default width for that macro will be used;
3732 otherwise, the default width of
3733 .Ql .No
3734 is used.
3735 .It Fl offset Ao Ar string Ac
3737 .Aq Ar string
3739 .Ar indent ,
3740 a default indent value (normally set to\~6n, similar to the value used in
3741 .Ql .Dl
3743 .Ql .Bd )
3744 is used.
3746 .Aq Ar string
3747 is a valid numeric expression instead
3748 .Pf ( Em with a scale indicator other than
3749 .Sq Em u ) ,
3750 use that value for indentation.
3751 The most useful scale indicators are
3752 .Sq m
3754 .Sq n ,
3755 specifying the so-called
3756 .Em \&Em
3758 .Em "En square" .
3759 This is approximately the width of the letters
3760 .Sq m
3762 .Sq n
3763 respectively
3764 of the current font (for nroff output, both scale indicators give the same
3765 values).
3767 .Aq Ar string
3768 isn't a numeric expression, it is tested whether it is an
3769 .Nm \-mdoc
3770 macro name, and the default offset value associated with this macro is used.
3771 Finally, if all tests fail,
3772 the width of
3773 .Aq Ar string
3774 (typeset with a fixed-width font) is taken as the offset.
3775 .It Fl compact
3776 Suppress insertion of vertical space before the list and between list items.
3780 .Sh "MISCELLANEOUS MACROS"
3782 Here a list of the remaining macros which do not fit well into one of the
3783 above sections.
3784 We couldn't find real examples for the following macros:
3785 .Ql .Me
3787 .Ql .Ot .
3788 They are documented here for completeness \- if you know how to use them
3789 properly please send a mail to
3790 .Mt @BUGMAIL@
3791 (including an example).
3793 .Bl -tag -width ".Li .Bt"
3794 .It Li .Bt
3795 prints
3797 .Bd -ragged -offset indent
3801 It is neither callable nor parsed and takes no arguments.
3803 .It Li .Fr
3805 .Dl Usage: .Fr Ao function return value Ac ...
3807 Don't use this macro.
3808 It allows a break right before the return value (usually a single digit)
3809 which is bad typographical behaviour.
3811 .Ql \e\[ti]
3812 to tie the return value to the previous word.
3814 .It Li .Hf
3815 Use this macro to include a (header) file literally.
3816 It first prints
3817 .Ql File:
3818 followed by the file name, then the contents of
3819 .Ao file Ac .
3821 .Dl Usage: .Hf Ao file Ac
3823 It is neither callable nor parsed.
3825 .It Li .Lk
3826 To be written.
3828 .It Li .Me
3829 Exact usage unknown.
3830 The documentation in the
3831 .Nm \-mdoc
3832 source file describes it as a macro for
3833 .Dq "menu entries" .
3835 Its default width is 6n.
3837 .It Li .Mt
3838 To be written.
3840 .It Li .Ot
3841 Exact usage unknown.
3842 The documentation in the
3843 .Nm \-mdoc
3844 source file describes it as
3845 .Dq old function type (fortran) .
3847 .It Li .Sm
3848 Activate (toggle) space mode.
3850 .Dl Usage: .Sm Oo on | off Oc ...
3852 If space mode is off, no spaces between macro arguments are inserted.
3853 If called without a parameter (or if the next parameter is neither
3854 .Ql on
3856 .Ql off ,
3857 .Ql .Sm
3858 toggles space mode.
3860 .It Li .Ud
3861 prints
3863 .Bd -ragged -offset indent
3867 It is neither callable nor parsed and takes no arguments.
3871 .Sh "PREDEFINED STRINGS"
3873 The following strings are predefined:
3876 lb lb lb lb
3877 l l l l.
3878 String  Nroff   Troff   Meaning
3879 <=      <=      \*[<=]  less equal
3880 >=      >=      \*[>=]  greater equal
3881 Rq      ''      \*[Rq]  right double quote
3882 Lq      ``      \*[Lq]  left double quote
3883 ua      ^       \*[ua]  upwards arrow
3884 aa      \'      \*[aa]  acute accent
3885 ga      \`      \*[ga]  grave accent
3886 q       \&"     \*[q]   straight double quote
3887 Pi      pi      \*[Pi]  greek pi
3888 Ne      !=      \*[Ne]  not equal
3889 Le      <=      \*[Le]  less equal
3890 Ge      >=      \*[Ge]  greater equal
3891 Lt      <       \*[Lt]  less than
3892 Gt      >       \*[Gt]  greater than
3893 Pm      +\-     \*[Pm]  plus minus
3894 If      infinity        \*[If]  infinity
3895 Am      \*[Am]  \*[Am]  ampersand
3896 Na      \*[Na]  \*[Na]  not a number
3897 Ba      \*[Ba]  \*[Ba]  vertical bar
3900 The names of the columns
3901 .Sy Nroff
3903 .Sy Troff
3904 are a bit misleading;
3905 .Sy Nroff
3906 shows the
3907 .Tn ASCII
3908 representation, while
3909 .Sy Troff
3910 gives the best glyph form available.
3911 For example, a Unicode enabled
3912 .Tn TTY Ns - Ns
3913 device will have proper glyph representations for all strings, whereas the
3914 enhancement for a Latin1
3915 .Tn TTY Ns - Ns
3916 device is only the plus-minus sign.
3918 String names which consist of two characters can be written as
3919 .Ql \e*(xx ;
3920 string names which consist of one character can be written as
3921 .Ql \e*x .
3922 A generic syntax for a string name of any length is
3923 .Ql \e*[xxx]
3924 (this is a
3925 .Xr @T_TROFF@ 1
3926 extension).
3929 .Sh DIAGNOSTICS
3931 The debugging macro
3932 .Ql .Db
3933 available in previous versions of
3934 .Nm \-mdoc
3935 has been removed since
3936 .Xr @T_TROFF@ 1
3937 provides better facilities to check parameters; additionally, many error and
3938 warning messages have been added to this macro package, making it both more
3939 robust and verbose.
3941 The only remaining debugging macro is
3942 .Ql .Rd
3943 which yields a register dump of all global registers and strings.
3944 A normal user will never need it.
3947 .Sh "FORMATTING WITH @U_ROFF@, TROFF, AND NROFF"
3949 By default, the package inhibits page breaks, headers, and footers if
3950 displayed with a
3951 .Tn TTY
3952 device like
3953 .Sq latin1
3955 .Sq unicode ,
3956 to make the manual more efficient for viewing on-line.
3957 This behaviour can be changed (e.g.\& to create a hardcopy of the
3958 .Tn TTY
3959 output) by setting the register
3960 .Ql cR
3961 to zero while calling
3962 .Xr @L_ROFF@ 1 ,
3963 resulting in multiple pages instead of a single, very long page:
3965 .Dl @L_ROFF@ \-Tlatin1 \-rcR=0 \-mdoc foo.man > foo.txt
3967 For double-sided printing, set register
3968 .Ql D
3969 to\~1:
3971 .Dl @L_ROFF@ \-Tps \-rD1 \-mdoc foo.man > foo.ps
3973 To change the document font size to 11pt or 12pt, set register
3974 .Ql S
3975 accordingly:
3977 .Dl @L_ROFF@ \-Tdvi \-rS11 \-mdoc foo.man > foo.dvi
3979 Register
3980 .Ql S
3981 is ignored for
3982 .Tn TTY
3983 devices.
3985 The line and title length can be changed by setting the registers
3986 .Ql LL
3988 .Ql LT ,
3989 respectively:
3991 .Dl @L_ROFF@ \-Tutf8 \-rLL=100n \-rLT=100n \-mdoc foo.man | less
3993 If not set, both registers default to 78n for TTY devices and 6.5i
3994 otherwise.
3997 .Sh FILES
3999 .Bl -tag -width mdoc-ditroff -compact
4000 .It Pa doc.tmac
4001 The main manual macro package.
4002 .It Pa mdoc.tmac
4003 A wrapper file to call
4004 .Pa doc.tmac .
4005 .It Pa mdoc-common
4006 Common strings, definitions, stuff related typographic output.
4007 .It Pa mdoc-nroff
4008 Definitions used for a
4009 .Tn TTY
4010 output device.
4011 .It Pa mdoc-ditroff
4012 Definitions used for all other devices.
4013 .It Pa mdoc.local
4014 Local additions and customizations.
4015 .It Pa andoc.tmac
4016 Use this file if you don't know whether the
4017 .Nm \-mdoc
4018 or the
4019 .Nm \-man
4020 package should be used.
4021 Multiple man pages (in either format) can be handled.
4025 .Sh "SEE ALSO"
4027 .Xr @L_ROFF@ 1 ,
4028 .Xr man 1 ,
4029 .Xr @L_TROFF@ 1 ,
4030 .Xr @L_ROFF@_man 7
4033 .Sh BUGS
4035 Section 3f has not been added to the header routines.
4037 .Ql \&.Nm
4038 font should be changed in
4039 .Em NAME
4040 section.
4042 .Ql \&.Fn
4043 needs to have a check to prevent splitting up
4044 if the line length is too short.
4045 Occasionally it
4046 separates the last parenthesis, and sometimes
4047 looks ridiculous if a line is in fill mode.
4049 The list and display macros do not do any keeps
4050 and certainly should be able to.
4051 .\" Note what happens if the parameter list overlaps a newline
4052 .\" boundary.
4053 .\" to make sure a line boundary is crossed:
4054 .\" .Bd -literal
4055 .\" \&.Fn struct\e\ dictionarytable\e\ *dictionarylookup struct\e\ dictionarytable\e\ *tab[]
4056 .\" .Ed
4057 .\" .Pp
4058 .\" produces, nudge nudge,
4059 .\" .Fn struct\ dictionarytable\ *dictionarylookup char\ *h struct\ dictionarytable\ *tab[] ,
4060 .\" .Fn struct\ dictionarytable\ *dictionarylookup char\ *h struct\ dictionarytable\ *tab[] ,
4061 .\" nudge
4062 .\" .Fn struct\ dictionarytable\ *dictionarylookup char\ *h struct\ dictionarytable\ *tab[] .
4063 .\" .Pp
4064 .\" If double quotes are used, for example:
4065 .\" .Bd -literal
4066 .\" \&.Fn \*qstruct dictionarytable *dictionarylookup\*q \*qchar *h\*q \*qstruct dictionarytable *tab[]\*q
4067 .\" .Ed
4068 .\" .Pp
4069 .\" produces, nudge nudge,
4070 .\" .Fn "struct dictionarytable *dictionarylookup" "char *h" "struct dictionarytable *tab[]" ,
4071 .\" nudge
4072 .\" .Fn "struct dictionarytable *dictionarylookup" "char *h" "struct dictionarytable *tab[]" ,
4073 .\" nudge
4074 .\" .Fn "struct dictionarytable *dictionarylookup" "char *h" "struct dictionarytable *tab[]" .
4075 .\" .Pp
4076 .\" Not a pretty sight...
4077 .\" In a paragraph, a long parameter containing unpaddable spaces as
4078 .\" in the former example will cause
4079 .\" .Xr troff
4080 .\" to break the line and spread
4081 .\" the remaining words out.
4082 .\" The latter example will adjust nicely to
4083 .\" justified margins, but may break in between an argument and its
4084 .\" declaration.
4085 .\" In
4086 .\" .Xr nroff
4087 .\" the right margin adjustment is normally ragged and the problem is
4088 .\" not as severe.
4090 .\" s-ts-mode