1if not modules then modules = { } end modules ['node-pag'] = {
2 version = 1.001,
3 comment = "companion to node-pag.mkiv",
4 author = "Hans Hagen, PRAGMA-ADE, Hasselt NL",
5 copyright = "PRAGMA ADE / ConTeXt Development Team",
6 license = "see context related readme files"
7}
8
9
10
11
12
13pagebuilders = pagebuilders or { }
14
15local starttiming, stoptiming = statistics.starttiming, statistics.stoptiming
16
17local actions = nodes.tasks.actions("pagebuilders")
18
19local function processor(head,groupcode,size,packtype,maxdepth,direction)
20 if head then
21 starttiming(pagebuilders)
22 head = actions(head,groupcode,size,packtype,maxdepth,direction)
23 stoptiming(pagebuilders)
24 end
25 return head
26end
27
28callbacks.register("pre_output_filter",processor,"preparing output box")
29
30statistics.register("output preparation time", function()
31 return statistics.elapsedseconds(pagebuilders)
32end)
33 |