Author Archives: qsf

Printing a booklet on a Mac

I had a 47-page PDF document that I wanted to turn into a compact A5 booklet – you know, one of those things where you get out the big stapler and make something like this:

Unfortunately, you need to print page 39 on the same page as page 10, and then pages 40 and 9 on the other side, etc, and when you get to anything more than about 4 pages it’s hard and tedious to do this by hand and get it right. My HP printer driver had a ‘booklet’ facility, and it worked OK for 8 pages, but let me down when given any more.

Now, there are utilities you can buy which can do exactly this, but why would I spend a tenner or two when I could instead use a few otherwise lucrative working hours and build one myself?

So here’s my solution, which could be a lot tidier, but does the only tricky bit of the job: getting the pages in the right order. It’s an Automator script which you can run as a service: once installed, you can right-click on a PDF and select Services, and you should find a ‘Make Booklet PDF’ option. It produces a new PDF on your Desktop with appropriately shuffled pages. You can then just print that using Preview as follows:

  • Go into the Layout section of the Print dialog.
  • Select Two-Sided Printing
  • Set Pages per Sheet to ‘2’
  • Set the ‘Two-Sided’ option to ‘Short-Edge Binding’

Now, please note: You should understand how this works before trying it! It’s not complex, and I could have made it much prettier and self-explanatory, but I was using Automator, which is so far from a real programming language as to be frustrating. It does, however, have a few useful ways of manipulating PDFs without having to install anything else, and my script will at least prompt you with some of the following information when you run it.

(Note too that if you’re reading this in 2022 or later, you definitely want to continue on to read the updates at the bottom of the post!)

OK,

  • First, the number of pages in your starting PDF must be a multiple of 4. Fortunately, you can easily append blank pages in Preview if needed. Select the last page and choose ‘Edit > Insert > Blank Page’ as often as needed and then save. The script will warn you if your page count isn’t right.

  • Then when you run the script, it will create a folder called ‘booklet-pages’ on your desktop. In here, it will create one PDF for each page of your document.

  • Finally, it will work out what order these pages should be in, and create a new ‘booklet.pdf’ on your desktop with the pages reassembled in that order.

  • You can then delete the ‘booklet-pages’ folder.

So, here’s a zip file containing the Automator script. You should be able to double-click it and open it in Automator if you want to see what’s inside, but I think if you put it into your ~/Library/Services folder within your home directory, it will probably just appear as a service if you right-click on a PDF file in the Finder.

Make Booklet PDF on desktop.zip (for pre-Monterey Macs)

Hope it’s useful to someone! Sorry I can’t provide any support if you try it, but recommendations and improvements are welcome from anybody with more Automator stamina than me! All I can say is that it works nicely on my Mac running High Sierra (10.13.6).

Some updates: please read these when you’ve read all of the above

Update:

If you’re doing this kind of thing, you may also like a video of MacOS PDF tips and tricks, which I made back in 2016 but which people still say they find useful.

Update April 2022:

MacOS version 12.3 and onwards doesn’t include Python 2, on which this script depended, and, while it does include Python 3, Apple haven’t updated Automator to make the switch quite as trivial as it should be! However, I’ve created an updated version which works on my Mac; I hope somebody can confirm that it works for them too! (See below.)

Update June 2022

The new version of the ZIP file below tries harder to find a copy of Python 3 on your computer.

For MacOS 12.3 and later:

  • Download this ZIP file: Make booklet PDF on desktop – 2022b.zip.
  • Your browser may uncompress this for you; if not, then double-click on the ZIP file to reveal the ‘Make booklet PDF on desktop’ workflow inside.
  • Double-click on this and you should be asked if you want to install it as a ‘Quick action’
  • This will then be copied into your ~/Library/Services folder as mentioned above, and you should find it in the ‘Quick actions’ submenu if you right-click on a PDF.

Update Sept 2023

Some people were seeing a final PDF that was blurry. I’ve changed the way the individual pages are combined back into a single PDF, which should fix this. It works on my Mac running Ventura 13.5.

For MacOS 13 and later:

The Hors-d’Oeuvre Test

Step aside Myers-Briggs! Here’s my latest psychoanalytical tool, for distinguishing between two fundamentally different types of personality.

When your subject is offered a food item that they don’t recognise, do they say:

  • Ooh – that looks interesting – thanks!

or

  • Mmm… Err… What is it?

Ponder that for a moment. I think we can agree — ignoring for a moment the statistical noise introduced by actual allergies — that this simple test reveals a great deal about how someone approaches life in general.

