[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[groff] 02/13: [docs]: Fix content, style, markup nits.
From: |
G. Branden Robinson |
Subject: |
[groff] 02/13: [docs]: Fix content, style, markup nits. |
Date: |
Sat, 16 Apr 2022 04:37:31 -0400 (EDT) |
gbranden pushed a commit to branch master
in repository groff.
commit 6ca0c14a6cd83769f091685b8ff0f75b13620206
Author: G. Branden Robinson <g.branden.robinson@gmail.com>
AuthorDate: Wed Apr 13 12:39:49 2022 +1000
[docs]: Fix content, style, markup nits.
Content:
* [groff.texi]: Fix missing word.
Style:
* [groff(7)]: Say "GNU troff" when presenting a GNU extension, since the
formatter might be installed as "troff".
* Drop tautological "current" modifier from "drawing position".
* Tighten wording.
Markup:
* Add Texinfo/man synchrony comment brackets.
* [groff(7)]: Break and `ne`ed _before_ calling paragraph macro, for
consistency with existing dead-tree typography practice.
---
doc/groff.texi | 28 ++++++++++++++++------------
man/groff.7.man | 42 +++++++++++++++---------------------------
2 files changed, 31 insertions(+), 39 deletions(-)
diff --git a/doc/groff.texi b/doc/groff.texi
index 427aee3e..9bcefef8 100644
--- a/doc/groff.texi
+++ b/doc/groff.texi
@@ -5873,9 +5873,9 @@ Looks like we'll end up paying \n[salaries] salaries.
Comparison operators comprise @code{<} (less than), @code{>} (greater
than), @code{<=} (less than or equal), @code{>=} (greater than or
equal), and @code{=} (equal). @code{==} is a synonym for @code{=}.
-When evaluated, a comparison operation is replaced with @samp{0} if it
-is false and @samp{1} if true. In the @code{roff} language, positive
-values are true, others false.
+When evaluated, a comparison is replaced with @samp{0} if it is false
+and @samp{1} if true. In the @code{roff} language, positive values are
+true, others false.
@cindex logical operators
@cindex operators, logical
@@ -5904,11 +5904,11 @@ within @code{if}, @code{ie}, and @code{while} requests.
Furthermore,
@code{!} is recognized only at the beginning of a numeric expression not
contained by another numeric expression. In other words, it must be the
``outermost'' operator. Attempting to include it elsewhere in the
-expression results in a warning diagnostic in the @samp{number} category
+expression produces a warning in the @samp{number} category
(@pxref{Debugging}), and its expression evaluates false. This
unfortunate limitation maintains compatibility with @acronym{AT&T}
-@code{troff}. You can around it by comparing numeric expressions to the
-canonical truth values @samp{0} and @samp{1}.
+@code{troff}. You can work around it by comparing numeric expressions
+to the canonical truth values @samp{0} and @samp{1}.
@Example
.nr X 1
@@ -5949,8 +5949,8 @@ X=\n[X] Y=\n[Y] Z=\n[Z]
For many requests and escape sequences that cause motion on the page,
the unary operators @code{+} and @code{-} work differently when leading
a numeric expression. They then indicate a motion relative to the
-current drawing position:@: positive is down in vertical contexts, right
-in horizontal ones.
+drawing position:@: positive is down in vertical contexts, right in
+horizontal ones.
@cindex @code{bp} request, using @code{+} and@tie{}@code{-} with
@cindex @code{in} request, using @code{+} and@tie{}@code{-} with
@@ -6025,10 +6025,10 @@ the beginning of an input line;@footnote{Control
structure syntax
creates an exception to this rule, but is designed to remain useful:
recalling our example, @samp{.if 1 .Underline this} would underline only
``this'', precisely. @xref{Conditionals and Loops}.} if the @code{|}
-operator were omitted, then the underline would be drawn a zero distance
-from the current position, producing device-dependent, and likely
-undesirable, results. On the @samp{ps} output device, it underlines the
-period.
+operator were omitted, then the underline would be drawn at zero
+distance from the current position, producing device-dependent, and
+likely undesirable, results. On the @samp{ps} output device, it
+underlines the period.
For vertical movements, the @code{|} operator specifies a distance from
the first text baseline on the page or in the current diversion, using
@@ -12165,6 +12165,8 @@ in the branches or bodies of these structures is
unusual.
@c ---------------------------------------------------------------------
+@c BEGIN Keep (roughly) parallel with subsection "Conditional
+@c expressions" of groff(7).
@node Operators in Conditionals, if-then, Conditionals and Loops, Conditionals
and Loops
@subsection Operators in Conditionals
@@ -12327,6 +12329,8 @@ true.@footnote{This bizarre behavior maintains
compatibility with
The unexpected @samp{r x} in the output is a clue that our conditional
was not interpreted as we planned, but matters may not always be so
obvious.
+@c END Keep (roughly) parallel with subsection "Conditional expressions"
+@c of groff(7).
@c ---------------------------------------------------------------------
diff --git a/man/groff.7.man b/man/groff.7.man
index bf1ac887..9cb417c6 100644
--- a/man/groff.7.man
+++ b/man/groff.7.man
@@ -896,7 +896,8 @@ then
.
.
.P
-.IR @g@troff 's
+GNU
+.IR troff 's \" GNU
scaling operator
.BI ( c ; e )
evaluates a numeric
@@ -910,9 +911,8 @@ is omitted,
scaling units are ignored in the evaluation
.RI of\~ e .
.
-.
-.P
-.I @g@troff
+GNU
+.I troff \" GNU
also provides a pair of operators to compute the extrema of two
operands:
.B >?\&
@@ -941,7 +941,7 @@ is a synonym for
.BR = .
.
When evaluated,
-a comparison operation is replaced with
+a comparison is replaced with
.RB \[lq] 0 \[rq]
if it is false and
.RB \[lq] 1 \[rq]
@@ -982,8 +982,8 @@ contained by another numeric expression.
In other words,
it must be the \[lq]outermost\[rq] operator.
.
-Attempting to include it elsewhere in the expression results in a
-warning diagnostic in the \[lq]number\[rq] category
+Attempting to include it elsewhere in the expression produces a warning
+in the \[lq]number\[rq] category
(see
.MR @g@troff @MAN1EXT@ ),
and its expression evaluates false.
@@ -1017,7 +1017,7 @@ and
.B \-
work differently when leading a numeric expression.
.
-They then indicate a motion relative to the current drawing position:
+They then indicate a motion relative to the drawing position:
positive is down in vertical contexts,
right in horizontal ones.
.
@@ -1196,36 +1196,24 @@ request must be the last such escape sequence on an
input line.
.SS "Conditional expressions"
.\" ====================================================================
.
+.\" BEGIN Keep (roughly) parallel with groff.texi node "Operators in
+.\" Conditionals".
The
.request .if ,
.request .ie ,
and
.request .while
-requests can test the truth values of numerical expressions.
+requests test the truth values of numeric expressions.
.
They also support several additional Boolean operators;
the members of this expanded class are termed
-.IR "conditional expressions" .
-.
-.
-.P
-A numerical expression
-.I expr
-is true if its value is positive.
-.
-In
-.I roff
-languages,
-negative values are false.
-.
-The truth values of other conditional expression operators are as shown
-below.
+.IR "conditional expressions" ;
+their truth values are as shown below.
.
.
-.\" BEGIN Keep (roughly) parallel with groff.texi node "Operators in
-.\" Conditionals".
-.P
+.br
.ne 14v
+.P
.TS
rf(BI) lB
rB lx.
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [groff] 02/13: [docs]: Fix content, style, markup nits.,
G. Branden Robinson <=