Re: [NTG-context] What is changed?

2013-02-04 Thread Wolfgang Schuster
Am 04.02.2013 um 20:12 schrieb Wolfgang Schuster : > > Am 04.02.2013 um 19:26 schrieb "Meer H. van der" : > >> More ideas? > > Move the Lua code to a luacode block or a external and use TeX only to access > the function.

Re: [NTG-context] What is changed?

2013-02-04 Thread Wolfgang Schuster
Am 04.02.2013 um 19:26 schrieb "Meer H. van der" : > More ideas? Move the Lua code to a luacode block or a external and use TeX only to access the function. Wolfgang ___ If your question is of interest to others as

Re: [NTG-context] What is changed?

2013-02-04 Thread Meer H. van der
On 4 feb. 2013, at 19:13, Aditya Mahajan wrote: > On Mon, 4 Feb 2013, H. van der Meer wrote: > >> The following worked without a hitch: >> >> \def\IsNilReturn#1{\edef\tmp{#1}\doifelse{\tmp}{nil}{\color[red]{ERROR}}{\tmp}} >> \def\formatDuration#1{\ctxlua{ >> local s = string.gsub("#1","\

Re: [NTG-context] What is changed?

2013-02-04 Thread Aditya Mahajan
On Mon, 4 Feb 2013, H. van der Meer wrote: The following worked without a hitch: \def\IsNilReturn#1{\edef\tmp{#1}\doifelse{\tmp}{nil}{\color[red]{ERROR}}{\tmp}} \def\formatDuration#1{\ctxlua{ local s = string.gsub("#1","\%D","") local d = tostring(hvdm.time:match(s)) tex

[NTG-context] What is changed?

2013-02-04 Thread H. van der Meer
The following worked without a hitch: \def\IsNilReturn#1{\edef\tmp{#1}\doifelse{\tmp}{nil}{\color[red]{ERROR}}{\tmp}} \def\formatDuration#1{\ctxlua{ local s = string.gsub("#1","\%D","") local d = tostring(hvdm.time:match(s)) tex.print(string.sub(d,1,2) ~= "0:" and d or stri