[90] in Software_Announce

home help back first fref pref prev next nref lref last post

ANNOUNCE: Installed pstoedit in outland

daemon@ATHENA.MIT.EDU (Erik Nygren)
Wed Nov 8 12:25:32 1995

To: software-announce@MIT.EDU
Date: Wed, 08 Nov 1995 12:24:29 EST
From: Erik Nygren <nygren@MIT.EDU>


Hello,

I installed pstoedit in the outland locker for Linux, SGI, Solaris,
AIX, NetBSD, and Ultrix.  It's a really cool utility that
allows you to convert postscript files to tgif, MIF (FrameMaker),
or xfig files so that you can edit them.  It doesn't work well on
everything but it works very well on Matlab plots.  It is quite
nice being able to import Matlab plots into Frame or tgif
and then edit them by hand, adding and changing labels, etc.
Remember that this is unsupported software here.

Run with:

	add outland
	pstoedit -f tgif foo.ps 
	pstoedit -f mif foo.ps

to generate foo.ps.obj and foo.ps.mif.

Here's the README:

PSTOEDIT 
Copyright (C) 1993,1994,1995 Wolfgang Glunz, Wolfgang.Glunz@zfe.siemens.de

pstoedit allows to convert Postscript(TM) files to a simple vector graphic
format, that can be edited. Currently tgif, xfig, and Framemaker(TM)
(MIF-format) and flat PostScript are supported.  Ask archie on where to
find tgif or xfig.  pstoedit works by redefining the basic painting operators
of Postscript. Others like image are not supported.  After redefining
these operators, the Postscript file that needs to be converted is
processed by GhostScript (gs). So you need to have Ghostscript in order
to use this program.  pstoedit uses a postprocessor to actually build
the input file for the editor.  This is a small lex-program (makeedit).
To build it, just type make.  Edit the pstoedit script and change LIB
according to your local environment. You need a C++ compiler, e.g. g++,
to compile makeedit.

pstoedit works reasonable with PostScript files containing
	* line drawings
	* gray scale filled polygons
	* non rotated text with standard fonts and no special codings
(Try to run it on golfer.ps that comes with ghostscript)

In particular pstoedit does not support
	* bitmap images
	* general fill patterns
	* colors
	* rotated text (only by translating it into polygons)
	  (rotated text is supportet for the xfig backend. Thanks to Ian MacPhedran)
	* ... 

The output of gs that is piped to makeedit is a flat PostScript which only
contains simple operations like moveto lineto, show, .... 
You can look at this file using the -f ps option of pstoedit.

As an alternative one could also write backends based on the PostScript code
generated from PostScript-To-PostScript translators like pstoai.ps or
still.ps. Another alternative (as suggested by "David B. Rosen" <rosen@unr.edu>)
would be to use the Gnu Graphics library as the basis for different backends.

There is one test (for the tgif backend) included. To run it type `make test'

To implement a new backend you can start from drvexample.c.
See also drvbase.h (drvbase.3) for explanation of the methods that need to 
implemented for a new backend.

If you just find this program useful, have made some improvements or other backends 
please send a mail to Wolfgang.Glunz@zfe.siemens.de.

Acknowledgements:

* Klaus Steinberger <Klaus.Steinberger@physik.uni-muenchen.de> who wrote the initial man page.
* David B. Rosen <rosen@murmur> for some ideas and some PostScript code from his ps2aplot program.
* Ian MacPhedran <Ian_MacPhedran@engr.USask.CA> for the xfig backend.



    This program is free software; you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
    the Free Software Foundation; either version 2 of the License, or
    (at your option) any later version.

    This program is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU General Public License for more details.

    You should have received a copy of the GNU General Public License
    along with this program; if not, write to the Free Software
    Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.



home help back first fref pref prev next nref lref last post