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

Unified Diff: third_party/WebKit/Source/core/layout/svg/LayoutSVGResourceMarker.h

Issue 2567853002: Clarify how LayoutSVGResourceMarker's m_viewport interacts with refX/refY (Closed)
Patch Set: Created 4 years 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 | « no previous file | third_party/WebKit/Source/core/layout/svg/LayoutSVGResourceMarker.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/layout/svg/LayoutSVGResourceMarker.h
diff --git a/third_party/WebKit/Source/core/layout/svg/LayoutSVGResourceMarker.h b/third_party/WebKit/Source/core/layout/svg/LayoutSVGResourceMarker.h
index 3c6bb3fe4b413a1c223f65be627e98a8e28608c9..63fe310a93dcbe641572dbdfb18e76fc79887998 100644
--- a/third_party/WebKit/Source/core/layout/svg/LayoutSVGResourceMarker.h
+++ b/third_party/WebKit/Source/core/layout/svg/LayoutSVGResourceMarker.h
@@ -54,7 +54,9 @@ class LayoutSVGResourceMarker final : public LayoutSVGResourceContainer {
SVGMarkerUnitsType markerUnits() const;
SVGMarkerOrientType orientType() const;
- const FloatRect& viewport() const { return m_viewport; }
+ // The viewport origin is (0,0) and not the reference point because each
+ // marker instance includes the reference in markerTransformation().
+ FloatRect viewport() const { return FloatRect(FloatPoint(), m_viewportSize); }
static const LayoutSVGResourceType s_resourceType = MarkerResourceType;
LayoutSVGResourceType resourceType() const override { return s_resourceType; }
@@ -66,7 +68,7 @@ class LayoutSVGResourceMarker final : public LayoutSVGResourceContainer {
AffineTransform viewportTransform() const;
- FloatRect m_viewport;
+ FloatSize m_viewportSize;
};
DEFINE_LAYOUT_SVG_RESOURCE_TYPE_CASTS(LayoutSVGResourceMarker,
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/layout/svg/LayoutSVGResourceMarker.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698