incubator-ooo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From a..@apache.org
Subject svn commit: r1209140 [4/11] - in /incubator/ooo/branches/alg/svgreplacement/main: ./ basegfx/inc/basegfx/matrix/ basegfx/inc/basegfx/polygon/ basegfx/source/polygon/ cppcanvas/source/mtfrenderer/ drawinglayer/ drawinglayer/inc/drawinglayer/primitive2d/...
Date Thu, 01 Dec 2011 16:26:53 GMT
Added: incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgellipsenode.hxx
URL: http://svn.apache.org/viewvc/incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgellipsenode.hxx?rev=1209140&view=auto
==============================================================================
--- incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgellipsenode.hxx (added)
+++ incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgellipsenode.hxx Thu Dec  1 16:25:17 2011
@@ -0,0 +1,85 @@
+/**************************************************************
+ * 
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ * 
+ *************************************************************/
+
+#ifndef INCLUDED_SVGIO_SVGREADER_SVGELLIPSENODE_HXX
+#define INCLUDED_SVGIO_SVGREADER_SVGELLIPSENODE_HXX
+
+#include <svgio/svgiodllapi.h>
+#include <svgio/svgreader/svgnode.hxx>
+#include <svgio/svgreader/svgstyleattributes.hxx>
+
+//////////////////////////////////////////////////////////////////////////////
+
+namespace svgio
+{
+    namespace svgreader
+    {
+        class SvgEllipseNode : public SvgNode
+        {
+        private:
+            /// use styles
+            SvgStyleAttributes          maSvgStyleAttributes;
+
+            /// variable scan values, dependent of given XAttributeList
+            SvgNumber               maCx;
+            SvgNumber               maCy;
+            SvgNumber               maRx;
+            SvgNumber               maRy;
+            basegfx::B2DHomMatrix*  mpaTransform;
+
+        public:
+            SvgEllipseNode(
+                SvgDocument& rDocument,
+                SvgNode* pParent);
+            virtual ~SvgEllipseNode();
+
+            virtual const SvgStyleAttributes* getSvgStyleAttributes() const;
+            virtual void parseAttribute(const rtl::OUString& rTokenName, SVGToken aSVGToken, const rtl::OUString& aContent);
+            virtual void decomposeSvgNode(drawinglayer::primitive2d::Primitive2DVector& rTarget, bool bReferenced) const;
+
+            /// Cx content, set if found in current context
+            const SvgNumber& getCx() const { return maCx; }
+            void setCx(const SvgNumber& rCx = SvgNumber()) { maCx = rCx; }
+
+            /// Cy content, set if found in current context
+            const SvgNumber& getCy() const { return maCy; }
+            void setCy(const SvgNumber& rCy = SvgNumber()) { maCy = rCy; }
+
+            /// Rx content, set if found in current context
+            const SvgNumber& getRx() const { return maRx; }
+            void setRx(const SvgNumber& rRx = SvgNumber()) { maRx = rRx; }
+
+            /// Ry content, set if found in current context
+            const SvgNumber& getRy() const { return maRy; }
+            void setRy(const SvgNumber& rRy = SvgNumber()) { maRy = rRy; }
+
+            /// transform content, set if found in current context
+            const basegfx::B2DHomMatrix* getTransform() const { return mpaTransform; }
+            void setTransform(const basegfx::B2DHomMatrix* pMatrix = 0) { if(mpaTransform) delete mpaTransform; mpaTransform = 0; if(pMatrix) mpaTransform = new basegfx::B2DHomMatrix(*pMatrix); }
+        };
+    } // end of namespace svgreader
+} // end of namespace svgio
+
+//////////////////////////////////////////////////////////////////////////////
+
+#endif //INCLUDED_SVGIO_SVGREADER_SVGELLIPSENODE_HXX
+
+// eof

Added: incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svggnode.hxx
URL: http://svn.apache.org/viewvc/incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svggnode.hxx?rev=1209140&view=auto
==============================================================================
--- incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svggnode.hxx (added)
+++ incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svggnode.hxx Thu Dec  1 16:25:17 2011
@@ -0,0 +1,66 @@
+/**************************************************************
+ * 
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ * 
+ *************************************************************/
+
+#ifndef INCLUDED_SVGIO_SVGREADER_SVGGNODE_HXX
+#define INCLUDED_SVGIO_SVGREADER_SVGGNODE_HXX
+
+#include <svgio/svgiodllapi.h>
+#include <svgio/svgreader/svgnode.hxx>
+#include <svgio/svgreader/svgstyleattributes.hxx>
+
+//////////////////////////////////////////////////////////////////////////////
+
+namespace svgio
+{
+    namespace svgreader
+    {
+        class SvgGNode : public SvgNode
+        {
+        private:
+            /// use styles
+            SvgStyleAttributes          maSvgStyleAttributes;
+
+            /// variable scan values, dependent of given XAttributeList
+            basegfx::B2DHomMatrix*      mpaTransform;
+
+        public:
+            SvgGNode(
+                SVGToken aType,
+                SvgDocument& rDocument,
+                SvgNode* pParent);
+            virtual ~SvgGNode();
+
+            virtual const SvgStyleAttributes* getSvgStyleAttributes() const;
+            virtual void parseAttribute(const rtl::OUString& rTokenName, SVGToken aSVGToken, const rtl::OUString& aContent);
+            virtual void decomposeSvgNode(drawinglayer::primitive2d::Primitive2DVector& rTarget, bool bReferenced) const;
+            
+            /// transform content
+            const basegfx::B2DHomMatrix* getTransform() const { return mpaTransform; }
+            void setTransform(const basegfx::B2DHomMatrix* pMatrix = 0) { if(mpaTransform) delete mpaTransform; mpaTransform = 0; if(pMatrix) mpaTransform = new basegfx::B2DHomMatrix(*pMatrix); }
+        };
+    } // end of namespace svgreader
+} // end of namespace svgio
+
+//////////////////////////////////////////////////////////////////////////////
+
+#endif //INCLUDED_SVGIO_SVGREADER_SVGGNODE_HXX
+
+// eof

