- From: Tab Atkins Jr. <jackalmage@gmail.com>
- Date: Thu, 12 Aug 2010 16:32:07 -0700
- To: Boris Zbarsky <bzbarsky@mit.edu>
- Cc: Arron Eicholz <Arron.Eicholz@microsoft.com>, "public-css-testsuite@w3.org" <public-css-testsuite@w3.org>, www-style list <www-style@w3.org>
On Mon, Aug 2, 2010 at 6:44 PM, Boris Zbarsky <bzbarsky@mit.edu> wrote:
> On 8/2/10 6:34 PM, Arron Eicholz wrote:
>>
>>
>> http://test.csswg.org/source/contributors/mozilla/submitted/css2.1/selectors/first-line-floats-002.htm
>
> This is a very interesting testcase that I wrote because the spec is pretty
> clear here but the behavior of some UA's didn't make sense. The testcase is
> basically:
>
> <style>
> div { color: red; }
> div:first-line { color: green }
> </style>
> <div>
> <span>
> <span style="float: left">This should be green</span>
> </span>
> </div>
>
> Ignoring the first-line business for the moment, the float inherits its
> color from the outer <span>. But section 5.12.1 explicitly says that this
> markup should behave just like this markup:
>
> <div style="color: red">
> <div:first-line style="color: green">
> <span>
> <span style="float: left">This should be green</span>
> </span>
> </div:first-line>
> </div>
Agreed; the spec is very clear that this is the correct element-tree.
The color of the float then follows naturally.
~TJ
Received on Thursday, 12 August 2010 23:33:00 UTC