Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP
Posting-Version: version B 2.10.2 9/18/84; site uw-beaver
Path: utzoo!watmath!clyde!cbosgd!ulysses!mhuxr!mhuxj!houxm!vax135!cornell!uw-beaver!info-mac
From: info-mac@uw-beaver
Newsgroups: fa.info-mac
Subject: MacWrite to Troff converter for Vax Unix
Message-ID: <311@uw-beaver>
Date: Sun, 30-Dec-84 18:27:02 EST
Article-I.D.: uw-beave.311
Posted: Sun Dec 30 18:27:02 1984
Date-Received: Mon, 31-Dec-84 03:17:51 EST
Sender: daemon@uw-beaver
Organization: U of Washington Computer Science
Lines: 33

From: (Van Jacobson) van@lbl-csam

Attached is a version of Mike Caplinger's MacWrite-to-Troff converter
that will run on a Vax (i.e., it has byte swaps inserted at appropriate
points).  This version should also work on a Sun (the byteswap is done
with the "ntohs" network routine with should be a nop on a Sun).

In addition to the byte swaps:

 - a translation table that maps all the special characters in the
   standard Mac Geneva font into appropriate troff characters has
   been added.

 - lines bracketed by .TS/.TE or .EQ/.EN are treated specially so
   tbl tables and eqn equations can be embedded in the MacWrite
   document.

 - there's a "-p" flag that saves space for pictures that were in the
   MacWrite document (to help make a `paste-up' final document).

 - a couple of minor bugs were squashed.

A complete shar archive follows.  Most files are self explanatory.  The
file "write2troff.dl" is a tohex'd MacWrite document describing the
program.  The fromhex'd .data version of it can be used as a test case
and/or downloaded to the Mac & inspected with MacWrite (you should
macput it with type "WORD" and owner "MACA").

Happy new year.

- Van (van@lbl-csam.arpa)

[filed on writetotroff.sh]