Re: [css3-multicol] Spanning elements and BFCs in Webkit

On Sep 28, 2011, at 4:46 PM, Tab Atkins Jr. wrote:

> I partially satisfied my action from last week in a response to the
> agenda thread.  I'll fully satisfy the action here.
> 
> I did some experiments to determine exactly how Webkit treats
> column-spanning elements.  Specifically, we were trying to determine
> if (1) each spanning element is a BFC, (2) consecutive runs of
> spanning elements get wrapped in an anonymous BFC, or (3) something
> else.
> 
> The answer is officially (3), though for most purposes it acts like (2).
> 
> First, margin-collapsing.  Consecutive spanning elements collapse
> margins together, while they clearly do not collapse their margins
> with those of adjacent non-spanning elements.  This is trivial to
> demonstrate, so I will not include a testcase.  This matches behavior
> (2).
> 
> Second, float containment.  Floats are allowed to extrude from
> spanning elements, and intrude into consecutive spanning elements.
> However, they are not allowed to intrude into the "multicol box"
> containing following columns of non-spanning elements.  Here is a
> testcase:

I consider it a bug that the BFC containing the spanning elements didn't expand itself to encompass all of the floats inside it.

The current *intended* behavior in WebKit is that the anonymous block that encloses the spanning elements establish a BFC, and that the spanning elements do not.

Feel free to file a bug on me with that test case, although I suppose we can wait and see what's officially decided first.

dave
(hyatt@apple.com)

Received on Thursday, 29 September 2011 01:06:58 UTC