gtklp(1)

πŸ’– gtklp β€” the manual page, but make it make sense πŸ’–

okay bestie, sit down, we're learning gtklp from gtklp(1) and honestly? it's giving "graphical printing era" and I'm obsessed. let's go 🫢


✨ NAME ✨

gtklp β€” print files via CUPS. that's it, that's the whole vibe. πŸ’…


✨ SYNOPSIS ✨

so there's three ways to call this thing, and here they all are, character for character, no cap:

gtklp [-P|-d printer] [-c configdir] [-S|-h server] [-p port] [-l] [-D]
[-V] [-b] [-i] [-F] [-H] [-C] [-U user] [-#|-n n] [-E] [-q priority]
[-t|-J jobname] [-o option=value ... ][file(s)]
lp [-d printer] [-S|-h server] [-p port] [-D] [-V] [-b] [-U user] [-#|-n
n] [-E] [-q priority] [-t|-J jobname] [-P page-list [-H handling] [-X]
[-o option=value ... ][file(s)]
lpr [-P|-d printer] [-S|-h server] [-p port] [-D] [-V] [-b] [-U user]
[-#|-n n] [-E] [-q priority] [-t|-J|-C|-T jobname] [-X] [-o option=value
... ][file(s)]

notice how the same program shows up as three different personalities depending on what you call it β€” main character energy fr fr. 🌈


✨ DESCRIPTION ✨

GtkLP is an graphical frontend for CUPS, the Common UNIX Printing System. πŸŽ€

basically it exists so you can have an easy (and graphical πŸ’–) way to reach ALL of the many, many options that cups-managed printers have. like, cups has a lot of options. GtkLP is the friend who translates. ✨


✨ OPTIONS ✨

the ones gtklp recognizes πŸ¦‹

  • -P printer β€” use printer as your default destination. where the job goes, periodt. πŸ‘‘
  • -d printer β€” literally equivalent to -P. same thing, different letter, no cap.
  • -c configdir β€” use configdir to set an alternative path to the configfiles for GtkLP. πŸ—‚οΈ
  • -S server β€” the name of the CUPS-Server.
  • -h server β€” the same as -S. twin behavior. πŸ’œ
  • -p port β€” the port of the CUPS-Server, 631 per default. πŸšͺ
  • -l β€” only list the chosen options as a list of commandline-parameters for lpr. nice for scripting purposes... (lowkey the sleeper hit of this whole page)
  • -D β€” Debug. πŸ”
  • -V β€” displays the version of GtkLP. say hi to her. πŸ‘‹
  • -b β€” use builtin defaults instead of saved options. fresh start energy ✨
  • -i β€” ignore data on stdin. sometimes useful, e.g. for printing from some versions of the Acrobat Reader. 😭 (we've all been there)
  • -F β€” hide the File-Tab if a file is given at the command-line.
  • -U user β€” the name of the cups-User to use. πŸ™‹
  • -# n β€” make n copies per default. yes bestie, multiple copies. πŸ”₯
  • -n n β€” the same as -#. ✨
  • -H β€” Help. πŸ†˜
  • -C β€” force console-mode. no GUI, just vibes.
  • -o option=value β€” specify extra options, same syntax as lpr.
  • -E β€” forces encryption when connecting to the server. πŸ”’
  • -q priority β€” specify the priority of the print job, from 1 (lowest) to 100 (highest). go big or go home. πŸ’…
  • -t jobname β€” specify the jobname. name your baby. 🍼
  • -J jobname β€” the same as -t.

if you call it as lp, these options differ from GtkLP's options πŸ‘€

  • -X β€” force X-Mode, even if GTKLP_FORCEX is not set to 1.
  • -P page-list β€” specifies which pages to print in the document. the list can contain a list of numbers and ranges (#-#) separated by commas (e.g. 1,3-5,16). πŸ—’οΈ
  • -H handling β€” specifies when the job should be printed. a value of immediate will print the file immediately, a value of hold will hold the job indefinitely, and a time value (HH:MM) will hold the job until the specified time. (does this option work ?) πŸ’€ β€” yes, that's genuinely in the original, I'm not making it up, the manpage itself is unsure.

if you call it as lpr, these options differ from GtkLP's options 🌸

  • -X β€” force X-Mode, even if GTKLP_FORCEX is not set to 1.
  • -C jobname β€” specify the jobname.
  • -T jobname β€” the same as -C.
  • -p β€” specifies that the print file should be formatted with a shaded header with the date, time, job name, and page number. this option is equivalent to -oprettyprint and is only useful when printing text files. πŸŽ€
  • -l β€” specifies that the print file is already formatted for the destination and should be sent without filtering. this option is equivalent to -oraw. 🧚
some other options from systemv's lp and berkeley's lpr are ignored without error message. (silently ignored. no warning. she just doesn't hear you. iconic, honestly.)

✨ PATHS ✨

GtkLP looks for config-files under

<configdir>

then under

$HOME/.gtklp/

and at last under

/etc/gtklp/.

that's the search order, bestie, in that exact order. πŸ”

to hide Printers from users, use the following pathes:

/etc/gtklp/accept/
/etc/gtklp/deny/
$HOME/.gtklp/

just put an empty file with the name of the printer the user should see by default to accept, put an empty file with the name of the printer the user should never see to deny. 🚫

  • if only accept exists, all but the accepted printers are allowed.
  • if only deny exists, all but the denied printers are accepted.

all users can deny accepted printers, but they can't unhide denied ones. (you can hide, but you cannot un-hide. the rules are the rules.) πŸ‘‘


✨ SPECIAL ✨

in GtkLP you can define a browser to open the help URL, the CUPS-Homepage and so on. just use your favorite HTML browser. 🌐 the first $1 in command-line will be substituted by the URL. πŸͺ„

if you can't connect to an X-Server, GtkLP acts as console-lpr. πŸ’€βž‘οΈπŸ’…

if called as lpr, or lp, GtkLP acts on console and has some other command-line parameters, see above. πŸ‘†


✨ VARIABLES ✨

you can set the following environment variables to influence the behaviour of GtkLP:

  • CUPS_SERVER β€” the default CUPS-server to connect to. πŸ–₯️
  • IPP_PORT β€” the default Port of the CUPS-server to connect to. πŸšͺ
  • PRINTER β€” the default printer to use. πŸ–¨οΈ
  • GTKLP_FORCEX β€” set to 1 to force X-Mode for lpr and lp. πŸ’₯

✨ ERROR ✨

GtkLP produces the following Error-Codes:

  1. 0 β€” normal program termination. βœ… everything slayed.
  2. 1 β€” small error, wrong parameters, etc. πŸ™ˆ a little oopsie.
  3. 2 β€” Server Problems, server not found, no default printer found, etc. 😭 the server ghosted you.
  4. 3 β€” BAD error. Fields declared too short, too many printers, etc. πŸ’€ this one is the real one. respect it.

✨ SEE ALSO ✨


this program was written by T. Mueller, 2000, 2001, 2002. πŸ“œ

it is licensed under the Terms of the GNU GENERAL PUBLIC LICENSE, see also http://www.gnu.org. πŸ›οΈ


✨ CONTACT ✨

the latest version of GtkLP is always available under http://gtklp.sourceforge.net/ 🌟

feel also free to contact me. please mail also, if you like the software !!! ;-) πŸ’Œ


and that's the whole page, bestie!! go forth and print responsibly βœ¨πŸ–¨οΈ

β€” Tobias Mueller, and this little manual is gtklp(1) πŸŽ€ πŸ’– πŸ¦‹

πŸ“¦ where this page comes from