I wrote:
I use a Samsung ML-4500 printer under Fedora Core 2 Linux using Cups.
As far as I can tell, the printer is configured correctly --
nevertheless the printer cannot print the whole page submitted to it; it
cuts off about 0.3 in. at each margin. As a consequence pages formatted
by Mozilla don't show the header or footer when printed.
Ghostscript includes a *.ps file -- align.ps -- which gives instructions
on how to generate a small file to be prepended to whatever is being
printed so as to correct this problem. I have printed this file, and
followed the instructions, getting the small file to be prepended,
namely:
<<
/.HWMargins [9.36 8.64 10.08 12.24]
/Margins [-84.0 -126.0]
>>
setpagedevice
Now my questions:
(1) The Margins command seems to work as described in the Ghostscript
documentation, but the .HWMargins command doesn't seem to do anything.
Is .HWMargins being overwritten somewhere farther down the chain of
filters? If so, where?
(2) Assuming I can find out what are the correct values to put into this
little file, what is the approved standard way to incorporate it or
something like it into the Cups print system?
James Wilkinson <james(a)westexe.demon.co.uk> replied:
This doesn't happen for me. The headers print fine.
If you run system-config-printer as root, edit the queue, and click on
Queue Options, what does it say under Imageable Area? Are all the
margins 36 pt?
Jason L Tibbitts <tibbs(a)math.uh.edu> replied:
One thing you can try is editing the PPD file. I had an HP Laserjet
4050 with the same problem, fixed by editing the PPD and changing
ImageableArea entries as appropriate to get things to fit.
The PPD that cups is currently using should be in /etc/cups/ppd.
Thanks to you both. Unfortunately
(1) Changing the margins using system-config-printer->queue->Queue Options
doesn't change the ppd file /etc/cups/ppd/lp0.ppd (which I believe is
cups control file for this printer). The margins were set to 36 point
when I started looking at them: I changed them to up to 144 points (which
seems to be the max allowed) without any effect on printing or on lp0.ppd.
Then I set them back to 36 pts.
(2) Editing the ppd file /etc/cups/ppd/lp0.ppd doesn't change printer
behavion. I rebooted the system just for good measure. Here is the
relevant change:
$ diff -c /etc/cups/ppd/Samsung-ML-4500-gdi.ppd /etc/cups/ppd/lp0.ppd
*** /etc/cups/ppd/Samsung-ML-4500-gdi.ppd Thu Aug 26 22:46:09 2004
--- /etc/cups/ppd/lp0.ppd Sun Aug 29 14:53:48 2004
***************
*** 143,147 ****
*DefaultImageableArea: Letter
! *ImageableArea Letter/Letter: "0 0 612 792"
*ImageableArea A4/A4: "0 0 595 842"
*ImageableArea A5/A5: "0 0 420 595"
*ImageableArea A6/A6: "0 0 297 420"
--- 143,147 ----
*DefaultImageableArea: Letter
! *ImageableArea Letter/Letter: "10 9 592 771"
*ImageableArea A4/A4: "0 0 595 842"
*ImageableArea A5/A5: "0 0 420 595"
*ImageableArea A6/A6: "0 0 297 420"
Is /etc/cups/ppd/lp0.ppd the right file to look at? Any other suggestions?
Thanks - jon