Added: incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svggradientnode.hxx
URL: http://svn.apache.org/viewvc/incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svggradientnode.hxx?rev=1209140&view=auto
==============================================================================
--- incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svggradientnode.hxx (added)
+++ incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svggradientnode.hxx Thu Dec  1 16:25:17 2011
@@ -0,0 +1,142 @@
+/**************************************************************
+ * 
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ * 
+ *************************************************************/
+
+#ifndef INCLUDED_SVGIO_SVGREADER_SVGGRADIENTNODE_HXX
+#define INCLUDED_SVGIO_SVGREADER_SVGGRADIENTNODE_HXX
+
+#include <svgio/svgiodllapi.h>
+#include <svgio/svgreader/svgnode.hxx>
+#include <svgio/svgreader/svgstyleattributes.hxx>
+#include <drawinglayer/primitive2d/svggradientprimitive2d.hxx>
+
+//////////////////////////////////////////////////////////////////////////////
+
+namespace svgio
+{
+    namespace svgreader
+    {
+        enum gradientUnits
+        {
+            userSpaceOnUse,
+            objectBoundingBox
+        };
+
+        class SvgGradientNode : public SvgNode
+        {
+        private:
+            /// use styles
+            SvgStyleAttributes          maSvgStyleAttributes;
+
+            /// linear gradient values
+            SvgNumber                   maX1;
+            SvgNumber                   maY1;
+            SvgNumber                   maX2;
+            SvgNumber                   maY2;
+
+            /// radial gradient values
+            SvgNumber                   maCx;
+            SvgNumber                   maCy;
+            SvgNumber                   maR;
+            SvgNumber                   maFx;
+            SvgNumber                   maFy;
+
+            /// variable scan values, dependent of given XAttributeList
+            gradientUnits               maGradientUnits;
+            drawinglayer::primitive2d::SpreadMethod   maSpreadMethod;
+            basegfx::B2DHomMatrix*      mpaGradientTransform;
+
+            /// link to another gradient used as style. If maXLink
+            /// is set, the node can be fetched on demand
+            rtl::OUString               maXLink;
+            const SvgGradientNode*      mpXLink;
+
+            /// link on demand
+            void tryToFindLink();
+
+        public:
+            SvgGradientNode(
+                SVGToken aType,
+                SvgDocument& rDocument,
+                SvgNode* pParent);
+            virtual ~SvgGradientNode();
+
+            virtual const SvgStyleAttributes* getSvgStyleAttributes() const;
+            virtual void parseAttribute(const rtl::OUString& rTokenName, SVGToken aSVGToken, const rtl::OUString& aContent);
+
+            /// collect gradient stop entries
+            void collectGradientEntries(drawinglayer::primitive2d::SvgGradientEntryVector& aVector) const;
+
+            /// x1 content
+            const SvgNumber getX1() const;
+            void setX1(const SvgNumber& rX1 = SvgNumber()) { maX1 = rX1; }
+
+            /// y1 content
+            const SvgNumber getY1() const;
+            void setY1(const SvgNumber& rY1 = SvgNumber()) { maY1 = rY1; }
+
+            /// x2 content
+            const SvgNumber getX2() const;
+            void setX2(const SvgNumber& rX2 = SvgNumber()) { maX2 = rX2; }
+
+            /// y2 content
+            const SvgNumber getY2() const;
+            void setY2(const SvgNumber& rY2 = SvgNumber()) { maY2 = rY2; }
+
+            /// Cx content
+            const SvgNumber getCx() const;
+            void setCx(const SvgNumber& rCx = SvgNumber()) { maCx = rCx; }
+
+            /// Cy content
+            const SvgNumber getCy() const;
+            void setCy(const SvgNumber& rCy = SvgNumber()) { maCy = rCy; }
+
+            /// R content
+            const SvgNumber getR() const;
+            void setR(const SvgNumber& rR = SvgNumber()) { maR = rR; }
+
+            /// Fx content
+            const SvgNumber* getFx() const;
+            void setFx(const SvgNumber& rFx = SvgNumber()) { maFx = rFx; }
+
+            /// Fy content
+            const SvgNumber* getFy() const;
+            void setFy(const SvgNumber& rFy = SvgNumber()) { maFy = rFy; }
+
+            /// gradientUnits content
+            gradientUnits getGradientUnits() const { return maGradientUnits; }
+            void setGradientUnits(const gradientUnits aGradientUnits) { maGradientUnits = aGradientUnits; }
+
+            /// SpreadMethod content
+            drawinglayer::primitive2d::SpreadMethod getSpreadMethod() const { return maSpreadMethod; }
+            void setSpreadMethod(const drawinglayer::primitive2d::SpreadMethod aSpreadMethod) { maSpreadMethod = aSpreadMethod; }
+
+            /// transform content, set if found in current context
+            const basegfx::B2DHomMatrix* getGradientTransform() const;
+            void setGradientTransform(const basegfx::B2DHomMatrix* pMatrix = 0);
+        };
+    } // end of namespace svgreader
+} // end of namespace svgio
+
+//////////////////////////////////////////////////////////////////////////////
+
+#endif //INCLUDED_SVGIO_SVGREADER_SVGGRADIENTNODE_HXX
+
+// eof

Added: incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svggradientstopnode.hxx
URL: http://svn.apache.org/viewvc/incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svggradientstopnode.hxx?rev=1209140&view=auto
==============================================================================
--- incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svggradientstopnode.hxx (added)
+++ incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svggradientstopnode.hxx Thu Dec  1 16:25:17 2011
@@ -0,0 +1,64 @@
+/**************************************************************
+ * 
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ * 
+ *************************************************************/
+
+#ifndef INCLUDED_SVGIO_SVGREADER_SVGGRADIENTSTOPNODE_HXX
+#define INCLUDED_SVGIO_SVGREADER_SVGGRADIENTSTOPNODE_HXX
+
+#include <svgio/svgiodllapi.h>
+#include <svgio/svgreader/svgnode.hxx>
+#include <svgio/svgreader/svgstyleattributes.hxx>
+
+//////////////////////////////////////////////////////////////////////////////
+
+namespace svgio
+{
+    namespace svgreader
+    {
+        class SvgGradientStopNode : public SvgNode
+        {
+        private:
+            /// use styles
+            SvgStyleAttributes          maSvgStyleAttributes;
+
+            /// local attributes
+            SvgNumber                   maOffset;
+
+        public:
+            SvgGradientStopNode(
+                SvgDocument& rDocument,
+                SvgNode* pParent);
+            virtual ~SvgGradientStopNode();
+
+            virtual const SvgStyleAttributes* getSvgStyleAttributes() const;
+            virtual void parseAttribute(const rtl::OUString& rTokenName, SVGToken aSVGToken, const rtl::OUString& aContent);
+
+            /// offset content
+            const SvgNumber getOffset() const { return maOffset; }
+            void setOffset(const SvgNumber& rOffset = SvgNumber()) { maOffset = rOffset; }
+        };
+    } // end of namespace svgreader
+} // end of namespace svgio
+
+//////////////////////////////////////////////////////////////////////////////
+
+#endif //INCLUDED_SVGIO_SVGREADER_SVGGRADIENTSTOPNODE_HXX
+
+// eof

Added: incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgimagenode.hxx
URL: http://svn.apache.org/viewvc/incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgimagenode.hxx?rev=1209140&view=auto
==============================================================================
--- incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgimagenode.hxx (added)
+++ incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgimagenode.hxx Thu Dec  1 16:25:17 2011
@@ -0,0 +1,94 @@
+/**************************************************************
+ * 
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ * 
+ *************************************************************/
+
+#ifndef INCLUDED_SVGIO_SVGREADER_SVGIMAGENODE_HXX
+#define INCLUDED_SVGIO_SVGREADER_SVGIMAGENODE_HXX
+
+#include <svgio/svgiodllapi.h>
+#include <svgio/svgreader/svgnode.hxx>
+#include <svgio/svgreader/svgstyleattributes.hxx>
+
+//////////////////////////////////////////////////////////////////////////////
+
+namespace svgio
+{
+    namespace svgreader
+    {
+        class SvgImageNode : public SvgNode
+        {
+        private:
+            /// use styles
+            SvgStyleAttributes      maSvgStyleAttributes;
+
+            /// variable scan values, dependent of given XAttributeList
+            SvgAspectRatio          maSvgAspectRatio;
+            basegfx::B2DHomMatrix*  mpaTransform;
+            SvgNumber               maX;
+            SvgNumber               maY;
+            SvgNumber               maWidth;
+            SvgNumber               maHeight;
+            rtl::OUString           maXLink;
+
+        public:
+            SvgImageNode(
+                SvgDocument& rDocument,
+                SvgNode* pParent);
+            virtual ~SvgImageNode();
+
+            virtual const SvgStyleAttributes* getSvgStyleAttributes() const;
+            virtual void parseAttribute(const rtl::OUString& rTokenName, SVGToken aSVGToken, const rtl::OUString& aContent);
+            virtual void decomposeSvgNode(drawinglayer::primitive2d::Primitive2DVector& rTarget, bool bReferenced) const;
+
+            /// SvgAspectRatio content
+            const SvgAspectRatio& getSvgAspectRatio() const { return maSvgAspectRatio; }
+            void setSvgAspectRatio(const SvgAspectRatio& rSvgAspectRatio = SvgAspectRatio()) { maSvgAspectRatio = rSvgAspectRatio; }
+
+            /// transform content, set if found in current context
+            const basegfx::B2DHomMatrix* getTransform() const { return mpaTransform; }
+            void setTransform(const basegfx::B2DHomMatrix* pMatrix = 0) { if(mpaTransform) delete mpaTransform; mpaTransform = 0; if(pMatrix) mpaTransform = new basegfx::B2DHomMatrix(*pMatrix); }
+
+            /// x content, set if found in current context
+            const SvgNumber& getX() const { return maX; }
+            void setX(const SvgNumber& rX = SvgNumber()) { maX = rX; }
+
+            /// y content, set if found in current context
+            const SvgNumber& getY() const { return maY; }
+            void setY(const SvgNumber& rY = SvgNumber()) { maY = rY; }
+
+            /// width content, set if found in current context
+            const SvgNumber& getWidth() const { return maWidth; }
+            void setWidth(const SvgNumber& rWidth = SvgNumber()) { maWidth = rWidth; }
+
+            /// height content, set if found in current context
+            const SvgNumber& getHeight() const { return maHeight; }
+            void setHeight(const SvgNumber& rHeight = SvgNumber()) { maHeight = rHeight; }
+            
+            /// XLink access
+            const rtl::OUString& getXLink() const { return maXLink; }
+        };
+    } // end of namespace svgreader
+} // end of namespace svgio
+
+//////////////////////////////////////////////////////////////////////////////
+
+#endif //INCLUDED_SVGIO_SVGREADER_SVGIMAGENODE_HXX
+
+// eof

