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

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

From: Mats Palmgren <mats.palmgren@bredband.net>
Date: Fri, 23 Mar 2007 04:47:09 +0100
Message-ID: <46034DBD.30903@bredband.net>
To: www-style@w3.org

Andrew Fedoniouk wrote:
> Question is: shall 'baz' be scrollable together with the content of
> the 'bar'?

No, the containing block is <foo>.

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.
Received on Friday, 23 March 2007 03:47:24 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 27 April 2009 13:54:50 GMT