From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/55612 Path: news.gmane.org!not-for-mail From: Andreas Schneider Newsgroups: gmane.comp.tex.context Subject: Re: \everyaftershipout isn't "called" for every pagebreak Date: Sun, 17 Jan 2010 23:13:16 +0100 Message-ID: References: <36ACBB12-6EB5-4ED9-A7A0-70F1CDDEE50D@googlemail.com> <4B53761C.3070106@wxs.nl> <4B5384E1.5010604@wxs.nl> Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1263766468 13098 80.91.229.12 (17 Jan 2010 22:14:28 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 17 Jan 2010 22:14:28 +0000 (UTC) To: ntg-context@ntg.nl Original-X-From: ntg-context-bounces@ntg.nl Sun Jan 17 23:14:20 2010 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from balder.ntg.nl ([195.12.62.10]) by lo.gmane.org with esmtp (Exim 4.50) id 1NWdO0-0005PJ-Jz for gctc-ntg-context-518@m.gmane.org; Sun, 17 Jan 2010 23:14:20 +0100 Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 9BBB6C9C07; Sun, 17 Jan 2010 23:14:18 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (balder.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id v+TW6kpFyUnF; Sun, 17 Jan 2010 23:13:56 +0100 (CET) Original-Received: from balder.ntg.nl (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id D776DC9D15; Sun, 17 Jan 2010 23:13:55 +0100 (CET) Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 6DCA9C9D18 for ; Sun, 17 Jan 2010 23:13:50 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (balder.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id Dt7TBSwkw49D for ; Sun, 17 Jan 2010 23:13:38 +0100 (CET) Original-Received: from lo.gmane.org (lo.gmane.org [80.91.229.12]) by balder.ntg.nl (Postfix) with ESMTP id 73A6CC9D12 for ; Sun, 17 Jan 2010 23:13:38 +0100 (CET) Original-Received: from list by lo.gmane.org with local (Exim 4.50) id 1NWdNI-00059h-JK for ntg-context@ntg.nl; Sun, 17 Jan 2010 23:13:36 +0100 Original-Received: from p54b4d1d0.dip.t-dialin.net ([84.180.209.208]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 17 Jan 2010 23:13:36 +0100 Original-Received: from aksdb by p54b4d1d0.dip.t-dialin.net with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 17 Jan 2010 23:13:36 +0100 X-Injected-Via-Gmane: http://gmane.org/ Original-Followup-To: gmane.comp.tex.context Original-Lines: 57 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: p54b4d1d0.dip.t-dialin.net User-Agent: KNode/4.3.4 X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.12 Precedence: list List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: ntg-context-bounces@ntg.nl Errors-To: ntg-context-bounces@ntg.nl Xref: news.gmane.org gmane.comp.tex.context:55612 Archived-At: > dealing with multipass data in mkiv is completely different from mkii > and at some point there will be a proper api for users (makes no sense > now as i might as well change internals along with luatex developments) > > in mkiv we store info in tables and much is available during a document > run anyway (in mkii we filter data from the tuo file) so the question > is, what info do you need? it's probably easier to provide it as core > functionality > > so i need speccs and a small test file > > Hans Thanks for that info! I think for specs my "plan" is too vague. I will explain what my goal is then you either see a good solution and/or tell me that this is out of scope for now :-) The test file to demonstrate the problem is in my initial newsgroup post for this thread. I will re-attach it here. What I need would be a precise page break handling. Currently ConTeXt seems to process a whole paragraph as one object, and then breaks it down to individual pages. That leads to a problem however: I want to refine my citation style. All bibliography is inserted into footnotes. If two (or more) consecutive citations _on the same page_ refer to the same bib entry, the footnote for that citation should read "Ibidem". Therefore I have to remember the last cited entry. Currently I use \appendtoks...\to\everyaftershipout to reset/clear the variable I use for storing that last entry. That works fine as long as the paragraphs are small. If however several citations within one (possibly large) paragraph are separated by a page break, the output will be wrong, since the event to reset the variable occurs too late (see above). The problem can be demonstrated with this example - the first footnote on each page should be "New". \define\test{\doifelse{\getvalue{testvar}}{page}{% \footnote{Repeat}% }{% \footnote{New}% \setvalue{testvar}{page}% }} \appendtoks \global\setvalue{testvar}{} \to\everyaftershipout \starttext \dorecurse{10}{\dorecurse{250}{text }\test} \dorecurse{10}{\dorecurse{250}{text }\test} \stoptext Best Regards, Andreas. ___________________________________________________________________________________ If your question is of interest to others as well, please add an entry to the Wiki! maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context webpage : http://www.pragma-ade.nl / http://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________