Added: incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svglinenode.hxx
URL: http://svn.apache.org/viewvc/incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svglinenode.hxx?rev=1209140&view=auto
==============================================================================
--- incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svglinenode.hxx (added)
+++ incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svglinenode.hxx Thu Dec  1 16:25:17 2011
@@ -0,0 +1,85 @@
+/**************************************************************
+ * 
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ * 
+ *************************************************************/
+
+#ifndef INCLUDED_SVGIO_SVGREADER_SVGLINENODE_HXX
+#define INCLUDED_SVGIO_SVGREADER_SVGLINENODE_HXX
+
+#include <svgio/svgiodllapi.h>
+#include <svgio/svgreader/svgnode.hxx>
+#include <svgio/svgreader/svgstyleattributes.hxx>
+
+//////////////////////////////////////////////////////////////////////////////
+
+namespace svgio
+{
+    namespace svgreader
+    {
+        class SvgLineNode : public SvgNode
+        {
+        private:
+            /// use styles
+            SvgStyleAttributes          maSvgStyleAttributes;
+
+            /// variable scan values, dependent of given XAttributeList
+            SvgNumber               maX1;
+            SvgNumber               maY1;
+            SvgNumber               maX2;
+            SvgNumber               maY2;
+            basegfx::B2DHomMatrix*  mpaTransform;
+
+        public:
+            SvgLineNode(
+                SvgDocument& rDocument,
+                SvgNode* pParent);
+            virtual ~SvgLineNode();
+
+            virtual const SvgStyleAttributes* getSvgStyleAttributes() const;
+            virtual void parseAttribute(const rtl::OUString& rTokenName, SVGToken aSVGToken, const rtl::OUString& aContent);
+            virtual void decomposeSvgNode(drawinglayer::primitive2d::Primitive2DVector& rTarget, bool bReferenced) const;
+
+            /// X1 content, set if found in current context
+            const SvgNumber& getX1() const { return maX1; }
+            void setX1(const SvgNumber& rX1 = SvgNumber()) { maX1 = rX1; }
+
+            /// Y1 content, set if found in current context
+            const SvgNumber& getY1() const { return maY1; }
+            void setY1(const SvgNumber& rY1 = SvgNumber()) { maY1 = rY1; }
+
+            /// X2 content, set if found in current context
+            const SvgNumber& getX2() const { return maX2; }
+            void setX2(const SvgNumber& rX2 = SvgNumber()) { maX2 = rX2; }
+
+            /// Y2 content, set if found in current context
+            const SvgNumber& getY2() const { return maY2; }
+            void setY2(const SvgNumber& rY2 = SvgNumber()) { maY2 = rY2; }
+
+            /// transform content, set if found in current context
+            const basegfx::B2DHomMatrix* getTransform() const { return mpaTransform; }
+            void setTransform(const basegfx::B2DHomMatrix* pMatrix = 0) { if(mpaTransform) delete mpaTransform; mpaTransform = 0; if(pMatrix) mpaTransform = new basegfx::B2DHomMatrix(*pMatrix); }
+        };
+    } // end of namespace svgreader
+} // end of namespace svgio
+
+//////////////////////////////////////////////////////////////////////////////
+
+#endif //INCLUDED_SVGIO_SVGREADER_SVGLINENODE_HXX
+
+// eof

Added: incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgnode.hxx
URL: http://svn.apache.org/viewvc/incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgnode.hxx?rev=1209140&view=auto
==============================================================================
--- incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgnode.hxx (added)
+++ incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgnode.hxx Thu Dec  1 16:25:17 2011
@@ -0,0 +1,127 @@
+/**************************************************************
+ * 
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ * 
+ *************************************************************/
+
+#ifndef INCLUDED_SVGIO_SVGREADER_SVGNODE_HXX
+#define INCLUDED_SVGIO_SVGREADER_SVGNODE_HXX
+
+#include <svgio/svgiodllapi.h>
+#include <svgio/svgreader/svgtools.hxx>
+#include <svgio/svgreader/svgtoken.hxx>
+#include <svgio/svgreader/svgpaint.hxx>
+#include <basegfx/matrix/b2dhommatrix.hxx>
+#include <com/sun/star/xml/sax/XAttributeList.hpp>
+#include <vector>
+#include <hash_map>
+
+//////////////////////////////////////////////////////////////////////////////
+// predefines
+namespace svgio 
+{ 
+    namespace svgreader 
+    { 
+        class SvgNode; 
+        class SvgDocument; 
+        class SvgStyleAttributes;
+    }
+}
+
+//////////////////////////////////////////////////////////////////////////////
+
+namespace svgio
+{
+    namespace svgreader
+    {
+        typedef ::std::vector< SvgNode* > SvgNodeVector;
+
+        enum XmlSpace
+        {
+            XmlSpace_notset,
+            XmlSpace_default,
+            XmlSpace_preserve
+        };
+
+        class SvgNode : private boost::noncopyable, public InfoProvider
+        {
+        private:
+            /// basic data, Type, document we belong to and parent (if not root)
+            SVGToken                    maType;
+            SvgDocument&                mrDocument;
+            const SvgNode*              mpParent;
+            const SvgNode*              mpAlternativeParent;
+
+            /// sub hierarchy
+            SvgNodeVector               maChildren;
+
+            /// Id svan value
+            rtl::OUString*              mpId;
+
+            /// Class svan value
+            rtl::OUString*              mpClass;
+
+            /// XmlSpace value
+            XmlSpace                    maXmlSpace;
+
+        public:
+            SvgNode(
+                SVGToken aType,
+                SvgDocument& rDocument,
+                SvgNode* pParent);
+            virtual ~SvgNode();
+
+            void parseAttributes(const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList >& xAttribs);
+            virtual const SvgStyleAttributes* getSvgStyleAttributes() const;
+            virtual void parseAttribute(const rtl::OUString& rTokenName, SVGToken aSVGToken, const rtl::OUString& aContent);
+            virtual void decomposeSvgNode(drawinglayer::primitive2d::Primitive2DVector& rTarget, bool bReferenced) const;
+
+            /// basic data read access
+            const SVGToken getType() const { return maType; }
+            const SvgDocument& getDocument() const { return mrDocument; }
+            const SvgNode* getParent() const { if(mpAlternativeParent) return mpAlternativeParent; return mpParent; }
+            const SvgNodeVector& getChildren() const { return maChildren; }
+
+            /// InfoProvider support for %, em and ex values
+            virtual const basegfx::B2DRange* getCurrentViewPort() const;
+            virtual double getCurrentFontSize() const;
+            virtual double getCurrentXHeight() const;
+
+            /// Id access
+            const rtl::OUString* getId() const { return mpId; }
+            void setId(const rtl::OUString* pfId = 0);
+
+            /// Class access
+            const rtl::OUString* getClass() const { return mpClass; }
+            void setClass(const rtl::OUString* pfClass = 0);
+
+            /// XmlSpace access
+            XmlSpace getXmlSpace() const;
+            void setXmlSpace(XmlSpace eXmlSpace = XmlSpace_notset) { maXmlSpace = eXmlSpace; }
+
+            /// alternative parent
+            void setAlternativeParent(const SvgNode* pAlternativeParent = 0) { mpAlternativeParent = pAlternativeParent; }
+        };
+    } // end of namespace svgreader
+} // end of namespace svgio
+
+//////////////////////////////////////////////////////////////////////////////
+
+#endif //INCLUDED_SVGIO_SVGREADER_SVGNODE_HXX
+
+// eof

Added: incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgpaint.hxx
URL: http://svn.apache.org/viewvc/incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgpaint.hxx?rev=1209140&view=auto
==============================================================================
--- incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgpaint.hxx (added)
+++ incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgpaint.hxx Thu Dec  1 16:25:17 2011
@@ -0,0 +1,62 @@
+/**************************************************************
+ * 
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ * 
+ *************************************************************/
+
+#ifndef INCLUDED_SVGIO_SVGREADER_SVGPAINT_HXX
+#define INCLUDED_SVGIO_SVGREADER_SVGPAINT_HXX
+
+#include <svgio/svgiodllapi.h>
+#include <basegfx/color/bcolor.hxx>
+
+//////////////////////////////////////////////////////////////////////////////
+
+namespace svgio
+{
+    namespace svgreader
+    {
+        class SvgPaint
+        {
+        private:
+            basegfx::BColor     maColor;
+
+            /// bitfield
+            bool                mbSet : 1;
+            bool                mbOn : 1;
+
+        public:
+            SvgPaint(const basegfx::BColor& rColor = basegfx::BColor(0.0, 0.0, 0.0), bool bSet = false, bool bOn = false)
+            :   maColor(rColor),
+                mbSet(bSet),
+                mbOn(bOn)
+            {
+            }
+
+            const basegfx::BColor& getBColor() const { return maColor; }
+            bool isSet() const { return mbSet; }
+            bool isOn() const { return mbOn; }
+        };
+    } // end of namespace svgreader
+} // end of namespace svgio
+
+//////////////////////////////////////////////////////////////////////////////
+
+#endif //INCLUDED_SVGIO_SVGREADER_SVGPAINT_HXX
+
+// eof

