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 * text with standard fonts and no special encodings Try to run it on golfer.ps or tiger.ps that comes with ghostscript, e.g., pstoedit -f ?? examples/tiger.ps (You can directly use examples/tiger.ps without copying first as ghostscript searches this file in the ghostscript installation directory) In particular pstoedit does not support * bitmap images * general fill patterns * ... 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 debug 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" ) 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. I've already a very basic backend to PDF which handles graphics and text that uses standard fonts and encodings. What kind of distribution policy do you think is suitable for that? Please email me your comments. Installing pstoedit: -------------------- *edit Makefile and change BINDIR, LIBDIR, and MANDIR according to your local environment You might also need to change the CC Variable to use your favorite C++ compiler. *edit pstoedit and change LIBDIR to the same place as in Makefile type make clean; make; make install; [make test;] Acknowledgements: * Klaus Steinberger who wrote the initial man page. * David B. Rosen for some ideas and some PostScript code from his ps2aplot program. * Ian MacPhedran 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.