Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place. |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
|
10-27-2015, 04:39 PM
|
#1
|
LQ Newbie
Registered: Oct 2015
Distribution: Ubuntu, Raspian
Posts: 21
Rep:
|
Custom CUPS testprint file
Is there a way to make a custom testprint file for CUPS? My current /usr/share/cups/data/testprint file contains the following:
Code:
#PDF-BANNER
Template default-testpage.pdf
Show printer-name printer-info printer-location printer-make-and-model printer-driver-name printer-driver-versio.....etc
I would like to use another pdf as Template, but trying that results in just the pdf printing without any of the 'Show' information. I have also tried editing default-testpage.pdf, with the same results. So, there must be something in the formatting of the pdf to allow for the 'Show' fields?
|
|
|
10-31-2015, 10:19 AM
|
#2
|
LQ 5k Club
Registered: May 2003
Location: London, UK
Distribution: Fedora40
Posts: 6,154
|
It looks like cups is generating the test page on-the-fly.
cups uses the
Code:
Template filename
Show options
directives in /usr/share/cups/data/testprint to do this.
To use yourpdf.pdf instead then copy that file to /usr/share/cups/data/ and edit /usr/share/cups/data/testprint to read like this:
Code:
#PDF-BANNER
Template yourpdf.pdf
Show printer-name printer-info printer-location printer-make-and-model printer-driver-name printer-driver-version paper-size imageable-area job-id options time-at-creation time-at-processing
Then restart cups. That should do it.
|
|
1 members found this post helpful.
|
10-31-2015, 06:08 PM
|
#3
|
LQ Muse
Registered: Aug 2005
Location: A2 area Mi.
Posts: 17,639
|
what is your printer?
my HP has many many many potions
BUT
the default cups color wheel dose everything that is needed
depending on HOW it looks you can diagnose a problem
from a low setting on DPI to low black or low color
|
|
|
11-09-2015, 11:21 AM
|
#4
|
LQ Newbie
Registered: Oct 2015
Distribution: Ubuntu, Raspian
Posts: 21
Original Poster
Rep:
|
Quote:
Originally Posted by tredegar
It looks like cups is generating the test page on-the-fly.
cups uses the
Code:
Template filename
Show options
directives in /usr/share/cups/data/testprint to do this.
To use yourpdf.pdf instead then copy that file to /usr/share/cups/data/ and edit /usr/share/cups/data/testprint to read like this:
Code:
#PDF-BANNER
Template yourpdf.pdf
Show printer-name printer-info printer-location printer-make-and-model printer-driver-name printer-driver-version paper-size imageable-area job-id options time-at-creation time-at-processing
Then restart cups. That should do it.
|
I already tried that, but it does not work. It just prints the pdf file none of the "show" information.
|
|
|
11-10-2015, 11:44 AM
|
#5
|
LQ 5k Club
Registered: May 2003
Location: London, UK
Distribution: Fedora40
Posts: 6,154
|
Quote:
It just prints the pdf file none of the "show" information.
|
I just tried this - it prints yourpdf.pdf and, in my case, some of the extra information, but it is way off to the right and basically unreadable.
I do not know enough about the PDF "standard" to be able to help you further. Is there such a thing as a "PDF Editor"? It might be worth opening the original with such, and determining its properties.
|
|
|
11-12-2015, 06:55 AM
|
#6
|
Member
Registered: Oct 2013
Location: IN, USA
Distribution: Arch, Debian Jessie
Posts: 814
|
Quote:
Originally Posted by tredegar
I do not know enough about the PDF "standard" to be able to help you further. Is there such a thing as a "PDF Editor"? It might be worth opening the original with such, and determining its properties.
|
I know that LibreOffice Draw is capable of importing PDFs, but to save it you have to re-export it, which might lose any special properties that might be there.
Maybe open it up with less and see if there's anything readable? I know that I was surprised to find human-readable metadata in a image file once.
|
|
|
11-12-2015, 06:27 PM
|
#7
|
LQ Guru
Registered: Aug 2004
Location: Sydney
Distribution: Rocky 9.2
Posts: 18,398
|
Have a look at pdftk (pdf toolkit); its cli pdf editor with a lot of options.
|
|
|
All times are GMT -5. The time now is 01:59 AM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|