Re: [CSS2.1] col attributes: XHTML and CSS inconsistency?

On Mon, Dec 29, 2008 at 5:44 PM, Brad Kemper <brad.kemper@gmail.com> wrote:
>
>
> On Dec 29, 2008, at 11:59 AM, fantasai wrote:
>
>>
>> Rainer Åhlfors wrote:
>>>
>>> Personally, I don't see what the problem would be to convert <col>'s to
>>> CSS as part of parsing.
>>> <col style="color: red;">
>>> <col style="color: blue;">
>>> td:nth-child(1) { color: red; }
>>> td:nth-child(1) { color: blue; }
>>> Or, am I missing something fundamental here?
>>
>> Yeah. Colspans and rowspans. The third <td> in a row
>> is not always in the third column.
>>
>> ~fantasai
>
> Still... presumably the UA knows what column a given cell is in (or started
> in), in order to apply the COL properties that it does. If "nth-child" is OK
> and not too burdensome for the UA, then what makes "nth-col" (or nth-column)
> so much worse?
>
> td:nth-col(1) { color: red; }
> td:nth-col(2) { color: blue; }
>
> If the first column TD of the row was a colspan (and not part of a rowspan),
> then nth-col(2) would be ignored. And if the first column TD of the row was
> a in a rowspan and was not the first TD of the span, then it would be
> ignored. It does not seem like this would make the rendering harder, and
> could be something that COL mapped to.
>

One more thing: Color doesn't apply to columns - The only properties
that do apply are border, background, width, and visibility.

Garrett

Received on Tuesday, 30 December 2008 02:07:40 UTC