Title: [91497] trunk/Source/WebCore
Revision
91497
Author
[email protected]
Date
2011-07-21 14:16:02 -0700 (Thu, 21 Jul 2011)

Log Message

https://bugs.webkit.org/show_bug.cgi?id=64975
Elements that have columns (e.g., column-width or column-count non-auto) and elements that have
column-spans establish block formatting contexts, and therefore they should not be allowing
child margins to collapse with their own margins.

Reviewed by Beth Dakin.

Covered by existing tests.

* rendering/RenderBlock.cpp:
(WebCore::RenderBlock::MarginInfo::MarginInfo):

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (91496 => 91497)


--- trunk/Source/WebCore/ChangeLog	2011-07-21 20:49:38 UTC (rev 91496)
+++ trunk/Source/WebCore/ChangeLog	2011-07-21 21:16:02 UTC (rev 91497)
@@ -1,3 +1,17 @@
+2011-07-21  Dave Hyatt  <[email protected]>
+
+        https://bugs.webkit.org/show_bug.cgi?id=64975
+        Elements that have columns (e.g., column-width or column-count non-auto) and elements that have
+        column-spans establish block formatting contexts, and therefore they should not be allowing
+        child margins to collapse with their own margins.
+
+        Reviewed by Beth Dakin.
+
+        Covered by existing tests.
+
+        * rendering/RenderBlock.cpp:
+        (WebCore::RenderBlock::MarginInfo::MarginInfo):
+
 2011-07-19  Matthew Delaney  <[email protected]>
 
         Add fast path for ImageBuffer::draw

Modified: trunk/Source/WebCore/rendering/RenderBlock.cpp (91496 => 91497)


--- trunk/Source/WebCore/rendering/RenderBlock.cpp	2011-07-21 20:49:38 UTC (rev 91496)
+++ trunk/Source/WebCore/rendering/RenderBlock.cpp	2011-07-21 21:16:02 UTC (rev 91497)
@@ -93,7 +93,8 @@
     // we're positioned, floating, a table cell.
     m_canCollapseWithChildren = !block->isRenderView() && !block->isRoot() && !block->isPositioned()
         && !block->isFloating() && !block->isTableCell() && !block->hasOverflowClip() && !block->isInlineBlockOrInlineTable()
-        && !block->isWritingModeRoot();
+        && !block->isWritingModeRoot() && block->style()->hasAutoColumnCount() && block->style()->hasAutoColumnWidth()
+        && !block->style()->columnSpan();
 
     m_canCollapseMarginBeforeWithChildren = m_canCollapseWithChildren && (beforeBorderPadding == 0) && block->style()->marginBeforeCollapse() != MSEPARATE;
 
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to