W3C home > Mailing lists > Public > www-style@w3.org > March 2007

Re: [CSS 2.1] child-> position:absolute, parent -> overflow:scroll

From: Andrew Fedoniouk <news@terrainformatica.com>
Date: Fri, 23 Mar 2007 21:04:30 -0800
Message-ID: <000d01c76dd1$f5919620$3501a8c0@TERRA>
To: "Mats Palmgren" <mats.palmgren@bredband.net>, <www-style@w3.org>

Thanks Mats,

----- Original Message ----- 
From: "Mats Palmgren" <mats.palmgren@bredband.net>
To: <www-style@w3.org>
Sent: Thursday, March 22, 2007 7:47 PM
Subject: Re: [CSS 2.1] child-> position:absolute, parent -> overflow:scroll

> Andrew Fedoniouk wrote:
>> Question is: shall 'baz' be scrollable together with the content of
>> the 'bar'?
> No, the containing block is <foo>.

I think too but please see below.

> If you had used top:auto and/or left:auto for <baz> instead
> then the answer would be yes, because then the UA should use the
> "static position" for the auto value(s).
> Note that position:fixed boxes are excluded, they never follow
> the scrolling because of the text:
> "all scrollable boxes should be assumed to be scrolled to their origin"
> in CSS 2.1 10.3.7:
> http://www.w3.org/TR/CSS21/visudet.html#abs-non-replaced-width
>> I'd be happy if someone will point me on the part of the spec that
>> explains that special role of overflowed elements in regards of
>> positioned children.
> There is no such special role, as far as I know.
> Note in particular the exception in CSS 2.1 11.1.1:
> "It affects the clipping of all of the element's content except any
> descendant elements (and their respective content and descendants)
> whose containing block is the viewport or an ancestor of the element."
> http://www.w3.org/TR/CSS21/visufx.html#propdef-overflow
> https://bugzilla.mozilla.org/show_bug.cgi?id=303676
> has some testcases and comments you may find useful.

Thanks for the link, here is one more:

This dynamic test uses three blocks:

<A abs-positioned>
  <B scrollable>   
     <C abs-positioned >

According to the spec block C shall
not move when B will be scrolled.


containing block of C is A (correct) 
so it does not move the block C (correct), but 
position of  block C is not correct.

containing block of A is B (not correct) so 
block is moving. 

containing block is A (correct) 
but it moves the block C while scrolling
block B (not correct)

Andrew Fedoniouk.
Received on Saturday, 24 March 2007 04:05:06 UTC

This archive was generated by hypermail 2.3.1 : Monday, 2 May 2016 14:27:28 UTC