haikuwebkit/LayoutTests/svg/custom/subpaths-moveto-only-render...

7 lines
353 B
XML
Raw Permalink Normal View History

REGRESSION (r91125): Polyline tool in google docs is broken https://bugs.webkit.org/show_bug.cgi?id=65796 Source/WebCore: Patch by Stephen Chenney <schenney@chromium.org> on 2011-12-02 Reviewed by Darin Adler. Work around a bug in CoreGraphics, that caused incorrect bounds for paths consisting only of move-to elements. This causes problems in SVG, when the enormous bounds prevented the drawing of things behind. Tests: svg/custom/path-moveto-only-rendering.svg svg/custom/subpaths-moveto-only-rendering.svg * platform/graphics/cg/PathCG.cpp: (WebCore::PathIsEmptyOrSingleMoveTester::PathIsEmptyOrSingleMoveTester): Class to test for isEmpty accoridng ot the same rules as other platforms. (WebCore::PathIsEmptyOrSingleMoveTester::isEmpty): Query the result (WebCore::PathIsEmptyOrSingleMoveTester::testPathElement): Path iterator method (WebCore::PathHasOnlyMoveToTester::PathHasOnlyMoveToTester): Class to test whether a path contains only move-to elements, and hence should have null bounds. (WebCore::PathHasOnlyMoveToTester::hasOnlyMoveTo): Query the result (WebCore::PathHasOnlyMoveToTester::testPathElement): Path iterator method. (WebCore::Path::boundingRect): Modified to check for move-to only paths (WebCore::Path::fastBoundingRect): Modified to check for move-to only paths (WebCore::Path::isEmpty): Now uses the method that matches other platforms. (WebCore::Path::hasCurrentPoint): Now uses CGPathIsEmpty directly (WebCore::Path::transform) : Now uses CGPathIsEmpty directly LayoutTests: Work around a bug in CoreGraphics, that caused incorrect bounds for paths consisting only of move-to elements. This causes problems in SVG, when the enormous bounds prevented the drawing of things behind. Will revert expectation file when expectations are stable. Patch by Stephen Chenney <schenney@chromium.org> on 2011-12-02 Reviewed by Darin Adler. * platform/chromium-mac/svg/custom/zero-path-square-cap-rendering2-expected.txt: Removed. * platform/chromium-win/svg/custom/zero-path-square-cap-rendering2-expected.txt: Removed. * platform/mac/svg/custom/path-moveto-only-rendering-expected.png: Added. * platform/mac/svg/custom/path-moveto-only-rendering-expected.txt: Added. * platform/mac/svg/custom/subpaths-moveto-only-rendering-expected.png: Added. * platform/mac/svg/custom/subpaths-moveto-only-rendering-expected.txt: Added. * svg/custom/path-moveto-only-rendering.svg: Added. * svg/custom/subpaths-moveto-only-rendering.svg: Added. * svg/custom/zero-path-square-cap-rendering2-expected.txt: Modified text output * platform/chromium/test_expectations.txt: Added flakiness for new tests from this patch Canonical link: https://commits.webkit.org/90366@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@101903 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2011-12-03 05:34:42 +00:00
<svg width="100%" height="100%" version="1.1" xmlns="http://www.w3.org/2000/svg">
<g transform="scale(0.766666)">
<rect width="100" height="100" style="fill:green"/>
<path stroke="red" stroke-width="496.95" stroke-linecap="square" stroke-linejoin="miter" stroke-miterlimit="8" shape-rendering="optimizeSpeed" d="M 0 0 m 10 10"/>
</g>
</svg>