From:	SMTP%"RELAY-INFO-VAX@CRVAX.SRI.COM" 20-MAY-1993 09:25:32.14
To:	EVERHART
CC:	
Subj:	Re: multiple postscript 'pages' per page

From: ferguson@eisner.decus.org
X-Newsgroups: comp.os.vms
Subject: Re: multiple postscript 'pages' per page
Message-Id: <1993May19.085326.199@eisner.decus.org>
Date: 19 May 93 08:53:26 -0400
Organization: DECUServe
Lines: 61
To: Info-VAX@kl.sri.com
X-Gateway-Source-Info: USENET

In article <1993May18.183744.12506@vms.eurokom.ie>, t_wade@vms.eurokom.ie writes:
> Hi there,
> 
> I have just hooked up an Apple Laserwriter to my VAXstation, and can now
> print postscript files.  What I'd like to be able to do is to print 4
> page images per physical page (lecture handouts).  Does anyone out there
> have any nifty postscript that can be inserted before the file to do this ?
> 
> (It is entirely possible that I have underestimated the difficulty of doing
> this, as I speak no Postscript).

Are you using DEC's postscript printer control software?  DCPS-PLUS and/or OPEN
(I think you would need -OPEN for the Laserwriter).  It's an add-on product,
but if you have it you just 

	PRINT file/PARAM=NUMBER_UP=4

I've writen a bit of postscript but have never tried this manually.  I would
think you would need to redefine the "showpage" operator so, when your
regular output did one, it called a routine of your own writing which 
either moved on to the next frame (i.e. by translate and scale) or 
did a real showpage to print the result.  It does not sound too hard, but 
everytime I've said 'that doesn't sound hard' about a postscript problem
Murphy strikes and it is.

Here's the kind of code you need to replace "showpage" (sorry, don't have
time to write the code to replace it _with_; perhaps someone does):

/mydict 100 dict def  % define personal dictionary
mydict begin  % switch to personal dictionary
              % all redefinitions go into personal dictionary
              % How necessary this really is depends on what kind of printer
              % control software you use; it's definitely needed for DCPS, 
              % else you run the risk of redefining some of its routines

<define all your routines needed for multiple-up here, plus the all-important:>

/old-showpage /showpage load def  %% save what "showpage" really is

end  % return from personal dictionary to whatever the default dictionary was;
     % "showpage" definition must go in default dictionary so it can be found
     % by the ps interpreter when needed
  
/showpage    % define personal definition of showpage so everything calls it
  {
    mydict begin  % point to dictionary containing the your definitions definitions

< code to handle movement, and conditionally do the following when ready >
< to actually put image on paper >

    old-showpage

%   return to whatever the default dictionary was
    end  % "close" personal dictionary
  } def


Good luck.  

	- Linwood Ferguson
	  DECUServe

