Jeremias Maerki <dev <at> jeremias-maerki.ch> writes:

> 
> Please, please, people, always state the FOP version you're working with.
> Sigh.
> 
> Anyway, if you're working with FOP 0.20.5 you'll have to modify the FOP
> source code or post-process the PostScript file.
> 
> If you're working with FOP 0.91beta or later you can use a special
> extension:
> 
>   <fo:declarations>
>    <ps:ps-setup-code name="duplex"
xmlns:ps="http://xmlgraphics.apache.org/fop/postscript";>
> <<
> /Duplex true
> >> setpagedevice
>     </ps:ps-setup-code>
>   </fo:declarations>
> 
> (the fo:declaractions element is to be placed between the
> layout-master-set and the first page-sequence.)
> 
> The documentation for this hasn't made it on the FOP website, yet.
> You'll find the specification on the Wiki:
> http://wiki.apache.org/xmlgraphics-fop/ExtensionsForPostScript
> 


Sorry about that, I'm using 0.91.

Althought your ps-setup-code solution adds to the output postscript it still
won't work, the reason being that each page still has a "setpagedevice" 
command. 
This seems to make the printer (or at least the
xerox 2425 I'm workin with) start a new page. Although it runs in duplex mode
(the duplexing unit is flipping pages as it prints) it's not actually putting
anything on the back, if I remove all but the first setpagedevice instruction
then it works fine.

It would seem that the setpagedevice ps code should only be added if and when
the format of a page has changed, since I'm in a hellishly busy time at work at
the moment I really can't spend time making an elegant solution to submit back
into the code base. However for my own use I'm simply going to move the section
in the fop postscript renderer that adds the setpagedevice section out of the
every page loop and into the one time only document setup section.

this is good enough for me at the moment, of course it would stop any paper
format changes mid stream, so should not be submitted to fop. Perhaps when this
busy period (2 months) is over I will take a better look at it and submit some
code that deals with it better (assuming it's not been done already by then).

Thanks for the quick reply.

Ken.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to