W3C home > Mailing lists > Public > www-style@w3.org > January 2010

Re: proposal for a new css combinator

From: Christoph Päper <christoph.paeper@crissov.de>
Date: Mon, 18 Jan 2010 10:32:42 +0100
Message-Id: <7E9A7481-5569-407A-B4B9-391CC8967B2C@crissov.de>
To: www-style list <www-style@w3.org>
Niels Matthijs:
> I'd like something between the space and child combinator. A  
> combinator that allows for an (x) number of levels between parent  
> and child, but stops at the first matching level it hits.

   <A>
     <B>match
       <B>no match</B>
       <C><B>no match</B></C>
     </B>
     <B>match</B>
     <C/>
     <B>match</B>
     <C>
       <B>match
         <B>no match</B>
         <C><B>no match</B></C>
       </B>
     </C>
   </A>

   A>B, A>*:not(B)>B, A *:not(B) *:not(B)>B {p:v}

Does the last part exclude any B between A and the desired B or
does it just require at least two non-B between A and the desired B?
That means, in regular expression syntax where consecutive tokens  
resemble direct descendants, it is which one of these?

   AB | A[^B]B | A[^B]*[^B]B = A[^B]*B

   AB | A[^B]B | A.*[^B].*[^B]B = A[^B]?B | A.*[^B].*[^B]B
Received on Monday, 18 January 2010 09:33:16 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 17:20:23 GMT