LibreOffice Module svgio (master) 1
Public Member Functions | Private Member Functions | Private Attributes | List of all members
svgio::svgreader::SvgSvgNode Class Referencefinal

#include <svgsvgnode.hxx>

Inheritance diagram for svgio::svgreader::SvgSvgNode:
[legend]
Collaboration diagram for svgio::svgreader::SvgSvgNode:
[legend]

Public Member Functions

 SvgSvgNode (SvgDocument &rDocument, SvgNode *pParent)
 
virtual ~SvgSvgNode () override
 
virtual const SvgStyleAttributesgetSvgStyleAttributes () const override
 
virtual void parseAttribute (const OUString &rTokenName, SVGToken aSVGToken, const OUString &aContent) override
 
virtual void decomposeSvgNode (drawinglayer::primitive2d::Primitive2DContainer &rTarget, bool bReferenced) const override
 
void seekReferenceWidth (double &fWidth, bool &bHasFound) const
 Seeks width and height of viewport, which is current before the new viewport is set. More...
 
void seekReferenceHeight (double &fHeight, bool &bHasFound) const
 
virtual basegfx::B2DRange getCurrentViewPort () const override
 InfoProvider support for % values in children. More...
 
const basegfx::B2DRangegetViewBox () const
 viewBox content More...
 
void setViewBox (const basegfx::B2DRange *pViewBox)
 
const SvgAspectRatiogetSvgAspectRatio () const
 SvgAspectRatio content. More...
 
const SvgNumbergetX () const
 x content More...
 
const SvgNumbergetY () const
 y content More...
 
const SvgNumbergetWidth () const
 width content More...
 
const SvgNumbergetHeight () const
 height content More...
 
- Public Member Functions inherited from svgio::svgreader::SvgNode
 SvgNode (SVGToken aType, SvgDocument &rDocument, SvgNode *pParent)
 
virtual ~SvgNode () override
 
 SvgNode (const SvgNode &)=delete
 
SvgNodeoperator= (const SvgNode &)=delete
 
void accept (Visitor &rVisitor)
 
void readLocalCssStyle (std::u16string_view aContent)
 scan helper to read and interpret a local CssStyle to mpLocalCssStyle More...
 
void parseAttributes (const css::uno::Reference< css::xml::sax::XAttributeList > &xAttribs)
 style helpers More...
 
virtual const SvgStyleAttributesgetSvgStyleAttributes () const
 
virtual void parseAttribute (const OUString &rTokenName, SVGToken aSVGToken, const OUString &aContent)
 
virtual void decomposeSvgNode (drawinglayer::primitive2d::Primitive2DContainer &rTarget, bool bReferenced) const
 
virtual bool supportsParentStyle () const
 #i125258# tell if this node is allowed to have a parent style (e.g. defs do not) More...
 
SVGToken getType () const
 basic data read access More...
 
const SvgDocumentgetDocument () const
 
const SvgNodegetParent () const
 
const std::vector< std::unique_ptr< SvgNode > > & getChildren () const
 
virtual basegfx::B2DRange getCurrentViewPort () const override
 InfoProvider support for %, em and ex values. More...
 
virtual double getCurrentFontSizeInherited () const override
 return font size of node inherited from parents More...
 
virtual double getCurrentXHeightInherited () const override
 return xheight of node inherited from parents More...
 
double getCurrentFontSize () const
 
double getCurrentXHeight () const
 
std::optional< OUString > const & getId () const
 Id access. More...
 
void setId (OUString const &)
 
std::optional< OUString > const & getClass () const
 Class access. More...
 
void setClass (OUString const &)
 
XmlSpace getXmlSpace () const
 XmlSpace access. More...
 
void setXmlSpace (XmlSpace eXmlSpace)
 
Display getDisplay () const
 Display access #i121656#. More...
 
void setDisplay (Display eDisplay)
 
void setAlternativeParent (const SvgNode *pAlternativeParent=nullptr)
 alternative parent More...
 
