Skip navigation.
KDE Developer's Journals

KDEPrint/kprinter in KDE3: automatically displayed tab if "poster" utility is found in $PATH

pipitas's picture
| | |
KDEPrint/kprinter in KDE3: automatically displayed tab if "poster" utility is found in $PATH

.

The poster tab of kprinter will *NOT* display if you don't have the "poster" utility installed and in your $PATH.

Obtain "poster" from here: printing.kde.org/downloads/.

Important: you need to use the version from the link above, should your distro's version not function properly! It contains some patches to make it work with KDEPrint (poster's commandline abilities don't suffer from these patches!). The patches (written by our deerly missed Michael Goffioul, who currently does have too little time for active KDEPrint development) have also been accepted by the upstream poster developer, years ago.

Unfortunately, some recent distro releases (Debian?, *buntu?) for some reason ship an older release, which makes the kprinter poster tab display an error message.

As soon as you install a patched version (compiling it is easy), kprinter will work with it.

If you find this is the case for your distro, you should contact its respective packager and/or submit a bug report. Ask them to use the patched version of poster to make it work with KDE.

Poster is meant to scale up a printout beyond available media sizes of your printer. You print small tiles of the final image (you do not even need to print all of them, as the line "tiles to be printed" shows). These pages you can glue together to form a "poor man's poster".

The actual printouts will slightly overlap, in order to allow some minor image shifting by the actual print devices, and by the person who uses scissors or cutters to trim the paper sheet towards the actual page image.

  • Above screenshot shows what you can tweak with the settings.
  • Determine the final poster size by selecting from the drop down listbox.
  • Determine the size of the printouts as "Page Size" on the "General" tab.
  • The number of tiles shown dynamically adapts to these size selections.
  • To select which tiles you want at all use the mouse and hold the shift key.
  • Printout will occur in the order you clicked the tiles.
  • Alternatively, just type a comma-separted list of tile numbers into the line edit field.
  • Change the "Cut Margin" as needed.

Tip 1: to not waste too much paper with experiments whose results you do not like, you may first want to "Print to File (PDF)" by selecting a different printer in the first place.

Or enable the checkbox "Preview" on the main kprinter dialog, and cancel the printout if the preview doesn't look like you expect; then try again with different settings.

How it works "under the hood": poster is utilized as a "prefilter" by KDEPrint. When KDEPrint receives a PostScript for printing (as is the case when you print from any KDE3 application), it sends this file to poster first, using appropriate commandline options (which you do not need to know if you use the GUI shown in the screenshot -- they are a bit awkward), receives the pre-filtered file from poster and sends it on to the real print subsystem (or to the preview application you may be using).

What you can do when it doesn't seem to work...

The utility and the kprinter tab do also work if you start kprinter as a standalone application (i.e. not from the 'Print...' menu entry of an application) and load a PostScript file into it.

However, if you start kprinter standalone, but load a non-PostScript file (text, image, PDF), and use "poster" on it, you may see an error message, or it may simply not work as expected. If you are lucky, you'll see a dialog pop up that asks if

Why is this?

The poster utility can only work with PostScript files and does require PostScript as input format.

Is there no hope then?

Yes, there is.

Just plug one more pre-filter into the pre-filtering chain of KDEPrint! One that creates the PostScript and feeds it to 'poster'. Eye-wink

How to do that?

Click on the right-most tab, labelled "Filters". Click on the top icon showing a funnel symbol. Select a pre-filter from the top-down list that takes your loaded input format, and converts it into PostScript:

  • "Generic Image to PS Filter",
  • "PDF to PostScript Converter", or
  • "Enscript Text Filter"

Make sure the stacking order of the two pre-filters (the "Poster" one may be active already)
is as needed. (If it's wrong, you'll see a unequivocal complaint in the user interface -- you can sort the order with the help of the "Up" and "Down" arrows.)

Tip 2: The "Preview" checkbox is not available, if you run kprinter from the commandline. If you are not confident about the results that will go on paper, and if you don't want to waste precious resources, you may want to "Print to File" first instead of the real printer. Then you can verify if the result comes at least close to what you expect by using KPDF to view it (KPDF also works with PostScript files, should you have printed to PS).

Tip 3: While the "Preview" checkbox is not there, another one is, when you run kprinter from the commandline: it is on the bottom left corner of the dialog, labled "Keep this dialog open after printing", and does what it says. So as long as you are experimenting with the different print settings, you do not need to restart kprinter every time you want to change an option....

Voila! Poster printing with KDE.
From any KDE application.
To any print device.
Even to the "PDF printer" that ships with KDE.
And also for any printable file format (PDF, image, PostScript, text),...
...when loaded into a kprinter started from the commandline if you don't forget to enable a PostScript producing pre-filter that consumes your original file and pipes its PS output into the Poster pre-filter...

How do you like that?

(And all this works in KDE since the days of KDE 2.2, released more than 6 years ago. But unfortunately, it was never really documented, remains a rather unknown little gem within KDEPrint, and in general is pretty under-appreciated.)