Added: incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgpathnode.hxx
URL: http://svn.apache.org/viewvc/incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgpathnode.hxx?rev=1209140&view=auto
==============================================================================
--- incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgpathnode.hxx (added)
+++ incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgpathnode.hxx Thu Dec  1 16:25:17 2011
@@ -0,0 +1,75 @@
+/**************************************************************
+ * 
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ * 
+ *************************************************************/
+
+#ifndef INCLUDED_SVGIO_SVGREADER_SVGPATHNODE_HXX
+#define INCLUDED_SVGIO_SVGREADER_SVGPATHNODE_HXX
+
+#include <svgio/svgiodllapi.h>
+#include <svgio/svgreader/svgnode.hxx>
+#include <svgio/svgreader/svgstyleattributes.hxx>
+
+//////////////////////////////////////////////////////////////////////////////
+
+namespace svgio
+{
+    namespace svgreader
+    {
+        class SvgPathNode : public SvgNode
+        {
+        private:
+            /// use styles
+            SvgStyleAttributes          maSvgStyleAttributes;
+
+            /// variable scan values, dependent of given XAttributeList
+            basegfx::B2DPolyPolygon*    mpPolyPolygon;
+            basegfx::B2DHomMatrix*      mpaTransform;
+            SvgNumber                   maPathLength;
+
+        public:
+            SvgPathNode(
+                SvgDocument& rDocument,
+                SvgNode* pParent);
+            virtual ~SvgPathNode();
+
+            virtual const SvgStyleAttributes* getSvgStyleAttributes() const;
+            virtual void parseAttribute(const rtl::OUString& rTokenName, SVGToken aSVGToken, const rtl::OUString& aContent);
+            virtual void decomposeSvgNode(drawinglayer::primitive2d::Primitive2DVector& rTarget, bool bReferenced) const;
+
+            /// path content, set if found in current context
+            const basegfx::B2DPolyPolygon* getPath() const { return mpPolyPolygon; }
+            void setPath(const basegfx::B2DPolyPolygon* pPath = 0) { if(mpPolyPolygon) delete mpPolyPolygon; mpPolyPolygon = 0; if(pPath) mpPolyPolygon = new basegfx::B2DPolyPolygon(*pPath); }
+
+            /// transform content, set if found in current context
+            const basegfx::B2DHomMatrix* getTransform() const { return mpaTransform; }
+            void setTransform(const basegfx::B2DHomMatrix* pMatrix = 0) { if(mpaTransform) delete mpaTransform; mpaTransform = 0; if(pMatrix) mpaTransform = new basegfx::B2DHomMatrix(*pMatrix); }
+
+            /// PathLength content
+            const SvgNumber& getPathLength() const { return maPathLength; }
+            void setPathLength(const SvgNumber& rPathLength = SvgNumber()) { maPathLength = rPathLength; }
+        };
+    } // end of namespace svgreader
+} // end of namespace svgio
+
+//////////////////////////////////////////////////////////////////////////////
+
+#endif //INCLUDED_SVGIO_SVGREADER_SVGPATHNODE_HXX
+
+// eof

Added: incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgpolynode.hxx
URL: http://svn.apache.org/viewvc/incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgpolynode.hxx?rev=1209140&view=auto
==============================================================================
--- incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgpolynode.hxx (added)
+++ incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgpolynode.hxx Thu Dec  1 16:25:17 2011
@@ -0,0 +1,78 @@
+/**************************************************************
+ * 
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ * 
+ *************************************************************/
+
+#ifndef INCLUDED_SVGIO_SVGREADER_SVGPOLYNODE_HXX
+#define INCLUDED_SVGIO_SVGREADER_SVGPOLYNODE_HXX
+
+#include <svgio/svgiodllapi.h>
+#include <svgio/svgreader/svgnode.hxx>
+#include <svgio/svgreader/svgstyleattributes.hxx>
+#include <basegfx/polygon/b2dpolygon.hxx>
+
+//////////////////////////////////////////////////////////////////////////////
+
+namespace svgio
+{
+    namespace svgreader
+    {
+        class SvgPolyNode : public SvgNode
+        {
+        private:
+            /// use styles
+            SvgStyleAttributes          maSvgStyleAttributes;
+
+            /// variable scan values, dependent of given XAttributeList
+            basegfx::B2DPolygon*        mpPolygon;
+            basegfx::B2DHomMatrix*      mpaTransform;
+
+            /// bitfield
+            bool                        mbIsPolyline : 1; // true = polyline, false = polygon
+
+        public:
+            SvgPolyNode(
+                SvgDocument& rDocument,
+                SvgNode* pParent,
+                bool bIsPolyline);
+            virtual ~SvgPolyNode();
+
+            virtual const SvgStyleAttributes* getSvgStyleAttributes() const;
+            virtual void parseAttribute(const rtl::OUString& rTokenName, SVGToken aSVGToken, const rtl::OUString& aContent);
+            virtual void decomposeSvgNode(drawinglayer::primitive2d::Primitive2DVector& rTarget, bool bReferenced) const;
+
+            /// type read access
+            bool isPolyline() const { return mbIsPolyline; }
+
+            /// Polygon content, set if found in current context
+            const basegfx::B2DPolygon* getPolygon() const { return mpPolygon; }
+            void setPolygon(const basegfx::B2DPolygon* pPolygon = 0) { if(mpPolygon) delete mpPolygon; mpPolygon = 0; if(pPolygon) mpPolygon = new basegfx::B2DPolygon(*pPolygon); }
+
+            /// transform content, set if found in current context
+            const basegfx::B2DHomMatrix* getTransform() const { return mpaTransform; }
+            void setTransform(const basegfx::B2DHomMatrix* pMatrix = 0) { if(mpaTransform) delete mpaTransform; mpaTransform = 0; if(pMatrix) mpaTransform = new basegfx::B2DHomMatrix(*pMatrix); }
+        };
+    } // end of namespace svgreader
+} // end of namespace svgio
+
+//////////////////////////////////////////////////////////////////////////////
+
+#endif //INCLUDED_SVGIO_SVGREADER_SVGPOLYNODE_HXX
+
+// eof

Added: incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgrectnode.hxx
URL: http://svn.apache.org/viewvc/incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgrectnode.hxx?rev=1209140&view=auto
==============================================================================
--- incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgrectnode.hxx (added)
+++ incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgrectnode.hxx Thu Dec  1 16:25:17 2011
@@ -0,0 +1,95 @@
+/**************************************************************
+ * 
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ * 
+ *************************************************************/
+
+#ifndef INCLUDED_SVGIO_SVGREADER_SVGRECTNODE_HXX
+#define INCLUDED_SVGIO_SVGREADER_SVGRECTNODE_HXX
+
+#include <svgio/svgiodllapi.h>
+#include <svgio/svgreader/svgnode.hxx>
+#include <svgio/svgreader/svgstyleattributes.hxx>
+
+//////////////////////////////////////////////////////////////////////////////
+
+namespace svgio
+{
+    namespace svgreader
+    {
+        class SvgRectNode : public SvgNode
+        {
+        private:
+            /// use styles
+            SvgStyleAttributes          maSvgStyleAttributes;
+
+            /// variable scan values, dependent of given XAttributeList
+            SvgNumber               maX;
+            SvgNumber               maY;
+            SvgNumber               maWidth;
+            SvgNumber               maHeight;
+            SvgNumber               maRx;
+            SvgNumber               maRy;
+            basegfx::B2DHomMatrix*  mpaTransform;
+
+        public:
+            SvgRectNode(
+                SvgDocument& rDocument,
+                SvgNode* pParent);
+            virtual ~SvgRectNode();
+
+            virtual const SvgStyleAttributes* getSvgStyleAttributes() const;
+            virtual void parseAttribute(const rtl::OUString& rTokenName, SVGToken aSVGToken, const rtl::OUString& aContent);
+            virtual void decomposeSvgNode(drawinglayer::primitive2d::Primitive2DVector& rTarget, bool bReferenced) const;
+
+            /// x content, set if found in current context
+            const SvgNumber& getX() const { return maX; }
+            void setX(const SvgNumber& rX = SvgNumber()) { maX = rX; }
+
+            /// y content, set if found in current context
+            const SvgNumber& getY() const { return maY; }
+            void setY(const SvgNumber& rY = SvgNumber()) { maY = rY; }
+
+            /// width content, set if found in current context
+            const SvgNumber& getWidth() const { return maWidth; }
+            void setWidth(const SvgNumber& rWidth = SvgNumber()) { maWidth = rWidth; }
+
+            /// height content, set if found in current context
+            const SvgNumber& getHeight() const { return maHeight; }
+            void setHeight(const SvgNumber& rHeight = SvgNumber()) { maHeight = rHeight; }
+
+            /// Rx content, set if found in current context
+            const SvgNumber& getRx() const { return maRx; }
+            void setRx(const SvgNumber& rRx = SvgNumber()) { maRx = rRx; }
+
+            /// Ry content, set if found in current context
+            const SvgNumber& getRy() const { return maRy; }
+            void setRy(const SvgNumber& rRy = SvgNumber()) { maRy = rRy; }
+
+            /// transform content, set if found in current context
+            const basegfx::B2DHomMatrix* getTransform() const { return mpaTransform; }
+            void setTransform(const basegfx::B2DHomMatrix* pMatrix = 0) { if(mpaTransform) delete mpaTransform; mpaTransform = 0; if(pMatrix) mpaTransform = new basegfx::B2DHomMatrix(*pMatrix); }
+        };
+    } // end of namespace svgreader
+} // end of namespace svgio
+
+//////////////////////////////////////////////////////////////////////////////
+
+#endif //INCLUDED_SVGIO_SVGREADER_SVGRECTNODE_HXX
+
+// eof

