Getting booklet printing working is proving more difficult than expected, even for just 4 pages. I have successfully used geometry to define an unusual paper size: A4 portrait halved from top to bottom. Then I add the booklet commands, and it combines pages 4 and 1 as expected onto a single A4 portrait page. But then page 2 is produced on its own, and then two blank pages. Page 3 is missing.
The same happens when I try A4 pages being reduced to A5 for a landscape booklet, so I don't think it's a result of my odd paper size. I've followed advice in this answer and put \setpdftargetpages after the preamble.
(I know about multicol and the like, but as far as I cant tell that can't generate two-sided printing of sheets that can just be folded into booklets.)
MNWE:
\documentclass[14pt,onecolumn]{memoir}
\title{Booklet printing test}
\usepackage{lipsum}
\marginparsep = 0pt
\marginparwidth = 0pt
\headsep = 0pt
\footskip = 0pt
\usepackage[showframe,paperwidth=10.5cm,paperheight=29.7cm,includeheadfoot,includemp,textwidth=9.5cm,textheight=27cm]{geometry}
\usepackage[print,four,twouparticle]{booklet}
\source{\magstep0}{\paperwidth}{\paperheight}
\target{\magstep0}{21cm}{\paperheight}
\begin{document}
\ifpdf
\pdfoutput = 1
\setpdftargetpages
\else
\setdvipstargetpages
\fi
\maketitle
\subsection{One}
\lipsum[2]
\newpage
\subsection{Two}
\lipsum[4-5]
\newpage
\subsection{Three}
\lipsum[6-7]
\newpage
\subsection{Four}
\lipsum[8]
\end{document}
bookletis essentially incompatible withgeometry. The documentation explains how to resolve the issue but it has never worked for me. One workaround usedgeometryin the initial stage and thenbookletonly. That no longer works for me so I developed a solution independent ofbookletwhich I explain in that answer, along with the failed, earlier solution. I do not currently know of a better answer though I am sure there must be one! – cfr Jun 01 '14 at 22:55a5paper, then assemble the pages thus produced in an a4 document, withpdfpagesand the\includepdfcommand. – Bernard Jun 01 '14 at 23:35pdfpages?pdfjamjust wrapspdfpagesanyway, I believe. Bernard's comment is essentially the basis of the answer I linked to in mine: compile the document to whatever size you like (A5 portrait in my case) and then usepdfpagesin a wrappertexdocument to create the signatures and prepare for printing onto whatever paper size (A4 landscape in my case). For example\includepdf[pages=-,nup=1x2,landscape,signature=4]{firststagepdf}for a 4 page signature. – cfr Jun 02 '14 at 01:53geometry(namely "If you are making any changes to the values of\paperwidthor\paperheight, say through the geometry package or the memoir class, then the booklet package must be called after those changes have been made. In this case you may have to specify a different\sourcethan usual, but I think that this is probably unlikely.") and put thebookletcommands aftergeometry. But thank you for confirming that you have issues too. – JGC Jun 02 '14 at 09:58pdfpagesapproach looks suitable, but would require a change in my workflow which I'd prefer to avoid. So, further answers still welcome! – JGC Jun 02 '14 at 10:01bookletrather than fixing the issues.) However, after struggling for hours with it, I finally decided a change to my workflow was much less hassle. I really hope you get an answer which avoids this since I can then adopt it and go back to a single source file. (I think hoping for a single pass of LaTeX may be unrealistic but that does depend on content. I tend to have cross references and citations which rule that out.) – cfr Jun 02 '14 at 14:29