unroff is a programmable, extensible troff translator that is useful for converting documents with embedded troff markup into another format. Although unroff has been designed with higher-level, structure-oriented target languages (such as SGML) in mind, it fully supports all constructs and idiosyncrasies of ordinary troff, so that even low-level formatting requests can be handled correctly if desired.
Translation rules for a specific output format and knowledge about existing troff macro packages are not hard-wired in unroff, instead, the translation is controlled by a user-supplied set of procedures written in the Scheme programming language. Interpretation of the procedures is facilitated by a full Scheme interpreted embedded in unroff. This manual describes the Scheme primitives provided by unroff that can be used to customize the translation rules implemented by existing back-ends and to write new ones for new output formats.