ROFF(5) Standards, Environments, and Macros ROFF(5) NNAAMMEE rrooffff - roff language reference for mandoc DDEESSCCRRIIPPTTIIOONN The rrooffff language is a general purpose text formatting language. Since traditional implementations of the mdoc(5) and man(5) manual formatting languages are based on it, many real-world manuals use small numbers of rrooffff requests and escape sequences intermixed with their mdoc(5) or man(5) code. To properly format such manuals, the mandoc(1) utility supports a tiny subset of rrooffff requests and escapes. Only these requests and escapes supported by mandoc(1) are documented in the present manual, together with the basic language syntax shared by rrooffff, mdoc(5), and man(5). For complete rrooffff manuals, consult the _S_E_E _A_L_S_O section. Input lines beginning with the control character `.' are parsed for requests and macros. Such lines are called "request lines" or "macro lines", respectively. Requests change the processing state and manipulate the formatting; some macros also define the document structure and produce formatted output. The single quote ("'") is accepted as an alternative control character, treated by mandoc(1) just like `.' Lines not beginning with control characters are called "text lines". They provide free-form text to be printed; the formatting of the text depends on the respective processing context. LLAANNGGUUAAGGEE SSYYNNTTAAXX rrooffff documents may contain only graphable 7-bit ASCII characters, the space character, and, in certain circumstances, the tab character. The backslash character `\' indicates the start of an escape sequence, used for example for _C_o_m_m_e_n_t_s, _S_p_e_c_i_a_l _C_h_a_r_a_c_t_e_r_s, _P_r_e_d_e_f_i_n_e_d _S_t_r_i_n_g_s, and user-defined strings defined using the _d_s request. For a listing of escape sequences, consult the _E_S_C_A_P_E _S_E_Q_U_E_N_C_E _R_E_F_E_R_E_N_C_E below. CCoommmmeennttss Text following an escaped double-quote `\"', whether in a request, macro, or text line, is ignored to the end of the line. A request line beginning with a control character and comment escape `.\"' is also ignored. Furthermore, request lines with only a control character and optional trailing whitespace are stripped from input. Examples: .\" This is a comment line. .\" The next line is ignored: . .Sh EXAMPLES \" This is a comment, too. example text \" And so is this. SSppeecciiaall CChhaarraacctteerrss Special characters are used to encode special glyphs and are rendered differently across output media. They may occur in request, macro, and text lines. Sequences begin with the escape character `\' followed by either an open-parenthesis `(' for two-character sequences; an open- bracket `[' for n-character sequences (terminated at a close-bracket `]'); or a single one character sequence. Examples: \(em Two-letter em dash escape. \e One-letter backslash escape. See mandoc_char(5) for a complete list. TTeexxtt DDeeccoorraattiioonn Terms may be text-decorated using the `\f' escape followed by an indicator: B (bold), I (italic), R (regular), or P (revert to previous mode). A numerical representation 3, 2, or 1 (bold, italic, and regular, respectively) may be used instead. The indicator or numerical representative may be preceded by C (constant-width), which is ignored. The two-character indicator `BI' requests a font that is both bold and italic. It may not be portable to old roff implementations. Examples: \fBbold\fR Write in bboolldd, then switch to regular font mode. \fIitalic\fP Write in _i_t_a_l_i_c, then return to previous font mode. \f(BIbold italic\fP Write in _bb_oo_ll_dd _ii_tt_aa_ll_ii_cc, then return to previous font mode. Text decoration is _n_o_t recommended for mdoc(5), which encourages semantic annotation. PPrreeddeeffiinneedd SSttrriinnggss Predefined strings, like _S_p_e_c_i_a_l _C_h_a_r_a_c_t_e_r_s, mark special output glyphs. Predefined strings are escaped with the slash-asterisk, `\*': single- character `\*X', two-character `\*(XX', and N-character `\*[N]'. Examples: \*(Am Two-letter ampersand predefined string. \*q One-letter double-quote predefined string. Predefined strings are not recommended for use, as they differ across implementations. Those supported by mandoc(1) are listed in mandoc_char(5). Manuals using these predefined strings are almost certainly not portable. WWhhiitteessppaaccee Whitespace consists of the space character. In text lines, whitespace is preserved within a line. In request and macro lines, whitespace delimits arguments and is discarded. Unescaped trailing spaces are stripped from text line input unless in a literal context. In general, trailing whitespace on any input line is discouraged for reasons of portability. In the rare case that a blank character is needed at the end of an input line, it may be forced by `\ \&'. Literal space characters can be produced in the output using escape sequences. In macro lines, they can also be included in arguments using quotation; see _M_A_C_R_O _S_Y_N_T_A_X for details. Blank text lines, which may include whitespace, are only permitted within literal contexts. If the first character of a text line is a space, that line is printed with a leading newline. SSccaalliinngg WWiiddtthhss Many requests and macros support scaled widths for their arguments. The syntax for a scaled width is `[+-]?[0-9]*.[0-9]*[:unit:]', where a decimal must be preceded or followed by at least one digit. Negative numbers, while accepted, are truncated to zero. The following scaling units are accepted: c centimetre i inch P pica (~1/6 inch) p point (~1/72 inch) f scale `u' by 65536 v default vertical span m width of rendered `m' (em) character n width of rendered `n' (en) character u default horizontal span for the terminal M mini-em (~1/100 em) Using anything other than `m', `n', or `v' is necessarily non-portable across output media. See _C_O_M_P_A_T_I_B_I_L_I_T_Y. If a scaling unit is not provided, the numerical value is interpreted under the default rules of `v' for vertical spaces and `u' for horizontal ones. Examples: .Bl -tag -width 2i two-inch tagged list indentation in mdoc(5) .HP 2i two-inch tagged list indentation in man(5) .sp 2v two vertical spaces SSeenntteennccee SSppaacciinngg Each sentence should terminate at the end of an input line. By doing this, a formatter will be able to apply the proper amount of spacing after the end of sentence (unescaped) period, exclamation mark, or question mark followed by zero or more non-sentence closing delimiters (`)', `]', `'', `"'). The proper spacing is also intelligently preserved if a sentence ends at the boundary of a macro line. Examples: Do not end sentences mid-line like this. Instead, end a sentence like this. A macro would end like this: .Xr mandoc 1 . RREEQQUUEESSTT SSYYNNTTAAXX A request or macro line consists of: 1. the control character `.' or `'' at the beginning of the line, 2. optionally an arbitrary amount of whitespace, 3. the name of the request or the macro, which is one word of arbitrary length, terminated by whitespace, 4. and zero or more arguments delimited by whitespace. Thus, the following request lines are all equivalent: .ig end .ig end . ig end MMAACCRROO SSYYNNTTAAXX Macros are provided by the mdoc(5) and man(5) languages and can be defined by the _d_e request. When called, they follow the same syntax as requests, except that macro arguments may optionally be quoted by enclosing them in double quote characters (`"'). Quoted text, even if it contains whitespace or would cause a macro invocation when unquoted, is always considered literal text. Inside quoted text, pairs of double quote characters (`""') resolve to single double quote characters. To be recognised as the beginning of a quoted argument, the opening quote character must be preceded by a space character. A quoted argument extends to the next double quote character that is not part of a pair, or to the end of the input line, whichever comes earlier. Leaving out the terminating double quote character at the end of the line is discouraged. For clarity, if more arguments follow on the same input line, it is recommended to follow the terminating double quote character by a space character; in case the next character after the terminating double quote character is anything else, it is regarded as the beginning of the next, unquoted argument. Both in quoted and unquoted arguments, pairs of backslashes (`\\') resolve to single backslashes. In unquoted arguments, space characters can alternatively be included by preceding them with a backslash (`\ '), but quoting is usually better for clarity. Examples: .Fn strlen "const char *s" Group arguments "const char *s" into one function argument. If unspecified, "const", "char", and "*s" would be considered separate arguments. .Op "Fl a" Consider "Fl a" as literal text instead of a flag macro. RREEQQUUEESSTT RREEFFEERREENNCCEE The mandoc(1) rrooffff parser recognises the following requests. For requests marked as "ignored" or "unsupported", any arguments are ignored, and the number of arguments is not checked. aabb [_m_e_s_s_a_g_e] Abort processing. Currently unsupported. aadd [bb | cc | ll | nn | rr] Set line adjustment mode for subsequent text. Currently ignored. aaff _r_e_g_i_s_t_e_r_n_a_m_e _f_o_r_m_a_t Assign an output format to a number register. Currently ignored. aallnn _n_e_w_n_a_m_e _o_l_d_n_a_m_e Create an alias for a number register. Currently unsupported. aallss _n_e_w_n_a_m_e _o_l_d_n_a_m_e Create an alias for a request, string, macro, or diversion. aamm _m_a_c_r_o_n_a_m_e [_e_n_d_m_a_c_r_o] Append to a macro definition. The syntax of this request is the same as that of ddee. aamm11 _m_a_c_r_o_n_a_m_e [_e_n_d_m_a_c_r_o] Append to a macro definition, switching roff compatibility mode off during macro execution (groff extension). The syntax of this request is the same as that of ddee11. Since mandoc(1) does not implement rrooffff compatibility mode at all, it handles this request as an alias for aamm. aammii _m_a_c_r_o_s_t_r_i_n_g [_e_n_d_s_t_r_i_n_g] Append to a macro definition, specifying the macro name indirectly (groff extension). The syntax of this request is the same as that of ddeeii. aammii11 _m_a_c_r_o_s_t_r_i_n_g [_e_n_d_s_t_r_i_n_g] Append to a macro definition, specifying the macro name indirectly and switching roff compatibility mode off during macro execution (groff extension). The syntax of this request is the same as that of ddeeii11. Since mandoc(1) does not implement rrooffff compatibility mode at all, it handles this request as an alias for aammii. aass _s_t_r_i_n_g_n_a_m_e [_s_t_r_i_n_g] Append to a user-defined string. The syntax of this request is the same as that of _d_s. If a user-defined string with the specified name does not yet exist, it is set to the empty string before appending. aass11 _s_t_r_i_n_g_n_a_m_e [_s_t_r_i_n_g] Append to a user-defined string, switching roff compatibility mode off during macro execution (groff extension). The syntax of this request is the same as that of ddss11. Since mandoc(1) does not implement rrooffff compatibility mode at all, it handles this request as an alias for aass. aasscciiiiffyy _d_i_v_n_a_m_e Fully unformat a diversion. Currently unsupported. bbaacckkttrraaccee Print a backtrace of the input stack. This is a groff extension and currently ignored. bbdd _f_o_n_t [_c_u_r_f_o_n_t] [_o_f_f_s_e_t] Artificially embolden by repeated printing with small shifts. Currently ignored. bblleeeeddaatt _l_e_f_t _t_o_p _w_i_d_t_h _h_e_i_g_h_t Set the BleedBox page parameter for PDF generation. This is a Heirloom extension and currently ignored. bbllmm _m_a_c_r_o_n_a_m_e Set a blank line trap. Currently unsupported. bbooxx _d_i_v_n_a_m_e Begin a diversion without including a partially filled line. Currently unsupported. bbooxxaa _d_i_v_n_a_m_e Add to a diversion without including a partially filled line. Currently unsupported. bbpp [++|--]_p_a_g_e_n_u_m_b_e_r Begin a new page. Currently ignored. BBPP _s_o_u_r_c_e _h_e_i_g_h_t _w_i_d_t_h _p_o_s_i_t_i_o_n _o_f_f_s_e_t _f_l_a_g_s _l_a_b_e_l Define a frame and place a picture in it. This is a Heirloom extension and currently unsupported. bbrr Break the output line. bbrreeaakk Break out of a wwhhiillee loop. Currently unsupported. bbrreeaakkcchhaarr _c_h_a_r _._._. Optional line break characters. This is a Heirloom extension and currently ignored. bbrrnnll _N Break output line after the next _N input lines. This is a Heirloom extension and currently ignored. bbrrpp Break and spread output line. Currently, this is implemented as an alias for bbrr. bbrrppnnll _N Break and spread output line after the next _N input lines. This is a Heirloom extension and currently ignored. cc22 [_c_h_a_r] Change the no-break control character. Currently unsupported. cccc [_c_h_a_r] Change the control character. If _c_h_a_r is not specified, the control character is reset to `.'. Trailing characters are ignored. ccee [_N] Center the next _N input lines without filling. _N defaults to 1. An argument of 0 or less ends centering. Currently, high level macros abort centering. ccff _f_i_l_e_n_a_m_e Output the contents of a file. Ignored because insecure. ccffllaaggss _f_l_a_g_s _c_h_a_r _._._. Set character flags. This is a groff extension and currently ignored. cchh _m_a_c_r_o_n_a_m_e [_d_i_s_t] Change a trap location. Currently ignored. cchhaarr _g_l_y_p_h_n_a_m_e [_s_t_r_i_n_g] Define a new glyph. Currently unsupported. cchhoopp _s_t_r_i_n_g_n_a_m_e Remove the last character from a macro, string, or diversion. Currently unsupported. ccllaassss _c_l_a_s_s_n_a_m_e _c_h_a_r _._._. Define a character class. This is a groff extension and currently ignored. cclloossee _s_t_r_e_a_m_n_a_m_e Close an open file. Ignored because insecure. CCLL _c_o_l_o_r _t_e_x_t Print text in color. This is a Heirloom extension and currently unsupported. ccoolloorr [11 | 00] Activate or deactivate colors. This is a groff extension and currently ignored. ccoommppoossiittee _f_r_o_m _t_o Define a name component for composite glyph names. This is a groff extension and currently unsupported. ccoonnttiinnuuee Immediately start the next iteration of a wwhhiillee loop. Currently unsupported. ccpp [11 | 00] Switch rrooffff compatibility mode on or off. Currently ignored. ccrrooppaatt _l_e_f_t _t_o_p _w_i_d_t_h _h_e_i_g_h_t Set the CropBox page parameter for PDF generation. This is a Heirloom extension and currently ignored. ccss _f_o_n_t [_w_i_d_t_h [_e_m_s_i_z_e]] Constant character spacing mode. Currently ignored. ccuu [_N] Underline next _N input lines including whitespace. Currently ignored. ddaa _d_i_v_n_a_m_e Append to a diversion. Currently unsupported. ddcchh _m_a_c_r_o_n_a_m_e [_d_i_s_t] Change a trap location in the current diversion. This is a Heirloom extension and currently unsupported. ddee _m_a_c_r_o_n_a_m_e [_e_n_d_m_a_c_r_o] Define a rrooffff macro. Its syntax can be either .ddee _m_a_c_r_o_n_a_m_e _d_e_f_i_n_i_t_i_o_n .. or .ddee _m_a_c_r_o_n_a_m_e _e_n_d_m_a_c_r_o _d_e_f_i_n_i_t_i_o_n ._e_n_d_m_a_c_r_o Both forms define or redefine the macro _m_a_c_r_o_n_a_m_e to represent the _d_e_f_i_n_i_t_i_o_n, which may consist of one or more input lines, including the newline characters terminating each line, optionally containing calls to rrooffff requests, rrooffff macros or high-level macros like man(5) or mdoc(5) macros, whichever applies to the document in question. Specifying a custom _e_n_d_m_a_c_r_o macro works in the same way as for iigg; namely, the call to `._e_n_d_m_a_c_r_o' first ends the _d_e_f_i_n_i_t_i_o_n, and after that, it is also evaluated as a rrooffff request or rrooffff macro, but not as a high-level macro. The macro can be invoked later using the syntax ._m_a_c_r_o_n_a_m_e [_a_r_g_u_m_e_n_t [_a_r_g_u_m_e_n_t _._._.]] Regarding argument parsing, see _M_A_C_R_O _S_Y_N_T_A_X above. The line invoking the macro will be replaced in the input stream by the _d_e_f_i_n_i_t_i_o_n, replacing all occurrences of \\$_N, where _N is a digit, by the _Nth _a_r_g_u_m_e_n_t. For example, .de ZN \fI\^\\$1\^\fP\\$2 .. .ZN XtFree . produces \fI\^XtFree\^\fP. in the input stream, and thus in the output: _X_t_F_r_e_e. Each occurrence of \\$* is replaced with all the arguments, joined together with single blank characters. Since macros and user-defined strings share a common string table, defining a macro _m_a_c_r_o_n_a_m_e clobbers the user-defined string _m_a_c_r_o_n_a_m_e, and the _d_e_f_i_n_i_t_i_o_n can also be printed using the `\*' string interpolation syntax described below ddss, but this is rarely useful because every macro definition contains at least one explicit newline character. In order to prevent endless recursion, both groff and mandoc(1) limit the stack depth for expanding macros and strings to a large, but finite number, and mandoc(1) also limits the length of the expanded input line. Do not rely on the exact values of these limits. ddee11 _m_a_c_r_o_n_a_m_e [_e_n_d_m_a_c_r_o] Define a rrooffff macro that will be executed with rrooffff compatibility mode switched off during macro execution. This is a groff extension. Since mandoc(1) does not implement rrooffff compatibility mode at all, it handles this request as an alias for ddee. ddeeffccoolloorr _n_e_w_n_a_m_e _s_c_h_e_m_e _c_o_m_p_o_n_e_n_t _._._. Define a color name. This is a groff extension and currently ignored. ddeeii _m_a_c_r_o_s_t_r_i_n_g [_e_n_d_s_t_r_i_n_g] Define a rrooffff macro, specifying the macro name indirectly (groff extension). The syntax of this request is the same as that of ddee. The effect is the same as: .ddee \*[_m_a_c_r_o_s_t_r_i_n_g] [\*[_e_n_d_s_t_r_i_n_g]] ddeeii11 _m_a_c_r_o_s_t_r_i_n_g [_e_n_d_s_t_r_i_n_g] Define a rrooffff macro that will be executed with rrooffff compatibility mode switched off during macro execution, specifying the macro name indirectly (groff extension). Since mandoc(1) does not implement rrooffff compatibility mode at all, it handles this request as an alias for ddeeii. ddeevviiccee _s_t_r_i_n_g _._._. ddeevviicceemm _s_t_r_i_n_g_n_a_m_e These two requests only make sense with the groff-specific intermediate output format and are unsupported. ddii _d_i_v_n_a_m_e Begin a diversion. Currently unsupported. ddoo _c_o_m_m_a_n_d [_a_r_g_u_m_e_n_t _._._.] Execute rrooffff request or macro line with compatibility mode disabled. Currently unsupported. ddss _s_t_r_i_n_g_n_a_m_e [["]_s_t_r_i_n_g] Define a user-defined string. The _s_t_r_i_n_g_n_a_m_e and _s_t_r_i_n_g arguments are space-separated. If the _s_t_r_i_n_g begins with a double-quote character, that character will not be part of the string. All remaining characters on the input line form the _s_t_r_i_n_g, including whitespace and double-quote characters, even trailing ones. The _s_t_r_i_n_g can be interpolated into subsequent text by using \*[_s_t_r_i_n_g_n_a_m_e] for a _s_t_r_i_n_g_n_a_m_e of arbitrary length, or \*(NN or \*N if the length of _s_t_r_i_n_g_n_a_m_e is two or one characters, respectively. Interpolation can be prevented by escaping the leading backslash; that is, an asterisk preceded by an even number of backslashes does not trigger string interpolation. Since user-defined strings and macros share a common string table, defining a string _s_t_r_i_n_g_n_a_m_e clobbers the macro _s_t_r_i_n_g_n_a_m_e, and the _s_t_r_i_n_g_n_a_m_e used for defining a string can also be invoked as a macro, in which case the following input line will be appended to the _s_t_r_i_n_g, forming a new input line passed to the rrooffff parser. For example, .ds badidea .S .badidea H SYNOPSIS invokes the SSHH macro when used in a man(5) document. Such abuse is of course strongly discouraged. ddss11 _s_t_r_i_n_g_n_a_m_e [["]_s_t_r_i_n_g] Define a user-defined string that will be expanded with rrooffff compatibility mode switched off during string expansion. This is a groff extension. Since mandoc(1) does not implement rrooffff compatibility mode at all, it handles this request as an alias for ddss. ddwwhh _d_i_s_t _m_a_c_r_o_n_a_m_e Set a location trap in the current diversion. This is a Heirloom extension and currently unsupported. ddtt [_d_i_s_t _m_a_c_r_o_n_a_m_e] Set a trap within a diversion. Currently unsupported. eecc [_c_h_a_r] Enable the escape mechanism and change the escape character. The _c_h_a_r argument defaults to the backslash (`\'). eeccrr Restore the escape character. Currently unsupported. eeccss Save the escape character. Currently unsupported. eell _b_o_d_y The "else" half of an if/else conditional. Pops a result off the stack of conditional evaluations pushed by iiee and uses it as its conditional. If no stack entries are present (e.g., due to no prior iiee calls) then false is assumed. The syntax of this request is similar to iiff except that the conditional is missing. eemm _m_a_c_r_o_n_a_m_e Set a trap at the end of input. Currently unsupported. EENN End an equation block. See EEQQ. eeoo Disable the escape mechanism completely. EEPP End a picture started by BBPP. This is a Heirloom extension and currently unsupported. EEQQ Begin an equation block. See eqn(5) for a description of the equation language. eerrrrpprriinntt _m_e_s_s_a_g_e Print a string like an error message. This is a Heirloom extension and currently ignored. eevv [_e_n_v_n_a_m_e] Switch to another environment. Currently unsupported. eevvcc [_e_n_v_n_a_m_e] Copy an environment into the current environment. Currently unsupported. eexx Abort processing and exit. Currently unsupported. ffaallllbbaacckk _c_u_r_f_o_n_t _f_o_n_t _._._. Select the fallback sequence for a font. This is a Heirloom extension and currently ignored. ffaamm [_f_a_m_i_l_y_n_a_m_e] Change the font family. This is a groff extension and currently ignored. ffcc [_d_e_l_i_m_c_h_a_r [_p_a_d_c_h_a_r]] Define a delimiting and a padding character for fields. Currently unsupported. ffcchhaarr _g_l_y_p_h_n_a_m_e [_s_t_r_i_n_g] Define a fallback glyph. Currently unsupported. ffccoolloorr _c_o_l_o_r_n_a_m_e Set the fill color for \D objects. This is a groff extension and currently ignored. ffddeeffeerrlliigg _f_o_n_t _s_t_r_i_n_g _._._. Defer ligature building. This is a Heirloom extension and currently ignored. ffeeaattuurree ++|--_n_a_m_e Enable or disable an OpenType feature. This is a Heirloom extension and currently ignored. ffii Switch to fill mode. See man(5). Ignored in mdoc(5). ffkkeerrnn _f_o_n_t _m_i_n_k_e_r_n Control the use of kerning tables for a font. This is a Heirloom extension and currently ignored. ffll Flush output. Currently ignored. fflliigg _f_o_n_t _s_t_r_i_n_g _c_h_a_r _._._. Define ligatures. This is a Heirloom extension and currently ignored. ffpp _p_o_s_i_t_i_o_n _f_o_n_t [_f_i_l_e_n_a_m_e] Assign font position. Currently ignored. ffppss _m_a_p_n_a_m_e _._._. Mount a font with a special character map. This is a Heirloom extension and currently ignored. ffsscchhaarr _f_o_n_t _g_l_y_p_h_n_a_m_e [_s_t_r_i_n_g] Define a font-specific fallback glyph. This is a groff extension and currently unsupported. ffssppaacceewwiiddtthh _f_o_n_t [_a_f_m_u_n_i_t_s] Set a font-specific width for the space character. This is a Heirloom extension and currently ignored. ffssppeecciiaall _c_u_r_f_o_n_t [_f_o_n_t _._._.] Conditionally define a special font. This is a groff extension and currently ignored. fftt [_f_o_n_t] Change the font. The following _f_o_n_t arguments are supported: BB, BBII, 33, 44 switches to bboolldd font II, 22 switches to _u_n_d_e_r_l_i_n_e_d font RR, CCWW, 11 switches to normal font PP or no argument switches back to the previous font This request takes effect only locally and may be overridden by macros and escape sequences. ffttrr _n_e_w_n_a_m_e [_o_l_d_n_a_m_e] Translate font name. This is a groff extension and currently ignored. ffzzoooomm _f_o_n_t [_p_e_r_m_i_l_l_e] Zoom font size. Currently ignored. ggccoolloorr [_c_o_l_o_r_n_a_m_e] Set glyph color. This is a groff extension and currently ignored. hhcc [_c_h_a_r] Set the hyphenation character. Currently ignored. hhccooddee _c_h_a_r _c_o_d_e _._._. Set hyphenation codes of characters. Currently ignored. hhiiddeecchhaarr _f_o_n_t _c_h_a_r _._._. Hide characters in a font. This is a Heirloom extension and currently ignored. hhllaa _l_a_n_g_u_a_g_e Set hyphenation language. This is a groff extension and currently ignored. hhllmm [_n_u_m_b_e_r] Set maximum number of consecutive hyphenated lines. Currently ignored. hhppff _f_i_l_e_n_a_m_e Load hyphenation pattern file. This is a groff extension and currently ignored. hhppffaa _f_i_l_e_n_a_m_e Load hyphenation pattern file, appending to the current patterns. This is a groff extension and currently ignored. hhppffccooddee _c_o_d_e _c_o_d_e _._._. Define mapping values for character codes in hyphenation patterns. This is a groff extension and currently ignored. hhww _w_o_r_d _._._. Specify hyphenation points in words. Currently ignored. hhyy [_m_o_d_e] Set automatic hyphenation mode. Currently ignored. hhyyllaanngg _l_a_n_g_u_a_g_e Set hyphenation language. This is a Heirloom extension and currently ignored. hhyylleenn _n_c_h_a_r Minimum word length for hyphenation. This is a Heirloom extension and currently ignored. hhyymm [_l_e_n_g_t_h] Set hyphenation margin. This is a groff extension and currently ignored. hhyypppp _p_e_n_a_l_t_y _._._. Define hyphenation penalties. This is a Heirloom extension and currently ignored. hhyyss [_l_e_n_g_t_h] Set hyphenation space. This is a groff extension and currently ignored. iiee _c_o_n_d_i_t_i_o_n _b_o_d_y The "if" half of an if/else conditional. The result of the conditional is pushed into a stack used by subsequent invocations of eell, which may be separated by any intervening input (or not exist at all). Its syntax is equivalent to iiff. iiff _c_o_n_d_i_t_i_o_n _b_o_d_y Begin a conditional. This request can also be written as follows: .iiff _c_o_n_d_i_t_i_o_n \{_b_o_d_y _b_o_d_y _._._.\} .iiff _c_o_n_d_i_t_i_o_n \{\ _b_o_d_y _._._. .\} The _c_o_n_d_i_t_i_o_n is a boolean expression. Currently, mandoc(1) supports the following subset of roff conditionals: ++oo If `!' is prefixed to _c_o_n_d_i_t_i_o_n, it is logically inverted. ++oo If the first character of _c_o_n_d_i_t_i_o_n is `n' (nroff mode) or `o' (odd page), it evaluates to true. ++oo If the first character of _c_o_n_d_i_t_i_o_n is `c' (character available), `e' (even page), `t' (troff mode), or `v' (vroff mode), it evaluates to false. ++oo If the first character of _c_o_n_d_i_t_i_o_n is `d', it evaluates to true if the rest of _c_o_n_d_i_t_i_o_n is the name of an existing user defined macro or string; otherwise, it evaluates to false. ++oo If the first character of _c_o_n_d_i_t_i_o_n is `r', it evaluates to true if the rest of _c_o_n_d_i_t_i_o_n is the name of an existing number register; otherwise, it evaluates to false. ++oo If the _c_o_n_d_i_t_i_o_n starts with a parenthesis or with an optionally signed integer number, it is evaluated according to the rules of _N_u_m_e_r_i_c_a_l _e_x_p_r_e_s_s_i_o_n_s explained below. It evaluates to true if the result is positive, or to false if the result is zero or negative. ++oo Otherwise, the first character of _c_o_n_d_i_t_i_o_n is regarded as a delimiter and it evaluates to true if the string extending from its first to its second occurrence is equal to the string extending from its second to its third occurrence. ++oo If _c_o_n_d_i_t_i_o_n cannot be parsed, it evaluates to false. If a conditional is false, its children are not processed, but are syntactically interpreted to preserve the integrity of the input document. Thus, .if t .ig will discard the `.ig', which may lead to interesting results, but .if t .if t \{\ will continue to syntactically interpret to the block close of the final conditional. Sub-conditionals, in this case, obviously inherit the truth value of the parent. If the _b_o_d_y section is begun by an escaped brace `\{', scope continues until the end of the input line containing the matching closing-brace escape sequence `\}'. If the _b_o_d_y is not enclosed in braces, scope continues until the end of the line. If the _c_o_n_d_i_t_i_o_n is followed by a _b_o_d_y on the same line, whether after a brace or not, then requests and macros _m_u_s_t begin with a control character. It is generally more intuitive, in this case, to write .iiff _c_o_n_d_i_t_i_o_n \{\ ._r_e_q_u_e_s_t .\} than having the request or macro follow as .iiff _c_o_n_d_i_t_i_o_n \{._r_e_q_u_e_s_t The scope of a conditional is always parsed, but only executed if the conditional evaluates to true. Note that the `\}' is converted into a zero-width escape sequence if not passed as a standalone macro `.\}'. For example, .Fl a \} b will result in `\}' being considered an argument of the `Fl' macro. iigg [_e_n_d_m_a_c_r_o] Ignore input. Its syntax can be either .iigg _i_g_n_o_r_e_d _t_e_x_t .. or .iigg _e_n_d_m_a_c_r_o _i_g_n_o_r_e_d _t_e_x_t ._e_n_d_m_a_c_r_o In the first case, input is ignored until a `..' request is encountered on its own line. In the second case, input is ignored until the specified `._e_n_d_m_a_c_r_o' is encountered. Do not use the escape character `\' anywhere in the definition of _e_n_d_m_a_c_r_o; it would cause very strange behaviour. When the _e_n_d_m_a_c_r_o is a roff request or a roff macro, like in .ig if the subsequent invocation of iiff will first terminate the _i_g_n_o_r_e_d _t_e_x_t, then be invoked as usual. Otherwise, it only terminates the _i_g_n_o_r_e_d _t_e_x_t, and arguments following it or the `..' request are discarded. iinn [[++|--]_w_i_d_t_h] Change indentation. See man(5). Ignored in mdoc(5). iinnddeexx _r_e_g_i_s_t_e_r _s_t_r_i_n_g_n_a_m_e _s_u_b_s_t_r_i_n_g Find a substring in a string. This is a Heirloom extension and currently unsupported. iitt _e_x_p_r_e_s_s_i_o_n _m_a_c_r_o Set an input line trap. The named _m_a_c_r_o will be invoked after processing the number of input text lines specified by the numerical _e_x_p_r_e_s_s_i_o_n. While evaluating the _e_x_p_r_e_s_s_i_o_n, the unit suffixes described below _S_c_a_l_i_n_g _W_i_d_t_h_s are ignored. iitt _e_x_p_r_e_s_s_i_o_n _m_a_c_r_o Set an input line trap, not counting lines ending with \c. Currently unsupported. IIXX _c_l_a_s_s _k_e_y_s_t_r_i_n_g To support the generation of a table of contents, pod2man(1) emits this user-defined macro, usually without defining it. To avoid reporting large numbers of spurious errors, mandoc(1) ignores it. kkeerrnn [11 | 00] Switch kerning on or off. Currently ignored. kkeerrnnaafftteerr _f_o_n_t _c_h_a_r _._._. _a_f_m_u_n_i_t_s _._._. Increase kerning after some characters. This is a Heirloom extension and currently ignored. kkeerrnnbbeeffoorree _f_o_n_t _c_h_a_r _._._. _a_f_m_u_n_i_t_s _._._. Increase kerning before some characters. This is a Heirloom extension and currently ignored. kkeerrnnppaaiirr _f_o_n_t _c_h_a_r _._._. _f_o_n_t _c_h_a_r _._._. _a_f_m_u_n_i_t_s Add a kerning pair to the kerning table. This is a Heirloom extension and currently ignored. llcc [_g_l_y_p_h] Define a leader repetition character. Currently unsupported. llcc__ccttyyppee _l_o_c_a_l_e_n_a_m_e Set the LC_CTYPE locale. This is a Heirloom extension and currently unsupported. llddss _m_a_c_r_o_n_a_m_e _s_t_r_i_n_g Define a local string. This is a Heirloom extension and currently unsupported. lleennggtthh _r_e_g_i_s_t_e_r _s_t_r_i_n_g Count the number of input characters in a string. Currently unsupported. lleettaaddjj _l_s_p_m_i_n _l_s_h_m_i_n _l_e_t_s_s _l_s_p_m_a_x _l_s_h_m_a_x Dynamic letter spacing and reshaping. This is a Heirloom extension and currently ignored. llff _l_i_n_e_n_o [_f_i_l_e_n_a_m_e] Change the line number for error messages. Ignored because insecure. llgg [11 | 00] Switch the ligature mechanism on or off. Currently ignored. llhhaanngg _f_o_n_t _c_h_a_r _._._. _a_f_m_u_n_i_t_s Hang characters at left margin. This is a Heirloom extension and currently ignored. lliinneettaabbss [11 | 00] Enable or disable line-tabs mode. This is a groff extension and currently unsupported. llll [[++|--]_w_i_d_t_h] Change the output line length. If the _w_i_d_t_h argument is omitted, the line length is reset to its previous value. The default setting for terminal output is 58n. If a sign is given, the line length is added to or subtracted from; otherwise, it is set to the provided value. Using this request in new manuals is discouraged for several reasons, among others because it overrides the mandoc(1) --OO wwiiddtthh command line option. llnnrr _r_e_g_i_s_t_e_r [++|--]_v_a_l_u_e [_i_n_c_r_e_m_e_n_t] Set local number register. This is a Heirloom extension and currently unsupported. llnnrrff _r_e_g_i_s_t_e_r [++|--]_v_a_l_u_e [_i_n_c_r_e_m_e_n_t] Set local floating-point register. This is a Heirloom extension and currently unsupported. llppffxx _s_t_r_i_n_g Set a line prefix. This is a Heirloom extension and currently unsupported. llss [_f_a_c_t_o_r] Set line spacing. It takes one integer argument specifying the vertical distance of subsequent output text lines measured in v units. Currently ignored. llssmm _m_a_c_r_o_n_a_m_e Set a leading spaces trap. This is a groff extension and currently unsupported. lltt [[++|--]_w_i_d_t_h] Set title line length. Currently ignored. mmcc _g_l_y_p_h [_d_i_s_t] Print margin character in the right margin. The _d_i_s_t is currently ignored; instead, 1n is used. mmeeddiiaassiizzee _m_e_d_i_a Set the device media size. This is a Heirloom extension and currently ignored. mmiinnssss _w_i_d_t_h Set minimum word space. This is a Heirloom extension and currently ignored. mmkk [_r_e_g_i_s_t_e_r] Mark vertical position. Currently ignored. mmssoo _f_i_l_e_n_a_m_e Load a macro file using the search path. Ignored because insecure. nnaa Disable adjusting without changing the adjustment mode. Currently ignored. nnee [_h_e_i_g_h_t] Declare the need for the specified minimum vertical space before the next trap or the bottom of the page. Currently ignored. nnff Switch to no-fill mode. See man(5). Ignored by mdoc(5). nnhh Turn off automatic hyphenation mode. Currently ignored. nnhhyycchhaarr _c_h_a_r _._._. Define hyphenation-inhibiting characters. This is a Heirloom extension and currently ignored. nnmm [_s_t_a_r_t [_i_n_c [_s_p_a_c_e [_i_n_d_e_n_t]]]] Print line numbers. Currently unsupported. nnnn [_n_u_m_b_e_r] Temporarily turn off line numbering. Currently unsupported. nnoopp _b_o_d_y Execute the rest of the input line as a request or macro line. Currently unsupported. nnrr _r_e_g_i_s_t_e_r [++|--]_e_x_p_r_e_s_s_i_o_n [_s_t_e_p_s_i_z_e] Define or change a register. A register is an arbitrary string value that defines some sort of state, which influences parsing and/or formatting. For the syntax of _e_x_p_r_e_s_s_i_o_n, see _N_u_m_e_r_i_c_a_l _e_x_p_r_e_s_s_i_o_n_s below. If it is prefixed by a sign, the register will be incremented or decremented instead of assigned to. The _s_t_e_p_s_i_z_e is used by the \\nn++ auto-increment feature. It remains unchanged when omitted while changing an existing register, and it defaults to 0 when defining a new register. The following _r_e_g_i_s_t_e_r is handled specially: nnSS If set to a positive integer value, certain mdoc(5) macros will behave in the same way as in the _S_Y_N_O_P_S_I_S section. If set to 0, these macros will behave in the same way as outside the _S_Y_N_O_P_S_I_S section, even when called within the _S_Y_N_O_P_S_I_S section itself. Note that starting a new mdoc(5) section with the SShh macro will reset this register. nnrrff _r_e_g_i_s_t_e_r [++|--]_e_x_p_r_e_s_s_i_o_n [_i_n_c_r_e_m_e_n_t] Define or change a floating-point register. This is a Heirloom extension and currently unsupported. nnrrooffff Force nroff mode. This is a groff extension and currently ignored. nnss Turn on no-space mode. Currently ignored. nnxx [_f_i_l_e_n_a_m_e] Abort processing of the current input file and process another one. Ignored because insecure. ooppeenn _s_t_r_e_a_m _f_i_l_e Open a file for writing. Ignored because insecure. ooppeennaa _s_t_r_e_a_m _f_i_l_e Open a file for appending. Ignored because insecure. ooss Output saved vertical space. Currently ignored. oouuttppuutt _s_t_r_i_n_g Output directly to intermediate output. Not supported. ppaaddjj [11 | 00] Globally control paragraph-at-once adjustment. This is a Heirloom extension and currently ignored. ppaappeerrssiizzee _m_e_d_i_a Set the paper size. This is a Heirloom extension and currently ignored. ppcc [_c_h_a_r] Change the page number character. Currently ignored. ppeevv Print environments. This is a groff extension and currently ignored. ppii _c_o_m_m_a_n_d Pipe output to a shell command. Ignored because insecure. PPII Low-level request used by BBPP. This is a Heirloom extension and currently unsupported. ppll [[++|--]_h_e_i_g_h_t] Change page length. Currently ignored. ppmm Print names and sizes of macros, strings, and diversions to standard error output. Currently ignored. ppnn [++|--]_n_u_m_b_e_r Change the page number of the next page. Currently ignored. ppnnrr Print all number registers on standard error output. Currently ignored. ppoo [[++|--]_o_f_f_s_e_t] Set a horizontal page offset. If no argument is specified, the page offset is reverted to its previous value. If a sign is specified, the new page offset is calculated relative to the current one; otherwise, it is absolute. The argument follows the syntax of _S_c_a_l_i_n_g _W_i_d_t_h_s and the default scaling unit is mm. ppss [[++|--]size] Change point size. Currently ignored. ppssbbbb _f_i_l_e_n_a_m_e Retrieve the bounding box of a PostScript file. Currently unsupported. ppsshhaappee _i_n_d_e_n_t _l_e_n_g_t_h _._._. Set a special shape for the current paragraph. This is a Heirloom extension and currently unsupported. ppssoo _c_o_m_m_a_n_d Include output of a shell command. Ignored because insecure. ppttrr Print the names and positions of all traps on standard error output. This is a groff extension and currently ignored. ppvvss [[++|--]_h_e_i_g_h_t] Change post-vertical spacing. This is a groff extension and currently ignored. rrcchhaarr _g_l_y_p_h _._._. Remove glyph definitions. Currently unsupported. rrdd [_p_r_o_m_p_t [_a_r_g_u_m_e_n_t _._._.]] Read from standard input. Currently ignored. rreeccuurrssiioonnlliimmiitt _m_a_x_r_e_c _m_a_x_t_a_i_l Set the maximum stack depth for recursive macros. This is a Heirloom extension and currently ignored. rreettuurrnn [_t_w_i_c_e] Exit a macro and return to the caller. Currently unsupported. rrffsscchhaarr _f_o_n_t _g_l_y_p_h _._._. Remove font-specific fallback glyph definitions. Currently unsupported. rrhhaanngg _f_o_n_t _c_h_a_r _._._. _a_f_m_u_n_i_t_s Hang characters at right margin. This is a Heirloom extension and currently ignored. rrjj [_N] Justify the next _N input lines to the right margin without filling. _N defaults to 1. An argument of 0 or less ends right adjustment. rrmm _m_a_c_r_o_n_a_m_e Remove a request, macro or string. rrnn _o_l_d_n_a_m_e _n_e_w_n_a_m_e Rename a request, macro, diversion, or string. In mandoc(1), user-defined macros, mdoc(5) and man(5) macros, and user-defined strings can be renamed, but renaming of predefined strings and of rrooffff requests is not supported, and diversions are not implemented at all. rrnnnn _o_l_d_n_a_m_e _n_e_w_n_a_m_e Rename a number register. Currently unsupported. rrrr _r_e_g_i_s_t_e_r Remove a register. rrss End no-space mode. Currently ignored. rrtt [_d_i_s_t] Return to marked vertical position. Currently ignored. sscchhaarr _g_l_y_p_h [_s_t_r_i_n_g] Define global fallback glyph. This is a groff extension and currently unsupported. sseennttcchhaarr _c_h_a_r _._._. Define sentence-ending characters. This is a Heirloom extension and currently ignored. sshhcc [_g_l_y_p_h] Change the soft hyphen character. Currently ignored. sshhiifftt [_n_u_m_b_e_r] Shift macro arguments. Currently unsupported. ssiizzeess _s_i_z_e _._._. Define permissible point sizes. This is a groff extension and currently ignored. ssoo _f_i_l_e_n_a_m_e Include a source file. The file is read and its contents processed as input in place of the ssoo request line. To avoid inadvertent inclusion of unrelated files, mandoc(1) only accepts relative paths not containing the strings "../" and "/..". This request requires man(1) to change to the right directory before calling mandoc(1), per convention to the root of the manual tree. Typical usage looks like: .so man3/Xcursor.3 As the whole concept is rather fragile, the use of ssoo is discouraged. Use ln(1) instead. sspp [_h_e_i_g_h_t] Break the output line and emit vertical space. The argument follows the syntax of _S_c_a_l_i_n_g _W_i_d_t_h_s and defaults to one blank line (1v). ssppaacceewwiiddtthh [11 | 00] Set the space width from the font metrics file. This is a Heirloom extension and currently ignored. ssppeecciiaall [_f_o_n_t _._._.] Define a special font. This is a groff extension and currently ignored. sspprreeaaddwwaarrnn [_w_i_d_t_h] Warn about wide spacing between words. Currently ignored. ssss _w_o_r_d_s_p_a_c_e [_s_e_n_t_e_n_c_e_s_p_a_c_e] Set space character size. Currently ignored. ssttyy _p_o_s_i_t_i_o_n _s_t_y_l_e Associate style with a font position. This is a groff extension and currently ignored. ssuubbssttrriinngg _s_t_r_i_n_g_n_a_m_e _s_t_a_r_t_p_o_s [_e_n_d_p_o_s] Replace a user-defined string with a substring. Currently unsupported. ssvv [_h_e_i_g_h_t] Save vertical space. Currently ignored. ssyy _c_o_m_m_a_n_d Execute shell command. Ignored because insecure. TT&& Re-start a table layout, retaining the options of the prior table invocation. See _T_S. ttaa [_w_i_d_t_h _._._. [TT _w_i_d_t_h _._._.]] Set tab stops. Each _w_i_d_t_h argument follows the syntax of _S_c_a_l_i_n_g _W_i_d_t_h_s. If prefixed by a plus sign, it is relative to the previous tab stop. The arguments after the TT marker are used repeatedly as often as needed; for each reuse, they are taken relative to the last previously established tab stop. When ttaa is called without arguments, all tab stops are cleared. ttcc [_g_l_y_p_h] Change tab repetition character. Currently unsupported. TTEE End a table context. See _T_S. ttii [++|--]_w_i_d_t_h Break the output line and indent the next output line by _w_i_d_t_h. If a sign is specified, the temporary indentation is calculated relative to the current indentation; otherwise, it is absolute. The argument follows the syntax of _S_c_a_l_i_n_g _W_i_d_t_h_s and the default scaling unit is mm. ttkkff _f_o_n_t _m_i_n_p_s _w_i_d_t_h_1 _m_a_x_p_s _w_i_d_t_h_2 Enable track kerning for a font. Currently ignored. ttll '_l_e_f_t'_c_e_n_t_e_r'_r_i_g_h_t' Print a title line. Currently unsupported. ttmm _s_t_r_i_n_g Print to standard error output. Currently ignored. ttmm11 _s_t_r_i_n_g Print to standard error output, allowing leading blanks. This is a groff extension and currently ignored. ttmmcc _s_t_r_i_n_g Print to standard error output without a trailing newline. This is a groff extension and currently ignored. ttrr _g_l_y_p_h _g_l_y_p_h _._._. Output character translation. The first glyph in each pair is replaced by the second one. Character escapes can be used; for example, tr \(xx\(yy replaces all invocations of \(xx with \(yy. ttrraacckk _f_o_n_t _m_i_n_p_s _w_i_d_t_h_1 _m_a_x_p_s _w_i_d_t_h_2 Static letter space tracking. This is a Heirloom extension and currently ignored. ttrraannsscchhaarr _c_h_a_r _._._. Define transparent characters for sentence-ending. This is a Heirloom extension and currently ignored. ttrrff _f_i_l_e_n_a_m_e Output the contents of a file, disallowing invalid characters. This is a groff extension and ignored because insecure. ttrriimmaatt _l_e_f_t _t_o_p _w_i_d_t_h _h_e_i_g_h_t Set the TrimBox page parameter for PDF generation. This is a Heirloom extension and currently ignored. ttrriinn _g_l_y_p_h _g_l_y_p_h _._._. Output character translation, ignored by aasscciiiiffyy. Currently unsupported. ttrrnntt _g_l_y_p_h _g_l_y_p_h _._._. Output character translation, ignored by \!. Currently unsupported. ttrrooffff Force troff mode. This is a groff extension and currently ignored. TTSS Begin a table, which formats input in aligned rows and columns. See tbl(5) for a description of the tbl language. uuff _f_o_n_t Globally set the underline font. Currently ignored. uull [_N] Underline next _N input lines. Currently ignored. uunnffoorrmmaatt _d_i_v_n_a_m_e Unformat spaces and tabs in a diversion. Currently unsupported. uunnwwaattcchh _m_a_c_r_o_n_a_m_e Disable notification for string or macro. This is a Heirloom extension and currently ignored. uunnwwaattcchhnn _r_e_g_i_s_t_e_r Disable notification for register. This is a Heirloom extension and currently ignored. vvpptt [11 | 00] Enable or disable vertical position traps. This is a groff extension and currently ignored. vvss [[++|--]_h_e_i_g_h_t] Change vertical spacing. Currently ignored. wwaarrnn _f_l_a_g_s Set warning level. Currently ignored. wwaarrnnssccaallee _s_i Set the scaling indicator used in warnings. This is a groff extension and currently ignored. wwaattcchh _m_a_c_r_o_n_a_m_e Notify on change of string or macro. This is a Heirloom extension and currently ignored. wwaattcchhlleennggtthh _m_a_x_l_e_n_g_t_h On change, report the contents of macros and strings up to the specified length. This is a Heirloom extension and currently ignored. wwaattcchhnn _r_e_g_i_s_t_e_r Notify on change of register. This is a Heirloom extension and currently ignored. wwhh _d_i_s_t [_m_a_c_r_o_n_a_m_e] Set a page location trap. Currently unsupported. wwhhiillee _c_o_n_d_i_t_i_o_n _b_o_d_y Repeated execution while a condition is true. Currently unsupported. wwrriittee ["]_s_t_r_i_n_g Write to an open file. Ignored because insecure. wwrriitteecc ["]_s_t_r_i_n_g Write to an open file without appending a newline. Ignored because insecure. wwrriitteemm _m_a_c_r_o_n_a_m_e Write macro or string to an open file. Ignored because insecure. xxffllaagg _l_e_v_e_l Set the extension level. This is a Heirloom extension and currently ignored. NNuummeerriiccaall eexxpprreessssiioonnss The _n_r, _i_f, and _i_e requests accept integer numerical expressions as arguments. These are always evaluated using the C _i_n_t type; integer overflow works the same way as in the C language. Numbers consist of an arbitrary number of digits `0' to `9' prefixed by an optional sign `+' or `-'. Each number may be followed by one optional scaling unit described below _S_c_a_l_i_n_g _W_i_d_t_h_s. The following equations hold: 1i = 6v = 6P = 10m = 10n = 52p = 1000M = 240u = 240 254c = 100i = 24000u = 24000 1f = 65536u = 65536 The following binary operators are implemented. Unless otherwise stated, they behave as in the C language: ++ addition -- subtraction ** multiplication // division %% remainder of division << less than >> greater than ==== equal to == equal to, same effect as ==== (this differs from C) <<== less than or equal to >>== greater than or equal to <<>> not equal to (corresponds to C !!==; this one is of limited portability, it is supported by Heirloom roff, but not by groff) && logical and (corresponds to C &&&&) :: logical or (corresponds to C ||||) <>?? maximum (not available in C) There is no concept of precedence; evaluation proceeds from left to right, except when subexpressions are enclosed in parentheses. Inside parentheses, whitespace is ignored. EESSCCAAPPEE SSEEQQUUEENNCCEE RREEFFEERREENNCCEE The mandoc(1) rrooffff parser recognises the following escape sequences. Note that the rrooffff language defines more escape sequences not implemented in mandoc(1). In mdoc(5) and man(5) documents, using escape sequences is discouraged except for those described in the _L_A_N_G_U_A_G_E _S_Y_N_T_A_X section above. A backslash followed by any character not listed here simply prints that character itself. \\<> A backslash at the end of an input line can be used to continue the logical input line on the next physical input line, joining the text on both lines together as if it were on a single input line. \\<> The escape sequence backslash-space (`\ ') is an unpaddable space-sized non-breaking space character; see _W_h_i_t_e_s_p_a_c_e. \\"" The rest of the input line is treated as _C_o_m_m_e_n_t_s. \\%% Hyphenation allowed at this point of the word; ignored by mandoc(1). \\&& Non-printing zero-width character; see _W_h_i_t_e_s_p_a_c_e. \\'' Acute accent special character; use `\(aa' instead. \\((_c_c _S_p_e_c_i_a_l _C_h_a_r_a_c_t_e_r_s with two-letter names, see mandoc_char(5). \\**[[_n_a_m_e]] Interpolate the string with the _n_a_m_e; see _P_r_e_d_e_f_i_n_e_d _S_t_r_i_n_g_s and _d_s. For short names, there are variants \*_c and \*(_c_c. \\,, Left italic correction (groff extension); ignored by mandoc(1). \\-- Special character "mathematical minus sign". \\// Right italic correction (groff extension); ignored by mandoc(1). \\[[_n_a_m_e]] _S_p_e_c_i_a_l _C_h_a_r_a_c_t_e_r_s with names of arbitrary length, see mandoc_char(5). \\^^ One-twelfth em half-narrow space character, effectively zero-width in mandoc(1). \\`` Grave accent special character; use `\(ga' instead. \\{{ Begin conditional input; see _i_f. \\|| One-sixth em narrow space character, effectively zero-width in mandoc(1). \\}} End conditional input; see _i_f. \\~~ Paddable non-breaking space character. \\00 Digit width space character. \\AA''_s_t_r_i_n_g'' Anchor definition; ignored by mandoc(1). \\BB''_s_t_r_i_n_g'' Interpolate `1' if _s_t_r_i_n_g conforms to the syntax of _N_u_m_e_r_i_c_a_l _e_x_p_r_e_s_s_i_o_n_s explained above and `0' otherwise. \\bb''_s_t_r_i_n_g'' Bracket building function; ignored by mandoc(1). \\CC''_n_a_m_e'' _S_p_e_c_i_a_l _C_h_a_r_a_c_t_e_r_s with names of arbitrary length. \\cc When encountered at the end of an input text line, the next input text line is considered to continue that line, even if there are request or macro lines in between. No whitespace is inserted. \\DD''_s_t_r_i_n_g'' Draw graphics function; ignored by mandoc(1). \\dd Move down by half a line; ignored by mandoc(1). \\ee Backslash special character. \\FF[[_n_a_m_e]] Switch font family (groff extension); ignored by mandoc(1). For short names, there are variants \F_c and \F(_c_c. \\ff[[_n_a_m_e]] Switch to the font _n_a_m_e, see _T_e_x_t _D_e_c_o_r_a_t_i_o_n. For short names, there are variants \f_c and \f(_c_c. \\gg[[_n_a_m_e]] Interpolate the format of a number register; ignored by mandoc(1). For short names, there are variants \g_c and \g(_c_c. \\HH''[[++||--]]_n_u_m_b_e_r'' Set the height of the current font; ignored by mandoc(1). \\hh''[[||]]_w_i_d_t_h'' Horizontal motion. If the vertical bar is given, the motion is relative to the current indentation. Otherwise, it is relative to the current position. The default scaling unit is mm. \\kk[[_n_a_m_e]] Mark horizontal input place in register; ignored by mandoc(1). For short names, there are variants \k_c and \k(_c_c. \\LL''_n_u_m_b_e_r[[_c]]'' Vertical line drawing function; ignored by mandoc(1). \\ll''_w_i_d_t_h[[_c]]'' Draw a horizontal line of _w_i_d_t_h using the glyph _c. \\MM[[_n_a_m_e]] Set fill (background) color (groff extension); ignored by mandoc(1). For short names, there are variants \M_c and \M(_c_c. \\mm[[_n_a_m_e]] Set glyph drawing color (groff extension); ignored by mandoc(1). For short names, there are variants \m_c and \m(_c_c. \\NN''_n_u_m_b_e_r'' Character _n_u_m_b_e_r on the current font. \\nn[[++||--]][[_n_a_m_e]] Interpolate the number register _n_a_m_e. For short names, there are variants \n_c and \n(_c_c. If the optional sign is specified, the register is first incremented or decremented by the _s_t_e_p_s_i_z_e that was specified in the relevant nnrr request, and the changed value is interpolated. \\oo''_s_t_r_i_n_g'' Overstrike, writing all the characters contained in the _s_t_r_i_n_g to the same output position. In terminal and HTML output modes, only the last one of the characters is visible. \\pp Break the output line at the end of the current word. \\RR''_n_a_m_e [[++||--]]_n_u_m_b_e_r'' Set number register; ignored by mandoc(1). \\SS''_n_u_m_b_e_r'' Slant output; ignored by mandoc(1). \\ss''[[++||--]]_n_u_m_b_e_r'' Change point size; ignored by mandoc(1). Alternative forms \s[+|-]_n, \s[+|-]'_n_u_m_b_e_r', \s[[+|-]_n_u_m_b_e_r], and \s[+|-][_n_u_m_b_e_r] are also parsed and ignored. \\tt Horizontal tab; ignored by mandoc(1). \\uu Move up by half a line; ignored by mandoc(1). \\VV[[_n_a_m_e]] Interpolate an environment variable; ignored by mandoc(1). For short names, there are variants \V_c and \V(_c_c. \\vv''_n_u_m_b_e_r'' Vertical motion; ignored by mandoc(1). \\ww''_s_t_r_i_n_g'' Interpolate the width of the _s_t_r_i_n_g. The mandoc(1) implementation assumes that after expansion of user-defined strings, the _s_t_r_i_n_g only contains normal characters, no escape sequences, and that each character has a width of 24 basic units. \\XX''_s_t_r_i_n_g'' Output _s_t_r_i_n_g as device control function; ignored in nroff mode and by mandoc(1). \\xx''_n_u_m_b_e_r'' Extra line space function; ignored by mandoc(1). \\YY[[_n_a_m_e]] Output a string as a device control function; ignored in nroff mode and by mandoc(1). For short names, there are variants \Y_c and \Y(_c_c. \\ZZ''_s_t_r_i_n_g'' Print _s_t_r_i_n_g with zero width and height; ignored by mandoc(1). \\zz Output the next character without advancing the cursor position. CCOOMMPPAATTIIBBIILLIITTYY The mandoc(1) implementation of the rrooffff language is intentionally incomplete. Unimplemented features include: -- For security reasons, mandoc(1) never reads or writes external files except via _s_o requests with safe relative paths. -- There is no automatic hyphenation, no adjustment to the right margin, and no centering; the output is always set flush-left. -- Support for setting tabulator positions and tabulator and leader characters is missing, and support for manually changing indentation is limited. -- The `u' scaling unit is the default terminal unit. In traditional troff systems, this unit changes depending on the output media. -- Width measurements are implemented in a crude way and often yield wrong results. Explicit movement requests and escapes are ignored. -- There is no concept of output pages, no support for floats, graphics drawing, and picture inclusion; terminal output is always continuous. -- Requests regarding color, font families, and glyph manipulation are ignored. Font support is very limited. Kerning is not implemented, and no ligatures are produced. -- The "'" macro control character does not suppress output line breaks. -- Diversions are not implemented, and support for traps is very incomplete. -- While recursion is supported, _w_h_i_l_e loops are not. The special semantics of the nnSS number register is an idiosyncracy of OpenBSD manuals and not supported by other mdoc(5) implementations. SSEEEE AALLSSOO mandoc(1), eqn(5), man(5), mandoc_char(5), mdoc(5), tbl(5) Joseph F. Ossanna and Brian W. Kernighan, _T_r_o_f_f _U_s_e_r_'_s _M_a_n_u_a_l, _A_T_&_T _B_e_l_l _L_a_b_o_r_a_t_o_r_i_e_s, Computing Science Technical Report, 54, http://www.kohala.com/start/troff/cstr54.ps, Murray Hill, New Jersey, 1976 and 1992. Joseph F. Ossanna, Brian W. Kernighan, and Gunnar Ritter, _H_e_i_r_l_o_o_m _D_o_c_u_m_e_n_t_a_t_i_o_n _T_o_o_l_s _N_r_o_f_f_/_T_r_o_f_f _U_s_e_r_'_s _M_a_n_u_a_l, http://heirloom.sourceforge.net/doctools/troff.pdf, September 17, 2007. HHIISSTTOORRYY The RUNOFF typesetting system, whose input forms the basis for rrooffff, was written in MAD and FAP for the CTSS operating system by Jerome E. Saltzer in 1964. Doug McIlroy rewrote it in BCPL in 1969, renaming it rrooffff. Dennis M. Ritchie rewrote McIlroy's rrooffff in PDP-11 assembly for Version 1 AT&T UNIX, Joseph F. Ossanna improved roff and renamed it nroff for Version 2 AT&T UNIX, then ported nroff to C as troff, which Brian W. Kernighan released with Version 7 AT&T UNIX. In 1989, James Clarke re- implemented troff in C++, naming it groff. AAUUTTHHOORRSS This rrooffff reference was written by Kristaps Dzonsons <_k_r_i_s_t_a_p_s_@_b_s_d_._l_v> and Ingo Schwarze <_s_c_h_w_a_r_z_e_@_o_p_e_n_b_s_d_._o_r_g>. illumos April 10, 2018 illumos