Re: [css3-multicol] margin collapsing between column-spanning element and blocks in column boxes: if, when?

Le Sam 14 septembre 2013 16:09, "Gérard Talbot" a écrit :
> Håkon,
>
> One issue that I wish would be explicit and clarified in the spec is if
> margin collapsing can occur between a column-spanning element and blocks
> in column boxes. If it can occur, then the spec should say so, then define
> under which conditions along with an example. If it does not occur, then
> the spec should say so.
>
> Here's a test where browsers differ:


http://www.gtalbot.org/BrowserBugsSection/CSS3Multi-Columns/Opera/NewTests/multicol-spanning-margin-collapsing-234.xht


I slightly modified the test. I changed the "p" character for "P" in the
tested text because Ahem font usage makes those glyphs 20% smaller.

The yellow vertical bars represent the column gaps.

The blue area represent the background-color of the multi-column element.

The black area represent the Ahem glyphs.

The small white area are the blank white spaces separating words.


> (
> This test is a modified and customized test from Example XX in
> http://www.w3.org/TR/css3-multicol/#column-span
> and in Example 22 in
> http://dev.w3.org/csswg/css-multicol/#column-span
> )
>
> Firefox 23 does not support column-span: all, so here, I am only taken
> into consideration IE10, IE11 (preview), Chrome 29.0.1547.65 and Opera
> 12.16.
>
> The issue involves the margin collapsing of the margin-bottom of the
> h2#column-spanning which is 80px with the margin-top (which is 40px) of
> the p in first column box.

To be more precise:

The issue involves the margin collapsing of the margin-bottom (which is
80px) of the silver h2#column-spanning with the margin-top (which is 40px)
of the second p (p#second-parg) which is beginning in first column box,
under the silver h2#column-spanning.


> If margin collapsing occurs between those 2 margins, then there should be
> an 80px (max(80px, 40px)) tall blue area. IE10 and IE11 do that. (Prince9
> also does that but it fails to render the margin-top of first p.)


It seems that IE10 does a slightly better job at balancing content.

> If margin collapsing does not occur (because it should not occur) between
> those 2 margins, then there should be an 120px (80px + 40px) tall blue
> area. Chrome 29.0.1547.65 and Opera 12.16 do that.
>
> If margin collapsing can occur between column-spanning element and blocks
> in column boxes, then it could be possible to create tests where several
> blocks' margin-top collapses with a preceding-sibling column-spanning
> element.
>
> If margin collapsing can occur between column-spanning element and blocks
> in column boxes, then it could be also possible to create tests where
> several blocks' margin-bottom collapses with a following-sibling
> column-spanning element.
>
> Another sub-issue is: can margin collapsing occur between 2
> vertically-adjacent (following sibling) column-spanning elements.

Gérard
-- 
CSS 2.1 Test suite RC6, March 23rd 2011
http://test.csswg.org/suites/css2.1/20110323/html4/toc.html

Contributions to CSS 2.1 test suite
http://www.gtalbot.org/BrowserBugsSection/css21testsuite/

Web authors' contributions to CSS 2.1 test suite
http://www.gtalbot.org/BrowserBugsSection/css21testsuite/web-authors-contributions-css21-testsuite.html

Received on Sunday, 15 September 2013 13:32:46 UTC