Added: incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgstyleattributes.hxx
URL: http://svn.apache.org/viewvc/incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgstyleattributes.hxx?rev=1209140&view=auto
==============================================================================
--- incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgstyleattributes.hxx (added)
+++ incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgstyleattributes.hxx Thu Dec  1 16:25:17 2011
@@ -0,0 +1,315 @@
+/**************************************************************
+ * 
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ * 
+ *************************************************************/
+
+#ifndef INCLUDED_SVGIO_SVGREADER_SVGSTYLEATTRIBUTES_HXX
+#define INCLUDED_SVGIO_SVGREADER_SVGSTYLEATTRIBUTES_HXX
+
+#include <svgio/svgiodllapi.h>
+#include <svgio/svgreader/svgpaint.hxx>
+#include <svgio/svgreader/svgnode.hxx>
+#include <vcl/vclenum.hxx>
+
+//////////////////////////////////////////////////////////////////////////////
+// predefines
+
+namespace svgio { namespace svgreader { class SvgGradientNode; }}
+
+//////////////////////////////////////////////////////////////////////////////
+
+namespace svgio
+{
+    namespace svgreader
+    {
+        enum StrokeLinecap
+        {
+            StrokeLinecap_notset,
+            StrokeLinecap_butt,
+            StrokeLinecap_round,
+            StrokeLinecap_square
+        };
+
+        enum StrokeLinejoin
+        {
+            StrokeLinejoin_notset,
+            StrokeLinejoin_miter,
+            StrokeLinejoin_round,
+            StrokeLinejoin_bevel
+        };
+
+        enum FontStretch
+        {
+            FontStretch_notset,
+            FontStretch_normal,
+            FontStretch_wider,
+            FontStretch_narrower,
+            FontStretch_ultra_condensed,
+            FontStretch_extra_condensed,
+            FontStretch_condensed,
+            FontStretch_semi_condensed,
+            FontStretch_semi_expanded,
+            FontStretch_expanded,
+            FontStretch_extra_expanded,
+            FontStretch_ultra_expanded
+        };
+
+        FontStretch getWider(FontStretch aSource);
+        FontStretch getNarrower(FontStretch aSource);
+
+        enum FontStyle
+        {
+            FontStyle_notset,
+            FontStyle_normal,
+            FontStyle_italic,
+            FontStyle_oblique
+        };
+
+        enum FontVariant
+        {
+            FontVariant_notset,
+            FontVariant_normal,
+            FontVariant_small_caps
+        };
+
+        enum FontWeight
+        {
+            FontWeight_notset,
+            FontWeight_100,
+            FontWeight_200,
+            FontWeight_300,
+            FontWeight_400, // same as FontWeight_normal
+            FontWeight_500,
+            FontWeight_600,
+            FontWeight_700, // same as FontWeight_bold
+            FontWeight_800,
+            FontWeight_900,
+            FontWeight_bolder,
+            FontWeight_lighter,
+        };
+
+        FontWeight getBolder(FontWeight aSource);
+        FontWeight getLighter(FontWeight aSource);
+        ::FontWeight getVclFontWeight(FontWeight aSource);
+
+        enum TextAlign
+        {
+            TextAlign_notset,
+            TextAlign_left,
+            TextAlign_right,
+            TextAlign_center,
+            TextAlign_justify
+        };
+
+        enum TextDecoration
+        {
+            TextDecoration_notset,
+            TextDecoration_none,
+            TextDecoration_underline,
+            TextDecoration_overline,
+            TextDecoration_line_through,
+            TextDecoration_blink
+        };
+
+        enum TextAnchor
+        {
+            TextAnchor_notset,
+            TextAnchor_start,
+            TextAnchor_middle,
+            TextAnchor_end
+        };
+
+        class SvgStyleAttributes
+        {
+        private:
+            SvgNode&                    mrOwner;
+            const SvgStyleAttributes*   mpCssStyleParent;
+
+            SvgPaint                    maFill;
+            SvgPaint                    maStroke;
+            SvgPaint                    maStopColor;
+            SvgNumber                   maStrokeWidth;
+            SvgNumber                   maStopOpacity;
+            const SvgGradientNode*      mpSvgGradientNodeFill;
+            const SvgGradientNode*      mpSvgGradientNodeStroke;
+            SvgNumber                   maFillOpacity;
+            SvgNumberVector             maStrokeDasharray;
+            SvgNumber                   maStrokeDashOffset;
+            StrokeLinecap               maStrokeLinecap;
+            StrokeLinejoin              maStrokeLinejoin;
+            SvgNumber                   maStrokeMiterLimit;
+            SvgNumber                   maStrokeOpacity;
+            SvgStringVector             maFontFamily;
+            SvgNumber                   maFontSize;
+            FontStretch                 maFontStretch;
+            FontStyle                   maFontStyle;
+            FontVariant                 maFontVariant;
+            FontWeight                  maFontWeight;
+            TextAlign                   maTextAlign;
+            TextDecoration              maTextDecoration;
+            TextAnchor                  maTextAnchor;
+
+            /// bitfield
+            bool                        maFillRule : 1; // true: NonZero, false: EvenOdd
+            bool                        maFillRuleSet : 1;
+
+            /// internal helpers
+            void add_fillGradient(
+                const basegfx::B2DPolyPolygon& rPath, 
+                drawinglayer::primitive2d::Primitive2DVector& rTarget, 
+                const SvgGradientNode& rFillGradient,
+                const basegfx::B2DRange& rGeoRange) const;
+            void add_fill(
+                const basegfx::B2DPolyPolygon& rPath, 
+                drawinglayer::primitive2d::Primitive2DVector& rTarget,
+                const basegfx::B2DRange& rGeoRange) const;
+            void add_stroke(
+                const basegfx::B2DPolyPolygon& rPath, 
+                drawinglayer::primitive2d::Primitive2DVector& rTarget,
+                const basegfx::B2DRange& rGeoRange) const;
+
+        public:
+            /// local attribute scanner
+            void parseStyleAttribute(const rtl::OUString& rTokenName, SVGToken aSVGToken, const rtl::OUString& aContent);
+
+            /// helper which does the necessary with a given path
+            void add_text(
+                drawinglayer::primitive2d::Primitive2DVector& rTarget, 
+                drawinglayer::primitive2d::Primitive2DVector& rSource) const;
+            void add_path(
+                const basegfx::B2DPolyPolygon& rPath, 
+                drawinglayer::primitive2d::Primitive2DVector& rTarget, 
+                const basegfx::B2DHomMatrix* pTransform) const;
+
+            /// helper to evtl. link to css style
+            void checkForCssStyle(const rtl::OUString& rClassStr) const;
+
+            /// scan helpers
+            void readStyle(const rtl::OUString& rCandidate);
+            const SvgStyleAttributes* getParentStyle() const;
+
+            SvgStyleAttributes(SvgNode& rOwner);
+            ~SvgStyleAttributes();
+
+            /// fill content
+            const basegfx::BColor* getFill() const;
+            void setFill(const SvgPaint& rFill) { maFill = rFill; }
+
+            /// stroke content
+            const basegfx::BColor* getStroke() const;
+            void setStroke(const SvgPaint& rStroke) { maStroke = rStroke; }
+
+            /// stop color content
+            const basegfx::BColor& getStopColor() const { return maStopColor.getBColor(); }
+            void setStopColor(const SvgPaint& rStopColor) { maStopColor = rStopColor; }
+
+            /// stroke-width content
+            const SvgNumber getStrokeWidth() const;
+            void setStrokeWidth(const SvgNumber& rStrokeWidth = SvgNumber()) { maStrokeWidth = rStrokeWidth; }
+
+            /// stop opacity content
+            const SvgNumber getStopOpacity() const;
+            void setStopOpacity(const SvgNumber& rStopOpacity = SvgNumber()) { maStopOpacity = rStopOpacity; }
+
+            /// access to evtl. set fill gradient
+            const SvgGradientNode* getSvgGradientNodeFill() const;
+            void setSvgGradientNodeFill(const SvgGradientNode* pNew) { mpSvgGradientNodeFill = pNew; }
+
+            /// access to evtl. set stroke gradient
+            const SvgGradientNode* getSvgGradientNodeStroke() const;
+            void setSvgGradientNodeStroke(const SvgGradientNode* pNew) { mpSvgGradientNodeStroke = pNew; }
+
+            /// fill opacity content
+            const SvgNumber getFillOpacity() const;
+            void setFillOpacity(const SvgNumber& rFillOpacity = SvgNumber()) { maFillOpacity = rFillOpacity; }
+
+            /// fill rule content
+            bool getFillRule() const;
+            void setFillRule(const bool* pFillRule = 0);
+
+            /// fill StrokeDasharray content
+            const SvgNumberVector& getStrokeDasharray() const;
+            void setStrokeDasharray(const SvgNumberVector& rStrokeDasharray = SvgNumberVector()) { maStrokeDasharray = rStrokeDasharray; }
+
+            /// StrokeDashOffset content
+            const SvgNumber getStrokeDashOffset() const;
+            void setStrokeDashOffset(const SvgNumber& rStrokeDashOffset = SvgNumber()) { maStrokeDashOffset = rStrokeDashOffset; }
+
+            /// StrokeLinecap content
+            const StrokeLinecap getStrokeLinecap() const;
+            void setStrokeLinecap(const StrokeLinecap aStrokeLinecap = StrokeLinecap_notset) { maStrokeLinecap = aStrokeLinecap; }
+
+            /// StrokeLinejoin content
+            const StrokeLinejoin getStrokeLinejoin() const;
+            void setStrokeLinejoin(const StrokeLinejoin aStrokeLinejoin = StrokeLinejoin_notset) { maStrokeLinejoin = aStrokeLinejoin; }
+
+            /// StrokeMiterLimit content
+            const SvgNumber getStrokeMiterLimit() const;
+            void setStrokeMiterLimit(const SvgNumber& rStrokeMiterLimit = SvgNumber()) { maStrokeMiterLimit = rStrokeMiterLimit; }
+
+            /// StrokeOpacity content
+            const SvgNumber getStrokeOpacity() const;
+            void setStrokeOpacity(const SvgNumber& rStrokeOpacity = SvgNumber()) { maStrokeOpacity = rStrokeOpacity; }
+
+            /// Font content
+            const SvgStringVector& getFontFamily() const;
+            void setFontFamily(const SvgStringVector& rSvgStringVector = SvgStringVector()) { maFontFamily = rSvgStringVector; }
+
+            /// FontSize content
+            const SvgNumber getFontSize() const;
+            void setFontSize(const SvgNumber& rFontSize = SvgNumber()) { maFontSize = rFontSize; }
+
+            /// FontStretch content
+            const FontStretch getFontStretch() const;
+            void setFontStretch(const FontStretch aFontStretch = FontStretch_notset) { maFontStretch = aFontStretch; }
+
+            /// FontStyle content
+            const FontStyle getFontStyle() const;
+            void setFontStyle(const FontStyle aFontStyle = FontStyle_notset) { maFontStyle = aFontStyle; }
+
+            /// FontVariant content
+            const FontVariant getFontVariant() const;
+            void setFontVariant(const FontVariant aFontVariant = FontVariant_notset) { maFontVariant = aFontVariant; }
+
+            /// FontWeight content
+            const FontWeight getFontWeight() const;
+            void setFontWeight(const FontWeight aFontWeight = FontWeight_notset) { maFontWeight = aFontWeight; }
+
+            /// TextAlign content
+            const TextAlign getTextAlign() const;
+            void setTextAlign(const TextAlign aTextAlign = TextAlign_notset) { maTextAlign = aTextAlign; }
+
+            /// TextDecoration content
+            const SvgStyleAttributes* getTextDecorationDefiningSvgStyleAttributes() const;
+            const TextDecoration getTextDecoration() const;
+            void setTextDecoration(const TextDecoration aTextDecoration = TextDecoration_notset) { maTextDecoration = aTextDecoration; }
+
+            /// TextAnchor content
+            const TextAnchor getTextAnchor() const;
+            void setTextAnchor(const TextAnchor aTextAnchor = TextAnchor_notset) { maTextAnchor = aTextAnchor; }
+
+        };
+    } // end of namespace svgreader
+} // end of namespace svgio
+
+//////////////////////////////////////////////////////////////////////////////
+
+#endif //INCLUDED_SVGIO_SVGREADER_SVGSTYLEATTRIBUTES_HXX
+
+// eof

