File: groff.info, Node: Simple Commands, Next: Graphics Commands, Prev: Comment Command, Up: Command Reference
6.1.2.2 Simple Commands
.......................
The commands in this subsection have a command code consisting of a
single character, taking a fixed number of arguments. Most of them are
commands for positioning and text writing. These commands are tolerant
of whitespace. Optionally, syntactical space can be inserted before,
after, and between the command letter and its arguments. All of these
commands are stackable; i.e., they can be preceded by other simple
commands or followed by arbitrary other commands on the same line. A
separating syntactical space is necessary only when two integer
arguments would clash or if the preceding argument ends with a string
argument.
'C ID'
Typeset the glyph of the special character ID. Trailing
syntactical space is necessary to allow special character names of
arbitrary length. The drawing position is not advanced.
'c G'
Typeset the glyph of the ordinary character C. The drawing
position is not advanced.
'f N'
Select the font mounted at position N. N cannot be negative.
'H N'
Horizontally move the drawing position to N basic units from the
left edge of the page. N cannot be negative.
'h N'
Move the drawing position right N basic units. AT&T 'troff'
allowed negative N; GNU 'troff' does not produce such values, but
'groff''s output driver library handles them.
'm COLOR-SCHEME [COMPONENT ...]'
Select the stroke color using the COMPONENTs in the color space
SCHEME. Each COMPONENT is an integer between 0 and 65535. The
quantity of components and their meanings vary with each SCHEME.
This command is a 'groff' extension.
'mc CYAN MAGENTA YELLOW'
Use the CMY color scheme with components cyan, magenta, and
yellow.
'md'
Use the default color (no components; black in most cases).
'mg GRAY'
Use a grayscale color scheme with a component ranging between
0 (black) and 65535 (white).
'mk CYAN MAGENTA YELLOW BLACK'
Use the CMYK color scheme with components cyan, magenta,
yellow, and black.
'mr RED GREEN BLUE'
Use the RGB color scheme with components red, green, and blue.
'N N'
Typeset the glyph with index N in the current font. N is normally
a non-negative integer. The drawing position is not advanced. The
'html' and 'xhtml' devices use this command with negative N to
produce unbreakable space; the absolute value of N is taken and
interpreted in basic units.
'n B A'
Indicate a break. No action is performed; the command is present
to make the output more easily parsed. The integers B and A
describe the vertical space amounts before and after the break,
respectively. GNU 'troff' issues this command but 'groff''s output
driver library ignores it. See 'v' and 'V' below.
'p N'
Begin a new page, setting its number to N. Each page is
independent, even from those using the same number. The vertical
drawing position is set to 0. All positioning, writing, and
drawing commands are interpreted in the context of a page, so a
'p' command must precede them.
's N'
Set type size to N scaled points (unit 'z' in GNU 'troff'. AT&T
'troff' used unscaled points 'p' instead; see *note Output Language
Compatibility::.
't XYZ'
't XYZ DUMMY-ARG'
Typeset a word XYZ; that is, set a sequence of ordinary glyphs
named X, Y, Z, ..., terminated by a space character or a line
break; an optional second integer argument is ignored (this allows
the formatter to generate an even number of arguments). Each glyph
is set at the current drawing position, and the position is then
advanced horizontally by the glyph's width. A glyph's width is
read from its metrics in the font description file, scaled to the
current type size, and rounded to a multiple of the horizontal
motion quantum. Use the 'C' command to emplace glyphs of special
characters. The 't' command is a 'groff' extension and is output
only for devices whose 'DESC' file contains the 'tcommand'
directive; see *note DESC File Format::.
'u N XYZ'
Typeset word XYZ with track kerning. As 't', but after placing
each glyph, the drawing position is further advanced horizontally
by N basic units ('u'). The 'u' command is a 'groff' extension and
is output only for devices whose 'DESC' file contains the
'tcommand' directive; see *note DESC File Format::.
'V N'
Vertically move the drawing position to N basic units from the top
edge of the page. N cannot be negative.
'v N'
Move the drawing position down N basic units. AT&T 'troff' allowed
negative N; GNU 'troff' does not produce such values, but 'groff''s
output driver library handles them.
'w'
Indicate an inter-word space. No action is performed; the command
is present to make the output more easily parsed. Only adjustable,
breakable inter-word spaces are thus described; those resulting
from '\~' or horizontal motion escape sequences are not. GNU
'troff' issues this command but 'groff''s output driver library
ignores it. See 'h' and 'H' above.