Command/doif...

From Wiki
< Command
Revision as of 03:06, 14 March 2012 by Jannis (talk | contribs) (moved Reference/en/doif... to Command/doif...: Text replace - "Reference/en/" to "Command/")
Jump to navigation Jump to search

\doif...

Block of code depending on a Lua value - example (by WS, 3/2011):

\starttext
  \ctxlua{test = true}
 
  Test is \ctxlua{commands.testcase(test)}{True}{False}.
 
  \ctxlua{test = false}

  Test is \ctxlua{commands.testcase(test)}{True}{False}.
\stoptext

See also

branches and decisions