Added: incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgstylenode.hxx
URL: http://svn.apache.org/viewvc/incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgstylenode.hxx?rev=1209140&view=auto
==============================================================================
--- incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgstylenode.hxx (added)
+++ incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgstylenode.hxx Thu Dec  1 16:25:17 2011
@@ -0,0 +1,64 @@
+/**************************************************************
+ * 
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ * 
+ *************************************************************/
+
+#ifndef INCLUDED_SVGIO_SVGREADER_SVGSTYLENODE_HXX
+#define INCLUDED_SVGIO_SVGREADER_SVGSTYLENODE_HXX
+
+#include <svgio/svgiodllapi.h>
+#include <svgio/svgreader/svgnode.hxx>
+#include <svgio/svgreader/svgstyleattributes.hxx>
+
+//////////////////////////////////////////////////////////////////////////////
+
+namespace svgio
+{
+    namespace svgreader
+    {
+        class SvgStyleNode : public SvgNode
+        {
+        private:
+            /// use styles
+            std::vector< SvgStyleAttributes* >      maSvgStyleAttributes;
+
+            /// bitfield
+            bool                                    mbTextCss : 1; // true == type is 'text/css'
+
+        public:
+            SvgStyleNode(
+                SvgDocument& rDocument,
+                SvgNode* pParent);
+            virtual ~SvgStyleNode();
+
+            virtual void parseAttribute(const rtl::OUString& rTokenName, SVGToken aSVGToken, const rtl::OUString& aContent);
+            void addCssStyleSheet(const rtl::OUString& aContent);
+
+            /// textCss access
+            bool isTextCss() const { return mbTextCss; }
+            void setTextCss(bool bNew) { mbTextCss = bNew; }
+        };
+    } // end of namespace svgreader
+} // end of namespace svgio
+
+//////////////////////////////////////////////////////////////////////////////
+
+#endif //INCLUDED_SVGIO_SVGREADER_SVGSTYLENODE_HXX
+
+// eof

