[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Export plot to PS
- Subject: Re: Export plot to PS
- From: Martin Schultz <martin.schultz(at)dkrz.de>
- Date: Thu, 29 Mar 2001 13:49:58 +0200
- Newsgroups: comp.lang.idl-pvwave
- Organization: Max-Planck-Institut fuer Meteorologie, Hamburg
- References: <3AC31C89.35113E1B@fys.ku.dk>
- Xref: news.doit.wisc.edu comp.lang.idl-pvwave:24232
Martin Skou Andersen wrote:
>
> Hi there...
> Is there a way to export/save a plot to an PostScript file?
> Or in anyway save a plot made by idl, to a image?
>
> Thanx
> --
> MVH. Martin Skou Andersen
> E-mail: Skou@fys.ku.dk
> Martin_Skou@mail.tele.dk
> Homepage: http://www.fys.ku.dk/~skou/
I believe that you created the plot using direct graphics as opposed
to object graphics (otherwise you would probably know the answer to
your question ;-).
The answer is no, but ...
You cannot "copy" the output of several IDL plotting commands to a ps
file or to the printer (leaving aside the tvread() option ->
http://www.dfanning.com where you will only get a bitmap copy).
In order to produce a ps plot, you must "rerun" all your plotting
commands after switching the devide to 'PS'. Here is a short tutorial:
plot, findgen(100) ; this should produce a graphics window
olddev = !D.Name
set_plot, 'PS'
plot, findgen(100) ; this will now be written into a postscript
file 'idl.ps'
device, /close ; *very* important
set_pot, olddev
You can use the device procedure (after set_plot,'PS') in order to set
up the postscript device according to your needs. Much more
comfortable, though, is the use of David Fanning's fsc_psconfig
program.
Of course you can also write a couple of objects where the plot is
made into a draw widget instead of a "normal" graphics window, and
then you have a print button which changes the device to ps and calls
the Show method again. This is probably what you really want, but I am
sorry, it's not ready yet ;-(
Good luck,
Martin
--
[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[
[[ Dr. Martin Schultz Max-Planck-Institut fuer Meteorologie [[
[[ Bundesstr. 55, 20146 Hamburg [[
[[ phone: +49 40 41173-308 [[
[[ fax: +49 40 41173-298 [[
[[ martin.schultz@dkrz.de [[
[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[