QSequentialAnimationGroup

Inheritance diagram of PySide2.QtCore.QSequentialAnimationGroup

Note

This class was introduced in Qt 4.6.

Synopsis

Functions

Signals

Detailed Description

The PySide2.QtCore.QSequentialAnimationGroup class provides a sequential group of animations.

PySide2.QtCore.QSequentialAnimationGroup is a PySide2.QtCore.QAnimationGroup that runs its animations in sequence, i.e., it starts one animation after another has finished playing. The animations are played in the order they are added to the group (using PySide2.Qt3DAnimation.Qt3DAnimation::QAnimationGroup.addAnimation() or PySide2.Qt3DAnimation.Qt3DAnimation::QAnimationGroup.insertAnimation() ). The animation group finishes when its last animation has finished.

At each moment there is at most one animation that is active in the group; it is returned by PySide2.QtCore.QSequentialAnimationGroup.currentAnimation() . An empty group has no current animation.

A sequential animation group can be treated as any other animation, i.e., it can be started, stopped, and added to other groups. You can also call PySide2.QtCore.QSequentialAnimationGroup.addPause() or PySide2.QtCore.QSequentialAnimationGroup.insertPause() to add a pause to a sequential animation group.

QSequentialAnimationGroup *group = new QSequentialAnimationGroup;

group->addAnimation(anim1);
group->addAnimation(anim2);

group->start();

In this example, anim1 and anim2 are two already set up PySide2.QtCore.QPropertyAnimation s.

class PySide2.QtCore.QSequentialAnimationGroup([parent=nullptr])
Parameters:parentPySide2.QtCore.QObject

Constructs a PySide2.QtCore.QSequentialAnimationGroup . parent is passed to PySide2.QtCore.QObject ‘s constructor.

PySide2.QtCore.QSequentialAnimationGroup.addPause(msecs)
Parameters:msecsPySide2.QtCore.int
Return type:PySide2.QtCore.QPauseAnimation

Adds a pause of msecs to this animation group. The pause is considered as a special type of animation, thus PySide2.Qt3DAnimation.Qt3DAnimation::QAnimationGroup.animationCount() will be increased by one.

See also

PySide2.QtCore.QSequentialAnimationGroup.insertPause() QAnimationGroup.addAnimation()

PySide2.QtCore.QSequentialAnimationGroup.currentAnimation()
Return type:PySide2.QtCore.QAbstractAnimation
PySide2.QtCore.QSequentialAnimationGroup.currentAnimationChanged(current)
Parameters:currentPySide2.QtCore.QAbstractAnimation
PySide2.QtCore.QSequentialAnimationGroup.insertPause(index, msecs)
Parameters:
  • indexPySide2.QtCore.int
  • msecsPySide2.QtCore.int
Return type:

PySide2.QtCore.QPauseAnimation

Inserts a pause of msecs milliseconds at index in this animation group.

See also

PySide2.QtCore.QSequentialAnimationGroup.addPause() QAnimationGroup.insertAnimation()