[NTG-context] Learning LuaTeX : Invoice

Henning Hraban Ramm hraban at fiee.net
Sun Feb 20 15:49:30 CET 2011


Am 2011-02-20 um 14:41 schrieb Wolfgang Schuster:

>
> Am 20.02.2011 um 14:29 schrieb Henning Hraban Ramm:
>
>> I found a better approach, but with the letter module involved, my  
>> "RegisterItem" is called twice!
>
> The letter modules does trialtypesetting of the content to get the  
> content
> of the \cc, \encl and \ps commands. To prevent that certain commands  
> and
> environments are preprocessed you can wrap them in
>
> \iftrialtypesetting \else
> ...
> \fi
>
> or
>
> \unless\iftrialtypesetting
> ...
> \fi


Thank you, but how does that map to Lua? I couldn't find  
"trialtypesetting" in the LuaTeX manual.
I tried
"if context.trialtypesetting() then return end"
but get only "undefined control sequence".

"""
context.iftrialtypesetting()
do
	return
end
context.fi()
"""
can't work, of course ("Incomplete \iffalse")

Greetlings from Lake Constance!
Hraban
---
http://www.fiee.net/texnique/
http://wiki.contextgarden.net
https://www.cacert.org (I'm an assurer)



More information about the ntg-context mailing list