It’s certainly, I would suggest, something you should check with a potential fiancé before dropping the big question, for example.

And when recruiting key personnel for your next startup, I suspect this simple test may be more effective and revealing than many more formal recruitment methods.

But even if not, you’ve got to admit it’s a lot more pleasurable…

Long-Stay Parking

A garage at Oradour-sur-Glane

Eyes in the back of my head

Just before Christmas, Tilly (my spaniel) and I went to the Dordogne and back in our campervan. I made a video about it, which, while it may be of interest only to travel vlog and ‘van life’ enthusiasts, does have a bit of novelty value, because I filmed it on a spherical (360-degree) camera.

This means that after you’ve watched it, you can go back and watch it again from a completely different angle and see what was happening behind you!

I’ll put the link here, rather than embedding it, because this is something you want to watch on the YouTube site. Or, better still, in the YouTube app on your tablet, or phone, or VR headset…

You can find the video here.

If I had had more time, I would have made it shorter 🙂

This was really just an experiment for me, and I learned a great deal about the challenges and opportunities of filming and editing this particular medium, which I may write about in due course.

Maccents

Having recently come back from France, I’ve been typing a lot more characters with accents on them than I usually do! For common European accents, this is really easy to do on the Mac, but I confess that, for many years, I didn’t know the trick until a friend showed me.

So in case you’re of the anglophone persuasion and you’ve missed it too, let me enlighten you: all you have to do is hold down the appropriate key on the keyboard, and a little menu pops up; you can select the variant you want by clicking on it, or by typing the associated number.

Safe harbour

Newhaven this morning, shortly after I disembarked from the Dieppe ferry.

What a difference a day makes…

The sky over my campsite yesterday morning; I hadn’t seen any blue up there for quite some time!

Camping Lune-sur-le-Lac

And the sky over the same campsite as I returned to it in the evening:

Camping Lune-sur-le-Lac

My pitch was just under the darkest bit at the bottom right.

It soon settled down to the standard grey rainclouds again afterwards, though!

Ode to a blustery winter campsite in the Dordogne

It’s good to know,
As the north winds blow,
That there’s plenty of eau,
And the eau is chaud.

Disdain

Tree-couleurs

I’m in the valley of the Vézère river, just north of the Dordogne. It’s been raining almost all day, but the moisture really adds vibrance to the splendid colours of the trees.

Fangorn

We met some local residents…

No, really! I’m very ferocious too!

Then we had a final brief pause in the rain, just in time for a dog-walk just before sunset.

Tout va bien ici. Pour moi, at least

Tilly (my spaniel) and I are in a very nice restaurant not far from Perigueux. We’re the only ones here, having walked over from the campervan, which is parked in an almost-empty campsite. Over the last couple of days, we’ve visited many very pretty villages, where almost everything has been closed. Not a petit-déjeuner or a café-au-lait to be had anywhere.

Now, I presumed this was just because of the time of year and because temperatures have been below zero for several days, only creeping above it today in order to allow for a steady rain.

But the proprietor doesn’t blame the climate, he blames the ‘gilets jaunes’. Normally, he says, there are visitors, including English and Germans, throughout the year. But they’ve seen the news, and they’re staying away. “Bordeaux aujourd’hui…”, he says, “c’est une catastrophe”.

I’ve seen a few protestors. At Dieppe on Weds, they were stopping all the lorries at several roundabouts, but I was always waved through with a cheery smile. Near Limoges today, they seemed just to be acting as traffic policemen, directing the traffic to make their presence felt. The only things I’ve seen burning were needed to warm frozen fingers.

Away from the big cities, I’ve seen nothing except the most mild expressions of discontent, like this decoration of a hydrant in a small farming village:

Roughly translated, it says, “Father Christmas’s sleigh runs on diesel.. a too-expensive fuel. No presents this year.”

So, no, this probably wouldn’t have been the week to visit any big cities. But in the countryside, visitors are currently a scarce resource and so are particularly welcome. If there’s anybody still around to do the welcoming, that is..

A quarter-century of coffee pots…

The Dutch RTL News programme did a short piece last week on the fact that the webcam was now about 25 years old.

They interviewed me for just a few minutes, after, ironically, having to spend about 45 mins getting their Skype working.

If, like me, you don’t speak any Dutch, you can hear me at about 0:16 and 1:24, and, in between the two, see some pictures of a much younger me!

© Copyright Quentin Stafford-Fraser