summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobert Longson <longsonr@gmail.com>2018-03-29 03:12:05 +0100
committerwolfbeast <mcwerewolf@gmail.com>2018-04-19 11:39:36 +0200
commit27d502fa7c87048780fc0445b29354e24b34804b (patch)
tree177bf9ba21e1997671bb0ad0082a2d33ceaccf40
parent85d6e8c1b47d826f574b320b690a510d65632c03 (diff)
downloaduxp-27d502fa7c87048780fc0445b29354e24b34804b.tar.gz
Bug 1448774. r=dholbert, a=RyanVM
--HG-- extra : source : edfd9ffbd7208ef0a59f40a0d77d8dd53c905cb9 extra : intermediate-source : 3784b22ec536b08ce95201d73ae8806340c18b8c
-rw-r--r--dom/svg/SVGTextContentElement.h1
-rw-r--r--layout/svg/SVGTextFrame.cpp4
2 files changed, 3 insertions, 2 deletions
diff --git a/dom/svg/SVGTextContentElement.h b/dom/svg/SVGTextContentElement.h
index 905468228f..5f126c8112 100644
--- a/dom/svg/SVGTextContentElement.h
+++ b/dom/svg/SVGTextContentElement.h
@@ -29,6 +29,7 @@ typedef SVGGraphicsElement SVGTextContentElementBase;
class SVGTextContentElement : public SVGTextContentElementBase
{
+ friend class ::SVGTextFrame;
public:
using FragmentOrElement::TextLength;
diff --git a/layout/svg/SVGTextFrame.cpp b/layout/svg/SVGTextFrame.cpp
index e681260682..e5a03333f9 100644
--- a/layout/svg/SVGTextFrame.cpp
+++ b/layout/svg/SVGTextFrame.cpp
@@ -5111,8 +5111,8 @@ SVGTextFrame::DoGlyphPositioning()
float actualTextLength =
static_cast<float>(presContext->AppUnitsToGfxUnits(frameLength) * factor);
- RefPtr<SVGAnimatedEnumeration> lengthAdjustEnum = element->LengthAdjust();
- uint16_t lengthAdjust = lengthAdjustEnum->AnimVal();
+ uint16_t lengthAdjust =
+ element->EnumAttributes()[SVGTextContentElement::LENGTHADJUST].GetAnimValue();
switch (lengthAdjust) {
case SVG_LENGTHADJUST_SPACINGANDGLYPHS:
// Scale the glyphs and their positions.