Re: [cssom-view] Definition of scrollWidth doesn't seem to make sense

On Thu, Jun 21, 2012 at 10:41 PM, Robert O'Callahan <robert@ocallahan.org>wrote:

> On Fri, Jun 22, 2012 at 5:04 PM, Robert O'Callahan <robert@ocallahan.org>wrote:
>
>> Actually the situation for scrollHeight is a little different. Webkit and
>> Opera place a scrollable element's bottom padding below the element's last
>> child, so bottom padding does get included in the scrollHeight even if the
>> last child overflows.
>>
>
> Then again, given this testcase:
> <!DOCTYPE HTML>
> <div style="width:200px; height:100px; padding-bottom:100px;
> overflow-y:scroll; border:1px solid black; background:orange;
> background-clip:content-box;">
>   <div style="height:200px; width:100px; background:yellow"></div>
> </div>
> Webkit and Opera render the orange content-box just 100px high, so it's
> not clear where they think the bottom-padding is. It's just looks like a
> bug that they can scroll vertically in that testcase.
>
>
This is actually a really interesting case.

IE7, Webkit, Opera and Firefox <= 11 all allow the area to be scrolled.

IE8+ and Firefox 12+ don't allow the content to be scrolled.

Should content overflow over the padding? Was this change intentional?

- E

Received on Friday, 29 June 2012 00:48:34 UTC