.\
cgfixps.pro
top cgFIXPS
Graphics, Utilities
cgFIXPS, in_filename [, out_filename] [, /A4] [, /LEDGER] [, /LEGAL] [, /LETTER] [, PAGETYPE=string] [, /QUIET] [, /SUCCESS]
This program modifies an IDL-produced PostScript landscape mode file so that the output is right side up rather than upside down. In other words, it turns a so-called seascape file into an actual landscape file. Files that are not currently in landscape mode will be ignored. Tested with single and multiple page PostScript output from IDL 7.0.1 and 7.1.
The program requires the Coyote Library to be installed on your machine.
Parameters
- in_filename in required type=string
The name of an IDL-produced PostScript file in landscape mode.
- out_filename in optional type=string
The name of the fixed output PostScript file. If not provided, the input file is overwritten. Overwritting assumes proper read/write permission in TEMP directory and in the directory where the input file is located.
Keywords
- A4 in optional type=boolean default=0
Set this keyword if the PostScript file is using a A4 Europeran sized page.
- LEDGER in optional type=boolean default=0
Set this keyword if the PostScript file is using a US ledger size (11 x 17 inch) page.
- LEGAL in optional type=boolean default=0
Set this keyword if the PostScript file is using a US legal size (8.5 x 14 inch) page.
- LETTER in optional type=boolean default=0
Set this keyword if the PostScript file is using a US letter size (8.5 x 11 inch) page.
- PAGETYPE in optional type=string default=Letter
A generic way to set the page size. A string of "LETTER", "LEDGER", "LEGAL", or "A4".
- QUIET in optional type=boolean default=0
Set this keyword to suppress error messages from the program.
- SUCCESS out optional type=boolean
If this keyword is set to a named variable, then on output the variable will return a 1 if the operation was successful, and a 0 otherwise. Using this keyword also supresses the program's ability to "throw" an error. Informational messages are issued about program developments, but this program will allow the program caller to decide what to do with unsuccessful program completion.
Author information
- Author:
FANNING SOFTWARE CONSULTING:
David W. Fanning 1645 Sheely Drive Fort Collins, CO 80526 USA Phone: 970-221-0438 E-mail: david@idlcoyote.com Coyote's Guide to IDL Programming: http://www.idlcoyote.com
- Copyright:
Copyright (c) 2009-2012, Fanning Software Consulting, Inc.
- History:
Change History:
Written by: David W. Fanning, 6 August 2009. Change to overwrite input file if output filename is not provided. 6 August 2009. DWF. Incorporated checks for non-landscape mode files and files that have already been fixed. 6 August 2009. DWF. Modified to fix multiple-page PostScript files and to work seamlessly with cgPS_Open output. 8 August 2009. DWF. Ran into a problem in which the PostScript file is stored in the directory pointed to by the IDL_TMPDIR environment variable. Now check to see if the input filename is the same as the output filename and make a change, if necessary. 22 July 2010. DWF. Retreated to standard error handling with cgErrorMsg as there are inevitable errors. 2 August 2010. DWF. Output file was created, even if not used. Now deleting file and issuing messages to explain why output file was not created. 1 November 2010. DWF. Added SUCCESS and QUIET keywords. 15 Novemember 2010. DWF. PostScript file structure changed in IDL 8. Made adjustment to find the PageBoundingBox line. 19 Dec 2010. DWF.
File attributes
Modification date: | Fri Mar 27 11:07:37 2015 |
Lines: | 306 |
Docformat: | rst rst |