Printing booklets

I often find myself wanting to print some small article or manual for reading. But I like to save paper: print everything in two sides and fit multiple pages per side. One way to do that is printing everything in order, but the better way is to order the pages so you can fold the printed leaves and make a small nice-looking booklet.

But how do you do that? Myself, I have this small script that handles the work, based on popular unix pstools. Here is it:

## Script for printing booklets. just call with your pdf file as argument, and it generates and
## First send to printer, then move the pages back to the input tray, and send
## by Nicolau <>
pdftops -expand -paper A4 $1 /tmp/
psbook < /tmp/ | psnup -2 | psselect -er >
psbook < /tmp/ | psnup -2 | psselect -o >

First of all the script converts the input file (assumed to be a pdf!) to postscript, and saves the result in /tmp. I’ve been needing to use this -expand option lately, otherwise the pages get reduced in some situations for some reason. After that we use the formidable psbook program to rearrange the pages for booklet printing. This is the program that does the most complicated work.

To actually print the output of psbook we need to call psnup to fit the pages into the leaves, and then select first the even pages then the odd pages for printing in the front and back side of the paper. In printers that can make two-sided printing automatically you only need to send the output of psnup directly… But in most non-advanced printers you need to print this first file, then move the paper to the input tray (preserving the “upwards” orientation of the pages) then send the next file. In my printer I do this and then I can pick up the output and immediately fold and bind. Beware that some printers might mess with the orientation and page order, so you have to check out how things are in your network.

Have a nice reading! 🙂


One thought on “Printing booklets

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s