double sided pdfs on a single sided printer

The place to post if you need help or advice

Moderators: ChrisThornett, LXF moderators

double sided pdfs on a single sided printer

Postby guy » Sat Jun 22, 2013 7:09 pm

I have lots of pdfs which are supposed to be printed double sided, but my printer is only single sided.

Easy, just print all odd sides, then turn the wad over and print all the even sides in reverse order.

Except, selecting "odd sides only" causes the Gnome(?) Document Viewer -> CUPS -> Epson printer driver chain to crash with no output. I suspect whatever package parses the pdf file for CUPS, but I'm not sure what that would be.

One way out would be to split each pdf into two, one with all the odd sides and one with all the even. There are too many to do manually, so a script would be needed.

Any ideas, either for a Debian-free tool with functional pdf print options or for said script?
"Klinger, do you know how many zoots were killed to make that one suit?" — BJ Hunnicutt
User avatar
guy
LXF regular
 
Posts: 1105
Joined: Thu Apr 07, 2005 12:07 pm
Location: Worcestershire

Postby johnhudson » Sat Jun 22, 2013 8:22 pm

The document is/should be sent as a series of pdf pages which CUPS then converts to postscript for printing.

So the problem is not a printer or a CUPS problem since, apart from rastering images, everything ends up in postscript.

The problem is the document viewer which is failing to concatenate all the odd pages before sending them to CUPS.
johnhudson
LXF regular
 
Posts: 884
Joined: Wed Aug 03, 2005 1:37 pm

Postby Dutch_Master » Sat Jun 22, 2013 10:09 pm

Try another PDF reader, like xpdf.
Dutch_Master
LXF regular
 
Posts: 2471
Joined: Tue Mar 27, 2007 1:49 am

Postby wyliecoyoteuk » Sun Jun 23, 2013 6:55 am

Actually, pdfs are already postscript.
You could use a script which parses the postscript and selects the odd then the even pages.
Cups can be set to print to a program, you need to create a virtual printer.
The sig between the asterisks is so cool that only REALLY COOL people can even see it!

*************** ************
User avatar
wyliecoyoteuk
LXF regular
 
Posts: 3466
Joined: Sun Apr 10, 2005 10:41 pm
Location: Birmingham, UK

Postby nelz » Sun Jun 23, 2013 8:06 am

pdftk splits and reassembles PDF files, it has options to split out the odd or even or any other page range) into a separate file. Reading the man page, it would appear you can use it to generate two PDFs, for the even and odd pages, and even reverse the page order in one of them.
"Insanity: doing the same thing over and over again and expecting different results." (Albert Einstein)
User avatar
nelz
Site admin
 
Posts: 8579
Joined: Mon Apr 04, 2005 11:52 am
Location: Warrington, UK

Postby guy » Sun Jun 23, 2013 10:45 am

Thanks all.

Yay, xpdf works. It seems to barf on many modern pdfs so I didn't think of it here. Works fine with my relatively simple ones for the buk of this job. Yeeks! Motif brings back memories.

If I run into trouble with the diagrams I'll take a look at pdftk.
"Klinger, do you know how many zoots were killed to make that one suit?" — BJ Hunnicutt
User avatar
guy
LXF regular
 
Posts: 1105
Joined: Thu Apr 07, 2005 12:07 pm
Location: Worcestershire

Postby guy » Sun Jun 23, 2013 12:13 pm

Update: xpdf did barf over the diagrams pdf. It couldn't cope that the pages were rotated 90 deg to print on portrait paper like the main document, and printed them non-rotated but shrunk to fit instead.

Amazingly, the Document Viewer coped with this pdf.
"Klinger, do you know how many zoots were killed to make that one suit?" — BJ Hunnicutt
User avatar
guy
LXF regular
 
Posts: 1105
Joined: Thu Apr 07, 2005 12:07 pm
Location: Worcestershire

Postby nelz » Sun Jun 23, 2013 12:26 pm

It is possible that these PDFs break the standard in some way. In that case, the solution may be as simple as doing a Print-to-PDF in the document viewer and then working with the new PDFs.
"Insanity: doing the same thing over and over again and expecting different results." (Albert Einstein)
User avatar
nelz
Site admin
 
Posts: 8579
Joined: Mon Apr 04, 2005 11:52 am
Location: Warrington, UK


Return to Help!

Who is online

Users browsing this forum: No registered users and 0 guests