bool hasLocalCssStyle ()
 Check if there is a local css style. More...
 
- Public Member Functions inherited from svgio::svgreader::InfoProvider
virtual ~InfoProvider ()
 
virtual basegfx::B2DRange getCurrentViewPort () const =0
 
virtual double getCurrentFontSizeInherited () const =0
 return font size of node inherited from parents More...
 
virtual double getCurrentXHeightInherited () const =0
 return xheight of node inherited from parents More...
 

Private Member Functions

void initializeStyleAttributes ()
 

Private Attributes

SvgStyleAttributes maSvgStyleAttributes
 use styles More...
 
std::unique_ptr< basegfx::B2DRangempViewBox
 variable scan values, dependent of given XAttributeList More...
 
SvgAspectRatio maSvgAspectRatio
 
SvgNumber maX
 
SvgNumber maY
 
SvgNumber maWidth
 
SvgNumber maHeight
 
SvgNumber maVersion
 
bool mbStyleAttributesInitialized: 1
 #i125258# bitfield More...
 

Additional Inherited Members

- Protected Member Functions inherited from svgio::svgreader::SvgNode
const SvgStyleAttributescheckForCssStyle (const SvgStyleAttributes &rOriginal) const
 helper to evtl. link to css style More...
 
void fillCssStyleVector (const SvgStyleAttributes &rOriginal)
 helper for filling the CssStyle vector once dependent on mbCssStyleVectorBuilt More...
 
void addCssStyle (const SvgDocument &rDocument, const OUString &aConcatenated)
 
void fillCssStyleVectorUsingHierarchyAndSelectors (const SvgNode &rCurrent, const OUString &aConcatenated)
 
void fillCssStyleVectorUsingParent (const SvgNode &rCurrent)
 

Detailed Description

Definition at line 27 of file svgsvgnode.hxx.

Constructor & Destructor Documentation

◆ SvgSvgNode()

svgio::svgreader::SvgSvgNode::SvgSvgNode ( SvgDocument rDocument,
SvgNode pParent 
)

Definition at line 34 of file svgsvgnode.cxx.

References Svg.

◆ ~SvgSvgNode()

svgio::svgreader::SvgSvgNode::~SvgSvgNode ( )
overridevirtual

Definition at line 100 of file svgsvgnode.cxx.

Member Function Documentation

◆ decomposeSvgNode()

void svgio::svgreader::SvgSvgNode::decomposeSvgNode ( drawinglayer::primitive2d::Primitive2DContainer rTarget,
bool  bReferenced 
) const
overridevirtual

◆ getCurrentViewPort()

basegfx::B2DRange svgio::svgreader::SvgSvgNode::getCurrentViewPort ( ) const
overridevirtual

◆ getHeight()

const SvgNumber & svgio::svgreader::SvgSvgNode::getHeight ( ) const
inline

height content

Definition at line 88 of file svgsvgnode.hxx.

References maHeight.

Referenced by decomposeSvgNode(), getCurrentViewPort(), and seekReferenceHeight().

◆ getSvgAspectRatio()

const SvgAspectRatio & svgio::svgreader::SvgSvgNode::getSvgAspectRatio ( ) const
inline

SvgAspectRatio content.

Definition at line 76 of file svgsvgnode.hxx.

References maSvgAspectRatio.

Referenced by decomposeSvgNode().

◆ getSvgStyleAttributes()

const SvgStyleAttributes * svgio::svgreader::SvgSvgNode::getSvgStyleAttributes ( ) const
overridevirtual

◆ getViewBox()

const basegfx::B2DRange * svgio::svgreader::SvgSvgNode::getViewBox ( ) const
inline

viewBox content

Definition at line 72 of file svgsvgnode.hxx.

References mpViewBox.

Referenced by decomposeSvgNode(), getCurrentViewPort(), seekReferenceHeight(), and seekReferenceWidth().

◆ getWidth()

