summaryrefslogtreecommitdiff
path: root/usr/src/man
diff options
context:
space:
mode:
Diffstat (limited to 'usr/src/man')
-rw-r--r--usr/src/man/man1/mandoc.1166
-rw-r--r--usr/src/man/man3c/ffs.3c2
-rw-r--r--usr/src/man/man4/ike.config.42
-rw-r--r--usr/src/man/man4/rcmscript.419
-rw-r--r--usr/src/man/man5/eqn.510
-rw-r--r--usr/src/man/man5/mandoc_char.5114
-rw-r--r--usr/src/man/man5/mandoc_roff.534
-rw-r--r--usr/src/man/man5/mdoc.529
8 files changed, 215 insertions, 161 deletions
diff --git a/usr/src/man/man1/mandoc.1 b/usr/src/man/man1/mandoc.1
index 9654a08bd0..d66d47a491 100644
--- a/usr/src/man/man1/mandoc.1
+++ b/usr/src/man/man1/mandoc.1
@@ -1,4 +1,4 @@
-.\" $Id: mandoc.1,v 1.155 2015/02/23 13:31:03 schwarze Exp $
+.\" $Id: mandoc.1,v 1.164 2015/11/05 17:47:51 schwarze Exp $
.\"
.\" Copyright (c) 2009, 2010, 2011 Kristaps Dzonsons <kristaps@bsd.lv>
.\" Copyright (c) 2012, 2014, 2015 Ingo Schwarze <schwarze@openbsd.org>
@@ -15,7 +15,7 @@
.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
.\"
-.Dd $Mdocdate: April 9 2016 $
+.Dd $Mdocdate: November 5 2015 $
.Dt MANDOC 1
.Os
.Sh NAME
@@ -24,14 +24,12 @@
.Sh SYNOPSIS
.Nm mandoc
.Op Fl acfhkl
-.Sm off
-.Op Fl I Cm os Li = Ar name
-.Sm on
-.Op Fl K Ns Ar encoding
+.Op Fl I Cm os Ns = Ns Ar name
+.Op Fl K Ar encoding
.Op Fl m Ns Ar format
-.Op Fl O Ns Ar option
-.Op Fl T Ns Ar output
-.Op Fl W Ns Ar level
+.Op Fl O Ar option
+.Op Fl T Ar output
+.Op Fl W Ar level
.Op Ar
.Sh DESCRIPTION
The
@@ -49,7 +47,7 @@ or
text from stdin, implying
.Fl m Ns Cm andoc ,
and produces
-.Fl T Ns Cm locale
+.Fl T Cm locale
output.
.Pp
The options are as follows:
@@ -77,9 +75,7 @@ This overrides any earlier
and
.Fl l
options.
-.Sm off
-.It Fl I Cm os Li = Ar name
-.Sm on
+.It Fl I Cm os Ns = Ns Ar name
Override the default operating system
.Ar name
for the
@@ -93,7 +89,7 @@ macro.
Display only the SYNOPSIS lines.
Implies
.Fl c .
-.It Fl K Ns Ar encoding
+.It Fl K Ar encoding
Specify the input encoding.
The supported
.Ar encoding
@@ -128,16 +124,16 @@ See
for available formats.
Defaults to
.Fl m Ns Cm andoc .
-.It Fl O Ns Ar option
+.It Fl O Ar option
Comma-separated output options.
-.It Fl T Ns Ar output
+.It Fl T Ar output
Output format.
See
.Sx Output Formats
for available formats.
Defaults to
-.Fl T Ns Cm locale .
-.It Fl W Ns Ar level
+.Fl T Cm locale .
+.It Fl W Ar level
Specify the minimum message
.Ar level
to be reported on the standard error output and to affect the exit status.
@@ -161,7 +157,7 @@ and
for details.
.Pp
The special option
-.Fl W Ns Cm stop
+.Fl W Cm stop
tells
.Nm
to exit after parsing a file that causes warnings or errors of at least
@@ -172,7 +168,7 @@ If both a
and
.Cm stop
are requested, they can be joined with a comma, for example
-.Fl W Ns Cm error , Ns Cm stop .
+.Fl W Cm error , Ns Cm stop .
.It Ar file
Read input from zero or more files.
If unspecified, reads from stdin.
@@ -229,54 +225,54 @@ The
utility accepts the following
.Fl T
arguments, which correspond to output modes:
-.Bl -tag -width "-Tlocale"
-.It Fl T Ns Cm ascii
+.Bl -tag -width "-T locale"
+.It Fl T Cm ascii
Produce 7-bit ASCII output.
See
.Sx ASCII Output .
-.It Fl T Ns Cm html
+.It Fl T Cm html
Produce HTML5, CSS1, and MathML output.
See
.Sx HTML Output .
.It Fl T Ns Cm lint
Parse only: produce no output.
Implies
-.Fl W Ns Cm warning .
-.It Fl T Ns Cm locale
+.Fl W Cm warning .
+.It Fl T Cm locale
Encode output using the current locale.
This is the default.
See
.Sx Locale Output .
-.It Fl T Ns Cm man
+.It Fl T Cm man
Produce
.Xr man 5
format output.
See
.Sx Man Output .
-.It Fl T Ns Cm pdf
+.It Fl T Cm pdf
Produce PDF output.
See
.Sx PDF Output .
-.It Fl T Ns Cm ps
+.It Fl T Cm ps
Produce PostScript output.
See
.Sx PostScript Output .
-.It Fl T Ns Cm tree
+.It Fl T Cm tree
Produce an indented parse tree.
-.It Fl T Ns Cm utf8
+.It Fl T Cm utf8
Encode output in the UTF\-8 multi-byte format.
See
.Sx UTF\-8 Output .
-.It Fl T Ns Cm xhtml
+.It Fl T Cm xhtml
This is a synonym for
-.Fl T Ns Cm html .
+.Fl T Cm html .
.El
.Pp
If multiple input files are specified, these will be processed by the
corresponding filter in-order.
.Ss ASCII Output
Output produced by
-.Fl T Ns Cm ascii
+.Fl T Cm ascii
is rendered in standard 7-bit ASCII documented in
.Xr ascii 5 .
.Pp
@@ -318,7 +314,7 @@ which will normalise to \(>=58.
.El
.Ss HTML Output
Output produced by
-.Fl T Ns Cm html
+.Fl T Cm html
conforms to HTML5 using optional self-closing tags.
Default styles use only CSS1.
Equations rendered from
@@ -326,11 +322,11 @@ Equations rendered from
blocks use MathML.
.Pp
The
-.Pa example.style.css
+.Pa mandoc.css
file documents style-sheet classes available for customising output.
If a style-sheet is not specified with
-.Fl O Ns Ar style ,
-.Fl T Ns Cm html
+.Fl O Cm style ,
+.Fl T Cm html
defaults to simple output (via an embedded style-sheet)
readable in any graphical or text-based web
browser.
@@ -386,7 +382,7 @@ relative URI.
.El
.Ss Locale Output
Locale-depending output encoding is triggered with
-.Fl T Ns Cm locale .
+.Fl T Cm locale .
This is the default.
.Ss Man Output
Translate input format into
@@ -414,7 +410,7 @@ level controls which
are displayed before copying the input to the output.
.Ss PDF Output
PDF-1.1 output may be generated by
-.Fl T Ns Cm pdf .
+.Fl T Cm pdf .
See
.Sx PostScript Output
for
@@ -424,7 +420,7 @@ arguments and defaults.
PostScript
.Qq Adobe-3.0
Level-2 pages may be generated by
-.Fl T Ns Cm ps .
+.Fl T Cm ps .
Output pages default to letter sized and are rendered in the Times font
family, 11-point.
Margins are calculated as 1/9 the page length and width.
@@ -456,11 +452,50 @@ is used.
.El
.Ss UTF\-8 Output
Use
-.Fl T Ns Cm utf8
+.Fl T Cm utf8
to force a UTF\-8 locale.
See
.Sx Locale Output
for details and options.
+.Ss Syntax tree output
+Use
+.Fl T Cm tree
+to show a human readable representation of the syntax tree.
+It is useful for debugging the source code of manual pages.
+The exact format is subject to change, so don't write parsers for it.
+Each output line shows one syntax tree node.
+Child nodes are indented with respect to their parent node.
+The columns are:
+.Pp
+.Bl -enum -compact
+.It
+For macro nodes, the macro name; for text and
+.Xr tbl 5
+nodes, the content.
+There is a special format for
+.Xr eqn 5
+nodes.
+.It
+Node type (text, elem, block, head, body, body-end, tail, tbl, eqn).
+.It
+Flags:
+.Bl -dash -compact
+.It
+An opening parenthesis if the node is an opening delimiter.
+.It
+An asterisk if the node starts a new input line.
+.It
+The input line number (starting at one).
+.It
+A colon.
+.It
+The input column number (starting at one).
+.It
+A closing parenthesis if the node is a closing delimiter.
+.It
+A full stop if the node ends a sentence.
+.El
+.El
.Sh EXIT STATUS
The
.Nm
@@ -477,21 +512,21 @@ they were lower than the requested
.Ar level .
.It 2
At least one warning occurred, but no error, and
-.Fl W Ns Cm warning
+.Fl W Cm warning
was specified.
.It 3
At least one parsing error occurred,
but no unsupported feature was encountered, and
-.Fl W Ns Cm error
+.Fl W Cm error
or
-.Fl W Ns Cm warning
+.Fl W Cm warning
was specified.
.It 4
At least one unsupported feature was encountered, and
-.Fl W Ns Cm unsupp ,
-.Fl W Ns Cm error
+.Fl W Cm unsupp ,
+.Fl W Cm error
or
-.Fl W Ns Cm warning
+.Fl W Cm warning
was specified.
.It 5
Invalid command line arguments were specified.
@@ -505,28 +540,28 @@ to exit at once, possibly in the middle of parsing or formatting a file.
.El
.Pp
Note that selecting
-.Fl T Ns Cm lint
+.Fl T Cm lint
output mode implies
-.Fl W Ns Cm warning .
+.Fl W Cm warning .
.Sh EXAMPLES
To page manuals to the terminal:
.Pp
-.Dl $ mandoc \-Wall,stop mandoc.1 2\*(Gt&1 | less
+.Dl $ mandoc \-W all,stop mandoc.1 2\*(Gt&1 | less
.Dl $ mandoc mandoc.1 mdoc.3 mdoc.5 | less
.Pp
To produce HTML manuals with
-.Ar style.css
+.Pa mandoc.css
as the style-sheet:
.Pp
-.Dl $ mandoc \-Thtml -Ostyle=style.css mdoc.5 \*(Gt mdoc.5.html
+.Dl $ mandoc \-T html -Ostyle=mandoc.css mdoc.5 \*(Gt mdoc.5.html
.Pp
To check over a large set of manuals:
.Pp
-.Dl $ mandoc \-Tlint `find /usr/src -name \e*\e.[1-9]`
+.Dl $ mandoc \-T lint \(gafind /usr/src -name \e*\e.[1-9]\(ga
.Pp
To produce a series of PostScript manuals for A4 paper:
.Pp
-.Dl $ mandoc \-Tps \-Opaper=a4 mdoc.5 man.5 \*(Gt manuals.ps
+.Dl $ mandoc \-T ps \-O paper=a4 mdoc.5 man.5 \*(Gt manuals.ps
.Pp
Convert a modern
.Xr mdoc 5
@@ -536,7 +571,7 @@ format, for use on systems lacking an
.Xr mdoc 5
parser:
.Pp
-.Dl $ mandoc \-Tman foo.mdoc \*(Gt foo.man
+.Dl $ mandoc \-T man foo.mdoc \*(Gt foo.man
.Sh DIAGNOSTICS
Messages displayed by
.Nm
@@ -603,7 +638,7 @@ levels except those about non-existent or unreadable input files
are hidden unless their level, or a lower level, is requested using a
.Fl W
option or
-.Fl T Ns Cm lint
+.Fl T Cm lint
output mode.
.Ss Warnings related to the document prologue
.Bl -ohang
@@ -889,13 +924,6 @@ list block contains text or macros before the first
.Ic \&It
macro.
The offending children are moved before the beginning of the list.
-.It Sy ".Vt block has child macro"
-.Pq mdoc
-The
-.Ic \&Vt
-macro supports plain text arguments only.
-Formatting may be ugly and semantic searching
-for the affected content might not work.
.It Sy "fill mode already enabled, skipping"
.Pq man
A
@@ -1521,6 +1549,13 @@ By requesting the inclusion of a sensitive file, a malicious document
might otherwise trick a privileged user into inadvertently displaying
the file on the screen, revealing the file content to bystanders.
The argument is ignored including the file name following it.
+.It Sy "skipping display without arguments"
+.Pq mdoc
+A
+.Ic \&Bd
+block macro does not have any arguments.
+The block is discarded, and the block content is displayed in
+whatever mode was active before the block.
.It Sy "missing list type, using -item"
.Pq mdoc
A
@@ -1717,6 +1752,7 @@ as if they were a text line.
.Xr mdoc 5 ,
.Xr tbl 5
.Sh AUTHORS
+.An -nosplit
The
.Nm
utility was written by
@@ -1725,10 +1761,10 @@ and is maintained by
.An Ingo Schwarze Aq Mt schwarze@openbsd.org .
.Sh BUGS
In
-.Fl T Ns Cm html ,
+.Fl T Cm html ,
the maximum size of an element attribute is determined by
.Dv BUFSIZ ,
which is usually 1024 bytes.
Be aware of this when setting long link
formats such as
-.Fl O Ns Cm style Ns = Ns Ar really/long/link .
+.Fl O Cm style Ns = Ns Ar really/long/link .
diff --git a/usr/src/man/man3c/ffs.3c b/usr/src/man/man3c/ffs.3c
index 2e59b005b0..2197f9e106 100644
--- a/usr/src/man/man3c/ffs.3c
+++ b/usr/src/man/man3c/ffs.3c
@@ -31,7 +31,7 @@ ffs \- find first set bit
.SH DESCRIPTION
.LP
-The \fBffs()\fR, \fBffsl()\, and \fBffsll()\fR functions finds the first bit set
+The \fBffs()\fR, \fBffsl()\fR, and \fBffsll()\fR functions finds the first bit set
(beginning with the least significant bit) and return the index of that bit.
Bits are numbered starting at one (the least significant bit).
.sp
diff --git a/usr/src/man/man4/ike.config.4 b/usr/src/man/man4/ike.config.4
index c8ff71888a..f6634a9757 100644
--- a/usr/src/man/man4/ike.config.4
+++ b/usr/src/man/man4/ike.config.4
@@ -139,7 +139,7 @@ An IKE phase 1 identity type. IKE phase 1 identity types include:
.RS 4n
A quoted string.
.sp
-Examples include:\fB"Label foo"\fR, or \fB"C=US, OU=Sun Microsystems\\, Inc.,
+Examples include:\fB"Label foo"\fR, or \fB"C=US, OU=Sun Microsystems\e, Inc.,
N=olemcd@eng.example.com"\fR
.sp
A backslash (\fB\e\fR) is an escape character. If the string needs an actual
diff --git a/usr/src/man/man4/rcmscript.4 b/usr/src/man/man4/rcmscript.4
index 86a14113fb..bf88dc894d 100644
--- a/usr/src/man/man4/rcmscript.4
+++ b/usr/src/man/man4/rcmscript.4
@@ -44,7 +44,6 @@ Coordination Manager
.fi
.SH DESCRIPTION
-.sp
.LP
Reconfiguration and Coordination Manager (RCM) is a framework designed to
coordinate device consumers during Solaris Dynamic Reconfiguration (DR). The
@@ -240,7 +239,6 @@ by newlines, where \fIname\fR is the name of the return data item that RCM
expects and \fIvalue\fR is the value associated with the data item.
.RE
.SS "Environment"
-.sp
.LP
The initial environment of RCM scripts is set as follows:
.RS +4
@@ -365,7 +363,6 @@ commands, environment parameters, and name-value pairs is ASCII unless the
controlling environment variables are specified otherwise.
.SS "Commands"
.SS "\fBscriptinfo\fR"
-.sp
.LP
The \fBscriptinfo\fR command is invoked to gather information about the script.
.sp
@@ -416,7 +413,6 @@ pair \fBrcm_failure_reason\fR and exit with status 1.
.RE
.SS "\fBregister\fR"
-.sp
.LP
The \fBregister\fR command is invoked to allow a script to specify the
resources that it or its application handles that could potentially be removed
@@ -450,7 +446,6 @@ pair \fBrcm_failure_reason\fR and exit with status 1.
.RE
.SS "\fBresourceinfo\fR \fIresourcename\fR"
-.sp
.LP
The \fBresourceinfo\fR command is invoked to get the usage information about
\fIresourcename\fR.
@@ -478,7 +473,6 @@ pair \fBrcm_failure_reason\fR and exit with status 1.
.RE
.SS "\fBqueryremove\fR \fIresourcename\fR"
-.sp
.LP
Prior to removing the resource from the system, the \fBqueryremove\fR command
is invoked to query the script to determine whether the script can release the
@@ -535,7 +529,6 @@ name-value pair \fBrcm_failure_reason\fR and exit with status 1.
.RE
.SS "\fBpreremove\fR \fIresourcename\fR"
-.sp
.LP
The \fBpreremove\fR command is invoked prior to an attempt to remove the given
\fIresourcename\fR. In response to this command the script can either release
@@ -590,7 +583,6 @@ name-value pair \fBrcm_failure_reason\fR and exit with status 1.
.RE
.SS "\fBpostremove\fR \fIresourcename\fR"
-.sp
.LP
The \fBpostremove\fR command is invoked after the given \fIresourcename\fR has
been removed.
@@ -628,7 +620,6 @@ pair \fBrcm_failure_reason\fR and exit with status 1.
.RE
.SS "Logging"
-.sp
.LP
A script must log all error and debug messages by writing to stdout the
name-value pairs listed below. The logged messages go to \fBsyslogd\fR(1M) with
@@ -676,7 +667,6 @@ the amount of information to log. \fBRCM_ENV_DEBUG_LEVEL\fR is a numeric value
ranging from 0 to 9, with 0 meaning log the least amount of information and 9
meaning log the most.
.SS "Installing or Removing RCM Scripts"
-.sp
.LP
You must use the following format to name a script:
.sp
@@ -739,7 +729,6 @@ Scripts for any hardware
.RE
.SS "Installing a Script"
-.sp
.LP
To install a script, copy the script to the appropriate directory from the list
above, change the userid and the groupid of the script to the desired values,
@@ -755,7 +744,6 @@ and send \fBSIGHUP\fR to \fBrcm_daemon\fR. For example:
.sp
.SS "Removing a script"
-.sp
.LP
Remove the script from the appropriate directory from the list above and send
\fBSIGHUP\fR to \fBrcm_daemon\fR. For example:
@@ -854,7 +842,7 @@ sub do_resourceinfo
my ($rsrc, $unit);
$rsrc = shift(@ARGV);
- if ($rsrc =~ /^\/dev\/rmt\/([0-9]+)$/) {
+ if ($rsrc =~ /^\e/dev\e/rmt\e/([0-9]+)$/) {
$unit = $1;
print "rcm_resource_usage_info=Backup Tape Unit Number $unit\en";
exit (0);
@@ -900,7 +888,6 @@ sub do_preremove
.in -2
.SH EXIT STATUS
-.sp
.LP
A script must exit with following exit status values:
.sp
@@ -948,7 +935,6 @@ name-value pair \fBrcm_failure_reason\fR before exiting.
.RE
.SH ERRORS
-.sp
.LP
If a script cannot successfully process an RCM command, it must supply to the
RCM a message indicating the reason for failure by writing a name-value pair,
@@ -967,7 +953,6 @@ rcm_failure_reason=\fIfailure_reason\fR
where \fIfailure_reason\fR is a localized human readable message describing the
reason for failure of the RCM command.
.SH ATTRIBUTES
-.sp
.LP
See \fBattributes\fR(5) for descriptions of the following attributes:
.sp
@@ -983,13 +968,11 @@ Interface Stability Evolving
.TE
.SH SEE ALSO
-.sp
.LP
\fBgettext\fR(1), \fBcfgadm\fR(1M), \fBcfgadm_scsi\fR(1M),
\fBcfgadm_pci\fR(1M), \fBsyslog\fR(3C), \fBsignal.h\fR(3HEAD),
\fBsyslog.conf\fR(4), \fBattributes\fR(5), \fBenviron\fR(5)
.SH NOTES
-.sp
.LP
RCM scripts are expected to properly handle all RCM commands that the script
implements and to log all errors. Only root has permission to add or remove an
diff --git a/usr/src/man/man5/eqn.5 b/usr/src/man/man5/eqn.5
index bfdb0cd58c..5fcf9ec3ea 100644
--- a/usr/src/man/man5/eqn.5
+++ b/usr/src/man/man5/eqn.5
@@ -1,4 +1,4 @@
-.\" $Id: eqn.7,v 1.34 2015/03/09 20:17:23 schwarze Exp $
+.\" $Id: eqn.7,v 1.35 2015/03/30 16:06:14 schwarze Exp $
.\"
.\" Copyright (c) 2011 Kristaps Dzonsons <kristaps@bsd.lv>
.\" Copyright (c) 2014 Ingo Schwarze <schwarze@openbsd.org>
@@ -15,7 +15,7 @@
.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
.\"
-.Dd $Mdocdate: March 9 2015 $
+.Dd $Mdocdate: March 30 2015 $
.Dt EQN 5
.Os
.Sh NAME
@@ -146,7 +146,7 @@ is used as the delimiter for the value
.Ar val .
This allows for arbitrary enclosure of terms (not just quotes), such as
.Pp
-.D1 Cm define Ar foo 'bar baz'
+.D1 Cm define Ar foo \(aqbar baz\(aq
.D1 Cm define Ar foo cbar bazc
.Pp
It is an error to have an empty
@@ -166,8 +166,8 @@ created.
Definitions can create arbitrary strings, for example, the following is
a legal construction.
.Bd -literal -offset indent
-define foo 'define'
-foo bar 'baz'
+define foo \(aqdefine\(aq
+foo bar \(aqbaz\(aq
.Ed
.Pp
Self-referencing definitions will raise an error.
diff --git a/usr/src/man/man5/mandoc_char.5 b/usr/src/man/man5/mandoc_char.5
index 48f8348c8e..cf102bb840 100644
--- a/usr/src/man/man5/mandoc_char.5
+++ b/usr/src/man/man5/mandoc_char.5
@@ -1,8 +1,8 @@
-.\" $Id: mandoc_char.7,v 1.59 2015/01/20 19:39:34 schwarze Exp $
+.\" $Id: mandoc_char.7,v 1.63 2015/09/02 15:38:35 schwarze Exp $
.\"
.\" Copyright (c) 2003 Jason McIntyre <jmc@openbsd.org>
.\" Copyright (c) 2009, 2010, 2011 Kristaps Dzonsons <kristaps@bsd.lv>
-.\" Copyright (c) 2011 Ingo Schwarze <schwarze@openbsd.org>
+.\" Copyright (c) 2011, 2013, 2015 Ingo Schwarze <schwarze@openbsd.org>
.\"
.\" Permission to use, copy, modify, and distribute this software for any
.\" purpose with or without fee is hereby granted, provided that the above
@@ -16,7 +16,7 @@
.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
.\"
-.Dd $Mdocdate: January 20 2015 $
+.Dd $Mdocdate: September 2 2015 $
.Dt MANDOC_CHAR 5
.Os
.Sh NAME
@@ -49,7 +49,7 @@ names; instead, provide ASCII transcriptions of the names.
.Ss Dashes and Hyphens
In typography there are different types of dashes of various width:
the hyphen (-),
-the minus sign (\-),
+the minus sign (\(mi),
the en-dash (\(en),
and the em-dash (\(em).
.Pp
@@ -64,10 +64,10 @@ lorry-driver
.Pp
The mathematical minus sign is used for negative numbers or subtraction.
It should be written as
-.Sq \e- :
+.Sq \e(mi :
.Bd -unfilled -offset indent
-a = 3 \e- 1;
-b = \e-2;
+a = 3 \e(mi 1;
+b = \e(mi2;
.Ed
.Pp
The en-dash is used to separate the two elements of a range,
@@ -142,6 +142,28 @@ Note that on text lines, literal double-quote characters can be used
verbatim.
All other quote-like characters can be used verbatim as well,
even on request and macro lines.
+.Ss Accents
+In output modes supporting such special output characters, for example
+.Fl T Cm pdf ,
+some
+.Xr mandoc_roff 5
+formatters convert the following ASCII input characters to the
+following Unicode special output characters:
+.Bl -column x(ga U+2018 -offset indent
+.It \(ga Ta U+2018 Ta left single quotation mark
+.It \(aq Ta U+2019 Ta right single quotation mark
+.It \(ti Ta U+02DC Ta small tilde
+.El
+.Pp
+In prose, this automatic substitution is often desirable;
+but when these characters have to be displayed as plain ASCII
+characters, for example in source code samples, they require
+escaping to render as follows:
+.Bl -column x(ga U+2018 -offset indent
+.It \e(ga Ta U+0060 Ta grave accent
+.It \e(aq Ta U+0027 Ta apostrophe
+.It \e(ti Ta U+007E Ta tilde
+.El
.Ss Periods
The period
.Pq Sq \&.
@@ -196,7 +218,7 @@ Spacing:
.Bl -column "Input" "Description" -offset indent -compact
.It Em Input Ta Em Description
.It Sq \e\ \& Ta unpaddable non-breaking space
-.It \e~ Ta paddable non-breaking space
+.It \e\(ti Ta paddable non-breaking space
.It \e0 Ta unpaddable, breaking digit-width space
.It \e| Ta one-sixth \e(em narrow space, zero width in nroff mode
.It \e^ Ta one-twelfth \e(em half-narrow space, zero width in nroff
@@ -371,9 +393,9 @@ Mathematical:
.It \e(ne Ta \(ne Ta not equivalent
.It \e(ap Ta \(ap Ta tilde operator
.It \e(|= Ta \(|= Ta asymptotically equal
-.It \e(=~ Ta \(=~ Ta approximately equal
-.It \e(~~ Ta \(~~ Ta almost equal
-.It \e(~= Ta \(~= Ta almost equal
+.It \e(=\(ti Ta \(=~ Ta approximately equal
+.It \e(\(ti\(ti Ta \(~~ Ta almost equal
+.It \e(\(ti= Ta \(~= Ta almost equal
.It \e(pt Ta \(pt Ta proportionate
.It \e(es Ta \(es Ta empty set
.It \e(mo Ta \(mo Ta element
@@ -436,15 +458,15 @@ Accents:
.It \e(a. Ta \(a. Ta dotted
.It \e(a^ Ta \(a^ Ta circumflex
.It \e(aa Ta \(aa Ta acute
-.It \e' Ta \' Ta acute
+.It \e\(aq Ta \' Ta acute
.It \e(ga Ta \(ga Ta grave
-.It \e` Ta \` Ta grave
+.It \e\(ga Ta \` Ta grave
.It \e(ab Ta \(ab Ta breve
.It \e(ac Ta \(ac Ta cedilla
.It \e(ad Ta \(ad Ta dieresis
.It \e(ah Ta \(ah Ta caron
.It \e(ao Ta \(ao Ta ring
-.It \e(a~ Ta \(a~ Ta tilde
+.It \e(a\(ti Ta \(a~ Ta tilde
.It \e(ho Ta \(ho Ta ogonek
.It \e(ha Ta \(ha Ta hat (text)
.It \e(ti Ta \(ti Ta tilde (text)
@@ -453,32 +475,32 @@ Accents:
Accented letters:
.Bl -column "Input" "Rendered" "Description" -offset indent -compact
.It Em Input Ta Em Rendered Ta Em Description
-.It \e('A Ta \('A Ta acute A
-.It \e('E Ta \('E Ta acute E
-.It \e('I Ta \('I Ta acute I
-.It \e('O Ta \('O Ta acute O
-.It \e('U Ta \('U Ta acute U
-.It \e('a Ta \('a Ta acute a
-.It \e('e Ta \('e Ta acute e
-.It \e('i Ta \('i Ta acute i
-.It \e('o Ta \('o Ta acute o
-.It \e('u Ta \('u Ta acute u
-.It \e(`A Ta \(`A Ta grave A
-.It \e(`E Ta \(`E Ta grave E
-.It \e(`I Ta \(`I Ta grave I
-.It \e(`O Ta \(`O Ta grave O
-.It \e(`U Ta \(`U Ta grave U
-.It \e(`a Ta \(`a Ta grave a
-.It \e(`e Ta \(`e Ta grave e
-.It \e(`i Ta \(`i Ta grave i
-.It \e(`o Ta \(`i Ta grave o
-.It \e(`u Ta \(`u Ta grave u
-.It \e(~A Ta \(~A Ta tilde A
-.It \e(~N Ta \(~N Ta tilde N
-.It \e(~O Ta \(~O Ta tilde O
-.It \e(~a Ta \(~a Ta tilde a
-.It \e(~n Ta \(~n Ta tilde n
-.It \e(~o Ta \(~o Ta tilde o
+.It \e(\(aqA Ta \('A Ta acute A
+.It \e(\(aqE Ta \('E Ta acute E
+.It \e(\(aqI Ta \('I Ta acute I
+.It \e(\(aqO Ta \('O Ta acute O
+.It \e(\(aqU Ta \('U Ta acute U
+.It \e(\(aqa Ta \('a Ta acute a
+.It \e(\(aqe Ta \('e Ta acute e
+.It \e(\(aqi Ta \('i Ta acute i
+.It \e(\(aqo Ta \('o Ta acute o
+.It \e(\(aqu Ta \('u Ta acute u
+.It \e(\(gaA Ta \(`A Ta grave A
+.It \e(\(gaE Ta \(`E Ta grave E
+.It \e(\(gaI Ta \(`I Ta grave I
+.It \e(\(gaO Ta \(`O Ta grave O
+.It \e(\(gaU Ta \(`U Ta grave U
+.It \e(\(gaa Ta \(`a Ta grave a
+.It \e(\(gae Ta \(`e Ta grave e
+.It \e(\(gai Ta \(`i Ta grave i
+.It \e(\(gao Ta \(`i Ta grave o
+.It \e(\(gau Ta \(`u Ta grave u
+.It \e(\(tiA Ta \(~A Ta tilde A
+.It \e(\(tiN Ta \(~N Ta tilde N
+.It \e(\(tiO Ta \(~O Ta tilde O
+.It \e(\(tia Ta \(~a Ta tilde a
+.It \e(\(tin Ta \(~n Ta tilde n
+.It \e(\(tio Ta \(~o Ta tilde o
.It \e(:A Ta \(:A Ta dieresis A
.It \e(:E Ta \(:E Ta dieresis E
.It \e(:I Ta \(:I Ta dieresis I
@@ -657,7 +679,7 @@ manual.
.Sh UNICODE CHARACTERS
The escape sequences
.Pp
-.Dl \e[uXXXX] and \eC'uXXXX'
+.Dl \e[uXXXX] and \eC\(aquXXXX\(aq
.Pp
are interpreted as Unicode codepoints.
The codepoint must be in the range above U+0080 and less than U+10FFFF.
@@ -669,10 +691,6 @@ must be given as uppercase characters,
and points must be zero-padded to four characters; if
greater than four characters, no zero padding is allowed.
Unicode surrogates are not allowed.
-.\" .Pp
-.\" Unicode glyphs attenuate to the
-.\" .Sq \&?
-.\" character if invalid or not rendered by current output media.
.Sh NUMBERED CHARACTERS
For backward compatibility with existing manuals,
.Xr mandoc 1
@@ -685,7 +703,7 @@ escape sequence, inserting the character
from the current character set into the output.
Of course, this is inherently non-portable and is already marked
as deprecated in the Heirloom roff manual.
-For example, do not use \eN'34', use \e(dq, or even the plain
+For example, do not use \eN\(aq34\(aq, use \e(dq, or even the plain
.Sq \(dq
character where possible.
.Sh COMPATIBILITY
@@ -702,14 +720,14 @@ In
.Fl T Ns Cm ascii ,
the
\e(ss, \e(nm, \e(nb, \e(nc, \e(ib, \e(ip, \e(pp, \e[sum], \e[product],
-\e[coproduct], \e(gr, \e(\-h, and \e(a. special characters render
+\e[coproduct], \e(gr, \e(-h, and \e(a. special characters render
differently between mandoc and groff.
.It
In
.Fl T Ns Cm html
and
.Fl T Ns Cm xhtml ,
-the \e(~=, \e(nb, and \e(nc special characters render differently
+the \e(\(ti=, \e(nb, and \e(nc special characters render differently
between mandoc and groff.
.It
The
diff --git a/usr/src/man/man5/mandoc_roff.5 b/usr/src/man/man5/mandoc_roff.5
index 55be0155aa..471c82e5ce 100644
--- a/usr/src/man/man5/mandoc_roff.5
+++ b/usr/src/man/man5/mandoc_roff.5
@@ -1,7 +1,7 @@
-.\" $Id: roff.7,v 1.70 2015/02/17 17:16:52 schwarze Exp $
+.\" $Id: roff.7,v 1.75 2015/09/24 18:41:22 schwarze Exp $
.\"
.\" Copyright (c) 2010, 2011, 2012 Kristaps Dzonsons <kristaps@bsd.lv>
-.\" Copyright (c) 2010, 2011, 2013, 2014 Ingo Schwarze <schwarze@openbsd.org>
+.\" Copyright (c) 2010, 2011, 2013-2015 Ingo Schwarze <schwarze@openbsd.org>
.\"
.\" Permission to use, copy, modify, and distribute this software for any
.\" purpose with or without fee is hereby granted, provided that the above
@@ -15,7 +15,7 @@
.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
.\"
-.Dd $Mdocdate: April 9 2016 $
+.Dd $Mdocdate: September 24 2015 $
.Dt MANDOC_ROFF 5
.Os
.Sh NAME
@@ -665,6 +665,8 @@ produces
.D1 \efI\e^XtFree\e^\efP.
.Pp
in the input stream, and thus in the output: \fI\^XtFree\^\fP.
+Each occurrence of \e\e$* is replaced with all the arguments,
+joined together with single blank characters.
.Pp
Since macros and user-defined strings share a common string table,
defining a macro
@@ -1057,8 +1059,6 @@ If the first character of COND is
.Pq string defined ,
.Sq e
.Pq even page ,
-.Sq r
-.Pq register accessed ,
.Sq t
.Pq troff mode ,
or
@@ -1066,6 +1066,11 @@ or
.Pq vroff mode ,
COND evaluates to false.
.It
+If the first character of COND is
+.Sq r ,
+it evaluates to true if the rest of COND is the name of an existing
+number register; otherwise, it evaluates to false.
+.It
If COND starts with a parenthesis or with an optionally signed
integer number, it is evaluated according to the rules of
.Sx Numerical expressions
@@ -1337,7 +1342,7 @@ Currently unsupported.
Temporarily turn off line numbering.
Currently unsupported.
.Ss \&nop
-Exexute the rest of the input line as a request or macro line.
+Execute the rest of the input line as a request or macro line.
Currently unsupported.
.Ss \&nr
Define or change a register.
@@ -1679,7 +1684,7 @@ Notify on change of string or macro.
This is a Heirloom extension and currently ignored.
.Ss \&watchlength
On change, report the contents of macros and strings
-up to the sepcified length.
+up to the specified length.
This is a Heirloom extension and currently ignored.
.Ss \&watchn
Notify on change of register.
@@ -1774,7 +1779,7 @@ minimum (not available in C)
maximum (not available in C)
.El
.Pp
-There is no concept of precendence; evaluation proceeds from left to right,
+There is no concept of precedence; evaluation proceeds from left to right,
except when subexpressions are enclosed in parantheses.
Inside parentheses, whitespace is ignored.
.Sh ESCAPE SEQUENCE REFERENCE
@@ -1834,9 +1839,15 @@ For short names, there are variants
.No \e* Ns Ar c
and
.No \e*( Ns Ar cc .
+.Ss \e,
+Left italic correction (groff extension); ignored by
+.Xr mandoc 1 .
.Ss \e-
Special character
.Dq mathematical minus sign .
+.Ss \e/
+Right italic correction (groff extension); ignored by
+.Xr mandoc 1 .
.Ss \e[ Ns Ar name ]
.Sx Special Characters
with names of arbitrary length, see
@@ -2028,10 +2039,7 @@ Print
with zero width and height; ignored by
.Xr mandoc 1 .
.Ss \ez
-Output the next character without advancing the cursor position;
-approximated in
-.Xr mandoc 1
-by simply skipping the next character.
+Output the next character without advancing the cursor position.
.Sh COMPATIBILITY
The
.Xr mandoc 1
@@ -2088,7 +2096,7 @@ loops are not.
.Pp
The special semantics of the
.Cm nS
-number register is an idiosyncrasy of
+number register is an idiosyncracy of
.Ox
manuals and not supported by other
.Xr mdoc 5
diff --git a/usr/src/man/man5/mdoc.5 b/usr/src/man/man5/mdoc.5
index 5be6dfb4a8..643a269781 100644
--- a/usr/src/man/man5/mdoc.5
+++ b/usr/src/man/man5/mdoc.5
@@ -1,4 +1,4 @@
-.\" $Id: mdoc.7,v 1.252 2015/02/23 13:31:04 schwarze Exp $
+.\" $Id: mdoc.7,v 1.257 2015/11/05 12:06:45 schwarze Exp $
.\"
.\" Copyright (c) 2009, 2010, 2011 Kristaps Dzonsons <kristaps@bsd.lv>
.\" Copyright (c) 2010, 2011, 2013 Ingo Schwarze <schwarze@openbsd.org>
@@ -16,10 +16,10 @@
.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
.\"
.\"
-.\" Copyright 2014 Garrett D'Amore <garrett@dmaore.org>
+.\" Copyright 2014 Garrett D'Amore <garrett@damore.org>
.\" Copyright 2015 Nexenta Systems, Inc. All rights reserved.
.\"
-.Dd Mar 13, 2016
+.Dd $Mdocdate: November 5 2015 $
.Dt MDOC 5
.Os
.Sh NAME
@@ -309,6 +309,11 @@ Print verbose information.
\&.El
.Ed
.Pp
+List the options in alphabetical order,
+uppercase before lowercase for each letter and
+with no regard to whether an option takes an argument.
+Put digits in ascending order before all letter options.
+.Pp
Manuals not documenting a command won't include the above fragment.
.Pp
Since the
@@ -1699,7 +1704,7 @@ See also
A function name.
Its syntax is as follows:
.Bd -ragged -offset indent
-.Pf \. Ns Sx \&Fn
+.Pf . Sx \&Fn
.Op Ar functype
.Ar funcname
.Op Oo Ar argtype Oc Ar argname
@@ -2170,7 +2175,7 @@ It is suggested to leave it unspecified, in which case
.Xr mandoc 1
uses its
.Fl Ios
-argument, or, if that isn't specified either,
+argument or, if that isn't specified either,
.Fa sysname
and
.Fa release
@@ -2232,19 +2237,23 @@ See also
Close parenthesised context opened by
.Sx \&Po .
.Ss \&Pf
-Removes the space between its argument
-.Pq Dq prefix
-and the following macro.
+Removes the space between its argument and the following macro.
Its syntax is as follows:
.Pp
.D1 .Pf Ar prefix macro arguments ...
.Pp
This is equivalent to:
.Pp
-.D1 .No Ar prefix No \&Ns Ar macro arguments ...
+.D1 .No \e& Ns Ar prefix No \&Ns Ar macro arguments ...
+.Pp
+The
+.Ar prefix
+argument is not parsed for macro names or delimiters,
+but used verbatim as if it were escaped.
.Pp
Examples:
.Dl ".Pf $ Ar variable_name"
+.Dl ".Pf . Ar macro_name"
.Dl ".Pf 0x Ar hex_digits"
.Pp
See also
@@ -2344,7 +2353,7 @@ Examples:
\&.%A J. D. Ullman
\&.%B Introduction to Automata Theory, Languages, and Computation
\&.%I Addison-Wesley
-\&.%C Reading, Massachusettes
+\&.%C Reading, Massachusetts
\&.%D 1979
\&.Re
.Ed