comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: Writing a plot in PDF format from IDL
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
Re: Writing a plot in PDF format from IDL [message #43448] Thu, 14 April 2005 19:19 Go to next message
Kenneth P. Bowman is currently offline  Kenneth P. Bowman
Messages: 585
Registered: May 2000
Senior Member
In article <1113523376.120343.69050@l41g2000cwc.googlegroups.com>,
"kirkland" <aaamblard@yahoo.fr> wrote:

> Does someone know how (if it is possible) to write a plot in
> PDF format from IDL ?
>

Write Postscript and then use one of many methods to convert to PDF
(Adobe Distiller, pstopdf, Illustrator, ...). Under Mac OS X, just
double-click the PS file.

Ken Bowman
Re: Writing a plot in PDF format from IDL [message #43545 is a reply to message #43448] Fri, 15 April 2005 06:07 Go to previous messageGo to next message
btt is currently offline  btt
Messages: 345
Registered: December 2000
Senior Member
Kenneth P. Bowman wrote:
> In article <1113523376.120343.69050@l41g2000cwc.googlegroups.com>,
> "kirkland" <aaamblard@yahoo.fr> wrote:
>
>
>> Does someone know how (if it is possible) to write a plot in
>> PDF format from IDL ?
>>
>
>
> Write Postscript and then use one of many methods to convert to PDF
> (Adobe Distiller, pstopdf, Illustrator, ...). Under Mac OS X, just
> double-click the PS file.
>

Under MacOSX I use the following.

;+
; NAME:
; PStoPDF
;
; PURPOSE:
; Use this procedure to convert a PostScript file to a PDF file.
;
; CALLING SEQUENCE:
; PStoPDF, filename, [/DELETEPS], [STATUS = variable], [/VERBOSE]
;
; ARGUMENTS:
; FILENAME A scalar or an array of file names for the postscript
; files to convert.
;
; KEYWORDS:
; DELETEPS Set this keyword to delete the PS file after
; converting to PDF.
; STATUS Set this keyword to a named variable to retrieve
; the operation status.It returns 1 if successful and 0 if not.
; VERBOSE Set this keyword to output update messages
; to the command line.
;
; REQUIREMENTS
; The routine spawns a command to 'pstopdf' - this is built
; in with Mac OSX and perhaps other platforms. FILE_DELETE
; is used to delete the file. FILE_DELETE appeared with IDL 5.4.
;
; MODIFICATION HISTORY
; 2004 written BT.
;-


PRO PStoPDF, psFile, $
DELETEPS = deletePS, $
STATUS = status, $
VERBOSE = verbose, $
_Ref_Extra = extra


STATUS = 0
n = n_elements(psFile)
if n EQ 0 then Return

For i = 0, n-1 Do Begin

cmd = 'pstopdf ' + psFile[i]
SPAWN,cmd, _extra = extra

If Keyword_set(DeletePS) then $
FILE_DELETE, psFile[i], _Extra = extra

if Keyword_Set(VERBOSE) then $
print, 'converting ', psFile[i] , ' to PDF'
EndFor

Status = 1
END
Re: Writing a plot in PDF format from IDL [message #43597 is a reply to message #43448] Wed, 20 April 2005 19:21 Go to previous message
kirkland is currently offline  kirkland
Messages: 2
Registered: April 2005
Junior Member
Kenneth P. Bowman wrote:
> In article <1113523376.120343.69050@l41g2000cwc.googlegroups.com>,
> "kirkland" <aaamblard@yahoo.fr> wrote:
>
>> Does someone know how (if it is possible) to write a plot in
>> PDF format from IDL ?
>>
>
> Write Postscript and then use one of many methods to convert to PDF
> (Adobe Distiller, pstopdf, Illustrator, ...). Under Mac OS X, just
> double-click the PS file.
>
> Ken Bowman


This I know, but how could I write it directly from IDL without using
a converter.
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: why do not the results agree?
Next Topic: Re: Inverse CWT

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 18:14:12 PDT 2025

Total time taken to generate the page: 0.00627 seconds