[NTG-context] first steps with \dosingleempty

Wolfgang Schuster schuster.wolfgang at googlemail.com
Thu Sep 11 10:12:50 CEST 2008


On Thu, Sep 11, 2008 at 9:56 AM, Goebel, Juergen
<juergen.goebel at eads.com> wrote:
> Hans Hagen wrote:
>
>> \unexpanded\def\Geb{\dosingleempty\doMyGeb}
>>
>> \def\doMyGeb[#1]#2#3%
>>    {, x \iffirstargument Aha \fi
>>     \doifsomethingelse{#2}{#2}{...}\space
>>     \doifsomethingelse{#3}{#3}{...}%
>>     \par}
>
> Thanks a lot, elegant and much shorter.
> But, alas, I can't test it yet since the
> \doifsomethingelse seems to be somewhat
> newer.  My oldtimer (according to Hraban)
> shall really be updated during the next
> days or weeks ...

You could use \doifelsenothing with reverse order for the second
and third argument, \doifsomethingelse was included after the
TL 2008 ConTeXt release.

Wolfgang


More information about the ntg-context mailing list