On Fri, Jul 29, 2011 at 03:53, Alasdair McAndrew
I'm setting up a table, for which I'd like the first column to have a background of a middle gray. According to the wiki, something like this should work:
\starttable[|p(4cm)|p(11.75cm)|] \HL \BL[1]\AR \VL\tfa{\bf A bit of text}\VL A lot of text, which will be broken up into several lines\VL\AR \HL \stoptable
There are two problems here: (1) the background covers only the line of "A bit of text" and not the entire cell, and (2) the background color is too light.
I experimented with this from the wiki:
\starttabulate[|CR{red}c|CC{yellow}c|CM{green}c|CL{blue}c|] \NC test \NC test \NC test \NC test \NC \NR \NC test \NC test \NC test \NC test \NC \NR \NC test \NC test \NC test \NC test \NC \NR \NC test \NC test \NC test \NC test \NC \NR \stoptabulate
but it produced no colors at all (and yes, I do have colors turned on).
How can I achieve the effect I'm after?
Thanks, Alasdair
Not sure how to do it with all the other table interfaces (what is their deprecation status anyway?), but: % set background of first (1) column (c) to gray \setupTABLE[c][1][background=color,backgroundcolor=gray] \bTABLE \bTR \bTD test \eTD \bTD test \eTD \bTD test \eTD \bTD test \eTD \eTR \bTR \bTD test \eTD \bTD test \eTD \bTD test \eTD \bTD test \eTD \eTR \bTR \bTD test \eTD \bTD test \eTD \bTD test \eTD \bTD test \eTD \eTR \bTR \bTD test \eTD \bTD test \eTD \bTD test \eTD \bTD test \eTD \eTR \eTABLE The syntax looks rather familiar if you've ever constructed tables in HTML. You may wish to define your own color (before setupTABLE, and replacing "gray" with "myowngray" there): \definecolor[myowngray][s=0.3] "s=" defines a grayscale color; 0 is black, 1 is white. Of course, you may choose a different name. Cheers, ~~ Ondra