From xyzzy@speakeasy.org  Sat Jun  2 22:14:40 2001
From: xyzzy@speakeasy.org (Trent Piepho)
Date: Sat, 2 Jun 2001 14:14:40 -0700 (PDT)
Subject: [Rd] paper size in postscript driver
In-Reply-To: <Pine.GSO.4.31.0106010715230.22278-100000@auk.stats>
Message-ID: <Pine.LNX.4.04.10106021404400.4114-100000@xyzzy.dsl.speakeasy.net>

On Fri, 1 Jun 2001, Prof Brian D Ripley wrote:
> > Why does it need to break anything?  Both staroffice and gimp produce
> > postscript that prints on the proper paper size.  Do they not work with
> > "proper" spooling software?  What is the "proper" spooling software for Linux?
> 
> The code you suggested adding is level-2 PostScript and does not work on
> my office printer, for example.  So, yes, it would break things.  This is
> why such code is the preserve of a Document Manager in the print spooling
> system in Adobe's model.

No need to give up so quickly!

First, there could be an option for postscript level in the PS driver.  Adobe
acrobat reader, staroffice, etc. have an option like this, where you can
select level 1, 2, 3.  People who have a level 1 printer, could just select
level 1 output.

Secondly, you can use a "protected" setpagedevice call that will work on both
level 1 and level 2 printers.  It looks something like this:

/setpagedevice where { pop << /param value ...  >> setpagedevice } if

The 'where' command will return false if setpagedevice isn't defined, and thus
it setpagedevice will never get called.

> R follows the recommendations of the PostScript Language Reference Manual
> (Appendix G, to be precise).  Looks like StarOffice and GIMP *on your Linux
> installation* do not.

It's not just those programs.  Lots of applications will output setpagedevice
commands to control paper size, duplex, etc.  It's usually the ones with more
comprehensive postscript support, that have these features.

-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-devel mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-devel-request@stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._


[Rd] paper size in postscript driver
Trent Piepho