Hello Dave,
There two main ways do it,
Instead of using the 'WIN' or 'X' buffer, you can use the 'Z' buffer or the PS to save as a postscript.
Using Z buffer is really simple, see the example :
myDevice = !D.NAME ; get device in use
set_plot, 'Z'
scrdim = [1400.,700.]
loadct, 0, /SILENT
!P.Background = 255
ERASE, 255
DEVICE, SET_PIXEL_DEPTH=24
DEVICE, SET_RESOLUTION=[scrdim[0],scrdim[1]]
DEVICE, DECOMPOSED = 0
plot, indgen(5), indgen(5),$
xstyle = 1, ystyle = 1,$
color = 0, TICKLEN = -0.01
pngout = '~/filename.png' ; Output file
WRITE_PNG, pngout, TVRD(TRUE = 1)
DEVICE, /CLOSE
set_plot, myDevice ; set the initial device
Cheers,
Vincent Sarago
|