Re: [css-d] Combining :only-of-type with :before?

2010-03-08 Thread Sjur Moshagen
Den 6. mar. 2010 kl. 08.09 skrev Philippe Wittenbergh: On Mar 6, 2010, at 12:04 AM, Sjur Moshagen wrote: The other thing i missed was the need to use double colons, like ::before - I tried only ':before'. What's the reason? When used directly with an element only a single colon (like

[css-d] Combining :only-of-type with :before?

2010-03-05 Thread Sjur Moshagen
Hello, I'm trying to style XML with CSS. I have successfully used the :only-of-type pseudo-class to let single instances of an element become inline, and multiple instances of the same be block elements. What I am NOT able to do is to combine this pseudo-class with the :before pseudo-class.

Re: [css-d] Combining :only-of-type with :before?

2010-03-05 Thread Philippe Wittenbergh
On Mar 5, 2010, at 7:18 PM, Sjur Moshagen wrote: I'm trying to style XML with CSS. I have successfully used the :only-of-type pseudo-class to let single instances of an element become inline, and multiple instances of the same be block elements. What I am NOT able to do is to combine

Re: [css-d] Combining :only-of-type with :before?

2010-03-05 Thread Sjur Moshagen
Den 5. mar. 2010 kl. 15.52 skrev Philippe Wittenbergh: What I want to achieve is: * multiple children of the same type should be displayed as a numbered list * lone children of the above type should be displayed as inline text, *without* any numbering Since i'm not able to combine the

Re: [css-d] Combining :only-of-type with :before?

2010-03-05 Thread Climis, Tim
The other thing i missed was the need to use double colons, like ::before - I tried only ':before'. What's the reason? :before is CSS2. ::before is CSS3. In CSS3, double colons go before pseudo-elements (first-line, first-letter, before, after), while single colons go before pseudo-classes

Re: [css-d] Combining :only-of-type with :before?

2010-03-05 Thread Philippe Wittenbergh
On Mar 6, 2010, at 12:04 AM, Sjur Moshagen wrote: The other thing i missed was the need to use double colons, like ::before - I tried only ':before'. What's the reason? When used directly with an element only a single colon (like :before) is needed. CSS2.1 vs CSS3 notation as Tim pointed