[BACK]Return to mdoc.7 CVS log [TXT][DIR] Up to [cvsweb.bsd.lv] / mandoc

Annotation of mandoc/mdoc.7, Revision 1.205

1.205   ! kristaps    1: .\"    $Id: mdoc.7,v 1.204 2011/08/19 12:55:33 kristaps Exp $
1.1       kristaps    2: .\"
1.179     schwarze    3: .\" Copyright (c) 2009, 2010, 2011 Kristaps Dzonsons <kristaps@bsd.lv>
1.130     schwarze    4: .\" Copyright (c) 2010 Ingo Schwarze <schwarze@openbsd.org>
1.1       kristaps    5: .\"
                      6: .\" Permission to use, copy, modify, and distribute this software for any
1.22      kristaps    7: .\" purpose with or without fee is hereby granted, provided that the above
                      8: .\" copyright notice and this permission notice appear in all copies.
1.1       kristaps    9: .\"
1.22      kristaps   10: .\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
                     11: .\" WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
                     12: .\" MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
                     13: .\" ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
                     14: .\" WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
                     15: .\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
                     16: .\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
1.50      kristaps   17: .\"
1.204     kristaps   18: .Dd $Mdocdate: August 19 2011 $
1.20      kristaps   19: .Dt MDOC 7
1.1       kristaps   20: .Os
                     21: .Sh NAME
1.57      kristaps   22: .Nm mdoc
                     23: .Nd mdoc language reference
1.1       kristaps   24: .Sh DESCRIPTION
                     25: The
1.57      kristaps   26: .Nm mdoc
1.50      kristaps   27: language is used to format
1.57      kristaps   28: .Bx
                     29: .Ux
1.138     kristaps   30: manuals.
1.144     schwarze   31: This reference document describes its syntax, structure, and
1.138     kristaps   32: usage.
1.200     kristaps   33: The reference implementation for
                     34: .Nm
                     35: formatting is
1.144     schwarze   36: .Xr mandoc 1 ;
                     37: the
1.57      kristaps   38: .Sx COMPATIBILITY
1.200     kristaps   39: section describes compatibility with other implementations.
1.57      kristaps   40: .Pp
1.13      kristaps   41: An
1.57      kristaps   42: .Nm
1.118     kristaps   43: document follows simple rules: lines beginning with the control
1.50      kristaps   44: character
1.185     kristaps   45: .Sq \&.
1.138     kristaps   46: are parsed for macros.
1.200     kristaps   47: Lines not beginning with the control character are
1.185     kristaps   48: interpreted within the scope of prior macros:
1.57      kristaps   49: .Bd -literal -offset indent
1.13      kristaps   50: \&.Sh Macro lines change control state.
1.185     kristaps   51: Text lines are interpreted within the current state.
1.57      kristaps   52: .Ed
1.46      kristaps   53: .Sh LANGUAGE SYNTAX
1.57      kristaps   54: .Nm
1.13      kristaps   55: documents may contain only graphable 7-bit ASCII characters, the space
1.138     kristaps   56: character, and, in certain circumstances, the tab character.
1.200     kristaps   57: The back-space character
                     58: .Sq \e
                     59: indicates the start of an escape sequence for
                     60: .Sx Comments ,
                     61: .Sx Predefined Strings ,
                     62: and
                     63: .Sx Special Characters .
