Changeset 117476 in webkit
- Timestamp:
- May 17, 2012 12:04:53 PM (12 years ago)
- Location:
- trunk/Source/WebCore
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebCore/ChangeLog
r117473 r117476 1 2012-05-17 Emil A Eklund <eae@chromium.org> 2 3 Fix rounding in RenderFlowThread::paintIntoRegion 4 https://bugs.webkit.org/show_bug.cgi?id=86695 5 6 Reviewed by Eric Seidel. 7 8 Fix rounding of offset in paintIntoRegion to ensure that we paint on 9 device pixel boundaries. 10 11 Covered by existing tests in fast/regions. 12 13 * platform/graphics/FractionalLayoutPoint.h: 14 (WebCore::roundedIntPoint): 15 Add roundedIntPoint(FractionalLayoutSize) function. 16 (WebCore): 17 * rendering/RenderFlowThread.cpp: 18 (WebCore::RenderFlowThread::paintIntoRegion): 19 1 20 2012-05-17 Andreas Kling <kling@webkit.org> 2 21 -
trunk/Source/WebCore/platform/graphics/FractionalLayoutPoint.h
r116767 r117476 168 168 } 169 169 170 inline IntPoint roundedIntPoint(const FractionalLayoutSize& size) 171 { 172 return IntPoint(size.width().round(), size.height().round()); 173 } 174 170 175 inline IntPoint ceiledIntPoint(const FractionalLayoutPoint& point) 171 176 { -
trunk/Source/WebCore/rendering/RenderFlowThread.cpp
r113842 r117476 293 293 // from the region rect's current position. The amount of offset is equal to the location of 294 294 // region in flow coordinates. 295 LayoutPoint renderFlowThreadOffset;295 IntPoint renderFlowThreadOffset; 296 296 if (style()->isFlippedBlocksWritingMode()) { 297 297 LayoutRect flippedRegionRect(regionRect); 298 298 flipForWritingMode(flippedRegionRect); 299 renderFlowThreadOffset = LayoutPoint(paintOffset - flippedRegionRect.location());299 renderFlowThreadOffset = roundedIntPoint(paintOffset - flippedRegionRect.location()); 300 300 } else 301 renderFlowThreadOffset = LayoutPoint(paintOffset - regionRect.location());301 renderFlowThreadOffset = roundedIntPoint(paintOffset - regionRect.location()); 302 302 303 303 context->translate(renderFlowThreadOffset.x(), renderFlowThreadOffset.y()); 304 info.rect.moveBy(-r oundedIntPoint(renderFlowThreadOffset));304 info.rect.moveBy(-renderFlowThreadOffset); 305 305 306 306 layer()->paint(context, info.rect, 0, 0, region, RenderLayer::PaintLayerTemporaryClipRects);
Note: See TracChangeset
for help on using the changeset viewer.