version 1.187, 2011/05/21 15:55:42 |
version 1.190, 2011/07/15 20:40:32 |
Line 296 sections, although this varies between manual sections |
|
Line 296 sections, although this varies between manual sections |
|
.Pp |
.Pp |
The following is a well-formed skeleton |
The following is a well-formed skeleton |
.Nm |
.Nm |
file: |
file for a utility |
|
.Qq progname : |
.Bd -literal -offset indent |
.Bd -literal -offset indent |
\&.Dd $\&Mdocdate$ |
\&.Dd $\&Mdocdate$ |
\&.Dt mdoc 7 |
\&.Dt PROGNAME section |
\&.Os |
\&.Os |
\&.Sh NAME |
\&.Sh NAME |
\&.Nm foo |
\&.Nm progname |
\&.Nd a description goes here |
\&.Nd a description goes here |
\&.\e\*q .Sh LIBRARY |
\&.\e\*q .Sh LIBRARY |
\&.\e\*q For sections 2, 3, & 9 only. |
\&.\e\*q For sections 2, 3, & 9 only. |
\&.\e\*q Not used in OpenBSD. |
\&.\e\*q Not used in OpenBSD. |
\&.Sh SYNOPSIS |
\&.Sh SYNOPSIS |
\&.Nm foo |
\&.Nm progname |
\&.Op Fl options |
\&.Op Fl options |
\&.Ar |
\&.Ar |
\&.Sh DESCRIPTION |
\&.Sh DESCRIPTION |
|
|
.Em SYNOPSIS |
.Em SYNOPSIS |
section line, else it is |
section line, else it is |
.Sx In-line . |
.Sx In-line . |
|
.Ss Special block macro |
|
The |
|
.Sx \&Ta |
|
macro can only be used below |
|
.Sx \&It |
|
in |
|
.Sx \&Bl Fl column |
|
lists. |
|
It delimits blocks representing table cells; |
|
these blocks have bodies, but no heads. |
|
.Pp |
|
.Bl -column "MacroX" "CallableX" "ParsedX" "closed by XXXX" -compact -offset indent |
|
.It Em Macro Ta Em Callable Ta Em Parsed Ta Em Scope |
|
.It Sx \&Ta Ta Yes Ta Yes Ta closed by Sx \&Ta , Sx \&It |
|
.El |
.Ss In-line |
.Ss In-line |
Closed by |
Closed by |
.Sx Reserved Terms , |
.Sx Reserved Terms , |
|
|
and |
and |
.Sx \&Os . |
.Sx \&Os . |
.Ss \&Dv |
.Ss \&Dv |
Defined variables such as preprocessor constants. |
Defined variables such as preprocessor constants, constant symbols, |
|
enumeration values, and so on. |
.Pp |
.Pp |
Examples: |
Examples: |
|
.Dl \&.Dv NULL |
.Dl \&.Dv BUFSIZ |
.Dl \&.Dv BUFSIZ |
.Dl \&.Dv STDOUT_FILENO |
.Dl \&.Dv STDOUT_FILENO |
.Pp |
.Pp |
See also |
See also |
.Sx \&Er . |
.Sx \&Er |
|
and |
|
.Sx \&Ev |
|
for special-purpose constants and |
|
.Sx \&Va |
|
for variable symbols. |
.Ss \&Dx |
.Ss \&Dx |
Format the DragonFly BSD version provided as an argument, or a default |
Format the DragonFly BSD version provided as an argument, or a default |
value if no argument is provided. |
value if no argument is provided. |
Line 1773 argument is used as the enclosure head, for example, s |
|
Line 1796 argument is used as the enclosure head, for example, s |
|
will emulate |
will emulate |
.Sx \&Do . |
.Sx \&Do . |
.Ss \&Er |
.Ss \&Er |
Display error constants. |
Error constants for definitions of the |
|
.Va errno |
|
libc global variable. |
.Pp |
.Pp |
Examples: |
Examples: |
.Dl \&.Er EPERM |
.Dl \&.Er EPERM |
.Dl \&.Er ENOENT |
.Dl \&.Er ENOENT |
.Pp |
.Pp |
See also |
See also |
.Sx \&Dv . |
.Sx \&Dv |
|
for general constants. |
.Ss \&Es |
.Ss \&Es |
This macro is obsolete and not implemented. |
This macro is obsolete and not implemented. |
.Ss \&Ev |
.Ss \&Ev |
Line 1790 Environmental variables such as those specified in |
|
Line 1816 Environmental variables such as those specified in |
|
Examples: |
Examples: |
.Dl \&.Ev DISPLAY |
.Dl \&.Ev DISPLAY |
.Dl \&.Ev PATH |
.Dl \&.Ev PATH |
|
.Pp |
|
See also |
|
.Sx \&Dv |
|
for general constants. |
.Ss \&Ex |
.Ss \&Ex |
Insert a standard sentence regarding exit values. |
Insert a standard sentence regarding exit values. |
Its syntax is as follows: |
Its syntax is as follows: |
|
|
.Sx \&Fc , |
.Sx \&Fc , |
and |
and |
.Sx \&Ft . |
.Sx \&Ft . |
|
.Ss \&Fr |
|
This macro is obsolete and not implemented. |
.Ss \&Ft |
.Ss \&Ft |
A function type. |
A function type. |
Its syntax is as follows: |
Its syntax is as follows: |
|
|
list is the most complicated. |
list is the most complicated. |
Its syntax is as follows: |
Its syntax is as follows: |
.Pp |
.Pp |
.D1 Pf \. Sx \&It Op Cm args |
.D1 Pf \. Sx \&It Ar cell Op <TAB> Ar cell ... |
|
.D1 Pf \. Sx \&It Ar cell Op Sx \&Ta Ar cell ... |
.Pp |
.Pp |
The |
The arguments consist of one or more lines of text and macros |
.Cm args |
representing a complete table line. |
are phrases, a mix of macros and text corresponding to a line column, |
Cells within the line are delimited by tabs or by the special |
delimited by tabs or the special |
.Sx \&Ta |
.Sq \&Ta |
block macro. |
pseudo-macro. |
The tab cell delimiter may only be used within the |
Lines subsequent the |
|
.Sx \&It |
.Sx \&It |
are interpreted within the scope of the last phrase. |
line itself; on following lines, only the |
Calling the pseudo-macro |
.Sx \&Ta |
.Sq \&Ta |
macro can be used to delimit cells, and |
will open a new phrase scope (this must occur on a macro line to be |
.Sx \&Ta |
interpreted as a macro). |
is only recognized as a macro when called by other macros, |
Note that the tab phrase delimiter may only be used within the |
not as the first macro on a line. |
|
.Pp |
|
Note that quoted strings may span tab-delimited cells on an |
.Sx \&It |
.Sx \&It |
line itself. |
line. |
Subsequent this, only the |
For example, |
.Sq \&Ta |
|
pseudo-macro may be used to delimit phrases. |
|
Furthermore, note that quoted sections propagate over tab-delimited |
|
phrases on an |
|
.Sx \&It , |
|
for example, |
|
.Pp |
.Pp |
.Dl .It \(dqcol1 ; <TAB> col2 ;\(dq \&; |
.Dl .It \(dqcol1 ; <TAB> col2 ;\(dq \&; |
.Pp |
.Pp |
|
|
.Sx \&Li , |
.Sx \&Li , |
and |
and |
.Sx \&Em . |
.Sx \&Em . |
|
.Ss \&Ta |
|
Table cell separator in |
|
.Sx \&Bl Fl column |
|
lists; can only be used below |
|
.Sx \&It . |
.Ss \&Tn |
.Ss \&Tn |
Format a tradename. |
Format a tradename. |
.Pp |
.Pp |
Line 2777 Newer groff and mandoc print |
|
Line 2810 Newer groff and mandoc print |
|
.Qq AT&T UNIX |
.Qq AT&T UNIX |
and the arguments. |
and the arguments. |
.It |
.It |
.Sx \&Bd Fl column |
.Sx \&Bl Fl column |
does not recognize trailing punctuation characters when they immediately |
does not recognize trailing punctuation characters when they immediately |
precede tabulator characters, but treats them as normal text and |
precede tabulator characters, but treats them as normal text and |
outputs a space before them. |
outputs a space before them. |