TROFF2RTF(1)
π TROFF2RTF(1) β General Commands Manual π
okay bestie, so there's this whole manual page called TROFF2RTF(1), and it lives in the General Commands Manual, and it's about to change your whole *roff-to-Word pipeline, no cap. let's get into it π«Ά
β¨ NAME β¨
troff2rtf β convert troff documents to Rich Text Format
πΈ SYNTAX πΈ
troff2rtf [ -mxx ] [ -S charset ] [ file ... ]
π¦ DESCRIPTION π¦
troff2rtf takes documents that were written to be formatted with troff (or nroff, or literally any of the other *roff variants, iykyk) and converts them into Rich Text Format. and why do we care? because RTF is a reasonably portable interchange standard, bestie β files in RTF format can be read by a whole variety of applications, e.g., Microsoft Word, WordPerfect (Macintosh version 2.0 and up), WriteNow. iconic behavior honestly π
the main use for troff2rtf is to make it easier to transport troff documents for use with microcomputers. so step one: convert your document to RTF, like this:
% troff2rtf [options] file > file.rtf
all the available options are described below. the one you'll most likely use is -mxx to specify a macro package like -me or -ms. and if the document contains tables, the conversion can be done like this instead:
% tblcvt file | troff2rtf [options] > file.rtf
then move the RTF file to your target machine and read it into your document processor. slay π
optional flags may be given to modify the operation of troff2rtf, as follows:
-mxxβ specify macro package, usually-man,-me,-mm, or-ms. β¨-S charsetβ specify the RTF character set.charsetcan be one of the following:ansimacpcpca. the default is the Macintosh character set. for documents that you intend to use under Windows,-S ansiis a better choice. π
π₯ SEE ALSO π₯
π WHO-TO-BLAME π
Paul DuBois, dubois@primate.wisc.edu. thank you for your service π«‘π
π BUGS π
okay so, real talk, table output generated when troff2rtf is used in concert with tblcvt has been known to crash Word outright β caution may be in order, bestie, do not play with this π. in addition, you may need to read the resulting RTF document into a word processor and tweak column widths manually. annoying? yes. fixable? also yes.
also: Word97 adds support for vertically merging table cells (using the \clvmgf and \clvmrg control words). troff2rtf supports vertical spans using these controls, but earlier versions of Word don't yet understand them. consequently, what you'll see for n-cell vertical spans is n individual cells, with all the text in the top cell and n-1 empty cells below it. not a vibe, but that's the tea π΅
and that's the whole page, bestie!! π it's from the General Commands Manual, and the page itself is TROFF2RTF(1) β that's your source, your version, your whole entire moment. go forth and convert πβ¨ππ¦πΈπ
π«Ά
π¦ where this page comes from
- debian bookworm: troffcvt 1.04+repack1-1
- ubuntu noble: troffcvt 1.04+repack1-1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms