| Index: Source/core/rendering/svg/SVGPathData.cpp
|
| diff --git a/Source/core/rendering/svg/SVGPathData.cpp b/Source/core/rendering/svg/SVGPathData.cpp
|
| index bd94518746f05f83035834196656c19e5e9a72ea..04c9c87a018e606d1429e2037d8de69f73a539c6 100644
|
| --- a/Source/core/rendering/svg/SVGPathData.cpp
|
| +++ b/Source/core/rendering/svg/SVGPathData.cpp
|
| @@ -21,6 +21,8 @@
|
| #include "core/rendering/svg/SVGPathData.h"
|
|
|
| #include "core/SVGNames.h"
|
| +#include "core/rendering/RenderObject.h"
|
| +#include "core/rendering/style/SVGRenderStyle.h"
|
| #include "core/svg/SVGCircleElement.h"
|
| #include "core/svg/SVGEllipseElement.h"
|
| #include "core/svg/SVGLineElement.h"
|
| @@ -102,6 +104,7 @@ static void updatePathFromPolygonElement(SVGElement* element, Path& path)
|
| static void updatePathFromRectElement(SVGElement* element, Path& path)
|
| {
|
| SVGRectElement* rect = toSVGRectElement(element);
|
| + ASSERT(rect->renderer());
|
|
|
| SVGLengthContext lengthContext(element);
|
| float width = rect->width()->currentValue()->value(lengthContext);
|
| @@ -112,8 +115,10 @@ static void updatePathFromRectElement(SVGElement* element, Path& path)
|
| return;
|
| if (!width && !height)
|
| return;
|
| - float x = rect->x()->currentValue()->value(lengthContext);
|
| - float y = rect->y()->currentValue()->value(lengthContext);
|
| +
|
| + const SVGRenderStyle& style = rect->renderer()->style()->svgStyle();
|
| + float x = lengthContext.valueForLength(style.x(), LengthModeWidth);
|
| + float y = lengthContext.valueForLength(style.y(), LengthModeHeight);
|
| float rx = rect->rx()->currentValue()->value(lengthContext);
|
| float ry = rect->ry()->currentValue()->value(lengthContext);
|
| bool hasRx = rx > 0;
|
|
|