Skia
2D Graphics Library
SkSVGNode Class Referenceabstract

#include <SkSVGNode.h>

Inheritance diagram for SkSVGNode:

Public Member Functions

 ~SkSVGNode () override
 
SkSVGTag tag () const
 
virtual void appendChild (sk_sp< SkSVGNode >)=0
 
void render (const SkSVGRenderContext &) const
 
bool asPaint (const SkSVGRenderContext &, SkPaint *) const
 
SkPath asPath (const SkSVGRenderContext &) const
 
SkRect objectBoundingBox (const SkSVGRenderContext &) const
 
void setAttribute (SkSVGAttribute, const SkSVGValue &)
 
bool setAttribute (const char *attributeName, const char *attributeValue)
 
virtual bool parseAndSetAttribute (const char *name, const char *value)
 
bool unique () const
 May return true if the caller is the only owner. More...
 
void ref () const
 Increment the reference count. More...
 
void unref () const
 Decrement the reference count. More...
 

Protected Member Functions

 SkSVGNode (SkSVGTag)
 
virtual bool onPrepareToRender (SkSVGRenderContext *) const
 
virtual void onRender (const SkSVGRenderContext &) const =0
 
virtual bool onAsPaint (const SkSVGRenderContext &, SkPaint *) const
 
virtual SkPath onAsPath (const SkSVGRenderContext &) const =0
 
virtual void onSetAttribute (SkSVGAttribute, const SkSVGValue &)
 
virtual bool hasChildren () const
 
virtual SkRect onObjectBoundingBox (const SkSVGRenderContext &) const
 

Static Protected Member Functions

static SkMatrix ComputeViewboxMatrix (const SkRect &, const SkRect &, SkSVGPreserveAspectRatio)
 

Constructor & Destructor Documentation

◆ ~SkSVGNode()

SkSVGNode::~SkSVGNode ( )
override

◆ SkSVGNode()

SkSVGNode::SkSVGNode ( SkSVGTag  )
protected

Member Function Documentation

◆ appendChild()

virtual void SkSVGNode::appendChild ( sk_sp< SkSVGNode )
pure virtual

◆ asPaint()

bool SkSVGNode::asPaint ( const SkSVGRenderContext ,
SkPaint  
) const

◆ asPath()

SkPath SkSVGNode::asPath ( const SkSVGRenderContext ) const

◆ ComputeViewboxMatrix()

static SkMatrix SkSVGNode::ComputeViewboxMatrix ( const SkRect ,
const SkRect ,
SkSVGPreserveAspectRatio   
)
staticprotected

◆ hasChildren()

virtual bool SkSVGNode::hasChildren ( ) const
inlineprotectedvirtual

Reimplemented in SkSVGContainer.

◆ objectBoundingBox()

SkRect SkSVGNode::objectBoundingBox ( const SkSVGRenderContext ) const

◆ onAsPaint()

virtual bool SkSVGNode::onAsPaint ( const SkSVGRenderContext ,
SkPaint  
) const
inlineprotectedvirtual

Reimplemented in SkSVGPattern, and SkSVGGradient.

◆ onAsPath()

virtual SkPath SkSVGNode::onAsPath ( const SkSVGRenderContext ) const
protectedpure virtual

◆ onObjectBoundingBox()

virtual SkRect SkSVGNode::onObjectBoundingBox ( const SkSVGRenderContext ) const
inlineprotectedvirtual

◆ onPrepareToRender()

virtual bool SkSVGNode::onPrepareToRender ( SkSVGRenderContext ) const
protectedvirtual

◆ onRender()

virtual void SkSVGNode::onRender ( const SkSVGRenderContext ) const
protectedpure virtual

◆ onSetAttribute()

virtual void SkSVGNode::onSetAttribute ( SkSVGAttribute  ,
const SkSVGValue  
)
inlineprotectedvirtual

Reimplemented in SkSVGTransformableNode, and SkSVGSVG.

◆ parseAndSetAttribute()

◆ ref()

void SkRefCntBase::ref ( ) const
inlineinherited

Increment the reference count.

Must be balanced by a call to unref().

◆ render()

void SkSVGNode::render ( const SkSVGRenderContext ) const

◆ setAttribute() [1/2]

bool SkSVGNode::setAttribute ( const char *  attributeName,
const char *  attributeValue 
)

◆ setAttribute() [2/2]

void SkSVGNode::setAttribute ( SkSVGAttribute  ,
const SkSVGValue  
)

◆ tag()

SkSVGTag SkSVGNode::tag ( ) const
inline

◆ unique()

bool SkRefCntBase::unique ( ) const
inlineinherited

May return true if the caller is the only owner.

Ensures that all previous owner's actions are complete.

◆ unref()

void SkRefCntBase::unref ( ) const
inlineinherited

Decrement the reference count.

If the reference count is 1 before the decrement, then delete the object. Note that if this is the case, then the object needs to have been allocated via new, and not on the stack.


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