Qt 6.x
The Qt SDK
Loading...
Searching...
No Matches
QSvgAnimateTransform Class Reference

#include <qsvgstyle_p.h>

+ Inheritance diagram for QSvgAnimateTransform:
+ Collaboration diagram for QSvgAnimateTransform:

Public Types

enum  TransformType {
  Empty , Translate , Scale , Rotate ,
  SkewX , SkewY
}
 
enum  Additive { Sum , Replace }
 
- Public Types inherited from QSvgStyleProperty
enum  Type {
  QUALITY , FILL , VIEWPORT_FILL , FONT ,
  STROKE , SOLID_COLOR , GRADIENT , TRANSFORM ,
  ANIMATE_TRANSFORM , ANIMATE_COLOR , OPACITY , COMP_OP
}
 

Public Member Functions

 QSvgAnimateTransform (int startMs, int endMs, int by=0)
 
void setArgs (TransformType type, Additive additive, const QList< qreal > &args)
 
void setFreeze (bool freeze)
 
void setRepeatCount (qreal repeatCount)
 
void apply (QPainter *p, const QSvgNode *node, QSvgExtraStates &states) override
 
void revert (QPainter *p, QSvgExtraStates &states) override
 
Type type () const override
 
QSvgAnimateTransform::Additive additiveType () const
 
bool animActive (qreal totalTimeElapsed)
 
bool transformApplied () const
 
void clearTransformApplied ()
 
- Public Member Functions inherited from QSvgStyleProperty
virtual ~QSvgStyleProperty ()
 
virtual void apply (QPainter *p, const QSvgNode *node, QSvgExtraStates &states)=0
 
virtual void revert (QPainter *p, QSvgExtraStates &states)=0
 
virtual Type type () const =0
 
- Public Member Functions inherited from QSvgRefCounted
 QSvgRefCounted ()
 
virtual ~QSvgRefCounted ()
 
void ref ()
 
void deref ()
 

Protected Member Functions

void resolveMatrix (const QSvgNode *node)
 

Detailed Description

Definition at line 607 of file qsvgstyle_p.h.

Member Enumeration Documentation

◆ Additive

Enumerator
Sum 
Replace 

Definition at line 619 of file qsvgstyle_p.h.

◆ TransformType

Enumerator
Empty 
Translate 
Scale 
Rotate 
SkewX 
SkewY 

Definition at line 610 of file qsvgstyle_p.h.

Constructor & Destructor Documentation

◆ QSvgAnimateTransform()

QSvgAnimateTransform::QSvgAnimateTransform ( int  startMs,
int  endMs,
int  by = 0 
)

Definition at line 613 of file qsvgstyle.cpp.

References Q_UNUSED.

Member Function Documentation

◆ additiveType()

QSvgAnimateTransform::Additive QSvgAnimateTransform::additiveType ( ) const
inline

Definition at line 632 of file qsvgstyle_p.h.

◆ animActive()

bool QSvgAnimateTransform::animActive ( qreal  totalTimeElapsed)
inline

Definition at line 637 of file qsvgstyle_p.h.

◆ apply()

void QSvgAnimateTransform::apply ( QPainter p,
const QSvgNode node,
QSvgExtraStates states 
)
overridevirtual

Implements QSvgStyleProperty.

Definition at line 637 of file qsvgstyle.cpp.

References resolveMatrix().

+ Here is the call graph for this function:

◆ clearTransformApplied()

void QSvgAnimateTransform::clearTransformApplied ( )
inline

Definition at line 657 of file qsvgstyle_p.h.

◆ resolveMatrix()

void QSvgAnimateTransform::resolveMatrix ( const QSvgNode node)
protected

Definition at line 651 of file qsvgstyle.cpp.

References QSvgTinyDocument::currentElapsed(), QSvgNode::document(), qCeil(), qDegreesToRadians(), qMax(), qTan(), QTransform::rotate(), Rotate, QTransform::scale(), Scale, QTransform::shear(), SkewX, SkewY, QTransform::translate(), and Translate.

Referenced by apply().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ revert()

void QSvgAnimateTransform::revert ( QPainter p,
QSvgExtraStates states 
)
overridevirtual

Implements QSvgStyleProperty.

Definition at line 645 of file qsvgstyle.cpp.

◆ setArgs()

void QSvgAnimateTransform::setArgs ( TransformType  type,
Additive  additive,
const QList< qreal > &  args 
)

Definition at line 628 of file qsvgstyle.cpp.

References args, Q_ASSERT, QList< T >::size(), and type().

Referenced by parseAnimateTransformNode().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ setFreeze()

void QSvgAnimateTransform::setFreeze ( bool  freeze)

Definition at line 780 of file qsvgstyle.cpp.

Referenced by parseAnimateTransformNode().

+ Here is the caller graph for this function:

◆ setRepeatCount()

void QSvgAnimateTransform::setRepeatCount ( qreal  repeatCount)

Definition at line 785 of file qsvgstyle.cpp.

Referenced by parseAnimateTransformNode().

+ Here is the caller graph for this function:

◆ transformApplied()

bool QSvgAnimateTransform::transformApplied ( ) const
inline

Definition at line 651 of file qsvgstyle_p.h.

◆ type()

QSvgStyleProperty::Type QSvgAnimateTransform::type ( ) const
overridevirtual

Implements QSvgStyleProperty.

Definition at line 775 of file qsvgstyle.cpp.

References QSvgStyleProperty::ANIMATE_TRANSFORM.

Referenced by setArgs().

+ Here is the caller graph for this function:

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