Hi everybody, The solution below works. Thanks a lot! Using Mojca's solution plus a newline after the command apparently does the trick. After that, I didn't try the other solution, which resembles Olivier's. Kind regards, Robert \defineblock[Nederlandsblok] \defineblock[Engelsblok] \setupblock[Nederlandsblok][before=,after=] \setupblock[Engelsblok][before=,after=] \hideblocks[Nederlandsblok] %\hideblocks[Engelsblok] \starttext there \beginNederlandsblok Ik vraag me af of ze ook appels verkopen 1 \endNederlandsblok \beginEngelsblok I really wonder if they do sell apples 1 \endEngelsblok there there \startitemize \item \beginNederlandsblok% Ik vraag me af of ze ook appels verkopen 2 \endNederlandsblok \beginEngelsblok I really wonder if they do sell apples 2 \endEngelsblok \item \beginNederlandsblok Ik vraag me af of ze ook appels verkopen 3 \endNederlandsblok \beginEngelsblok I really wonder if they do sell apples 3 \endEngelsblok \stopitemize \stoptext Mojca Miklavec wrote:
Rob Ermers wrote:
Hi,
If I make sure there is enough space, i.e. more than one space, between the \begin... and the text, it works! However in the pdf the item drops a line down, like this:
See \def\dodefineblock in core-buf.tex.
Does \setupblock[Nederlandsblok][before=,after=] \setupblock[Engelsblok][before=,after=] solve your problem?
Besides that, I would prefer to define something like \def\NlEn#1#2{% \beginNederlandsblok% {#1}% \endNederlandsblok% \beginEngelsblok% {#2}% \endEngelsblok}
in your case, but you should ask someone else why this doesn't work (I guess it's some strange expansion problem again - I never understood that topic).
Another extremely lightweight TeX solution:
\newif\ifenglish \englishtrue % \englishfalse
\def\NlEn#1#2{\ifenglish{#2}\else{#1}\fi} \starttext \NlEn{Dutch}{English} \stoptext
However, if you want to have more complex stuff in it, you probably have to use a more complex definition (send an exaple that fails).
Mojca
\defineblock[Nederlandsblok, Engelsblok]
\starttext \startitemize \item \beginNederlandsblok Ik vraag me af of ze ook appels verkopen \endNederlandsblok \beginEngelsblok I really wonder if they do sell apples \endEngelsblok \item \beginNederlandsblok Ik vraag me af of ze ook appels verkopen \endNederlandsblok \beginEngelsblok I really wonder if they do sell apples \endEngelsblok \stopitemize \stoptext
_______________________________________________ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context