psnup ignores "-p" option

Bug #396025 reported by Francesco Galgani
36
This bug affects 7 people
Affects Status Importance Assigned to Milestone
psutils (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

On Ubuntu 9.04, psnup (provided by psutils 1.17-26) always produces an US-Letter size output, even if the "-pa4" option is setted.

Thanks for your attention,
Francesco Galgani

Tags: patch
Revision history for this message
febrile (febrile) wrote :

This also applies on 9.10's psutils 1.17-26. psnup produces US-letter output regardless of:

-pa4 and/or -Pa4 options
-w595 -h842 options
/etc/papersize: "a4"

This leads to text being lost off the page width-wise when trying to n-up A4 documents, so it's completely unusable anywhere US-letter is not the norm.

I'm no expert, but happy to follow up trying to help diagnose if you walk me through it.
Thanks.

Revision history for this message
febrile (febrile) wrote :

Some follow-up:
Looking at input and output files as text, it seems psnup doesn't write %%DocumentMedia and %%BoundingBox lines to the output. When I copy the lines
%%DocumentMedia: plain 595 842 0 () ()
%%BoundingBox: 0 0 595 842
from the input into the output file, everything shows correctly: correct papersize, no lost text.
(Why it should default to US-letter when both my /etc/papersize and en-GB locale are A4-centric is beyond me.)

Revision history for this message
febrile (febrile) wrote :

... and in fact putting either one of those 2 lines

%%DocumentMedia: plain 595 842 0 () ()
 or
%%BoundingBox: 0 0 595 842

into the output seems to save the day (viewing in evince).

Revision history for this message
febrile (febrile) wrote :

Ah, it seems this may at least partly be an evince problem rather than psutils.

The output (without DocumentMedia or BoundingBox lines added) shows up correctly as A4 using gv, but as US-letter with evince. If the .ps file doesn't specify then I guess the viewer should look to the system default papersize; it seems evince doesn't do that.

BUT I'd say psnup ignoring the -w -h and -p flags is still a bug: it's not as documented in the manpages, and I guess it could be a hassle if you're working with documents that aren't your system default papersize.

Revision history for this message
Sam Liddicott (sam-liddicott) wrote :

evince clearly has a bad strategy for dealing with documents that lack media information when gv can do so successfully.

psutils also is faulty in not emitting the information

Revision history for this message
AZ (m-dev) wrote :

this add the paper size information to the postscript document based on the output paper size configuration.

Revision history for this message
AZ (m-dev) wrote :

solution added to ppa https://launchpad.net/~m-dev/+archive/bugfix for maverick

tags: added: patch
Changed in psutils (Ubuntu):
status: New → Confirmed
Revision history for this message
lainme (lainme) wrote :

This bug seems last long. I am using ubuntu10.04 and also affected by the bug.

Revision history for this message
Jay Berkenbilt (ejb) wrote :

Debian psutils 1.17-30 (just uploaded) now incorporates this patch.

Revision history for this message
Andy (acreech2330) wrote :

I am having the same problem as well. I am running Linux Mint 14 Cinnamon on an Acer Aspire Laptop 64 bit. I am using psnup through the package psutils 1.17-32. I have tried to set the output page size to -W 8.5 i -H 7 i. I have also tried to use -Plegal. I have tried various combinations of these parameters, but it still only produces a letter size page.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.