Am 23.04.2013 um 20:11 schrieb "Verhaag, G.C.H.M."
Hi Luigi,
Thanks for your very quick response, just great! Your suggestion works!
By the way, what does this expanded mean, is it documented somewhere? Is it a typical MKIV thing related to Lua?
It’s a typical way in MkIV to check for the existing of values in “command” keys but it has nothing to do with Lua. I can demonstrate the purpose of \unexpanded with the following example. First I create the two command \one and \two, afterwards I add \expandedone and \expandedtwo which hold the expanded values of \one and \two. As you can see I get the same text with \one and \expandedone. In the next step I redefine \one and \two to hold a new value and compare again the content of all four macros. Unlike in the previous output \one and \expandedone are different while \two and \expandedtwo show the same result. The reason why \expandedtwo show “Second” is that \unexpanded\def prevented the expansion of \two in \edef\expandedtwo{…}. \starttext \def\one{One} \unexpanded\def\two{Two} \edef\expandedone{\one} \edef\expandedtwo{\two} \startlines \one:\expandedone \two:\expandedtwo \stoplines \def\one{First} \def\two{Second} \startlines \one:\expandedone \two:\expandedtwo \stoplines \stoptext Wolfgang