Skip to content
  • fmalita@chromium.org's avatar
    [Chromium] SVG repaint issues · 4898bdae
    fmalita@chromium.org authored
    https://bugs.webkit.org/show_bug.cgi?id=99874
    
    Reviewed by Levi Weintraub.
    
    Source/WebCore:
    
    RenderSVGRoot::paintReplaced() converts the container offsets to a relative transform,
    but in doing so it ends up accumulating subpixel rounding deltas twice: first for
    adjustedPaintOffset and second in localToParentTransform(). If coordinates are on
    half-pixel boundaries, the 2x rounding delta yields a full pixel drift and we end up
    painting at the wrong location.
    
    This can be avoided by using localToBorderBoxTransform() directly, which (unlike
    localToParentTransform()) doesn't perform rounding.
    
    No new tests: existing pixel results cover this change after rebaseline.
    
    * rendering/svg/RenderSVGRoot.cpp:
    (WebCore::RenderSVGRoot::paintReplaced):
    
    LayoutTests:
    
    * platform/chromium-linux/svg/zoom/page/zoom-svg-float-border-padding-expected.png:
    * platform/chromium-linux/svg/zoom/text/zoom-svg-float-border-padding-expected.png:
    * platform/chromium-win/svg/custom/object-sizing-width-50p-height-75p-on-target-svg-absolute-expected.png:
    * platform/chromium-win/svg/custom/object-sizing-width-50p-height-75p-on-target-svg-expected.png:
    * platform/chromium/TestExpectations:
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@132377 268f45cc-cd09-0410-ab3c-d52691b4dbfc
    4898bdae