Article View: comp.sys.mac
Article #1347Re: Looking for troff to word processor/page layout
From: Brian Martin
Date: Thu, 13 Jul 1989 19:20
Date: Thu, 13 Jul 1989 19:20
38 lines
1977 bytes
1977 bytes
In article <237@6sigma.UUCP> blm@6sigma.UUCP (Brian Matthews) writes:
>I've got a bunch of text in troff (actually eroff), using pic and tbl. I
>need to get this text into either Word, Word Perfect, or Ventura on the
>PC, with as much formatting intact as possible.
>Brian L. Matthews +1 206 854 6578
What I've done in the past is to format the document with something like
nroff -TEpson my_troff.src | awk -f my_translator > output.doc
or whatever output driver is available (look in /usr/lib/term). This approach
formats your text with embedded style changes for the target output device,
and the awk filter translates the printer codes to RTF format. In your
troff source, you'll need to turn headers and footers off, set the page length
to 66 so that there are no page breaks, and set paragraph spacing to one line
so that your filter can differentiate between line breaks which are word wrap
and line breaks which are for paragraphs.
To handle pic and eqn, you probably want to generate postscript with the ditroff
driver.
-- Brian
====
Brian K. Martin, M.D.
Department of Psychiatry
John A. Burns School of Medicine
University of Hawaii
and
Martin Information Systems, Ltd.
1103 9th Ave., Suite 203
Honolulu, Hawai`i 96816-2403
Voice (808) 733-2003
Fax (808) 733-2011
ARPA: uhccux!bmartin@nosc.MIL
UUCP: {uunet,dcdwest,ucbvax}!ucsd!nosc!uhccux!bmartin
INTERNET: bmartin@uhccux.uhcc.hawaii.edu
Technical Details
Message-ID:
<4325@uhccux.uhcc.hawaii.edu>Path:
arc1-ca.pugleaf.net!utzoo!attcan!utgpu!jarvis.csri.toronto.edu!rutgers!usc!apple!oliveb!ames!uhccux!bmartinReferences:
<237@6sigma.UUCP>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!attcan!utgpu!jarvis.csri.toronto.edu!rutgers!usc!apple!oliveb!ames!uhccux!bmartin From: bmartin@uhccux.uhcc.hawaii.edu (Brian Martin) Newsgroups: comp.sys.mac Subject: Re: Looking for troff to word processor/page layout Summary: use the nroff driver with an awk script Message-ID: <4325@uhccux.uhcc.hawaii.edu> Date: 13 Jul 89 19:20:14 GMT References: <237@6sigma.UUCP> Reply-To: bmartin@uhccux.UUCP (Brian Martin) Organization: University of Hawaii Lines: 38