Note that single characters can have the eighth bit set, as can the names of fonts and special characters. The names of characters and fonts can be of arbitrary length. A character that is to be printed will always be in the current font.
A string argument is always terminated by the next whitespace character (space, tab, or newline); an embedded # character is regarded as part of the argument, not as the beginning of a comment command. An integer argument is already terminated by the next non-digit character, which then is regarded as the first character of the next argument or command.
A comment. Ignore any characters from the #~ character up to the next newline character.
This command is the only possibility for commenting in the intermediate output. Each comment can be preceded by arbitrary syntacticalspace; every command can be terminated by a comment.
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 smart about 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 only necessary when two integer arguments would clash or if the preceding argument ends with a string argument. *..rm@arg1.rm@arg2.rm@index1.rm@index2...cformat:.command<name><arguments><punctuation>.decommand.ds@arg1 2 .shift 2 .IP B]@arg1]]I]@arg2]] Open a new environment by copying the actual device configuration data to the environment stack. The current environment is setup by the device specification and manipulated by the setting commands. *..rm@arg1.rm@arg2.rm@index1.rm@index2...cformat:.command<name><arguments><punctuation>.decommand.ds@arg1 2 .shift 2 .IP B]@arg1]]I]@arg2]] Close the actual environment (opened by a preceding {~command) and restore the previous environment from the environment stack as the actual device configuration data. *..rm@arg1.rm@arg2.rm@index1.rm@index2...cformat:.command<name><arguments><punctuation>.decommand.ds@arg1 2 .shift 2 .IP B]@arg1]]I]@arg2]] Print a special groff character named ]==0).return.IR The trailing syntactical space or line break is necessary to allow character names of arbitrary length. The character is printed at the current print position; the characters size is read from the font file. The print position is not changed. *..rm@arg1.rm@arg2.rm@index1.rm@index2...cformat:.command<name><arguments><punctuation>.decommand.ds@arg1 2 .shift 2 .IP B]@arg1]]I]@arg2]] Print character~ ]==0).return.IR at the current print position; the characters size is read from the font file. The print position is not changed. *..rm@arg1.rm@arg2.rm@index1.rm@index2...cformat:.command<name><arguments><punctuation>.decommand.ds@arg1 2 .shift 2 .IP B]@arg1]]I]@arg2]] Set font to font number~ ]==0).return.IR (a non-negative integer). *..rm@arg1.rm@arg2.rm@index1.rm@index2...cformat:.command<name><arguments><punctuation>.decommand.ds@arg1 2 .shift 2 .IP B]@arg1]]I]@arg2]] Move right to the absolute vertical position~ ]==0).return.IR (a non-negative integer in basic units~ *] .. .ec .Endofmacrodefinitions..c-----------------Semanticaldefinitions..nr@maxcolor65536.ds@backslash[rs] .ds @linebreak R][la]line_break[ra]].. relative to left edge of current page. *..rm@arg1.rm@arg2.rm@index1.rm@index2...cformat:.command<name><arguments><punctuation>.decommand.ds@arg1 2 .shift 2 .IP B]@arg1]]I]@arg2]] Move ]==0).return.IR (a non-negative integer) basic units~ *] .. .ec .Endofmacrodefinitions..c-----------------Semanticaldefinitions..nr@maxcolor65536.ds@backslash[rs] .ds @linebreak R][la]line_break[ra]].. horizontally to the right. [54] allows negative values for n also, but groff doesnt use this. *..rm@arg1.rm@arg2.rm@index1.rm@index2...cformat:.command<name><arguments><punctuation>.decommand.ds@arg1 2 .shift 2 .IP B]@arg1]]I]@arg2]] Set the color for text (glyphs), line drawing, and the outline of graphic objects using different color schemes; the analoguous command for the filling color of graphic objects is DF. The color components are specified as integer arguments between 0 and 0@maxcolor]. The number of color components and their meaning vary for the different color schemes. These commands are generated by the groff escape sequence @backslash]m. No position changing. These commands are a groff extension. *..rm@arg1.rm@arg2.rm@index1.rm@index2...cformat:.command<name><arguments><punctuation>.decommand.ds@arg1 2 .shift 2 .IP B]@arg1]]I]@arg2]] Set color using the CMY color scheme, having the 3~color components cyan, magenta, and yellow. *..rm@arg1.rm@arg2.rm@index1.rm@index2...cformat:.command<name><arguments><punctuation>.decommand.ds@arg1 2 .shift 2 .IP B]@arg1]]I]@arg2]] Set color to the default color value (black in most cases). No component arguments. *..rm@arg1.rm@arg2.rm@index1.rm@index2...cformat:.command<name><arguments><punctuation>.decommand.ds@arg1 2 .shift 2 .IP B]@arg1]]I]@arg2]] Set color to the shade of gray given by the argument, an integer between 0 (black) and 0@maxcolor] (white). *..rm@arg1.rm@arg2.rm@index1.rm@index2...cformat:.command<name><arguments><punctuation>.decommand.ds@arg1 2 .shift 2 .IP B]@arg1]]I]@arg2]] Set color using the CMYK color scheme, having the 4~color components cyan, magenta, yellow, and black. *..rm@arg1.rm@arg2.rm@index1.rm@index2...cformat:.command<name><arguments><punctuation>.decommand.ds@arg1 2 .shift 2 .IP B]@arg1]]I]@arg2]] Set color using the RGB color scheme, having the 3~color components red, green, and blue. *..rm@arg1.rm@arg2.rm@index1.rm@index2...cformat:.command<name><arguments><punctuation>.decommand.ds@arg1 2 .shift 2 .IP B]@arg1]]I]@arg2]] Print character with index~ ]==0).return.IR (an integer, normally non-negative) of the current font. The print position is not changed. If -T~html is used, negative values are emitted also to indicate an unbreakable space with given width. For example, N~-193 represents an unbreakable space which has a width of 193u. This command is a groff extension. *..rm@arg1.rm@arg2.rm@index1.rm@index2...cformat:.command<name><arguments><punctuation>.decommand.ds@arg1 2 .shift 2 .IP B]@arg1]]I]@arg2]] Inform the device about a line break, but no positioning is done by this command. In classical troff, the integer arguments ]==0).return.IR and~ ]==0).return.IR informed about the space before and after the current line to make the intermediate output more human readable without performing any action. In groff, they are just ignored, but they must be provided for compatibility reasons. *..rm@arg1.rm@arg2.rm@index1.rm@index2...cformat:.command<name><arguments><punctuation>.decommand.ds@arg1 2 .shift 2 .IP B]@arg1]]I]@arg2]] Begin a new page in the outprint. The page number is set to~ ]==0).return.IR This page is completely independent of pages formerly processed even if those have the same page number. The vertical position on the outprint is automatically set to~0. All positioning, writing, and drawing is always done relative to a page, so a p~command must be issued before any of these commands. *..rm@arg1.rm@arg2.rm@index1.rm@index2...cformat:.command<name><arguments><punctuation>.decommand.ds@arg1 2 .shift 2 .IP B]@arg1]]I]@arg2]] Set point size to ]==0).return.IR scaled points (this is unit~ *] .. .ec .Endofmacrodefinitions..c-----------------Semanticaldefinitions..nr@maxcolor65536.ds@backslash[rs] .ds @linebreak R][la]line_break[ra]].. in GNU troff). Classical troff used the unit points ( *] .. .ec .Endofmacrodefinitions..c-----------------Semanticaldefinitions..nr@maxcolor65536.ds@backslash[rs] .ds @linebreak R][la]line_break[ra]].. instead; see section COMPATIBILITY. *..rm@arg1.rm@arg2.rm@index1.rm@index2...cformat:.command<name><arguments><punctuation>.decommand.ds@arg1 2 .shift 2 .IP B]@arg1]]I]@arg2]] 1 *...cfollow-uplinefora.TPheader.deTP+.br.ns.TP Print a word, i.e. a sequence of characters ]==0).return.IR 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). The first character should be printed at the current position, the current horizontal position should then be increased by the width of the first character, and so on for each character. The widths of the characters are read from the font file, scaled for the current point size, and rounded to a multiple of the horizontal resolution. Special characters cannot be printed using this command (use the C command for named characters). This command is a groff extension; it is only used for devices whose DESC file contains the tcommand keyword; see groff_font(5). *..rm@arg1.rm@arg2.rm@index1.rm@index2...cformat:.command<name><arguments><punctuation>.decommand.ds@arg1 2 .shift 2 .IP B]@arg1]]I]@arg2]] Print word with track kerning. This is the same as the t command except that after printing each character, the current horizontal position is increased by the sum of the width of that character and~ ]==0).return.IR (an integer in basic units~ *] .. .ec .Endofmacrodefinitions..c-----------------Semanticaldefinitions..nr@maxcolor65536.ds@backslash[rs] .ds @linebreak R][la]line_break[ra]].. This command is a groff extension; it is only used for devices whose DESC file contains the tcommand keyword; see groff_font(5). *..rm@arg1.rm@arg2.rm@index1.rm@index2...cformat:.command<name><arguments><punctuation>.decommand.ds@arg1 2 .shift 2 .IP B]@arg1]]I]@arg2]] Move down to the absolute vertical position~ ]==0).return.IR (a non-negative integer in basic units~ *] .. .ec .Endofmacrodefinitions..c-----------------Semanticaldefinitions..nr@maxcolor65536.ds@backslash[rs] .ds @linebreak R][la]line_break[ra]].. relative to upper edge of current page. *..rm@arg1.rm@arg2.rm@index1.rm@index2...cformat:.command<name><arguments><punctuation>.decommand.ds@arg1 2 .shift 2 .IP B]@arg1]]I]@arg2]] Move ]==0).return.IR basic units~ *] .. .ec .Endofmacrodefinitions..c-----------------Semanticaldefinitions..nr@maxcolor65536.ds@backslash[rs] .ds @linebreak R][la]line_break[ra]].. down (n is a non-negative integer). [54] allows negative values for n also, but groff doesnt use this. *..rm@arg1.rm@arg2.rm@index1.rm@index2...cformat:.command<name><arguments><punctuation>.decommand.ds@arg1 2 .shift 2 .IP B]@arg1]]I]@arg2]] Informs about a paddable whitespace to increase readability. The spacing itself must be performed explicitly by a move command.
Unless indicated otherwise, each graphics command directly corresponds to a similar groff@backslash]D escape sequence; see groff(7).
Unknown D~commands are assumed to be device-specific. Its arguments are parsed as strings; the whole information is then sent to the postprocessor.
In the following command reference, the syntax element [la]line_break[ra] means a syntactical line break as defined in section Separation. .el .ds @args I]h1~v1 h2~v2].IPB]Da] @args]@linebreak].rm@args...cgraphicscommand.Dwithavariablenumberofarguments.cformat:.D-multiarg<subcommand>.deD-multiarg.ds@sub
-->
"B]D@sub]] @args]@linebreak]"
Draw B-spline from current position to offset *.rm@arg1.rm@arg2...deindexed_offset.if(0.] < 4) 1 3 *..el.nop@arg2] sub @index2]) then to offset *.rm@arg1.rm@arg2...deindexed_offset.if(0.] < 4) 1 3 *..el.nop@arg2] sub @index2]) if given, etc. up to *.rm@arg1.rm@arg2...deindexed_offset.if(0.] < 4) 1 3 *..el.nop@arg2] sub @index2]) This command takes a variable number of argument pairs; the current position is moved to the terminal point of the drawn curve. *]@linebreak]".rm@sub...deDa-command.shift1.iet.ds@argsh sub 1 v sub 1h sub 2 v sub 2
"B]Da] @args]@linebreak]"
Draw arc from current position to *.rm@arg1.rm@arg2...deindexed_offset.if(0.] < 4) 1 3 *..el.nop@arg2] sub @index2]) *.rm@arg1.rm@arg2...deindexed_offset.if(0.] < 4) 1 3 *..el.nop@arg2] sub @index2]) with center at *.rm@arg1.rm@arg2...deindexed_offset.if(0.] < 4) 1 3 *..el.nop@arg2] sub @index2]) then move the current position to the final point of the arc. * .rm @arg1 .rm @arg2 .. .c format: .D-command <subcommand> <arguments>".deD-command.ds@sub
"B]D@sub]] I]/]@linebreak]"
*]@linebreak] .rm @sub .. .c format: .D-command+ <subcommand> <arguments>".ccontinueprevious.D-commandheading.deD-command+.ds@sub *...cfollow-uplinefora.TPheader.deTP+.br.ns.TP Draw a solid circle using the current fill color with diameter~ ]==0).return.IR (integer in basic units~ *] .. .ec .Endofmacrodefinitions..c-----------------Semanticaldefinitions..nr@maxcolor65536.ds@backslash[rs] .ds @linebreak R][la]line_break[ra]].. with leftmost point at the current position; then move the current position to the rightmost point of the circle. An optional second integer argument is ignored (this allows to the formatter to generate an even number of arguments). This command is a groff extension. * .rm @arg1 .rm @arg2 .. .c format: .D-command <subcommand> <arguments>".deD-command.ds@sub
"B]D@sub]] I]/]@linebreak]"
Draw circle line with diameter~ ]==0).return.IR (integer in basic units~ *] .. .ec .Endofmacrodefinitions..c-----------------Semanticaldefinitions..nr@maxcolor65536.ds@backslash[rs] .ds @linebreak R][la]line_break[ra]].. with leftmost point at the current position; then move the current position to the rightmost point of the circle. * .rm @arg1 .rm @arg2 .. .c format: .D-command <subcommand> <arguments>".deD-command.ds@sub
"B]D@sub]] I]/]@linebreak]"
Draw a solid ellipse in the current fill color with a horizontal diameter of~ ]==0).return.IR and a vertical diameter of~ ]==0).return.IR (both integers in basic units~ *] .. .ec .Endofmacrodefinitions..c-----------------Semanticaldefinitions..nr@maxcolor65536.ds@backslash[rs] .ds @linebreak R][la]line_break[ra]].. with the leftmost point at the current position; then move to the rightmost point of the ellipse. This command is a groff extension. * .rm @arg1 .rm @arg2 .. .c format: .D-command <subcommand> <arguments>".deD-command.ds@sub
"B]D@sub]] I]/]@linebreak]"
Draw an outlined ellipse with a horizontal diameter of~ ]==0).return.IR and a vertical diameter of~ ]==0).return.IR (both integers in basic units~ *] .. .ec .Endofmacrodefinitions..c-----------------Semanticaldefinitions..nr@maxcolor65536.ds@backslash[rs] .ds @linebreak R][la]line_break[ra]].. with the leftmost point at current position; then move to the rightmost point of the ellipse. * .rm @arg1 .rm @arg2 .. .c format: .D-command <subcommand> <arguments>".deD-command.ds@sub
"B]D@sub]] I]/]@linebreak]"
Set fill color for solid drawing objects using different color schemes; the analoguous command for setting the color of text, line graphics, and the outline of graphic objects is m. The color components are specified as integer arguments between 0 and 0@maxcolor]. The number of color components and their meaning vary for the different color schemes. These commands are generated by the groff escape sequences @backslash]DF ... and @backslash]M (with no other corresponding graphics commands). No position changing. This command is a groff extension. * .rm @arg1 .rm @arg2 .. .c format: .D-command <subcommand> <arguments>".deD-command.ds@sub
-->
"B]D@sub]] I]/]@linebreak]"
Set fill color for solid drawing objects using the CMY color scheme, having the 3~color components cyan, magenta, and yellow. * .rm @arg1 .rm @arg2 .. .c format: .D-command <subcommand> <arguments>".deD-command.ds@sub
"B]D@sub]] I]/]@linebreak]"
Set fill color for solid drawing objects to the default fill color value (black in most cases). No component arguments. * .rm @arg1 .rm @arg2 .. .c format: .D-command <subcommand> <arguments>".deD-command.ds@sub
"B]D@sub]] I]/]@linebreak]"
Set fill color for solid drawing objects to the shade of gray given by the argument, an integer between 0 (black) and 0@maxcolor] (white). * .rm @arg1 .rm @arg2 .. .c format: .D-command <subcommand> <arguments>".deD-command.ds@sub
"B]D@sub]] I]/]@linebreak]"
Set fill color for solid drawing objects using the CMYK color scheme, having the 4~color components cyan, magenta, yellow, and black. * .rm @arg1 .rm @arg2 .. .c format: .D-command <subcommand> <arguments>".deD-command.ds@sub
"B]D@sub]] I]/]@linebreak]"
Set fill color for solid drawing objects using the RGB color scheme, having the 3~color components red, green, and blue.
The argument ]==0).return.IR must be an integer in the range -32767 to 32767.
-->
"0 [<=] "n" [<=] 1000"
Set the color for filling solid drawing objects to a shade of gray, where 0 corresponds to solid white, 1000 (the default) to solid black, and values in between to intermediate shades of gray; this is obsoleted by command DFg.
n" < 0 or "n" > 1000"
Set the filling color to the color that is currently being used for the text and the outline, see command m. For example, the command sequence
-->
mg 0 0 0@maxcolor] Df -1
sets all colors to blue.
No position changing. This command is a groff extension. * .rm @arg1 .rm @arg2 .. .c format: .D-command <subcommand> <arguments>".deD-command.ds@sub
"B]D@sub]] I]/]@linebreak]"
Draw line from current position to offset .el.IR@arg1]1,.IR@arg1]2,.nop...,.I@arg1]n..rm@arg1...deoffset.if(0.] < 2) 1 (integers in basic units~ *] .. .ec .Endofmacrodefinitions..c-----------------Semanticaldefinitions..nr@maxcolor65536.ds@backslash[rs] .ds @linebreak R][la]line_break[ra]].. then set current position to the end of the drawn line. .el .ds @args I]h1~v1 h2~v2].IPB]Da] @args]@linebreak].rm@args...cgraphicscommand.Dwithavariablenumberofarguments.cformat:.D-multiarg<subcommand>.deD-multiarg.ds@sub
"B]D@sub]] @args]@linebreak]"
Draw a polygon line from current position to offset .el.IR@arg1]1,.IR@arg1]2,.nop...,.I@arg1]n..rm@arg1...deoffset.if(0.] < 2) 1 from there to offset .el.IR@arg1]1,.IR@arg1]2,.nop...,.I@arg1]n..rm@arg1...deoffset.if(0.] < 2) 1 etc. up to offset .el.IR@arg1]1,.IR@arg1]2,.nop...,.I@arg1]n..rm@arg1...deoffset.if(0.] < 2) 1 and from there back to the starting position. For historical reasons, the position is changed by adding the sum of all arguments with odd index to the actual horizontal position and the even ones to the vertical position. Although this doesnt make sense it is kept for compatibility. As the polygon is closed, the end of drawing is the starting point, so the position doesnt change. This command is a groff extension. .el .ds @args I]h1~v1 h2~v2].IPB]Da] @args]@linebreak].rm@args...cgraphicscommand.Dwithavariablenumberofarguments.cformat:.D-multiarg<subcommand>.deD-multiarg.ds@sub
"B]D@sub]] @args]@linebreak]"
The same macro as the corresponding Dp command with the same arguments, but draws a solid polygon in the current fill color rather than an outlined polygon. The position is changed in the same way as with Dp.
No position changing. This command is a groff extension. * .rm @arg1 .rm @arg2 .. .c format: .D-command <subcommand> <arguments>".deD-command.ds@sub
"B]D@sub]] I]/]@linebreak]"
Set the current line thickness to~ ]==0).return.IR (an integer in basic units~ *] .. .ec .Endofmacrodefinitions..c-----------------Semanticaldefinitions..nr@maxcolor65536.ds@backslash[rs] .ds @linebreak R][la]line_break[ra]].. if ]==0).return.IR if ]==0).return.IR select the smallest available line thickness; if ]==0).return.IR set the line thickness proportional to the point size (this is the default before the first Dt command was specified). For historical reasons, the horizontal position is changed by adding the argument to the actual horizontal position, while the vertical position is not changed. Although this doesnt make sense it is kept for compatibility.
No position changing. This command is a groff extension.
*] .IP B]x@sub]]@args]]@linebreak] .rm @sub .rm @args .. .de xsub .RI ( " " control command)" Use ]==0).return.IR as the intended name for the current file in error reports. This is useful for remembering the original file name when groff uses an internal piping mechanism. The input file is not changed by this command. This command is a groff extension. 1
"B]x@sub]]@args]]@linebreak]"
*] .IP B]x@sub]]@args]]@linebreak] .rm @sub .rm @args .. .de xsub .RI ( " " control command)" Mount font position~ ]==0).return.IR (a non-negative integer) with font named~ ]==0).return.IR (a text word), cf. groff_font(5). 1
"B]x@sub]]@args]]@linebreak]"
*] .IP B]x@sub]]@args]]@linebreak] .rm @sub .rm @args .. .de xsub .RI ( " " control command)" Set character height to~ ]==0).return.IR (a positive integer in scaled points~ *] .. .ec .Endofmacrodefinitions..c-----------------Semanticaldefinitions..nr@maxcolor65536.ds@backslash[rs] .ds @linebreak R][la]line_break[ra]].. Classical troff used the unit points ( *] .. .ec .Endofmacrodefinitions..c-----------------Semanticaldefinitions..nr@maxcolor65536.ds@backslash[rs] .ds @linebreak R][la]line_break[ra]].. instead; see section COMPATIBILITY. 1
"B]x@sub]]@args]]@linebreak]"
*] .IP B]x@sub]]@args]]@linebreak] .rm @sub .rm @args .. .de xsub .RI ( " " control command)" Initialize device. This is the third command of the prologue. 1
"B]x@sub]]@args]]@linebreak]"
*] .IP B]x@sub]]@args]]@linebreak] .rm @sub .rm @args .. .de xsub .RI ( " " control command)" Parsed but ignored. The classical documentation reads pause device, can berestarted. 1
"B]x@sub]]@args]]@linebreak]"
*] .IP B]x@sub]]@args]]@linebreak] .rm @sub .rm @args .. .de xsub .RI ( " " control command)" Resolution is~ ]==0).return.IR while ]==0).return.IR is the minimal horizontal motion, and ]==0).return.IR the minimal vertical motion possible with this device; all arguments are positive integers in basic units~ *] .. .ec .Endofmacrodefinitions..c-----------------Semanticaldefinitions..nr@maxcolor65536.ds@backslash[rs] .ds @linebreak R][la]line_break[ra]].. per inch. This is the second command of the prologue. 1
*] .IP B]x@sub]]@args]]@linebreak] .rm @sub .rm @args .. .de xsub .RI ( " " control command)" Terminates the processing of the current file; issued as the last command of any intermediate troff output. 1
"B]x@sub]]@args]]@linebreak]"
*] .IP B]x@sub]]@args]]@linebreak] .rm @sub .rm @args .. .de xsub .RI ( " " control command)" Generate trailer information, if any. In groff, this is actually just ignored. 1
"B]x@sub]]@args]]@linebreak]"
*] .IP B]x@sub]]@args]]@linebreak] .rm @sub .rm @args .. .de xsub .RI ( " " control command)" Set name of device to word ]==0).return.IR a sequence of characters ended by the next whitespace character. The possible device names coincide with those from the groff -T option. This is the first command of the prologue. 1
"B]x@sub]]@args]]@linebreak]"
*] .IP B]x@sub]]@args]]@linebreak] .rm @sub .rm @args .. .de xsub .RI ( " " control command)" Configure underlining of spaces. If ]==0).return.IR is~1, start underlining of spaces; if ]==0).return.IR is~0, stop underlining of spaces. This is needed for the cu request in nroff mode and is ignored otherwise. This command is a groff extension. 1
"B]x@sub]]@args]]@linebreak]"
*] .IP B]x@sub]]@args]]@linebreak] .rm @sub .rm @args .. .de xsub .RI ( " " control command)" Send string ]==0).return.IR uninterpreted to the device. If the line following this command starts with a + character this line is interpreted as a continuation line in the following sense. The + is ignored, but a newline character is sent instead to the device, the rest of the line is sent uninterpreted. The same applies to all following lines until the first character of a line is not a + character. This command is generated by the groff escape sequence @backslash]X. The line-continuing feature is a groff extension.
Move right ]==0).return.IR (exactly two decimal digits) basic units~ *] .. .ec .Endofmacrodefinitions..c-----------------Semanticaldefinitions..nr@maxcolor65536.ds@backslash[rs] .ds @linebreak R][la]line_break[ra]].. then print character~ ]==0).return.IR
In groff, arbitrary syntactical space around and within this command is allowed to be added. Only when a preceding command on the same line ends with an argument of variable length a separating space is obligatory. In classicaltroff, large clusters of these and other commands were used, mostly without spaces; this made such output almost unreadable.
For modern high-resolution devices, this command does not make sense because the width of the characters can become much larger than two decimal digits. In groff, this is only used for the devices X75, X75-12, X100, and X100-12. For other devices, the commands t and~ u provide a better functionality.
x T ps
x res 72000 1 1
x init
p1
x font 5 TR
f5
s10000
V12000
H72000
thell
wh2500
tw
H96620
torld
n12000 0
x trailer
V792000
x stop
This output can be fed into the postprocessor grops(1) to get its representation as a PostScript file.
-->
Low-resolution device
latin1
This is similar to the high-resolution device except that the positioning is done at a minor scale. Some comments (lines starting with #) were added for clarification; they were not generated by the formatter.
"shell>""CB]f[]"
# prologue
x T latin1
x res 240 24 40
x init
# begin a new page
p1
# font setup
x font 1 R
f1
s10
# initial positioning on the page
V40
H0
# write text hell
thell
# inform about a space, and do it by a horizontal jump
wh24
# write text world
tworld
# announce line break, but do nothing because ...
n40 0
# ... the end of the document has been reached
x trailer
V2640
x stop
This output can be fed into the postprocessor grotty(1) to get a formatted text document.
-->
Classical style output
As a computer monitor has a very low resolution compared to modern printers the intermediate output for the X~devices can use the jump-and-write command with its 2-digit displacements.
"shell>""CB]f[]"
x T X100
x res 100 1 1
x init
p1
x font 5 TR
f5
s10
V16
H100
# write text with old-style jump-and-write command
ch07e07l03lw06w11o07r05l03dh7
n16 0
x trailer
V1100
x stop
This output can be fed into the postprocessor xditview(1x) or gxditview(1) for displaying in~X.
Due to the obsolete jump-and-write command, the text clusters in the classical output are almost unreadable.
The classical quasi device independence is not yet implemented.
The old hardware was very different from what we use today.
So the groff devices are also fundamentally different from the ones in classical troff. For example, the classical PostScript device was called post and had a resolution of 720 units per inch, while groffs ps device has a resolution of 72000 units per inch. Maybe, by implementing some rescaling mechanism similar to the classical quasi device independence, these could be integrated into modern groff.
The B-spline command
D~ is correctly handled by the intermediate output parser, but the drawing routines arent implemented in some of the postprocessor programs.
The argument of the commands
s and x H has the implicit unit scaled point~ *] .. .ec .Endofmacrodefinitions..c-----------------Semanticaldefinitions..nr@maxcolor65536.ds@backslash[rs] .ds @linebreak R][la]line_break[ra]].. in groff, while classical troff had point ( *] .. .ec .Endofmacrodefinitions..c-----------------Semanticaldefinitions..nr@maxcolor65536.ds@backslash[rs] .ds @linebreak R][la]line_break[ra]].. This isnt an incompatibility, but a compatible extension, for both units coincide for all devices without a sizescale parameter, including all classical and the groff text devices. The few groff devices with a sizescale parameter either did not exist, had a different name, or seem to have had a different resolution. So conflicts with classical devices are very unlikely.
The position changing after the commands
Dp, DP, and Dt is illogical, but as old versions of groff used this feature it is kept for compatibility reasons.
Temporarily, there existed some confusion on the positioning after the
D commands that are groff extensions. This has been clarified by establishing the classical rule for all groff drawing commands:
The position after a graphic object has been drawn is at its end;for circles and ellipses, the "end" is at the right side.
From this, the positionings specified for the drawing commands above follow quite naturally.
The differences between groff and classical troff are documented in groff_diff(7).
Defines the parser and postprocessor for the intermediate output. It is located relative to the top directory of the groff source tree, e.g. @GROFFSRCDIR@. This parser is the definitive specification of the groff intermediate output format.