1.57      kristaps   64: .Ss Comments
1.200     kristaps   65: Text following an escaped double-quote
1.203     kristaps   66: .Sq \e\(dq ,
1.185     kristaps   67: whether in a macro or text line, is ignored to the end of
1.138     kristaps   68: line.
1.200     kristaps   69: A macro line beginning with a control character and comment escape
1.203     kristaps   70: .Sq \&.\e\(dq
1.138     kristaps   71: is also ignored.
1.200     kristaps   72: Furthermore,
                     73: macro lines with only a control character and optional trailing
                     74: whitespace are
1.138     kristaps   75: stripped from input.
1.201     kristaps   76: .Pp
                     77: Examples:
                     78: .Bd -literal -offset indent -compact
1.203     kristaps   79: \&.\e\(dq This is a comment line.
                     80: \&.\e\(dq The next line is ignored:
1.201     kristaps   81: \&.
1.203     kristaps   82: \&.Em Emphasis \e\(dq This is also a comment.
1.201     kristaps   83: .Ed
1.57      kristaps   84: .Ss Special Characters
1.200     kristaps   85: Special characters are used to encode special glyphs and are rendered
                     86: differently across output media.
                     87: They may occur in both macro and text lines.
1.43      kristaps   88: Sequences begin with the escape character
1.57      kristaps   89: .Sq \e
1.50      kristaps   90: followed by either an open-parenthesis
1.57      kristaps   91: .Sq \&(
1.1       kristaps   92: for two-character sequences; an open-bracket
1.57      kristaps   93: .Sq \&[
1.1       kristaps   94: for n-character sequences (terminated at a close-bracket
1.57      kristaps   95: .Sq \&] ) ;
1.144     schwarze   96: or a single one character sequence.
1.200     kristaps   97: .Pp
                     98: Examples:
                     99: .Bl -tag -width Ds -offset indent -compact
1.203     kristaps  100: .It Li \e(em
1.204     kristaps  101: Two-letter em dash escape.
1.203     kristaps  102: .It Li \ee
1.204     kristaps  103: One-letter backslash escape.
1.200     kristaps  104: .El
                    105: .Pp
1.100     kristaps  106: See
1.57      kristaps  107: .Xr mandoc_char 7
1.100     kristaps  108: for a complete list.
1.57      kristaps  109: .Ss Text Decoration
1.54      kristaps  110: Terms may be text-decorated using the
1.57      kristaps  111: .Sq \ef
1.200     kristaps  112: escape followed by an indicator: B (bold), I (italic), R (regular), or P
                    113: (revert to previous mode).
                    114: A numerical representation 3, 2, or 1 (bold, italic, and regular,
1.100     kristaps  115: respectively) may be used instead.
1.185     kristaps  116: If a macro opens a font scope after calling
                    117: .Sq \ef ,
                    118: such as with
                    119: .Sx \&Bf ,
                    120: the
                    121: .Sq \ef
                    122: mode will be restored upon exiting the
1.78      kristaps  123: .Sx \&Bf
1.185     kristaps  124: scope.
1.76      kristaps  125: .Pp
1.200     kristaps  126: Examples:
                    127: .Bl -tag -width Ds -offset indent -compact
1.203     kristaps  128: .It Li \efBbold\efR
1.204     kristaps  129: Write in bold, then switch to regular font mode.
1.203     kristaps  130: .It Li \efIitalic\efP
1.204     kristaps  131: Write in italic, then return to previous font mode.
1.200     kristaps  132: .El
                    133: .Pp
                    134: Text decoration is
1.76      kristaps  135: .Em not
1.82      kristaps  136: recommended for
1.57      kristaps  137: .Nm ,
1.74      kristaps  138: which encourages semantic annotation.
1.57      kristaps  139: .Ss Predefined Strings
1.200     kristaps  140: Predefined strings, like
1.57      kristaps  141: .Sx Special Characters ,
1.200     kristaps  142: mark special output glyphs.
1.54      kristaps  143: Predefined strings are escaped with the slash-asterisk,
1.57      kristaps  144: .Sq \e* :
1.54      kristaps  145: single-character
1.57      kristaps  146: .Sq \e*X ,
1.54      kristaps  147: two-character
1.57      kristaps  148: .Sq \e*(XX ,
1.54      kristaps  149: and N-character
1.57      kristaps  150: .Sq \e*[N] .
1.200     kristaps  151: .Pp
                    152: Examples:
                    153: .Bl -tag -width Ds -offset indent -compact
1.203     kristaps  154: .It Li \e*(Am
1.204     kristaps  155: Two-letter ampersand predefined string.
                    156: .It Li \e*q
                    157: One-letter double-quote predefined string.
1.200     kristaps  158: .El
                    159: .Pp
                    160: These strings are set using
                    161: .Xr roff 7 ,
                    162: although
                    163: .Nm
                    164: consists of several pre-set escapes listed in
                    165: .Xr mandoc_char 7 .
1.57      kristaps  166: .Ss Whitespace
1.98      kristaps  167: Whitespace consists of the space character.
1.200     kristaps  168: In text lines, whitespace is preserved within a line.
                    169: In macro lines, whitespace delimits arguments and is discarded.
1.57      kristaps  170: .Pp
1.200     kristaps  171: Unescaped trailing spaces are stripped from text line input unless in a
                    172: literal context.
                    173: In general, trailing whitespace on any input line is discouraged for
                    174: reasons of portability.
1.194     schwarze  175: In the rare case that a blank character is needed at the end of an
                    176: input line, it may be forced by
                    177: .Sq \e\ \e& .
                    178: .Pp
1.205   ! kristaps  179: In general, space characters can be rendered as literal
1.203     kristaps  180: characters by using non-breaking space escapes or
                    181: .Sx Quotation .
                    182: .Pp
1.200     kristaps  183: Blank text lines, which may include whitespace, are only permitted
                    184: within literal contexts.
                    185: If the first character of a text line is a space, that line is printed
                    186: with a leading newline.
1.57      kristaps  187: .Ss Quotation
1.203     kristaps  188: Macro arguments may be quoted with double-quotes to so that the
                    189: enclosed text is one literal term.
                    190: Quoted text, even if whitespace or if it would cause a macro invocation
                    191: when unquoted, is considered literal text.
1.194     schwarze  192: .Pp
1.100     kristaps  193: A quoted argument begins with a double-quote preceded by whitespace.
1.144     schwarze  194: The next double-quote not pairwise adjacent to another double-quote
1.100     kristaps  195: terminates the literal, regardless of surrounding whitespace.
1.57      kristaps  196: .Pp
1.203     kristaps  197: Examples:
                    198: .Bl -tag -width Ds -offset indent -compact
                    199: .It Li .Fn strlen \(dqconst char *s\(dq
1.204     kristaps  200: Group arguments
1.203     kristaps  201: .Qq const char *s
1.205   ! kristaps  202: into one function argument.
1.204     kristaps  203: If unspecified,
                    204: .Qq const ,
                    205: .Qq char ,
                    206: and
                    207: .Qq *s
                    208: would be considered separate arguments.
                    209: .Pq See Sx \&Fn .
1.203     kristaps  210: .It Li .Op \(dqFl a\(dq
1.204     kristaps  211: Consider
1.203     kristaps  212: .Qq \&Fl a
1.204     kristaps  213: as literal text instead of a flag macro.
                    214: .Pq Aee Sx \&Op , \&Fl .
1.203     kristaps  215: .El
1.61      kristaps  216: .Ss Scaling Widths
1.200     kristaps  217: Many macros support scaled widths for their arguments.
                    218: The syntax for a scaled width is
1.62      kristaps  219: .Sq Li [+-]?[0-9]*.[0-9]*[:unit:] ,
1.61      kristaps  220: where a decimal must be preceded or proceeded by at least one digit.
1.100     kristaps  221: Negative numbers, while accepted, are truncated to zero.
1.200     kristaps  222: .Pp
1.100     kristaps  223: The following scaling units are accepted:
1.61      kristaps  224: .Pp
                    225: .Bl -tag -width Ds -offset indent -compact
                    226: .It c
                    227: centimetre
                    228: .It i
                    229: inch
                    230: .It P
                    231: pica (~1/6 inch)
                    232: .It p
                    233: point (~1/72 inch)
                    234: .It f
                    235: synonym for
                    236: .Sq u
                    237: .It v
                    238: default vertical span
                    239: .It m
                    240: width of rendered
                    241: .Sq m
                    242: .Pq em
                    243: character
                    244: .It n
                    245: width of rendered
                    246: .Sq n
                    247: .Pq en
                    248: character
                    249: .It u
                    250: default horizontal span
                    251: .It M
                    252: mini-em (~1/100 em)
                    253: .El
                    254: .Pp
                    255: Using anything other than
                    256: .Sq m ,
                    257: .Sq n ,
                    258: .Sq u ,
                    259: or
                    260: .Sq v
1.100     kristaps  261: is necessarily non-portable across output media.
                    262: See
1.61      kristaps  263: .Sx COMPATIBILITY .
1.200     kristaps  264: .Pp
                    265: Examples:
                    266: .Bl -tag -width Ds -offset indent -compact
1.203     kristaps  267: .It Li \&.Bl -tag -width 2i
1.200     kristaps  268: two-inch tagged list indentation
                    269: .Pq see Sx \&Bl
1.203     kristaps  270: .It Li \&.sp 2v
1.200     kristaps  271: two vertical spaces
1.201     kristaps  272: .Pq see Sx \&sp
1.200     kristaps  273: .El
1.101     kristaps  274: .Ss Sentence Spacing
1.200     kristaps  275: Sentences should terminate at the end of an input line.
                    276: By doing this, a formatter will be able to apply the proper amount of
1.101     kristaps  277: spacing after the end of sentence (unescaped) period, exclamation mark,
1.107     kristaps  278: or question mark followed by zero or more non-sentence closing
1.179     schwarze  279: delimiters
                    280: .Po
                    281: .Sq \&) ,
1.107     kristaps  282: .Sq \&] ,
                    283: .Sq \&' ,
1.179     schwarze  284: .Sq \&"
                    285: .Pc .
1.102     kristaps  286: .Pp
                    287: The proper spacing is also intelligently preserved if a sentence ends at
1.144     schwarze  288: the boundary of a macro line.
1.107     kristaps  289: .Pp
1.200     kristaps  290: Examples:
                    291: .Bd -literal -offset indent -compact
                    292: Do not end sentences mid-line like this.  Instead,
                    293: end a sentence like this.
                    294: A macro would end like this:
                    295: \&.Xr mandoc 1 \&.
                    296: .Ed
1.43      kristaps  297: .Sh MANUAL STRUCTURE
1.66      kristaps  298: A well-formed
1.57      kristaps  299: .Nm
1.66      kristaps  300: document consists of a document prologue followed by one or more
                    301: sections.
                    302: .Pp
1.141     kristaps  303: The prologue, which consists of the
1.64      kristaps  304: .Sx \&Dd ,
                    305: .Sx \&Dt ,
1.33      kristaps  306: and
1.66      kristaps  307: .Sx \&Os
1.141     kristaps  308: macros in that order, is required for every document.
1.66      kristaps  309: .Pp
1.82      kristaps  310: The first section (sections are denoted by
1.66      kristaps  311: .Sx \&Sh )
                    312: must be the NAME section, consisting of at least one
1.64      kristaps  313: .Sx \&Nm
1.50      kristaps  314: followed by
1.66      kristaps  315: .Sx \&Nd .
                    316: .Pp
1.122     kristaps  317: Following that, convention dictates specifying at least the
                    318: .Em SYNOPSIS
                    319: and
                    320: .Em DESCRIPTION
                    321: sections, although this varies between manual sections.
1.66      kristaps  322: .Pp
                    323: The following is a well-formed skeleton
                    324: .Nm
1.188     kristaps  325: file for a utility
                    326: .Qq progname :
1.57      kristaps  327: .Bd -literal -offset indent
1.43      kristaps  328: \&.Dd $\&Mdocdate$
1.188     kristaps  329: \&.Dt PROGNAME section
1.43      kristaps  330: \&.Os
                    331: \&.Sh NAME
1.188     kristaps  332: \&.Nm progname
1.194     schwarze  333: \&.Nd one line about what it does
1.203     kristaps  334: \&.\e\(dq .Sh LIBRARY
                    335: \&.\e\(dq For sections 2, 3, & 9 only.
                    336: \&.\e\(dq Not used in OpenBSD.
1.58      kristaps  337: \&.Sh SYNOPSIS
1.188     kristaps  338: \&.Nm progname
1.58      kristaps  339: \&.Op Fl options
                    340: \&.Ar
                    341: \&.Sh DESCRIPTION
                    342: The
                    343: \&.Nm
                    344: utility processes files ...
1.203     kristaps  345: \&.\e\(dq .Sh IMPLEMENTATION NOTES
                    346: \&.\e\(dq Not used in OpenBSD.
                    347: \&.\e\(dq .Sh RETURN VALUES
                    348: \&.\e\(dq For sections 2, 3, & 9 only.
                    349: \&.\e\(dq .Sh ENVIRONMENT
                    350: \&.\e\(dq For sections 1, 6, 7, & 8 only.
                    351: \&.\e\(dq .Sh FILES
                    352: \&.\e\(dq .Sh EXIT STATUS
                    353: \&.\e\(dq For sections 1, 6, & 8 only.
                    354: \&.\e\(dq .Sh EXAMPLES
                    355: \&.\e\(dq .Sh DIAGNOSTICS
                    356: \&.\e\(dq For sections 1, 4, 6, 7, & 8 only.
                    357: \&.\e\(dq .Sh ERRORS
                    358: \&.\e\(dq For sections 2, 3, & 9 only.
                    359: \&.\e\(dq .Sh SEE ALSO
                    360: \&.\e\(dq .Xr foobar 1
                    361: \&.\e\(dq .Sh STANDARDS
                    362: \&.\e\(dq .Sh HISTORY
                    363: \&.\e\(dq .Sh AUTHORS
                    364: \&.\e\(dq .Sh CAVEATS
                    365: \&.\e\(dq .Sh BUGS
                    366: \&.\e\(dq .Sh SECURITY CONSIDERATIONS
                    367: \&.\e\(dq Not used in OpenBSD.
1.57      kristaps  368: .Ed
                    369: .Pp
1.144     schwarze  370: The sections in an
1.66      kristaps  371: .Nm
1.100     kristaps  372: document are conventionally ordered as they appear above.
                    373: Sections should be composed as follows:
1.73      kristaps  374: .Bl -ohang -offset Ds
                    375: .It Em NAME
1.144     schwarze  376: The name(s) and a one line description of the documented material.
1.100     kristaps  377: The syntax for this as follows:
1.73      kristaps  378: .Bd -literal -offset indent
1.144     schwarze  379: \&.Nm name0 ,
                    380: \&.Nm name1 ,
1.73      kristaps  381: \&.Nm name2
1.144     schwarze  382: \&.Nd a one line description
1.73      kristaps  383: .Ed
                    384: .Pp
1.185     kristaps  385: Multiple
                    386: .Sq \&Nm
                    387: names should be separated by commas.
                    388: .Pp
1.73      kristaps  389: The
1.66      kristaps  390: .Sx \&Nm
1.73      kristaps  391: macro(s) must precede the
                    392: .Sx \&Nd
                    393: macro.
1.80      kristaps  394: .Pp
1.82      kristaps  395: See
1.80      kristaps  396: .Sx \&Nm
                    397: and
                    398: .Sx \&Nd .
1.73      kristaps  399: .It Em LIBRARY
                    400: The name of the library containing the documented material, which is
1.108     kristaps  401: assumed to be a function in a section 2, 3, or 9 manual.
1.100     kristaps  402: The syntax for this is as follows:
1.73      kristaps  403: .Bd -literal -offset indent
                    404: \&.Lb libarm
                    405: .Ed
                    406: .Pp
                    407: See
1.80      kristaps  408: .Sx \&Lb .
1.73      kristaps  409: .It Em SYNOPSIS
                    410: Documents the utility invocation syntax, function call syntax, or device
1.82      kristaps  411: configuration.
1.73      kristaps  412: .Pp
                    413: For the first, utilities (sections 1, 6, and 8), this is
                    414: generally structured as follows:
                    415: .Bd -literal -offset indent
1.185     kristaps  416: \&.Nm bar
1.73      kristaps  417: \&.Op Fl v
                    418: \&.Op Fl o Ar file
                    419: \&.Op Ar
1.185     kristaps  420: \&.Nm foo
1.73      kristaps  421: \&.Op Fl v
                    422: \&.Op Fl o Ar file
                    423: \&.Op Ar
                    424: .Ed
                    425: .Pp
1.185     kristaps  426: Commands should be ordered alphabetically.
                    427: .Pp
1.73      kristaps  428: For the second, function calls (sections 2, 3, 9):
                    429: .Bd -literal -offset indent
1.146     kristaps  430: \&.In header.h
1.73      kristaps  431: \&.Vt extern const char *global;
                    432: \&.Ft "char *"
                    433: \&.Fn foo "const char *src"
                    434: \&.Ft "char *"
                    435: \&.Fn bar "const char *src"
                    436: .Ed
                    437: .Pp
1.185     kristaps  438: Ordering of
                    439: .Sx \&In ,
                    440: .Sx \&Vt ,
                    441: .Sx \&Fn ,
                    442: and
                    443: .Sx \&Fo
                    444: macros should follow C header-file conventions.
                    445: .Pp
1.73      kristaps  446: And for the third, configurations (section 4):
                    447: .Bd -literal -offset indent
1.203     kristaps  448: \&.Cd \(dqit* at isa? port 0x2e\(dq
                    449: \&.Cd \(dqit* at isa? port 0x4e\(dq
1.73      kristaps  450: .Ed
                    451: .Pp
1.82      kristaps  452: Manuals not in these sections generally don't need a
1.73      kristaps  453: .Em SYNOPSIS .
1.80      kristaps  454: .Pp
1.122     kristaps  455: Some macros are displayed differently in the
                    456: .Em SYNOPSIS
                    457: section, particularly
                    458: .Sx \&Nm ,
1.80      kristaps  459: .Sx \&Cd ,
1.122     kristaps  460: .Sx \&Fd ,
                    461: .Sx \&Fn ,
                    462: .Sx \&Fo ,
                    463: .Sx \&In ,
                    464: .Sx \&Vt ,
                    465: and
                    466: .Sx \&Ft .
1.138     kristaps  467: All of these macros are output on their own line.
1.144     schwarze  468: If two such dissimilar macros are pairwise invoked (except for
1.122     kristaps  469: .Sx \&Ft
                    470: before
                    471: .Sx \&Fo
                    472: or
1.123     kristaps  473: .Sx \&Fn ) ,
1.122     kristaps  474: they are separated by a vertical space, unless in the case of
                    475: .Sx \&Fo ,
1.80      kristaps  476: .Sx \&Fn ,
1.122     kristaps  477: and
1.80      kristaps  478: .Sx \&Ft ,
1.122     kristaps  479: which are always separated by vertical space.
1.128     schwarze  480: .Pp
                    481: When text and macros following an
                    482: .Sx \&Nm
                    483: macro starting an input line span multiple output lines,
                    484: all output lines but the first will be indented to align
                    485: with the text immediately following the
                    486: .Sx \&Nm
                    487: macro, up to the next
                    488: .Sx \&Nm ,
1.141     kristaps  489: .Sx \&Sh ,
1.128     schwarze  490: or
                    491: .Sx \&Ss
                    492: macro or the end of an enclosing block, whichever comes first.
1.73      kristaps  493: .It Em DESCRIPTION
1.185     kristaps  494: This begins with an expansion of the brief, one line description in
                    495: .Em NAME :
                    496: .Bd -literal -offset indent
                    497: The
                    498: \&.Nm
                    499: utility does this, that, and the other.
                    500: .Ed
                    501: .Pp
                    502: It usually follows with a breakdown of the options (if documenting a
1.73      kristaps  503: command), such as:
                    504: .Bd -literal -offset indent
                    505: The arguments are as follows:
                    506: \&.Bl \-tag \-width Ds
                    507: \&.It Fl v
                    508: Print verbose information.
                    509: \&.El
                    510: .Ed
1.80      kristaps  511: .Pp
1.73      kristaps  512: Manuals not documenting a command won't include the above fragment.
1.198     schwarze  513: .Pp
                    514: Since the
                    515: .Em DESCRIPTION
                    516: section usually contains most of the text of a manual, longer manuals
                    517: often use the
                    518: .Sx \&Ss
                    519: macro to form subsections.
                    520: In very long manuals, the
                    521: .Em DESCRIPTION
                    522: may be split into multiple sections, each started by an
                    523: .Sx \&Sh
                    524: macro followed by a non-standard section name, and each having
                    525: several subsections, like in the present
                    526: .Nm
                    527: manual.
1.73      kristaps  528: .It Em IMPLEMENTATION NOTES
1.100     kristaps  529: Implementation-specific notes should be kept here.
                    530: This is useful when implementing standard functions that may have side
                    531: effects or notable algorithmic implications.
1.73      kristaps  532: .It Em RETURN VALUES
1.144     schwarze  533: This section documents the
                    534: return values of functions in sections 2, 3, and 9.
1.73      kristaps  535: .Pp
                    536: See
                    537: .Sx \&Rv .
                    538: .It Em ENVIRONMENT
1.141     kristaps  539: Lists the environment variables used by the utility,
                    540: and explains the syntax and semantics of their values.
                    541: The
                    542: .Xr environ 7
                    543: manual provides examples of typical content and formatting.
1.73      kristaps  544: .Pp
                    545: See
                    546: .Sx \&Ev .
                    547: .It Em FILES
1.100     kristaps  548: Documents files used.
1.141     kristaps  549: It's helpful to document both the file name and a short description of how
1.100     kristaps  550: the file is used (created, modified, etc.).
1.73      kristaps  551: .Pp
                    552: See
                    553: .Sx \&Pa .
1.99      kristaps  554: .It Em EXIT STATUS
1.144     schwarze  555: This section documents the
                    556: command exit status for section 1, 6, and 8 utilities.
1.100     kristaps  557: Historically, this information was described in
1.99      kristaps  558: .Em DIAGNOSTICS ,
                    559: a practise that is now discouraged.
                    560: .Pp
                    561: See
                    562: .Sx \&Ex .
1.73      kristaps  563: .It Em EXAMPLES
1.100     kristaps  564: Example usages.
                    565: This often contains snippets of well-formed, well-tested invocations.
1.144     schwarze  566: Make sure that examples work properly!
1.73      kristaps  567: .It Em DIAGNOSTICS
1.100     kristaps  568: Documents error conditions.
                    569: This is most useful in section 4 manuals.
1.73      kristaps  570: Historically, this section was used in place of
                    571: .Em EXIT STATUS
                    572: for manuals in sections 1, 6, and 8; however, this practise is
                    573: discouraged.
                    574: .Pp
                    575: See
1.80      kristaps  576: .Sx \&Bl
                    577: .Fl diag .
1.73      kristaps  578: .It Em ERRORS
                    579: Documents error handling in sections 2, 3, and 9.
                    580: .Pp
                    581: See
                    582: .Sx \&Er .
                    583: .It Em SEE ALSO
1.100     kristaps  584: References other manuals with related topics.
                    585: This section should exist for most manuals.
                    586: Cross-references should conventionally be ordered first by section, then
                    587: alphabetically.
1.73      kristaps  588: .Pp
1.198     schwarze  589: References to other documentation concerning the topic of the manual page,
                    590: for example authoritative books or journal articles, may also be
                    591: provided in this section.
                    592: .Pp
1.73      kristaps  593: See
1.198     schwarze  594: .Sx \&Rs
                    595: and
1.73      kristaps  596: .Sx \&Xr .
                    597: .It Em STANDARDS
1.100     kristaps  598: References any standards implemented or used.
                    599: If not adhering to any standards, the
1.73      kristaps  600: .Em HISTORY
                    601: section should be used instead.
                    602: .Pp
                    603: See
                    604: .Sx \&St .
                    605: .It Em HISTORY
1.198     schwarze  606: A brief history of the subject, including where it was first implemented,
                    607: and when it was ported to or reimplemented for the operating system at hand.
1.73      kristaps  608: .It Em AUTHORS
1.143     schwarze  609: Credits to the person or persons who wrote the code and/or documentation.
1.141     kristaps  610: Authors should generally be noted by both name and email address.
1.73      kristaps  611: .Pp
                    612: See
                    613: .Sx \&An .
                    614: .It Em CAVEATS
1.141     kristaps  615: Common misuses and misunderstandings should be explained
1.73      kristaps  616: in this section.
                    617: .It Em BUGS
1.147     kristaps  618: Known bugs, limitations, and work-arounds should be described
1.141     kristaps  619: in this section.
1.73      kristaps  620: .It Em SECURITY CONSIDERATIONS
                    621: Documents any security precautions that operators should consider.
1.66      kristaps  622: .El
1.43      kristaps  623: .Sh MACRO SYNTAX
1.56      kristaps  624: Macros are one to three three characters in length and begin with a
1.141     kristaps  625: control character,
1.57      kristaps  626: .Sq \&. ,
1.100     kristaps  627: at the beginning of the line.
                    628: An arbitrary amount of whitespace may sit between the control character
                    629: and the macro name.
                    630: Thus, the following are equivalent:
1.64      kristaps  631: .Bd -literal -offset indent
                    632: \&.Pp
                    633: \&.\ \ \ \&Pp
                    634: .Ed
1.57      kristaps  635: .Pp
1.100     kristaps  636: The syntax of a macro depends on its classification.
                    637: In this section,
1.57      kristaps  638: .Sq \-arg
1.43      kristaps  639: refers to macro arguments, which may be followed by zero or more
1.57      kristaps  640: .Sq parm
1.43      kristaps  641: parameters;
1.57      kristaps  642: .Sq \&Yo
1.43      kristaps  643: opens the scope of a macro; and if specified,
1.57      kristaps  644: .Sq \&Yc
1.43      kristaps  645: closes it out.
1.57      kristaps  646: .Pp
1.43      kristaps  647: The
1.57      kristaps  648: .Em Callable
1.166     schwarze  649: column indicates that the macro may also be called by passing its name
                    650: as an argument to another macro.
1.194     schwarze  651: For example,
                    652: .Sq \&.Op \&Fl O \&Ar file
                    653: produces
                    654: .Sq Op Fl O Ar file .
                    655: To prevent a macro call and render the macro name literally,
1.195     schwarze  656: escape it by prepending a zero-width space,
1.194     schwarze  657: .Sq \e& .
                    658: For example,
                    659: .Sq \&Op \e&Fl O
                    660: produces
                    661: .Sq Op \&Fl O .
1.166     schwarze  662: If a macro is not callable but its name appears as an argument
                    663: to another macro, it is interpreted as opaque text.
                    664: For example,
1.60      kristaps  665: .Sq \&.Fl \&Sh
1.55      kristaps  666: produces
1.60      kristaps  667: .Sq Fl \&Sh .
1.57      kristaps  668: .Pp
1.55      kristaps  669: The
1.141     kristaps  670: .Em Parsed
1.166     schwarze  671: column indicates whether the macro may call other macros by receiving
                    672: their names as arguments.
                    673: If a macro is not parsed but the name of another macro appears
                    674: as an argument, it is interpreted as opaque text.
1.57      kristaps  675: .Pp
1.55      kristaps  676: The
1.57      kristaps  677: .Em Scope
1.43      kristaps  678: column, if applicable, describes closure rules.
1.57      kristaps  679: .Ss Block full-explicit
1.100     kristaps  680: Multi-line scope closed by an explicit closing macro.
                    681: All macros contains bodies; only
1.64      kristaps  682: .Sx \&Bf
1.185     kristaps  683: and
                    684: .Pq optionally
                    685: .Sx \&Bl
                    686: contain a head.
1.57      kristaps  687: .Bd -literal -offset indent
1.50      kristaps  688: \&.Yo \(lB\-arg \(lBparm...\(rB\(rB \(lBhead...\(rB
                    689: \(lBbody...\(rB
1.43      kristaps  690: \&.Yc
1.57      kristaps  691: .Ed
                    692: .Pp
1.141     kristaps  693: .Bl -column -compact -offset indent "MacroX" "CallableX" "ParsedX" "closed by XXX"
                    694: .It Em Macro Ta Em Callable Ta Em Parsed Ta Em Scope
1.64      kristaps  695: .It Sx \&Bd  Ta    \&No     Ta    \&No     Ta    closed by Sx \&Ed
                    696: .It Sx \&Bf  Ta    \&No     Ta    \&No     Ta    closed by Sx \&Ef
                    697: .It Sx \&Bk  Ta    \&No     Ta    \&No     Ta    closed by Sx \&Ek
                    698: .It Sx \&Bl  Ta    \&No     Ta    \&No     Ta    closed by Sx \&El
                    699: .It Sx \&Ed  Ta    \&No     Ta    \&No     Ta    opened by Sx \&Bd
                    700: .It Sx \&Ef  Ta    \&No     Ta    \&No     Ta    opened by Sx \&Bf
                    701: .It Sx \&Ek  Ta    \&No     Ta    \&No     Ta    opened by Sx \&Bk
                    702: .It Sx \&El  Ta    \&No     Ta    \&No     Ta    opened by Sx \&Bl
1.57      kristaps  703: .El
                    704: .Ss Block full-implicit
1.43      kristaps  705: Multi-line scope closed by end-of-file or implicitly by another macro.
1.50      kristaps  706: All macros have bodies; some
1.57      kristaps  707: .Po
1.64      kristaps  708: .Sx \&It Fl bullet ,
                    709: .Fl hyphen ,
                    710: .Fl dash ,
                    711: .Fl enum ,
                    712: .Fl item
1.57      kristaps  713: .Pc
1.64      kristaps  714: don't have heads; only one
                    715: .Po
1.141     kristaps  716: .Sx \&It
                    717: in
                    718: .Sx \&Bl Fl column
1.82      kristaps  719: .Pc
1.64      kristaps  720: has multiple heads.
1.57      kristaps  721: .Bd -literal -offset indent
1.50      kristaps  722: \&.Yo \(lB\-arg \(lBparm...\(rB\(rB \(lBhead... \(lBTa head...\(rB\(rB
                    723: \(lBbody...\(rB
1.57      kristaps  724: .Ed
                    725: .Pp
1.141     kristaps  726: .Bl -column -compact -offset indent "MacroX" "CallableX" "ParsedX" "closed by XXXXXXXXXXX"
                    727: .It Em Macro Ta Em Callable Ta Em Parsed Ta Em Scope
1.197     kristaps  728: .It Sx \&It Ta \&No Ta Yes  Ta closed by Sx \&It , Sx \&El
                    729: .It Sx \&Nd Ta \&No Ta \&No Ta closed by Sx \&Sh
                    730: .It Sx \&Nm Ta \&No Ta Yes  Ta closed by Sx \&Nm , Sx \&Sh , Sx \&Ss
                    731: .It Sx \&Sh Ta \&No Ta Yes  Ta closed by Sx \&Sh
                    732: .It Sx \&Ss Ta \&No Ta Yes  Ta closed by Sx \&Sh , Sx \&Ss
1.57      kristaps  733: .El
1.128     schwarze  734: .Pp
                    735: Note that the
                    736: .Sx \&Nm
                    737: macro is a
                    738: .Sx Block full-implicit
                    739: macro only when invoked as the first macro
                    740: in a
                    741: .Em SYNOPSIS
                    742: section line, else it is
                    743: .Sx In-line .
1.57      kristaps  744: .Ss Block partial-explicit
1.100     kristaps  745: Like block full-explicit, but also with single-line scope.
                    746: Each has at least a body and, in limited circumstances, a head
1.64      kristaps  747: .Po
                    748: .Sx \&Fo ,
                    749: .Sx \&Eo
                    750: .Pc
1.50      kristaps  751: and/or tail
1.64      kristaps  752: .Pq Sx \&Ec .
1.57      kristaps  753: .Bd -literal -offset indent
1.50      kristaps  754: \&.Yo \(lB\-arg \(lBparm...\(rB\(rB \(lBhead...\(rB
                    755: \(lBbody...\(rB
                    756: \&.Yc \(lBtail...\(rB
1.2       kristaps  757:
1.43      kristaps  758: \&.Yo \(lB\-arg \(lBparm...\(rB\(rB \(lBhead...\(rB \
1.50      kristaps  759: \(lBbody...\(rB \&Yc \(lBtail...\(rB
1.57      kristaps  760: .Ed
                    761: .Pp
1.141     kristaps  762: .Bl -column "MacroX" "CallableX" "ParsedX" "closed by XXXX" -compact -offset indent
                    763: .It Em Macro Ta Em Callable Ta Em Parsed Ta Em Scope
1.64      kristaps  764: .It Sx \&Ac  Ta    Yes      Ta    Yes      Ta    opened by Sx \&Ao
1.63      kristaps  765: .It Sx \&Ao  Ta    Yes      Ta    Yes      Ta    closed by Sx \&Ac
1.64      kristaps  766: .It Sx \&Bc  Ta    Yes      Ta    Yes      Ta    closed by Sx \&Bo
                    767: .It Sx \&Bo  Ta    Yes      Ta    Yes      Ta    opened by Sx \&Bc
                    768: .It Sx \&Brc Ta    Yes      Ta    Yes      Ta    opened by Sx \&Bro
                    769: .It Sx \&Bro Ta    Yes      Ta    Yes      Ta    closed by Sx \&Brc
                    770: .It Sx \&Dc  Ta    Yes      Ta    Yes      Ta    opened by Sx \&Do
                    771: .It Sx \&Do  Ta    Yes      Ta    Yes      Ta    closed by Sx \&Dc
                    772: .It Sx \&Ec  Ta    Yes      Ta    Yes      Ta    opened by Sx \&Eo
                    773: .It Sx \&Eo  Ta    Yes      Ta    Yes      Ta    closed by Sx \&Ec
                    774: .It Sx \&Fc  Ta    Yes      Ta    Yes      Ta    opened by Sx \&Fo
                    775: .It Sx \&Fo  Ta    \&No     Ta    \&No     Ta    closed by Sx \&Fc
                    776: .It Sx \&Oc  Ta    Yes      Ta    Yes      Ta    closed by Sx \&Oo
                    777: .It Sx \&Oo  Ta    Yes      Ta    Yes      Ta    opened by Sx \&Oc
                    778: .It Sx \&Pc  Ta    Yes      Ta    Yes      Ta    closed by Sx \&Po
                    779: .It Sx \&Po  Ta    Yes      Ta    Yes      Ta    opened by Sx \&Pc
                    780: .It Sx \&Qc  Ta    Yes      Ta    Yes      Ta    opened by Sx \&Oo
                    781: .It Sx \&Qo  Ta    Yes      Ta    Yes      Ta    closed by Sx \&Oc
1.63      kristaps  782: .It Sx \&Re  Ta    \&No     Ta    \&No     Ta    opened by Sx \&Rs
                    783: .It Sx \&Rs  Ta    \&No     Ta    \&No     Ta    closed by Sx \&Re
1.64      kristaps  784: .It Sx \&Sc  Ta    Yes      Ta    Yes      Ta    opened by Sx \&So
                    785: .It Sx \&So  Ta    Yes      Ta    Yes      Ta    closed by Sx \&Sc
                    786: .It Sx \&Xc  Ta    Yes      Ta    Yes      Ta    opened by Sx \&Xo
                    787: .It Sx \&Xo  Ta    Yes      Ta    Yes      Ta    closed by Sx \&Xc
1.57      kristaps  788: .El
                    789: .Ss Block partial-implicit
1.195     schwarze  790: Like block full-implicit, but with single-line scope closed by the
                    791: end of the line.
1.57      kristaps  792: .Bd -literal -offset indent
1.43      kristaps  793: \&.Yo \(lB\-arg \(lBval...\(rB\(rB \(lBbody...\(rB \(lBres...\(rB
1.57      kristaps  794: .Ed
                    795: .Pp
1.141     kristaps  796: .Bl -column "MacroX" "CallableX" "ParsedX" -compact -offset indent
                    797: .It Em Macro Ta Em Callable Ta Em Parsed
1.64      kristaps  798: .It Sx \&Aq  Ta    Yes      Ta    Yes
                    799: .It Sx \&Bq  Ta    Yes      Ta    Yes
                    800: .It Sx \&Brq Ta    Yes      Ta    Yes
                    801: .It Sx \&D1  Ta    \&No     Ta    \&Yes
                    802: .It Sx \&Dl  Ta    \&No     Ta    Yes
                    803: .It Sx \&Dq  Ta    Yes      Ta    Yes
                    804: .It Sx \&Op  Ta    Yes      Ta    Yes
                    805: .It Sx \&Pq  Ta    Yes      Ta    Yes
                    806: .It Sx \&Ql  Ta    Yes      Ta    Yes
                    807: .It Sx \&Qq  Ta    Yes      Ta    Yes
                    808: .It Sx \&Sq  Ta    Yes      Ta    Yes
1.83      kristaps  809: .It Sx \&Vt  Ta    Yes      Ta    Yes
1.57      kristaps  810: .El
1.83      kristaps  811: .Pp
                    812: Note that the
                    813: .Sx \&Vt
                    814: macro is a
                    815: .Sx Block partial-implicit
                    816: only when invoked as the first macro
1.109     kristaps  817: in a
                    818: .Em SYNOPSIS
                    819: section line, else it is
1.83      kristaps  820: .Sx In-line .
1.190     schwarze  821: .Ss Special block macro
                    822: The
                    823: .Sx \&Ta
                    824: macro can only be used below
                    825: .Sx \&It
                    826: in
                    827: .Sx \&Bl Fl column
                    828: lists.
                    829: It delimits blocks representing table cells;
                    830: these blocks have bodies, but no heads.
                    831: .Pp
                    832: .Bl -column "MacroX" "CallableX" "ParsedX" "closed by XXXX" -compact -offset indent
                    833: .It Em Macro Ta Em Callable Ta Em Parsed Ta Em Scope
                    834: .It Sx \&Ta  Ta    Yes      Ta    Yes    Ta closed by Sx \&Ta , Sx \&It
                    835: .El
1.57      kristaps  836: .Ss In-line
1.195     schwarze  837: Closed by the end of the line, fixed argument lengths,
                    838: and/or subsequent macros.
1.100     kristaps  839: In-line macros have only text children.
                    840: If a number (or inequality) of arguments is
1.57      kristaps  841: .Pq n ,
1.3       kristaps  842: then the macro accepts an arbitrary number of arguments.
1.57      kristaps  843: .Bd -literal -offset indent
1.144     schwarze  844: \&.Yo \(lB\-arg \(lBval...\(rB\(rB \(lBargs...\(rB \(lBres...\(rB
1.43      kristaps  845:
                    846: \&.Yo \(lB\-arg \(lBval...\(rB\(rB \(lBargs...\(rB Yc...
                    847:
                    848: \&.Yo \(lB\-arg \(lBval...\(rB\(rB arg0 arg1 argN
1.57      kristaps  849: .Ed
                    850: .Pp
1.141     kristaps  851: .Bl -column "MacroX" "CallableX" "ParsedX" "Arguments" -compact -offset indent
                    852: .It Em Macro Ta Em Callable Ta Em Parsed Ta Em Arguments
1.63      kristaps  853: .It Sx \&%A  Ta    \&No     Ta    \&No     Ta    >0
                    854: .It Sx \&%B  Ta    \&No     Ta    \&No     Ta    >0
                    855: .It Sx \&%C  Ta    \&No     Ta    \&No     Ta    >0
                    856: .It Sx \&%D  Ta    \&No     Ta    \&No     Ta    >0
                    857: .It Sx \&%I  Ta    \&No     Ta    \&No     Ta    >0
                    858: .It Sx \&%J  Ta    \&No     Ta    \&No     Ta    >0
                    859: .It Sx \&%N  Ta    \&No     Ta    \&No     Ta    >0
                    860: .It Sx \&%O  Ta    \&No     Ta    \&No     Ta    >0
                    861: .It Sx \&%P  Ta    \&No     Ta    \&No     Ta    >0
1.69      kristaps  862: .It Sx \&%Q  Ta    \&No     Ta    \&No     Ta    >0
1.63      kristaps  863: .It Sx \&%R  Ta    \&No     Ta    \&No     Ta    >0
                    864: .It Sx \&%T  Ta    \&No     Ta    \&No     Ta    >0
1.69      kristaps  865: .It Sx \&%U  Ta    \&No     Ta    \&No     Ta    >0
1.63      kristaps  866: .It Sx \&%V  Ta    \&No     Ta    \&No     Ta    >0
1.176     schwarze  867: .It Sx \&Ad  Ta    Yes      Ta    Yes      Ta    >0
                    868: .It Sx \&An  Ta    Yes      Ta    Yes      Ta    >0
1.64      kristaps  869: .It Sx \&Ap  Ta    Yes      Ta    Yes      Ta    0
                    870: .It Sx \&Ar  Ta    Yes      Ta    Yes      Ta    n
                    871: .It Sx \&At  Ta    Yes      Ta    Yes      Ta    1
                    872: .It Sx \&Bsx Ta    Yes      Ta    Yes      Ta    n
                    873: .It Sx \&Bt  Ta    \&No     Ta    \&No     Ta    0
                    874: .It Sx \&Bx  Ta    Yes      Ta    Yes      Ta    n
                    875: .It Sx \&Cd  Ta    Yes      Ta    Yes      Ta    >0
1.176     schwarze  876: .It Sx \&Cm  Ta    Yes      Ta    Yes      Ta    >0
1.64      kristaps  877: .It Sx \&Db  Ta    \&No     Ta    \&No     Ta    1
1.142     kristaps  878: .It Sx \&Dd  Ta    \&No     Ta    \&No     Ta    n
1.64      kristaps  879: .It Sx \&Dt  Ta    \&No     Ta    \&No     Ta    n
1.176     schwarze  880: .It Sx \&Dv  Ta    Yes      Ta    Yes      Ta    >0
1.64      kristaps  881: .It Sx \&Dx  Ta    Yes      Ta    Yes      Ta    n
                    882: .It Sx \&Em  Ta    Yes      Ta    Yes      Ta    >0
                    883: .It Sx \&En  Ta    \&No     Ta    \&No     Ta    0
                    884: .It Sx \&Er  Ta    Yes      Ta    Yes      Ta    >0
                    885: .It Sx \&Es  Ta    \&No     Ta    \&No     Ta    0
1.176     schwarze  886: .It Sx \&Ev  Ta    Yes      Ta    Yes      Ta    >0
1.64      kristaps  887: .It Sx \&Ex  Ta    \&No     Ta    \&No     Ta    n
1.176     schwarze  888: .It Sx \&Fa  Ta    Yes      Ta    Yes      Ta    >0
1.64      kristaps  889: .It Sx \&Fd  Ta    \&No     Ta    \&No     Ta    >0
                    890: .It Sx \&Fl  Ta    Yes      Ta    Yes      Ta    n
                    891: .It Sx \&Fn  Ta    Yes      Ta    Yes      Ta    >0
                    892: .It Sx \&Fr  Ta    \&No     Ta    \&No     Ta    n
1.176     schwarze  893: .It Sx \&Ft  Ta    Yes      Ta    Yes      Ta    >0
1.64      kristaps  894: .It Sx \&Fx  Ta    Yes      Ta    Yes      Ta    n
                    895: .It Sx \&Hf  Ta    \&No     Ta    \&No     Ta    n
                    896: .It Sx \&Ic  Ta    Yes      Ta    Yes      Ta    >0
1.184     kristaps  897: .It Sx \&In  Ta    \&No     Ta    \&No     Ta    1
1.64      kristaps  898: .It Sx \&Lb  Ta    \&No     Ta    \&No     Ta    1
1.176     schwarze  899: .It Sx \&Li  Ta    Yes      Ta    Yes      Ta    >0
                    900: .It Sx \&Lk  Ta    Yes      Ta    Yes      Ta    >0
1.64      kristaps  901: .It Sx \&Lp  Ta    \&No     Ta    \&No     Ta    0
                    902: .It Sx \&Ms  Ta    Yes      Ta    Yes      Ta    >0
                    903: .It Sx \&Mt  Ta    Yes      Ta    Yes      Ta    >0
                    904: .It Sx \&Nm  Ta    Yes      Ta    Yes      Ta    n
                    905: .It Sx \&No  Ta    Yes      Ta    Yes      Ta    0
                    906: .It Sx \&Ns  Ta    Yes      Ta    Yes      Ta    0
                    907: .It Sx \&Nx  Ta    Yes      Ta    Yes      Ta    n
                    908: .It Sx \&Os  Ta    \&No     Ta    \&No     Ta    n
                    909: .It Sx \&Ot  Ta    \&No     Ta    \&No     Ta    n
                    910: .It Sx \&Ox  Ta    Yes      Ta    Yes      Ta    n
                    911: .It Sx \&Pa  Ta    Yes      Ta    Yes      Ta    n
1.88      kristaps  912: .It Sx \&Pf  Ta    Yes      Ta    Yes      Ta    1
1.64      kristaps  913: .It Sx \&Pp  Ta    \&No     Ta    \&No     Ta    0
                    914: .It Sx \&Rv  Ta    \&No     Ta    \&No     Ta    n
                    915: .It Sx \&Sm  Ta    \&No     Ta    \&No     Ta    1
                    916: .It Sx \&St  Ta    \&No     Ta    Yes      Ta    1
                    917: .It Sx \&Sx  Ta    Yes      Ta    Yes      Ta    >0
                    918: .It Sx \&Sy  Ta    Yes      Ta    Yes      Ta    >0
                    919: .It Sx \&Tn  Ta    Yes      Ta    Yes      Ta    >0
                    920: .It Sx \&Ud  Ta    \&No     Ta    \&No     Ta    0
                    921: .It Sx \&Ux  Ta    Yes      Ta    Yes      Ta    n
                    922: .It Sx \&Va  Ta    Yes      Ta    Yes      Ta    n
                    923: .It Sx \&Vt  Ta    Yes      Ta    Yes      Ta    >0
1.84      kristaps  924: .It Sx \&Xr  Ta    Yes      Ta    Yes      Ta    >0
1.64      kristaps  925: .It Sx \&br  Ta    \&No     Ta    \&No     Ta    0
                    926: .It Sx \&sp  Ta    \&No     Ta    \&No     Ta    1
1.82      kristaps  927: .El
1.195     schwarze  928: .Ss Delimiters
                    929: When a macro argument consists of one single input character
                    930: considered as a delimiter, the argument gets special handling.
                    931: This does not apply when delimiters appear in arguments containing
                    932: more than one character.
                    933: Consequently, to prevent special handling and just handle it
                    934: like any other argument, a delimiter can be escaped by prepending
                    935: a zero-width space
                    936: .Pq Sq \e& .
                    937: In text lines, delimiters never need escaping, but may be used
                    938: as normal punctuation.
                    939: .Pp
                    940: For many macros, when the leading arguments are opening delimiters,
                    941: these delimiters are put before the macro scope,
                    942: and when the trailing arguments are closing delimiters,
                    943: these delimiters are put after the macro scope.
                    944: For example,
                    945: .Pp
                    946: .D1 Pf \. \&Aq "( [ word ] ) ."
                    947: .Pp
                    948: renders as:
                    949: .Pp
                    950: .D1 Aq ( [ word ] ) .
                    951: .Pp
                    952: Opening delimiters are:
                    953: .Pp
                    954: .Bl -tag -width Ds -offset indent -compact
                    955: .It \&(
                    956: left parenthesis
                    957: .It \&[
                    958: left bracket
                    959: .El
                    960: .Pp
                    961: Closing delimiters are:
                    962: .Pp
                    963: .Bl -tag -width Ds -offset indent -compact
                    964: .It \&.
                    965: period
                    966: .It \&,
                    967: comma
                    968: .It \&:
                    969: colon
                    970: .It \&;
                    971: semicolon
                    972: .It \&)
                    973: right parenthesis
                    974: .It \&]
                    975: right bracket
                    976: .It \&?
                    977: question mark
                    978: .It \&!
                    979: exclamation mark
                    980: .El
                    981: .Pp
                    982: Note that even a period preceded by a backslash
                    983: .Pq Sq \e.\&
                    984: gets this special handling; use
                    985: .Sq \e&.
                    986: to prevent that.
                    987: .Pp
                    988: Many in-line macros interrupt their scope when they encounter
                    989: delimiters, and resume their scope when more arguments follow that
                    990: are not delimiters.
                    991: For example,
                    992: .Pp
                    993: .D1 Pf \. \&Fl "a ( b | c \e*(Ba d ) e"
                    994: .Pp
                    995: renders as:
                    996: .Pp
                    997: .D1 Fl a ( b | c \*(Ba d ) e
                    998: .Pp
                    999: This applies to both opening and closing delimiters,
                   1000: and also to the middle delimiter:
                   1001: .Pp
                   1002: .Bl -tag -width Ds -offset indent -compact
                   1003: .It \&|
                   1004: vertical bar
                   1005: .El
                   1006: .Pp
                   1007: As a special case, the predefined string \e*(Ba is handled and rendered
                   1008: in the same way as a plain
                   1009: .Sq \&|
                   1010: character.
                   1011: Using this predefined string is not recommended in new manuals.
1.63      kristaps 1012: .Sh REFERENCE
                   1013: This section is a canonical reference of all macros, arranged
1.100     kristaps 1014: alphabetically.
                   1015: For the scoping of individual macros, see
1.63      kristaps 1016: .Sx MACRO SYNTAX .
                   1017: .Ss \&%A
                   1018: Author name of an
                   1019: .Sx \&Rs
1.138     kristaps 1020: block.
                   1021: Multiple authors should each be accorded their own
1.64      kristaps 1022: .Sx \%%A
1.138     kristaps 1023: line.
                   1024: Author names should be ordered with full or abbreviated forename(s)
                   1025: first, then full surname.
1.63      kristaps 1026: .Ss \&%B
                   1027: Book title of an
                   1028: .Sx \&Rs
1.138     kristaps 1029: block.
                   1030: This macro may also be used in a non-bibliographic context when
1.63      kristaps 1031: referring to book titles.
                   1032: .Ss \&%C
                   1033: Publication city or location of an
                   1034: .Sx \&Rs
                   1035: block.
                   1036: .Ss \&%D
                   1037: Publication date of an
                   1038: .Sx \&Rs
1.138     kristaps 1039: block.
1.181     schwarze 1040: Recommended formats of arguments are
                   1041: .Ar month day , year
                   1042: or just
                   1043: .Ar year .
1.63      kristaps 1044: .Ss \&%I
                   1045: Publisher or issuer name of an
                   1046: .Sx \&Rs
                   1047: block.
                   1048: .Ss \&%J
                   1049: Journal name of an
                   1050: .Sx \&Rs
                   1051: block.
                   1052: .Ss \&%N
                   1053: Issue number (usually for journals) of an
                   1054: .Sx \&Rs
                   1055: block.
                   1056: .Ss \&%O
                   1057: Optional information of an
                   1058: .Sx \&Rs
                   1059: block.
                   1060: .Ss \&%P
                   1061: Book or journal page number of an
                   1062: .Sx \&Rs
                   1063: block.
                   1064: .Ss \&%Q
                   1065: Institutional author (school, government, etc.) of an
                   1066: .Sx \&Rs
1.138     kristaps 1067: block.
                   1068: Multiple institutional authors should each be accorded their own
1.64      kristaps 1069: .Sx \&%Q
1.63      kristaps 1070: line.
                   1071: .Ss \&%R
                   1072: Technical report name of an
                   1073: .Sx \&Rs
                   1074: block.
                   1075: .Ss \&%T
                   1076: Article title of an
                   1077: .Sx \&Rs
1.138     kristaps 1078: block.
                   1079: This macro may also be used in a non-bibliographical context when
                   1080: referring to article titles.
1.69      kristaps 1081: .Ss \&%U
1.70      kristaps 1082: URI of reference document.
1.63      kristaps 1083: .Ss \&%V
                   1084: Volume number of an
                   1085: .Sx \&Rs
                   1086: block.
                   1087: .Ss \&Ac
1.141     kristaps 1088: Close an
1.63      kristaps 1089: .Sx \&Ao
1.138     kristaps 1090: block.
                   1091: Does not have any tail arguments.
1.63      kristaps 1092: .Ss \&Ad
1.141     kristaps 1093: Memory address.
                   1094: Do not use this for postal addresses.
1.63      kristaps 1095: .Pp
1.64      kristaps 1096: Examples:
1.173     kristaps 1097: .Dl \&.Ad [0,$]
                   1098: .Dl \&.Ad 0x00000000
1.63      kristaps 1099: .Ss \&An
1.100     kristaps 1100: Author name.
1.196     schwarze 1101: Can be used both for the authors of the program, function, or driver
                   1102: documented in the manual, or for the authors of the manual itself.
1.141     kristaps 1103: Requires either the name of an author or one of the following arguments:
1.140     kristaps 1104: .Pp
                   1105: .Bl -tag -width "-nosplitX" -offset indent -compact
1.64      kristaps 1106: .It Fl split
1.141     kristaps 1107: Start a new output line before each subsequent invocation of
                   1108: .Sx \&An .
1.64      kristaps 1109: .It Fl nosplit
                   1110: The opposite of
                   1111: .Fl split .
                   1112: .El
                   1113: .Pp
1.141     kristaps 1114: The default is
                   1115: .Fl nosplit .
                   1116: The effect of selecting either of the
                   1117: .Fl split
                   1118: modes ends at the beginning of the
                   1119: .Em AUTHORS
                   1120: section.
1.140     kristaps 1121: In the
                   1122: .Em AUTHORS
1.141     kristaps 1123: section, the default is
                   1124: .Fl nosplit
                   1125: for the first author listing and
1.64      kristaps 1126: .Fl split
1.141     kristaps 1127: for all other author listings.
1.64      kristaps 1128: .Pp
                   1129: Examples:
1.173     kristaps 1130: .Dl \&.An -nosplit
                   1131: .Dl \&.An Kristaps Dzonsons \&Aq kristaps@bsd.lv
1.63      kristaps 1132: .Ss \&Ao
1.141     kristaps 1133: Begin a block enclosed by angle brackets.
1.100     kristaps 1134: Does not have any head arguments.
1.63      kristaps 1135: .Pp
1.64      kristaps 1136: Examples:
1.173     kristaps 1137: .Dl \&.Fl -key= \&Ns \&Ao \&Ar val \&Ac
1.63      kristaps 1138: .Pp
1.64      kristaps 1139: See also
                   1140: .Sx \&Aq .
1.63      kristaps 1141: .Ss \&Ap
1.138     kristaps 1142: Inserts an apostrophe without any surrounding whitespace.
1.124     kristaps 1143: This is generally used as a grammatical device when referring to the verb
1.140     kristaps 1144: form of a function.
                   1145: .Pp
                   1146: Examples:
1.173     kristaps 1147: .Dl \&.Fn execve \&Ap d
1.63      kristaps 1148: .Ss \&Aq
1.141     kristaps 1149: Encloses its arguments in angle brackets.
1.64      kristaps 1150: .Pp
                   1151: Examples:
1.173     kristaps 1152: .Dl \&.Fl -key= \&Ns \&Aq \&Ar val
1.64      kristaps 1153: .Pp
                   1154: .Em Remarks :
                   1155: this macro is often abused for rendering URIs, which should instead use
                   1156: .Sx \&Lk
                   1157: or
                   1158: .Sx \&Mt ,
                   1159: or to note pre-processor
                   1160: .Dq Li #include
                   1161: statements, which should use
                   1162: .Sx \&In .
                   1163: .Pp
                   1164: See also
                   1165: .Sx \&Ao .
1.63      kristaps 1166: .Ss \&Ar
1.100     kristaps 1167: Command arguments.
                   1168: If an argument is not provided, the string
1.141     kristaps 1169: .Dq file ...\&
1.66      kristaps 1170: is used as a default.
1.64      kristaps 1171: .Pp
                   1172: Examples:
1.196     schwarze 1173: .Dl ".Fl o Ar file"
                   1174: .Dl ".Ar"
                   1175: .Dl ".Ar arg1 , arg2 ."
                   1176: .Pp
                   1177: The arguments to the
                   1178: .Sx \&Ar
                   1179: macro are names and placeholders for command arguments;
                   1180: for fixed strings to be passed verbatim as arguments, use
                   1181: .Sx \&Fl
                   1182: or
                   1183: .Sx \&Cm .
1.63      kristaps 1184: .Ss \&At
1.100     kristaps 1185: Formats an AT&T version.
1.141     kristaps 1186: Accepts one optional argument:
1.140     kristaps 1187: .Pp
                   1188: .Bl -tag -width "v[1-7] | 32vX" -offset indent -compact
1.64      kristaps 1189: .It Cm v[1-7] | 32v
                   1190: A version of
                   1191: .At .
1.192     schwarze 1192: .It Cm III
                   1193: .At III .
1.64      kristaps 1194: .It Cm V[.[1-4]]?
1.141     kristaps 1195: A version of
                   1196: .At V .
1.64      kristaps 1197: .El
                   1198: .Pp
1.141     kristaps 1199: Note that these arguments do not begin with a hyphen.
1.64      kristaps 1200: .Pp
                   1201: Examples:
1.173     kristaps 1202: .Dl \&.At
1.192     schwarze 1203: .Dl \&.At III
1.173     kristaps 1204: .Dl \&.At V.1
1.65      kristaps 1205: .Pp
                   1206: See also
1.66      kristaps 1207: .Sx \&Bsx ,
1.65      kristaps 1208: .Sx \&Bx ,
1.66      kristaps 1209: .Sx \&Dx ,
1.65      kristaps 1210: .Sx \&Fx ,
                   1211: .Sx \&Nx ,
                   1212: .Sx \&Ox ,
                   1213: and
                   1214: .Sx \&Ux .
1.63      kristaps 1215: .Ss \&Bc
1.141     kristaps 1216: Close a
1.64      kristaps 1217: .Sx \&Bo
1.138     kristaps 1218: block.
                   1219: Does not have any tail arguments.
1.63      kristaps 1220: .Ss \&Bd
1.141     kristaps 1221: Begin a display block.
1.131     kristaps 1222: Its syntax is as follows:
                   1223: .Bd -ragged -offset indent
                   1224: .Pf \. Sx \&Bd
1.141     kristaps 1225: .Fl Ns Ar type
1.131     kristaps 1226: .Op Fl offset Ar width
                   1227: .Op Fl compact
                   1228: .Ed
                   1229: .Pp
1.141     kristaps 1230: Display blocks are used to select a different indentation and
                   1231: justification than the one used by the surrounding text.
1.185     kristaps 1232: They may contain both macro lines and text lines.
1.141     kristaps 1233: By default, a display block is preceded by a vertical space.
1.64      kristaps 1234: .Pp
1.141     kristaps 1235: The
                   1236: .Ar type
                   1237: must be one of the following:
                   1238: .Bl -tag -width 13n -offset indent
                   1239: .It Fl centered
1.198     schwarze 1240: Produce one output line from each input line, and centre-justify each line.
1.141     kristaps 1241: Using this display type is not recommended; many
                   1242: .Nm
                   1243: implementations render it poorly.
                   1244: .It Fl filled
1.198     schwarze 1245: Change the positions of line breaks to fill each line, and left- and
                   1246: right-justify the resulting block.
1.141     kristaps 1247: .It Fl literal
1.198     schwarze 1248: Produce one output line from each input line,
                   1249: and do not justify the block at all.
1.169     kristaps 1250: Preserve white space as it appears in the input.
1.198     schwarze 1251: Always use a constant-width font.
                   1252: Use this for displaying source code.
1.64      kristaps 1253: .It Fl ragged
1.198     schwarze 1254: Change the positions of line breaks to fill each line, and left-justify
                   1255: the resulting block.
1.64      kristaps 1256: .It Fl unfilled
1.198     schwarze 1257: The same as
                   1258: .Fl literal ,
                   1259: but using the same font as for normal text, which is a variable width font
                   1260: if supported by the output device.
1.64      kristaps 1261: .El
                   1262: .Pp
1.141     kristaps 1263: The
                   1264: .Ar type
                   1265: must be provided first.
                   1266: Additional arguments may follow:
                   1267: .Bl -tag -width 13n -offset indent
                   1268: .It Fl offset Ar width
                   1269: Indent the display by the
                   1270: .Ar width ,
                   1271: which may be one of the following:
1.64      kristaps 1272: .Bl -item
                   1273: .It
1.141     kristaps 1274: One of the pre-defined strings
                   1275: .Cm indent ,
1.198     schwarze 1276: the width of a standard indentation (six constant width characters);
1.141     kristaps 1277: .Cm indent-two ,
1.64      kristaps 1278: twice
1.141     kristaps 1279: .Cm indent ;
                   1280: .Cm left ,
1.131     kristaps 1281: which has no effect;
1.141     kristaps 1282: .Cm right ,
                   1283: which justifies to the right margin; or
                   1284: .Cm center ,
1.64      kristaps 1285: which aligns around an imagined centre axis.
                   1286: .It
1.141     kristaps 1287: A macro invocation, which selects a predefined width
                   1288: associated with that macro.
1.100     kristaps 1289: The most popular is the imaginary macro
1.67      kristaps 1290: .Ar \&Ds ,
1.64      kristaps 1291: which resolves to
1.141     kristaps 1292: .Sy 6n .
1.64      kristaps 1293: .It
1.141     kristaps 1294: A width using the syntax described in
1.64      kristaps 1295: .Sx Scaling Widths .
                   1296: .It
1.141     kristaps 1297: An arbitrary string, which indents by the length of this string.
1.64      kristaps 1298: .El
                   1299: .Pp
1.141     kristaps 1300: When the argument is missing,
                   1301: .Fl offset
                   1302: is ignored.
1.64      kristaps 1303: .It Fl compact
1.141     kristaps 1304: Do not assert vertical space before the display.
1.64      kristaps 1305: .El
                   1306: .Pp
                   1307: Examples:
                   1308: .Bd -literal -offset indent
1.141     kristaps 1309: \&.Bd \-literal \-offset indent \-compact
1.65      kristaps 1310:    Hello       world.
1.64      kristaps 1311: \&.Ed
                   1312: .Ed
1.66      kristaps 1313: .Pp
                   1314: See also
                   1315: .Sx \&D1
                   1316: and
                   1317: .Sx \&Dl .
1.63      kristaps 1318: .Ss \&Bf
1.129     kristaps 1319: Change the font mode for a scoped block of text.
                   1320: Its syntax is as follows:
                   1321: .Bd -ragged -offset indent
                   1322: .Pf \. Sx \&Bf
                   1323: .Oo
                   1324: .Fl emphasis | literal | symbolic |
                   1325: .Cm \&Em | \&Li | \&Sy
                   1326: .Oc
                   1327: .Ed
                   1328: .Pp
                   1329: The
                   1330: .Fl emphasis
                   1331: and
                   1332: .Cm \&Em
                   1333: argument are equivalent, as are
                   1334: .Fl symbolic
                   1335: and
1.144     schwarze 1336: .Cm \&Sy ,
1.129     kristaps 1337: and
                   1338: .Fl literal
                   1339: and
                   1340: .Cm \&Li .
                   1341: Without an argument, this macro does nothing.
                   1342: The font mode continues until broken by a new font mode in a nested
                   1343: scope or
                   1344: .Sx \&Ef
                   1345: is encountered.
                   1346: .Pp
                   1347: See also
                   1348: .Sx \&Li ,
                   1349: .Sx \&Ef ,
1.141     kristaps 1350: .Sx \&Em ,
1.129     kristaps 1351: and
                   1352: .Sx \&Sy .
1.63      kristaps 1353: .Ss \&Bk
1.186     schwarze 1354: For each macro, keep its output together on the same output line,
                   1355: until the end of the macro or the end of the input line is reached,
                   1356: whichever comes first.
1.185     kristaps 1357: Line breaks in text lines are unaffected.
1.141     kristaps 1358: The syntax is as follows:
1.131     kristaps 1359: .Pp
                   1360: .D1 Pf \. Sx \&Bk Fl words
                   1361: .Pp
1.133     kristaps 1362: The
                   1363: .Fl words
1.141     kristaps 1364: argument is required; additional arguments are ignored.
1.127     schwarze 1365: .Pp
1.141     kristaps 1366: The following example will not break within each
1.133     kristaps 1367: .Sx \&Op
                   1368: macro line:
1.127     schwarze 1369: .Bd -literal -offset indent
                   1370: \&.Bk \-words
1.133     kristaps 1371: \&.Op Fl f Ar flags
                   1372: \&.Op Fl o Ar output
1.127     schwarze 1373: \&.Ek
                   1374: .Ed
1.129     kristaps 1375: .Pp
1.133     kristaps 1376: Be careful in using over-long lines within a keep block!
                   1377: Doing so will clobber the right margin.
1.63      kristaps 1378: .Ss \&Bl
1.141     kristaps 1379: Begin a list.
1.171     schwarze 1380: Lists consist of items specified using the
1.141     kristaps 1381: .Sx \&It
                   1382: macro, containing a head or a body or both.
                   1383: The list syntax is as follows:
1.131     kristaps 1384: .Bd -ragged -offset indent
                   1385: .Pf \. Sx \&Bl
1.141     kristaps 1386: .Fl Ns Ar type
1.131     kristaps 1387: .Op Fl width Ar val
                   1388: .Op Fl offset Ar val
                   1389: .Op Fl compact
                   1390: .Op HEAD ...
                   1391: .Ed
                   1392: .Pp
1.141     kristaps 1393: The list
                   1394: .Ar type
                   1395: is mandatory and must be specified first.
                   1396: The
                   1397: .Fl width
                   1398: and
                   1399: .Fl offset
                   1400: arguments accept
1.104     kristaps 1401: .Sx Scaling Widths
1.141     kristaps 1402: or use the length of the given string.
                   1403: The
                   1404: .Fl offset
                   1405: is a global indentation for the whole list, affecting both item heads
                   1406: and bodies.
                   1407: For those list types supporting it, the
                   1408: .Fl width
                   1409: argument requests an additional indentation of item bodies,
                   1410: to be added to the
                   1411: .Fl offset .
                   1412: Unless the
                   1413: .Fl compact
                   1414: argument is specified, list entries are separated by vertical space.
                   1415: .Pp
1.103     kristaps 1416: A list must specify one of the following list types:
                   1417: .Bl -tag -width 12n -offset indent
                   1418: .It Fl bullet
1.141     kristaps 1419: No item heads can be specified, but a bullet will be printed at the head
                   1420: of each item.
                   1421: Item bodies start on the same output line as the bullet
                   1422: and are indented according to the
1.104     kristaps 1423: .Fl width
1.141     kristaps 1424: argument.
1.103     kristaps 1425: .It Fl column
                   1426: A columnated list.
1.104     kristaps 1427: The
                   1428: .Fl width
1.141     kristaps 1429: argument has no effect; instead, each argument specifies the width
                   1430: of one column, using either the
1.103     kristaps 1431: .Sx Scaling Widths
1.141     kristaps 1432: syntax or the string length of the argument.
                   1433: If the first line of the body of a
1.114     kristaps 1434: .Fl column
                   1435: list is not an
                   1436: .Sx \&It
1.141     kristaps 1437: macro line,
                   1438: .Sx \&It
                   1439: contexts spanning one input line each are implied until an
1.114     kristaps 1440: .Sx \&It
1.141     kristaps 1441: macro line is encountered, at which point items start being interpreted as
1.114     kristaps 1442: described in the
                   1443: .Sx \&It
                   1444: documentation.
1.103     kristaps 1445: .It Fl dash
1.141     kristaps 1446: Like
                   1447: .Fl bullet ,
                   1448: except that dashes are used in place of bullets.
1.103     kristaps 1449: .It Fl diag
                   1450: Like
                   1451: .Fl inset ,
1.141     kristaps 1452: except that item heads are not parsed for macro invocations.
1.198     schwarze 1453: Most often used in the
                   1454: .Em DIAGNOSTICS
                   1455: section with error constants in the item heads.
1.103     kristaps 1456: .It Fl enum
1.141     kristaps 1457: A numbered list.
1.198     schwarze 1458: No item heads can be specified.
1.141     kristaps 1459: Formatted like
                   1460: .Fl bullet ,
                   1461: except that cardinal numbers are used in place of bullets,
                   1462: starting at 1.
1.103     kristaps 1463: .It Fl hang
                   1464: Like
                   1465: .Fl tag ,
1.141     kristaps 1466: except that the first lines of item bodies are not indented, but follow
                   1467: the item heads like in
                   1468: .Fl inset
                   1469: lists.
1.103     kristaps 1470: .It Fl hyphen
                   1471: Synonym for
                   1472: .Fl dash .
                   1473: .It Fl inset
1.141     kristaps 1474: Item bodies follow items heads on the same line, using normal inter-word
                   1475: spacing.
                   1476: Bodies are not indented, and the
1.104     kristaps 1477: .Fl width
                   1478: argument is ignored.
1.103     kristaps 1479: .It Fl item
1.141     kristaps 1480: No item heads can be specified, and none are printed.
                   1481: Bodies are not indented, and the
1.104     kristaps 1482: .Fl width
                   1483: argument is ignored.
1.103     kristaps 1484: .It Fl ohang
1.141     kristaps 1485: Item bodies start on the line following item heads and are not indented.
1.104     kristaps 1486: The
                   1487: .Fl width
                   1488: argument is ignored.
1.103     kristaps 1489: .It Fl tag
1.141     kristaps 1490: Item bodies are indented according to the
1.103     kristaps 1491: .Fl width
                   1492: argument.
1.141     kristaps 1493: When an item head fits inside the indentation, the item body follows
                   1494: this head on the same output line.
                   1495: Otherwise, the body starts on the output line following the head.
1.103     kristaps 1496: .El
1.114     kristaps 1497: .Pp
1.198     schwarze 1498: Lists may be nested within lists and displays.
                   1499: Nesting of
                   1500: .Fl column
                   1501: and
                   1502: .Fl enum
                   1503: lists may not be portable.
                   1504: .Pp
1.114     kristaps 1505: See also
1.141     kristaps 1506: .Sx \&El
                   1507: and
1.114     kristaps 1508: .Sx \&It .
1.63      kristaps 1509: .Ss \&Bo
1.141     kristaps 1510: Begin a block enclosed by square brackets.
1.100     kristaps 1511: Does not have any head arguments.
1.65      kristaps 1512: .Pp
                   1513: Examples:
1.140     kristaps 1514: .Bd -literal -offset indent -compact
1.65      kristaps 1515: \&.Bo 1 ,
1.91      kristaps 1516: \&.Dv BUFSIZ \&Bc
1.65      kristaps 1517: .Ed
                   1518: .Pp
                   1519: See also
                   1520: .Sx \&Bq .
1.63      kristaps 1521: .Ss \&Bq
1.82      kristaps 1522: Encloses its arguments in square brackets.
1.65      kristaps 1523: .Pp
                   1524: Examples:
1.173     kristaps 1525: .Dl \&.Bq 1 , \&Dv BUFSIZ
1.65      kristaps 1526: .Pp
                   1527: .Em Remarks :
                   1528: this macro is sometimes abused to emulate optional arguments for
                   1529: commands; the correct macros to use for this purpose are
                   1530: .Sx \&Op ,
                   1531: .Sx \&Oo ,
                   1532: and
                   1533: .Sx \&Oc .
                   1534: .Pp
                   1535: See also
                   1536: .Sx \&Bo .
1.63      kristaps 1537: .Ss \&Brc
1.141     kristaps 1538: Close a
1.65      kristaps 1539: .Sx \&Bro
1.138     kristaps 1540: block.
                   1541: Does not have any tail arguments.
1.63      kristaps 1542: .Ss \&Bro
1.141     kristaps 1543: Begin a block enclosed by curly braces.
1.100     kristaps 1544: Does not have any head arguments.
1.65      kristaps 1545: .Pp
                   1546: Examples:
1.140     kristaps 1547: .Bd -literal -offset indent -compact
1.65      kristaps 1548: \&.Bro 1 , ... ,
1.91      kristaps 1549: \&.Va n \&Brc
1.65      kristaps 1550: .Ed
                   1551: .Pp
                   1552: See also
                   1553: .Sx \&Brq .
1.63      kristaps 1554: .Ss \&Brq
1.65      kristaps 1555: Encloses its arguments in curly braces.
                   1556: .Pp
                   1557: Examples:
1.173     kristaps 1558: .Dl \&.Brq 1 , ... , \&Va n
1.65      kristaps 1559: .Pp
                   1560: See also
                   1561: .Sx \&Bro .
1.63      kristaps 1562: .Ss \&Bsx
1.65      kristaps 1563: Format the BSD/OS version provided as an argument, or a default value if
                   1564: no argument is provided.
                   1565: .Pp
                   1566: Examples:
1.173     kristaps 1567: .Dl \&.Bsx 1.0
                   1568: .Dl \&.Bsx
1.65      kristaps 1569: .Pp
                   1570: See also
                   1571: .Sx \&At ,
                   1572: .Sx \&Bx ,
1.66      kristaps 1573: .Sx \&Dx ,
1.65      kristaps 1574: .Sx \&Fx ,
                   1575: .Sx \&Nx ,
                   1576: .Sx \&Ox ,
                   1577: and
                   1578: .Sx \&Ux .
1.63      kristaps 1579: .Ss \&Bt
1.66      kristaps 1580: Prints
1.198     schwarze 1581: .Dq is currently in beta test.
1.63      kristaps 1582: .Ss \&Bx
1.65      kristaps 1583: Format the BSD version provided as an argument, or a default value if no
                   1584: argument is provided.
                   1585: .Pp
                   1586: Examples:
1.198     schwarze 1587: .Dl \&.Bx 4.3 Tahoe
1.173     kristaps 1588: .Dl \&.Bx 4.4
                   1589: .Dl \&.Bx
1.65      kristaps 1590: .Pp
                   1591: See also
                   1592: .Sx \&At ,
                   1593: .Sx \&Bsx ,
1.66      kristaps 1594: .Sx \&Dx ,
1.65      kristaps 1595: .Sx \&Fx ,
                   1596: .Sx \&Nx ,
                   1597: .Sx \&Ox ,
                   1598: and
                   1599: .Sx \&Ux .
1.63      kristaps 1600: .Ss \&Cd
1.141     kristaps 1601: Kernel configuration declaration.
1.100     kristaps 1602: This denotes strings accepted by
1.66      kristaps 1603: .Xr config 8 .
1.196     schwarze 1604: It is most often used in section 4 manual pages.
1.66      kristaps 1605: .Pp
                   1606: Examples:
1.173     kristaps 1607: .Dl \&.Cd device le0 at scode?
1.66      kristaps 1608: .Pp
                   1609: .Em Remarks :
                   1610: this macro is commonly abused by using quoted literals to retain
1.138     kristaps 1611: whitespace and align consecutive
1.66      kristaps 1612: .Sx \&Cd
1.100     kristaps 1613: declarations.
                   1614: This practise is discouraged.
1.63      kristaps 1615: .Ss \&Cm
1.100     kristaps 1616: Command modifiers.
1.196     schwarze 1617: Typically used for fixed strings passed as arguments, unless
                   1618: .Sx \&Fl
                   1619: is more appropriate.
                   1620: Also useful when specifying configuration options or keys.
1.66      kristaps 1621: .Pp
                   1622: Examples:
1.196     schwarze 1623: .Dl ".Nm mt Fl f Ar device Cm rewind"
                   1624: .Dl ".Nm ps Fl o Cm pid , Ns Cm command"
                   1625: .Dl ".Nm dd Cm if= Ns Ar file1 Cm of= Ns Ar file2"
                   1626: .Dl ".Cm IdentityFile Pa ~/.ssh/id_rsa"
                   1627: .Dl ".Cm LogLevel Dv DEBUG"
1.63      kristaps 1628: .Ss \&D1
1.100     kristaps 1629: One-line indented display.
                   1630: This is formatted by the default rules and is useful for simple indented
                   1631: statements.
                   1632: It is followed by a newline.
1.66      kristaps 1633: .Pp
                   1634: Examples:
1.173     kristaps 1635: .Dl \&.D1 \&Fl abcdefgh
1.66      kristaps 1636: .Pp
                   1637: See also
                   1638: .Sx \&Bd
                   1639: and
                   1640: .Sx \&Dl .
1.63      kristaps 1641: .Ss \&Db
1.141     kristaps 1642: Switch debugging mode.
1.120     kristaps 1643: Its syntax is as follows:
1.117     kristaps 1644: .Pp
1.120     kristaps 1645: .D1 Pf \. Sx \&Db Cm on | off
1.141     kristaps 1646: .Pp
                   1647: This macro is ignored by
                   1648: .Xr mandoc 1 .
1.63      kristaps 1649: .Ss \&Dc
1.141     kristaps 1650: Close a
1.66      kristaps 1651: .Sx \&Do
1.138     kristaps 1652: block.
                   1653: Does not have any tail arguments.
1.63      kristaps 1654: .Ss \&Dd
1.100     kristaps 1655: Document date.
                   1656: This is the mandatory first macro of any
1.66      kristaps 1657: .Nm
1.100     kristaps 1658: manual.
1.120     kristaps 1659: Its syntax is as follows:
1.66      kristaps 1660: .Pp
1.181     schwarze 1661: .D1 Pf \. Sx \&Dd Ar month day , year
1.66      kristaps 1662: .Pp
1.82      kristaps 1663: The
1.181     schwarze 1664: .Ar month
                   1665: is the full English month name, the
                   1666: .Ar day
                   1667: is an optionally zero-padded numeral, and the
                   1668: .Ar year
                   1669: is the full four-digit year.
                   1670: .Pp
                   1671: Other arguments are not portable; the
                   1672: .Xr mandoc 1
                   1673: utility handles them as follows:
                   1674: .Bl -dash -offset 3n -compact
                   1675: .It
                   1676: To have the date automatically filled in by the
                   1677: .Ox
                   1678: version of
1.72      kristaps 1679: .Xr cvs 1 ,
1.181     schwarze 1680: the special string
                   1681: .Dq $\&Mdocdate$
                   1682: can be given as an argument.
                   1683: .It
                   1684: A few alternative date formats are accepted as well
                   1685: and converted to the standard form.
                   1686: .It
                   1687: If a date string cannot be parsed, it is used verbatim.
                   1688: .It
                   1689: If no date string is given, the current date is used.
                   1690: .El
1.66      kristaps 1691: .Pp
                   1692: Examples:
1.173     kristaps 1693: .Dl \&.Dd $\&Mdocdate$
                   1694: .Dl \&.Dd $\&Mdocdate: July 21 2007$
                   1695: .Dl \&.Dd July 21, 2007
1.66      kristaps 1696: .Pp
                   1697: See also
                   1698: .Sx \&Dt
                   1699: and
                   1700: .Sx \&Os .
1.63      kristaps 1701: .Ss \&Dl
1.100     kristaps 1702: One-line intended display.
                   1703: This is formatted as literal text and is useful for commands and
                   1704: invocations.
                   1705: It is followed by a newline.
1.66      kristaps 1706: .Pp
                   1707: Examples:
1.173     kristaps 1708: .Dl \&.Dl % mandoc mdoc.7 \e(ba less
1.66      kristaps 1709: .Pp
                   1710: See also
                   1711: .Sx \&Bd
                   1712: and
                   1713: .Sx \&D1 .
1.63      kristaps 1714: .Ss \&Do
1.141     kristaps 1715: Begin a block enclosed by double quotes.
1.138     kristaps 1716: Does not have any head arguments.
1.66      kristaps 1717: .Pp
                   1718: Examples:
1.140     kristaps 1719: .Bd -literal -offset indent -compact
                   1720: \&.Do
                   1721: April is the cruellest month
                   1722: \&.Dc
                   1723: \e(em T.S. Eliot
                   1724: .Ed
1.66      kristaps 1725: .Pp
                   1726: See also
                   1727: .Sx \&Dq .
1.63      kristaps 1728: .Ss \&Dq
1.138     kristaps 1729: Encloses its arguments in
                   1730: .Dq typographic
                   1731: double-quotes.
1.66      kristaps 1732: .Pp
                   1733: Examples:
1.91      kristaps 1734: .Bd -literal -offset indent -compact
1.66      kristaps 1735: \&.Dq April is the cruellest month
                   1736: \e(em T.S. Eliot
                   1737: .Ed
                   1738: .Pp
                   1739: See also
1.139     kristaps 1740: .Sx \&Qq ,
                   1741: .Sx \&Sq ,
1.138     kristaps 1742: and
1.66      kristaps 1743: .Sx \&Do .
1.139     kristaps 1744: .Ss \&Dt
1.100     kristaps 1745: Document title.
                   1746: This is the mandatory second macro of any
1.66      kristaps 1747: .Nm
1.100     kristaps 1748: file.
1.120     kristaps 1749: Its syntax is as follows:
                   1750: .Bd -ragged -offset indent
                   1751: .Pf \. Sx \&Dt
                   1752: .Oo
1.141     kristaps 1753: .Ar title
1.120     kristaps 1754: .Oo
1.141     kristaps 1755: .Ar section
                   1756: .Op Ar volume | arch
1.120     kristaps 1757: .Oc
                   1758: .Oc
                   1759: .Ed
1.66      kristaps 1760: .Pp
                   1761: Its arguments are as follows:
                   1762: .Bl -tag -width Ds -offset Ds
1.141     kristaps 1763: .It Ar title
1.111     kristaps 1764: The document's title (name), defaulting to
1.138     kristaps 1765: .Dq UNKNOWN
1.111     kristaps 1766: if unspecified.
                   1767: It should be capitalised.
1.141     kristaps 1768: .It Ar section
1.100     kristaps 1769: The manual section.
                   1770: This may be one of
1.66      kristaps 1771: .Ar 1
                   1772: .Pq utilities ,
                   1773: .Ar 2
                   1774: .Pq system calls ,
                   1775: .Ar 3
                   1776: .Pq libraries ,
                   1777: .Ar 3p
                   1778: .Pq Perl libraries ,
                   1779: .Ar 4
                   1780: .Pq devices ,
                   1781: .Ar 5
                   1782: .Pq file formats ,
                   1783: .Ar 6
                   1784: .Pq games ,
                   1785: .Ar 7
                   1786: .Pq miscellaneous ,
                   1787: .Ar 8
                   1788: .Pq system utilities ,
                   1789: .Ar 9
                   1790: .Pq kernel functions ,
                   1791: .Ar X11
                   1792: .Pq X Window System ,
                   1793: .Ar X11R6
                   1794: .Pq X Window System ,
                   1795: .Ar unass
                   1796: .Pq unassociated ,
                   1797: .Ar local
                   1798: .Pq local system ,
                   1799: .Ar draft
                   1800: .Pq draft manual ,
                   1801: or
                   1802: .Ar paper
                   1803: .Pq paper .
1.111     kristaps 1804: It should correspond to the manual's filename suffix and defaults to
1.138     kristaps 1805: .Dq 1
1.111     kristaps 1806: if unspecified.
1.141     kristaps 1807: .It Ar volume
1.66      kristaps 1808: This overrides the volume inferred from
                   1809: .Ar section .
                   1810: This field is optional, and if specified, must be one of
                   1811: .Ar USD
                   1812: .Pq users' supplementary documents ,
                   1813: .Ar PS1
                   1814: .Pq programmers' supplementary documents ,
                   1815: .Ar AMD
                   1816: .Pq administrators' supplementary documents ,
                   1817: .Ar SMM
                   1818: .Pq system managers' manuals ,
                   1819: .Ar URM
                   1820: .Pq users' reference manuals ,
                   1821: .Ar PRM
                   1822: .Pq programmers' reference manuals ,
                   1823: .Ar KM
                   1824: .Pq kernel manuals ,
                   1825: .Ar IND
                   1826: .Pq master index ,
                   1827: .Ar MMI
                   1828: .Pq master index ,
                   1829: .Ar LOCAL
                   1830: .Pq local manuals ,
                   1831: .Ar LOC
                   1832: .Pq local manuals ,
                   1833: or
                   1834: .Ar CON
                   1835: .Pq contributed manuals .
1.141     kristaps 1836: .It Ar arch
1.100     kristaps 1837: This specifies a specific relevant architecture.
                   1838: If
1.141     kristaps 1839: .Ar volume
1.66      kristaps 1840: is not provided, it may be used in its place, else it may be used
1.100     kristaps 1841: subsequent that.
                   1842: It, too, is optional.
                   1843: It must be one of
1.66      kristaps 1844: .Ar alpha ,
                   1845: .Ar amd64 ,
                   1846: .Ar amiga ,
                   1847: .Ar arc ,
                   1848: .Ar arm ,
                   1849: .Ar armish ,
                   1850: .Ar aviion ,
                   1851: .Ar hp300 ,
                   1852: .Ar hppa ,
                   1853: .Ar hppa64 ,
                   1854: .Ar i386 ,
                   1855: .Ar landisk ,
1.86      kristaps 1856: .Ar loongson ,
1.66      kristaps 1857: .Ar luna88k ,
                   1858: .Ar mac68k ,
                   1859: .Ar macppc ,
1.160     kristaps 1860: .Ar mips64 ,
1.66      kristaps 1861: .Ar mvme68k ,
                   1862: .Ar mvme88k ,
                   1863: .Ar mvmeppc ,
                   1864: .Ar pmax ,
                   1865: .Ar sgi ,
                   1866: .Ar socppc ,
                   1867: .Ar sparc ,
                   1868: .Ar sparc64 ,
                   1869: .Ar sun3 ,
                   1870: .Ar vax ,
                   1871: or
                   1872: .Ar zaurus .
                   1873: .El
                   1874: .Pp
                   1875: Examples:
1.173     kristaps 1876: .Dl \&.Dt FOO 1
                   1877: .Dl \&.Dt FOO 4 KM
                   1878: .Dl \&.Dt FOO 9 i386
1.66      kristaps 1879: .Pp
                   1880: See also
                   1881: .Sx \&Dd
                   1882: and
                   1883: .Sx \&Os .
1.63      kristaps 1884: .Ss \&Dv
1.189     kristaps 1885: Defined variables such as preprocessor constants, constant symbols,
                   1886: enumeration values, and so on.
1.66      kristaps 1887: .Pp
                   1888: Examples:
1.189     kristaps 1889: .Dl \&.Dv NULL
1.173     kristaps 1890: .Dl \&.Dv BUFSIZ
                   1891: .Dl \&.Dv STDOUT_FILENO
1.66      kristaps 1892: .Pp
                   1893: See also
1.189     kristaps 1894: .Sx \&Er
                   1895: and
                   1896: .Sx \&Ev
                   1897: for special-purpose constants and
                   1898: .Sx \&Va
                   1899: for variable symbols.
1.63      kristaps 1900: .Ss \&Dx
1.71      kristaps 1901: Format the DragonFly BSD version provided as an argument, or a default
1.66      kristaps 1902: value if no argument is provided.
                   1903: .Pp
                   1904: Examples:
1.173     kristaps 1905: .Dl \&.Dx 2.4.1
                   1906: .Dl \&.Dx
1.66      kristaps 1907: .Pp
                   1908: See also
                   1909: .Sx \&At ,
                   1910: .Sx \&Bsx ,
                   1911: .Sx \&Bx ,
                   1912: .Sx \&Fx ,
                   1913: .Sx \&Nx ,
                   1914: .Sx \&Ox ,
                   1915: and
                   1916: .Sx \&Ux .
1.63      kristaps 1917: .Ss \&Ec
1.131     kristaps 1918: Close a scope started by
                   1919: .Sx \&Eo .
                   1920: Its syntax is as follows:
                   1921: .Pp
1.141     kristaps 1922: .D1 Pf \. Sx \&Ec Op Ar TERM
1.131     kristaps 1923: .Pp
                   1924: The
1.141     kristaps 1925: .Ar TERM
1.131     kristaps 1926: argument is used as the enclosure tail, for example, specifying \e(rq
                   1927: will emulate
                   1928: .Sx \&Dc .
1.63      kristaps 1929: .Ss \&Ed
1.131     kristaps 1930: End a display context started by
                   1931: .Sx \&Bd .
1.63      kristaps 1932: .Ss \&Ef
1.141     kristaps 1933: End a font mode context started by
1.129     kristaps 1934: .Sx \&Bf .
1.63      kristaps 1935: .Ss \&Ek
1.141     kristaps 1936: End a keep context started by
1.127     schwarze 1937: .Sx \&Bk .
1.63      kristaps 1938: .Ss \&El
1.141     kristaps 1939: End a list context started by
1.117     kristaps 1940: .Sx \&Bl .
                   1941: .Pp
                   1942: See also
                   1943: .Sx \&Bl
                   1944: and
                   1945: .Sx \&It .
1.63      kristaps 1946: .Ss \&Em
1.198     schwarze 1947: Denotes text that should be
                   1948: .Em emphasised .
1.100     kristaps 1949: Note that this is a presentation term and should not be used for
                   1950: stylistically decorating technical terms.
1.198     schwarze 1951: Depending on the output device, this is usually represented
                   1952: using an italic font or underlined characters.
1.66      kristaps 1953: .Pp
                   1954: Examples:
1.173     kristaps 1955: .Dl \&.Em Warnings!
                   1956: .Dl \&.Em Remarks :
1.138     kristaps 1957: .Pp
                   1958: See also
                   1959: .Sx \&Bf ,
1.198     schwarze 1960: .Sx \&Li ,
                   1961: .Sx \&No ,
1.138     kristaps 1962: and
1.198     schwarze 1963: .Sx \&Sy .
1.63      kristaps 1964: .Ss \&En
1.141     kristaps 1965: This macro is obsolete and not implemented in
                   1966: .Xr mandoc 1 .
1.63      kristaps 1967: .Ss \&Eo
1.131     kristaps 1968: An arbitrary enclosure.
                   1969: Its syntax is as follows:
                   1970: .Pp
1.141     kristaps 1971: .D1 Pf \. Sx \&Eo Op Ar TERM
1.131     kristaps 1972: .Pp
                   1973: The
1.141     kristaps 1974: .Ar TERM
1.131     kristaps 1975: argument is used as the enclosure head, for example, specifying \e(lq
                   1976: will emulate
                   1977: .Sx \&Do .
1.63      kristaps 1978: .Ss \&Er
1.189     kristaps 1979: Error constants for definitions of the
                   1980: .Va errno
                   1981: libc global variable.
1.196     schwarze 1982: This is most often used in section 2 and 3 manual pages.
1.66      kristaps 1983: .Pp
                   1984: Examples:
1.173     kristaps 1985: .Dl \&.Er EPERM
                   1986: .Dl \&.Er ENOENT
1.66      kristaps 1987: .Pp
                   1988: See also
1.189     kristaps 1989: .Sx \&Dv
                   1990: for general constants.
1.63      kristaps 1991: .Ss \&Es
1.132     kristaps 1992: This macro is obsolete and not implemented.
1.63      kristaps 1993: .Ss \&Ev
1.66      kristaps 1994: Environmental variables such as those specified in
                   1995: .Xr environ 7 .
                   1996: .Pp
                   1997: Examples:
1.173     kristaps 1998: .Dl \&.Ev DISPLAY
                   1999: .Dl \&.Ev PATH
1.189     kristaps 2000: .Pp
                   2001: See also
                   2002: .Sx \&Dv
                   2003: for general constants.
1.63      kristaps 2004: .Ss \&Ex
1.191     kristaps 2005: Insert a standard sentence regarding command exit values of 0 on success
                   2006: and >0 on failure.
1.196     schwarze 2007: This is most often used in section 1, 6, and 8 manual pages.
1.141     kristaps 2008: Its syntax is as follows:
                   2009: .Pp
1.193     schwarze 2010: .D1 Pf \. Sx \&Ex Fl std Op Ar utility ...
1.141     kristaps 2011: .Pp
1.191     kristaps 2012: If
1.66      kristaps 2013: .Ar utility
1.141     kristaps 2014: is not specified, the document's name set by
1.66      kristaps 2015: .Sx \&Nm
1.141     kristaps 2016: is used.
1.191     kristaps 2017: Multiple
                   2018: .Ar utility
                   2019: arguments are treated as separate utilities.
1.139     kristaps 2020: .Pp
                   2021: See also
                   2022: .Sx \&Rv .
1.63      kristaps 2023: .Ss \&Fa
1.117     kristaps 2024: Function argument.
1.120     kristaps 2025: Its syntax is as follows:
                   2026: .Bd -ragged -offset indent
                   2027: .Pf \. Sx \&Fa
                   2028: .Op Cm argtype
                   2029: .Cm argname
                   2030: .Ed
                   2031: .Pp
1.117     kristaps 2032: This may be invoked for names with or without the corresponding type.
                   2033: It is also used to specify the field name of a structure.
                   2034: Most often, the
                   2035: .Sx \&Fa
                   2036: macro is used in the
                   2037: .Em SYNOPSIS
1.120     kristaps 2038: within
                   2039: .Sx \&Fo
1.117     kristaps 2040: section when documenting multi-line function prototypes.
                   2041: If invoked with multiple arguments, the arguments are separated by a
                   2042: comma.
                   2043: Furthermore, if the following macro is another
                   2044: .Sx \&Fa ,
                   2045: the last argument will also have a trailing comma.
                   2046: .Pp
                   2047: Examples:
1.173     kristaps 2048: .Dl \&.Fa \(dqconst char *p\(dq
                   2049: .Dl \&.Fa \(dqint a\(dq \(dqint b\(dq \(dqint c\(dq
                   2050: .Dl \&.Fa foo
1.120     kristaps 2051: .Pp
                   2052: See also
                   2053: .Sx \&Fo .
1.63      kristaps 2054: .Ss \&Fc
1.141     kristaps 2055: End a function context started by
1.131     kristaps 2056: .Sx \&Fo .
1.63      kristaps 2057: .Ss \&Fd
1.117     kristaps 2058: Historically used to document include files.
                   2059: This usage has been deprecated in favour of
                   2060: .Sx \&In .
                   2061: Do not use this macro.
                   2062: .Pp
                   2063: See also
1.122     kristaps 2064: .Sx MANUAL STRUCTURE
                   2065: and
1.117     kristaps 2066: .Sx \&In .
1.63      kristaps 2067: .Ss \&Fl
1.196     schwarze 2068: Command-line flag or option.
1.100     kristaps 2069: Used when listing arguments to command-line utilities.
                   2070: Prints a fixed-width hyphen
1.79      kristaps 2071: .Sq \-
1.100     kristaps 2072: directly followed by each argument.
                   2073: If no arguments are provided, a hyphen is printed followed by a space.
                   2074: If the argument is a macro, a hyphen is prefixed to the subsequent macro
                   2075: output.
1.79      kristaps 2076: .Pp
                   2077: Examples:
1.199     schwarze 2078: .Dl ".Fl R Op Fl H | L | P"
                   2079: .Dl ".Op Fl 1AaCcdFfgHhikLlmnopqRrSsTtux"
                   2080: .Dl ".Fl type Cm d Fl name Pa CVS"
                   2081: .Dl ".Fl Ar signal_number"
                   2082: .Dl ".Fl o Fl"
1.79      kristaps 2083: .Pp
                   2084: See also
                   2085: .Sx \&Cm .
1.63      kristaps 2086: .Ss \&Fn
1.119     kristaps 2087: A function name.
1.120     kristaps 2088: Its syntax is as follows:
1.119     kristaps 2089: .Bd -ragged -offset indent
                   2090: .Pf \. Ns Sx \&Fn
1.185     kristaps 2091: .Op Ar functype
                   2092: .Ar funcname
                   2093: .Op Oo Ar argtype Oc Ar argname
1.119     kristaps 2094: .Ed
1.120     kristaps 2095: .Pp
1.122     kristaps 2096: Function arguments are surrounded in parenthesis and
1.119     kristaps 2097: are delimited by commas.
                   2098: If no arguments are specified, blank parenthesis are output.
1.196     schwarze 2099: In the
                   2100: .Em SYNOPSIS
                   2101: section, this macro starts a new output line,
                   2102: and a blank line is automatically inserted between function definitions.
1.119     kristaps 2103: .Pp
                   2104: Examples:
1.203     kristaps 2105: .Dl \&.Fn \(dqint funcname\(dq \(dqint arg0\(dq \(dqint arg1\(dq
                   2106: .Dl \&.Fn funcname \(dqint arg0\(dq
1.173     kristaps 2107: .Dl \&.Fn funcname arg0
1.196     schwarze 2108: .Pp
1.120     kristaps 2109: .Bd -literal -offset indent -compact
                   2110: \&.Ft functype
                   2111: \&.Fn funcname
                   2112: .Ed
1.119     kristaps 2113: .Pp
1.163     schwarze 2114: When referring to a function documented in another manual page, use
1.162     schwarze 2115: .Sx \&Xr
1.163     schwarze 2116: instead.
1.119     kristaps 2117: See also
1.196     schwarze 2118: .Sx MANUAL STRUCTURE ,
                   2119: .Sx \&Fo ,
1.119     kristaps 2120: and
                   2121: .Sx \&Ft .
1.63      kristaps 2122: .Ss \&Fo
1.120     kristaps 2123: Begin a function block.
                   2124: This is a multi-line version of
                   2125: .Sx \&Fn .
                   2126: Its syntax is as follows:
                   2127: .Pp
1.185     kristaps 2128: .D1 Pf \. Sx \&Fo Ar funcname
1.120     kristaps 2129: .Pp
                   2130: Invocations usually occur in the following context:
                   2131: .Bd -ragged -offset indent
1.185     kristaps 2132: .Pf \. Sx \&Ft Ar functype
1.120     kristaps 2133: .br
1.185     kristaps 2134: .Pf \. Sx \&Fo Ar funcname
1.120     kristaps 2135: .br
1.185     kristaps 2136: .Pf \. Sx \&Fa Oo Ar argtype Oc Ar argname
1.120     kristaps 2137: .br
1.183     kristaps 2138: \&.\.\.
1.120     kristaps 2139: .br
                   2140: .Pf \. Sx \&Fc
                   2141: .Ed
                   2142: .Pp
                   2143: A
                   2144: .Sx \&Fo
                   2145: scope is closed by
1.196     schwarze 2146: .Sx \&Fc .
1.120     kristaps 2147: .Pp
                   2148: See also
1.122     kristaps 2149: .Sx MANUAL STRUCTURE ,
1.120     kristaps 2150: .Sx \&Fa ,
                   2151: .Sx \&Fc ,
                   2152: and
1.139     kristaps 2153: .Sx \&Ft .
1.190     schwarze 2154: .Ss \&Fr
1.198     schwarze 2155: This macro is obsolete and not implemented in
                   2156: .Xr mandoc 1 .
                   2157: .Pp
                   2158: It was used to show function return values.
                   2159: The syntax was:
                   2160: .Pp
                   2161: .Dl Pf . Sx \&Fr Ar value
1.63      kristaps 2162: .Ss \&Ft
1.120     kristaps 2163: A function type.
                   2164: Its syntax is as follows:
                   2165: .Pp
1.185     kristaps 2166: .D1 Pf \. Sx \&Ft Ar functype
1.120     kristaps 2167: .Pp
1.196     schwarze 2168: In the
                   2169: .Em SYNOPSIS
                   2170: section, a new output line is started after this macro.
                   2171: .Pp
1.120     kristaps 2172: Examples:
1.173     kristaps 2173: .Dl \&.Ft int
1.120     kristaps 2174: .Bd -literal -offset indent -compact
                   2175: \&.Ft functype
                   2176: \&.Fn funcname
                   2177: .Ed
                   2178: .Pp
                   2179: See also
1.122     kristaps 2180: .Sx MANUAL STRUCTURE ,
                   2181: .Sx \&Fn ,
1.120     kristaps 2182: and
1.122     kristaps 2183: .Sx \&Fo .
1.63      kristaps 2184: .Ss \&Fx
1.144     schwarze 2185: Format the
                   2186: .Fx
                   2187: version provided as an argument, or a default value
1.65      kristaps 2188: if no argument is provided.
                   2189: .Pp
                   2190: Examples:
1.173     kristaps 2191: .Dl \&.Fx 7.1
                   2192: .Dl \&.Fx
1.65      kristaps 2193: .Pp
                   2194: See also
                   2195: .Sx \&At ,
1.66      kristaps 2196: .Sx \&Bsx ,
1.65      kristaps 2197: .Sx \&Bx ,
1.66      kristaps 2198: .Sx \&Dx ,
1.65      kristaps 2199: .Sx \&Nx ,
                   2200: .Sx \&Ox ,
                   2201: and
                   2202: .Sx \&Ux .
1.63      kristaps 2203: .Ss \&Hf
1.198     schwarze 2204: This macro is not implemented in
                   2205: .Xr mandoc 1 .
                   2206: .Pp
                   2207: It was used to include the contents of a (header) file literally.
                   2208: The syntax was:
                   2209: .Pp
                   2210: .Dl Pf . Sx \&Hf Ar filename
1.63      kristaps 2211: .Ss \&Ic
1.132     kristaps 2212: Designate an internal or interactive command.
                   2213: This is similar to
                   2214: .Sx \&Cm
                   2215: but used for instructions rather than values.
                   2216: .Pp
                   2217: Examples:
1.196     schwarze 2218: .Dl \&.Ic :wq
1.173     kristaps 2219: .Dl \&.Ic hash
                   2220: .Dl \&.Ic alias
1.132     kristaps 2221: .Pp
                   2222: Note that using
1.144     schwarze 2223: .Sx \&Bd Fl literal
1.132     kristaps 2224: or
                   2225: .Sx \&D1
                   2226: is preferred for displaying code; the
                   2227: .Sx \&Ic
                   2228: macro is used when referring to specific instructions.
1.63      kristaps 2229: .Ss \&In
1.118     kristaps 2230: An
1.138     kristaps 2231: .Dq include
1.118     kristaps 2232: file.
1.196     schwarze 2233: When invoked as the first macro on an input line in the
1.118     kristaps 2234: .Em SYNOPSIS
1.196     schwarze 2235: section, the argument is displayed in angle brackets
                   2236: and preceded by
1.138     kristaps 2237: .Dq #include ,
1.196     schwarze 2238: and a blank line is inserted in front if there is a preceding
                   2239: function declaration.
                   2240: This is most often used in section 2, 3, and 9 manual pages.
1.118     kristaps 2241: .Pp
1.122     kristaps 2242: Examples:
1.196     schwarze 2243: .Dl \&.In sys/types.h
1.122     kristaps 2244: .Pp
                   2245: See also
                   2246: .Sx MANUAL STRUCTURE .
1.63      kristaps 2247: .Ss \&It
1.120     kristaps 2248: A list item.
                   2249: The syntax of this macro depends on the list type.
1.114     kristaps 2250: .Pp
                   2251: Lists
                   2252: of type
                   2253: .Fl hang ,
                   2254: .Fl ohang ,
                   2255: .Fl inset ,
                   2256: and
                   2257: .Fl diag
1.120     kristaps 2258: have the following syntax:
1.114     kristaps 2259: .Pp
1.185     kristaps 2260: .D1 Pf \. Sx \&It Ar args
1.114     kristaps 2261: .Pp
                   2262: Lists of type
                   2263: .Fl bullet ,
                   2264: .Fl dash ,
                   2265: .Fl enum ,
                   2266: .Fl hyphen
                   2267: and
                   2268: .Fl item
1.120     kristaps 2269: have the following syntax:
1.114     kristaps 2270: .Pp
1.120     kristaps 2271: .D1 Pf \. Sx \&It
1.114     kristaps 2272: .Pp
                   2273: with subsequent lines interpreted within the scope of the
                   2274: .Sx \&It
                   2275: until either a closing
                   2276: .Sx \&El
                   2277: or another
                   2278: .Sx \&It .
                   2279: .Pp
                   2280: The
                   2281: .Fl tag
1.120     kristaps 2282: list has the following syntax:
1.114     kristaps 2283: .Pp
1.120     kristaps 2284: .D1 Pf \. Sx \&It Op Cm args
1.114     kristaps 2285: .Pp
1.120     kristaps 2286: Subsequent lines are interpreted as with
1.114     kristaps 2287: .Fl bullet
                   2288: and family.
                   2289: The line arguments correspond to the list's left-hand side; body
                   2290: arguments correspond to the list's contents.
                   2291: .Pp
                   2292: The
                   2293: .Fl column
                   2294: list is the most complicated.
1.120     kristaps 2295: Its syntax is as follows:
1.114     kristaps 2296: .Pp
1.190     schwarze 2297: .D1 Pf \. Sx \&It Ar cell Op <TAB> Ar cell ...
                   2298: .D1 Pf \. Sx \&It Ar cell Op Sx \&Ta Ar cell ...
1.114     kristaps 2299: .Pp
1.190     schwarze 2300: The arguments consist of one or more lines of text and macros
                   2301: representing a complete table line.
                   2302: Cells within the line are delimited by tabs or by the special
                   2303: .Sx \&Ta
                   2304: block macro.
                   2305: The tab cell delimiter may only be used within the
1.114     kristaps 2306: .Sx \&It
1.190     schwarze 2307: line itself; on following lines, only the
                   2308: .Sx \&Ta
                   2309: macro can be used to delimit cells, and
                   2310: .Sx \&Ta
                   2311: is only recognized as a macro when called by other macros,
                   2312: not as the first macro on a line.
                   2313: .Pp
                   2314: Note that quoted strings may span tab-delimited cells on an
1.114     kristaps 2315: .Sx \&It
1.190     schwarze 2316: line.
                   2317: For example,
1.114     kristaps 2318: .Pp
1.173     kristaps 2319: .Dl .It \(dqcol1 ; <TAB> col2 ;\(dq \&;
1.114     kristaps 2320: .Pp
                   2321: will preserve the semicolon whitespace except for the last.
                   2322: .Pp
                   2323: See also
                   2324: .Sx \&Bl .
1.63      kristaps 2325: .Ss \&Lb
1.109     kristaps 2326: Specify a library.
1.120     kristaps 2327: The syntax is as follows:
1.109     kristaps 2328: .Pp
1.185     kristaps 2329: .D1 Pf \. Sx \&Lb Ar library
1.109     kristaps 2330: .Pp
                   2331: The
1.185     kristaps 2332: .Ar library
1.109     kristaps 2333: parameter may be a system library, such as
1.193     schwarze 2334: .Cm libz
1.109     kristaps 2335: or
1.193     schwarze 2336: .Cm libpam ,
1.109     kristaps 2337: in which case a small library description is printed next to the linker
                   2338: invocation; or a custom library, in which case the library name is
                   2339: printed in quotes.
                   2340: This is most commonly used in the
                   2341: .Em SYNOPSIS
                   2342: section as described in
                   2343: .Sx MANUAL STRUCTURE .
                   2344: .Pp
                   2345: Examples:
1.173     kristaps 2346: .Dl \&.Lb libz
                   2347: .Dl \&.Lb mdoc
1.63      kristaps 2348: .Ss \&Li
1.198     schwarze 2349: Denotes text that should be in a
                   2350: .Li literal
                   2351: font mode.
1.131     kristaps 2352: Note that this is a presentation term and should not be used for
                   2353: stylistically decorating technical terms.
1.138     kristaps 2354: .Pp
1.198     schwarze 2355: On terminal output devices, this is often indistinguishable from
                   2356: normal text.
                   2357: .Pp
1.138     kristaps 2358: See also
                   2359: .Sx \&Bf ,
1.198     schwarze 2360: .Sx \&Em ,
                   2361: .Sx \&No ,
1.138     kristaps 2362: and
1.198     schwarze 2363: .Sx \&Sy .
1.63      kristaps 2364: .Ss \&Lk
1.100     kristaps 2365: Format a hyperlink.
1.120     kristaps 2366: Its syntax is as follows:
1.70      kristaps 2367: .Pp
1.185     kristaps 2368: .D1 Pf \. Sx \&Lk Ar uri Op Ar name
1.70      kristaps 2369: .Pp
                   2370: Examples:
1.203     kristaps 2371: .Dl \&.Lk http://bsd.lv \(dqThe BSD.lv Project\(dq
1.173     kristaps 2372: .Dl \&.Lk http://bsd.lv
1.70      kristaps 2373: .Pp
                   2374: See also
                   2375: .Sx \&Mt .
1.63      kristaps 2376: .Ss \&Lp
1.132     kristaps 2377: Synonym for
                   2378: .Sx \&Pp .
1.63      kristaps 2379: .Ss \&Ms
1.138     kristaps 2380: Display a mathematical symbol.
1.140     kristaps 2381: Its syntax is as follows:
                   2382: .Pp
1.185     kristaps 2383: .D1 Pf \. Sx \&Ms Ar symbol
1.138     kristaps 2384: .Pp
                   2385: Examples:
1.173     kristaps 2386: .Dl \&.Ms sigma
                   2387: .Dl \&.Ms aleph
1.63      kristaps 2388: .Ss \&Mt
1.116     kristaps 2389: Format a
1.138     kristaps 2390: .Dq mailto:
1.116     kristaps 2391: hyperlink.
1.120     kristaps 2392: Its syntax is as follows:
1.116     kristaps 2393: .Pp
1.185     kristaps 2394: .D1 Pf \. Sx \&Mt Ar address
1.116     kristaps 2395: .Pp
                   2396: Examples:
1.173     kristaps 2397: .Dl \&.Mt discuss@manpages.bsd.lv
1.63      kristaps 2398: .Ss \&Nd
1.144     schwarze 2399: A one line description of the manual's content.
1.132     kristaps 2400: This may only be invoked in the
                   2401: .Em SYNOPSIS
                   2402: section subsequent the
                   2403: .Sx \&Nm
                   2404: macro.
                   2405: .Pp
                   2406: Examples:
1.198     schwarze 2407: .Dl Pf . Sx \&Nd mdoc language reference
                   2408: .Dl Pf . Sx \&Nd format and display UNIX manuals
1.132     kristaps 2409: .Pp
                   2410: The
                   2411: .Sx \&Nd
                   2412: macro technically accepts child macros and terminates with a subsequent
                   2413: .Sx \&Sh
                   2414: invocation.
                   2415: Do not assume this behaviour: some
                   2416: .Xr whatis 1
                   2417: database generators are not smart enough to parse more than the line
                   2418: arguments and will display macros verbatim.
                   2419: .Pp
                   2420: See also
                   2421: .Sx \&Nm .
1.63      kristaps 2422: .Ss \&Nm
1.128     schwarze 2423: The name of the manual page, or \(em in particular in section 1, 6,
                   2424: and 8 pages \(em of an additional command or feature documented in
                   2425: the manual page.
                   2426: When first invoked, the
                   2427: .Sx \&Nm
                   2428: macro expects a single argument, the name of the manual page.
                   2429: Usually, the first invocation happens in the
                   2430: .Em NAME
                   2431: section of the page.
                   2432: The specified name will be remembered and used whenever the macro is
                   2433: called again without arguments later in the page.
                   2434: The
                   2435: .Sx \&Nm
                   2436: macro uses
                   2437: .Sx Block full-implicit
                   2438: semantics when invoked as the first macro on an input line in the
                   2439: .Em SYNOPSIS
                   2440: section; otherwise, it uses ordinary
                   2441: .Sx In-line
                   2442: semantics.
                   2443: .Pp
                   2444: Examples:
                   2445: .Bd -literal -offset indent
                   2446: \&.Sh SYNOPSIS
                   2447: \&.Nm cat
                   2448: \&.Op Fl benstuv
                   2449: \&.Op Ar
                   2450: .Ed
                   2451: .Pp
                   2452: In the
                   2453: .Em SYNOPSIS
                   2454: of section 2, 3 and 9 manual pages, use the
                   2455: .Sx \&Fn
                   2456: macro rather than
                   2457: .Sx \&Nm
                   2458: to mark up the name of the manual page.
1.63      kristaps 2459: .Ss \&No
1.198     schwarze 2460: Normal text.
                   2461: Closes the scope of any preceding in-line macro.
                   2462: When used after physical formatting macros like
                   2463: .Sx \&Em
                   2464: or
                   2465: .Sx \&Sy ,
                   2466: switches back to the standard font face and weight.
                   2467: Can also be used to embed plain text strings in macro lines
                   2468: using semantic annotation macros.
1.132     kristaps 2469: .Pp
                   2470: Examples:
1.198     schwarze 2471: .Dl ".Em italic , Sy bold , No and roman"
                   2472: .Pp
                   2473: .Bd -literal -offset indent -compact
                   2474: \&.Sm off
                   2475: \&.Cm :C No / Ar pattern No / Ar replacement No /
                   2476: \&.Sm on
                   2477: .Ed
                   2478: .Pp
                   2479: See also
                   2480: .Sx \&Em ,
                   2481: .Sx \&Li ,
                   2482: and
                   2483: .Sx \&Sy .
1.63      kristaps 2484: .Ss \&Ns
1.198     schwarze 2485: Suppress a space between the output of the preceding macro
                   2486: and the following text or macro.
                   2487: Following invocation, input is interpreted as normal text
                   2488: just like after an
                   2489: .Sx \&No
                   2490: macro.
1.178     kristaps 2491: .Pp
                   2492: This has no effect when invoked at the start of a macro line.
1.138     kristaps 2493: .Pp
                   2494: Examples:
1.198     schwarze 2495: .Dl ".Ar name Ns = Ns Ar value"
                   2496: .Dl ".Cm :M Ns Ar pattern"
                   2497: .Dl ".Fl o Ns Ar output"
1.138     kristaps 2498: .Pp
                   2499: See also
                   2500: .Sx \&No
                   2501: and
                   2502: .Sx \&Sm .
1.63      kristaps 2503: .Ss \&Nx
1.144     schwarze 2504: Format the
                   2505: .Nx
                   2506: version provided as an argument, or a default value if
1.65      kristaps 2507: no argument is provided.
                   2508: .Pp
                   2509: Examples:
1.173     kristaps 2510: .Dl \&.Nx 5.01
                   2511: .Dl \&.Nx
1.65      kristaps 2512: .Pp
                   2513: See also
                   2514: .Sx \&At ,
1.66      kristaps 2515: .Sx \&Bsx ,
1.65      kristaps 2516: .Sx \&Bx ,
1.66      kristaps 2517: .Sx \&Dx ,
1.65      kristaps 2518: .Sx \&Fx ,
                   2519: .Sx \&Ox ,
                   2520: and
                   2521: .Sx \&Ux .
1.63      kristaps 2522: .Ss \&Oc
1.141     kristaps 2523: Close multi-line
1.132     kristaps 2524: .Sx \&Oo
                   2525: context.
1.63      kristaps 2526: .Ss \&Oo
1.132     kristaps 2527: Multi-line version of
                   2528: .Sx \&Op .
                   2529: .Pp
                   2530: Examples:
1.138     kristaps 2531: .Bd -literal -offset indent -compact
1.132     kristaps 2532: \&.Oo
                   2533: \&.Op Fl flag Ns Ar value
                   2534: \&.Oc
                   2535: .Ed
1.63      kristaps 2536: .Ss \&Op
1.196     schwarze 2537: Optional part of a command line.
1.132     kristaps 2538: Prints the argument(s) in brackets.
1.196     schwarze 2539: This is most often used in the
                   2540: .Em SYNOPSIS
                   2541: section of section 1 and 8 manual pages.
1.132     kristaps 2542: .Pp
                   2543: Examples:
1.173     kristaps 2544: .Dl \&.Op \&Fl a \&Ar b
                   2545: .Dl \&.Op \&Ar a | b
1.132     kristaps 2546: .Pp
                   2547: See also
                   2548: .Sx \&Oo .
1.63      kristaps 2549: .Ss \&Os
1.100     kristaps 2550: Document operating system version.
                   2551: This is the mandatory third macro of
1.66      kristaps 2552: any
                   2553: .Nm
1.120     kristaps 2554: file.
                   2555: Its syntax is as follows:
1.66      kristaps 2556: .Pp
1.185     kristaps 2557: .D1 Pf \. Sx \&Os Op Ar system Op Ar version
1.66      kristaps 2558: .Pp
                   2559: The optional
1.185     kristaps 2560: .Ar system
1.100     kristaps 2561: parameter specifies the relevant operating system or environment.
                   2562: Left unspecified, it defaults to the local operating system version.
                   2563: This is the suggested form.
1.66      kristaps 2564: .Pp
                   2565: Examples:
1.173     kristaps 2566: .Dl \&.Os
                   2567: .Dl \&.Os KTH/CSC/TCS
                   2568: .Dl \&.Os BSD 4.3
1.66      kristaps 2569: .Pp
                   2570: See also
                   2571: .Sx \&Dd
                   2572: and
                   2573: .Sx \&Dt .
1.63      kristaps 2574: .Ss \&Ot
1.198     schwarze 2575: This macro is obsolete and not implemented in
                   2576: .Xr mandoc 1 .
1.66      kristaps 2577: .Pp
1.198     schwarze 2578: Historical
                   2579: .Xr mdoc 7
                   2580: packages described it as
                   2581: .Dq "old function type (FORTRAN)" .
1.63      kristaps 2582: .Ss \&Ox
1.144     schwarze 2583: Format the
                   2584: .Ox
                   2585: version provided as an argument, or a default value
1.65      kristaps 2586: if no argument is provided.
                   2587: .Pp
                   2588: Examples:
1.173     kristaps 2589: .Dl \&.Ox 4.5
                   2590: .Dl \&.Ox
1.65      kristaps 2591: .Pp
                   2592: See also
                   2593: .Sx \&At ,
                   2594: .Sx \&Bsx ,
                   2595: .Sx \&Bx ,
1.66      kristaps 2596: .Sx \&Dx ,
1.65      kristaps 2597: .Sx \&Fx ,
                   2598: .Sx \&Nx ,
                   2599: and
                   2600: .Sx \&Ux .
1.63      kristaps 2601: .Ss \&Pa
1.196     schwarze 2602: An absolute or relative file system path, or a file or directory name.
                   2603: If an argument is not provided, the character
                   2604: .Sq \(ti
1.165     kristaps 2605: is used as a default.
1.132     kristaps 2606: .Pp
                   2607: Examples:
1.173     kristaps 2608: .Dl \&.Pa /usr/bin/mandoc
                   2609: .Dl \&.Pa /usr/share/man/man7/mdoc.7
1.132     kristaps 2610: .Pp
                   2611: See also
                   2612: .Sx \&Lk .
1.63      kristaps 2613: .Ss \&Pc
1.132     kristaps 2614: Close parenthesised context opened by
                   2615: .Sx \&Po .
1.63      kristaps 2616: .Ss \&Pf
1.198     schwarze 2617: Removes the space between its argument
1.138     kristaps 2618: .Pq Dq prefix
1.198     schwarze 2619: and the following macro.
1.132     kristaps 2620: Its syntax is as follows:
                   2621: .Pp
1.198     schwarze 2622: .D1 .Pf Ar prefix macro arguments ...
                   2623: .Pp
                   2624: This is equivalent to:
1.132     kristaps 2625: .Pp
1.198     schwarze 2626: .D1 .No Ar prefix No \&Ns Ar macro arguments ...
1.132     kristaps 2627: .Pp
                   2628: Examples:
1.198     schwarze 2629: .Dl ".Pf $ Ar variable_name"
                   2630: .Dl ".Pf 0x Ar hex_digits"
                   2631: .Pp
                   2632: See also
                   2633: .Sx \&Ns
                   2634: and
                   2635: .Sx \&Sm .
1.63      kristaps 2636: .Ss \&Po
1.132     kristaps 2637: Multi-line version of
                   2638: .Sx \&Pq .
1.63      kristaps 2639: .Ss \&Pp
1.132     kristaps 2640: Break a paragraph.
                   2641: This will assert vertical space between prior and subsequent macros
                   2642: and/or text.
1.198     schwarze 2643: .Pp
                   2644: Paragraph breaks are not needed before or after
                   2645: .Sx \&Sh
                   2646: or
                   2647: .Sx \&Ss
                   2648: macros or before displays
                   2649: .Pq Sx \&Bd
                   2650: or lists
                   2651: .Pq Sx \&Bl
                   2652: unless the
                   2653: .Fl compact
                   2654: flag is given.
1.63      kristaps 2655: .Ss \&Pq
1.132     kristaps 2656: Parenthesised enclosure.
                   2657: .Pp
                   2658: See also
                   2659: .Sx \&Po .
1.63      kristaps 2660: .Ss \&Qc
1.138     kristaps 2661: Close quoted context opened by
                   2662: .Sx \&Qo .
1.63      kristaps 2663: .Ss \&Ql
1.138     kristaps 2664: Format a single-quoted literal.
                   2665: See also
                   2666: .Sx \&Qq
                   2667: and
                   2668: .Sx \&Sq .
1.63      kristaps 2669: .Ss \&Qo
1.138     kristaps 2670: Multi-line version of
                   2671: .Sx \&Qq .
1.63      kristaps 2672: .Ss \&Qq
1.138     kristaps 2673: Encloses its arguments in
1.198     schwarze 2674: .Qq typewriter
1.138     kristaps 2675: double-quotes.
                   2676: Consider using
                   2677: .Sx \&Dq .
                   2678: .Pp
                   2679: See also
                   2680: .Sx \&Dq ,
                   2681: .Sx \&Sq ,
                   2682: and
                   2683: .Sx \&Qo .
1.63      kristaps 2684: .Ss \&Re
1.141     kristaps 2685: Close an
1.63      kristaps 2686: .Sx \&Rs
1.100     kristaps 2687: block.
                   2688: Does not have any tail arguments.
1.63      kristaps 2689: .Ss \&Rs
1.141     kristaps 2690: Begin a bibliographic
1.63      kristaps 2691: .Pq Dq reference
1.100     kristaps 2692: block.
                   2693: Does not have any head arguments.
                   2694: The block macro may only contain
1.63      kristaps 2695: .Sx \&%A ,
                   2696: .Sx \&%B ,
                   2697: .Sx \&%C ,
                   2698: .Sx \&%D ,
                   2699: .Sx \&%I ,
                   2700: .Sx \&%J ,
                   2701: .Sx \&%N ,
                   2702: .Sx \&%O ,
                   2703: .Sx \&%P ,
                   2704: .Sx \&%Q ,
                   2705: .Sx \&%R ,
                   2706: .Sx \&%T ,
1.120     kristaps 2707: .Sx \&%U ,
1.63      kristaps 2708: and
                   2709: .Sx \&%V
                   2710: child macros (at least one must be specified).
                   2711: .Pp
1.64      kristaps 2712: Examples:
1.91      kristaps 2713: .Bd -literal -offset indent -compact
1.63      kristaps 2714: \&.Rs
                   2715: \&.%A J. E. Hopcroft
                   2716: \&.%A J. D. Ullman
                   2717: \&.%B Introduction to Automata Theory, Languages, and Computation
                   2718: \&.%I Addison-Wesley
                   2719: \&.%C Reading, Massachusettes
                   2720: \&.%D 1979
                   2721: \&.Re
                   2722: .Ed
                   2723: .Pp
                   2724: If an
                   2725: .Sx \&Rs
                   2726: block is used within a SEE ALSO section, a vertical space is asserted
                   2727: before the rendered output, else the block continues on the current
                   2728: line.
                   2729: .Ss \&Rv
1.193     schwarze 2730: Insert a standard sentence regarding a function call's return value of 0
1.191     kristaps 2731: on success and \-1 on error, with the
                   2732: .Va errno
                   2733: libc global variable set on error.
                   2734: Its syntax is as follows:
                   2735: .Pp
1.193     schwarze 2736: .D1 Pf \. Sx \&Rv Fl std Op Ar function ...
1.191     kristaps 2737: .Pp
1.139     kristaps 2738: If
                   2739: .Ar function
1.191     kristaps 2740: is not specified, the document's name set by
1.139     kristaps 2741: .Sx \&Nm
1.191     kristaps 2742: is used.
                   2743: Multiple
                   2744: .Ar function
                   2745: arguments are treated as separate functions.
1.139     kristaps 2746: .Pp
                   2747: See also
                   2748: .Sx \&Ex .
1.63      kristaps 2749: .Ss \&Sc
1.138     kristaps 2750: Close single-quoted context opened by
                   2751: .Sx \&So .
1.63      kristaps 2752: .Ss \&Sh
1.138     kristaps 2753: Begin a new section.
                   2754: For a list of conventional manual sections, see
                   2755: .Sx MANUAL STRUCTURE .
                   2756: These sections should be used unless it's absolutely necessary that
                   2757: custom sections be used.
                   2758: .Pp
                   2759: Section names should be unique so that they may be keyed by
                   2760: .Sx \&Sx .
1.197     kristaps 2761: Although this macro is parsed, it should not consist of child node or it
                   2762: may not be linked with
                   2763: .Sx \&Sx .
1.138     kristaps 2764: .Pp
                   2765: See also
                   2766: .Sx \&Pp ,
                   2767: .Sx \&Ss ,
                   2768: and
                   2769: .Sx \&Sx .
1.63      kristaps 2770: .Ss \&Sm
1.134     schwarze 2771: Switches the spacing mode for output generated from macros.
                   2772: Its syntax is as follows:
                   2773: .Pp
                   2774: .D1 Pf \. Sx \&Sm Cm on | off
                   2775: .Pp
                   2776: By default, spacing is
1.193     schwarze 2777: .Cm on .
1.134     schwarze 2778: When switched
1.193     schwarze 2779: .Cm off ,
1.134     schwarze 2780: no white space is inserted between macro arguments and between the
1.185     kristaps 2781: output generated from adjacent macros, but text lines
1.134     schwarze 2782: still get normal spacing between words and sentences.
1.63      kristaps 2783: .Ss \&So
1.138     kristaps 2784: Multi-line version of
                   2785: .Sx \&Sq .
1.63      kristaps 2786: .Ss \&Sq
1.138     kristaps 2787: Encloses its arguments in
1.198     schwarze 2788: .Sq typewriter
1.138     kristaps 2789: single-quotes.
                   2790: .Pp
                   2791: See also
                   2792: .Sx \&Dq ,
                   2793: .Sx \&Qq ,
                   2794: and
                   2795: .Sx \&So .
1.63      kristaps 2796: .Ss \&Ss
1.198     schwarze 2797: Begin a new subsection.
1.138     kristaps 2798: Unlike with
                   2799: .Sx \&Sh ,
1.198     schwarze 2800: there is no convention for the naming of subsections.
                   2801: Except
                   2802: .Em DESCRIPTION ,
                   2803: the conventional sections described in
                   2804: .Sx MANUAL STRUCTURE
                   2805: rarely have subsections.
1.138     kristaps 2806: .Pp
                   2807: Sub-section names should be unique so that they may be keyed by
1.197     kristaps 2808: .Sx \&Sx .
                   2809: Although this macro is parsed, it should not consist of child node or it
                   2810: may not be linked with
1.138     kristaps 2811: .Sx \&Sx .
                   2812: .Pp
                   2813: See also
                   2814: .Sx \&Pp ,
                   2815: .Sx \&Sh ,
                   2816: and
                   2817: .Sx \&Sx .
1.63      kristaps 2818: .Ss \&St
1.139     kristaps 2819: Replace an abbreviation for a standard with the full form.
                   2820: The following standards are recognised:
                   2821: .Pp
                   2822: .Bl -tag -width "-p1003.1g-2000X" -compact
                   2823: .It \-p1003.1-88
                   2824: .St -p1003.1-88
                   2825: .It \-p1003.1-90
                   2826: .St -p1003.1-90
                   2827: .It \-p1003.1-96
                   2828: .St -p1003.1-96
                   2829: .It \-p1003.1-2001
                   2830: .St -p1003.1-2001
                   2831: .It \-p1003.1-2004
                   2832: .St -p1003.1-2004
                   2833: .It \-p1003.1-2008
                   2834: .St -p1003.1-2008
                   2835: .It \-p1003.1
                   2836: .St -p1003.1
                   2837: .It \-p1003.1b
                   2838: .St -p1003.1b
                   2839: .It \-p1003.1b-93
                   2840: .St -p1003.1b-93
                   2841: .It \-p1003.1c-95
                   2842: .St -p1003.1c-95
                   2843: .It \-p1003.1g-2000
                   2844: .St -p1003.1g-2000
                   2845: .It \-p1003.1i-95
                   2846: .St -p1003.1i-95
                   2847: .It \-p1003.2-92
                   2848: .St -p1003.2-92
                   2849: .It \-p1003.2a-92
                   2850: .St -p1003.2a-92
                   2851: .It \-p1387.2-95
                   2852: .St -p1387.2-95
                   2853: .It \-p1003.2
                   2854: .St -p1003.2
                   2855: .It \-p1387.2
                   2856: .St -p1387.2
                   2857: .It \-isoC
                   2858: .St -isoC
                   2859: .It \-isoC-90
                   2860: .St -isoC-90
                   2861: .It \-isoC-amd1
                   2862: .St -isoC-amd1
                   2863: .It \-isoC-tcor1
                   2864: .St -isoC-tcor1
                   2865: .It \-isoC-tcor2
                   2866: .St -isoC-tcor2
                   2867: .It \-isoC-99
                   2868: .St -isoC-99
                   2869: .It \-iso9945-1-90
                   2870: .St -iso9945-1-90
                   2871: .It \-iso9945-1-96
                   2872: .St -iso9945-1-96
                   2873: .It \-iso9945-2-93
                   2874: .St -iso9945-2-93
                   2875: .It \-ansiC
                   2876: .St -ansiC
                   2877: .It \-ansiC-89
                   2878: .St -ansiC-89
                   2879: .It \-ansiC-99
                   2880: .St -ansiC-99
                   2881: .It \-ieee754
                   2882: .St -ieee754
                   2883: .It \-iso8802-3
                   2884: .St -iso8802-3
                   2885: .It \-ieee1275-94
                   2886: .St -ieee1275-94
                   2887: .It \-xpg3
                   2888: .St -xpg3
                   2889: .It \-xpg4
                   2890: .St -xpg4
                   2891: .It \-xpg4.2
                   2892: .St -xpg4.2
1.196     schwarze 2893: .It \-xpg4.3
1.139     kristaps 2894: .St -xpg4.3
                   2895: .It \-xbd5
                   2896: .St -xbd5
                   2897: .It \-xcu5
                   2898: .St -xcu5
                   2899: .It \-xsh5
                   2900: .St -xsh5
                   2901: .It \-xns5
                   2902: .St -xns5
                   2903: .It \-xns5.2
                   2904: .St -xns5.2
                   2905: .It \-xns5.2d2.0
                   2906: .St -xns5.2d2.0
                   2907: .It \-xcurses4.2
                   2908: .St -xcurses4.2
                   2909: .It \-susv2
                   2910: .St -susv2
                   2911: .It \-susv3
                   2912: .St -susv3
                   2913: .It \-svid4
                   2914: .St -svid4
                   2915: .El
1.63      kristaps 2916: .Ss \&Sx
1.198     schwarze 2917: Reference a section or subsection in the same manual page.
                   2918: The referenced section or subsection name must be identical to the
1.138     kristaps 2919: enclosed argument, including whitespace.
                   2920: .Pp
                   2921: Examples:
1.173     kristaps 2922: .Dl \&.Sx MANUAL STRUCTURE
1.172     kristaps 2923: .Pp
                   2924: See also
                   2925: .Sx \&Sh
                   2926: and
                   2927: .Sx \&Ss .
1.63      kristaps 2928: .Ss \&Sy
1.138     kristaps 2929: Format enclosed arguments in symbolic
                   2930: .Pq Dq boldface .
                   2931: Note that this is a presentation term and should not be used for
                   2932: stylistically decorating technical terms.
                   2933: .Pp
                   2934: See also
                   2935: .Sx \&Bf ,
1.198     schwarze 2936: .Sx \&Em ,
1.138     kristaps 2937: .Sx \&Li ,
                   2938: and
1.198     schwarze 2939: .Sx \&No .
1.190     schwarze 2940: .Ss \&Ta
                   2941: Table cell separator in
                   2942: .Sx \&Bl Fl column
                   2943: lists; can only be used below
                   2944: .Sx \&It .
1.63      kristaps 2945: .Ss \&Tn
1.138     kristaps 2946: Format a tradename.
                   2947: .Pp
1.198     schwarze 2948: Since this macro is often implemented to use a small caps font,
                   2949: it has historically been used for acronyms (like ASCII) as well.
                   2950: Such usage is not recommended because it would use the same macro
                   2951: sometimes for semantical annotation, sometimes for physical formatting.
                   2952: .Pp
1.138     kristaps 2953: Examples:
1.173     kristaps 2954: .Dl \&.Tn IBM
1.63      kristaps 2955: .Ss \&Ud
1.110     kristaps 2956: Prints out
1.198     schwarze 2957: .Dq currently under development.
1.63      kristaps 2958: .Ss \&Ux
1.100     kristaps 2959: Format the UNIX name.
                   2960: Accepts no argument.
1.65      kristaps 2961: .Pp
                   2962: Examples:
1.173     kristaps 2963: .Dl \&.Ux
1.65      kristaps 2964: .Pp
                   2965: See also
                   2966: .Sx \&At ,
1.66      kristaps 2967: .Sx \&Bsx ,
1.65      kristaps 2968: .Sx \&Bx ,
1.66      kristaps 2969: .Sx \&Dx ,
1.65      kristaps 2970: .Sx \&Fx ,
                   2971: .Sx \&Nx ,
                   2972: and
                   2973: .Sx \&Ox .
1.63      kristaps 2974: .Ss \&Va
1.132     kristaps 2975: A variable name.
                   2976: .Pp
                   2977: Examples:
1.173     kristaps 2978: .Dl \&.Va foo
                   2979: .Dl \&.Va const char *bar ;
1.63      kristaps 2980: .Ss \&Vt
1.100     kristaps 2981: A variable type.
1.122     kristaps 2982: This is also used for indicating global variables in the
                   2983: .Em SYNOPSIS
1.100     kristaps 2984: section, in which case a variable name is also specified.
                   2985: Note that it accepts
1.83      kristaps 2986: .Sx Block partial-implicit
1.196     schwarze 2987: syntax when invoked as the first macro on an input line in the
1.122     kristaps 2988: .Em SYNOPSIS
                   2989: section, else it accepts ordinary
1.83      kristaps 2990: .Sx In-line
                   2991: syntax.
1.196     schwarze 2992: In the former case, this macro starts a new output line,
                   2993: and a blank line is inserted in front if there is a preceding
                   2994: function definition or include directive.
1.83      kristaps 2995: .Pp
                   2996: Note that this should not be confused with
                   2997: .Sx \&Ft ,
                   2998: which is used for function return types.
                   2999: .Pp
                   3000: Examples:
1.173     kristaps 3001: .Dl \&.Vt unsigned char
                   3002: .Dl \&.Vt extern const char * const sys_signame[] \&;
1.83      kristaps 3003: .Pp
                   3004: See also
1.122     kristaps 3005: .Sx MANUAL STRUCTURE
1.83      kristaps 3006: and
                   3007: .Sx \&Va .
1.84      kristaps 3008: .Ss \&Xc
1.87      kristaps 3009: Close a scope opened by
                   3010: .Sx \&Xo .
1.84      kristaps 3011: .Ss \&Xo
1.170     schwarze 3012: Extend the header of an
                   3013: .Sx \&It
                   3014: macro or the body of a partial-implicit block macro
                   3015: beyond the end of the input line.
                   3016: This macro originally existed to work around the 9-argument limit
                   3017: of historic
                   3018: .Xr roff 7 .
1.84      kristaps 3019: .Ss \&Xr
                   3020: Link to another manual
                   3021: .Pq Qq cross-reference .
1.120     kristaps 3022: Its syntax is as follows:
1.84      kristaps 3023: .Pp
1.185     kristaps 3024: .D1 Pf \. Sx \&Xr Ar name section
1.84      kristaps 3025: .Pp
                   3026: The
1.185     kristaps 3027: .Ar name
1.84      kristaps 3028: and
1.185     kristaps 3029: .Ar section
1.100     kristaps 3030: are the name and section of the linked manual.
                   3031: If
1.185     kristaps 3032: .Ar section
1.84      kristaps 3033: is followed by non-punctuation, an
                   3034: .Sx \&Ns
1.100     kristaps 3035: is inserted into the token stream.
                   3036: This behaviour is for compatibility with
1.148     kristaps 3037: GNU troff.
1.84      kristaps 3038: .Pp
                   3039: Examples:
1.173     kristaps 3040: .Dl \&.Xr mandoc 1
                   3041: .Dl \&.Xr mandoc 1 \&;
                   3042: .Dl \&.Xr mandoc 1 \&Ns s behaviour
1.84      kristaps 3043: .Ss \&br
1.140     kristaps 3044: Emits a line-break.
                   3045: This macro should not be used; it is implemented for compatibility with
                   3046: historical manuals.
                   3047: .Pp
                   3048: Consider using
                   3049: .Sx \&Pp
                   3050: in the event of natural paragraph breaks.
1.84      kristaps 3051: .Ss \&sp
1.140     kristaps 3052: Emits vertical space.
                   3053: This macro should not be used; it is implemented for compatibility with
                   3054: historical manuals.
                   3055: Its syntax is as follows:
                   3056: .Pp
1.185     kristaps 3057: .D1 Pf \. Sx \&sp Op Ar height
1.140     kristaps 3058: .Pp
                   3059: The
1.185     kristaps 3060: .Ar height
1.140     kristaps 3061: argument must be formatted as described in
                   3062: .Sx Scaling Widths .
                   3063: If unspecified,
                   3064: .Sx \&sp
                   3065: asserts a single vertical space.
1.4       kristaps 3066: .Sh COMPATIBILITY
1.93      kristaps 3067: This section documents compatibility between mandoc and other other
                   3068: troff implementations, at this time limited to GNU troff
                   3069: .Pq Qq groff .
1.50      kristaps 3070: The term
1.57      kristaps 3071: .Qq historic groff
1.166     schwarze 3072: refers to groff versions before 1.17,
                   3073: which featured a significant update of the
1.57      kristaps 3074: .Pa doc.tmac
1.166     schwarze 3075: file.
1.57      kristaps 3076: .Pp
1.93      kristaps 3077: Heirloom troff, the other significant troff implementation accepting
                   3078: \-mdoc, is similar to historic groff.
                   3079: .Pp
1.150     kristaps 3080: The following problematic behaviour is found in groff:
                   3081: .ds hist (Historic groff only.)
                   3082: .Pp
1.57      kristaps 3083: .Bl -dash -compact
1.168     kristaps 3084: .It
                   3085: Display macros
1.171     schwarze 3086: .Po
                   3087: .Sx \&Bd ,
                   3088: .Sx \&Dl ,
                   3089: and
                   3090: .Sx \&D1
                   3091: .Pc
1.168     kristaps 3092: may not be nested.
                   3093: \*[hist]
1.147     kristaps 3094: .It
1.150     kristaps 3095: .Sx \&At
                   3096: with unknown arguments produces no output at all.
                   3097: \*[hist]
                   3098: Newer groff and mandoc print
                   3099: .Qq AT&T UNIX
                   3100: and the arguments.
1.149     kristaps 3101: .It
1.190     schwarze 3102: .Sx \&Bl Fl column
1.150     kristaps 3103: does not recognize trailing punctuation characters when they immediately
                   3104: precede tabulator characters, but treats them as normal text and
                   3105: outputs a space before them.
                   3106: .It
                   3107: .Sx \&Bd Fl ragged compact
                   3108: does not start a new line.
                   3109: \*[hist]
1.142     kristaps 3110: .It
1.150     kristaps 3111: .Sx \&Dd
1.181     schwarze 3112: with non-standard arguments behaves very strangely.
                   3113: When there are three arguments, they are printed verbatim.
                   3114: Any other number of arguments is replaced by the current date,
                   3115: but without any arguments the string
                   3116: .Dq Epoch
                   3117: is printed.
1.125     kristaps 3118: .It
1.150     kristaps 3119: .Sx \&Fl
                   3120: does not print a dash for an empty argument.
                   3121: \*[hist]
1.137     kristaps 3122: .It
1.150     kristaps 3123: .Sx \&Fn
                   3124: does not start a new line unless invoked as the line macro in the
                   3125: .Em SYNOPSIS
                   3126: section.
                   3127: \*[hist]
1.119     kristaps 3128: .It
1.150     kristaps 3129: .Sx \&Fo
                   3130: with
1.120     kristaps 3131: .Pf non- Sx \&Fa
1.150     kristaps 3132: children causes inconsistent spacing between arguments.
                   3133: In mandoc, a single space is always inserted between arguments.
1.120     kristaps 3134: .It
                   3135: .Sx \&Ft
                   3136: in the
1.150     kristaps 3137: .Em SYNOPSIS
                   3138: causes inconsistent vertical spacing, depending on whether a prior
1.120     kristaps 3139: .Sx \&Fn
                   3140: has been invoked.
                   3141: See
                   3142: .Sx \&Ft
                   3143: and
                   3144: .Sx \&Fn
1.150     kristaps 3145: for the normalised behaviour in mandoc.
1.120     kristaps 3146: .It
1.150     kristaps 3147: .Sx \&In
                   3148: ignores additional arguments and is not treated specially in the
                   3149: .Em SYNOPSIS .
                   3150: \*[hist]
1.118     kristaps 3151: .It
1.150     kristaps 3152: .Sx \&It
                   3153: sometimes requires a
                   3154: .Fl nested
                   3155: flag.
                   3156: \*[hist]
                   3157: In new groff and mandoc, any list may be nested by default and
                   3158: .Fl enum
                   3159: lists will restart the sequence only for the sub-list.
1.115     kristaps 3160: .It
1.150     kristaps 3161: .Sx \&Li
1.195     schwarze 3162: followed by a delimiter is incorrectly used in some manuals
1.150     kristaps 3163: instead of properly quoting that character, which sometimes works with
                   3164: historic groff.
1.57      kristaps 3165: .It
1.150     kristaps 3166: .Sx \&Lk
                   3167: only accepts a single link-name argument; the remainder is misformatted.
1.81      kristaps 3168: .It
1.80      kristaps 3169: .Sx \&Pa
1.150     kristaps 3170: does not format its arguments when used in the FILES section under
1.100     kristaps 3171: certain list types.
1.80      kristaps 3172: .It
1.150     kristaps 3173: .Sx \&Ta
                   3174: can only be called by other macros, but not at the beginning of a line.
                   3175: .It
                   3176: .Sx \&%C
                   3177: is not implemented.
1.166     schwarze 3178: .It
                   3179: Historic groff only allows up to eight or nine arguments per macro input
                   3180: line, depending on the exact situation.
                   3181: Providing more arguments causes garbled output.
                   3182: The number of arguments on one input line is not limited with mandoc.
1.150     kristaps 3183: .It
                   3184: Historic groff has many un-callable macros.
                   3185: Most of these (excluding some block-level macros) are callable
                   3186: in new groff and mandoc.
                   3187: .It
                   3188: .Sq \(ba
                   3189: (vertical bar) is not fully supported as a delimiter.
                   3190: \*[hist]
1.79      kristaps 3191: .It
1.77      kristaps 3192: .Sq \ef
1.150     kristaps 3193: .Pq font face
                   3194: and
                   3195: .Sq \ef
                   3196: .Pq font family face
1.93      kristaps 3197: .Sx Text Decoration
1.150     kristaps 3198: escapes behave irregularly when specified within line-macro scopes.
1.77      kristaps 3199: .It
1.150     kristaps 3200: Negative scaling units return to prior lines.
                   3201: Instead, mandoc truncates them to zero.
                   3202: .El
                   3203: .Pp
                   3204: The following features are unimplemented in mandoc:
                   3205: .Pp
                   3206: .Bl -dash -compact
1.61      kristaps 3207: .It
1.150     kristaps 3208: .Sx \&Bd
                   3209: .Fl file Ar file .
1.57      kristaps 3210: .It
1.78      kristaps 3211: .Sx \&Bd
1.126     kristaps 3212: .Fl offset Ar center
1.64      kristaps 3213: and
1.150     kristaps 3214: .Fl offset Ar right .
                   3215: Groff does not implement centered and flush-right rendering either,
                   3216: but produces large indentations.
                   3217: .It
                   3218: The
                   3219: .Sq \eh
                   3220: .Pq horizontal position ,
                   3221: .Sq \ev
                   3222: .Pq vertical position ,
                   3223: .Sq \em
                   3224: .Pq text colour ,
                   3225: .Sq \eM
                   3226: .Pq text filling colour ,
1.152     kristaps 3227: .Sq \ez
                   3228: .Pq zero-length character ,
1.153     kristaps 3229: .Sq \ew
                   3230: .Pq string length ,
1.154     kristaps 3231: .Sq \ek
                   3232: .Pq horizontal position marker ,
1.157     kristaps 3233: .Sq \eo
                   3234: .Pq text overstrike ,
1.64      kristaps 3235: and
1.150     kristaps 3236: .Sq \es
                   3237: .Pq text size
1.153     kristaps 3238: escape sequences are all discarded in mandoc.
1.57      kristaps 3239: .It
1.150     kristaps 3240: The
                   3241: .Sq \ef
                   3242: scaling unit is accepted by mandoc, but rendered as the default unit.
1.57      kristaps 3243: .It
1.150     kristaps 3244: In quoted literals, groff allows pairwise double-quotes to produce a
                   3245: standalone double-quote in formatted output.
                   3246: This is not supported by mandoc.
1.57      kristaps 3247: .El
1.2       kristaps 3248: .Sh SEE ALSO
1.159     schwarze 3249: .Xr man 1 ,
1.57      kristaps 3250: .Xr mandoc 1 ,
1.180     kristaps 3251: .Xr eqn 7 ,
1.174     kristaps 3252: .Xr man 7 ,
1.198     schwarze 3253: .Xr mandoc_char 7 ,
1.174     kristaps 3254: .Xr roff 7 ,
                   3255: .Xr tbl 7
1.151     kristaps 3256: .Sh HISTORY
                   3257: The
                   3258: .Nm
                   3259: language first appeared as a troff macro package in
                   3260: .Bx 4.4 .
                   3261: It was later significantly updated by Werner Lemberg and Ruslan Ermilov
1.155     kristaps 3262: in groff-1.17.
1.151     kristaps 3263: The standalone implementation that is part of the
                   3264: .Xr mandoc 1
                   3265: utility written by Kristaps Dzonsons appeared in
                   3266: .Ox 4.6 .
1.2       kristaps 3267: .Sh AUTHORS
                   3268: The
1.57      kristaps 3269: .Nm
1.50      kristaps 3270: reference was written by
1.202     kristaps 3271: .An Kristaps Dzonsons ,
                   3272: .Mt kristaps@bsd.lv .

CVSweb