summaryrefslogtreecommitdiff
path: root/share
diff options
context:
space:
mode:
authorIngo Schwarze <schwarze@cvs.openbsd.org>2013-12-15 21:18:01 +0000
committerIngo Schwarze <schwarze@cvs.openbsd.org>2013-12-15 21:18:01 +0000
commitee8f3980ad6c08aa008115495ca99bf641aca115 (patch)
tree9610c80897f4fcf4beefb5b0300c2f91cca8ee85 /share
parent426fcb420507ecdcf179807d7c8ff374460f590a (diff)
The "value" argument to the roff(7) .nr requests ends right before
the first non-digit character. While here, implement and document an optional sign, requesting increment or decrement, as documented in the Ossanna/Kernighan/Ritter troff manual and supported by groff. Reported by bentley@ on discuss at mdocml.
Diffstat (limited to 'share')
-rw-r--r--share/man/man7/roff.715
1 files changed, 9 insertions, 6 deletions
diff --git a/share/man/man7/roff.7 b/share/man/man7/roff.7
index 527a6923961..e8d10a5efb9 100644
--- a/share/man/man7/roff.7
+++ b/share/man/man7/roff.7
@@ -1,4 +1,4 @@
-.\" $OpenBSD: roff.7,v 1.24 2013/10/22 20:37:54 schwarze Exp $
+.\" $OpenBSD: roff.7,v 1.25 2013/12/15 21:18:00 schwarze Exp $
.\"
.\" Copyright (c) 2010, 2011 Kristaps Dzonsons <kristaps@bsd.lv>
.\" Copyright (c) 2010, 2011 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: October 22 2013 $
+.Dd $Mdocdate: December 15 2013 $
.Dt ROFF 7
.Os
.Sh NAME
@@ -840,19 +840,22 @@ the name of the request, macro or string to be undefined.
Currently, it is ignored including its arguments,
and the number of arguments is not checked.
.Ss \&nr
-Define a register.
+Define or change a register.
A register is an arbitrary string value that defines some sort of state,
which influences parsing and/or formatting.
Its syntax is as follows:
.Pp
-.D1 Pf \. Cm \&nr Ar name Ar value
+.D1 Pf \. Cm \&nr Ar name Oo +|- Oc Ns Ar value
.Pp
The
.Ar value
may, at the moment, only be an integer.
-So far, only the following register
+If it is prefixed by a sign, the register will be
+incremented or decremented instead of assigned to.
+.Pp
+The following register
.Ar name
-is recognised:
+is handled specially:
.Bl -tag -width Ds
.It Cm nS
If set to a positive integer value, certain