svgio/inc/svgio/svgreader/svgnode.hxx     |    2 +-
 svgio/inc/svgio/svgreader/svgtextnode.hxx |    2 ++
 svgio/source/svgreader/svgtextnode.cxx    |    5 +++++
 3 files changed, 8 insertions(+), 1 deletion(-)

New commits:
commit 701324a1e1f7e0c181ff1a50956ced686785ea53
Author: Xisco Fauli <aniste...@gmail.com>
Date:   Tue Jan 26 01:29:22 2016 +0100

    SVGIO: tdf#45771: Fix issue when text size is twice its size...
    
    ... when using relative units (em, ex)
    
    This is because for nodes of type textnode, getFontSizeNumber
    is called from SvgCharacterNode::createSimpleTextPrimitive
    and from SvgNode::getCurrentFontSize(), so avoid the second call.
    
    Change-Id: Ibd418708a572e3c1643164a900fac7e7481afe81
    Reviewed-on: https://gerrit.libreoffice.org/21801
    Tested-by: Jenkins <c...@libreoffice.org>
    Reviewed-by: Noel Grandin <noelgran...@gmail.com>

diff --git a/svgio/inc/svgio/svgreader/svgnode.hxx 
b/svgio/inc/svgio/svgreader/svgnode.hxx
index ab7f28a..d72cde3 100644
--- a/svgio/inc/svgio/svgreader/svgnode.hxx
+++ b/svgio/inc/svgio/svgreader/svgnode.hxx
@@ -160,7 +160,7 @@ namespace svgio
             virtual double getCurrentFontSizeInherited() const override;
             virtual double getCurrentXHeightInherited() const override;
 
-            double getCurrentFontSize() const;
+            virtual double getCurrentFontSize() const;
             double getCurrentXHeight() const;
 
             /// Id access
diff --git a/svgio/inc/svgio/svgreader/svgtextnode.hxx 
b/svgio/inc/svgio/svgreader/svgtextnode.hxx
index 7922f13..86c1321 100644
--- a/svgio/inc/svgio/svgreader/svgtextnode.hxx
+++ b/svgio/inc/svgio/svgreader/svgtextnode.hxx
@@ -58,6 +58,8 @@ namespace svgio
             virtual void parseAttribute(const OUString& rTokenName, SVGToken 
aSVGToken, const OUString& aContent) override;
             virtual void 
decomposeSvgNode(drawinglayer::primitive2d::Primitive2DContainer& rTarget, bool 
bReferenced) const override;
 
+            virtual double getCurrentFontSize() const override;
+
             /// transform content, set if found in current context
             const basegfx::B2DHomMatrix* getTransform() const { return 
mpaTransform; }
             void setTransform(const basegfx::B2DHomMatrix* pMatrix = nullptr) 
{ if(mpaTransform) delete mpaTransform; mpaTransform = nullptr; if(pMatrix) 
mpaTransform = new basegfx::B2DHomMatrix(*pMatrix); }
diff --git a/svgio/source/svgreader/svgtextnode.cxx 
b/svgio/source/svgreader/svgtextnode.cxx
index 4637bce..ae7d0e1 100644
--- a/svgio/source/svgreader/svgtextnode.cxx
+++ b/svgio/source/svgreader/svgtextnode.cxx
@@ -260,6 +260,11 @@ namespace svgio
                 }
             }
         }
+
+        double SvgTextNode::getCurrentFontSize() const
+        {
+            return getCurrentFontSizeInherited();
+        }
     } // end of namespace svgreader
 } // end of namespace svgio
 
_______________________________________________
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to