[Thread Prev][Thread Next][Index]

Re: manipulate postscript output from -batch



Hi ferreters,

Here is an update and hopefully a solution to the issue:
My aim was to produce a number of high quality
postscript files directly from a shell script, and with the orientation and scaling as I want it.
I think I could find a solution, based also on a previous posting in this list.
Basically I was trying to get the same power as the "gksm2ps" options but in batch mode,
where "metafile" stuff is not working. Options 1 and 2 where not satifactory, but No. 3 does the job nicely.

1) Use -gif option and manipulate the size and ratio with the window command
options /aspect and /size (suggested by Toni Mira): Though it works in principle, it produces bitmap (pixel)
 graphics in which small font look really ugly (sometimes illegible) or if one increases resolution (larger /size=...), thinn
line can disappear or look edgy.

2) use -batch option and then try to manipulate the resulting postscript using various pstools:
e.g. this worked in principle for me (though see caveats below):
     > ps2eps outfile.ps                                                                                           # 1. create eps
     > epsffit -c -r -a 20 30 590 770 outfile.eps rotated_and_scaled.eps      # 2. rotate and stretch
     > ps2ps fitted.eps fitted.ps                                                                              # 3. create ps again

  The problem here is that I can only get lines in color mode (like the "-l cps" option
  of gksm2ps) and that fonts still look distorted and everything looks less precise and fine than
  in an X-windows output followed by gksm2ps.

         This is it:
3) use the -unmapped option. It seems to allow "set window/aspect=XY/size=XY" commands for the
first internal ferret window and also set + cancel metafile commands, but not "set window/new". 
Then use gksm2ps to creat the ps file to your needs.
With this method it is possible to create nice looking single page ps-files.

Perhaps an additional comment on this usage of the "-unmapped" option in the next
ferret user's guide would be good.

Rolf


----------  Forwarded Message  ----------

Subject: manipulate postscript output from -batch
Date: Monday 03 May 2004 13:22
From: Rolf von Kuhlmann <kuhlmann@mpch-mainz.mpg.de>
To: ferret_users@noaa.gov

Hallo ferreters,

I would like to produce a number of plots directly in postscript format.
"ferret -batch" works nicely except that my plot appears as landscape
(and with american page size settings)
though intended as portrait, and thus also looks squeezed compared to
a version produced by writing in a metafile and then using gksm2ps -p
 portrait ...

Is there a way to manipulate the orientation and size of the postscript
file created in batch mode similarly to the gksm2ps options?
Otherwise I guess I have to edit the ps-file itself ...

Thanks for any suggestions!

Regards, Rolf

-------------------------------------------------------

-- 
----------------------------------------------------------------------------------
Rolf von Kuhlmann
Max-Planck-Institut fuer Chemie   |  Tel: (+49)-(06131)-305-332
Nachwuchsgruppe / Abt. Luftchemie |  Fax: (+49)-(06131)-305-577
J.J.-Becher-Weg 27    |  E-Mail: kuhlmann@mpch-mainz.mpg.de
D-55128 Mainz         |  Web: http://www.mpch-mainz.mpg.de/~kuhlmann
----------------------------------------------------------------------------------



[Thread Prev][Thread Next][Index]

Dept of Commerce / NOAA / OAR / PMEL / TMAP

Contact Us | Privacy Policy | Disclaimer | Accessibility Statement