Backed out changeset 0b44e8715bf5 (bug 1239100) for build bustage (SVGGeometryElement.webidl missing). r=backout
authorSebastian Hengst <archaeopteryx@coole-files.de>
Sun, 18 Dec 2016 11:42:51 +0100
changeset 371343 dd45619670c7fbf5c5b2ce09e33cc4f28a65db5c
parent 371342 0b44e8715bf5e9a799df69847ea9b57637cd7131
child 371344 4f5d03fe0e90e3041e694d63eb0c6a76a6621de5
push id6996
push userjlorenzo@mozilla.com
push dateMon, 06 Mar 2017 20:48:21 +0000
treeherdermozilla-beta@d89512dab048 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbackout
bugs1239100
milestone53.0a1
backs out0b44e8715bf5e9a799df69847ea9b57637cd7131
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Backed out changeset 0b44e8715bf5 (bug 1239100) for build bustage (SVGGeometryElement.webidl missing). r=backout
accessible/base/nsAccessibilityService.cpp
dom/base/nsGkAtomList.h
dom/svg/SVGCircleElement.cpp
dom/svg/SVGCircleElement.h
dom/svg/SVGEllipseElement.cpp
dom/svg/SVGEllipseElement.h
dom/svg/SVGGeometryElement.cpp
dom/svg/SVGGeometryElement.h
dom/svg/SVGImageElement.cpp
dom/svg/SVGImageElement.h
dom/svg/SVGLineElement.cpp
dom/svg/SVGLineElement.h
dom/svg/SVGPathData.cpp
dom/svg/SVGPathElement.cpp
dom/svg/SVGPathElement.h
dom/svg/SVGPolyElement.cpp
dom/svg/SVGPolyElement.h
dom/svg/SVGPolygonElement.cpp
dom/svg/SVGPolygonElement.h
dom/svg/SVGPolylineElement.cpp
dom/svg/SVGPolylineElement.h
dom/svg/SVGRectElement.cpp
dom/svg/SVGRectElement.h
dom/svg/moz.build
dom/svg/nsSVGElement.cpp
dom/svg/nsSVGPathGeometryElement.cpp
dom/svg/nsSVGPathGeometryElement.h
dom/svg/nsSVGPolyElement.cpp
dom/svg/nsSVGPolyElement.h
dom/tests/mochitest/general/test_interfaces.html
dom/webidl/SVGPathElement.webidl
dom/webidl/moz.build
layout/base/nsCSSFrameConstructor.cpp
layout/generic/nsFrameIdList.h
layout/painting/nsDisplayItemTypesList.h
layout/style/nsStyleStruct.cpp
layout/svg/SVGGeometryFrame.cpp
layout/svg/SVGGeometryFrame.h
layout/svg/moz.build
layout/svg/nsSVGClipPathFrame.cpp
layout/svg/nsSVGEffects.cpp
layout/svg/nsSVGImageFrame.cpp
layout/svg/nsSVGMarkerFrame.cpp
layout/svg/nsSVGMarkerFrame.h
layout/svg/nsSVGPathGeometryFrame.cpp
layout/svg/nsSVGPathGeometryFrame.h
layout/svg/nsSVGPatternFrame.cpp
layout/svg/nsSVGPatternFrame.h
layout/svg/nsSVGUtils.cpp
layout/svg/nsSVGUtils.h
testing/web-platform/meta/svg/historical.html.ini
testing/web-platform/meta/svg/interfaces.html.ini
--- a/accessible/base/nsAccessibilityService.cpp
+++ b/accessible/base/nsAccessibilityService.cpp
@@ -56,17 +56,17 @@
 #ifdef MOZ_CRASHREPORTER
 #include "nsExceptionHandler.h"
 #endif
 
 #include "nsImageFrame.h"
 #include "nsIObserverService.h"
 #include "nsLayoutUtils.h"
 #include "nsPluginFrame.h"
-#include "SVGGeometryFrame.h"
+#include "nsSVGPathGeometryFrame.h"
 #include "nsTreeBodyFrame.h"
 #include "nsTreeColumns.h"
 #include "nsTreeUtils.h"
 #include "nsXBLPrototypeBinding.h"
 #include "nsXBLBinding.h"
 #include "mozilla/ArrayUtils.h"
 #include "mozilla/dom/DOMStringList.h"
 #include "mozilla/Preferences.h"
