Changes

Jump to navigation Jump to search
1,325 bytes added ,  23:06, 30 January 2005
no edit summary
\NC \tex{LR} \NC last row \NC\LR
\HL
\NC \tex{AR} \NC automatic row \NC\SR
\HL
\stoptable
</context>
 
A very nice application in table are background colors for rows/cells (a feature that doesn't work in tabulate):
<texcode>
\setupcolors[state=start]
\placetable[here][tab:sample]{sample table}
\starttable[|l|l|]
\HL
\BL[2]\SR
\NC Command \NC Meaning \NC\SR
\HL
\NC \tex{NC} \NC next column \NC\FR
\NC \tex{HL} \NC horizontal line \NC\MR
\NC \tex{VL} \NC vertical line \NC\MR
\NC \tex{NR} \NC next row \NC\LR
\HL
\CL[green]\SR
\NC \tex{AR} \NC automatic row \NC\SR
\HL
\stoptable
</texcode>
The commands work something like this: first, you say what background colour you want for the next row
and then you typeset the row. Observe: the line with the colour-command and the row it is supposed
to colour should end in the same command (i.e. both \SR, \LR, \FR, ...). If they don't, the background
won't cover the whole cell.
 
* \BL makes a gray background: the optional argument tells BL how many cells it should color
* \CL makes a colored line
<context>
\setupcolors[state=start]
\placetable[here][tab:sample]{sample table}
\starttable[|l|l|]
\HL
\BL[1]\SR
\NC Command \NC Meaning \NC\SR
\HL
\NC \tex{NC} \NC next column \NC\FR
\NC \tex{HL} \NC horizontal line \NC\MR
\NC \tex{VL} \NC vertical line \NC\MR
\NC \tex{NR} \NC next row \NC\LR
\HL
\CL[green]\SR
\NC \tex{AR} \NC automatic row \NC\SR
\HL
\stoptable
</context>
Anonymous user

Navigation menu