const SvgNumber & svgio::svgreader::SvgSvgNode::getWidth ( ) const
inline

width content

Definition at line 85 of file svgsvgnode.hxx.

References maWidth.

Referenced by decomposeSvgNode(), getCurrentViewPort(), and seekReferenceWidth().

◆ getX()

const SvgNumber & svgio::svgreader::SvgSvgNode::getX ( ) const
inline

x content

Definition at line 79 of file svgsvgnode.hxx.

References maX.

Referenced by decomposeSvgNode(), and getCurrentViewPort().

◆ getY()

const SvgNumber & svgio::svgreader::SvgSvgNode::getY ( ) const
inline

y content

Definition at line 82 of file svgsvgnode.hxx.

References maY.

Referenced by decomposeSvgNode(), and getCurrentViewPort().

◆ initializeStyleAttributes()

void svgio::svgreader::SvgSvgNode::initializeStyleAttributes ( )
private

◆ parseAttribute()

void svgio::svgreader::SvgSvgNode::parseAttribute ( const OUString &  rTokenName,
SVGToken  aSVGToken,
const OUString &  aContent 
)
overridevirtual

◆ seekReferenceHeight()

void svgio::svgreader::SvgSvgNode::seekReferenceHeight ( double &  fHeight,
bool &  bHasFound 
) const

◆ seekReferenceWidth()

void svgio::svgreader::SvgSvgNode::seekReferenceWidth ( double &  fWidth,
bool &  bHasFound 
) const

◆ setViewBox()

void svgio::svgreader::SvgSvgNode::setViewBox ( const basegfx::B2DRange pViewBox)
inline

Definition at line 73 of file svgsvgnode.hxx.

References mpViewBox.

Referenced by parseAttribute().

Member Data Documentation

◆ maHeight

SvgNumber svgio::svgreader::SvgSvgNode::maHeight
private

Definition at line 40 of file svgsvgnode.hxx.

Referenced by getHeight(), and parseAttribute().

◆ maSvgAspectRatio

SvgAspectRatio svgio::svgreader::SvgSvgNode::maSvgAspectRatio
private

Definition at line 36 of file svgsvgnode.hxx.

Referenced by getSvgAspectRatio(), and parseAttribute().

◆ maSvgStyleAttributes

SvgStyleAttributes svgio::svgreader::SvgSvgNode::maSvgStyleAttributes
private

use styles

Definition at line 31 of file svgsvgnode.hxx.

Referenced by getSvgStyleAttributes(), initializeStyleAttributes(), and parseAttribute().

◆ maVersion

SvgNumber svgio::svgreader::SvgSvgNode::maVersion
private

Definition at line 41 of file svgsvgnode.hxx.

Referenced by parseAttribute().

◆ maWidth

SvgNumber svgio::svgreader::SvgSvgNode::maWidth
private

Definition at line 39 of file svgsvgnode.hxx.

Referenced by getWidth(), and parseAttribute().

◆ maX

SvgNumber svgio::svgreader::SvgSvgNode::maX
private

Definition at line 37 of file svgsvgnode.hxx.

Referenced by getX(), and parseAttribute().

◆ maY

SvgNumber svgio::svgreader::SvgSvgNode::maY
private

Definition at line 38 of file svgsvgnode.hxx.

Referenced by getY(), and parseAttribute().

◆ mbStyleAttributesInitialized

bool svgio::svgreader::SvgSvgNode::mbStyleAttributesInitialized
private

#i125258# bitfield

Definition at line 44 of file svgsvgnode.hxx.

Referenced by initializeStyleAttributes().

◆ mpViewBox

std::unique_ptr<basegfx::B2DRange> svgio::svgreader::SvgSvgNode::mpViewBox
private

variable scan values, dependent of given XAttributeList

Definition at line 35 of file svgsvgnode.hxx.

Referenced by getViewBox(), and setViewBox().


The documentation for this class was generated from the following files: