Re: Fwd: Extra Blank page being printed

Ken Sharp <[email protected]>
Newsgroups gmane.comp.printing.ghostscript.devel
Message-ID <[email protected]>
At 07:58 16/03/2016 +0000, Ken Sharp wrote:


>The system converts PDFs to PostScript which are concatenated and then 
>printed. An extra "image" is printing after the fourth "page", making the 
>duplex printing out of sequence. Can anyone suggest why? This question is 
>a desperation move...

Firstly this is not a forum for support but for programming questions 
relating to developing software which interfaces to the Ghostscript internals.

If you think you have uncovered a bug you may open a bug report at 
bugs.ghostscript.com don't forget to include an example file, and command 
line required to reproduce the problem.


>It prints in Duplex, so if I say "page" here, I mean 2 images, one front 
>and one back on a sheet of paper. Usually the back one is blank
>The application generates "User Letters" that are two pages, a Coversheet 
>and a "User Document" concatenated together using a Byte copy.

PostScript is a programming language, PostScript files are programs. 
Effectively you are concatenating two programs together, do you think this 
is likely to work ?

While it will, for some cases, especially simple cases, in general 
concatenating PostScript programs is well known to fail, sometimes 
spectacularly. This is not a sensible approach to whatever your problem is.


>The Coversheet is a generic PostScript (mostly static) file created by 
>Microsoft Word.
>The User Document is converted from PDF to PostScript with GhostScript.
>%%Creator: GPL Ghostscript GIT PRERELEASE 908 (ps2write)
>
>It has a duplex command inserted thus above the BeginProlog statement.:
><< /Duplex true >> setpagedevice

Well that will likely be the start if your problems, each invocation of 
setpagedevice 'resets' the device. Assuming your printer was initially in 
duplex mode, issuing a new setpagedevice will (normally) cause the printer 
to eject the page by printing a blank page and restarting in duplex mode.


>If converted to PDF from PostScript, the User Letter is always 2 pages. 
>There is no blank image.

Sounds to me exactly what I would expect to happen by meddling with the 
duplex setting and issuing a setpagedevice on every other page.


>... Maybe it is the printer...  Thank you for any suggestions, Michael

Beyond the above, there is nothing I can possibly say without seeing the 
programs. Nothing here makes me think there is any problem beyond your 
insertion of setpagedevice operators though.


                 Ken
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.