From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/58003 Path: news.gmane.org!not-for-mail From: "Wolfgang Werners-Lucchini" Newsgroups: gmane.comp.tex.context Subject: Re: callback.register Date: Fri, 09 Apr 2010 11:59:17 +0200 Message-ID: <4BBF1695.7921.2D7D43@wwl.musensturm.de> References: 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: dough.gmane.org 1270807061 24891 80.91.229.12 (9 Apr 2010 09:57:41 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Fri, 9 Apr 2010 09:57:41 +0000 (UTC) To: ntg-context@ntg.nl Original-X-From: ntg-context-bounces@ntg.nl Fri Apr 09 11:57:40 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.69) (envelope-from ) id 1O0Ay4-0006qC-G3 for gctc-ntg-context-518@m.gmane.org; Fri, 09 Apr 2010 11:57:40 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id E6007C9CC8; Fri, 9 Apr 2010 11:57:39 +0200 (CEST) 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 k-Nwrm9njKX8; Fri, 9 Apr 2010 11:57:26 +0200 (CEST) Original-Received: from balder.ntg.nl (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id CAAF3C9CA0; Fri, 9 Apr 2010 11:57:26 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id DC630C9CA0 for ; Fri, 9 Apr 2010 11:57:25 +0200 (CEST) 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 JDv5SXziE855 for ; Fri, 9 Apr 2010 11:57:14 +0200 (CEST) Original-Received: from moutng.kundenserver.de (moutng.kundenserver.de [212.227.17.8]) by balder.ntg.nl (Postfix) with ESMTP id 73A00C9C90 for ; Fri, 9 Apr 2010 11:57:14 +0200 (CEST) Original-Received: from [192.168.178.23] (p4FC79461.dip0.t-ipconnect.de [79.199.148.97]) by mrelayeu.kundenserver.de (node=mreu1) with ESMTP (Nemesis) id 0LeyNP-1NA0kY2QpD-00ptRO; Fri, 09 Apr 2010 11:57:13 +0200 Priority: normal In-reply-to: X-mailer: Pegasus Mail for Windows (4.41, DE v4.41 R1) Content-description: Mail message body X-Provags-ID: V01U2FsdGVkX18gmxy7L7Vt7x+/pbn3PGo9XMXYHaRqqgK19Xd Dsm9z1wKKYjVdT3pTEfNe82j/w6qAF9hvJnabDVx40Y1H3fz1Y FOz/ULkpYJaDrSRL6V6kg== 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:58003 Archived-At: > > I tried the following > > > > -------------------------------------- > > \starttext > > \startluacode > > local OldPreLB > > > > function MyPreLB(head,gc) > > ?texio.write_nl("########### Here I am!") > > ?OldPreLB(head,gc) > > end > > > > OldPreLB = callback.find('pre_linebreak_filter') > > callback.register('pre_linebreak_filter',MyPreLB) > > \stopluacode > > > > Test > > \stoptext > > -------------------------------------- > > > > but MyPreLB() is not called. > > What I am doing wrong here? > > Hi Wolfgang, > > see http://www.ntg.nl/pipermail/ntg-context/2010/047018.html > > -- > Best regards, > > Li Yanrui (???) I see! >From the info found there ----------------------------------------- there are two user hooks: tasks.appendaction("processors","before","modules.mine.whatever_a") tasks.appendaction("processors","after","modules.mine.whatever_b") ----------------------------------------- it is not clear for me how to use this. So it seems that the luatex reference is useless for a context user. Is there an other documentation on this? I have found an other mechanism in 'luat-cbk.lua' which offers a pair of functions 'callbacks.push()' and 'callbacks.pop()'. But I have not made any attempts to use them. Are they useable or are they disabled too? Wolfgang ___________________________________________________________________________________ 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 ___________________________________________________________________________________