[comp.text] Wordstar to MAC ?

mfi@beach.cis.ufl.edu (Mark Interrante) (05/19/88)

My wife has a thesis in wordstar on a PC and now that we have a mac
she wants to move it over to the MAC.  We do not know wordstar, (the
typist provided the disk) but I can obtain access to a PC with wordstar.

Does wordstar have the ability to write (msword, RTF) file formats?

I would like the formatting to transfer but forgoeing that, how do we
save straight text files in wordstar?

					Thanks.

------------------------------------------------------------------------------
| Mark Interrante                                            CIS Department  |
| (904) 335-8047                                      University of Florida  |
| Internet:  mfi@beach.cis.ufl.edu                   Gainesville, FL  32611  |
------------------------------------------------------------------------------

chuq@plaid.Sun.COM (Chuq Von Rospach) (05/19/88)

>My wife has a thesis in wordstar on a PC and now that we have a mac
>she wants to move it over to the MAC.

>Does wordstar have the ability to write (msword, RTF) file formats?

>I would like the formatting to transfer but forgoeing that, how do we
>save straight text files in wordstar?

Coincidentally, one of my authors writes with a PC and Wordstar. Since I
need to move the text to my Mac for layout. I'm primarily interested in the
text, but I tried to save some of the formatting in a way that I can use it
as a guide during layout. 

What I do is load the text files onto my Unix box here via PC-NFS, then run
the enclosed program on it. It does a pretty good job of parsing out a
WordStar file and cleaning it up. After that, I download it from my Unix box
to my Mac.

This program is a really dirty hack, but wotthehell. And if you can get
fiels directly from a PC to a Mac, you should be able to compile this thing
with LightSpeed C and cut the middle-machine out completely.

Anyway, this should give you ideas...

chuq
-----
/* This will unpack a wordstar file reasonable cleanly */
#include <stdio.h>
#include <ctype.h>

main()
{
    int c;
    int nl = 0;
    int nb = 0;
    int first = 0;

    while ((c = getchar()) != EOF) {
	if (!isascii(c)) /* strip high bits */
	    c = toascii(c);

	if (iscntrl(c) && c != 10) { /* control chars, excelt \n */

	    if (c == 13 || c == 26) /* ignore ^M and ^Z */
		continue;
	    else if (c == 19) /* ^S, italics */
		printf("(I)");
	    else
		printf("|%d|", c); /* Anything else */

	} else {
	    if (c == 10) {
		if (nl) { /* if we just printed a \n, don't dbl space */
		    nl = 0;
		} else {
		    nl++;
		    putchar(c);
		    first++;
		}
	    } else if (c == 32) { /* removing excess spaces */
		nb++;
		if (nb == 5) {
		    nb = 0;
		    if (!nl) {
			putchar('\n');
			first++;
			nl++;
		    }
		}
	    } else {
		nl = 0;
		if (nb && !first)
		    putchar(' ');
		nb = 0;
		putchar(c);
		first = 0;
	    }
	}
    }

    putchar('\n');
}

Chuq Von Rospach			chuq@sun.COM		Delphi: CHUQ

	Robert A. Heinlein: 1907-1988. He will never truly die as long as we
                           read his words and speak his name. Rest in Peace.

dao@cs.nott.ac.uk (David Osborne) (06/02/88)

Apple bundle a conversion utility called Apple File Exchange
with the new System (5.0 or 5.1, I think)... this offers a means
of translating other word-processing formats to and from the likes
of MacWrite and Word.  a translation script is provided to handle
conversion to/from ibm's DCA-RTF format;  the manual says that other
scripts, including one for translating WordStar, are commercially
available.  i haven't got the manual here, but it does give the
address of a company in the US offering one for dealing with WordStar.
I'll post the details when i have them.

dave
-- 
David Osborne
+---------------------------------------------------------------------------+
| Cripps Computing Centre, University of Nottingham, Nottingham NG7 2RD, UK |
| JANET: dao@uk.ac.nott.cs		||	     cczdao@uk.ac.nott.vaxa |
| UUCP: {...!mcvax}!ukc!nott-cs!dao					    |
| ARPA: dao%cs.nott.ac.uk@ucl-cs.arpa	||   @ucl-cs.arpa:dao@cs.nott.cs.uk |
| Phone: +44 602 506101 x2064				     Voice: "Dave!" |
+---------------------------------------------------------------------------+