What You See Is What You Get
Jerome H. Saltzer, a grad student then, later a
Professor of Electrical Engineering, now retired. Saltzer’s PhD thesis
was the first application for
RUNOFF and is available from the
The same is true for the other main macro
packages that come with
groff: man, mdoc,
ms, mm, and mandoc. This won’t work in general;
for example, to load trace.tmac, either ‘-mtrace’ or
‘-m trace’ must be used.
This section is derived from Writing Papers with nroff using -me by Eric P. Allman.
If you need finer granularity of the vertical
space, use the
pvs request (see Changing Type Sizes).
Note that the use of a ‘.ll
length’ request to initialize the line length, prior to use of the
‘TH’ macro, is supported for backward compatibility with some
versions of the
man program. Always use the
-rLL=length option, or an equivalent ‘.nr LL
length’ request, in preference to such a ‘.ll length’
request. In particular, note that in nroff mode, the request ‘.ll
65n’, (with any length expression that evaluates equal to
65n, i.e., the formatter’s default line length in nroff mode),
does not set the line length to 65n (it is adjusted to the
man macro package’s default setting of 78n), whereas the
use of the -rLL=65n option, or the ‘.nr LL 65n’ request
does establish a line length of 65n.
Actually, only the title is required.
For an explanation what special characters are see Special Characters.
those that specify vertical or horizontal motion or a type size
Note that, for example, ‘!(-1)’ evaluates to
gtroff treats both negative numbers and zero as
troff implementation also allows
tabs for argument separation –
gtroff intentionally doesn’t
The last solution, i.e., using escaped spaces,
is “classical” in the sense that it can be found in most
documents. Nevertheless, it is not optimal in all situations, since
‘\ ’ inserts a fixed-width, non-breaking space character that
gtroff provides a different command
insert a stretchable, non-breaking space.
Unfortunately, this is a lie. But
gtroff hackers will believe it
Soft hyphen character is a misnomer since it is an output glyph.
Tab repetition character is a misnomer since it is an output glyph.
Leader repetition character is a misnomer since it is an output glyph.
that a one-character symbol is not the same as an input character, i.e.,
a is not the same as
\[a]. By default,
groff defines only a single one-character symbol,
is usually accessed as
\-. On the other hand,
the special feature that
\[charXXX] is the same as the
input character with character code XXX. For example,
\[char97] is identical to the letter
a if ASCII
encoding is active.
\C is actually a
misnomer since it accesses an output glyph.
Note that the output glyphs themselves don’t have such
gtroff, a glyph is a numbered box with a given
width, depth, and height, nothing else. All manipulations with the
cflags request work on the input level.
char is a misnomer since an output glyph is
This is usually the parenthesis. Note that in most cases the real dimensions of the glyphs in a font are not related to its type size! For example, the standard POSTSCRIPT font families ‘Times Roman’, ‘Helvetica’, and ‘Courier’ can’t be used together at 10pt; to get acceptable output, the size of ‘Helvetica’ has to be reduced by one point, and the size of ‘Courier’ must be increased by one point.
The created output nodes must be identical. See Gtroff Internals.
The name of this conditional operator is a misnomer since it tests names of output glyphs.
While it is possible to define and call a macro ‘.’ with
.de . . tm foo .. . .. \" This calls macro `.'!
you can’t use this as the end-of-macro macro: during a macro definition, ‘..’ is never handled as a call to ‘.’, even if you say ‘.de foo .’ explicitly.
Margin character is a misnomer since it is an output glyph.
\S, which are processed immediately if
not in copy-in mode.
char is a misnomer since it reports
missing glyphs – there aren’t missing input characters, only invalid
To be completely independent of the current
escape character, use
\(rs, which represents a reverse solidus
The parser and postprocessor for intermediate output can
be found in the file
‘c’ is actually a misnomer since it outputs a glyph.
troff has also abandoned the binary
This keyword is misnamed since it starts a list of ordered glyphs, not characters.
The distinction between
input, characters, and output, glyphs, is not clearly separated in the
groff; for example, the
char request should
glyph since it defines an output entity.