summaryrefslogtreecommitdiff
path: root/tex/context/base/core-env.lua
diff options
context:
space:
mode:
Diffstat (limited to 'tex/context/base/core-env.lua')
-rw-r--r--tex/context/base/core-env.lua9
1 files changed, 9 insertions, 0 deletions
diff --git a/tex/context/base/core-env.lua b/tex/context/base/core-env.lua
index a4d1fdd92..8cbc93038 100644
--- a/tex/context/base/core-env.lua
+++ b/tex/context/base/core-env.lua
@@ -78,6 +78,15 @@ setmetatableindex(tex.ifs, function(t,k)
return csname_id(k) ~= undefined and create(k)[2] == iftrue -- inefficient, this create, we need a helper
end)
+function context.setconditional(name,value)
+ if value then
+ context.settruevalue(name)
+ else
+ context.setfalsevalue(name)
+ end
+end
+
+
-- todo : global
-- not possible as we let at the tex end to zerocount and plusone