From aacdde41ef02392949aee16b2e428a8913d27efe Mon Sep 17 00:00:00 2001 From: Hans Hagen Date: Tue, 7 Aug 2007 01:37:00 +0200 Subject: stable 2007.08.07 01:37 --- tex/context/base/core-uti.lua | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 tex/context/base/core-uti.lua (limited to 'tex/context/base/core-uti.lua') 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-- +

A utility file has always been part of and with +the move to we also moved a lot of multi-pass info +to a table. Instead of loading a based +utility file under different setups, we now load a table once. This +saves much runtime but at the cost of more memory usage.

+--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-- +

Variables are saved using in the previously defined table and passed +onto using the following method. Of course one can also +directly access the variable using a call.

+--ldx]]-- + +function job.initializevariable(cs,value) + tex.sprint("\\xdef\\"..cs.."{"..value.."}") +end -- cgit v1.2.3