troff - (BSD) typeset or format documents
Synopsis
Description
Environment Variables
Files
Examples
See Also
/usr/ucb/troff [-afiz] [-daS] [-da=S] [-Ffontdir] [-mname] [-nN] [-olist] [-raN] [-ra=N] [-sN] [-Tdevice] [-uN] [-xN]
troff formats text in the named files for printing on phototypesetter devices. Its capabilities are described in the Nroff/Troff user's manual.troff generates output in an intermediate ASCII format which must be passed through a device-dependent post-processor before it can be printed; see the description of the -T option and the example below.
If no file argument is present, the standard input is read. An argument consisting of a single minus (-) is taken to be a file name corresponding to the standard input. The options, which may appear in any order so long as they appear before the files, are:
-olist Print only pages whose page numbers appear in the comma-separated list of numbers and ranges. A range N-M means pages N through M; an initial -N means from the beginning to page N; and a final N- means from N to the end. -nN Number first generated page N. -sN Stop every N pages. Troff will stop the phototypesetter every N pages, produce a trailer to allow changing cassettes, and resume when the typesetter's start button is pressed. -mname Prepend the macro file /usr/ucblib/doctools/tmac/tmac.name to the input files. -raN Set register a (one-character) to N. -ra=N Set register a (may be more than one character) to N. -daN Define string a (one-character) to S. -da=N Define string a (may be more than one character) to S. -i Read standard input after the input files are exhausted. -z Check syntax only; do not generate any output except for error messages. -Ffontdir Use the directory fontdir to locate font files. -u N Set the emboldening amount, i.e. the number of times a character is printed to simulate bold output, to N. -Tdevice Prepare output for the specified device. Available devices are:
ps for PostScript output with 72,000 dpi and AFM fonts (default), with dpost as post-processor psmed for PostScript output with 3,600 dpi and AFM fonts, with dpost as post-processor pslow for PostScript output with 432 dpi and AFM fonts, with dpost as post-processor post for PostScript output with 720 dpi and ditroff fonts, with dpost as post-processor aps for the Autologic APS-5, with daps as post-processor -f Refrain from feeding out paper and stopping phototypesetter at the end of the run. -a Send a printable text-only approximation of the results to the standard output. -xN Enable extensions to previous versions of troff at level N. Level 0 disables any extensions; level 1 enables all extensions except for long requests and request arguments; level 2 enables these in addition but executes short requests which are prefixes of undefined long requests; level 3 ignores undefined long requests.
LANG, LC_ALL See locale(7). LC_CTYPE Determines the mapping of bytes to characters. TYPESETTER Specifies a device name as with the -T option. TROFFONTS A colon-separated list of directory names to search for PostScript fonts before the device font directory. TROFFMACS Specifies the location to search for macro files with the -m option. This string forms a prefix to which the macro package name is immediately appended. Thus to make '-mname' work with a file '/path/to/tmac.name', use 'TROFFMACS=/path/to/tmac.'
/tmp/ta* temporary file
/usr/ucblib/doctools/tmac/* standard macro files
/usr/ucblib/doctools/font/* font width tables
To generate a PostScript file from input that contains equations and tables, useThe resulting file can then be sent to a printer, displayed by a previewer, or passed to further post-processing utilities, such as a PDF distiller.<input tbl | eqn | troff | dpost >output.ps
J. F. Ossanna, Nroff/Troff user's manual
B. W. Kernighan, A TROFF Tutorial
eqn(1B), tbl(1B)
Heirloom Documentation Tools | TROFF (1B) | 9/4/06 |