troff2html converts
troff(1) (or
groff(1), depending on the processing mode) input documents to an
html
document on the standard output. Although a full
troff parse is done, many features are ignored in the mapping to
html.
The troff t condition test evaluates true, the n condition tests evaluates false, and the groff
compatibility register \\n[.C] evaluates to 0 (enable groff parsing) if it is referenced before the first groff
.cp (compatibility mode) request.
The generated html has properly nested begin/end tags, even though most browsers don't care.
.xx name[=
value] is a special
troff2html request that handles program tracing,
html extensions
and
troff macro package magic that went way past the author's willingness to understand. Supported operations are:
- author=text
Specifies the contact information for the document HEAD section.
- background=URL
Specifies the document background URL.
- debug=level
The debug trace level; higher levels produce more output.
- get=+-register
Traces each get for the named number register. -
turns tracing off.
- hot='word ...'
Adds (+) or removes (-) word ... from the hot-word
list. Constructs that match (hot-word ... SWITCH-FONT text SWITCH-FONT ... ) adds text as a hot link to
another portion of the document. refer and see are the default hot words. Case is ignored when matching hot words.
- logo=URL
Specifies the logo/banner image URL that is centered at the top of the document.
- mailto=address
Sets the email address to send comments and suggestions.
- meta.name
Emits the html tag <META name="name" content="content
">.
- package=text
text is prepended to the html document title.
- set=+-register
Traces each set for the named number register. -
turns tracing off.
- title=text
Sets the document title.
Local URL links are generated for all top level headings. These can be referenced by embedding the benign (albeit convoluted)
troff
construct \h'0*\w"label"'text\g'0', where
label is the local link label and
text is the hot link text. If
label
and
text are the same then use \h'0*1'text\h'0'.