summaryrefslogtreecommitdiff
path: root/tex/context/base/mkxl/node-tsk.lmt
diff options
context:
space:
mode:
Diffstat (limited to 'tex/context/base/mkxl/node-tsk.lmt')
-rw-r--r--tex/context/base/mkxl/node-tsk.lmt52
1 files changed, 52 insertions, 0 deletions
diff --git a/tex/context/base/mkxl/node-tsk.lmt b/tex/context/base/mkxl/node-tsk.lmt
index 61e5bc0d4..c12c9597e 100644
--- a/tex/context/base/mkxl/node-tsk.lmt
+++ b/tex/context/base/mkxl/node-tsk.lmt
@@ -952,3 +952,55 @@ nonut = [[
--
-- }
-- }
+
+-- -- localboxes -- --
+
+tasks.new {
+ name = "localboxes",
+ processor = nodeprocessor,
+ sequence = {
+ "before", -- for users
+ "lists",
+ "after", -- for users
+ },
+ templates = {
+
+default = [[
+return function(head)
+end
+]],
+
+process = [[
+local tonut = nodes.tonut
+local tonode = nodes.nuts.tonode
+
+%localize%
+
+-- line,leftbox,rightbox,linenumber,leftskip,rightskip,lefthang,righthang,indent,parfillleftskip,parfillrightskip
+
+return function(line,leftbox,rightbox,...)
+ nutline = tonut(line)
+ nutleftbox = leftbox and tonut(leftbox)
+ nutrightbox = rightbox and tonut(rightbox)
+%actions%
+end
+]],
+
+step = [[
+ tonut((%action%(line,leftbox,rightbox,...)))
+]],
+
+nut = [[
+ %action%(nutline,nutleftbox,nutrightbox,...)
+]],
+
+nohead = [[
+ %action%(line,leftbox,rightbox,...)
+]],
+
+nonut = [[
+ %action%(nutline,nutleftbox,nutrightbox,...)
+]],
+
+ }
+}