Added: incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgsvgnode.hxx
URL: http://svn.apache.org/viewvc/incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgsvgnode.hxx?rev=1209140&view=auto
==============================================================================
--- incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgsvgnode.hxx (added)
+++ incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgsvgnode.hxx Thu Dec  1 16:25:17 2011
@@ -0,0 +1,97 @@
+/**************************************************************
+ * 
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ * 
+ *************************************************************/
+
+#ifndef INCLUDED_SVGIO_SVGREADER_SVGSVGNODE_HXX
+#define INCLUDED_SVGIO_SVGREADER_SVGSVGNODE_HXX
+
+#include <svgio/svgiodllapi.h>
+#include <svgio/svgreader/svgstyleattributes.hxx>
+
+//////////////////////////////////////////////////////////////////////////////
+
+namespace svgio
+{
+    namespace svgreader
+    {
+        class SvgSvgNode : public SvgNode
+        {
+        private:
+            /// use styles
+            SvgStyleAttributes      maSvgStyleAttributes;
+
+            /// variable scan values, dependent of given XAttributeList
+            basegfx::B2DRange*      mpViewBox;
+            SvgAspectRatio          maSvgAspectRatio;
+            SvgNumber               maX;
+            SvgNumber               maY;
+            SvgNumber               maWidth;
+            SvgNumber               maHeight;
+            SvgNumber               maVersion;
+
+        public:
+            SvgSvgNode(
+                SvgDocument& rDocument,
+                SvgNode* pParent);
+            virtual ~SvgSvgNode();
+
+            virtual const SvgStyleAttributes* getSvgStyleAttributes() const;
+            virtual void parseAttribute(const rtl::OUString& rTokenName, SVGToken aSVGToken, const rtl::OUString& aContent);
+            virtual void decomposeSvgNode(drawinglayer::primitive2d::Primitive2DVector& rTarget, bool bReferenced) const;
+            
+            /// InfoProvider support for % values
+            virtual const basegfx::B2DRange* getCurrentViewPort() const;
+
+            /// viewBox content
+            const basegfx::B2DRange* getViewBox() const { return mpViewBox; }
+            void setViewBox(const basegfx::B2DRange* pViewBox = 0) { if(mpViewBox) delete mpViewBox; mpViewBox = 0; if(pViewBox) mpViewBox = new basegfx::B2DRange(*pViewBox); }
+
+            /// SvgAspectRatio content
+            const SvgAspectRatio& getSvgAspectRatio() const { return maSvgAspectRatio; }
+            void setSvgAspectRatio(const SvgAspectRatio& rSvgAspectRatio = SvgAspectRatio()) { maSvgAspectRatio = rSvgAspectRatio; }
+
+            /// x content
+            const SvgNumber& getX() const { return maX; }
+            void setX(const SvgNumber& rX = SvgNumber()) { maX = rX; }
+
+            /// y content
+            const SvgNumber& getY() const { return maY; }
+            void setY(const SvgNumber& rY = SvgNumber()) { maY = rY; }
+
+            /// width content
+            const SvgNumber& getWidth() const { return maWidth; }
+            void setWidth(const SvgNumber& rWidth = SvgNumber()) { maWidth = rWidth; }
+
+            /// height content
+            const SvgNumber& getHeight() const { return maHeight; }
+            void setHeight(const SvgNumber& rHeight = SvgNumber()) { maHeight = rHeight; }
+
+            /// version content
+            const SvgNumber& getVersion() const { return maVersion; }
+            void setVersion(const SvgNumber& rVersion = SvgNumber()) { maVersion = rVersion; }
+        };
+    } // end of namespace svgreader
+} // end of namespace svgio
+
+//////////////////////////////////////////////////////////////////////////////
+
+#endif //INCLUDED_SVGIO_SVGREADER_SVGSVGNODE_HXX
+
+// eof

Added: incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgsymbolnode.hxx
URL: http://svn.apache.org/viewvc/incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgsymbolnode.hxx?rev=1209140&view=auto
==============================================================================
--- incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgsymbolnode.hxx (added)
+++ incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgsymbolnode.hxx Thu Dec  1 16:25:17 2011
@@ -0,0 +1,68 @@
+/**************************************************************
+ * 
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ * 
+ *************************************************************/
+
+#ifndef INCLUDED_SVGIO_SVGREADER_SVGSYMBOLNODE_HXX
+#define INCLUDED_SVGIO_SVGREADER_SVGSYMBOLNODE_HXX
+
+#include <svgio/svgiodllapi.h>
+#include <svgio/svgreader/svgstyleattributes.hxx>
+
+//////////////////////////////////////////////////////////////////////////////
+
+namespace svgio
+{
+    namespace svgreader
+    {
+        class SvgSymbolNode : public SvgNode
+        {
+        private:
+            /// use styles
+            SvgStyleAttributes      maSvgStyleAttributes;
+
+            /// variable scan values, dependent of given XAttributeList
+            basegfx::B2DRange*      mpViewBox;
+            SvgAspectRatio          maSvgAspectRatio;
+
+        public:
+            SvgSymbolNode(
+                SvgDocument& rDocument,
+                SvgNode* pParent);
+            virtual ~SvgSymbolNode();
+
+            virtual const SvgStyleAttributes* getSvgStyleAttributes() const;
+            virtual void parseAttribute(const rtl::OUString& rTokenName, SVGToken aSVGToken, const rtl::OUString& aContent);
+
+            /// viewBox content
+            const basegfx::B2DRange* getViewBox() const { return mpViewBox; }
+            void setViewBox(const basegfx::B2DRange* pViewBox = 0) { if(mpViewBox) delete mpViewBox; mpViewBox = 0; if(pViewBox) mpViewBox = new basegfx::B2DRange(*pViewBox); }
+
+            /// SvgAspectRatio content
+            const SvgAspectRatio& getSvgAspectRatio() const { return maSvgAspectRatio; }
+            void setSvgAspectRatio(const SvgAspectRatio& rSvgAspectRatio = SvgAspectRatio()) { maSvgAspectRatio = rSvgAspectRatio; }
+        };
+    } // end of namespace svgreader
+} // end of namespace svgio
+
+//////////////////////////////////////////////////////////////////////////////
+
+#endif //INCLUDED_SVGIO_SVGREADER_SVGSYMBOLNODE_HXX
+
+// eof

Added: incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgtextnode.hxx
URL: http://svn.apache.org/viewvc/incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgtextnode.hxx?rev=1209140&view=auto
==============================================================================
--- incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgtextnode.hxx (added)
+++ incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgtextnode.hxx Thu Dec  1 16:25:17 2011
@@ -0,0 +1,74 @@
+/**************************************************************
+ * 
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ * 
+ *************************************************************/
+
+#ifndef INCLUDED_SVGIO_SVGREADER_SVGTEXTNODE_HXX
+#define INCLUDED_SVGIO_SVGREADER_SVGTEXTNODE_HXX
+
+#include <svgio/svgiodllapi.h>
+#include <svgio/svgreader/svgnode.hxx>
+#include <svgio/svgreader/svgstyleattributes.hxx>
+#include <svgio/svgreader/svgcharacternode.hxx>
+
+//////////////////////////////////////////////////////////////////////////////
+
+namespace svgio
+{
+    namespace svgreader
+    {
+        class SvgTextNode : public SvgNode
+        {
+        private:
+            /// use styles
+            SvgStyleAttributes      maSvgStyleAttributes;
+
+            /// variable scan values, dependent of given XAttributeList
+            basegfx::B2DHomMatrix*  mpaTransform;
+            SvgTextPositions        maSvgTextPositions;
+
+            /// local helpers
+            void DecomposeChild(const SvgNode& rCandidate, drawinglayer::primitive2d::Primitive2DVector& rTarget, SvgTextPosition& rSvgTextPosition) const;
+            void addTextPrimitives(const SvgNode& rCandidate, drawinglayer::primitive2d::Primitive2DVector& rTarget, drawinglayer::primitive2d::Primitive2DVector& rSource) const;
+
+        public:
+            SvgTextNode(
+                SvgDocument& rDocument,
+                SvgNode* pParent);
+            virtual ~SvgTextNode();
+
+            virtual const SvgStyleAttributes* getSvgStyleAttributes() const;
+            virtual void parseAttribute(const rtl::OUString& rTokenName, SVGToken aSVGToken, const rtl::OUString& aContent);
+            virtual void decomposeSvgNode(drawinglayer::primitive2d::Primitive2DVector& rTarget, bool bReferenced) const;
+
+            /// transform content, set if found in current context
+            const basegfx::B2DHomMatrix* getTransform() const { return mpaTransform; }
+            void setTransform(const basegfx::B2DHomMatrix* pMatrix = 0) { if(mpaTransform) delete mpaTransform; mpaTransform = 0; if(pMatrix) mpaTransform = new basegfx::B2DHomMatrix(*pMatrix); }
+
+            /// access to SvgTextPositions
+            const SvgTextPositions& getSvgTextPositions() const { return maSvgTextPositions; }
+        };
+    } // end of namespace svgreader
+} // end of namespace svgio
+
+//////////////////////////////////////////////////////////////////////////////
+
+#endif //INCLUDED_SVGIO_SVGREADER_SVGTEXTNODE_HXX
+
+// eof

