* Can not register the callback functions in MkIV
@ 2010-02-19 7:04 Yanrui Li
2010-02-19 12:21 ` Yanrui Li
0 siblings, 1 reply; 3+ messages in thread
From: Yanrui Li @ 2010-02-19 7:04 UTC (permalink / raw)
To: mailing list for ConTeXt users
[-- Attachment #1.1: Type: text/plain, Size: 654 bytes --]
Hi,
Now it seems that we have not allowed to register the callback functions
since beta 2010.02.18.
For example:
\startluacode
local old_pre_linebreak_filter = callback.find ('pre_linebreak_filter')
local function my_pre_linebreak_filter (head, groupcode)
if old_pre_linebreak_filter then
old_pre_linebreak_filter (head, groupcode)
end
print ('This is my pre_linebreak_callback')
return true
end
callback.register ('pre_linebreak_filter', my_pre_linebreak_filter)
\stopluacode
\starttext
This is just a test!
\stoptext
The 'my_pre_linebreak_filter' function can not work again. Is this a bug?
--
Best regards,
Li Yanrui
[-- Attachment #1.2: Type: text/html, Size: 824 bytes --]
[-- Attachment #2: Type: text/plain, Size: 486 bytes --]
___________________________________________________________________________________
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
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Can not register the callback functions in MkIV
2010-02-19 7:04 Can not register the callback functions in MkIV Yanrui Li
@ 2010-02-19 12:21 ` Yanrui Li
2010-02-19 13:05 ` Hans Hagen
0 siblings, 1 reply; 3+ messages in thread
From: Yanrui Li @ 2010-02-19 12:21 UTC (permalink / raw)
To: mailing list for ConTeXt users
[-- Attachment #1.1: Type: text/plain, Size: 851 bytes --]
2010/2/19 Yanrui Li <liyanrui.m2@gmail.com>
> Hi,
>
> Now it seems that we have not allowed to register the callback functions
> since beta 2010.02.18.
>
> For example:
>
> \startluacode
>
> local old_pre_linebreak_filter = callback.find ('pre_linebreak_filter')
>
> local function my_pre_linebreak_filter (head, groupcode)
> if old_pre_linebreak_filter then
> old_pre_linebreak_filter (head, groupcode)
> end
> print ('This is my pre_linebreak_callback')
> return true
> end
>
> callback.register ('pre_linebreak_filter', my_pre_linebreak_filter)
>
> \stopluacode
>
> \starttext
>
> This is just a test!
>
> \stoptext
>
> The 'my_pre_linebreak_filter' function can not work again. Is this a bug?
>
> --
> Best regards,
>
> Li Yanrui
>
I see. The 'pre_linebreak_filter' callback function is frozen.
--
Best regards,
Li Yanrui
[-- Attachment #1.2: Type: text/html, Size: 1299 bytes --]
[-- Attachment #2: Type: text/plain, Size: 486 bytes --]
___________________________________________________________________________________
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
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Can not register the callback functions in MkIV
2010-02-19 12:21 ` Yanrui Li
@ 2010-02-19 13:05 ` Hans Hagen
0 siblings, 0 replies; 3+ messages in thread
From: Hans Hagen @ 2010-02-19 13:05 UTC (permalink / raw)
To: mailing list for ConTeXt users
On 19-2-2010 13:21, Yanrui Li wrote:
> 2010/2/19 Yanrui Li<liyanrui.m2@gmail.com>
>
>> Hi,
>>
>> Now it seems that we have not allowed to register the callback functions
>> since beta 2010.02.18.
>>
>> For example:
>>
>> \startluacode
>>
>> local old_pre_linebreak_filter = callback.find ('pre_linebreak_filter')
>>
>> local function my_pre_linebreak_filter (head, groupcode)
>> if old_pre_linebreak_filter then
>> old_pre_linebreak_filter (head, groupcode)
>> end
>> print ('This is my pre_linebreak_callback')
>> return true
>> end
>>
>> callback.register ('pre_linebreak_filter', my_pre_linebreak_filter)
>>
>> \stopluacode
>>
>> \starttext
>>
>> This is just a test!
>>
>> \stoptext
>>
>> The 'my_pre_linebreak_filter' function can not work again. Is this a bug?
>>
>> --
>> Best regards,
>>
>> Li Yanrui
>>
>
> I see. The 'pre_linebreak_filter' callback function is frozen.
indeed as otherwise you kick out functionality; there are two user hooks:
tasks.appendaction("processors","before","modules.mine.whatever_a")
tasks.appendaction("processors","after","modules.mine.whatever_b")
as it's impossible to forsee what interference happens it will be clear
that there is no support beyonf this
Hans
-----------------------------------------------------------------
Hans Hagen | PRAGMA ADE
Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
| www.pragma-pod.nl
-----------------------------------------------------------------
___________________________________________________________________________________
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
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2010-02-19 13:05 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-02-19 7:04 Can not register the callback functions in MkIV Yanrui Li
2010-02-19 12:21 ` Yanrui Li
2010-02-19 13:05 ` Hans Hagen
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).