Re: [proposal] Table cell selectors.

Isn't CSS independent of what the elements mean, thus meaning that if we add @column and @row we are changing the direction of CSS
selectors by incorporating associations with document models?  And surely if the same can be done using nth-child() we shouldn't
implement something that does less if it is just a cut-down repeat?

Thomas O'Connor
me@ocoth.id.au


----- Original Message ----- 
From: "Andrew Fedoniouk" <news@terrainformatica.com>
To: "dolphinling" <dolphinling@myrealbox.com>
Cc: <www-style@w3.org>
Sent: Sunday, November 14, 2004 8:39 PM
Subject: Re: [proposal] Table cell selectors.


>
> | > E[@column=number @row=number]
>
> | Can't you do this with nth-child? Specifically tr:nth-child(n) >
> | td:nth-child(n)? It fails only if you have rowspans or colspans in your
> | table.
>
> It's a bit different, generally speaking.
>
> See:
> th[@column=number @row=number]
> td[@column=number @row=number]
> -or (not exactly though)-
> tr[@index=number]>td[@index=number]
>
> Notation E[@index=n] is more specific (less computational complexity) than
> nth-child
> because it is a selector of element itself and not a selector of  any
> arbitrary child of some parent.
>
> And it looks more clear and obvious, at least for me.
>
> Andrew Fedoniouk.
> http://terrainformatica.com
>
>
>
>
>
> Original Message from: "dolphinling"
> | Andrew Fedoniouk wrote:
> | > To intoduce:
> | >
> | > Table cell selector:
> | >
> | > E[@column=number @row=number]
> | >
> | > Matches any table cell located at column number and row number. Where
> number
> | > is a decimal number or "odd" or "even" or "last" values. Columns and
> rows
> | > numbers start from number 1.
> |
> | Can't you do this with nth-child? Specifically tr:nth-child(n) >
> | td:nth-child(n)? It fails only if you have rowspans or colspans in your
> | table.
> |
> | > I think that index selector for any other elements would be also useful.
> | > E[@index=number]
> | > Where number is a decimal number or "odd" or "even" or "last" values.
> | > Numbers of element indexes also start from 1.
> |
> | Again, nth-child(), which actually has even more flexibility. See
> | http://www.w3.org/TR/2001/CR-css3-selectors-20011113/#structural-pseudos.
> |
> |
>
>
>
>

Received on Sunday, 14 November 2004 09:56:48 UTC