Problem with printing on custom size paper
4 Attachment(s)
So, I have the following setup:
- desktop computer running Xubuntu 19.10 - cups 2.2.12 installed with one network Canon MF8280Cw printer installed in 2 variants: - one time lpd://ip.ad.re.ss - one time socket://ip.ad.re.ss I have a custom document that I need to print, meaning the label.pdf from the attachments. The document is a mask that should be printed on a given transport label that I receive from our transport partner and has a size of 167 mm x 102 mm. No matter what settings I am trying to apply all I manage to print out is looking like the print.pdf, only the lower part of the initial document gets printed out... on what seems to be the right xasis positioning... top part is chopped off... What is also very strange is that the printer is not trying to split the job on different pages and after printing the first one... You can also see my print settings, although I have also tried other ones. I do not know what to try... I have the feeling that I should declare the custom paper size in the settings of the printer, but I am not sure and I do not know in what direction I can research more about this. My google fu is also not helping at this moment. From another computer with Windows I can print the document, but there I can declare the custom size of the paper in the printer properties. Here in Linux, this custom size is visible only in the print dialog of the pdf document viewer and I cannot declare it in Cups or anywhere in the printer properties. I have also tried 2 different pdf viewers: Atril and Gnome Document Viewer. Another thing: on the printer itself I have declared this type of custom paper size and I can declare in which tray I have fed the custom size paper. When printing from the windows machine the printer takes automatically paper from where I have declare that it is. When printing from Linux every time, I get an error on the printer (or a warning) and I have to manually specify (on the printer) from where it should take paper. The result, as said is like the one from print.pdf Any hint? Any idea? Thank you very much! |
A Few things:
People usually give width by height; so A4=210 x 297 mm. 167mm x 102mm sounds like it's wider than long. Something in the print chain defaulted to landscape when I tried that, turning the page sideways. The solution to that is to set the page square (167x167) or even longer. when the label finishes, the printer is given a for feed which ejects it, so the length doesn't actually matter, as long as you know the stuff being printed isn't longer. If your app accommodates it, set up a square custom page. The printing chain is: PDF viewer --> cups --> ghostscript & ppd --> printer The further left you can set the custom page, the better. You may have to set it on pdf viewer and cups. If it's giving headaches, set it as default. |
If you print to pdf first and then take the resulting file and print it, is there any difference with printing behaviour?
|
Quote:
On PDF viewer I can do it, the same on the printer... the ghostscript & ppd is pretty difficult to alter as it receives mainly data and passes it forward... Quote:
Thank you! |
You could tweak the image to trick it into printing in the desired space. You could tweak the ppd to favor your custom size. YMMV. Certain label types have "templates" that can be used. I'm not sure how you'd use those in linux. I normally take the dots per inch specification of the printer and do the math. With 25.4mm per inch it's not that difficult to figure out. Or close guess / trial and error it.
|
If you don't need repeatability, you could take a sheet of graph paper (grid lines) and tape the label to it to favor the area that gets printed. Depends on the printer I guess, some favor particular paper thicknesses and aren't very flexible.
|
Quote:
So "engineeringly" speaking I am covered with a solution that resolves 80% of the problem and the actual topic is only a learning issue. thanks for the thoughts though! |
Quote:
Printers --> your printer --> properties, or something like that. I spotted your pics at the bottom. 167x102 is probably going to turn the page 90 degrees, print landscape, and run off the end of the page. Set 167x167 if that (167x102) is your paper size. There's a compulsory margin around most printers of minimum 0.5" (~12.7mm), = 25.4mm left/right and top/bottom. It may be larger on some. But you can usually shrink output to fit. |
Quote:
Defining a 167x167 custom size did not helped: when I print portrait I get only the left part of the document, when I print landscape I get the same result as before. I also thing it is a "type mismatch" somewhere, a kind of autorotate that functions when it should not be on the entire printing chain. I say this because the printer throws me an error every time when I am printing on the custom paper size. Normally if the printer matches the size of the document with a paper size its taking it automatically. In my case the printer blinks red and asks me to choose a paper size on which to print the job. Since the print preview is ok, I think further down on the "pipe to the printer" the thing gets one more time rotated... would be interesting to find where, and I do not know how I can investigate... thanks for all the ideas so far! |
It is possible to run the printing filter chain manually, and that is explained here...
https://wiki.ubuntu.com/DebuggingPrintingProblems and https://fedoraproject.org/wiki/How_t...ilters_by_hand To get the filters used for a particular print job, you can put CUPS into debug mode with Code:
sudo cupstctl --debug-logging Code:
sudo grep -iA3 filters /var/log/cups/error_log Code:
D [31/Mar/2020:07:43:55 +1300] [Job 42] 2 filters for job: |
So it is turning the page and printing landscape? Have you considered LYING as a solution.
Set in in landscape, set the size as 102x167 and it will probably turn it to portrait. Do nothing to the printer:hattip: |
Quote:
thanks for the suggestions. |
All times are GMT -5. The time now is 07:35 AM. |