Changeset 167820 in webkit
- Timestamp:
- Apr 25, 2014 2:05:59 PM (10 years ago)
- Location:
- trunk
- Files:
-
- 3 added
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r167818 r167820 1 2014-04-25 David Hyatt <hyatt@apple.com> 2 3 Column rules not respecting scroll offsets. 4 https://bugs.webkit.org/show_bug.cgi?id=109683 5 6 Reviewed by Dean Jackson. 7 8 * fast/multicol/scrolling-column-rules.html: Added. 9 * platform/mac/fast/multicol/scrolling-column-rules-expected.png: Added. 10 * platform/mac/fast/multicol/scrolling-column-rules-expected.txt: Added. 11 1 12 2014-04-23 Jon Honeycutt <jhoneycutt@apple.com> 2 13 -
trunk/Source/WebCore/ChangeLog
r167818 r167820 1 2014-04-25 David Hyatt <hyatt@apple.com> 2 3 Column rules not respecting scroll offsets. 4 https://bugs.webkit.org/show_bug.cgi?id=109683 5 6 Reviewed by Dean Jackson. 7 8 Added fast/multicol/scrolling-column-rules.html 9 10 * rendering/RenderBlock.cpp: 11 (WebCore::RenderBlock::paintColumnRules): 12 Make paintColumnRules virtual so that it works with both column implementations. 13 14 (WebCore::RenderBlock::paintObject): 15 Changed to call paintColumnRules with the adjusted scroll offset and to do it after 16 bailing on the root background only check. 17 18 * rendering/RenderBlock.h: 19 paintColumnRules is now virtual. 20 21 * rendering/RenderBlockFlow.cpp: 22 (WebCore::RenderBlockFlow::paintColumnRules): 23 (WebCore::RenderBlockFlow::paintBoxDecorations): Deleted. 24 * rendering/RenderBlockFlow.h: 25 Got rid of paintBoxDecorations override since it failed when hasBoxDecorations was false 26 anyway. Override paintColumnRules instead to paint at the right time. 27 1 28 2014-04-23 Jon Honeycutt <jhoneycutt@apple.com> 2 29 -
trunk/Source/WebCore/rendering/RenderBlock.cpp
r167810 r167820 1827 1827 void RenderBlock::paintColumnRules(PaintInfo& paintInfo, const LayoutPoint& paintOffset) 1828 1828 { 1829 if ( paintInfo.context->paintingDisabled())1829 if (!hasColumns() || paintInfo.context->paintingDisabled()) 1830 1830 return; 1831 1831 … … 2114 2114 paintInfo.context->restore(); 2115 2115 } 2116 if (hasColumns() && !paintInfo.paintRootBackgroundOnly())2117 paintColumnRules(paintInfo, paintOffset);2118 2116 } 2119 2117 … … 2123 2121 } 2124 2122 2125 // We're done. We don't bother painting any children.2126 if (paint Phase == PaintPhaseBlockBackground || paintInfo.paintRootBackgroundOnly())2123 // If just painting the root background, then return. 2124 if (paintInfo.paintRootBackgroundOnly()) 2127 2125 return; 2128 2126 … … 2131 2129 scrolledOffset.move(-scrolledContentOffset()); 2132 2130 2131 // Column rules need to account for scrolling and clipping. 2132 // FIXME: Clipping of column rules does not work. We will need a separate paint phase for column rules I suspect in order to get 2133 // clipping correct (since it has to paint as background but is still considered "contents"). 2134 if ((paintPhase == PaintPhaseBlockBackground || paintPhase == PaintPhaseChildBlockBackground) && style().visibility() == VISIBLE) 2135 paintColumnRules(paintInfo, scrolledOffset); 2136 2137 // Done with backgrounds, borders and column rules. 2138 if (paintPhase == PaintPhaseBlockBackground) 2139 return; 2140 2133 2141 // 2. paint contents 2134 2142 if (paintPhase != PaintPhaseSelfOutline) { -
trunk/Source/WebCore/rendering/RenderBlock.h
r167817 r167820 484 484 void paintContents(PaintInfo&, const LayoutPoint&); 485 485 void paintColumnContents(PaintInfo&, const LayoutPoint&, bool paintFloats = false); 486 v oid paintColumnRules(PaintInfo&, const LayoutPoint&);486 virtual void paintColumnRules(PaintInfo&, const LayoutPoint&); 487 487 void paintSelection(PaintInfo&, const LayoutPoint&); 488 488 void paintCaret(PaintInfo&, const LayoutPoint&, CaretType); -
trunk/Source/WebCore/rendering/RenderBlockFlow.cpp
r167803 r167820 1998 1998 } 1999 1999 2000 void RenderBlockFlow::paint BoxDecorations(PaintInfo& paintInfo, const LayoutPoint& point)2001 { 2002 RenderBlock::paint BoxDecorations(paintInfo, point);2003 2004 if (!multiColumnFlowThread() || !paintInfo.shouldPaintWithinRoot(*this))2005 return; 2006 2000 void RenderBlockFlow::paintColumnRules(PaintInfo& paintInfo, const LayoutPoint& point) 2001 { 2002 RenderBlock::paintColumnRules(paintInfo, point); 2003 2004 if (!multiColumnFlowThread() || paintInfo.context->paintingDisabled()) 2005 return; 2006 2007 2007 // Iterate over our children and paint the column rules as needed. 2008 2008 for (auto& columnSet : childrenOfType<RenderMultiColumnSet>(*this)) { -
trunk/Source/WebCore/rendering/RenderBlockFlow.h
r167803 r167820 83 83 virtual void updateLogicalHeight() override; 84 84 85 virtual void paint BoxDecorations(PaintInfo&, const LayoutPoint&) override;85 virtual void paintColumnRules(PaintInfo&, const LayoutPoint&) override; 86 86 87 87 public:
Note: See TracChangeset
for help on using the changeset viewer.