From adb203bc05e3e36173cbd46b9951f79821a81799 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Mon, 15 Apr 2024 11:27:54 +0200 Subject: Merging upstream version 4:24.2.1. Signed-off-by: Daniel Baumann --- svgio/inc/svgstyleattributes.hxx | 3 ++- svgio/inc/svgsymbolnode.hxx | 15 +++++++++++++++ 2 files changed, 17 insertions(+), 1 deletion(-) (limited to 'svgio/inc') diff --git a/svgio/inc/svgstyleattributes.hxx b/svgio/inc/svgstyleattributes.hxx index 6078194266..4516773e83 100644 --- a/svgio/inc/svgstyleattributes.hxx +++ b/svgio/inc/svgstyleattributes.hxx @@ -166,7 +166,8 @@ namespace svgio::svgreader { Auto, Middle, - Hanging + Hanging, + Central }; enum class Visibility diff --git a/svgio/inc/svgsymbolnode.hxx b/svgio/inc/svgsymbolnode.hxx index 7a19b335b7..e82f75a767 100644 --- a/svgio/inc/svgsymbolnode.hxx +++ b/svgio/inc/svgsymbolnode.hxx @@ -29,6 +29,12 @@ namespace svgio::svgreader /// use styles SvgStyleAttributes maSvgStyleAttributes; + SvgNumber maX; + SvgNumber maY; + SvgNumber maWidth; + SvgNumber maHeight; + + std::unique_ptr mpViewBox; SvgAspectRatio maSvgAspectRatio; public: @@ -39,6 +45,15 @@ namespace svgio::svgreader virtual const SvgStyleAttributes* getSvgStyleAttributes() const override; virtual void parseAttribute(SVGToken aSVGToken, const OUString& aContent) override; + virtual void decomposeSvgNode(drawinglayer::primitive2d::Primitive2DContainer& rTarget, bool bReferenced) const override; + + /// viewBox content + const basegfx::B2DRange* getViewBox() const { return mpViewBox.get(); } + void setViewBox(const basegfx::B2DRange* pViewBox) { mpViewBox.reset(); if(pViewBox) mpViewBox.reset( new basegfx::B2DRange(*pViewBox) ); } + + /// SvgAspectRatio content + const SvgAspectRatio& getSvgAspectRatio() const { return maSvgAspectRatio; } + }; } // end of namespace svgio::svgreader -- cgit v1.2.3