summaryrefslogtreecommitdiff
path: root/tex/context/base/mkiv/strc-usr.lua
diff options
context:
space:
mode:
authorHans Hagen <pragma@wxs.nl>2019-02-22 20:29:46 +0100
committerContext Git Mirror Bot <phg@phi-gamma.net>2019-02-22 20:29:46 +0100
commit7b271baae19db1528fbe6621bdf50af89a5a336b (patch)
tree4fc24a8f2be20aa90e90f6e1bcb62d69f4946235 /tex/context/base/mkiv/strc-usr.lua
parent67b9965fe473d18f13ed4c40f1e4e008eb870322 (diff)
downloadcontext-7b271baae19db1528fbe6621bdf50af89a5a336b.tar.gz
2019-02-22 19:43:00
Diffstat (limited to 'tex/context/base/mkiv/strc-usr.lua')
-rw-r--r--tex/context/base/mkiv/strc-usr.lua29
1 files changed, 29 insertions, 0 deletions
diff --git a/tex/context/base/mkiv/strc-usr.lua b/tex/context/base/mkiv/strc-usr.lua
new file mode 100644
index 000000000..f121fe296
--- /dev/null
+++ b/tex/context/base/mkiv/strc-usr.lua
@@ -0,0 +1,29 @@
+if not modules then modules = { } end modules ['strc-usr'] = {
+ version = 1.000,
+ comment = "companion to strc-usr.mkiv",
+ author = "Wolfgang Schuster",
+ copyright = "PRAGMA ADE / ConTeXt Development Team",
+ license = "see context related readme files"
+}
+
+-- The following is copied from \type {tabl-xtb.lua} to make the userdata environment
+-- work with \LUA\ documents.
+
+local context = context
+local ctxcore = context.core
+
+local startuserdata = ctxcore.startuserdata
+local stopuserdata = ctxcore.stopuserdata
+
+local startcollecting = context.startcollecting
+local stopcollecting = context.stopcollecting
+
+function ctxcore.startuserdata(...)
+ startcollecting()
+ startuserdata(...)
+end
+
+function ctxcore.stopuserdata()
+ stopuserdata()
+ stopcollecting()
+end