Added: incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgtextpathnode.hxx
URL: http://svn.apache.org/viewvc/incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgtextpathnode.hxx?rev=1209140&view=auto
==============================================================================
--- incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgtextpathnode.hxx (added)
+++ incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgtextpathnode.hxx Thu Dec  1 16:25:17 2011
@@ -0,0 +1,93 @@
+/**************************************************************
+ * 
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ * 
+ *************************************************************/
+
+#ifndef INCLUDED_SVGIO_SVGREADER_SVGTEXTPATHNODE_HXX
+#define INCLUDED_SVGIO_SVGREADER_SVGTEXTPATHNODE_HXX
+
+#include <svgio/svgiodllapi.h>
+#include <svgio/svgreader/svgnode.hxx>
+#include <svgio/svgreader/svgstyleattributes.hxx>
+#include <svgio/svgreader/svgpathnode.hxx>
+
+//////////////////////////////////////////////////////////////////////////////
+
+namespace svgio
+{
+    namespace svgreader
+    {
+        class SvgTextPathNode : public SvgNode
+        {
+        private:
+            /// use styles
+            SvgStyleAttributes      maSvgStyleAttributes;
+
+            /// link to path content. If maXLink
+            /// is set, the node can be fetched on demand
+            rtl::OUString           maXLink;
+            const SvgPathNode*      mpXLink;
+
+            /// variable scan values, dependent of given XAttributeList
+            SvgNumber               maStartOffset;
+
+            /// bitfield
+            bool                    mbMethod : 1; // true = align, false = stretch
+            bool                    mbSpacing : 1; // true = auto, false = exact
+
+            /// link on demand
+            void tryToFindLink();
+
+        public:
+            SvgTextPathNode(
+                SvgDocument& rDocument,
+                SvgNode* pParent);
+            virtual ~SvgTextPathNode();
+
+            virtual const SvgStyleAttributes* getSvgStyleAttributes() const;
+            virtual void parseAttribute(const rtl::OUString& rTokenName, SVGToken aSVGToken, const rtl::OUString& aContent);
+            void decomposePathNode(
+                const drawinglayer::primitive2d::Primitive2DSequence& rPathContent, 
+                drawinglayer::primitive2d::Primitive2DVector& rTarget, 
+                const basegfx::B2DPoint& rTextStart) const;
+            bool isValid() const;
+
+            /// StartOffset content
+            const SvgNumber& getStartOffset() const { return maStartOffset; }
+            void setStartOffset(const SvgNumber& rStartOffset = SvgNumber()) { maStartOffset = rStartOffset; }
+
+            /// Method content
+            bool getMethod() const { return mbMethod; }
+            void setMethod(bool bNew) { mbMethod = bNew; }
+
+            /// Spacing content
+            bool getSpacing() const { return mbSpacing; }
+            void setSpacing(bool bNew) { mbSpacing = bNew; }
+
+            /// access to referenced SvgPathNode
+            const SvgPathNode* getReferencedSvgPathNode() const;
+        };
+    } // end of namespace svgreader
+} // end of namespace svgio
+
+//////////////////////////////////////////////////////////////////////////////
+
+#endif //INCLUDED_SVGIO_SVGREADER_SVGTEXTPATHNODE_HXX
+
+// eof

Added: incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgtoken.hxx
URL: http://svn.apache.org/viewvc/incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgtoken.hxx?rev=1209140&view=auto
==============================================================================
--- incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgtoken.hxx (added)
+++ incubator/ooo/branches/alg/svgreplacement/main/svgio/inc/svgio/svgreader/svgtoken.hxx Thu Dec  1 16:25:17 2011
@@ -0,0 +1,171 @@
+/**************************************************************
+ * 
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ * 
+ *************************************************************/
+
+#ifndef INCLUDED_SVGIO_SVGREADER_SVGTOKEN_HXX
+#define INCLUDED_SVGIO_SVGREADER_SVGTOKEN_HXX
+
+#include <svgio/svgiodllapi.h>
+#include <rtl/ustring.hxx>
+#include <hash_map>
+
+//////////////////////////////////////////////////////////////////////////////
+
+namespace svgio
+{
+    namespace svgreader
+    {
+        // SVG token mapper with hashing
+        enum SVGToken
+        {
+            SVGTokenUnknown = 0,
+
+            // diverse attribute tokens
+            SVGTokenWidth,
+            SVGTokenHeight,
+            SVGTokenViewBox,
+            SVGTokenTransform,
+            SVGTokenStyle,
+            SVGTokenD,
+            SVGTokenX,
+            SVGTokenY,
+            SVGTokenXmlns,
+            SVGTokenVersion,
+            SVGTokenId,
+            SVGTokenRx,
+            SVGTokenRy,
+            SVGTokenPoints,
+            SVGTokenDx,
+            SVGTokenDy,
+            SVGTokenRotate,
+            SVGTokenTextLength,
+            SVGTokenLengthAdjust,
+            SVGTokenFont,
+            SVGTokenFontFamily,
+            SVGTokenFontSize,
+            SVGTokenFontSizeAdjust,
+            SVGTokenFontStretch,
+            SVGTokenFontStyle,
+            SVGTokenFontVariant,
+            SVGTokenFontWeight,
+            SVGTokenDirection,
+            SVGTokenLetterSpacing,
+            SVGTokenTextDecoration,
+            SVGTokenUnicodeBidi,
+            SVGTokenWordSpacing,
+            SVGTokenCharacter, // not in the hash, just for simple text handling in SvgCharacterNode
+            SVGTokenTspan,
+            SVGTokenTref,
+            SVGTokenTextPath,
+            SVGTokenStartOffset,
+            SVGTokenMethod,
+            SVGTokenSpacing,
+            SVGTokenTextAlign,
+            SVGTokenPathLength,
+            SVGTokenType,
+            SVGTokenClass,
+            SVGTokenTextAnchor,
+            SVGTokenXmlSpace,
+
+            // AspectRatio and params
+            SVGTokenPreserveAspectRatio,
+            SVGTokenDefer,
+            SVGTokenNone,
+            SVGTokenXMinYMin,
+            SVGTokenXMidYMin,
+            SVGTokenXMaxYMin,
+            SVGTokenXMinYMid,
+            SVGTokenXMidYMid,
+            SVGTokenXMaxYMid,
+            SVGTokenXMinYMax,
+            SVGTokenXMidYMax,
+            SVGTokenXMaxYMax,
+            SVGTokenMeet,
+            SVGTokenSlice,
+
+            // structural elements
+            SVGTokenDefs,
+            SVGTokenG,
+            SVGTokenSvg,
+            SVGTokenSymbol,
+            SVGTokenUse,
+
+            // shape elements
+            SVGTokenCircle,
+            SVGTokenEllipse,
+            SVGTokenLine,
+            SVGTokenPath,
+            SVGTokenPolygon,
+            SVGTokenPolyline,
+            SVGTokenRect,
+            SVGTokenImage,
+
+            // gradient elements and tokens
+            SVGTokenLinearGradient,
+            SVGTokenRadialGradient,
+            SVGTokenStop,
+            SVGTokenOffset,
+            SVGTokenX1,
+            SVGTokenY1,
+            SVGTokenX2,
+            SVGTokenY2,
+            SVGTokenCx,
+            SVGTokenCy,
+            SVGTokenFx,
+            SVGTokenFy,
+            SVGTokenR,
+            SVGTokenGradientUnits,
+            SVGTokenGradientTransform,
+            SVGTokenSpreadMethod,
+            SVGTokenXlinkHref,
+            SVGTokenStopColor,
+            SVGTokenStopOpacity,
+
+            // fill tokens
+            SVGTokenFill,
+            SVGTokenFillOpacity,
+            SVGTokenFillRule,
+
+            // stroke tokens
+            SVGTokenStroke,
+            SVGTokenStrokeDasharray,
+            SVGTokenStrokeDashoffset,
+            SVGTokenStrokeLinecap,
+            SVGTokenStrokeLinejoin,
+            SVGTokenStrokeMiterlimit,
+            SVGTokenStrokeOpacity,
+            SVGTokenStrokeWidth,
+
+            // text tokens
+            SVGTokenText,
+
+            SVGTokenLast
+        };
+
+        SVGToken StrToSVGToken(const rtl::OUString& rStr);
+
+    } // end of namespace svgreader
+} // end of namespace svgio
+
+//////////////////////////////////////////////////////////////////////////////
+
+#endif //INCLUDED_SVGIO_SVGREADER_SVGTOKEN_HXX
+
+// eof



Mime
View raw message