diff options
author | Hans Hagen <pragma@wxs.nl> | 2007-08-07 01:37:00 +0200 |
---|---|---|
committer | Hans Hagen <pragma@wxs.nl> | 2007-08-07 01:37:00 +0200 |
commit | aacdde41ef02392949aee16b2e428a8913d27efe (patch) | |
tree | 1ca125418e41b0335ee115a24cf27acb8fa7eae9 /tex/context/base/core-uti.lua | |
parent | dbcaab8b8f76309b9fc4e05bf8a42f6b56e61893 (diff) | |
download | context-aacdde41ef02392949aee16b2e428a8913d27efe.tar.gz |
stable 2007.08.07 01:37
Diffstat (limited to 'tex/context/base/core-uti.lua')
-rw-r--r-- | tex/context/base/core-uti.lua | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/tex/context/base/core-uti.lua b/tex/context/base/core-uti.lua new file mode 100644 index 000000000..00811e528 --- /dev/null +++ b/tex/context/base/core-uti.lua @@ -0,0 +1,29 @@ +if not modules then modules = { } end modules ['core-uti'] = { + version = 1.001, + comment = "companion to core-uti.tex", + author = "Hans Hagen, PRAGMA-ADE, Hasselt NL", + copyright = "PRAGMA ADE / ConTeXt Development Team", + license = "see context related readme files" +} + +--[[ldx-- +<p>A utility file has always been part of <l n='context'/> and with +the move to <l n='luatex'/> we also moved a lot of multi-pass info +to a <l n='lua'/> table. Instead of loading a <l n='tex'/> based +utility file under different setups, we now load a table once. This +saves much runtime but at the cost of more memory usage.</p> +--ldx]]-- + +if not jobs then jobs = { } end +if not job then jobs['main'] = { } end job = jobs['main'] +if not job.variables then job.variables = { } end + +--[[ldx-- +<p>Variables are saved using in the previously defined table and passed +onto <l n='tex'/> using the following method. Of course one can also +directly access the variable using a <l n='lua'/> call.</p> +--ldx]]-- + +function job.initializevariable(cs,value) + tex.sprint("\\xdef\\"..cs.."{"..value.."}") +end |