=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/mandoc/Attic/man.7,v retrieving revision 1.21 retrieving revision 1.22 diff -c -r1.21 -r1.22 *** src/usr.bin/mandoc/Attic/man.7 2010/05/14 01:54:37 1.21 --- src/usr.bin/mandoc/Attic/man.7 2010/05/14 14:47:44 1.22 *************** *** 1,4 **** ! .\" $Id: man.7,v 1.21 2010/05/14 01:54:37 schwarze Exp $ .\" .\" Copyright (c) 2009 Kristaps Dzonsons .\" --- 1,4 ---- ! .\" $Id: man.7,v 1.22 2010/05/14 14:47:44 schwarze Exp $ .\" .\" Copyright (c) 2009 Kristaps Dzonsons .\" *************** *** 25,32 **** .Nm man language was historically used to format .Ux ! manuals. This reference document describes its syntax, structure, and ! usage. .Pp .Bf -emphasis Do not use --- 25,32 ---- .Nm man language was historically used to format .Ux ! manuals. ! This reference document describes its syntax, structure, and usage. .Pp .Bf -emphasis Do not use *************** *** 42,48 **** document follows simple rules: lines beginning with the control character .Sq \&. ! are parsed for macros. Other lines are interpreted within the scope of prior macros: .Bd -literal -offset indent \&.SH Macro lines change control state. --- 42,49 ---- document follows simple rules: lines beginning with the control character .Sq \&. ! are parsed for macros. ! Other lines are interpreted within the scope of prior macros: .Bd -literal -offset indent \&.SH Macro lines change control state. *************** *** 51,57 **** .Sh INPUT ENCODING .Nm documents may contain only graphable 7-bit ASCII characters, the ! space character, and the tabs character. All manuals must have .Ux line termination. .Pp --- 52,59 ---- .Sh INPUT ENCODING .Nm documents may contain only graphable 7-bit ASCII characters, the ! space character, and the tabs character. ! All manuals must have .Ux line termination. .Pp *************** *** 61,70 **** Text following a .Sq \e\*" , whether in a macro or free-form text line, is ignored to the end of ! line. A macro line with only a control character and comment escape, .Sq \&.\e" , ! is also ignored. Macro lines with only a control character and ! optionally whitespace are stripped from input. .Ss Special Characters Special characters may occur in both macro and free-form lines. Sequences begin with the escape character --- 63,74 ---- Text following a .Sq \e\*" , whether in a macro or free-form text line, is ignored to the end of ! line. ! A macro line with only a control character and comment escape, .Sq \&.\e" , ! is also ignored. ! Macro lines with only a control character and optionally whitespace are ! stripped from input. .Ss Special Characters Special characters may occur in both macro and free-form lines. Sequences begin with the escape character *************** *** 75,83 **** .Sq \&[ for n-character sequences (terminated at a close-bracket .Sq \&] ) ; ! or a single one-character sequence. See .Xr mandoc_char 7 ! for a complete list. Examples include .Sq \e(em .Pq em-dash and --- 79,89 ---- .Sq \&[ for n-character sequences (terminated at a close-bracket .Sq \&] ) ; ! or a single one-character sequence. ! See .Xr mandoc_char 7 ! for a complete list. ! Examples include .Sq \e(em .Pq em-dash and *************** *** 92,100 **** .D1 \efBbold\efR \efIitalic\efP .Pp A numerical representation 3, 2, or 1 (bold, italic, and Roman, ! respectively) may be used instead. A text decoration is only valid, if ! specified in free-form text, until the next macro invocation; if ! specified within a macro, it's only valid until the macro closes scope. Note that macros like .Sx \&BR open and close a font scope with each argument. --- 98,107 ---- .D1 \efBbold\efR \efIitalic\efP .Pp A numerical representation 3, 2, or 1 (bold, italic, and Roman, ! respectively) may be used instead. ! A text decoration is only valid, if specified in free-form text, until ! the next macro invocation; if specified within a macro, it's only valid ! until the macro closes scope. Note that macros like .Sx \&BR open and close a font scope with each argument. *************** *** 132,145 **** Blank free-form lines, which may include spaces, are permitted and rendered as an empty line. .Pp ! In macro lines, whitespace delimits arguments and is discarded. If ! arguments are quoted, whitespace within the quotes is retained. .Ss Dates The .Sx \&TH macro is the only .Nm ! macro that requires a date. The form for this date is the ISO-8601 standard .Cm YYYY-MM-DD . .Ss Scaling Widths --- 139,153 ---- Blank free-form lines, which may include spaces, are permitted and rendered as an empty line. .Pp ! In macro lines, whitespace delimits arguments and is discarded. ! If arguments are quoted, whitespace within the quotes is retained. .Ss Dates The .Sx \&TH macro is the only .Nm ! macro that requires a date. ! The form for this date is the ISO-8601 standard .Cm YYYY-MM-DD . .Ss Scaling Widths *************** *** 152,159 **** The syntax for scaled widths is .Sq Li [+-]?[0-9]*.[0-9]*[:unit:]? , where a decimal must be preceded or proceeded by at least one digit. ! Negative numbers, while accepted, are truncated to zero. The following ! scaling units are accepted: .Pp .Bl -tag -width Ds -offset indent -compact .It c --- 160,167 ---- The syntax for scaled widths is .Sq Li [+-]?[0-9]*.[0-9]*[:unit:]? , where a decimal must be preceded or proceeded by at least one digit. ! Negative numbers, while accepted, are truncated to zero. ! The following scaling units are accepted: .Pp .Bl -tag -width Ds -offset indent -compact .It c *************** *** 209,222 **** .Nm document must contain contains at least the .Sx \&TH ! macro describing the document's section and title. It may occur ! anywhere in the document, although conventionally, it appears as the ! first macro. .Pp Beyond .Sx \&TH , ! at least one macro or text node must appear in the document. Documents ! are generally structured as follows: .Bd -literal -offset indent \&.TH FOO 1 2009-10-10 \&. --- 217,230 ---- .Nm document must contain contains at least the .Sx \&TH ! macro describing the document's section and title. ! It may occur anywhere in the document, although conventionally, it ! appears as the first macro. .Pp Beyond .Sx \&TH , ! at least one macro or text node must appear in the document. ! Documents are generally structured as follows: .Bd -literal -offset indent \&.TH FOO 1 2009-10-10 \&. *************** *** 232,244 **** The \efBfoo\efR utility processes files... \&. \&.\e\*q .SH IMPLEMENTATION NOTES - \&.\e\*q The next is for sections 1 & 8 only. - \&.\e\*q .SH EXIT STATUS \&.\e\*q The next is for sections 2, 3, & 9 only. \&.\e\*q .SH RETURN VALUES \&.\e\*q The next is for sections 1, 6, 7, & 8 only. \&.\e\*q .SH ENVIRONMENT \&.\e\*q .SH FILES \&.\e\*q .SH EXAMPLES \&.\e\*q The next is for sections 1, 4, 6, 7, & 8 only. \&.\e\*q .SH DIAGNOSTICS --- 240,252 ---- The \efBfoo\efR utility processes files... \&. \&.\e\*q .SH IMPLEMENTATION NOTES \&.\e\*q The next is for sections 2, 3, & 9 only. \&.\e\*q .SH RETURN VALUES \&.\e\*q The next is for sections 1, 6, 7, & 8 only. \&.\e\*q .SH ENVIRONMENT \&.\e\*q .SH FILES + \&.\e\*q The next is for sections 1 & 8 only. + \&.\e\*q .SH EXIT STATUS \&.\e\*q .SH EXAMPLES \&.\e\*q The next is for sections 1, 4, 6, 7, & 8 only. \&.\e\*q .SH DIAGNOSTICS *************** *** 256,273 **** .Pp The sections in a .Nm ! document are conventionally ordered as they appear above. Sections ! should be composed as follows: .Bl -ohang -offset indent .It Em NAME ! The name(s) and a short description of the documented material. The ! syntax for this is generally as follows: .Pp .D1 \efBname\efR \e(en description .It Em LIBRARY The name of the library containing the documented material, which is ! assumed to be a function in a section 2 or 3 manual. For functions in ! the C library, this may be as follows: .Pp .D1 Standard C Library (libc, -lc) .It Em SYNOPSIS --- 264,281 ---- .Pp The sections in a .Nm ! document are conventionally ordered as they appear above. ! Sections should be composed as follows: .Bl -ohang -offset indent .It Em NAME ! The name(s) and a short description of the documented material. ! The syntax for this is generally as follows: .Pp .D1 \efBname\efR \e(en description .It Em LIBRARY The name of the library containing the documented material, which is ! assumed to be a function in a section 2 or 3 manual. ! For functions in the C library, this may be as follows: .Pp .D1 Standard C Library (libc, -lc) .It Em SYNOPSIS *************** *** 295,328 **** It usually contains a break-down of the options (if documenting a command). .It Em IMPLEMENTATION NOTES ! Implementation-specific notes should be kept here. This is useful when ! implementing standard functions that may have side effects or notable ! algorithmic implications. ! .It Em EXIT STATUS ! Command exit status for section 1, 6, and 8 manuals. This section is ! the dual of ! .Em RETURN VALUES , ! which is used for functions. Historically, this information was ! described in ! .Em DIAGNOSTICS , ! a practise that is now discouraged. .It Em RETURN VALUES This section is the dual of .Em EXIT STATUS , ! which is used for commands. It documents the return values of functions ! in sections 2, 3, and 9. .It Em ENVIRONMENT Documents any usages of environment variables, e.g., .Xr environ 7 . .It Em FILES ! Documents files used. It's helpful to document both the file and a ! short description of how the file is used (created, modified, etc.). .It Em EXAMPLES ! Example usages. This often contains snippets of well-formed, ! well-tested invocations. Make doubly sure that your examples work ! properly! .It Em DIAGNOSTICS ! Documents error conditions. This is most useful in section 4 manuals. Historically, this section was used in place of .Em EXIT STATUS for manuals in sections 1, 6, and 8; however, this practise is --- 303,339 ---- It usually contains a break-down of the options (if documenting a command). .It Em IMPLEMENTATION NOTES ! Implementation-specific notes should be kept here. ! This is useful when implementing standard functions that may have side ! effects or notable algorithmic implications. .It Em RETURN VALUES This section is the dual of .Em EXIT STATUS , ! which is used for commands. ! It documents the return values of functions in sections 2, 3, and 9. .It Em ENVIRONMENT Documents any usages of environment variables, e.g., .Xr environ 7 . .It Em FILES ! Documents files used. ! It's helpful to document both the file and a short description of how ! the file is used (created, modified, etc.). ! .It Em EXIT STATUS ! Command exit status for section 1, 6, and 8 manuals. ! This section is the dual of ! .Em RETURN VALUES , ! which is used for functions. ! Historically, this information was described in ! .Em DIAGNOSTICS , ! a practise that is now discouraged. .It Em EXAMPLES ! Example usages. ! This often contains snippets of well-formed, ! well-tested invocations. ! Make doubly sure that your examples work properly! .It Em DIAGNOSTICS ! Documents error conditions. ! This is most useful in section 4 manuals. Historically, this section was used in place of .Em EXIT STATUS for manuals in sections 1, 6, and 8; however, this practise is *************** *** 330,337 **** .It Em ERRORS Documents error handling in sections 2, 3, and 9. .It Em SEE ALSO ! References other manuals with related topics. This section should exist ! for most manuals. .Pp .D1 \&.BR bar \&( 1 \&), .Pp --- 341,348 ---- .It Em ERRORS Documents error handling in sections 2, 3, and 9. .It Em SEE ALSO ! References other manuals with related topics. ! This section should exist for most manuals. .Pp .D1 \&.BR bar \&( 1 \&), .Pp *************** *** 364,374 **** Macros are one to three three characters in length and begin with a control character , .Sq \&. , ! at the beginning of the line. The .Sq \(aq ! macro control character is also accepted. An arbitrary amount of ! whitespace (spaces or tabs) may sit between the control character and ! the macro name. Thus, the following are equivalent: .Bd -literal -offset indent \&.PP \&.\ \ \ PP --- 375,387 ---- Macros are one to three three characters in length and begin with a control character , .Sq \&. , ! at the beginning of the line. ! The .Sq \(aq ! macro control character is also accepted. ! An arbitrary amount of whitespace (spaces or tabs) may sit between the ! control character and the macro name. ! Thus, the following are equivalent: .Bd -literal -offset indent \&.PP \&.\ \ \ PP *************** *** 376,390 **** .Pp The .Nm ! macros are classified by scope: line scope or block scope. Line ! macros are only scoped to the current line (and, in some situations, ! the subsequent line). Block macros are scoped to the current line and ! subsequent lines until closed by another block macro. .Ss Line Macros Line macros are generally scoped to the current line, with the body ! consisting of zero or more arguments. If a macro is scoped to the next ! line and the line arguments are empty, the next line, which must be ! text, is used instead. Thus: .Bd -literal -offset indent \&.I foo --- 389,405 ---- .Pp The .Nm ! macros are classified by scope: line scope or block scope. ! Line macros are only scoped to the current line (and, in some ! situations, the subsequent line). ! Block macros are scoped to the current line and subsequent lines until ! closed by another block macro. .Ss Line Macros Line macros are generally scoped to the current line, with the body ! consisting of zero or more arguments. ! If a macro is scoped to the next line and the line arguments are empty, ! the next line, which must be text, is used instead. ! Thus: .Bd -literal -offset indent \&.I foo *************** *** 438,451 **** Macros marked as .Qq compat are included for compatibility with the significant corpus of existing ! manuals that mix dialects of roff. These macros should not be used for ! portable .Nm manuals. .Ss Block Macros ! Block macros are comprised of a head and body. Like for in-line macros, ! the head is scoped to the current line and, in one circumstance, the ! next line (the next-line stipulations as in .Sx Line Macros apply here as well). .Pp --- 453,466 ---- Macros marked as .Qq compat are included for compatibility with the significant corpus of existing ! manuals that mix dialects of roff. ! These macros should not be used for portable .Nm manuals. .Ss Block Macros ! Block macros are comprised of a head and body. ! Like for in-line macros, the head is scoped to the current line and, in ! one circumstance, the next line (the next-line stipulations as in .Sx Line Macros apply here as well). .Pp *************** *** 500,506 **** macros for decorating text. .Sh REFERENCE This section is a canonical reference to all macros, arranged ! alphabetically. For the scoping of individual macros, see .Sx MACRO SYNTAX . .Ss \&B Text is rendered in bold face. --- 515,522 ---- macros for decorating text. .Sh REFERENCE This section is a canonical reference to all macros, arranged ! alphabetically. ! For the scoping of individual macros, see .Sx MACRO SYNTAX . .Ss \&B Text is rendered in bold face. *************** *** 513,519 **** and .Sx \&r . .Ss \&BI ! Text is rendered alternately in bold face and italic. Thus, .Sq .BI this word and that causes .Sq this --- 529,536 ---- and .Sx \&r . .Ss \&BI ! Text is rendered alternately in bold face and italic. ! Thus, .Sq .BI this word and that causes .Sq this *************** *** 523,529 **** .Sq word and .Sq that ! render in italics. Whitespace between arguments is omitted in output. .Pp Examples: .Pp --- 540,547 ---- .Sq word and .Sq that ! render in italics. ! Whitespace between arguments is omitted in output. .Pp Examples: .Pp *************** *** 558,564 **** and .Sx \&IR . .Ss \&DT ! Has no effect. Included for compatibility. .Ss \&HP Begin a paragraph whose initial output line is left-justified, but subsequent output lines are indented, with the following syntax: --- 576,583 ---- and .Sx \&IR . .Ss \&DT ! Has no effect. ! Included for compatibility. .Ss \&HP Begin a paragraph whose initial output line is left-justified, but subsequent output lines are indented, with the following syntax: *************** *** 622,629 **** .Pp The .Cm head ! argument is used as a leading term, flushed to the left margin. This is ! useful for bulleted paragraphs and so on. .Pp See also .Sx \&HP , --- 641,648 ---- .Pp The .Cm head ! argument is used as a leading term, flushed to the left margin. ! This is useful for bulleted paragraphs and so on. .Pp See also .Sx \&HP , *************** *** 648,656 **** and .Sx \&RI . .Ss \&LP ! Begin an undecorated paragraph. The scope of a paragraph is closed by a ! subsequent paragraph, sub-section, section, or end of file. The saved ! paragraph left-margin width is re-set to the default. .Pp See also .Sx \&HP , --- 667,676 ---- and .Sx \&RI . .Ss \&LP ! Begin an undecorated paragraph. ! The scope of a paragraph is closed by a subsequent paragraph, ! sub-section, section, or end of file. ! The saved paragraph left-margin width is re-set to the default. .Pp See also .Sx \&HP , *************** *** 725,733 **** and .Sx \&IR . .Ss \&RS ! Begin a part setting the left margin. The left margin controls the ! offset, following an initial indentation, to un-indented text such as ! that of .Sx \&PP . This has the following syntax: .Bd -filled -offset indent --- 745,753 ---- and .Sx \&IR . .Ss \&RS ! Begin a part setting the left margin. ! The left margin controls the offset, following an initial indentation, ! to un-indented text such as that of .Sx \&PP . This has the following syntax: .Bd -filled -offset indent *************** *** 744,759 **** Text is rendered in small size (one point smaller than the default font) bold face. .Ss \&SH ! Begin a section. The scope of a section is only closed by another ! section or the end of file. The paragraph left-margin width is re-set ! to the default. .Ss \&SM Text is rendered in small size (one point smaller than the default font). .Ss \&SS ! Begin a sub-section. The scope of a sub-section is closed by a ! subsequent sub-section, section, or end of file. The paragraph ! left-margin width is re-set to the default. .Ss \&TH Sets the title of the manual page with the following syntax: .Bd -filled -offset indent --- 764,781 ---- Text is rendered in small size (one point smaller than the default font) bold face. .Ss \&SH ! Begin a section. ! The scope of a section is only closed by another section or the end of ! file. ! The paragraph left-margin width is re-set to the default. .Ss \&SM Text is rendered in small size (one point smaller than the default font). .Ss \&SS ! Begin a sub-section. ! The scope of a sub-section is closed by a subsequent sub-section, ! section, or end of file. ! The paragraph left-margin width is re-set to the default. .Ss \&TH Sets the title of the manual page with the following syntax: .Bd -filled -offset indent *************** *** 766,778 **** .Cm title and numeric manual section .Cm section ! arguments must be provided. The .Cm date argument should be formatted as described in .Sx Dates : ! if it does not conform, the current date is used instead. The .Cm source ! string specifies the organisation providing the utility. The .Cm volume string replaces the default rendered volume, which is dictated by the manual section. --- 788,803 ---- .Cm title and numeric manual section .Cm section ! arguments must be provided. ! The .Cm date argument should be formatted as described in .Sx Dates : ! if it does not conform, the current date is used instead. ! The .Cm source ! string specifies the organisation providing the utility. ! The .Cm volume string replaces the default rendered volume, which is dictated by the manual section. *************** *** 783,789 **** .Ss \&TP Begin a paragraph where the head, if exceeding the indentation width, is followed by a newline; if not, the body follows on the same line after a ! buffer to the indentation width. Subsequent output lines are indented. The syntax is as follows: .Bd -filled -offset indent .Pf \. Sx \&TP --- 808,815 ---- .Ss \&TP Begin a paragraph where the head, if exceeding the indentation width, is followed by a newline; if not, the body follows on the same line after a ! buffer to the indentation width. ! Subsequent output lines are indented. The syntax is as follows: .Bd -filled -offset indent .Pf \. Sx \&TP *************** *** 813,819 **** .\" .Ss \&UC .\" Has no effect. Included for compatibility. .Ss \&br ! Breaks the current line. Consecutive invocations have no further effect. .Pp See also .Sx \&sp . --- 839,846 ---- .\" .Ss \&UC .\" Has no effect. Included for compatibility. .Ss \&br ! Breaks the current line. ! Consecutive invocations have no further effect. .Pp See also .Sx \&sp . *************** *** 821,827 **** End literal mode begun by .Sx \&nf . .Ss \&i ! Italicise arguments. Synonym for .Sx \&I . .Pp See also --- 848,855 ---- End literal mode begun by .Sx \&nf . .Ss \&i ! Italicise arguments. ! Synonym for .Sx \&I . .Pp See also *************** *** 835,841 **** Don't align to the right margin. .Ss \&nf Begin literal mode: all subsequent free-form lines have their end of ! line boundaries preserved. May be ended by .Sx \&fi . .Ss \&r Fonts and styles (bold face, italics) reset to roman (default font). --- 863,870 ---- Don't align to the right margin. .Ss \&nf Begin literal mode: all subsequent free-form lines have their end of ! line boundaries preserved. ! May be ended by .Sx \&fi . .Ss \&r Fonts and styles (bold face, italics) reset to roman (default font). *************** *** 860,866 **** .Sx Scaling Widths . If 0, this is equivalent to the .Sx \&br ! macro. Defaults to 1, if unspecified. .Pp See also .Sx \&br . --- 889,896 ---- .Sx Scaling Widths . If 0, this is equivalent to the .Sx \&br ! macro. ! Defaults to 1, if unspecified. .Pp See also .Sx \&br . *************** *** 888,900 **** .Bl -dash -compact .It In quoted literals, GNU troff allowed pair-wise double-quotes to produce ! a standalone double-quote in formatted output. It is not known whether ! this behaviour is exhibited by other formatters. .It The .Sx \&sp ! macro does not accept negative values in mandoc. In GNU troff, this ! would result in strange behaviour. .It The .Sq \(aq --- 918,930 ---- .Bl -dash -compact .It In quoted literals, GNU troff allowed pair-wise double-quotes to produce ! a standalone double-quote in formatted output. ! It is not known whether this behaviour is exhibited by other formatters. .It The .Sx \&sp ! macro does not accept negative values in mandoc. ! In GNU troff, this would result in strange behaviour. .It The .Sq \(aq *************** *** 912,917 **** reference was written by .An Kristaps Dzonsons Aq kristaps@bsd.lv . .Sh CAVEATS ! Do not use this language. Use .Xr mdoc 7 , instead. --- 942,948 ---- reference was written by .An Kristaps Dzonsons Aq kristaps@bsd.lv . .Sh CAVEATS ! Do not use this language. ! Use .Xr mdoc 7 , instead.