[cups] Printing With CUPS CLI Doesn't Make Margins

Helge Blischke HelgeBlischke at web.de
Wed Jul 9 09:54:12 PDT 2014


Am 09.07.2014 um 17:38 schrieb Ahmet Sezgin Duran:

> Hi,
>
> I'm using Ubuntu 14.04 AMD64.
>
> I'm trying to print a document in a special page size. Width 10 cm,
> Height 18 cm, left-right margins 2 cm and top-bottom margins 1 cm. I
> tried to create a page model in printer settings. Like this:
>
> http://i.imgur.com/6tJWQES.png
>
> Printing with this page size works without a problem. But I need to do
> it on the command line. I found how can I do in CUPS documents. Like
> this:
>
> lp -o media=Custom.100x180cm -o page-left=57 -o page-right=57 -o
> page-top=28 -o page-bottom=28 result.jpg
>
> When I print the document (image actually), page sizes are OK but  
> there
> are no margins :/ I'm testing these on CUPS's virtual PDF printer.
>
> Any ideas?
>

AFAIK, Ubuntu 14.04 implements the cups-filters package from  
openprinting.
 From the (fairly recent) sources of this package I learned that
(1)	JPEG images (document-format=image/jpeg) are processed by the
	imagetoraster filter (see /usr/share/cups/mime/cupsfilters.convs).
(2)	The imagetoraster filter (as other imatetofoo filters from this  
package)
	do not honour the page-xxxx attributes to set the margins (they only
	evaluate the respective defaults from the printer's PPD).

So, on the short term, you probably are out of luck.
I suggest to file a bug at
https://bugs.linuxfoundation.org/
for this issue.

Helge





More information about the cups mailing list