summaryrefslogtreecommitdiff
path: root/man
diff options
context:
space:
mode:
authorwlemb <wlemb>2002-05-11 07:20:03 +0000
committerwlemb <wlemb>2002-05-11 07:20:03 +0000
commit93144cf203cf3eb2bd572648c039b9149c1aebe4 (patch)
treeba7f77af5d3931fe40175220f00846dab921762b /man
parentbbf2e3c1ebf9ee6a8a0bde2aa812f29fe0f3029e (diff)
downloadgroff-93144cf203cf3eb2bd572648c039b9149c1aebe4.tar.gz
Adding `warnscale' and `spreadwarn' requests, based on a patch from
Jeffrey Friedl <jfriedl@yahoo.com>. * src/roff/troff/input.cc (spread_limit, warn_scale, warn_scaling_indicator): New global variables. (warnscale_request, spreadwarn_requests): New functions. (main): Initialize `warn_scale' and `warn_scaling_indicator'. (init_input_requests): Updated. (error_type): Add `OUTPUT_WARNING'. (do_error): Handle it. (output_warning): New warning function which shows output location. * src/roff/troff/env.h (spread_limit): New external variable. * src/roff/troff/env.cc (environment::choose_breakpoint): Use `output_warning'. (distribute_space): Emit warning if added space is larger than `spread_limit'. (environment::possibly_break_line): Emit warning if a line can't be adjusted on both sides. * doc/groff.texinfo, man/groff_diff.man, man/groff.man: Document it.
Diffstat (limited to 'man')
-rw-r--r--man/groff.man49
-rw-r--r--man/groff_diff.man50
2 files changed, 80 insertions, 19 deletions
diff --git a/man/groff.man b/man/groff.man
index 133a39c4..bfa0420e 100644
--- a/man/groff.man
+++ b/man/groff.man
@@ -2,7 +2,7 @@
.ig
groff.man
-Last update: 21 Apr 2002
+Last update: 11 May 2002
This file is part of groff, the GNU roff type-setting system.
@@ -746,21 +746,21 @@ There is a sophisticated interface for handling tab positions.
A
.B numerical value
is a signed or unsigned integer or float with or without an appended
-scale indicator.
+scaling indicator.
.
A
-.B scale indicator
+.B scaling indicator
is a one-character abbreviation for a unit of measurement.
.
-A number followed by a scale indicator signifies a size value.
+A number followed by a scaling indicator signifies a size value.
.
-By default, numerical values do not have a scale indicator, i.e., they
+By default, numerical values do not have a scaling indicator, i.e., they
are normal numbers.
.
.P
The
.I roff
-language defines the following scale indicators.
+language defines the following scaling indicators.
.
.
.P
@@ -1385,7 +1385,7 @@ or
.BR grey .
.I component
can be single components specified as fractions in the range 0 to 1
-(default scale indicator\~\c
+(default scaling indicator\~\c
.scaleindicator f ),
as a string of two-digit hexadecimal color components with a leading
.BR # ,
@@ -1436,7 +1436,7 @@ but with compatibility mode switched off during string expansion.
.REQ .dt N trap
Set diversion trap to position
.I N
-(default scale indicator\~\c
+(default scaling indicator\~\c
.scaleindicator v ).
.
.REQ .ec
@@ -1610,7 +1610,7 @@ Switch to hyphenation mode
.REQ .hym n
Set the hyphenation margin to
.I n
-(default scale indicator\~\c
+(default scaling indicator\~\c
.scaleindicator m ).
.
.REQ .hys n
@@ -1647,7 +1647,7 @@ Change to previous indent value.
.REQ .in \[+-]N
Change indent according to
.I \[+-]N
-(default scale indicator\~\c
+(default scaling indicator\~\c
.scaleindicator m ).
.
.REQ .it N trap
@@ -1710,7 +1710,7 @@ Set line length according to
.I \[+-]N
(default size
.scalednumber 6.5 i ,
-default scale indicator\~\c
+default scaling indicator\~\c
.scaleindicator m ).
.
.REQ .ls
@@ -1724,7 +1724,7 @@ i.e.,
blank lines are inserted after each text output line.
.
.REQ .lt \[+-]N
-Length of title (default scale indicator\~\c
+Length of title (default scaling indicator\~\c
.scaleindicator m ).
.
.REQ .mc
@@ -1740,7 +1740,7 @@ Set margin character to
.I c
and distance to
.I N
-from right margin (default scale indicator\~\c
+from right margin (default scaling indicator\~\c
.scaleindicator m ).
.
.REQ .mk register
@@ -1761,7 +1761,7 @@ Need a one-line vertical space.
.REQ .ne N
Need
.I N
-vertical space (default scale indicator\~\c
+vertical space (default scaling indicator\~\c
.scaleindicator v ).
.
.REQ .nf
@@ -1850,7 +1850,7 @@ The current page length is stored in
.REQ .pl \[+-]N
Change page length to
.I \[+-]N
-(default scale indicator\~\c
+(default scaling indicator\~\c
.scaleindicator v ).
.
.REQ .pm
@@ -1903,7 +1903,7 @@ Change to previous post-vertical line spacing.
.REQ .pvs \[+-]N
Change post-vertical line spacing according to
.I \[+-]N
-(default scale indicator\~\c
+(default scaling indicator\~\c
.scaleindicator p ).
.
.REQ .rchar c1 c2 .\|.\|.\&
@@ -1949,7 +1949,7 @@ Restore spacing; turn no-space mode off.
.REQ .rt \[+-]N
Return
.I (upward only)
-to marked vertical place (default scale indicator\~\c
+to marked vertical place (default scaling indicator\~\c
.scaleindicator v ).
.
.REQ .shc
@@ -1993,6 +1993,15 @@ Fonts
etc.\& are special and will be searched for characters not in the
current font.
.
+.REQ .spreadwarn
+Toggle the spread warning on and off without changing its value.
+.
+.REQ .spreadwarn limit
+Emit a warning if each space in an output line is widened by
+.I limit
+or more (default scaling indicator\~\c
+.scaleindicator m ).
+.
.REQ .ss N
Space-character size set to
.IR N /12
@@ -2162,7 +2171,7 @@ Change to previous vertical base line spacing.
.REQ .vs \[+-]N
Set vertical base line spacing according to
.I \[+-]N
-(default scale indicator\~\c
+(default scaling indicator\~\c
.scaleindicator p ).
Default value is
.scalednumber 12 p .
@@ -2171,6 +2180,10 @@ Default value is
Set warnings code to
.IR n .
.
+.REQ .warnscale si
+Set scaling indicator used in warnings to
+.IR si .
+.
.REQ .wh N
Remove (first) trap at position
.IR N .
diff --git a/man/groff_diff.man b/man/groff_diff.man
index ca8168e2..c1e22e2f 100644
--- a/man/groff_diff.man
+++ b/man/groff_diff.man
@@ -3,7 +3,7 @@
.ig
groff_diff.man
-Last update : 15 Apr 2002
+Last update : 11 May 2002
This file is part of groff, the GNU roff type-setting system.
It is the source of the man-page groff_diff(7).
@@ -1913,6 +1913,36 @@ are special and will be searched for characters not in the current
font.
.
.TP
+.BI .spreadwarn\ limit
+Make
+.B troff
+emit a warning if the additional space inserted for each space between
+words in an output line is larger or equal to
+.IR limit .
+.
+A negative value is changed to zero; no argument toggles the warning on
+and off without changing
+.IR limit .
+.
+The default scaling indicator is\~\c
+.BR m .
+.
+At startup,
+.B spreadwarn
+is deactivated, and
+.I limit
+is set to 3m.
+.
+For example,
+.B .spreadwarn\ 0.2m
+will cause a warning if
+.B troff
+must add 0.2m or more for each interword space in a line.
+.
+This request is active only if text is justified to both margins (using
+.BR .ad\ b ).
+.
+.TP
.BI .sty\ n\ f
Associate style\~\c
.I f
@@ -2208,6 +2238,24 @@ If
is not given, all warnings will be enabled.
.
.TP
+.BI .warnscale\ si
+Set the scaling indicator used in warnings to
+.IR si .
+.
+Valid values for
+.I si
+are
+.BR u ,
+.BR i ,
+.BR c ,
+.BR p ,
+and
+.BR P .
+.
+At startup, it is set to\~\c
+.BR i .
+.
+.TP
.BI .while \ c\ anything
While condition\~\c
.I c