[Webkit-unassigned] [Bug 51148] New: Overflow: auto failing to account for scrollbars after an element's size is increased

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed Dec 15 15:56:31 PST 2010


https://bugs.webkit.org/show_bug.cgi?id=51148

           Summary: Overflow: auto failing to account for scrollbars after
                    an element's size is increased
           Product: WebKit
           Version: 528+ (Nightly build)
          Platform: All
        OS/Version: All
            Status: UNCONFIRMED
          Severity: Normal
          Priority: P2
         Component: Layout and Rendering
        AssignedTo: webkit-unassigned at lists.webkit.org
        ReportedBy: mkbitbucket at mac.com


This is relatively new bug that has cropped up in our application on Safari and Chrome in the last month. I've taken the very complex JS and HTML from our app and reproduced the bug in the attached html page (with some embedded JS). The basic scenario is this:

We render a DIV (absolutely positioned, if that makes any difference) and give it a default size. The contents of that DIV (in this case an image) are loaded dynamically and can vary in size. When we get back the URL of the image, we put that into the DIV in an IMG tag, get its rendered height and width and then reset the size of the DIV to match. There is a lot math involved here because we want to make sure that if the image is too large to fit into the DIVs (which make up a form in our web application) we size the DIV so that it is completely visible on the screen, but the DIV should scroll so that the user can see their entire image. 

In most cases, the image will fit on the screen and there should be no scrollbars because the DIVs size exactly matches the image inside of it.

This works perfectly in FF, IE and was working in the WebKit browsers until recently.

The attached example reproduces the problem and the button implements our current, ugly workaround where we set the overflow: hidden, trigger a reflow and then set overflow: auto again.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list