Re: [css3-multicol] abspos clipping

Håkon Wium Lie <howcome@opera.com> writes:

> Morten Stenshorne wrote:
>
>  > > Changed "Content in the normal flow" to "Floated or in-flow content", as per:
>  > >
>  > >   http://www.w3.org/TR/css3-multicol/#overflow
>  > 
>  > So abspos boxes aren't clipped, not even if the containing block of the
>  > abspos is the multicol container itself or a descendant?
>
> Correct; the old text didn't specify clipping and the new text doens't
> specify clipping for abspos. Do you think it should?

Yes, while your new wording of course isn't a spec regression as such
(it's an improvement), I'd find it strange if an abspos contained by the
multicol or a descendant isn't clipped by the gaps. I think it should be
the same as for how the 'overflow' property treats absolutely positioned
descendants (if the box that specifies hidden overflow is a containing
block of the abspos, the abspos is clipped).

I wrote a couple of tests, to examine the current implementations.

IE10 and Presto agree on this one:

<p>There should be a 50px by 50px square below.</p>
<div style="columns:3; column-fill:auto; overflow:hidden; column-gap:0; width:600px; height:100px;">
  <div style="position:relative;">
    <div style="position:absolute; top:-50px; left:150px; width:500px; height:100px; background:lime;"></div>
  </div>
  <div style="height:200px;"></div><!-- cause multiple columns -->
</div>

The abspos is clipped at the gap (and at the multicol's boundaries,
since the multicol is the containing block of the relpos, which in turn
is the containing block of the abspos). Makes sense to me (this is the
behavior that I want), but it kind of violates the current spec.

IE10 and Presto also agree with each other in the next test case, but
they don't agree with me: :)

<p>There should be a 50px by 50px square below.</p>
<div style="position:relative; overflow:hidden; columns:3; column-fill:auto; column-gap:0; width:600px; height:100px;">
  <div style="position:absolute; top:-50px; left:150px; width:500px; height:100px; background:lime;"></div>
  <div style="height:200px;"></div>
</div>

Here the abspos is only clipped against the multicol, but not against
the gap. I find this weird. It's in line with the spec, though.

-- 
---- Morten Stenshorne, developer, Opera Software ASA ----
---- Office: +47 23692400 ------ Mobile: +47 93440112 ----
------------------ http://www.opera.com/ -----------------

Received on Monday, 13 May 2013 15:51:00 UTC