summaryrefslogtreecommitdiff
path: root/tex/context/base/mkiv/cldf-int.lua
diff options
context:
space:
mode:
authorContext Git Mirror Bot <phg42.2a@gmail.com>2016-07-22 22:33:21 +0200
committerContext Git Mirror Bot <phg42.2a@gmail.com>2016-07-22 22:33:21 +0200
commitdd7c4b1a54bfc5e358eb9f766c0b865fc47cbe46 (patch)
tree2e8888da6188eb742a98c3c05a26e2b75b198e62 /tex/context/base/mkiv/cldf-int.lua
parent50928735daee408de73737b055b2535d96424824 (diff)
downloadcontext-dd7c4b1a54bfc5e358eb9f766c0b865fc47cbe46.tar.gz
2016-07-22 20:13:00
Diffstat (limited to 'tex/context/base/mkiv/cldf-int.lua')
-rw-r--r--tex/context/base/mkiv/cldf-int.lua96
1 files changed, 48 insertions, 48 deletions
diff --git a/tex/context/base/mkiv/cldf-int.lua b/tex/context/base/mkiv/cldf-int.lua
index 2743e4924..cd4db2e90 100644
--- a/tex/context/base/mkiv/cldf-int.lua
+++ b/tex/context/base/mkiv/cldf-int.lua
@@ -172,51 +172,51 @@ function interfaces.tolist(t)
return concat(r,", ")
end
---~ \startluacode
---~ function test(opt_1, opt_2, arg_1)
---~ context.startnarrower()
---~ context("options 1: %s",interfaces.tolist(opt_1))
---~ context.par()
---~ context("options 2: %s",interfaces.tolist(opt_2))
---~ context.par()
---~ context("argument 1: %s",arg_1)
---~ context.stopnarrower()
---~ end
-
---~ interfaces.definecommand {
---~ name = "test",
---~ arguments = {
---~ { "option", "list" },
---~ { "option", "hash" },
---~ { "content", "string" },
---~ },
---~ macro = test,
---~ }
---~ \stopluacode
-
---~ test: \test[1][a=3]{whatever}
-
---~ \startluacode
---~ local function startmore(opt_1)
---~ context.startnarrower()
---~ context("start more, options: %s",interfaces.tolist(opt_1))
---~ context.startnarrower()
---~ end
-
---~ local function stopmore(opt_1)
---~ context.stopnarrower()
---~ context("stop more, options: %s",interfaces.tolist(opt_1))
---~ context.stopnarrower()
---~ end
-
---~ interfaces.definecommand ( "more", {
---~ environment = true,
---~ arguments = {
---~ { "option", "list" },
---~ },
---~ starter = startmore,
---~ stopper = stopmore,
---~ } )
---~ \stopluacode
-
---~ more: \startmore[1] one \startmore[2] two \stopmore one \stopmore
+-- \startluacode
+-- function test(opt_1, opt_2, arg_1)
+-- context.startnarrower()
+-- context("options 1: %s",interfaces.tolist(opt_1))
+-- context.par()
+-- context("options 2: %s",interfaces.tolist(opt_2))
+-- context.par()
+-- context("argument 1: %s",arg_1)
+-- context.stopnarrower()
+-- end
+--
+-- interfaces.definecommand {
+-- name = "test",
+-- arguments = {
+-- { "option", "list" },
+-- { "option", "hash" },
+-- { "content", "string" },
+-- },
+-- macro = test,
+-- }
+-- \stopluacode
+--
+-- test: \test[1][a=3]{whatever}
+--
+-- \startluacode
+-- local function startmore(opt_1)
+-- context.startnarrower()
+-- context("start more, options: %s",interfaces.tolist(opt_1))
+-- context.startnarrower()
+-- end
+--
+-- local function stopmore(opt_1)
+-- context.stopnarrower()
+-- context("stop more, options: %s",interfaces.tolist(opt_1))
+-- context.stopnarrower()
+-- end
+--
+-- interfaces.definecommand ( "more", {
+-- environment = true,
+-- arguments = {
+-- { "option", "list" },
+-- },
+-- starter = startmore,
+-- stopper = stopmore,
+-- } )
+-- \stopluacode
+--
+-- more: \startmore[1] one \startmore[2] two \stopmore one \stopmore