On 25-1-2011 8:44, Wolfgang Schuster wrote:
\startsetups layer
% In my real code (= not in this example)
% the value of 'n' is used here to set the appropriate background,
% = n-th page of a PDF, and also to draw a filled rectangle on
% the left or right side (depending on whether n is even or odd)
% The code bellow fails [1]
\startluacode
print("N=", n)
if n == 2 then
else
end
\stopluacode
\stopsetups
\startluasetups layer
\stopluasetups
\luasetup{...}
-----------------------------------------------------------------
Hans Hagen | PRAGMA ADE
Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com
| www.pragma-pod.nl
-----------------------------------------------------------------
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the
Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________