Bug 109867

Summary: incorrect repainting when a table has a transform
Product: WebKit Reporter: arno. <a.renevier>
Component: TablesAssignee: arno. <a.renevier>
Status: RESOLVED FIXED    
Severity: Normal CC: buildbot, commit-queue, eric, esprehn+autocc, ggaren, glenn, mitz, ojan.autocc, rniwa, simon.fraser, webkit.review.bot
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
testcase
none
patch proposal: disable layout state during layout of table (and tableSection,tableRow) render object
none
updated patch; check for reflections as well
none
Archive of layout-test-results from webkit-ews-03 for mac-mountainlion
none
Archive of layout-test-results from webkit-ews-15 for mac-mountainlion-wk2
none
same patch; title and meta tags removed in LayoutTests
none
updated patch none

arno.
Reported 2013-02-14 14:56:02 PST
Created attachment 188434 [details] testcase Hi, I have a table-like element (display: table). This element has a transform. Inside I have a block element. When I modify both the width and the height of the element, it is not repainted correctly: the rectangular part right of the current shape is not painted. I attach a testcase which add one pixel in width and one pixel in width a few times. The result should be a rectangle, but actually, a triangle like shape is painted on the page.
Attachments
testcase (916 bytes, text/html)
2013-02-14 14:56 PST, arno.
no flags
patch proposal: disable layout state during layout of table (and tableSection,tableRow) render object (6.58 KB, patch)
2013-02-14 17:22 PST, arno.
no flags
updated patch; check for reflections as well (8.89 KB, patch)
2013-05-02 17:23 PDT, arno.
no flags
Archive of layout-test-results from webkit-ews-03 for mac-mountainlion (743.42 KB, application/zip)
2013-05-02 18:42 PDT, Build Bot
no flags
Archive of layout-test-results from webkit-ews-15 for mac-mountainlion-wk2 (506.62 KB, application/zip)
2013-05-02 22:10 PDT, Build Bot
no flags
same patch; title and meta tags removed in LayoutTests (8.60 KB, patch)
2013-05-03 10:17 PDT, arno.
no flags
updated patch (7.84 KB, patch)
2013-05-03 16:02 PDT, arno.
no flags
arno.
Comment 1 2013-02-14 17:13:59 PST
Actually, this happens computeRectForRepaint for the inner div does not take into account the transformation of its parent. When the parent is not a table-like element, the rectangle takes into account the transformation. The difference between is because layout state is disabled in the generic case, but is enabled with a table.
arno.
Comment 2 2013-02-14 17:22:37 PST
Created attachment 188456 [details] patch proposal: disable layout state during layout of table (and tableSection,tableRow) render object
arno.
Comment 3 2013-02-14 17:24:44 PST
For other objects, LayoutState is also disabled when there is a reflection. I wonder if we should also do the same thing.
Eric Seidel (no email)
Comment 4 2013-02-14 19:11:14 PST
Mitz is your man for LayoutState.
Geoffrey Garen
Comment 5 2013-05-02 17:03:43 PDT
Comment on attachment 188456 [details] patch proposal: disable layout state during layout of table (and tableSection,tableRow) render object Looks like we should check for reflection as well.
arno.
Comment 6 2013-05-02 17:23:14 PDT
Created attachment 200376 [details] updated patch; check for reflections as well new test (checking for reflection) fails without the patch and passes with the patch
Build Bot
Comment 7 2013-05-02 18:42:39 PDT
Comment on attachment 200376 [details] updated patch; check for reflections as well Attachment 200376 [details] did not pass mac-ews (mac): Output: http://webkit-queues.appspot.com/results/357286 New failing tests: fast/frames/crash-remove-iframe-during-object-beforeload.html
Build Bot
Comment 8 2013-05-02 18:42:41 PDT
Created attachment 200380 [details] Archive of layout-test-results from webkit-ews-03 for mac-mountainlion The attached test failures were seen while running run-webkit-tests on the mac-ews. Bot: webkit-ews-03 Port: mac-mountainlion Platform: Mac OS X 10.8.2
Simon Fraser (smfr)
Comment 9 2013-05-02 19:47:51 PDT
Comment on attachment 200376 [details] updated patch; check for reflections as well View in context: https://bugs.webkit.org/attachment.cgi?id=200376&action=review > LayoutTests/fast/repaint/reflection-table-layout-expected.html:6 > + <meta charset="utf-8"> > + > + <title>Repaint test for bug 109867</title> You can remove these. > LayoutTests/fast/repaint/reflection-table-layout.html:6 > + <meta charset="utf-8"> > + > + <title>Repaint test for bug 109867</title> Ditto.
Build Bot
Comment 10 2013-05-02 22:10:41 PDT
Comment on attachment 200376 [details] updated patch; check for reflections as well Attachment 200376 [details] did not pass mac-wk2-ews (mac-wk2): Output: http://webkit-queues.appspot.com/results/384350 New failing tests: fast/frames/crash-remove-iframe-during-object-beforeload.html
Build Bot
Comment 11 2013-05-02 22:10:44 PDT
Created attachment 200388 [details] Archive of layout-test-results from webkit-ews-15 for mac-mountainlion-wk2 The attached test failures were seen while running run-webkit-tests on the mac-wk2-ews. Bot: webkit-ews-15 Port: mac-mountainlion-wk2 Platform: Mac OS X 10.8.2
arno.
Comment 12 2013-05-03 10:17:43 PDT
Created attachment 200435 [details] same patch; title and meta tags removed in LayoutTests
Simon Fraser (smfr)
Comment 13 2013-05-03 11:23:14 PDT
Comment on attachment 200435 [details] same patch; title and meta tags removed in LayoutTests View in context: https://bugs.webkit.org/attachment.cgi?id=200435&action=review > LayoutTests/fast/repaint/transform-table-layout.html:25 > + window.setTimeout(function() { > + div.style.width = '2px'; It would be nice to have a test that doesn't require a timeout. It might be better to make a test that dumps repaint rectangles, rather than using a ref test.
arno.
Comment 14 2013-05-03 16:02:28 PDT
Created attachment 200505 [details] updated patch Looks like there is an helper function to test repaint bugs. This patch use those function
Simon Fraser (smfr)
Comment 15 2013-05-03 20:21:40 PDT
Comment on attachment 200505 [details] updated patch Excellent!
WebKit Commit Bot
Comment 16 2013-05-03 20:48:32 PDT
Comment on attachment 200505 [details] updated patch Clearing flags on attachment: 200505 Committed r149550: <http://trac.webkit.org/changeset/149550>
WebKit Commit Bot
Comment 17 2013-05-03 20:48:35 PDT
All reviewed patches have been landed. Closing bug.
Note You need to log in before you can comment on or make changes to this bug.