Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1687)

Unified Diff: Source/core/rendering/svg/SVGMarkerData.h

Issue 539833004: [SVG2] Add support for marker orient="auto-start-reverse". (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: add dump-render-tree output + fix nit and test Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/core/rendering/svg/RenderSVGShape.cpp ('k') | Source/core/rendering/svg/SVGRenderTreeAsText.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/rendering/svg/SVGMarkerData.h
diff --git a/Source/core/rendering/svg/SVGMarkerData.h b/Source/core/rendering/svg/SVGMarkerData.h
index 123c4ca15b319961a8a4b82a8aff37860839c9f0..17032d108d9270c139166f90c8e2d4115b810806 100644
--- a/Source/core/rendering/svg/SVGMarkerData.h
+++ b/Source/core/rendering/svg/SVGMarkerData.h
@@ -47,9 +47,10 @@ struct MarkerPosition {
class SVGMarkerData {
public:
- SVGMarkerData(Vector<MarkerPosition>& positions)
+ SVGMarkerData(Vector<MarkerPosition>& positions, bool autoStartReverse)
: m_positions(positions)
, m_elementIndex(0)
+ , m_autoStartReverse(autoStartReverse)
{
}
@@ -88,6 +89,8 @@ private:
switch (type) {
case StartMarker:
+ if (m_autoStartReverse)
+ outAngle += 180;
return narrowPrecisionToFloat(outAngle);
case MidMarker:
// WK193015: Prevent bugs due to angles being non-continuous.
@@ -147,6 +150,7 @@ private:
FloatPoint m_subpathStart;
FloatPoint m_inslopePoints[2];
FloatPoint m_outslopePoints[2];
+ bool m_autoStartReverse;
};
}
« no previous file with comments | « Source/core/rendering/svg/RenderSVGShape.cpp ('k') | Source/core/rendering/svg/SVGRenderTreeAsText.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698