[NTG-context] conditional format in xtables

Wolfgang Schuster schuster.wolfgang at gmail.com
Tue Apr 10 23:07:28 CEST 2018


The normal \doif... commands don’t work because they aren’t expandable
but you can use the \expdoif... commands (look into setup-en.pdf for all 
of them).

Wolfgang
> Pablo Rodriguez <mailto:oinos at gmx.es>
> 10. April 2018 um 19:18
> Dear list,
>
> thanks to Wolfgang, I learnt to set conditional format in xtables, such
> as in:
>
> \setupxtable
> [foregroundcolor={\ifnum\currentxtablecolumn=2 red\else green\fi}]
> \starttext
> \startxtable
> \startxrow
> \startxcell one \stopxcell
> \startxcell two \stopxcell
> \startxcell tree \stopxcell
> \startxcell four \stopxcell
> \stopxrow
> \stopxtable
> \stoptext
>
> My question is whether I can use ConTeXt conditionals instead of the
> ones from TeX. {\doifelse{\currentxtablecolumn}{2}{red}{green}} doesn’t
> work here.
>
> Many thanks for your help,
>
> Pablo

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.ntg.nl/pipermail/ntg-context/attachments/20180410/9858bf13/attachment.html>


More information about the ntg-context mailing list