Comment 39 for bug 1243484

Revision history for this message
In , Adrian Johnson (ajohnson-redneon) wrote :

(In reply to comment #15)
> I am not sure whether the macro only does the equivalent of
>
> <</PageSize[595 842]/ImagingBBox null>>setpagedevice
>
> In this case we could simply skip its call when the paper size does not
> change (at least when I comment it out I get a correct printout and duplex
> works).

That is basically all the macro does. It also checks if the setpagedevice operator exists before calling it.

So yes we could just skip calling the macro when the page size does not change. Alternatively I could change the macro to only change the page size if it is different to the previous page. This has the advanatge of preserving page independence as required by the DSC specification. ie the macro will be output for every page so pages can be printed in any order and the correct page size will be used but the macro will not alter the page size if the page size in the page device dictionary is already correct.