Re: [CSS21] More issues with issues with 9.5 (Floats)

Anton Prowse wrote:
> A couple more float issues.
> 
> Issue 1:
> 
> There is excellent interop demonstrating that line boxes are not 
> shortened in the presence of floats which appear later in the source 
> document (and hence overlap the floats in many situations).  This fact 
> is missing from the spec.


Not so, try narrowing the viewport with this test.

<div>
x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x 
x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x x 
x x x x x x x x x x x x x x x x
<span style="float: left; background: red;">float</span>
<span style="background: lime;">x x x x x x x x x x x x x x</span>
</div>


What situations do you mean by where you write "and hence overlap the 
floats in many situations"?


> Issue 2:
> 
> 9.5.1 says:
>   # 3. The right outer edge of a left-floating box may not be to the
>   # right of the left outer edge of any right-floating box that is to
>   # the right of it. Analogous rules hold for right-floating elements.
> 
> This means a left float can be to the right of a right float.  (They 
> need to be in different containing blocks in order to construct this 
> situation, obviously.)  Fx3.6 agrees; I haven't tested in others.  This 
> doesn't cause a problem, but I wanted to seek confirmation that this was 
> an intentional feature of the spec.
> 
> Cheers,
> Anton Prowse
> http://dev.moonhenge.net


This means that floats floated in opposite directions can not overlap 
each other if their combined width is greater than that of their 
containing block. If their containing block is narrowed or the floats 
width is increased, this can cause the float that is later in the 
source to drop below the earlier float.


-- 
Alan http://css-class.com/

Armies Cannot Stop An Idea Whose Time Has Come. - Victor Hugo

Received on Sunday, 5 September 2010 13:17:48 UTC