@@ -1168,18 +1168,18 @@ nsAccessibilityService::CreateAccessible
           frameType == nsGkAtoms::scrollFrame) {
         newAcc = new XULTabpanelAccessible(content, document);
       }
     }
   }
 
   if (!newAcc) {
     if (content->IsSVGElement()) {
-      SVGGeometryFrame* geometryFrame = do_QueryFrame(frame);
-      if (geometryFrame) {
+      nsSVGPathGeometryFrame* pathGeometryFrame = do_QueryFrame(frame);
+      if (pathGeometryFrame) {
         // A graphic elements: rect, circle, ellipse, line, path, polygon,
         // polyline and image. A 'use' and 'text' graphic elements require
         // special support.
         newAcc = new EnumRoleAccessible<roles::GRAPHIC>(content, document);
       } else if (content->IsSVGElement(nsGkAtoms::svg)) {
         newAcc = new EnumRoleAccessible<roles::DIAGRAM>(content, document);
       }
 
--- a/dom/base/nsGkAtomList.h
+++ b/dom/base/nsGkAtomList.h
@@ -2046,27 +2046,27 @@ GK_ATOM(svgClipPathFrame, "SVGClipPathFr
 GK_ATOM(svgDefsFrame, "SVGDefsFrame")
 GK_ATOM(svgFEContainerFrame, "SVGFEContainerFrame")
 GK_ATOM(svgFEImageFrame, "SVGFEImageFrame")
 GK_ATOM(svgFELeafFrame, "SVGFELeafFrame")
 GK_ATOM(svgFEUnstyledLeafFrame, "SVGFEUnstyledLeafFrame")
 GK_ATOM(svgFilterFrame, "SVGFilterFrame")
 GK_ATOM(svgForeignObjectFrame, "SVGForeignObjectFrame")
 GK_ATOM(svgGenericContainerFrame, "SVGGenericContainerFrame")
-GK_ATOM(svgGeometryFrame, "SVGGeometryFrame")
 GK_ATOM(svgGFrame, "SVGGFrame")
 GK_ATOM(svgGradientFrame, "SVGGradientFrame")
 GK_ATOM(svgImageFrame, "SVGImageFrame")
 GK_ATOM(svgInnerSVGFrame, "SVGInnerSVGFrame")
 GK_ATOM(svgLinearGradientFrame, "SVGLinearGradientFrame")
 GK_ATOM(svgMarkerFrame, "SVGMarkerFrame")
 GK_ATOM(svgMarkerAnonChildFrame, "SVGMarkerAnonChildFrame")
 GK_ATOM(svgMaskFrame, "SVGMaskFrame")
 GK_ATOM(svgOuterSVGFrame, "SVGOuterSVGFrame")
 GK_ATOM(svgOuterSVGAnonChildFrame, "SVGOuterSVGAnonChildFrame")
+GK_ATOM(svgPathGeometryFrame, "SVGPathGeometryFrame")
 GK_ATOM(svgPatternFrame, "SVGPatternFrame")
 GK_ATOM(svgRadialGradientFrame, "SVGRadialGradientFrame")
 GK_ATOM(svgStopFrame, "SVGStopFrame")
 GK_ATOM(svgSwitchFrame, "SVGSwitchFrame")
 GK_ATOM(svgTextFrame, "SVGTextFrame")
 GK_ATOM(svgUseFrame, "SVGUseFrame")
 GK_ATOM(svgViewFrame, "SVGViewFrame")
 GK_ATOM(HTMLVideoFrame, "VideoFrame")
--- a/dom/svg/SVGCircleElement.cpp
+++ b/dom/svg/SVGCircleElement.cpp
@@ -75,17 +75,17 @@ SVGCircleElement::HasValidDimensions() c
 nsSVGElement::LengthAttributesInfo
 SVGCircleElement::GetLengthInfo()
 {
   return LengthAttributesInfo(mLengthAttributes, sLengthInfo,
                               ArrayLength(sLengthInfo));
 }
 
 //----------------------------------------------------------------------
-// SVGGeometryElement methods
+// nsSVGPathGeometryElement methods
 
 bool
 SVGCircleElement::GetGeometryBounds(Rect* aBounds,
                                     const StrokeOptions& aStrokeOptions,
                                     const Matrix& aToBoundsSpace,
                                     const Matrix* aToNonScalingStrokeSpace)
 {
   float x, y, r;
--- a/dom/svg/SVGCircleElement.h
+++ b/dom/svg/SVGCircleElement.h
@@ -2,40 +2,40 @@
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #ifndef mozilla_dom_SVGCircleElement_h
 #define mozilla_dom_SVGCircleElement_h
 
-#include "SVGGeometryElement.h"
+#include "nsSVGPathGeometryElement.h"
 #include "nsSVGLength2.h"
 
 nsresult NS_NewSVGCircleElement(nsIContent **aResult,
                                 already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo);
 
+typedef nsSVGPathGeometryElement SVGCircleElementBase;
+
 namespace mozilla {
 namespace dom {
 
-typedef SVGGeometryElement SVGCircleElementBase;
-
 class SVGCircleElement final : public SVGCircleElementBase
 {
 protected:
   explicit SVGCircleElement(already_AddRefed<mozilla::dom::NodeInfo>& aNodeInfo);
   virtual JSObject* WrapNode(JSContext *cx, JS::Handle<JSObject*> aGivenProto) override;
   friend nsresult (::NS_NewSVGCircleElement(nsIContent **aResult,
                                             already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo));
 
 public:
   // nsSVGSVGElement methods:
   virtual bool HasValidDimensions() const override;
 
-  // SVGGeometryElement methods:
+  // nsSVGPathGeometryElement methods:
   virtual bool GetGeometryBounds(Rect* aBounds, const StrokeOptions& aStrokeOptions,
                                  const Matrix& aToBoundsSpace,
                                  const Matrix* aToNonScalingStrokeSpace = nullptr) override;
   virtual already_AddRefed<Path> BuildPath(PathBuilder* aBuilder) override;
 
   virtual nsresult Clone(mozilla::dom::NodeInfo *aNodeInfo, nsINode **aResult) const override;
 
   // WebIDL
--- a/dom/svg/SVGEllipseElement.cpp
+++ b/dom/svg/SVGEllipseElement.cpp
@@ -86,17 +86,17 @@ SVGEllipseElement::HasValidDimensions() 
 nsSVGElement::LengthAttributesInfo
 SVGEllipseElement::GetLengthInfo()
 {
   return LengthAttributesInfo(mLengthAttributes, sLengthInfo,
                               ArrayLength(sLengthInfo));
 }
 
 //----------------------------------------------------------------------
-// SVGGeometryElement methods
+// nsSVGPathGeometryElement methods
 
 bool
 SVGEllipseElement::GetGeometryBounds(Rect* aBounds,
                                      const StrokeOptions& aStrokeOptions,
                                      const Matrix& aToBoundsSpace,
                                      const Matrix* aToNonScalingStrokeSpace)
 {
   float x, y, rx, ry;
--- a/dom/svg/SVGEllipseElement.h
+++ b/dom/svg/SVGEllipseElement.h
@@ -2,40 +2,40 @@
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #ifndef mozilla_dom_SVGEllipseElement_h
 #define mozilla_dom_SVGEllipseElement_h
 
-#include "SVGGeometryElement.h"
+#include "nsSVGPathGeometryElement.h"
 #include "nsSVGLength2.h"
 
 nsresult NS_NewSVGEllipseElement(nsIContent **aResult,
                                  already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo);
 
 namespace mozilla {
 namespace dom {
 
-typedef SVGGeometryElement SVGEllipseElementBase;
+typedef nsSVGPathGeometryElement SVGEllipseElementBase;
 
 class SVGEllipseElement final : public SVGEllipseElementBase
 {
 protected:
   explicit SVGEllipseElement(already_AddRefed<mozilla::dom::NodeInfo>& aNodeInfo);
   virtual JSObject* WrapNode(JSContext *cx, JS::Handle<JSObject*> aGivenProto) override;
   friend nsresult (::NS_NewSVGEllipseElement(nsIContent **aResult,
                                              already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo));
 
 public:
   // nsSVGSVGElement methods:
   virtual bool HasValidDimensions() const override;
 
-  // SVGGeometryElement methods:
+  // nsSVGPathGeometryElement methods:
   virtual bool GetGeometryBounds(Rect* aBounds, const StrokeOptions& aStrokeOptions,
                                  const Matrix& aToBoundsSpace,
                                  const Matrix* aToNonScalingStrokeSpace = nullptr) override;
   virtual already_AddRefed<Path> BuildPath(PathBuilder* aBuilder) override;
 
   virtual nsresult Clone(mozilla::dom::NodeInfo *aNodeInfo, nsINode **aResult) const override;
 
   // WebIDL
--- a/dom/svg/SVGImageElement.cpp
+++ b/dom/svg/SVGImageElement.cpp
@@ -230,17 +230,17 @@ SVGImageElement::IsAttributeMapped(const
     sViewportsMap,
   };
 
   return FindAttributeDependence(name, map) ||
     SVGImageElementBase::IsAttributeMapped(name);
 }
 
 //----------------------------------------------------------------------
-// SVGGeometryElement methods
+// nsSVGPathGeometryElement methods
 
 /* For the purposes of the update/invalidation logic pretend to
    be a rectangle. */
 bool
 SVGImageElement::GetGeometryBounds(Rect* aBounds,
                                    const StrokeOptions& aStrokeOptions,
                                    const Matrix& aToBoundsSpace,
                                    const Matrix* aToNonScalingStrokeSpace)
--- a/dom/svg/SVGImageElement.h
+++ b/dom/svg/SVGImageElement.h
@@ -4,31 +4,31 @@
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #ifndef mozilla_dom_SVGImageElement_h
 #define mozilla_dom_SVGImageElement_h
 
 #include "nsImageLoadingContent.h"
 #include "nsSVGLength2.h"
+#include "nsSVGPathGeometryElement.h"
 #include "nsSVGString.h"
-#include "SVGGeometryElement.h"
 #include "SVGAnimatedPreserveAspectRatio.h"
 
 nsresult NS_NewSVGImageElement(nsIContent **aResult,
                                already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo);
 
+typedef nsSVGPathGeometryElement SVGImageElementBase;
+
 class nsSVGImageFrame;
 
 namespace mozilla {
 namespace dom {
 class DOMSVGAnimatedPreserveAspectRatio;
 
-typedef SVGGeometryElement SVGImageElementBase;
-
 class SVGImageElement : public SVGImageElementBase,
                         public nsImageLoadingContent
 {
   friend class ::nsSVGImageFrame;
 
 protected:
   explicit SVGImageElement(already_AddRefed<mozilla::dom::NodeInfo>& aNodeInfo);
   virtual ~SVGImageElement();
@@ -51,17 +51,17 @@ public:
                               nsIContent* aBindingParent,
                               bool aCompileEventHandlers) override;
   virtual void UnbindFromTree(bool aDeep, bool aNullParent) override;
 
   virtual EventStates IntrinsicState() const override;
 
   NS_IMETHOD_(bool) IsAttributeMapped(const nsIAtom* name) const override;
 
-  // SVGGeometryElement methods:
+  // nsSVGPathGeometryElement methods:
   virtual bool GetGeometryBounds(Rect* aBounds, const StrokeOptions& aStrokeOptions,
                                  const Matrix& aToBoundsSpace,
                                  const Matrix* aToNonScalingStrokeSpace = nullptr) override;
   virtual already_AddRefed<Path> BuildPath(PathBuilder* aBuilder) override;
 
   // nsSVGSVGElement methods:
   virtual bool HasValidDimensions() const override;
 
--- a/dom/svg/SVGLineElement.cpp
+++ b/dom/svg/SVGLineElement.cpp
@@ -105,17 +105,17 @@ SVGLineElement::IsAttributeMapped(const 
 nsSVGElement::LengthAttributesInfo
 SVGLineElement::GetLengthInfo()
 {
   return LengthAttributesInfo(mLengthAttributes, sLengthInfo,
                               ArrayLength(sLengthInfo));
 }
 
 //----------------------------------------------------------------------
-// SVGGeometryElement methods
+// nsSVGPathGeometryElement methods
 
 void
 SVGLineElement::GetMarkPoints(nsTArray<nsSVGMark> *aMarks) {
   float x1, y1, x2, y2;
 
   GetAnimatedLengthValues(&x1, &y1, &x2, &y2, nullptr);
 
   float angle = atan2(y2 - y1, x2 - x1);
--- a/dom/svg/SVGLineElement.h
+++ b/dom/svg/SVGLineElement.h
@@ -2,26 +2,26 @@
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #ifndef mozilla_dom_SVGLineElement_h
 #define mozilla_dom_SVGLineElement_h
 
-#include "SVGGeometryElement.h"
+#include "nsSVGPathGeometryElement.h"
 #include "nsSVGLength2.h"
 
 nsresult NS_NewSVGLineElement(nsIContent **aResult,
                               already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo);
 
 namespace mozilla {
 namespace dom {
 
-typedef SVGGeometryElement SVGLineElementBase;
+typedef nsSVGPathGeometryElement SVGLineElementBase;
 
 class SVGLineElement final : public SVGLineElementBase
 {
 protected:
   explicit SVGLineElement(already_AddRefed<mozilla::dom::NodeInfo>& aNodeInfo);
   virtual JSObject* WrapNode(JSContext *cx, JS::Handle<JSObject*> aGivenProto) override;
   friend nsresult (::NS_NewSVGLineElement(nsIContent **aResult,
                                           already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo));
@@ -29,17 +29,17 @@ protected:
   // a tiny amount to a barely-nonzero-length line that all of our draw targets
   // will render
   void MaybeAdjustForZeroLength(float aX1, float aY1, float& aX2, float aY2);
 
 public:
   // nsIContent interface
   NS_IMETHOD_(bool) IsAttributeMapped(const nsIAtom* name) const override;
 
-  // SVGGeometryElement methods:
+  // nsSVGPathGeometryElement methods:
   virtual bool IsMarkable() override { return true; }
   virtual void GetMarkPoints(nsTArray<nsSVGMark> *aMarks) override;
   virtual void GetAsSimplePath(SimplePath* aSimplePath) override;
   virtual already_AddRefed<Path> BuildPath(PathBuilder* aBuilder) override;
   virtual bool GetGeometryBounds(Rect* aBounds, const StrokeOptions& aStrokeOptions,
                                  const Matrix& aToBoundsSpace,
                                  const Matrix* aToNonScalingStrokeSpace = nullptr) override;
 
--- a/dom/svg/SVGPathData.cpp
+++ b/dom/svg/SVGPathData.cpp
@@ -10,20 +10,20 @@
 #include "gfxPlatform.h"
 #include "mozilla/gfx/2D.h"
 #include "mozilla/gfx/Types.h"
 #include "mozilla/gfx/Point.h"
 #include "mozilla/RefPtr.h"
 #include "nsError.h"
 #include "nsString.h"
 #include "nsSVGPathDataParser.h"
+#include "nsSVGPathGeometryElement.h" // for nsSVGMark
 #include <stdarg.h>
 #include "nsStyleConsts.h"
 #include "SVGContentUtils.h"
-#include "SVGGeometryElement.h" // for nsSVGMark
 #include "SVGPathSegUtils.h"
 #include <algorithm>
 
 using namespace mozilla;
 using namespace mozilla::gfx;
 
 static bool IsMoveto(uint16_t aSegType)
 {
--- a/dom/svg/SVGPathElement.cpp
+++ b/dom/svg/SVGPathElement.cpp
@@ -1,19 +1,21 @@
+/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #include "mozilla/dom/SVGPathElement.h"
 
 #include <algorithm>
 
 #include "DOMSVGPathSeg.h"
 #include "DOMSVGPathSegList.h"
+#include "DOMSVGPoint.h"
 #include "gfx2DGlue.h"
 #include "gfxPlatform.h"
 #include "mozilla/dom/SVGPathElementBinding.h"
 #include "mozilla/gfx/2D.h"
 #include "mozilla/RefPtr.h"
 #include "nsCOMPtr.h"
 #include "nsComputedDOMStyle.h"
 #include "nsGkAtoms.h"
@@ -29,16 +31,19 @@ namespace mozilla {
 namespace dom {
 
 JSObject*
 SVGPathElement::WrapNode(JSContext *aCx, JS::Handle<JSObject*> aGivenProto)
 {
   return SVGPathElementBinding::Wrap(aCx, this, aGivenProto);
 }
 
+nsSVGElement::NumberInfo SVGPathElement::sNumberInfo = 
+{ &nsGkAtoms::pathLength, 0, false };
+
 //----------------------------------------------------------------------
 // Implementation
 
 SVGPathElement::SVGPathElement(already_AddRefed<mozilla::dom::NodeInfo>& aNodeInfo)
   : SVGPathElementBase(aNodeInfo)
 {
 }
 
@@ -52,16 +57,55 @@ SVGPathElement::SizeOfExcludingThis(mozi
          mD.SizeOfExcludingThis(aMallocSizeOf);
 }
 
 //----------------------------------------------------------------------
 // nsIDOMNode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGPathElement)
 
+already_AddRefed<SVGAnimatedNumber>
+SVGPathElement::PathLength()
+{
+  return mPathLength.ToDOMAnimatedNumber(this);
+}
+
+float
+SVGPathElement::GetTotalLength()
+{
+  RefPtr<Path> flat = GetOrBuildPathForMeasuring();
+  return flat ? flat->ComputeLength() : 0.f;
+}
+
+already_AddRefed<nsISVGPoint>
+SVGPathElement::GetPointAtLength(float distance, ErrorResult& rv)
+{
+  RefPtr<Path> path = GetOrBuildPathForMeasuring();
+  if (!path) {
+    rv.Throw(NS_ERROR_FAILURE);
+    return nullptr;
+  }
+
+  float totalLength = path->ComputeLength();
+  if (mPathLength.IsExplicitlySet()) {
+    float pathLength = mPathLength.GetAnimValue();
+    if (pathLength <= 0) {
+      rv.Throw(NS_ERROR_FAILURE);
+      return nullptr;
+    }
+    distance *= totalLength / pathLength;
+  }
+  distance = std::max(0.f,         distance);
+  distance = std::min(totalLength, distance);
+
+  nsCOMPtr<nsISVGPoint> point =
+    new DOMSVGPoint(path->ComputePointAtLength(distance));
+  return point.forget();
+}
+
 uint32_t
 SVGPathElement::GetPathSegAtLength(float distance)
 {
   return mD.GetAnimValue().GetPathSegAtLength(distance);
 }
 
 already_AddRefed<DOMSVGPathSegClosePath>
 SVGPathElement::CreateSVGPathSegClosePath()
@@ -236,16 +280,22 @@ SVGPathElement::AnimatedPathSegList()
 // nsSVGElement methods
 
 /* virtual */ bool
 SVGPathElement::HasValidDimensions() const
 {
   return !mD.GetAnimValue().IsEmpty();
 }
 
+nsSVGElement::NumberAttributesInfo
+SVGPathElement::GetNumberInfo()
+{
+  return NumberAttributesInfo(&mPathLength, &sNumberInfo, 1);
+}
+
 //----------------------------------------------------------------------
 // nsIContent methods
 
 NS_IMETHODIMP_(bool)
 SVGPathElement::IsAttributeMapped(const nsIAtom* name) const
 {
   static const MappedAttributeEntry* const map[] = {
     sMarkersMap
@@ -257,17 +307,17 @@ SVGPathElement::IsAttributeMapped(const 
 
 already_AddRefed<Path>
 SVGPathElement::GetOrBuildPathForMeasuring()
 {
   return mD.GetAnimValue().BuildPathForMeasuring();
 }
 
 //----------------------------------------------------------------------
-// SVGGeometryElement methods
+// nsSVGPathGeometryElement methods
 
 bool
 SVGPathElement::AttributeDefinesGeometry(const nsIAtom *aName)
 {
   return aName == nsGkAtoms::d ||
          aName == nsGkAtoms::pathLength;
 }
 
--- a/dom/svg/SVGPathElement.h
+++ b/dom/svg/SVGPathElement.h
@@ -4,31 +4,32 @@
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #ifndef mozilla_dom_SVGPathElement_h
 #define mozilla_dom_SVGPathElement_h
 
 #include "mozilla/gfx/2D.h"
 #include "mozilla/RefPtr.h"
+#include "nsSVGNumber2.h"
+#include "nsSVGPathGeometryElement.h"
 #include "SVGAnimatedPathSegList.h"
-#include "SVGGeometryElement.h"
 #include "DOMSVGPathSeg.h"
 
 nsresult NS_NewSVGPathElement(nsIContent **aResult,
                               already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo);
 
+typedef nsSVGPathGeometryElement SVGPathElementBase;
+
 namespace mozilla {
 
 class nsISVGPoint;
 
 namespace dom {
 
-typedef SVGGeometryElement SVGPathElementBase;
-
 class SVGPathElement final : public SVGPathElementBase
 {
   typedef mozilla::gfx::Path Path;
 
 protected:
   friend nsresult (::NS_NewSVGPathElement(nsIContent **aResult,
                                           already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo));
   virtual JSObject* WrapNode(JSContext *cx, JS::Handle<JSObject*> aGivenProto) override;
@@ -39,17 +40,17 @@ public:
   NS_DECL_SIZEOF_EXCLUDING_THIS
 
   // nsIContent interface
   NS_IMETHOD_(bool) IsAttributeMapped(const nsIAtom* name) const override;
 
   // nsSVGSVGElement methods:
   virtual bool HasValidDimensions() const override;
 
-  // SVGGeometryElement methods:
+  // nsSVGPathGeometryElement methods:
   virtual bool AttributeDefinesGeometry(const nsIAtom *aName) override;
   virtual bool IsMarkable() override;
   virtual void GetMarkPoints(nsTArray<nsSVGMark> *aMarks) override;
   virtual already_AddRefed<Path> BuildPath(PathBuilder* aBuilder) override;
 
   /**
    * This returns a path without the extra little line segments that
    * ApproximateZeroLengthSubpathSquareCaps can insert if we have square-caps.
@@ -76,16 +77,19 @@ public:
   /**
    * Gets the ratio of the actual path length to the content author's estimated
    * length (as provided by the <path> element's 'pathLength' attribute). This
    * is used to scale stroke dashing, and to scale offsets along a textPath.
    */
   float GetPathLengthScale(PathLengthScaleForType aFor);
 
   // WebIDL
+  already_AddRefed<SVGAnimatedNumber> PathLength();
+  float GetTotalLength();
+  already_AddRefed<nsISVGPoint> GetPointAtLength(float distance, ErrorResult& rv);
   uint32_t GetPathSegAtLength(float distance);
   already_AddRefed<DOMSVGPathSegClosePath> CreateSVGPathSegClosePath();
   already_AddRefed<DOMSVGPathSegMovetoAbs> CreateSVGPathSegMovetoAbs(float x, float y);
   already_AddRefed<DOMSVGPathSegMovetoRel> CreateSVGPathSegMovetoRel(float x, float y);
   already_AddRefed<DOMSVGPathSegLinetoAbs> CreateSVGPathSegLinetoAbs(float x, float y);
   already_AddRefed<DOMSVGPathSegLinetoRel> CreateSVGPathSegLinetoRel(float x, float y);
   already_AddRefed<DOMSVGPathSegCurvetoCubicAbs>
     CreateSVGPathSegCurvetoCubicAbs(float x, float y, float x1, float y1, float x2, float y2);
@@ -111,15 +115,20 @@ public:
     CreateSVGPathSegCurvetoQuadraticSmoothAbs(float x, float y);
   already_AddRefed<DOMSVGPathSegCurvetoQuadraticSmoothRel>
     CreateSVGPathSegCurvetoQuadraticSmoothRel(float x, float y);
   already_AddRefed<DOMSVGPathSegList> PathSegList();
   already_AddRefed<DOMSVGPathSegList> AnimatedPathSegList();
 
 protected:
 
+  // nsSVGElement method
+  virtual NumberAttributesInfo GetNumberInfo() override;
+
   SVGAnimatedPathSegList mD;
+  nsSVGNumber2 mPathLength;
+  static NumberInfo sNumberInfo;
 };
 
 } // namespace dom
 } // namespace mozilla
 
 #endif // mozilla_dom_SVGPathElement_h
--- a/dom/svg/SVGPolygonElement.cpp
+++ b/dom/svg/SVGPolygonElement.cpp
@@ -32,36 +32,36 @@ SVGPolygonElement::SVGPolygonElement(alr
 }
 
 //----------------------------------------------------------------------
 // nsIDOMNode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGPolygonElement)
 
 //----------------------------------------------------------------------
-// SVGGeometryElement methods
+// nsSVGPathGeometryElement methods
 
 void
 SVGPolygonElement::GetMarkPoints(nsTArray<nsSVGMark> *aMarks)
 {
-  SVGPolyElement::GetMarkPoints(aMarks);
+  nsSVGPolyElement::GetMarkPoints(aMarks);
 
   if (aMarks->IsEmpty() || aMarks->LastElement().type != nsSVGMark::eEnd) {
     return;
   }
 
   nsSVGMark *endMark = &aMarks->LastElement();
   nsSVGMark *startMark = &aMarks->ElementAt(0);
   float angle = atan2(startMark->y - endMark->y, startMark->x - endMark->x);
 
   endMark->type = nsSVGMark::eMid;
   endMark->angle = SVGContentUtils::AngleBisect(angle, endMark->angle);
   startMark->angle = SVGContentUtils::AngleBisect(angle, startMark->angle);
   // for a polygon (as opposed to a polyline) there's an implicit extra point
-  // co-located with the start point that SVGPolyElement::GetMarkPoints
+  // co-located with the start point that nsSVGPolyElement::GetMarkPoints
   // doesn't return
   aMarks->AppendElement(nsSVGMark(startMark->x, startMark->y, startMark->angle,
                                   nsSVGMark::eEnd));
 }
 
 already_AddRefed<Path>
 SVGPolygonElement::BuildPath(PathBuilder* aBuilder)
 {
--- a/dom/svg/SVGPolygonElement.h
+++ b/dom/svg/SVGPolygonElement.h
@@ -3,36 +3,36 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #ifndef mozilla_dom_SVGPolygonElement_h
 #define mozilla_dom_SVGPolygonElement_h
 
 #include "mozilla/Attributes.h"
-#include "SVGPolyElement.h"
+#include "nsSVGPolyElement.h"
 
 nsresult NS_NewSVGPolygonElement(nsIContent **aResult,
                                  already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo);
 
+typedef nsSVGPolyElement SVGPolygonElementBase;
+
 namespace mozilla {
 namespace dom {
 
-typedef SVGPolyElement SVGPolygonElementBase;
-
 class SVGPolygonElement final : public SVGPolygonElementBase
 {
 protected:
   explicit SVGPolygonElement(already_AddRefed<mozilla::dom::NodeInfo>& aNodeInfo);
   virtual JSObject* WrapNode(JSContext *cx, JS::Handle<JSObject*> aGivenProto) override;
   friend nsresult (::NS_NewSVGPolygonElement(nsIContent **aResult,
                                              already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo));
 
 public:
-  // SVGGeometryElement methods:
+  // nsSVGPathGeometryElement methods:
   virtual void GetMarkPoints(nsTArray<nsSVGMark> *aMarks) override;
   virtual already_AddRefed<Path> BuildPath(PathBuilder* aBuilder) override;
 
   virtual nsresult Clone(mozilla::dom::NodeInfo *aNodeInfo, nsINode **aResult) const override;
 };
 
 } // namespace dom
 } // namespace mozilla
--- a/dom/svg/SVGPolylineElement.cpp
+++ b/dom/svg/SVGPolylineElement.cpp
@@ -31,17 +31,17 @@ SVGPolylineElement::SVGPolylineElement(a
 }
 
 //----------------------------------------------------------------------
 // nsIDOMNode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGPolylineElement)
 
 //----------------------------------------------------------------------
-// SVGGeometryElement methods
+// nsSVGPathGeometryElement methods
 
 already_AddRefed<Path>
 SVGPolylineElement::BuildPath(PathBuilder* aBuilder)
 {
   const SVGPointList &points = mPoints.GetAnimValue();
 
   if (points.IsEmpty()) {
     return nullptr;
--- a/dom/svg/SVGPolylineElement.h
+++ b/dom/svg/SVGPolylineElement.h
@@ -2,35 +2,35 @@
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #ifndef mozilla_dom_SVGPolylineElement_h
 #define mozilla_dom_SVGPolylineElement_h
 
-#include "SVGPolyElement.h"
+#include "nsSVGPolyElement.h"
 
 nsresult NS_NewSVGPolylineElement(nsIContent **aResult,
                                   already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo);
 
+typedef nsSVGPolyElement SVGPolylineElementBase;
+
 namespace mozilla {
 namespace dom {
 
-typedef SVGPolyElement SVGPolylineElementBase;
-
 class SVGPolylineElement final : public SVGPolylineElementBase
 {
 protected:
   explicit SVGPolylineElement(already_AddRefed<mozilla::dom::NodeInfo>& aNodeInfo);
   virtual JSObject* WrapNode(JSContext *cx, JS::Handle<JSObject*> aGivenProto) override;
   friend nsresult (::NS_NewSVGPolylineElement(nsIContent **aResult,
                                               already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo));
 
-  // SVGGeometryElement methods:
+  // nsSVGPathGeometryElement methods:
   virtual already_AddRefed<Path> BuildPath(PathBuilder* aBuilder) override;
 
 public:
   // nsIContent interface
   virtual nsresult Clone(mozilla::dom::NodeInfo *aNodeInfo, nsINode **aResult) const override;
 };
 
 } // namespace dom
--- a/dom/svg/SVGRectElement.cpp
+++ b/dom/svg/SVGRectElement.cpp
@@ -104,17 +104,17 @@ SVGRectElement::HasValidDimensions() con
 nsSVGElement::LengthAttributesInfo
 SVGRectElement::GetLengthInfo()
 {
   return LengthAttributesInfo(mLengthAttributes, sLengthInfo,
                               ArrayLength(sLengthInfo));
 }
 
 //----------------------------------------------------------------------
-// SVGGeometryElement methods
+// nsSVGPathGeometryElement methods
 
 bool
 SVGRectElement::GetGeometryBounds(Rect* aBounds,
                                   const StrokeOptions& aStrokeOptions,
                                   const Matrix& aToBoundsSpace,
                                   const Matrix* aToNonScalingStrokeSpace)
 {
   Rect rect;
--- a/dom/svg/SVGRectElement.h
+++ b/dom/svg/SVGRectElement.h
@@ -2,40 +2,40 @@
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #ifndef mozilla_dom_SVGRectElement_h
 #define mozilla_dom_SVGRectElement_h
 
+#include "nsSVGPathGeometryElement.h"
 #include "nsSVGLength2.h"
-#include "SVGGeometryElement.h"
 
 nsresult NS_NewSVGRectElement(nsIContent **aResult,
                               already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo);
 
+typedef nsSVGPathGeometryElement SVGRectElementBase;
+
 namespace mozilla {
 namespace dom {
 
-typedef SVGGeometryElement SVGRectElementBase;
-
 class SVGRectElement final : public SVGRectElementBase
 {
 protected:
   explicit SVGRectElement(already_AddRefed<mozilla::dom::NodeInfo>& aNodeInfo);
   virtual JSObject* WrapNode(JSContext *cx, JS::Handle<JSObject*> aGivenProto) override;
   friend nsresult (::NS_NewSVGRectElement(nsIContent **aResult,
                                           already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo));
 
 public:
   // nsSVGSVGElement methods:
   virtual bool HasValidDimensions() const override;
 
-  // SVGGeometryElement methods:
+  // nsSVGPathGeometryElement methods:
   virtual bool GetGeometryBounds(Rect* aBounds, const StrokeOptions& aStrokeOptions,
                                  const Matrix& aToBoundsSpace,
                                  const Matrix* aToNonScalingStrokeSpace = nullptr) override;
   virtual void GetAsSimplePath(SimplePath* aSimplePath) override;
   virtual already_AddRefed<Path> BuildPath(PathBuilder* aBuilder = nullptr) override;
 
   virtual nsresult Clone(mozilla::dom::NodeInfo *aNodeInfo, nsINode **aResult) const override;
 
--- a/dom/svg/moz.build
+++ b/dom/svg/moz.build
@@ -59,17 +59,16 @@ EXPORTS.mozilla.dom += [
     'SVGFEPointLightElement.h',
     'SVGFESpecularLightingElement.h',
     'SVGFESpotLightElement.h',
     'SVGFETileElement.h',
     'SVGFETurbulenceElement.h',
     'SVGFilterElement.h',
     'SVGForeignObjectElement.h',
     'SVGGElement.h',
-    'SVGGeometryElement.h',
     'SVGGradientElement.h',
     'SVGGraphicsElement.h',
     'SVGImageElement.h',
     'SVGIRect.h',
     'SVGLineElement.h',
     'SVGMarkerElement.h',
     'SVGMaskElement.h',
     'SVGMatrix.h',
@@ -126,16 +125,18 @@ UNIFIED_SOURCES += [
     'nsSVGFeatures.cpp',
     'nsSVGFilters.cpp',
     'nsSVGInteger.cpp',
     'nsSVGIntegerPair.cpp',
     'nsSVGLength2.cpp',
     'nsSVGNumber2.cpp',
     'nsSVGNumberPair.cpp',
     'nsSVGPathDataParser.cpp',
+    'nsSVGPathGeometryElement.cpp',
+    'nsSVGPolyElement.cpp',
     'nsSVGString.cpp',
     'nsSVGTransform.cpp',
     'nsSVGViewBox.cpp',
     'SVGAElement.cpp',
     'SVGAngle.cpp',
     'SVGAnimatedAngle.cpp',
     'SVGAnimatedBoolean.cpp',
     'SVGAnimatedEnumeration.cpp',
@@ -183,17 +184,16 @@ UNIFIED_SOURCES += [
     'SVGFESpecularLightingElement.cpp',
     'SVGFESpotLightElement.cpp',
     'SVGFETileElement.cpp',
     'SVGFETurbulenceElement.cpp',
     'SVGFilterElement.cpp',
     'SVGForeignObjectElement.cpp',
     'SVGFragmentIdentifier.cpp',
     'SVGGElement.cpp',
-    'SVGGeometryElement.cpp',
     'SVGGradientElement.cpp',
     'SVGGraphicsElement.cpp',
     'SVGImageElement.cpp',
     'SVGIntegerPairSMILType.cpp',
     'SVGLength.cpp',
     'SVGLengthList.cpp',
     'SVGLengthListSMILType.cpp',
     'SVGLineElement.cpp',
@@ -212,17 +212,16 @@ UNIFIED_SOURCES += [
     'SVGOrientSMILType.cpp',
     'SVGPathData.cpp',
     'SVGPathElement.cpp',
     'SVGPathSegListSMILType.cpp',
     'SVGPathSegUtils.cpp',
     'SVGPatternElement.cpp',
     'SVGPointList.cpp',
     'SVGPointListSMILType.cpp',
-    'SVGPolyElement.cpp',
     'SVGPolygonElement.cpp',
     'SVGPolylineElement.cpp',
     'SVGPreserveAspectRatio.cpp',
     'SVGRect.cpp',
     'SVGRectElement.cpp',
     'SVGScriptElement.cpp',
     'SVGSetElement.cpp',
     'SVGStopElement.cpp',
--- a/dom/svg/nsSVGElement.cpp
+++ b/dom/svg/nsSVGElement.cpp
@@ -11,16 +11,17 @@
 #include "nsSVGElement.h"
 
 #include "mozilla/dom/SVGSVGElement.h"
 #include "mozilla/dom/SVGTests.h"
 #include "nsContentUtils.h"
 #include "nsICSSDeclaration.h"
 #include "nsIDocument.h"
 #include "nsIDOMMutationEvent.h"
+#include "nsSVGPathGeometryElement.h"
 #include "mozilla/InternalMutationEvent.h"
 #include "nsError.h"
 #include "nsIPresShell.h"
 #include "nsGkAtoms.h"
 #include "mozilla/css/StyleRule.h"
 #include "nsRuleWalker.h"
 #include "mozilla/css/Declaration.h"
 #include "nsCSSProps.h"
@@ -39,17 +40,16 @@
 #include "nsSVGViewBox.h"
 #include "nsSVGString.h"
 #include "mozilla/dom/SVGAnimatedEnumeration.h"
 #include "SVGAnimatedNumberList.h"
 #include "SVGAnimatedLengthList.h"
 #include "SVGAnimatedPointList.h"
 #include "SVGAnimatedPathSegList.h"
 #include "SVGContentUtils.h"
-#include "SVGGeometryElement.h"
 #include "nsIFrame.h"
 #include "nsQueryObject.h"
 #include <stdarg.h>
 #include "nsSMILMappedAttribute.h"
 #include "SVGMotionSMILAttr.h"
 #include "nsAttrValueOrString.h"
 #include "nsSMILAnimationController.h"
 #include "mozilla/dom/SVGElementBinding.h"
rename from dom/svg/SVGGeometryElement.cpp
rename to dom/svg/nsSVGPathGeometryElement.cpp
--- a/dom/svg/SVGGeometryElement.cpp
+++ b/dom/svg/nsSVGPathGeometryElement.cpp
@@ -1,102 +1,88 @@
 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
-#include "SVGGeometryElement.h"
+#include "nsSVGPathGeometryElement.h"
 
-#include "DOMSVGPoint.h"
 #include "gfxPlatform.h"
 #include "mozilla/gfx/2D.h"
 #include "nsComputedDOMStyle.h"
 #include "nsSVGUtils.h"
 #include "nsSVGLength2.h"
 #include "SVGContentUtils.h"
 
 using namespace mozilla;
 using namespace mozilla::gfx;
 
-nsSVGElement::NumberInfo SVGGeometryElement::sNumberInfo =
-{ &nsGkAtoms::pathLength, 0, false };
-
 //----------------------------------------------------------------------
 // Implementation
 
-SVGGeometryElement::SVGGeometryElement(already_AddRefed<mozilla::dom::NodeInfo>& aNodeInfo)
-  : SVGGeometryElementBase(aNodeInfo)
+nsSVGPathGeometryElement::nsSVGPathGeometryElement(already_AddRefed<mozilla::dom::NodeInfo>& aNodeInfo)
+  : nsSVGPathGeometryElementBase(aNodeInfo)
 {
 }
 
-nsSVGElement::NumberAttributesInfo
-SVGGeometryElement::GetNumberInfo()
-{
-  return NumberAttributesInfo(&mPathLength, &sNumberInfo, 1);
-}
-
 nsresult
-SVGGeometryElement::AfterSetAttr(int32_t aNamespaceID, nsIAtom* aName,
-                                 const nsAttrValue* aValue, bool aNotify)
+nsSVGPathGeometryElement::AfterSetAttr(int32_t aNamespaceID, nsIAtom* aName,
+                                       const nsAttrValue* aValue, bool aNotify)
 {
   if (mCachedPath &&
       aNamespaceID == kNameSpaceID_None &&
       AttributeDefinesGeometry(aName)) {
     mCachedPath = nullptr;
   }
-  return SVGGeometryElementBase::AfterSetAttr(aNamespaceID, aName,
-                                              aValue, aNotify);
+  return nsSVGPathGeometryElementBase::AfterSetAttr(aNamespaceID, aName,
+                                                    aValue, aNotify);
 }
 
 bool
-SVGGeometryElement::AttributeDefinesGeometry(const nsIAtom *aName)
+nsSVGPathGeometryElement::AttributeDefinesGeometry(const nsIAtom *aName)
 {
-  if (aName == nsGkAtoms::pathLength) {
-    return true;
-  }
-
   // Check for nsSVGLength2 attribute
   LengthAttributesInfo info = GetLengthInfo();
   for (uint32_t i = 0; i < info.mLengthCount; i++) {
     if (aName == *info.mLengthInfo[i].mName) {
       return true;
     }
   }
 
   return false;
 }
 
 bool
-SVGGeometryElement::GeometryDependsOnCoordCtx()
+nsSVGPathGeometryElement::GeometryDependsOnCoordCtx()
 {
   // Check the nsSVGLength2 attribute
-  LengthAttributesInfo info = const_cast<SVGGeometryElement*>(this)->GetLengthInfo();
+  LengthAttributesInfo info = const_cast<nsSVGPathGeometryElement*>(this)->GetLengthInfo();
   for (uint32_t i = 0; i < info.mLengthCount; i++) {
     if (info.mLengths[i].GetSpecifiedUnitType() == nsIDOMSVGLength::SVG_LENGTHTYPE_PERCENTAGE) {
       return true;
     }   
   }
   return false;
 }
 
 bool
-SVGGeometryElement::IsMarkable()
+nsSVGPathGeometryElement::IsMarkable()
 {
   return false;
 }
 
 void
-SVGGeometryElement::GetMarkPoints(nsTArray<nsSVGMark> *aMarks)
+nsSVGPathGeometryElement::GetMarkPoints(nsTArray<nsSVGMark> *aMarks)
 {
 }
 
 already_AddRefed<Path>
-SVGGeometryElement::GetOrBuildPath(const DrawTarget& aDrawTarget,
-                                   FillRule aFillRule)
+nsSVGPathGeometryElement::GetOrBuildPath(const DrawTarget& aDrawTarget,
+                                         FillRule aFillRule)
 {
   // We only cache the path if it matches the backend used for screen painting:
   bool cacheable  = aDrawTarget.GetBackendType() ==
                     gfxPlatform::GetPlatform()->GetDefaultContentBackend();
 
   // Checking for and returning mCachedPath before checking the pref means
   // that the pref is only live on page reload (or app restart for SVG in
   // chrome). The benefit is that we avoid causing a CPU memory cache miss by
@@ -111,23 +97,23 @@ SVGGeometryElement::GetOrBuildPath(const
   RefPtr<Path> path = BuildPath(builder);
   if (cacheable && NS_SVGPathCachingEnabled()) {
     mCachedPath = path;
   }
   return path.forget();
 }
 
 already_AddRefed<Path>
-SVGGeometryElement::GetOrBuildPathForMeasuring()
+nsSVGPathGeometryElement::GetOrBuildPathForMeasuring()
 {
   return nullptr;
 }
 
 FillRule
-SVGGeometryElement::GetFillRule()
+nsSVGPathGeometryElement::GetFillRule()
 {
   FillRule fillRule = FillRule::FILL_WINDING; // Equivalent to StyleFillRule::Nonzero
 
   RefPtr<nsStyleContext> styleContext =
     nsComputedDOMStyle::GetStyleContextForElementNoFlush(this, nullptr,
                                                          nullptr);
   
   if (styleContext) {
@@ -139,47 +125,8 @@ SVGGeometryElement::GetFillRule()
     }
   } else {
     // ReportToConsole
     NS_WARNING("Couldn't get style context for content in GetFillRule");
   }
 
   return fillRule;
 }
-
-float
-SVGGeometryElement::GetTotalLength()
-{
-  RefPtr<Path> flat = GetOrBuildPathForMeasuring();
-  return flat ? flat->ComputeLength() : 0.f;
-}
-
-already_AddRefed<nsISVGPoint>
-SVGGeometryElement::GetPointAtLength(float distance, ErrorResult& rv)
-{
-  RefPtr<Path> path = GetOrBuildPathForMeasuring();
-  if (!path) {
-    rv.Throw(NS_ERROR_FAILURE);
-    return nullptr;
-  }
-
-  float totalLength = path->ComputeLength();
-  if (mPathLength.IsExplicitlySet()) {
-    float pathLength = mPathLength.GetAnimValue();
-    if (pathLength <= 0) {
-      rv.Throw(NS_ERROR_FAILURE);
-      return nullptr;
-    }
-    distance *= totalLength / pathLength;
-  }
-  distance = std::max(0.f,         distance);
-  distance = std::min(totalLength, distance);
-
-  nsCOMPtr<nsISVGPoint> point =
-    new DOMSVGPoint(path->ComputePointAtLength(distance));
-  return point.forget();
-}
-
-already_AddRefed<SVGAnimatedNumber>
-SVGGeometryElement::PathLength()
-{
-  return mPathLength.ToDOMAnimatedNumber(this);
-}
rename from dom/svg/SVGGeometryElement.h
rename to dom/svg/nsSVGPathGeometryElement.h
--- a/dom/svg/SVGGeometryElement.h
+++ b/dom/svg/nsSVGPathGeometryElement.h
@@ -1,60 +1,53 @@
 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
-#ifndef mozilla_dom_SVGGeometryElement_h
-#define mozilla_dom_SVGGeometryElement_h
+#ifndef __NS_SVGPATHGEOMETRYELEMENT_H__
+#define __NS_SVGPATHGEOMETRYELEMENT_H__
 
 #include "mozilla/gfx/2D.h"
 #include "SVGGraphicsElement.h"
-#include "nsISVGPoint.h"
-#include "nsSVGNumber2.h"
 
 struct nsSVGMark {
   enum Type {
     eStart,
     eMid,
     eEnd,
 
     eTypeCount
   };
 
   float x, y, angle;
   Type type;
   nsSVGMark(float aX, float aY, float aAngle, Type aType) :
     x(aX), y(aY), angle(aAngle), type(aType) {}
 };
 
-namespace mozilla {
-namespace dom {
+typedef mozilla::dom::SVGGraphicsElement nsSVGPathGeometryElementBase;
 
-class SVGAnimatedNumber;
-
-typedef mozilla::dom::SVGGraphicsElement SVGGeometryElementBase;
-
-class SVGGeometryElement : public SVGGeometryElementBase
+class nsSVGPathGeometryElement : public nsSVGPathGeometryElementBase
 {
 protected:
   typedef mozilla::gfx::CapStyle CapStyle;
   typedef mozilla::gfx::DrawTarget DrawTarget;
   typedef mozilla::gfx::FillRule FillRule;
   typedef mozilla::gfx::Float Float;
   typedef mozilla::gfx::Matrix Matrix;
   typedef mozilla::gfx::Path Path;
   typedef mozilla::gfx::Point Point;
   typedef mozilla::gfx::PathBuilder PathBuilder;
   typedef mozilla::gfx::Rect Rect;
   typedef mozilla::gfx::StrokeOptions StrokeOptions;
 
 public:
-  explicit SVGGeometryElement(already_AddRefed<mozilla::dom::NodeInfo>& aNodeInfo);
+  explicit nsSVGPathGeometryElement(already_AddRefed<mozilla::dom::NodeInfo>& aNodeInfo);
 
   virtual nsresult AfterSetAttr(int32_t aNamespaceID, nsIAtom* aName,
                                 const nsAttrValue* aValue, bool aNotify) override;
 
   /**
    * Causes this element to discard any Path object that GetOrBuildPath may
    * have cached.
    */
@@ -161,17 +154,17 @@ public:
   }
 
   /**
    * Returns a Path that can be used to paint, hit-test or calculate bounds for
    * this element. May return nullptr if there is no [valid] path. The path
    * that is created may be cached and returned on subsequent calls.
    */
   virtual already_AddRefed<Path> GetOrBuildPath(const DrawTarget& aDrawTarget,
-                                                FillRule fillRule);
+                                                     FillRule fillRule);
 
   /**
    * The same as GetOrBuildPath, but bypasses the cache (neither returns any
    * previously cached Path, nor caches the Path that in does return).
    * this element. May return nullptr if there is no [valid] path.
    */
   virtual already_AddRefed<Path> BuildPath(PathBuilder* aBuilder) = 0;
 
@@ -193,27 +186,13 @@ public:
   virtual already_AddRefed<Path> GetOrBuildPathForMeasuring();
 
   /**
    * Returns the current computed value of the CSS property 'fill-rule' for
    * this element.
    */
   FillRule GetFillRule();
 
-  // WebIDL
-  already_AddRefed<SVGAnimatedNumber> PathLength();
-  float GetTotalLength();
-  already_AddRefed<nsISVGPoint>
-    GetPointAtLength(float distance, ErrorResult& rv);
-
 protected:
-  // nsSVGElement method
-  virtual NumberAttributesInfo GetNumberInfo() override;
-
-  nsSVGNumber2 mPathLength;
-  static NumberInfo sNumberInfo;
   mutable RefPtr<Path> mCachedPath;
 };
 
-} // namespace dom
-} // namespace mozilla
-
-#endif // mozilla_dom_SVGGeometryElement_h
+#endif
rename from dom/svg/SVGPolyElement.cpp
rename to dom/svg/nsSVGPolyElement.cpp
--- a/dom/svg/SVGPolyElement.cpp
+++ b/dom/svg/nsSVGPolyElement.cpp
@@ -1,97 +1,97 @@
 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
-#include "SVGPolyElement.h"
+#include "nsSVGPolyElement.h"
 #include "DOMSVGPointList.h"
 #include "mozilla/gfx/2D.h"
 #include "SVGContentUtils.h"
 
 using namespace mozilla;
 using namespace mozilla::gfx;
 
 //----------------------------------------------------------------------
 // nsISupports methods
 
-NS_IMPL_ADDREF_INHERITED(SVGPolyElement,SVGPolyElementBase)
-NS_IMPL_RELEASE_INHERITED(SVGPolyElement,SVGPolyElementBase)
+NS_IMPL_ADDREF_INHERITED(nsSVGPolyElement,nsSVGPolyElementBase)
+NS_IMPL_RELEASE_INHERITED(nsSVGPolyElement,nsSVGPolyElementBase)
 
-NS_INTERFACE_MAP_BEGIN(SVGPolyElement)
-NS_INTERFACE_MAP_END_INHERITING(SVGPolyElementBase)
+NS_INTERFACE_MAP_BEGIN(nsSVGPolyElement)
+NS_INTERFACE_MAP_END_INHERITING(nsSVGPolyElementBase)
 
 //----------------------------------------------------------------------
 // Implementation
 
-SVGPolyElement::SVGPolyElement(already_AddRefed<mozilla::dom::NodeInfo>& aNodeInfo)
-  : SVGPolyElementBase(aNodeInfo)
+nsSVGPolyElement::nsSVGPolyElement(already_AddRefed<mozilla::dom::NodeInfo>& aNodeInfo)
+  : nsSVGPolyElementBase(aNodeInfo)
 {
 }
 
-SVGPolyElement::~SVGPolyElement()
+nsSVGPolyElement::~nsSVGPolyElement()
 {
 }
 
 already_AddRefed<DOMSVGPointList>
-SVGPolyElement::Points()
+nsSVGPolyElement::Points()
 {
   void *key = mPoints.GetBaseValKey();
   RefPtr<DOMSVGPointList> points = DOMSVGPointList::GetDOMWrapper(key, this, false);
   return points.forget();
 }
 
 already_AddRefed<DOMSVGPointList>
-SVGPolyElement::AnimatedPoints()
+nsSVGPolyElement::AnimatedPoints()
 {
   void *key = mPoints.GetAnimValKey();
   RefPtr<DOMSVGPointList> points = DOMSVGPointList::GetDOMWrapper(key, this, true);
   return points.forget();
 }
 
 
 //----------------------------------------------------------------------
 // nsIContent methods
 
 NS_IMETHODIMP_(bool)
-SVGPolyElement::IsAttributeMapped(const nsIAtom* name) const
+nsSVGPolyElement::IsAttributeMapped(const nsIAtom* name) const
 {
   static const MappedAttributeEntry* const map[] = {
     sMarkersMap
   };
   
   return FindAttributeDependence(name, map) ||
-    SVGPolyElementBase::IsAttributeMapped(name);
+    nsSVGPolyElementBase::IsAttributeMapped(name);
 }
 
 //----------------------------------------------------------------------
 // nsSVGElement methods
 
 /* virtual */ bool
-SVGPolyElement::HasValidDimensions() const
+nsSVGPolyElement::HasValidDimensions() const
 {
   return !mPoints.GetAnimValue().IsEmpty();
 }
 
 //----------------------------------------------------------------------
-// SVGGeometryElement methods
+// nsSVGPathGeometryElement methods
 
 bool
-SVGPolyElement::AttributeDefinesGeometry(const nsIAtom *aName)
+nsSVGPolyElement::AttributeDefinesGeometry(const nsIAtom *aName)
 {
   if (aName == nsGkAtoms::points)
     return true;
 
   return false;
 }
 
 void
-SVGPolyElement::GetMarkPoints(nsTArray<nsSVGMark> *aMarks)
+nsSVGPolyElement::GetMarkPoints(nsTArray<nsSVGMark> *aMarks)
 {
   const SVGPointList &points = mPoints.GetAnimValue();
 
   if (!points.Length())
     return;
 
   float px = points[0].mX, py = points[0].mY, prevAngle = 0.0;
 
@@ -117,20 +117,20 @@ SVGPolyElement::GetMarkPoints(nsTArray<n
     py = y;
   }
 
   aMarks->LastElement().angle = prevAngle;
   aMarks->LastElement().type = nsSVGMark::eEnd;
 }
 
 bool
-SVGPolyElement::GetGeometryBounds(Rect* aBounds,
-                                  const StrokeOptions& aStrokeOptions,
-                                  const Matrix& aToBoundsSpace,
-                                  const Matrix* aToNonScalingStrokeSpace)
+nsSVGPolyElement::GetGeometryBounds(Rect* aBounds,
+                                    const StrokeOptions& aStrokeOptions,
+                                    const Matrix& aToBoundsSpace,
+                                    const Matrix* aToNonScalingStrokeSpace)
 {
   const SVGPointList &points = mPoints.GetAnimValue();
 
   if (!points.Length()) {
     // Rendering of the element is disabled
     aBounds->SetEmpty();
     return true;
   }
rename from dom/svg/SVGPolyElement.h
rename to dom/svg/nsSVGPolyElement.h
--- a/dom/svg/SVGPolyElement.h
+++ b/dom/svg/nsSVGPolyElement.h
@@ -3,32 +3,31 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #ifndef NS_SVGPOLYELEMENT_H_
 #define NS_SVGPOLYELEMENT_H_
 
 #include "mozilla/Attributes.h"
+#include "nsSVGPathGeometryElement.h"
 #include "SVGAnimatedPointList.h"
-#include "SVGGeometryElement.h"
+
+typedef nsSVGPathGeometryElement nsSVGPolyElementBase;
 
 namespace mozilla {
 class DOMSVGPointList;
-
-namespace dom {
+} // namespace mozilla
 
-typedef SVGGeometryElement SVGPolyElementBase;
-
-class SVGPolyElement : public SVGPolyElementBase
+class nsSVGPolyElement : public nsSVGPolyElementBase
 {
 protected:
-  explicit SVGPolyElement(already_AddRefed<mozilla::dom::NodeInfo>& aNodeInfo);
+  explicit nsSVGPolyElement(already_AddRefed<mozilla::dom::NodeInfo>& aNodeInfo);
 
-  virtual ~SVGPolyElement();
+  virtual ~nsSVGPolyElement();
 
 public:
   //interfaces
 
   NS_DECL_ISUPPORTS_INHERITED
 
   // nsIContent interface
   NS_IMETHOD_(bool) IsAttributeMapped(const nsIAtom* name) const override;
@@ -38,28 +37,25 @@ public:
   }
   virtual nsIAtom* GetPointListAttrName() const override {
     return nsGkAtoms::points;
   }
 
   // nsSVGElement methods:
   virtual bool HasValidDimensions() const override;
 
-  // SVGGeometryElement methods:
+  // nsSVGPathGeometryElement methods:
   virtual bool AttributeDefinesGeometry(const nsIAtom *aName) override;
   virtual bool IsMarkable() override { return true; }
   virtual void GetMarkPoints(nsTArray<nsSVGMark> *aMarks) override;
   virtual bool GetGeometryBounds(Rect* aBounds, const StrokeOptions& aStrokeOptions,
                                  const Matrix& aToBoundsSpace,
                                  const Matrix* aToNonScalingStrokeSpace = nullptr) override;
 
   // WebIDL
   already_AddRefed<mozilla::DOMSVGPointList> Points();
   already_AddRefed<mozilla::DOMSVGPointList> AnimatedPoints();
 
 protected:
   SVGAnimatedPointList mPoints;
 };
 
-} // namespace dom
-} // namespace mozilla
-
 #endif //NS_SVGPOLYELEMENT_H_
--- a/dom/tests/mochitest/general/test_interfaces.html
+++ b/dom/tests/mochitest/general/test_interfaces.html
@@ -1003,18 +1003,16 @@ var interfaceNamesInGlobalScope =
     "SVGFETurbulenceElement",
 // IMPORTANT: Do not change this list without review from a DOM peer!
     "SVGFilterElement",
 // IMPORTANT: Do not change this list without review from a DOM peer!
     "SVGForeignObjectElement",
 // IMPORTANT: Do not change this list without review from a DOM peer!
     "SVGGElement",
 // IMPORTANT: Do not change this list without review from a DOM peer!
-    "SVGGeometryElement",
-// IMPORTANT: Do not change this list without review from a DOM peer!
     "SVGGradientElement",
 // IMPORTANT: Do not change this list without review from a DOM peer!
     "SVGGraphicsElement",
 // IMPORTANT: Do not change this list without review from a DOM peer!
     "SVGImageElement",
 // IMPORTANT: Do not change this list without review from a DOM peer!
     "SVGLength",
 // IMPORTANT: Do not change this list without review from a DOM peer!
--- a/dom/webidl/SVGPathElement.webidl
+++ b/dom/webidl/SVGPathElement.webidl
@@ -4,18 +4,24 @@
  * You can obtain one at http://mozilla.org/MPL/2.0/.
  *
  * The origin of this IDL file is
  * http://www.w3.org/TR/SVG2/
  *
  * Copyright © 2012 W3C® (MIT, ERCIM, Keio), All Rights Reserved. W3C
  * liability, trademark and document use rules apply.
  */
-interface SVGPathElement : SVGGeometryElement {
+interface SVGPathElement : SVGGraphicsElement {
 
+  [Constant]
+  readonly attribute SVGAnimatedNumber pathLength;
+
+  float getTotalLength();
+  [NewObject, Throws]
+  SVGPoint getPointAtLength(float distance);
   unsigned long getPathSegAtLength(float distance);
   [NewObject]
   SVGPathSegClosePath createSVGPathSegClosePath();
   [NewObject]
   SVGPathSegMovetoAbs createSVGPathSegMovetoAbs(float x, float y);
   [NewObject]
   SVGPathSegMovetoRel createSVGPathSegMovetoRel(float x, float y);
   [NewObject]
--- a/dom/webidl/moz.build
+++ b/dom/webidl/moz.build
@@ -465,17 +465,16 @@ WEBIDL_FILES = [
     'SVGFESpotLightElement.webidl',
     'SVGFETileElement.webidl',
     'SVGFETurbulenceElement.webidl',
     'SVGFilterElement.webidl',
     'SVGFilterPrimitiveStandardAttributes.webidl',
     'SVGFitToViewBox.webidl',
     'SVGForeignObjectElement.webidl',
     'SVGGElement.webidl',
-    'SVGGeometryElement.webidl',
     'SVGGradientElement.webidl',
     'SVGGraphicsElement.webidl',
     'SVGImageElement.webidl',
     'SVGLength.webidl',
     'SVGLengthList.webidl',
     'SVGLinearGradientElement.webidl',
     'SVGLineElement.webidl',
     'SVGMarkerElement.webidl',
--- a/layout/base/nsCSSFrameConstructor.cpp
+++ b/layout/base/nsCSSFrameConstructor.cpp
@@ -131,17 +131,17 @@ NS_NewHTMLVideoFrame (nsIPresShell* aPre
 
 nsContainerFrame*
 NS_NewSVGOuterSVGFrame(nsIPresShell* aPresShell, nsStyleContext* aContext);
 nsContainerFrame*
 NS_NewSVGOuterSVGAnonChildFrame(nsIPresShell* aPresShell, nsStyleContext* aContext);
 nsIFrame*
 NS_NewSVGInnerSVGFrame(nsIPresShell* aPresShell, nsStyleContext* aContext);
 nsIFrame*
-NS_NewSVGGeometryFrame(nsIPresShell* aPresShell, nsStyleContext* aContext);
+NS_NewSVGPathGeometryFrame(nsIPresShell* aPresShell, nsStyleContext* aContext);
 nsIFrame*
 NS_NewSVGGFrame(nsIPresShell* aPresShell, nsStyleContext* aContext);
 nsIFrame*
 NS_NewSVGGenericContainerFrame(nsIPresShell* aPresShell, nsStyleContext* aContext);
 nsContainerFrame*
 NS_NewSVGForeignObjectFrame(nsIPresShell* aPresShell, nsStyleContext* aContext);
 nsIFrame*
 NS_NewSVGAFrame(nsIPresShell* aPresShell, nsStyleContext* aContext);
@@ -5488,23 +5488,23 @@ nsCSSFrameConstructor::FindSVGData(Eleme
              aTag == nsGkAtoms::textPath) {
     return &sSuppressData;
   }
 
   static const FrameConstructionDataByTag sSVGData[] = {
     SIMPLE_SVG_CREATE(svg, NS_NewSVGInnerSVGFrame),
     SIMPLE_SVG_CREATE(g, NS_NewSVGGFrame),
     SIMPLE_SVG_CREATE(svgSwitch, NS_NewSVGSwitchFrame),
-    SIMPLE_SVG_CREATE(polygon, NS_NewSVGGeometryFrame),
-    SIMPLE_SVG_CREATE(polyline, NS_NewSVGGeometryFrame),
-    SIMPLE_SVG_CREATE(circle, NS_NewSVGGeometryFrame),
-    SIMPLE_SVG_CREATE(ellipse, NS_NewSVGGeometryFrame),
-    SIMPLE_SVG_CREATE(line, NS_NewSVGGeometryFrame),
-    SIMPLE_SVG_CREATE(rect, NS_NewSVGGeometryFrame),
-    SIMPLE_SVG_CREATE(path, NS_NewSVGGeometryFrame),
+    SIMPLE_SVG_CREATE(polygon, NS_NewSVGPathGeometryFrame),
+    SIMPLE_SVG_CREATE(polyline, NS_NewSVGPathGeometryFrame),
+    SIMPLE_SVG_CREATE(circle, NS_NewSVGPathGeometryFrame),
+    SIMPLE_SVG_CREATE(ellipse, NS_NewSVGPathGeometryFrame),
+    SIMPLE_SVG_CREATE(line, NS_NewSVGPathGeometryFrame),
+    SIMPLE_SVG_CREATE(rect, NS_NewSVGPathGeometryFrame),
+    SIMPLE_SVG_CREATE(path, NS_NewSVGPathGeometryFrame),
     SIMPLE_SVG_CREATE(defs, NS_NewSVGContainerFrame),
     SIMPLE_SVG_CREATE(generic_, NS_NewSVGGenericContainerFrame),
     { &nsGkAtoms::foreignObject,
       FCDATA_WITH_WRAPPING_BLOCK(FCDATA_DISALLOW_OUT_OF_FLOW,
                                  NS_NewSVGForeignObjectFrame,
                                  nsCSSAnonBoxes::mozSVGForeignContent) },
     SIMPLE_SVG_CREATE(a, NS_NewSVGAFrame),
     SIMPLE_SVG_CREATE(linearGradient, NS_NewSVGLinearGradientFrame),
--- a/layout/generic/nsFrameIdList.h
+++ b/layout/generic/nsFrameIdList.h
@@ -148,17 +148,17 @@ FRAME_ID(nsSVGImageFrame)
 FRAME_ID(nsSVGInnerSVGFrame)
 FRAME_ID(nsSVGLinearGradientFrame)
 FRAME_ID(nsSVGMarkerFrame)
 FRAME_ID(nsSVGMarkerAnonChildFrame)
 FRAME_ID(nsSVGMaskFrame)
 FRAME_ID(nsSVGOuterSVGFrame)
 FRAME_ID(nsSVGOuterSVGAnonChildFrame)
 FRAME_ID(nsSVGPaintServerFrame)
-FRAME_ID(SVGGeometryFrame)
+FRAME_ID(nsSVGPathGeometryFrame)
 FRAME_ID(nsSVGPatternFrame)
 FRAME_ID(nsSVGRadialGradientFrame)
 FRAME_ID(nsSVGStopFrame)
 FRAME_ID(nsSVGSwitchFrame)
 FRAME_ID(SVGTextFrame)
 FRAME_ID(nsSVGUseFrame)
 FRAME_ID(SVGViewFrame)
 FRAME_ID(nsTableCellFrame)
--- a/layout/painting/nsDisplayItemTypesList.h
+++ b/layout/painting/nsDisplayItemTypesList.h
@@ -47,17 +47,17 @@ DECLARE_DISPLAY_ITEM_TYPE(RESOLUTION)
 DECLARE_DISPLAY_ITEM_TYPE(SCROLL_INFO_LAYER)
 DECLARE_DISPLAY_ITEM_TYPE(SELECTION_OVERLAY)
 DECLARE_DISPLAY_ITEM_TYPE(SOLID_COLOR)
 DECLARE_DISPLAY_ITEM_TYPE(SOLID_COLOR_REGION)
 DECLARE_DISPLAY_ITEM_TYPE(SUBDOCUMENT)
 DECLARE_DISPLAY_ITEM_TYPE(MASK)
 DECLARE_DISPLAY_ITEM_TYPE(FILTER)
 DECLARE_DISPLAY_ITEM_TYPE(SVG_OUTER_SVG)
-DECLARE_DISPLAY_ITEM_TYPE(SVG_GEOMETRY)
+DECLARE_DISPLAY_ITEM_TYPE(SVG_PATH_GEOMETRY)
 DECLARE_DISPLAY_ITEM_TYPE(SVG_TEXT)
 DECLARE_DISPLAY_ITEM_TYPE(TABLE_CELL_BACKGROUND)
 DECLARE_DISPLAY_ITEM_TYPE(TABLE_CELL_SELECTION)
 DECLARE_DISPLAY_ITEM_TYPE(TABLE_ROW_BACKGROUND)
 DECLARE_DISPLAY_ITEM_TYPE(TABLE_ROW_GROUP_BACKGROUND)
 DECLARE_DISPLAY_ITEM_TYPE(TABLE_BORDER_BACKGROUND)
 DECLARE_DISPLAY_ITEM_TYPE(TEXT)
 DECLARE_DISPLAY_ITEM_TYPE(TEXT_OVERFLOW)
--- a/layout/style/nsStyleStruct.cpp
+++ b/layout/style/nsStyleStruct.cpp
@@ -913,17 +913,17 @@ PaintURIChanged(const nsStyleSVGPaint& a
 nsChangeHint
 nsStyleSVG::CalcDifference(const nsStyleSVG& aNewData) const
 {
   nsChangeHint hint = nsChangeHint(0);
 
   if (!DefinitelyEqualURIs(mMarkerEnd, aNewData.mMarkerEnd) ||
       !DefinitelyEqualURIs(mMarkerMid, aNewData.mMarkerMid) ||
       !DefinitelyEqualURIs(mMarkerStart, aNewData.mMarkerStart)) {
-    // Markers currently contribute to SVGGeometryFrame::mRect,
+    // Markers currently contribute to nsSVGPathGeometryFrame::mRect,
     // so we need a reflow as well as a repaint. No intrinsic sizes need
     // to change, so nsChangeHint_NeedReflow is sufficient.
     return nsChangeHint_UpdateEffects |
            nsChangeHint_NeedReflow |
            nsChangeHint_NeedDirtyReflow | // XXX remove me: bug 876085
            nsChangeHint_RepaintFrame;
   }
 
@@ -934,30 +934,30 @@ nsStyleSVG::CalcDifference(const nsStyle
     hint |= nsChangeHint_RepaintFrame;
     if (HasStroke() != aNewData.HasStroke() ||
         (!HasStroke() && HasFill() != aNewData.HasFill())) {
       // Frame bounds and overflow rects depend on whether we "have" fill or
       // stroke. Whether we have stroke or not just changed, or else we have no
       // stroke (in which case whether we have fill or not is significant to frame
       // bounds) and whether we have fill or not just changed. In either case we
       // need to reflow so the frame rect is updated.
-      // XXXperf this is a waste on non SVGGeometryFrames.
+      // XXXperf this is a waste on non nsSVGPathGeometryFrames.
       hint |= nsChangeHint_NeedReflow |
               nsChangeHint_NeedDirtyReflow; // XXX remove me: bug 876085
     }
     if (PaintURIChanged(mFill, aNewData.mFill) ||
         PaintURIChanged(mStroke, aNewData.mStroke)) {
       hint |= nsChangeHint_UpdateEffects;
     }
   }
 
-  // Stroke currently contributes to SVGGeometryFrame::mRect, so
+  // Stroke currently contributes to nsSVGPathGeometryFrame::mRect, so
   // we need a reflow here. No intrinsic sizes need to change, so
   // nsChangeHint_NeedReflow is sufficient.
-  // Note that stroke-dashoffset does not affect SVGGeometryFrame::mRect.
+  // Note that stroke-dashoffset does not affect nsSVGPathGeometryFrame::mRect.
   // text-anchor changes also require a reflow since it changes frames' rects.
   if (mStrokeWidth           != aNewData.mStrokeWidth           ||
       mStrokeMiterlimit      != aNewData.mStrokeMiterlimit      ||
       mStrokeLinecap         != aNewData.mStrokeLinecap         ||
       mStrokeLinejoin        != aNewData.mStrokeLinejoin        ||
       mTextAnchor            != aNewData.mTextAnchor) {
     return hint |
            nsChangeHint_NeedReflow |
@@ -1181,19 +1181,19 @@ nsStyleSVGReset::CalcDifference(const ns
     // which is done during overflow computation.
     hint |= nsChangeHint_UpdateOverflow;
   }
 
   if (mDominantBaseline != aNewData.mDominantBaseline) {
     // XXXjwatt: why NS_STYLE_HINT_REFLOW? Isn't that excessive?
     hint |= NS_STYLE_HINT_REFLOW;
   } else if (mVectorEffect  != aNewData.mVectorEffect) {
-    // Stroke currently affects SVGGeometryFrame::mRect, and
+    // Stroke currently affects nsSVGPathGeometryFrame::mRect, and
     // vector-effect affect stroke. As a result we need to reflow if
-    // vector-effect changes in order to have SVGGeometryFrame::
+    // vector-effect changes in order to have nsSVGPathGeometryFrame::
     // ReflowSVG called to update its mRect. No intrinsic sizes need
     // to change so nsChangeHint_NeedReflow is sufficient.
     hint |= nsChangeHint_NeedReflow |
             nsChangeHint_NeedDirtyReflow | // XXX remove me: bug 876085
             nsChangeHint_RepaintFrame;
   } else if (mStopColor     != aNewData.mStopColor     ||
              mFloodColor    != aNewData.mFloodColor    ||
              mLightingColor != aNewData.mLightingColor ||
@@ -4016,18 +4016,18 @@ nsStyleUserInterface::CalcDifference(con
 
   // We could do better. But it wouldn't be worth it, URL-specified cursors are
   // rare.
   if (mCursorImages != aNewData.mCursorImages) {
     hint |= nsChangeHint_UpdateCursor;
   }
 
   if (mPointerEvents != aNewData.mPointerEvents) {
-    // SVGGeometryFrame's mRect depends on stroke _and_ on the value
-    // of pointer-events. See SVGGeometryFrame::ReflowSVG's use of
+    // nsSVGPathGeometryFrame's mRect depends on stroke _and_ on the value
+    // of pointer-events. See nsSVGPathGeometryFrame::ReflowSVG's use of
     // GetHitTestFlags. (Only a reflow, no visual change.)
     hint |= nsChangeHint_NeedReflow |
             nsChangeHint_NeedDirtyReflow; // XXX remove me: bug 876085
   }
 
   if (mUserModify != aNewData.mUserModify) {
     hint |= NS_STYLE_HINT_VISUAL;
   }
--- a/layout/svg/moz.build
+++ b/layout/svg/moz.build
@@ -36,27 +36,27 @@ UNIFIED_SOURCES += [
     'nsSVGGFrame.cpp',
     'nsSVGGradientFrame.cpp',
     'nsSVGImageFrame.cpp',
     'nsSVGInnerSVGFrame.cpp',
     'nsSVGIntegrationUtils.cpp',
     'nsSVGMarkerFrame.cpp',
     'nsSVGMaskFrame.cpp',
     'nsSVGOuterSVGFrame.cpp',
+    'nsSVGPathGeometryFrame.cpp',
     'nsSVGPatternFrame.cpp',
     'nsSVGStopFrame.cpp',
     'nsSVGSwitchFrame.cpp',
     'nsSVGUseFrame.cpp',
     'nsSVGUtils.cpp',
     'SVGContextPaint.cpp',
     'SVGFEContainerFrame.cpp',
     'SVGFEImageFrame.cpp',
     'SVGFELeafFrame.cpp',
     'SVGFEUnstyledLeafFrame.cpp',
-    'SVGGeometryFrame.cpp',
     'SVGTextFrame.cpp',
     'SVGViewFrame.cpp',
 ]
 
 if CONFIG['CPU_ARCH'] == 'arm' and CONFIG['BUILD_ARM_NEON']:
     SOURCES += ['nsSVGMaskFrameNEON.cpp']
     SOURCES['nsSVGMaskFrameNEON.cpp'].flags += CONFIG['NEON_FLAGS']
 
--- a/layout/svg/nsSVGClipPathFrame.cpp
+++ b/layout/svg/nsSVGClipPathFrame.cpp
@@ -7,18 +7,18 @@
 #include "nsSVGClipPathFrame.h"
 
 // Keep others in (case-insensitive) order:
 #include "DrawResult.h"
 #include "gfxContext.h"
 #include "mozilla/dom/SVGClipPathElement.h"
 #include "nsGkAtoms.h"
 #include "nsSVGEffects.h"
-#include "SVGGeometryElement.h"
-#include "SVGGeometryFrame.h"
+#include "nsSVGPathGeometryElement.h"
+#include "nsSVGPathGeometryFrame.h"
 #include "nsSVGUtils.h"
 
 using namespace mozilla;
 using namespace mozilla::dom;
 using namespace mozilla::gfx;
 using namespace mozilla::image;
 
 // Arbitrary number
@@ -51,20 +51,20 @@ nsSVGClipPathFrame::ApplyClipPath(gfxCon
   gfxContextMatrixAutoSaveRestore autoRestore(&aContext);
 
   RefPtr<Path> clipPath;
 
   nsISVGChildFrame* singleClipPathChild = nullptr;
   IsTrivial(&singleClipPathChild);
 
   if (singleClipPathChild) {
-    SVGGeometryFrame* pathFrame = do_QueryFrame(singleClipPathChild);
+    nsSVGPathGeometryFrame* pathFrame = do_QueryFrame(singleClipPathChild);
     if (pathFrame) {
-      SVGGeometryElement* pathElement =
-        static_cast<SVGGeometryElement*>(pathFrame->GetContent());
+      nsSVGPathGeometryElement* pathElement =
+        static_cast<nsSVGPathGeometryElement*>(pathFrame->GetContent());
       gfxMatrix toChildsUserSpace = pathElement->
         PrependLocalTransformsTo(GetClipPathTransform(aClippedFrame) * aMatrix,
                                  eUserSpaceToParent);
       gfxMatrix newMatrix =
         aContext.CurrentMatrix().PreMultiply(toChildsUserSpace).NudgeToIntegers();
       if (!newMatrix.IsSingular()) {
         aContext.SetMatrix(newMatrix);
         FillRule clipRule =
@@ -246,17 +246,17 @@ nsSVGClipPathFrame::PaintFrameIntoMask(n
   nsIContent* childContent = child->GetContent();
   if (childContent->IsSVGElement()) {
     toChildsUserSpace =
       static_cast<const nsSVGElement*>(childContent)->
         PrependLocalTransformsTo(mMatrixForChildren, eUserSpaceToParent);
   }
 
   // Our children have NS_STATE_SVG_CLIPPATH_CHILD set on them, and
-  // SVGGeometryFrame::Render checks for that state bit and paints
+  // nsSVGPathGeometryFrame::Render checks for that state bit and paints
   // only the geometry (opaque black) if set.
   result &= frame->PaintSVG(aTarget, toChildsUserSpace);
 
   if (maskUsage.shouldGenerateClipMaskLayer) {
     aTarget.PopGroupAndBlend();
   } else if (maskUsage.shouldApplyClipPath) {
     aTarget.PopClip();
   }
@@ -421,25 +421,25 @@ nsSVGClipPathFrame::IsValid()
 
     nsIAtom* kidType = kid->GetType();
 
     if (kidType == nsGkAtoms::svgUseFrame) {
       for (nsIFrame* grandKid : kid->PrincipalChildList()) {
 
         nsIAtom* grandKidType = grandKid->GetType();
 
-        if (grandKidType != nsGkAtoms::svgGeometryFrame &&
+        if (grandKidType != nsGkAtoms::svgPathGeometryFrame &&
             grandKidType != nsGkAtoms::svgTextFrame) {
           return false;
         }
       }
       continue;
     }
 
-    if (kidType != nsGkAtoms::svgGeometryFrame &&
+    if (kidType != nsGkAtoms::svgPathGeometryFrame &&
         kidType != nsGkAtoms::svgTextFrame) {
       return false;
     }
   }
 
   return true;
 }
 
--- a/layout/svg/nsSVGEffects.cpp
+++ b/layout/svg/nsSVGEffects.cpp
@@ -8,21 +8,21 @@
 
 // Keep others in (case-insensitive) order:
 #include "mozilla/RestyleManagerHandle.h"
 #include "mozilla/RestyleManagerHandleInlines.h"
 #include "nsCSSFrameConstructor.h"
 #include "nsISupportsImpl.h"
 #include "nsSVGClipPathFrame.h"
 #include "nsSVGPaintServerFrame.h"
+#include "nsSVGPathGeometryElement.h"
 #include "nsSVGFilterFrame.h"
 #include "nsSVGMaskFrame.h"
 #include "nsIReflowCallback.h"
 #include "nsCycleCollectionParticipant.h"
-#include "SVGGeometryElement.h"
 #include "SVGUseElement.h"
 
 using namespace mozilla;
 using namespace mozilla::dom;
 
 void
 nsSVGRenderingObserver::StartListening()
 {
@@ -521,18 +521,18 @@ GetEffectProperty(nsIURI* aURI, nsIFrame
   props.Set(aProperty, prop);
   return prop;
 }
 
 nsSVGMarkerProperty*
 nsSVGEffects::GetMarkerProperty(nsIURI* aURI, nsIFrame* aFrame,
   const mozilla::FramePropertyDescriptor<nsSVGMarkerProperty>* aProperty)
 {
-  MOZ_ASSERT(aFrame->GetType() == nsGkAtoms::svgGeometryFrame &&
-             static_cast<SVGGeometryElement*>(aFrame->GetContent())->IsMarkable(),
+  MOZ_ASSERT(aFrame->GetType() == nsGkAtoms::svgPathGeometryFrame &&
+             static_cast<nsSVGPathGeometryElement*>(aFrame->GetContent())->IsMarkable(),
              "Bad frame");
   return GetEffectProperty(aURI, aFrame, aProperty);
 }
 
 nsSVGTextPathProperty*
 nsSVGEffects::GetTextPathProperty(nsIURI* aURI, nsIFrame* aFrame,
   const mozilla::FramePropertyDescriptor<nsSVGTextPathProperty>* aProperty)
 {
@@ -738,18 +738,18 @@ nsSVGEffects::UpdateEffects(nsIFrame* aF
   props.Delete(FillProperty());
   props.Delete(StrokeProperty());
   props.Delete(BackgroundImageProperty());
 
   // Ensure that the filter is repainted correctly
   // We can't do that in DoUpdate as the referenced frame may not be valid
   GetOrCreateFilterProperty(aFrame);
 
-  if (aFrame->GetType() == nsGkAtoms::svgGeometryFrame &&
-      static_cast<SVGGeometryElement*>(aFrame->GetContent())->IsMarkable()) {
+  if (aFrame->GetType() == nsGkAtoms::svgPathGeometryFrame &&
+      static_cast<nsSVGPathGeometryElement*>(aFrame->GetContent())->IsMarkable()) {
     // Set marker properties here to avoid reference loops
     nsCOMPtr<nsIURI> markerURL =
       GetMarkerURI(aFrame, &nsStyleSVG::mMarkerStart);
     GetMarkerProperty(markerURL, aFrame, MarkerBeginProperty());
     markerURL = GetMarkerURI(aFrame, &nsStyleSVG::mMarkerMid);
     GetMarkerProperty(markerURL, aFrame, MarkerMiddleProperty());
     markerURL = GetMarkerURI(aFrame, &nsStyleSVG::mMarkerEnd);
     GetMarkerProperty(markerURL, aFrame, MarkerEndProperty());
--- a/layout/svg/nsSVGImageFrame.cpp
+++ b/layout/svg/nsSVGImageFrame.cpp
@@ -8,20 +8,20 @@
 #include "gfxPlatform.h"
 #include "mozilla/gfx/2D.h"
 #include "imgIContainer.h"
 #include "nsContainerFrame.h"
 #include "nsIImageLoadingContent.h"
 #include "nsLayoutUtils.h"
 #include "imgINotificationObserver.h"
 #include "nsSVGEffects.h"
+#include "nsSVGPathGeometryFrame.h"
 #include "mozilla/dom/SVGSVGElement.h"
 #include "nsSVGUtils.h"
 #include "SVGContentUtils.h"
-#include "SVGGeometryFrame.h"
 #include "SVGImageContext.h"
 #include "mozilla/dom/SVGImageElement.h"
 #include "nsContentUtils.h"
 #include "nsIReflowCallback.h"
 #include "mozilla/Unused.h"
 
 using namespace mozilla;
 using namespace mozilla::dom;
@@ -41,25 +41,25 @@ public:
   void SetFrame(nsSVGImageFrame *frame) { mFrame = frame; }
 
 private:
   ~nsSVGImageListener() {}
 
   nsSVGImageFrame *mFrame;
 };
 
-class nsSVGImageFrame : public SVGGeometryFrame
+class nsSVGImageFrame : public nsSVGPathGeometryFrame
                       , public nsIReflowCallback
 {
   friend nsIFrame*
   NS_NewSVGImageFrame(nsIPresShell* aPresShell, nsStyleContext* aContext);
 
 protected:
   explicit nsSVGImageFrame(nsStyleContext* aContext)
-    : SVGGeometryFrame(aContext)
+    : nsSVGPathGeometryFrame(aContext)
     , mReflowCallbackPosted(false)
   {
     EnableVisibilityTracking();
   }
 
   virtual ~nsSVGImageFrame();
 
 public:
@@ -67,17 +67,17 @@ public:
 
   // nsISVGChildFrame interface:
   virtual DrawResult PaintSVG(gfxContext& aContext,
                               const gfxMatrix& aTransform,
                               const nsIntRect* aDirtyRect = nullptr) override;
   virtual nsIFrame* GetFrameForPoint(const gfxPoint& aPoint) override;
   virtual void ReflowSVG() override;
 
-  // SVGGeometryFrame methods:
+  // nsSVGPathGeometryFrame methods:
   virtual uint16_t GetHitTestFlags() override;
 
   // nsIFrame interface:
   virtual nsresult  AttributeChanged(int32_t         aNameSpaceID,
                                      nsIAtom*        aAttribute,
                                      int32_t         aModType) override;
 
   void OnVisibilityChange(Visibility aNewVisibility,
@@ -149,17 +149,17 @@ nsSVGImageFrame::~nsSVGImageFrame()
 void
 nsSVGImageFrame::Init(nsIContent*       aContent,
                       nsContainerFrame* aParent,
                       nsIFrame*         aPrevInFlow)
 {
   NS_ASSERTION(aContent->IsSVGElement(nsGkAtoms::image),
                "Content is not an SVG image!");
 
-  SVGGeometryFrame::Init(aContent, aParent, aPrevInFlow);
+  nsSVGPathGeometryFrame::Init(aContent, aParent, aPrevInFlow);
 
   if (GetStateBits() & NS_FRAME_IS_NONDISPLAY) {
     // Non-display frames are likely to be patterns, masks or the like.
     // Treat them as always visible.
     IncApproximateVisibleCount();
   }
 
   mListener = new nsSVGImageListener(this);
@@ -235,33 +235,33 @@ nsSVGImageFrame::AttributeChanged(int32_
       element->mStringAttributes[SVGImageElement::XLINK_HREF].IsExplicitlySet();
     if (hrefIsSet) {
       element->LoadSVGImage(true, true);
     } else {
       element->CancelImageRequests(true);
     }
   }
 
-  return SVGGeometryFrame::AttributeChanged(aNameSpaceID,
-                                            aAttribute, aModType);
+  return nsSVGPathGeometryFrame::AttributeChanged(aNameSpaceID,
+                                                  aAttribute, aModType);
 }
 
 void
 nsSVGImageFrame::OnVisibilityChange(Visibility aNewVisibility,
                                     Maybe<OnNonvisible> aNonvisibleAction)
 {
   nsCOMPtr<nsIImageLoadingContent> imageLoader = do_QueryInterface(mContent);
   if (!imageLoader) {
-    SVGGeometryFrame::OnVisibilityChange(aNewVisibility, aNonvisibleAction);
+    nsSVGPathGeometryFrame::OnVisibilityChange(aNewVisibility, aNonvisibleAction);
     return;
   }
 
   imageLoader->OnVisibilityChange(aNewVisibility, aNonvisibleAction);
 
-  SVGGeometryFrame::OnVisibilityChange(aNewVisibility, aNonvisibleAction);
+  nsSVGPathGeometryFrame::OnVisibilityChange(aNewVisibility, aNonvisibleAction);
 }
 
 gfx::Matrix
 nsSVGImageFrame::GetRasterImageTransform(int32_t aNativeWidth,
                                          int32_t aNativeHeight)
 {
   float x, y, width, height;
   SVGImageElement *element = static_cast<SVGImageElement*>(mContent);
@@ -494,17 +494,17 @@ nsSVGImageFrame::GetFrameForPoint(const 
 
 nsIAtom *
 nsSVGImageFrame::GetType() const
 {
   return nsGkAtoms::svgImageFrame;
 }
 
 //----------------------------------------------------------------------
-// SVGGeometryFrame methods:
+// nsSVGPathGeometryFrame methods:
 
 // Lie about our fill/stroke so that covered region and hit detection work properly
 
 void
 nsSVGImageFrame::ReflowSVG()
 {
   NS_ASSERTION(nsSVGUtils::OuterSVGIsCallingReflowSVG(this),
                "This call is probably a wasteful mistake");
--- a/layout/svg/nsSVGMarkerFrame.cpp
+++ b/layout/svg/nsSVGMarkerFrame.cpp
@@ -5,18 +5,18 @@
 
 // Main header first:
 #include "nsSVGMarkerFrame.h"
 
 // Keep others in (case-insensitive) order:
 #include "gfxContext.h"
 #include "nsSVGEffects.h"
 #include "mozilla/dom/SVGMarkerElement.h"
-#include "SVGGeometryElement.h"
-#include "SVGGeometryFrame.h"
+#include "nsSVGPathGeometryElement.h"
+#include "nsSVGPathGeometryFrame.h"
 
 using namespace mozilla::dom;
 using namespace mozilla::gfx;
 
 nsContainerFrame*
 NS_NewSVGMarkerFrame(nsIPresShell* aPresShell, nsStyleContext* aContext)
 {
   return new (aPresShell) nsSVGMarkerFrame(aContext);
@@ -67,17 +67,17 @@ nsSVGMarkerFrame::GetType() const
 }
 
 //----------------------------------------------------------------------
 // nsSVGContainerFrame methods:
 
 gfxMatrix
 nsSVGMarkerFrame::GetCanvasTM()
 {
-  NS_ASSERTION(mMarkedFrame, "null SVGGeometry frame");
+  NS_ASSERTION(mMarkedFrame, "null nsSVGPathGeometry frame");
 
   if (mInUse2) {
     // We're going to be bailing drawing the marker, so return an identity.
     return gfxMatrix();
   }
 
   SVGMarkerElement *content = static_cast<SVGMarkerElement*>(mContent);
   
@@ -99,17 +99,17 @@ GetAnonymousChildFrame(nsIFrame* aFrame)
   MOZ_ASSERT(kid && kid->GetType() == nsGkAtoms::svgMarkerAnonChildFrame,
              "expected to find anonymous child of marker frame");
   return kid;
 }
 
 nsresult
 nsSVGMarkerFrame::PaintMark(gfxContext& aContext,
                             const gfxMatrix& aToMarkedFrameUserSpace,
-                            SVGGeometryFrame *aMarkedFrame,
+                            nsSVGPathGeometryFrame *aMarkedFrame,
                             nsSVGMark *aMark, float aStrokeWidth)
 {
   // If the flag is set when we get here, it means this marker frame
   // has already been used painting the current mark, and the document
   // has a marker reference loop.
   if (mInUse)
     return NS_OK;
 
@@ -160,17 +160,17 @@ nsSVGMarkerFrame::PaintMark(gfxContext& 
     aContext.Restore();
 
   return (result == DrawResult::SUCCESS) ? NS_OK : NS_ERROR_FAILURE;
 }
 
 SVGBBox
 nsSVGMarkerFrame::GetMarkBBoxContribution(const Matrix &aToBBoxUserspace,
                                           uint32_t aFlags,
-                                          SVGGeometryFrame *aMarkedFrame,
+                                          nsSVGPathGeometryFrame *aMarkedFrame,
                                           const nsSVGMark *aMark,
                                           float aStrokeWidth)
 {
   SVGBBox bbox;
 
   // If the flag is set when we get here, it means this marker frame
   // has already been used in calculating the current mark bbox, and
   // the document has a marker reference loop.
@@ -221,17 +221,17 @@ nsSVGMarkerFrame::SetParentCoordCtxProvi
   marker->SetParentCoordCtxProvider(aContext);
 }
 
 //----------------------------------------------------------------------
 // helper class
 
 nsSVGMarkerFrame::AutoMarkerReferencer::AutoMarkerReferencer(
     nsSVGMarkerFrame *aFrame,
-    SVGGeometryFrame *aMarkedFrame
+    nsSVGPathGeometryFrame *aMarkedFrame
     MOZ_GUARD_OBJECT_NOTIFIER_PARAM_IN_IMPL)
       : mFrame(aFrame)
 {
   MOZ_GUARD_OBJECT_NOTIFIER_INIT;
   mFrame->mInUse = true;
   mFrame->mMarkedFrame = aMarkedFrame;
 
   SVGSVGElement *ctx =
--- a/layout/svg/nsSVGMarkerFrame.h
+++ b/layout/svg/nsSVGMarkerFrame.h
@@ -11,19 +11,19 @@
 #include "gfxRect.h"
 #include "nsFrame.h"
 #include "nsLiteralString.h"
 #include "nsQueryFrame.h"
 #include "nsSVGContainerFrame.h"
 #include "nsSVGUtils.h"
 
 class gfxContext;
+class nsSVGPathGeometryFrame;
 
 namespace mozilla {
-class SVGGeometryFrame;
 namespace dom {
 class SVGSVGElement;
 } // namespace dom
 } // namespace mozilla
 
 struct nsSVGMark;
 
 class nsSVGMarkerFrame : public nsSVGContainerFrame
@@ -79,45 +79,45 @@ public:
                  nsGkAtoms::svgMarkerAnonChildFrame,
                "Where is our anonymous child?");
     return PrincipalChildList().FirstChild()->GetContentInsertionFrame();
   }
 
   // nsSVGMarkerFrame methods:
   nsresult PaintMark(gfxContext& aContext,
                      const gfxMatrix& aToMarkedFrameUserSpace,
-                     SVGGeometryFrame *aMarkedFrame,
+                     nsSVGPathGeometryFrame *aMarkedFrame,
                      nsSVGMark *aMark,
                      float aStrokeWidth);
 
   SVGBBox GetMarkBBoxContribution(const Matrix &aToBBoxUserspace,
                                   uint32_t aFlags,
-                                  SVGGeometryFrame *aMarkedFrame,
+                                  nsSVGPathGeometryFrame *aMarkedFrame,
                                   const nsSVGMark *aMark,
                                   float aStrokeWidth);
 
 private:
   // stuff needed for callback
-  SVGGeometryFrame *mMarkedFrame;
+  nsSVGPathGeometryFrame *mMarkedFrame;
   float mStrokeWidth, mX, mY, mAutoAngle;
   bool mIsStart;  // whether the callback is for a marker-start marker
 
   // nsSVGContainerFrame methods:
   virtual gfxMatrix GetCanvasTM() override;
 
   // A helper class to allow us to paint markers safely. The helper
   // automatically sets and clears the mInUse flag on the marker frame (to
   // prevent nasty reference loops) as well as the reference to the marked
   // frame and its coordinate context. It's easy to mess this up
   // and break things, so this helper makes the code far more robust.
   class MOZ_RAII AutoMarkerReferencer
   {
   public:
     AutoMarkerReferencer(nsSVGMarkerFrame *aFrame,
-                         SVGGeometryFrame *aMarkedFrame
+                         nsSVGPathGeometryFrame *aMarkedFrame
                          MOZ_GUARD_OBJECT_NOTIFIER_PARAM);
     ~AutoMarkerReferencer();
   private:
     nsSVGMarkerFrame *mFrame;
     MOZ_DECL_USE_GUARD_OBJECT_NOTIFIER
   };
 
   // nsSVGMarkerFrame methods:
rename from layout/svg/SVGGeometryFrame.cpp
rename to layout/svg/nsSVGPathGeometryFrame.cpp
--- a/layout/svg/SVGGeometryFrame.cpp
+++ b/layout/svg/nsSVGPathGeometryFrame.cpp
@@ -1,15 +1,15 @@
 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 // Main header first:
-#include "SVGGeometryFrame.h"
+#include "nsSVGPathGeometryFrame.h"
 
 // Keep others in (case-insensitive) order:
 #include "gfx2DGlue.h"
 #include "gfxContext.h"
 #include "gfxPlatform.h"
 #include "gfxUtils.h"
 #include "mozilla/gfx/2D.h"
 #include "mozilla/gfx/Helpers.h"
@@ -17,66 +17,66 @@
 #include "mozilla/SVGContextPaint.h"
 #include "nsDisplayList.h"
 #include "nsGkAtoms.h"
 #include "nsLayoutUtils.h"
 #include "nsRenderingContext.h"
 #include "nsSVGEffects.h"
 #include "nsSVGIntegrationUtils.h"
 #include "nsSVGMarkerFrame.h"
-#include "SVGGeometryElement.h"
+#include "nsSVGPathGeometryElement.h"
 #include "nsSVGUtils.h"
 #include "mozilla/ArrayUtils.h"
 #include "SVGAnimatedTransformList.h"
 #include "SVGContentUtils.h"
 #include "SVGGraphicsElement.h"
 
 using namespace mozilla;
 using namespace mozilla::gfx;
 using namespace mozilla::image;
 
 //----------------------------------------------------------------------
 // Implementation
 
 nsIFrame*
-NS_NewSVGGeometryFrame(nsIPresShell* aPresShell,
-                       nsStyleContext* aContext)
+NS_NewSVGPathGeometryFrame(nsIPresShell* aPresShell,
+                           nsStyleContext* aContext)
 {
-  return new (aPresShell) SVGGeometryFrame(aContext);
+  return new (aPresShell) nsSVGPathGeometryFrame(aContext);
 }
 
-NS_IMPL_FRAMEARENA_HELPERS(SVGGeometryFrame)
+NS_IMPL_FRAMEARENA_HELPERS(nsSVGPathGeometryFrame)
 
 //----------------------------------------------------------------------
 // nsQueryFrame methods
 
-NS_QUERYFRAME_HEAD(SVGGeometryFrame)
+NS_QUERYFRAME_HEAD(nsSVGPathGeometryFrame)
   NS_QUERYFRAME_ENTRY(nsISVGChildFrame)
-  NS_QUERYFRAME_ENTRY(SVGGeometryFrame)
+  NS_QUERYFRAME_ENTRY(nsSVGPathGeometryFrame)
 NS_QUERYFRAME_TAIL_INHERITING(nsFrame)
 
 //----------------------------------------------------------------------
 // Display list item:
 
-class nsDisplaySVGGeometry : public nsDisplayItem {
+class nsDisplaySVGPathGeometry : public nsDisplayItem {
 public:
-  nsDisplaySVGGeometry(nsDisplayListBuilder* aBuilder,
-                       SVGGeometryFrame* aFrame)
+  nsDisplaySVGPathGeometry(nsDisplayListBuilder* aBuilder,
+                           nsSVGPathGeometryFrame* aFrame)
     : nsDisplayItem(aBuilder, aFrame)
   {
-    MOZ_COUNT_CTOR(nsDisplaySVGGeometry);
+    MOZ_COUNT_CTOR(nsDisplaySVGPathGeometry);
     MOZ_ASSERT(aFrame, "Must have a frame!");
   }
 #ifdef NS_BUILD_REFCNT_LOGGING
-  virtual ~nsDisplaySVGGeometry() {
-    MOZ_COUNT_DTOR(nsDisplaySVGGeometry);
+  virtual ~nsDisplaySVGPathGeometry() {
+    MOZ_COUNT_DTOR(nsDisplaySVGPathGeometry);
   }
 #endif
 
-  NS_DISPLAY_DECL_NAME("nsDisplaySVGGeometry", TYPE_SVG_GEOMETRY)
+  NS_DISPLAY_DECL_NAME("nsDisplaySVGPathGeometry", TYPE_SVG_PATH_GEOMETRY)
 
   virtual void HitTest(nsDisplayListBuilder* aBuilder, const nsRect& aRect,
                        HitTestState* aState, nsTArray<nsIFrame*> *aOutFrames) override;
   virtual void Paint(nsDisplayListBuilder* aBuilder,
                      nsRenderingContext* aCtx) override;
 
   nsDisplayItemGeometry* AllocateGeometry(nsDisplayListBuilder* aBuilder) override
   {
@@ -84,124 +84,122 @@ public:
   }
 
   void ComputeInvalidationRegion(nsDisplayListBuilder* aBuilder,
                                  const nsDisplayItemGeometry* aGeometry,
                                  nsRegion *aInvalidRegion) override;
 };
 
 void
-nsDisplaySVGGeometry::HitTest(nsDisplayListBuilder* aBuilder, const nsRect& aRect,
-                              HitTestState* aState, nsTArray<nsIFrame*> *aOutFrames)
+nsDisplaySVGPathGeometry::HitTest(nsDisplayListBuilder* aBuilder, const nsRect& aRect,
+                                  HitTestState* aState, nsTArray<nsIFrame*> *aOutFrames)
 {
-  SVGGeometryFrame *frame = static_cast<SVGGeometryFrame*>(mFrame);
+  nsSVGPathGeometryFrame *frame = static_cast<nsSVGPathGeometryFrame*>(mFrame);
   nsPoint pointRelativeToReferenceFrame = aRect.Center();
   // ToReferenceFrame() includes frame->GetPosition(), our user space position.
   nsPoint userSpacePtInAppUnits = pointRelativeToReferenceFrame -
                                    (ToReferenceFrame() - frame->GetPosition());
   gfxPoint userSpacePt =
     gfxPoint(userSpacePtInAppUnits.x, userSpacePtInAppUnits.y) /
       frame->PresContext()->AppUnitsPerCSSPixel();
   if (frame->GetFrameForPoint(userSpacePt)) {
     aOutFrames->AppendElement(frame);
   }
 }
 
 void
-nsDisplaySVGGeometry::Paint(nsDisplayListBuilder* aBuilder,
-                            nsRenderingContext* aCtx)
+nsDisplaySVGPathGeometry::Paint(nsDisplayListBuilder* aBuilder,
+                                nsRenderingContext* aCtx)
 {
   uint32_t appUnitsPerDevPixel = mFrame->PresContext()->AppUnitsPerDevPixel();
 
   // ToReferenceFrame includes our mRect offset, but painting takes
   // account of that too. To avoid double counting, we subtract that
   // here.
   nsPoint offset = ToReferenceFrame() - mFrame->GetPosition();
 
   gfxPoint devPixelOffset =
     nsLayoutUtils::PointToGfxPoint(offset, appUnitsPerDevPixel);
 
   gfxMatrix tm = nsSVGIntegrationUtils::GetCSSPxToDevPxMatrix(mFrame) *
                    gfxMatrix::Translation(devPixelOffset);
   DrawResult result =
-    static_cast<SVGGeometryFrame*>(mFrame)->PaintSVG(*aCtx->ThebesContext(), tm);
+    static_cast<nsSVGPathGeometryFrame*>(mFrame)->PaintSVG(*aCtx->ThebesContext(), tm);
 
   nsDisplayItemGenericImageGeometry::UpdateDrawResult(this, result);
 }
 
 void
-nsDisplaySVGGeometry::ComputeInvalidationRegion(
+nsDisplaySVGPathGeometry::ComputeInvalidationRegion(
   nsDisplayListBuilder* aBuilder,
   const nsDisplayItemGeometry* aGeometry,
   nsRegion* aInvalidRegion)
 {
   auto geometry =
     static_cast<const nsDisplayItemGenericImageGeometry*>(aGeometry);
 
   if (aBuilder->ShouldSyncDecodeImages() &&
       geometry->ShouldInvalidateToSyncDecodeImages()) {
     bool snap;
     aInvalidRegion->Or(*aInvalidRegion, GetBounds(aBuilder, &snap));
   }
 
   nsDisplayItem::ComputeInvalidationRegion(aBuilder, aGeometry, aInvalidRegion);
 }
 
-namespace mozilla {
-
 //----------------------------------------------------------------------
 // nsIFrame methods
 
 void
-SVGGeometryFrame::Init(nsIContent*       aContent,
-                       nsContainerFrame* aParent,
-                       nsIFrame*         aPrevInFlow)
+nsSVGPathGeometryFrame::Init(nsIContent*       aContent,
+                             nsContainerFrame* aParent,
+                             nsIFrame*         aPrevInFlow)
 {
   AddStateBits(aParent->GetStateBits() & NS_STATE_SVG_CLIPPATH_CHILD);
   nsFrame::Init(aContent, aParent, aPrevInFlow);
 }
 
 nsresult
-SVGGeometryFrame::AttributeChanged(int32_t         aNameSpaceID,
-                                   nsIAtom*        aAttribute,
-                                   int32_t         aModType)
+nsSVGPathGeometryFrame::AttributeChanged(int32_t         aNameSpaceID,
+                                         nsIAtom*        aAttribute,
+                                         int32_t         aModType)
 {
   // We don't invalidate for transform changes (the layers code does that).
   // Also note that SVGTransformableElement::GetAttributeChangeHint will
   // return nsChangeHint_UpdateOverflow for "transform" attribute changes
   // and cause DoApplyRenderingChangeToTree to make the SchedulePaint call.
 
   if (aNameSpaceID == kNameSpaceID_None &&
-      (static_cast<SVGGeometryElement*>
+      (static_cast<nsSVGPathGeometryElement*>
                   (mContent)->AttributeDefinesGeometry(aAttribute))) {
     nsLayoutUtils::PostRestyleEvent(
       mContent->AsElement(), nsRestyleHint(0),
       nsChangeHint_InvalidateRenderingObservers);
     nsSVGUtils::ScheduleReflowSVG(this);
   }
   return NS_OK;
 }
 
 /* virtual */ void
-SVGGeometryFrame::DidSetStyleContext(nsStyleContext* aOldStyleContext)
+nsSVGPathGeometryFrame::DidSetStyleContext(nsStyleContext* aOldStyleContext)
 {
   nsFrame::DidSetStyleContext(aOldStyleContext);
 
   if (aOldStyleContext) {
     auto oldStyleEffects = aOldStyleContext->PeekStyleEffects();
     if (oldStyleEffects &&
         StyleEffects()->mOpacity != oldStyleEffects->mOpacity &&
         nsSVGUtils::CanOptimizeOpacity(this)) {
       // nsIFrame::BuildDisplayListForStackingContext() is not going to create an
       // nsDisplayOpacity display list item, so DLBI won't invalidate for us.
       InvalidateFrame();
     }
 
-    SVGGeometryElement* element =
-      static_cast<SVGGeometryElement*>(mContent);
+    nsSVGPathGeometryElement* element =
+      static_cast<nsSVGPathGeometryElement*>(mContent);
 
     auto oldStyleSVG = aOldStyleContext->PeekStyleSVG();
     if (oldStyleSVG && !SVGContentUtils::ShapeTypeHasNoCorners(mContent)) {
       if (StyleSVG()->mStrokeLinecap != oldStyleSVG->mStrokeLinecap &&
           element->IsSVGElement(nsGkAtoms::path)) {
         // If the stroke-linecap changes to or from "butt" then our element
         // needs to update its cached Moz2D Path, since SVGPathData::BuildPath
         // decides whether or not to insert little lines into the path for zero
@@ -219,24 +217,24 @@ SVGGeometryFrame::DidSetStyleContext(nsS
           element->ClearAnyCachedPath();
         }
       }
     }
   }
 }
 
 nsIAtom *
-SVGGeometryFrame::GetType() const
+nsSVGPathGeometryFrame::GetType() const
 {
-  return nsGkAtoms::svgGeometryFrame;
+  return nsGkAtoms::svgPathGeometryFrame;
 }
 
 bool
-SVGGeometryFrame::IsSVGTransformed(gfx::Matrix *aOwnTransform,
-                                   gfx::Matrix *aFromParentTransform) const
+nsSVGPathGeometryFrame::IsSVGTransformed(gfx::Matrix *aOwnTransform,
+                                         gfx::Matrix *aFromParentTransform) const
 {
   bool foundTransform = false;
 
   // Check if our parent has children-only transforms:
   nsIFrame *parent = GetParent();
   if (parent &&
       parent->IsFrameOfType(nsIFrame::eSVG | nsIFrame::eSVGContainer)) {
     foundTransform = static_cast<nsSVGContainerFrame*>(parent)->
@@ -255,36 +253,36 @@ SVGGeometryFrame::IsSVGTransformed(gfx::
                            eUserSpaceToParent));
     }
     foundTransform = true;
   }
   return foundTransform;
 }
 
 void
-SVGGeometryFrame::BuildDisplayList(nsDisplayListBuilder*   aBuilder,
-                                   const nsRect&           aDirtyRect,
-                                   const nsDisplayListSet& aLists)
+nsSVGPathGeometryFrame::BuildDisplayList(nsDisplayListBuilder*   aBuilder,
+                                         const nsRect&           aDirtyRect,
+                                         const nsDisplayListSet& aLists)
 {
   if (!static_cast<const nsSVGElement*>(mContent)->HasValidDimensions() ||
       (!IsVisibleForPainting(aBuilder) && aBuilder->IsForPainting())) {
     return;
   }
   DisplayOutline(aBuilder, aLists);
   aLists.Content()->AppendNewToTop(
-    new (aBuilder) nsDisplaySVGGeometry(aBuilder, this));
+    new (aBuilder) nsDisplaySVGPathGeometry(aBuilder, this));
 }
 
 //----------------------------------------------------------------------
 // nsISVGChildFrame methods
 
 DrawResult
-SVGGeometryFrame::PaintSVG(gfxContext& aContext,
-                           const gfxMatrix& aTransform,
-                           const nsIntRect* aDirtyRect)
+nsSVGPathGeometryFrame::PaintSVG(gfxContext& aContext,
+                                 const gfxMatrix& aTransform,
+                                 const nsIntRect* aDirtyRect)
 {
   if (!StyleVisibility()->IsVisible())
     return DrawResult::SUCCESS;
 
   // Matrix to the geometry's user space:
   gfxMatrix newMatrix =
     aContext.CurrentMatrix().PreMultiply(aTransform).NudgeToIntegers();
   if (newMatrix.IsSingular()) {
@@ -313,17 +311,17 @@ SVGGeometryFrame::PaintSVG(gfxContext& a
       paintOrder >>= NS_STYLE_PAINT_ORDER_BITWIDTH;
     }
   }
 
   return DrawResult::SUCCESS;
 }
 
 nsIFrame*
-SVGGeometryFrame::GetFrameForPoint(const gfxPoint& aPoint)
+nsSVGPathGeometryFrame::GetFrameForPoint(const gfxPoint& aPoint)
 {
   FillRule fillRule;
   uint16_t hitTestFlags;
   if (GetStateBits() & NS_STATE_SVG_CLIPPATH_CHILD) {
     hitTestFlags = SVG_HIT_TEST_FILL;
     fillRule = nsSVGUtils::ToFillRule(StyleSVG()->mClipRule);
   } else {
     hitTestFlags = GetHitTestFlags();
@@ -337,18 +335,18 @@ SVGGeometryFrame::GetFrameForPoint(const
         return nullptr;
       }
     }
     fillRule = nsSVGUtils::ToFillRule(StyleSVG()->mFillRule);
   }
 
   bool isHit = false;
 
-  SVGGeometryElement* content =
-    static_cast<SVGGeometryElement*>(mContent);
+  nsSVGPathGeometryElement* content =
+    static_cast<nsSVGPathGeometryElement*>(mContent);
 
   // Using ScreenReferenceDrawTarget() opens us to Moz2D backend specific hit-
   // testing bugs. Maybe we should use a BackendType::CAIRO DT for hit-testing
   // so that we get more consistent/backwards compatible results?
   RefPtr<DrawTarget> drawTarget =
     gfxPlatform::GetPlatform()->ScreenReferenceDrawTarget();
   RefPtr<Path> path = content->GetOrBuildPath(*drawTarget, fillRule);
   if (!path) {
@@ -378,17 +376,17 @@ SVGGeometryFrame::GetFrameForPoint(const
 
   if (isHit && nsSVGUtils::HitTestClip(this, aPoint))
     return this;
 
   return nullptr;
 }
 
 nsRect
-SVGGeometryFrame::GetCoveredRegion()
+nsSVGPathGeometryFrame::GetCoveredRegion()
 {
   gfxMatrix canvasTM = GetCanvasTM();
   if (canvasTM.PreservesAxisAlignedRectangles()) {
     return nsSVGUtils::TransformFrameRectToOuterSVG(
              mRect, canvasTM, PresContext());
   }
 
   // To get tight bounds we need to compute directly in outer SVG coordinates
@@ -400,17 +398,17 @@ SVGGeometryFrame::GetCoveredRegion()
   nsRect region = nsLayoutUtils::RoundGfxRectToAppRect(
                     extent, PresContext()->AppUnitsPerCSSPixel());
 
   return nsSVGUtils::TransformFrameRectToOuterSVG(
                        region, gfxMatrix(), PresContext());
 }
 
 void
-SVGGeometryFrame::ReflowSVG()
+nsSVGPathGeometryFrame::ReflowSVG()
 {
   NS_ASSERTION(nsSVGUtils::OuterSVGIsCallingReflowSVG(this),
                "This call is probably a wasteful mistake");
 
   MOZ_ASSERT(!(GetStateBits() & NS_FRAME_IS_NONDISPLAY),
              "ReflowSVG mechanism not designed for this");
 
   if (!nsSVGUtils::NeedsReflowSVG(this)) {
@@ -454,17 +452,17 @@ SVGGeometryFrame::ReflowSVG()
   // Invalidate, but only if this is not our first reflow (since if it is our
   // first reflow then we haven't had our first paint yet).
   if (!(GetParent()->GetStateBits() & NS_FRAME_FIRST_REFLOW)) {
     InvalidateFrame();
   }
 }
 
 void
-SVGGeometryFrame::NotifySVGChanged(uint32_t aFlags)
+nsSVGPathGeometryFrame::NotifySVGChanged(uint32_t aFlags)
 {
   MOZ_ASSERT(aFlags & (TRANSFORM_CHANGED | COORD_CONTEXT_CHANGED),
              "Invalidation logic may need adjusting");
 
   // Changes to our ancestors may affect how we render when we are rendered as
   // part of our ancestor (specifically, if our coordinate context changes size
   // and we have percentage lengths defining our geometry, then we need to be
   // reflowed). However, ancestor changes cannot affect how we render when we
@@ -478,43 +476,43 @@ SVGGeometryFrame::NotifySVGChanged(uint3
   // when it's not visible. See the complexities of GetBBoxContribution.
 
   if (aFlags & COORD_CONTEXT_CHANGED) {
     // Stroke currently contributes to our mRect, which is why we have to take
     // account of stroke-width here. Note that we do not need to take account
     // of stroke-dashoffset since, although that can have a percentage value
     // that is resolved against our coordinate context, it does not affect our
     // mRect.
-    if (static_cast<SVGGeometryElement*>(mContent)->GeometryDependsOnCoordCtx() ||
+    if (static_cast<nsSVGPathGeometryElement*>(mContent)->GeometryDependsOnCoordCtx() ||
         StyleSVG()->mStrokeWidth.HasPercent()) {
-      static_cast<SVGGeometryElement*>(mContent)->ClearAnyCachedPath();
+      static_cast<nsSVGPathGeometryElement*>(mContent)->ClearAnyCachedPath();
       nsSVGUtils::ScheduleReflowSVG(this);
     }
   }
 
   if ((aFlags & TRANSFORM_CHANGED) && StyleSVGReset()->HasNonScalingStroke()) {
     // Stroke currently contributes to our mRect, and our stroke depends on
     // the transform to our outer-<svg> if |vector-effect:non-scaling-stroke|.
     nsSVGUtils::ScheduleReflowSVG(this);
   } 
 }
 
 SVGBBox
-SVGGeometryFrame::GetBBoxContribution(const Matrix &aToBBoxUserspace,
-                                      uint32_t aFlags)
+nsSVGPathGeometryFrame::GetBBoxContribution(const Matrix &aToBBoxUserspace,
+                                            uint32_t aFlags)
 {
   SVGBBox bbox;
 
   if (aToBBoxUserspace.IsSingular()) {
     // XXX ReportToConsole
     return bbox;
   }
 
-  SVGGeometryElement* element =
-    static_cast<SVGGeometryElement*>(mContent);
+  nsSVGPathGeometryElement* element =
+    static_cast<nsSVGPathGeometryElement*>(mContent);
 
   bool getFill = (aFlags & nsSVGUtils::eBBoxIncludeFillGeometry) ||
                  ((aFlags & nsSVGUtils::eBBoxIncludeFill) &&
                   StyleSVG()->mFill.Type() != eStyleSVGPaintType_None);
 
   bool getStroke = (aFlags & nsSVGUtils::eBBoxIncludeStrokeGeometry) ||
                    ((aFlags & nsSVGUtils::eBBoxIncludeStroke) &&
                     nsSVGUtils::HasStroke(this));
@@ -620,17 +618,17 @@ SVGGeometryFrame::GetBBoxContribution(co
       // only do some GetStrokeOptions() implementations sometimes
       // significantly overestimate the stroke bounds, but if an argument is
       // passed for the aTransform parameter then they just return bounds-of-
       // transformed-bounds.  These two things combined can lead the bounds to
       // be unacceptably oversized, leading to massive over-invalidation.
       //
       // Second, the way we account for non-scaling-stroke by transforming the
       // path using the transform to the outer-<svg> element is not compatible
-      // with the way that SVGGeometryFrame::Reflow() inserts a scale
+      // with the way that nsSVGPathGeometryFrame::Reflow() inserts a scale
       // into aToBBoxUserspace and then scales the bounds that we return.
       SVGContentUtils::AutoStrokeOptions strokeOptions;
       SVGContentUtils::GetStrokeOptions(&strokeOptions, element,
                                         StyleContext(), nullptr,
                                         SVGContentUtils::eIgnoreStrokeDashing);
       Rect strokeBBoxExtents;
       gfxMatrix userToOuterSVG;
       if (nsSVGUtils::GetNonScalingStrokeTransform(this, &userToOuterSVG)) {
@@ -657,24 +655,24 @@ SVGGeometryFrame::GetBBoxContribution(co
       MOZ_ASSERT(ToRect(strokeBBoxExtents).IsFinite(), "bbox is about to go bad");
       bbox.UnionEdges(strokeBBoxExtents);
 #endif
     }
   }
 
   // Account for markers:
   if ((aFlags & nsSVGUtils::eBBoxIncludeMarkers) != 0 &&
-      static_cast<SVGGeometryElement*>(mContent)->IsMarkable()) {
+      static_cast<nsSVGPathGeometryElement*>(mContent)->IsMarkable()) {
 
     float strokeWidth = nsSVGUtils::GetStrokeWidth(this);
     MarkerProperties properties = GetMarkerProperties(this);
 
     if (properties.MarkersExist()) {
       nsTArray<nsSVGMark> marks;
-      static_cast<SVGGeometryElement*>(mContent)->GetMarkPoints(&marks);
+      static_cast<nsSVGPathGeometryElement*>(mContent)->GetMarkPoints(&marks);
       uint32_t num = marks.Length();
 
       // These are in the same order as the nsSVGMark::Type constants.
       nsSVGMarkerFrame* markerFrames[] = {
         properties.GetMarkerStartFrame(),
         properties.GetMarkerMidFrame(),
         properties.GetMarkerEndFrame(),
       };
@@ -694,31 +692,31 @@ SVGGeometryFrame::GetBBoxContribution(co
       }
     }
   }
 
   return bbox;
 }
 
 //----------------------------------------------------------------------
-// SVGGeometryFrame methods:
+// nsSVGPathGeometryFrame methods:
 
 gfxMatrix
-SVGGeometryFrame::GetCanvasTM()
+nsSVGPathGeometryFrame::GetCanvasTM()
 {
   NS_ASSERTION(GetParent(), "null parent");
 
   nsSVGContainerFrame *parent = static_cast<nsSVGContainerFrame*>(GetParent());
   dom::SVGGraphicsElement *content = static_cast<dom::SVGGraphicsElement*>(mContent);
 
   return content->PrependLocalTransformsTo(parent->GetCanvasTM());
 }
 
-SVGGeometryFrame::MarkerProperties
-SVGGeometryFrame::GetMarkerProperties(SVGGeometryFrame *aFrame)
+nsSVGPathGeometryFrame::MarkerProperties
+nsSVGPathGeometryFrame::GetMarkerProperties(nsSVGPathGeometryFrame *aFrame)
 {
   NS_ASSERTION(!aFrame->GetPrevContinuation(), "aFrame should be first continuation");
 
   MarkerProperties result;
   nsCOMPtr<nsIURI> markerURL =
     nsSVGEffects::GetMarkerURI(aFrame, &nsStyleSVG::mMarkerStart);
   result.mMarkerStart =
     nsSVGEffects::GetMarkerProperty(markerURL, aFrame,
@@ -732,57 +730,57 @@ SVGGeometryFrame::GetMarkerProperties(SV
   markerURL = nsSVGEffects::GetMarkerURI(aFrame, &nsStyleSVG::mMarkerEnd);
   result.mMarkerEnd =
     nsSVGEffects::GetMarkerProperty(markerURL, aFrame,
                                     nsSVGEffects::MarkerEndProperty());
   return result;
 }
 
 nsSVGMarkerFrame *
-SVGGeometryFrame::MarkerProperties::GetMarkerStartFrame()
+nsSVGPathGeometryFrame::MarkerProperties::GetMarkerStartFrame()
 {
   if (!mMarkerStart)
     return nullptr;
   return static_cast<nsSVGMarkerFrame *>
     (mMarkerStart->GetReferencedFrame(nsGkAtoms::svgMarkerFrame, nullptr));
 }
 
 nsSVGMarkerFrame *
-SVGGeometryFrame::MarkerProperties::GetMarkerMidFrame()
+nsSVGPathGeometryFrame::MarkerProperties::GetMarkerMidFrame()
 {
   if (!mMarkerMid)
     return nullptr;
   return static_cast<nsSVGMarkerFrame *>
     (mMarkerMid->GetReferencedFrame(nsGkAtoms::svgMarkerFrame, nullptr));
 }
 
 nsSVGMarkerFrame *
-SVGGeometryFrame::MarkerProperties::GetMarkerEndFrame()
+nsSVGPathGeometryFrame::MarkerProperties::GetMarkerEndFrame()
 {
   if (!mMarkerEnd)
     return nullptr;
   return static_cast<nsSVGMarkerFrame *>
     (mMarkerEnd->GetReferencedFrame(nsGkAtoms::svgMarkerFrame, nullptr));
 }
 
 void
-SVGGeometryFrame::Render(gfxContext* aContext,
-                         uint32_t aRenderComponents,
-                         const gfxMatrix& aNewTransform)
+nsSVGPathGeometryFrame::Render(gfxContext* aContext,
+                               uint32_t aRenderComponents,
+                               const gfxMatrix& aNewTransform)
 {
   MOZ_ASSERT(!aNewTransform.IsSingular());
 
   DrawTarget* drawTarget = aContext->GetDrawTarget();
 
   FillRule fillRule =
     nsSVGUtils::ToFillRule((GetStateBits() & NS_STATE_SVG_CLIPPATH_CHILD) ?
                              StyleSVG()->mClipRule : StyleSVG()->mFillRule);
 
-  SVGGeometryElement* element =
-    static_cast<SVGGeometryElement*>(mContent);
+  nsSVGPathGeometryElement* element =
+    static_cast<nsSVGPathGeometryElement*>(mContent);
 
   AntialiasMode aaMode =
     (StyleSVG()->mShapeRendering == NS_STYLE_SHAPE_RENDERING_OPTIMIZESPEED ||
      StyleSVG()->mShapeRendering == NS_STYLE_SHAPE_RENDERING_CRISPEDGES) ?
     AntialiasMode::NONE : AntialiasMode::SUBPIXEL;
 
   // We wait as late as possible before setting the transform so that we don't
   // set it unnecessarily if we return early (it's an expensive operation for
@@ -797,17 +795,17 @@ SVGGeometryFrame::Render(gfxContext* aCo
     if (path) {
       ColorPattern white(ToDeviceColor(Color(1.0f, 1.0f, 1.0f, 1.0f)));
       drawTarget->Fill(path, white,
                        DrawOptions(1.0f, CompositionOp::OP_OVER, aaMode));
     }
     return;
   }
 
-  SVGGeometryElement::SimplePath simplePath;
+  nsSVGPathGeometryElement::SimplePath simplePath;
   RefPtr<Path> path;
 
   element->GetAsSimplePath(&simplePath);
   if (!simplePath.IsPath()) {
     path = element->GetOrBuildPath(*drawTarget, fillRule);
     if (!path) {
       return;
     }
@@ -873,29 +871,29 @@ SVGGeometryFrame::Render(gfxContext* aCo
       } else {
         drawTarget->Stroke(path, strokePattern, strokeOptions, drawOptions);
       }
     }
   }
 }
 
 void
-SVGGeometryFrame::PaintMarkers(gfxContext& aContext,
-                               const gfxMatrix& aTransform)
+nsSVGPathGeometryFrame::PaintMarkers(gfxContext& aContext,
+                                     const gfxMatrix& aTransform)
 {
   SVGContextPaint* contextPaint = SVGContextPaint::GetContextPaint(mContent);
 
-  if (static_cast<SVGGeometryElement*>(mContent)->IsMarkable()) {
+  if (static_cast<nsSVGPathGeometryElement*>(mContent)->IsMarkable()) {
     MarkerProperties properties = GetMarkerProperties(this);
 
     if (properties.MarkersExist()) {
       float strokeWidth = nsSVGUtils::GetStrokeWidth(this, contextPaint);
 
       nsTArray<nsSVGMark> marks;
-      static_cast<SVGGeometryElement*>
+      static_cast<nsSVGPathGeometryElement*>
                  (mContent)->GetMarkPoints(&marks);
 
       uint32_t num = marks.Length();
       if (num) {
         // These are in the same order as the nsSVGMark::Type constants.
         nsSVGMarkerFrame* markerFrames[] = {
           properties.GetMarkerStartFrame(),
           properties.GetMarkerMidFrame(),
@@ -912,13 +910,12 @@ SVGGeometryFrame::PaintMarkers(gfxContex
           }
         }
       }
     }
   }
 }
 
 uint16_t
-SVGGeometryFrame::GetHitTestFlags()
+nsSVGPathGeometryFrame::GetHitTestFlags()
 {
   return nsSVGUtils::GetGeometryHitTestFlags(this);
 }
-} // namespace mozilla
rename from layout/svg/SVGGeometryFrame.h
rename to layout/svg/nsSVGPathGeometryFrame.h
--- a/layout/svg/SVGGeometryFrame.h
+++ b/layout/svg/nsSVGPathGeometryFrame.h
@@ -1,67 +1,61 @@
 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
-#ifndef __SVGGEOMETRYFRAME_H__
-#define __SVGGEOMETRYFRAME_H__
+#ifndef __NS_SVGPATHGEOMETRYFRAME_H__
+#define __NS_SVGPATHGEOMETRYFRAME_H__
 
 #include "mozilla/Attributes.h"
 #include "gfxMatrix.h"
 #include "gfxRect.h"
 #include "nsFrame.h"
 #include "nsISVGChildFrame.h"
 #include "nsLiteralString.h"
 #include "nsQueryFrame.h"
 #include "nsSVGUtils.h"
 
 namespace mozilla {
-class SVGGeometryFrame;
 namespace gfx {
 class DrawTarget;
 } // namespace gfx
 } // namespace mozilla
 
 class gfxContext;
-class nsDisplaySVGGeometry;
+class nsDisplaySVGPathGeometry;
 class nsIAtom;
 class nsIFrame;
 class nsIPresShell;
 class nsStyleContext;
 class nsSVGMarkerFrame;
 class nsSVGMarkerProperty;
 
 struct nsRect;
 
-nsIFrame*
-NS_NewSVGGeometryFrame(nsIPresShell* aPresShell, nsStyleContext* aContext);
-
-namespace mozilla {
-
-class SVGGeometryFrame : public nsFrame
-                       , public nsISVGChildFrame
+class nsSVGPathGeometryFrame : public nsFrame
+                             , public nsISVGChildFrame
 {
   typedef mozilla::gfx::DrawTarget DrawTarget;
 
   friend nsIFrame*
-  ::NS_NewSVGGeometryFrame(nsIPresShell* aPresShell, nsStyleContext* aContext);
+  NS_NewSVGPathGeometryFrame(nsIPresShell* aPresShell, nsStyleContext* aContext);
 
-  friend class ::nsDisplaySVGGeometry;
+  friend class nsDisplaySVGPathGeometry;
 
 protected:
-  explicit SVGGeometryFrame(nsStyleContext* aContext)
+  explicit nsSVGPathGeometryFrame(nsStyleContext* aContext)
     : nsFrame(aContext)
   {
      AddStateBits(NS_FRAME_SVG_LAYOUT | NS_FRAME_MAY_BE_TRANSFORMED);
   }
 
 public:
-  NS_DECL_QUERYFRAME_TARGET(SVGGeometryFrame)
+  NS_DECL_QUERYFRAME_TARGET(nsSVGPathGeometryFrame)
   NS_DECL_QUERYFRAME
   NS_DECL_FRAMEARENA_HELPERS
 
   // nsIFrame interface:
   virtual void Init(nsIContent*       aContent,
                     nsContainerFrame* aParent,
                     nsIFrame*         aPrevInFlow) override;
 
@@ -74,35 +68,35 @@ public:
                                      nsIAtom*        aAttribute,
                                      int32_t         aModType) override;
 
   virtual void DidSetStyleContext(nsStyleContext* aOldStyleContext) override;
 
   /**
    * Get the "type" of the frame
    *
-   * @see nsGkAtoms::svgGeometryFrame
+   * @see nsGkAtoms::svgPathGeometryFrame
    */
   virtual nsIAtom* GetType() const override;
 
   virtual bool IsSVGTransformed(Matrix *aOwnTransforms = nullptr,
                                 Matrix *aFromParentTransforms = nullptr) const override;
 
 #ifdef DEBUG_FRAME_DUMP
   virtual nsresult GetFrameName(nsAString& aResult) const override
   {
-    return MakeFrameName(NS_LITERAL_STRING("SVGGeometry"), aResult);
+    return MakeFrameName(NS_LITERAL_STRING("SVGPathGeometry"), aResult);
   }
 #endif
 
   virtual void BuildDisplayList(nsDisplayListBuilder*   aBuilder,
                                 const nsRect&           aDirtyRect,
                                 const nsDisplayListSet& aLists) override;
 
-  // SVGGeometryFrame methods
+  // nsSVGPathGeometryFrame methods
   gfxMatrix GetCanvasTM();
 protected:
   // nsISVGChildFrame interface:
   virtual DrawResult PaintSVG(gfxContext& aContext,
                               const gfxMatrix& aTransform,
                               const nsIntRect* aDirtyRect = nullptr) override;
   virtual nsIFrame* GetFrameForPoint(const gfxPoint& aPoint) override;
   virtual nsRect GetCoveredRegion() override;
@@ -142,13 +136,12 @@ private:
     nsSVGMarkerFrame *GetMarkerStartFrame();
     nsSVGMarkerFrame *GetMarkerMidFrame();
     nsSVGMarkerFrame *GetMarkerEndFrame();
   };
 
   /**
    * @param aFrame should be the first continuation
    */
-  static MarkerProperties GetMarkerProperties(SVGGeometryFrame *aFrame);
+  static MarkerProperties GetMarkerProperties(nsSVGPathGeometryFrame *aFrame);
 };
-} // namespace mozilla
 
-#endif // __SVGGEOMETRYFRAME_H__
+#endif // __NS_SVGPATHGEOMETRYFRAME_H__
--- a/layout/svg/nsSVGPatternFrame.cpp
+++ b/layout/svg/nsSVGPatternFrame.cpp
@@ -13,17 +13,17 @@
 #include "gfxPattern.h"
 #include "gfxPlatform.h"
 #include "mozilla/gfx/2D.h"
 #include "nsContentUtils.h"
 #include "nsGkAtoms.h"
 #include "nsISVGChildFrame.h"
 #include "nsStyleContext.h"
 #include "nsSVGEffects.h"
-#include "SVGGeometryFrame.h"
+#include "nsSVGPathGeometryFrame.h"
 #include "mozilla/dom/SVGPatternElement.h"
 #include "nsSVGUtils.h"
 #include "nsSVGAnimatedTransformList.h"
 #include "SVGContentUtils.h"
 
 using namespace mozilla;
 using namespace mozilla::dom;
 using namespace mozilla::gfx;
@@ -387,17 +387,17 @@ nsSVGPatternFrame::PaintPattern(const Dr
   }
 
   // OK, now render -- note that we use "firstKid", which
   // we got at the beginning because it takes care of the
   // referenced pattern situation for us
 
   if (aSource->IsFrameOfType(nsIFrame::eSVGGeometry)) {
     // Set the geometrical parent of the pattern we are rendering
-    patternWithChildren->mSource = static_cast<SVGGeometryFrame*>(aSource);
+    patternWithChildren->mSource = static_cast<nsSVGPathGeometryFrame*>(aSource);
   }
 
   // Delay checking NS_FRAME_DRAWING_AS_PAINTSERVER bit until here so we can
   // give back a clear surface if there's a loop
   if (!(patternWithChildren->GetStateBits() & NS_FRAME_DRAWING_AS_PAINTSERVER)) {
     patternWithChildren->AddStateBits(NS_FRAME_DRAWING_AS_PAINTSERVER);
     for (nsIFrame* kid = firstKid; kid;
          kid = kid->GetNextSibling()) {
--- a/layout/svg/nsSVGPatternFrame.h
+++ b/layout/svg/nsSVGPatternFrame.h
@@ -10,21 +10,21 @@
 #include "gfxMatrix.h"
 #include "mozilla/gfx/2D.h"
 #include "mozilla/RefPtr.h"
 #include "nsAutoPtr.h"
 #include "nsSVGPaintServerFrame.h"
 
 class nsIFrame;
 class nsSVGLength2;
+class nsSVGPathGeometryFrame;
 class nsSVGViewBox;
 
 namespace mozilla {
 class SVGAnimatedPreserveAspectRatio;
-class SVGGeometryFrame;
 class nsSVGAnimatedTransformList;
 } // namespace mozilla
 
 /**
  * Patterns can refer to other patterns. We create an nsSVGPaintingProperty
  * with property type nsGkAtoms::href to track the referenced pattern.
  */
 class nsSVGPatternFrame : public nsSVGPaintServerFrame
@@ -137,17 +137,17 @@ protected:
                           const gfxRect &callerBBox,
                           const Matrix &callerCTM,
                           nsIFrame *aTarget);
 
 private:
   // this is a *temporary* reference to the frame of the element currently
   // referencing our pattern.  This must be temporary because different
   // referencing frames will all reference this one frame
-  SVGGeometryFrame                 *mSource;
+  nsSVGPathGeometryFrame           *mSource;
   nsAutoPtr<gfxMatrix>              mCTM;
 
 protected:
   // This flag is used to detect loops in xlink:href processing
   bool                              mLoopFlag;
   bool                              mNoHRefURI;
 };
 
--- a/layout/svg/nsSVGUtils.cpp
+++ b/layout/svg/nsSVGUtils.cpp
@@ -41,18 +41,18 @@
 #include "nsSVGForeignObjectFrame.h"
 #include "nsSVGInnerSVGFrame.h"
 #include "nsSVGIntegrationUtils.h"
 #include "nsSVGLength2.h"
 #include "nsSVGMaskFrame.h"
 #include "nsSVGOuterSVGFrame.h"
 #include "mozilla/dom/SVGClipPathElement.h"
 #include "mozilla/dom/SVGPathElement.h"
-#include "SVGGeometryElement.h"
-#include "SVGGeometryFrame.h"
+#include "nsSVGPathGeometryElement.h"
+#include "nsSVGPathGeometryFrame.h"
 #include "nsSVGPaintServerFrame.h"
 #include "mozilla/dom/SVGSVGElement.h"
 #include "nsTextFrame.h"
 #include "SVGContentUtils.h"
 #include "SVGTextFrame.h"
 #include "mozilla/Unused.h"
 
 using namespace mozilla;
@@ -409,17 +409,17 @@ nsSVGUtils::GetCanvasTM(nsIFrame *aFrame
     return nsSVGIntegrationUtils::GetCSSPxToDevPxMatrix(aFrame);
   }
 
   nsSVGContainerFrame *containerFrame = do_QueryFrame(aFrame);
   if (containerFrame) {
     return containerFrame->GetCanvasTM();
   }
 
-  return static_cast<SVGGeometryFrame*>(aFrame)->GetCanvasTM();
+  return static_cast<nsSVGPathGeometryFrame*>(aFrame)->GetCanvasTM();
 }
 
 gfxMatrix
 nsSVGUtils::GetUserToCanvasTM(nsIFrame *aFrame)
 {
   nsISVGChildFrame* svgFrame = do_QueryFrame(aFrame);
   NS_ASSERTION(svgFrame, "bad frame");
 
@@ -1272,17 +1272,17 @@ nsSVGUtils::GetRelativeRect(uint16_t aUn
 bool
 nsSVGUtils::CanOptimizeOpacity(nsIFrame *aFrame)
 {
   if (!(aFrame->GetStateBits() & NS_FRAME_SVG_LAYOUT)) {
     return false;
   }
   nsIAtom *type = aFrame->GetType();
   if (type != nsGkAtoms::svgImageFrame &&
-      type != nsGkAtoms::svgGeometryFrame) {
+      type != nsGkAtoms::svgPathGeometryFrame) {
     return false;
   }
   if (aFrame->StyleEffects()->HasFilters()) {
     return false;
   }
   // XXX The SVG WG is intending to allow fill, stroke and markers on <image>
   if (type == nsGkAtoms::svgImageFrame) {
     return true;
@@ -1378,17 +1378,17 @@ nsSVGUtils::PathExtentsToMaxStrokeExtent
                                           const gfxMatrix& aMatrix)
 {
   NS_ASSERTION(aFrame->IsSVGText(), "expected an nsTextFrame for SVG text");
   return ::PathExtentsToMaxStrokeExtents(aPathExtents, aFrame, 0.5, aMatrix);
 }
 
 /*static*/ gfxRect
 nsSVGUtils::PathExtentsToMaxStrokeExtents(const gfxRect& aPathExtents,
-                                          SVGGeometryFrame* aFrame,
+                                          nsSVGPathGeometryFrame* aFrame,
                                           const gfxMatrix& aMatrix)
 {
   bool strokeMayHaveCorners =
     !SVGContentUtils::ShapeTypeHasNoCorners(aFrame->GetContent());
 
   // For a shape without corners the stroke can only extend half the stroke
   // width from the path in the x/y-axis directions. For shapes with corners
   // the stroke can extend by sqrt(1/2) (think 45 degree rotated rect, or line
--- a/layout/svg/nsSVGUtils.h
+++ b/layout/svg/nsSVGUtils.h
@@ -34,25 +34,25 @@ class nsIFrame;
 class nsPresContext;
 class nsStyleContext;
 class nsStyleSVGPaint;
 class nsSVGDisplayContainerFrame;
 class nsSVGElement;
 class nsSVGEnum;
 class nsSVGLength2;
 class nsSVGOuterSVGFrame;
+class nsSVGPathGeometryFrame;
 class nsTextFrame;
 
 struct nsStyleSVG;
 struct nsRect;
 
 namespace mozilla {
 class SVGContextPaint;
 struct SVGContextPaintImpl;
-class SVGGeometryFrame;
 namespace dom {
 class Element;
 class UserSpaceMetrics;
 } // namespace dom
 namespace gfx {
 class DrawTarget;
 class GeneralPattern;
 } // namespace gfx
@@ -181,17 +181,16 @@ public:
   typedef mozilla::dom::Element Element;
   typedef mozilla::gfx::AntialiasMode AntialiasMode;
   typedef mozilla::gfx::DrawTarget DrawTarget;
   typedef mozilla::gfx::FillRule FillRule;
   typedef mozilla::gfx::GeneralPattern GeneralPattern;
   typedef mozilla::gfx::Size Size;
   typedef mozilla::SVGContextPaint SVGContextPaint;
   typedef mozilla::SVGContextPaintImpl SVGContextPaintImpl;
-  typedef mozilla::SVGGeometryFrame SVGGeometryFrame;
   typedef mozilla::image::DrawResult DrawResult;
 
   static void Init();
 
   NS_DECLARE_FRAME_PROPERTY_DELETABLE(ObjectBoundingBoxProperty, gfxRect)
 
   /**
    * Gets the nearest nsSVGInnerSVGFrame or nsSVGOuterSVGFrame frame. aFrame
@@ -478,17 +477,17 @@ public:
    * fill/path extents.
    *
    * This should die once bug 478152 is fixed.
    */
   static gfxRect PathExtentsToMaxStrokeExtents(const gfxRect& aPathExtents,
                                                nsTextFrame* aFrame,
                                                const gfxMatrix& aMatrix);
   static gfxRect PathExtentsToMaxStrokeExtents(const gfxRect& aPathExtents,
-                                               SVGGeometryFrame* aFrame,
+                                               nsSVGPathGeometryFrame* aFrame,
                                                const gfxMatrix& aMatrix);
 
   /**
    * Convert a floating-point value to a 32-bit integer value, clamping to
    * the range of valid integers.
    */
   static int32_t ClampToInt(double aVal)
   {
--- a/testing/web-platform/meta/svg/historical.html.ini
+++ b/testing/web-platform/meta/svg/historical.html.ini
@@ -19,8 +19,17 @@
     expected: FAIL
 
   [SVGGraphicsElement.prototype.requiredFeatures must be removed]
     expected: FAIL
 
   [SVGSVGElement.prototype.useCurrentView must be removed]
     expected: FAIL
 
+  [SVGPathElement.prototype.getPointAtLength must be moved to SVGGeometryElement.prototype]
+    expected: FAIL
+
+  [SVGPathElement.prototype.getTotalLength must be moved to SVGGeometryElement.prototype]
+    expected: FAIL
+
+  [SVGPathElement.prototype.pathLength must be moved to SVGGeometryElement.prototype]
+    expected: FAIL
+
--- a/testing/web-platform/meta/svg/interfaces.html.ini
+++ b/testing/web-platform/meta/svg/interfaces.html.ini
@@ -1,10 +1,25 @@
 [interfaces.html]
   type: testharness
+  [SVGGeometryElement interface: existence and properties of interface object]
+    expected: FAIL
+
+  [SVGGeometryElement interface object length]
+    expected: FAIL
+
+  [SVGGeometryElement interface object name]
+    expected: FAIL
+
+  [SVGGeometryElement interface: existence and properties of interface prototype object]
+    expected: FAIL
+
+  [SVGGeometryElement interface: existence and properties of interface prototype object's "constructor" property]
+    expected: FAIL
+
   [SVGGeometryElement interface: operation isPointInFill(DOMPoint)]
     expected: FAIL
 
   [SVGGeometryElement interface: operation isPointInStroke(DOMPoint)]
     expected: FAIL
 
   [SVGNumber interface: existence and properties of interface object]
     expected: FAIL
@@ -286,23 +301,29 @@
     expected: FAIL
 
   [SVGElement interface: style must inherit property "onsort" with the proper type (62)]
     expected: FAIL
 
   [SVGTransform interface: svg.createSVGTransform() must inherit property "matrix" with the proper type (8)]
     expected: FAIL
 
-  [SVGGeometryElement interface: path must inherit property "isPointInFill" with the proper type (1)]
+  [SVGPathElement interface: existence and properties of interface object]
+    expected: FAIL
+
+  [SVGPathElement interface: existence and properties of interface prototype object]
+    expected: FAIL
+
+  [SVGGeometryElement interface: path must inherit property "isPointInFill" with the proper type (0)]
     expected: FAIL
 
   [SVGGeometryElement interface: calling isPointInFill(DOMPoint) on path with too few arguments must throw TypeError]
     expected: FAIL
 
-  [SVGGeometryElement interface: path must inherit property "isPointInStroke" with the proper type (2)]
+  [SVGGeometryElement interface: path must inherit property "isPointInStroke" with the proper type (1)]
     expected: FAIL
 
   [SVGGeometryElement interface: calling isPointInStroke(DOMPoint) on path with too few arguments must throw TypeError]
     expected: FAIL
 
   [SVGElement interface: path must inherit property "onautocomplete" with the proper type (8)]
     expected: FAIL
 
@@ -322,35 +343,23 @@
     expected: FAIL
 
   [SVGRectElement interface: existence and properties of interface object]
     expected: FAIL
 
   [SVGRectElement interface: existence and properties of interface prototype object]
     expected: FAIL
 
-  [SVGGeometryElement interface: rect must inherit property "pathLength" with the proper type (0)]
-    expected: FAIL
-
-  [SVGGeometryElement interface: rect must inherit property "isPointInFill" with the proper type (1)]
+  [SVGGeometryElement interface: rect must inherit property "isPointInFill" with the proper type (0)]
     expected: FAIL
 
   [SVGGeometryElement interface: calling isPointInFill(DOMPoint) on rect with too few arguments must throw TypeError]
     expected: FAIL
 
-  [SVGGeometryElement interface: rect must inherit property "isPointInStroke" with the proper type (2)]
-    expected: FAIL
-
-  [SVGGeometryElement interface: rect must inherit property "getTotalLength" with the proper type (3)]
-    expected: FAIL
-
-  [SVGGeometryElement interface: rect must inherit property "getPointAtLength" with the proper type (4)]
-    expected: FAIL
-
-  [SVGGeometryElement interface: calling getPointAtLength(float) on rect with too few arguments must throw TypeError]
+  [SVGGeometryElement interface: rect must inherit property "isPointInStroke" with the proper type (1)]
     expected: FAIL
 
   [SVGGeometryElement interface: calling isPointInStroke(DOMPoint) on rect with too few arguments must throw TypeError]
     expected: FAIL
 
   [SVGElement interface: rect must inherit property "onautocomplete" with the proper type (8)]
     expected: FAIL
 
@@ -370,40 +379,28 @@
     expected: FAIL
 
   [SVGCircleElement interface: existence and properties of interface object]
     expected: FAIL
 
   [SVGCircleElement interface: existence and properties of interface prototype object]
     expected: FAIL
 
-  [SVGGeometryElement interface: circle must inherit property "pathLength" with the proper type (0)]
-    expected: FAIL
-
-  [SVGGeometryElement interface: circle must inherit property "isPointInFill" with the proper type (1)]
+  [SVGGeometryElement interface: circle must inherit property "isPointInFill" with the proper type (0)]
     expected: FAIL
 
   [SVGGeometryElement interface: calling isPointInFill(DOMPoint) on circle with too few arguments must throw TypeError]
     expected: FAIL
 
-  [SVGGeometryElement interface: circle must inherit property "isPointInStroke" with the proper type (2)]
+  [SVGGeometryElement interface: circle must inherit property "isPointInStroke" with the proper type (1)]
     expected: FAIL
 
   [SVGGeometryElement interface: calling isPointInStroke(DOMPoint) on circle with too few arguments must throw TypeError]
     expected: FAIL
 
-  [SVGGeometryElement interface: circle must inherit property "getTotalLength" with the proper type (3)]
-    expected: FAIL
-
-  [SVGGeometryElement interface: circle must inherit property "getPointAtLength" with the proper type (4)]
-    expected: FAIL
-
-  [SVGGeometryElement interface: calling getPointAtLength(float) on circle with too few arguments must throw TypeError]
-    expected: FAIL
-
   [SVGElement interface: circle must inherit property "onautocomplete" with the proper type (8)]
     expected: FAIL
 
   [SVGElement interface: circle must inherit property "onautocompleteerror" with the proper type (9)]
     expected: FAIL
 
   [SVGElement interface: circle must inherit property "oncancel" with the proper type (11)]
     expected: FAIL
@@ -418,40 +415,28 @@
     expected: FAIL
 
   [SVGEllipseElement interface: existence and properties of interface object]
     expected: FAIL
 
   [SVGEllipseElement interface: existence and properties of interface prototype object]
     expected: FAIL
 
-  [SVGGeometryElement interface: ellipse must inherit property "pathLength" with the proper type (0)]
-    expected: FAIL
-
-  [SVGGeometryElement interface: ellipse must inherit property "isPointInFill" with the proper type (1)]
+  [SVGGeometryElement interface: ellipse must inherit property "isPointInFill" with the proper type (0)]
     expected: FAIL
 
   [SVGGeometryElement interface: calling isPointInFill(DOMPoint) on ellipse with too few arguments must throw TypeError]
     expected: FAIL
 
-  [SVGGeometryElement interface: ellipse must inherit property "isPointInStroke" with the proper type (2)]
+  [SVGGeometryElement interface: ellipse must inherit property "isPointInStroke" with the proper type (1)]
     expected: FAIL
 
   [SVGGeometryElement interface: calling isPointInStroke(DOMPoint) on ellipse with too few arguments must throw TypeError]
     expected: FAIL
 
-  [SVGGeometryElement interface: ellipse must inherit property "getTotalLength" with the proper type (3)]
-    expected: FAIL
-
-  [SVGGeometryElement interface: ellipse must inherit property "getPointAtLength" with the proper type (4)]
-    expected: FAIL
-
-  [SVGGeometryElement interface: calling getPointAtLength(float) on ellipse with too few arguments must throw TypeError]
-    expected: FAIL
-
   [SVGElement interface: ellipse must inherit property "onautocomplete" with the proper type (8)]
     expected: FAIL
 
   [SVGElement interface: ellipse must inherit property "onautocompleteerror" with the proper type (9)]
     expected: FAIL
 
   [SVGElement interface: ellipse must inherit property "oncancel" with the proper type (11)]
     expected: FAIL
@@ -466,40 +451,28 @@
     expected: FAIL
 
   [SVGLineElement interface: existence and properties of interface object]
     expected: FAIL
 
   [SVGLineElement interface: existence and properties of interface prototype object]
     expected: FAIL
 
-  [SVGGeometryElement interface: line must inherit property "pathLength" with the proper type (0)]
-    expected: FAIL
-
-  [SVGGeometryElement interface: line must inherit property "isPointInFill" with the proper type (1)]
+  [SVGGeometryElement interface: line must inherit property "isPointInFill" with the proper type (0)]
     expected: FAIL
 
   [SVGGeometryElement interface: calling isPointInFill(DOMPoint) on line with too few arguments must throw TypeError]
     expected: FAIL
 
-  [SVGGeometryElement interface: line must inherit property "isPointInStroke" with the proper type (2)]
+  [SVGGeometryElement interface: line must inherit property "isPointInStroke" with the proper type (1)]
     expected: FAIL
 
   [SVGGeometryElement interface: calling isPointInStroke(DOMPoint) on line with too few arguments must throw TypeError]
     expected: FAIL
 
-  [SVGGeometryElement interface: line must inherit property "getTotalLength" with the proper type (3)]
-    expected: FAIL
-
-  [SVGGeometryElement interface: line must inherit property "getPointAtLength" with the proper type (4)]
-    expected: FAIL
-
-  [SVGGeometryElement interface: calling getPointAtLength(float) on line with too few arguments must throw TypeError]
-    expected: FAIL
-
   [SVGElement interface: line must inherit property "onautocomplete" with the proper type (8)]
     expected: FAIL
 
   [SVGElement interface: line must inherit property "onautocompleteerror" with the proper type (9)]
     expected: FAIL
 
   [SVGElement interface: line must inherit property "oncancel" with the proper type (11)]
     expected: FAIL
@@ -514,40 +487,28 @@
     expected: FAIL
 
   [SVGPolylineElement interface: existence and properties of interface object]
     expected: FAIL
 
   [SVGPolylineElement interface: existence and properties of interface prototype object]
     expected: FAIL
 
-  [SVGGeometryElement interface: polyline must inherit property "pathLength" with the proper type (0)]
-    expected: FAIL
-
-  [SVGGeometryElement interface: polyline must inherit property "isPointInFill" with the proper type (1)]
+  [SVGGeometryElement interface: polyline must inherit property "isPointInFill" with the proper type (0)]
     expected: FAIL
 
   [SVGGeometryElement interface: calling isPointInFill(DOMPoint) on polyline with too few arguments must throw TypeError]
     expected: FAIL
 
-  [SVGGeometryElement interface: polyline must inherit property "isPointInStroke" with the proper type (2)]
+  [SVGGeometryElement interface: polyline must inherit property "isPointInStroke" with the proper type (1)]
     expected: FAIL
 
   [SVGGeometryElement interface: calling isPointInStroke(DOMPoint) on polyline with too few arguments must throw TypeError]
     expected: FAIL
 
-  [SVGGeometryElement interface: polyline must inherit property "getTotalLength" with the proper type (3)]
-    expected: FAIL
-
-  [SVGGeometryElement interface: polyline must inherit property "getPointAtLength" with the proper type (4)]
-    expected: FAIL
-
-  [SVGGeometryElement interface: calling getPointAtLength(float) on polyline with too few arguments must throw TypeError]
-    expected: FAIL
-
   [SVGElement interface: polyline must inherit property "onautocomplete" with the proper type (8)]
     expected: FAIL
 
   [SVGElement interface: polyline must inherit property "onautocompleteerror" with the proper type (9)]
     expected: FAIL
 
   [SVGElement interface: polyline must inherit property "oncancel" with the proper type (11)]
     expected: FAIL
@@ -562,40 +523,28 @@
     expected: FAIL
 
   [SVGPolygonElement interface: existence and properties of interface object]
     expected: FAIL
 
   [SVGPolygonElement interface: existence and properties of interface prototype object]
     expected: FAIL
 
-  [SVGGeometryElement interface: polygon must inherit property "pathLength" with the proper type (0)]
-    expected: FAIL
-
-  [SVGGeometryElement interface: polygon must inherit property "isPointInFill" with the proper type (1)]
+  [SVGGeometryElement interface: polygon must inherit property "isPointInFill" with the proper type (0)]
     expected: FAIL
 
   [SVGGeometryElement interface: calling isPointInFill(DOMPoint) on polygon with too few arguments must throw TypeError]
     expected: FAIL
 
-  [SVGGeometryElement interface: polygon must inherit property "isPointInStroke" with the proper type (2)]
+  [SVGGeometryElement interface: polygon must inherit property "isPointInStroke" with the proper type (1)]
     expected: FAIL
 
   [SVGGeometryElement interface: calling isPointInStroke(DOMPoint) on polygon with too few arguments must throw TypeError]
     expected: FAIL
 
-  [SVGGeometryElement interface: polygon must inherit property "getTotalLength" with the proper type (3)]
-    expected: FAIL
-
-  [SVGGeometryElement interface: polygon must inherit property "getPointAtLength" with the proper type (4)]
-    expected: FAIL
-
-  [SVGGeometryElement interface: calling getPointAtLength(float) on polygon with too few arguments must throw TypeError]
-    expected: FAIL
-
   [SVGElement interface: polygon must inherit property "onautocomplete" with the proper type (8)]
     expected: FAIL
 
   [SVGElement interface: polygon must inherit property "onautocompleteerror" with the proper type (9)]
     expected: FAIL
 
   [SVGElement interface: polygon must inherit property "oncancel" with the proper type (11)]
     expected: FAIL
@@ -1603,16 +1552,25 @@
     expected: FAIL
 
   [SVGElement interface: feTurbulence must inherit property "oncuechange" with the proper type (18)]
     expected: FAIL
 
   [SVGElement interface: feTurbulence must inherit property "onsort" with the proper type (62)]
     expected: FAIL
 
+  [SVGGeometryElement interface: attribute pathLength]
+    expected: FAIL
+
+  [SVGGeometryElement interface: operation getTotalLength()]
+    expected: FAIL
+
+  [SVGGeometryElement interface: operation getPointAtLength(float)]
+    expected: FAIL
+
   [SVGGeometryElement interface: path must inherit property "isPointInFill" with the proper type (1)]
     expected: FAIL
 
   [SVGGeometryElement interface: path must inherit property "isPointInStroke" with the proper type (2)]
     expected: FAIL
 
   [SVGGeometryElement interface: rect must inherit property "pathLength" with the proper type (0)]
     expected: FAIL