From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/915 Path: main.gmane.org!not-for-mail From: ecashin@coe.uga.edu (Ed L. Cashin) Newsgroups: gmane.comp.tex.context Subject: Re: seeking ConTeXt code Date: 13 Sep 1999 16:33:02 -0400 Sender: owner-ntg-context@let.uu.nl Message-ID: References: <37D41559.1124304E@wxs.nl> <37D61A5C.771BF52E@wxs.nl> NNTP-Posting-Host: coloc-standby.netfonds.no Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: main.gmane.org 1035391759 28297 80.91.224.250 (23 Oct 2002 16:49:19 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Wed, 23 Oct 2002 16:49:19 +0000 (UTC) Cc: ntg-context@ntg.nl Original-To: Hans Hagen Xref: main.gmane.org gmane.comp.tex.context:915 X-Report-Spam: http://spam.gmane.org/gmane.comp.tex.context:915 Hans Hagen writes: > Hi Ed, [Ed wrote:] > > > > * quire collation (for booklet-style pagination but without > > > > post-processing) ... > This concerns \stelarrangerenin or \setuparranging [Ed wrote:] > > Is it hard to do? Basically, I'm interested in taking a document with > > dynamically-generated context (so I won't know beforehand how many > > pages there are) and making it have pages ready for double-sided > > front-and-back printing, as if I ran my LaTeX "[twosided]" document > > through the psutils' psbook and "psnup -n 2". > > There are two ways to do this: > > (1) while typesetting > (2) afterwards > > Actually (2) comes down to (1) where each page is pasted in as a figure. > This feature is built in texexec: texexec --pdfarrange --paper=a4a5 > --pdf --print=up yourfile.pdf Just to make sure I'm following you, are you saying that 2 is done with the command, texexec --pdfarrange --paper=a4a5 --pdf --print=up yourfile.pdf ... ? I tried that; and I'll refer to this method later as the "--pdfarrange" method. > Method 1 is the most natural one because there the typesetting is tuned > to the natural paper size. You pick up a paperformat and map it onto a > print format. Then you set up the arrangement. The next sample is from > the manual ( > > \setuppapersize [A7][A3] > \setuparranging [2*8,rotated,doublesided] > \setuppagenumber [alternative=doublesided] > \setuplayout [margin=0pt,width=fit] > \setupbackgrounds [text][text][background=screen] > \setupcolors [state=start] > \setuplayout [location=middle,marking=color] > \setuptolerance [tolerant] > \setupbodyfont [6pt] > > \starttext > \dorecurse{30}{\input tufte \par \input knuth \par} > \stoptext I have been playing with this, and it seems to work, but it is has a much longer execution time compared to, e.g., psbook. It seems that the "--pdfarrange" method is significantly faster. Is that what you'd expect? > Now, the main problem is that arrangement takes place in the last > stage. This means running with the arrangement commented and then > run a last one with the arrangement. The reson behind this is that > otherwise all the references and indexes and lists get spoiled (page > 5 can be output before page 1). I haven't been using documents that have references and lists in my experiments. Are you saying that the --pdfarrange method will generate documents with incorrect indices, references, etc.? > When you use a5 on a4, you can use texexec. Just set up your document > for a5, and run texexec: > > texexec --paper=a5a4 --print=up yourfile > > will run context untill all refs are sorted out, and then apply a last > pass doing the reshuffel. > > I can add a feature to texexec (--arrange) that does the 'commenting' > (sort of), so that one has full controll in the source. I'll give this > some thought. What would be the advantage of the texexec --arrange option versus putting the pagination commands in the source? I noticed that a while back Taco Hoekwater posted to the pdftex list a method that consisted of just directly noodling with the page number order in the PDF document itself. You warned that the number of bytes has to stay the same, but it sounded like it would work. That wouldn't work in this case, would it? I'm putting the pages 2 per sheet of paper. > Concerning the manual, we will start uploading soon on a chapter by > chapter base. The first 4 chapters are in typesetting stage (chapter 4 > is what you need). Whoo!! That is very good news! -- --Ed Cashin ecashin@coe.uga.edu