Auf dieser Seite

QParallelAnimationGroup Class

Die Klasse „QParallelAnimationGroup“ stellt eine parallele Gruppe von Animationen bereit. Mehr...

Header: #include <QParallelAnimationGroup>
CMake: find_package(Qt6 REQUIRED COMPONENTS Core)
target_link_libraries(mytarget PRIVATE Qt6::Core)
qmake: QT += core
Erbt von: QAnimationGroup

Öffentliche Funktionen

QParallelAnimationGroup(QObject *parent = nullptr)
virtual ~QParallelAnimationGroup()

Neu implementierte öffentliche Funktionen

virtual int duration() const override

Neu implementierte geschützte Funktionen

virtual bool event(QEvent *event) override
virtual void updateCurrentTime(int currentTime) override
virtual void updateDirection(QAbstractAnimation::Direction direction) override
virtual void updateState(QAbstractAnimation::State newState, QAbstractAnimation::State oldState) override

Ausführliche Beschreibung

QParallelAnimationGroup – eine „ container for animations“ – startet alle ihre Animationen, sobald sie selbst „ started “ ist, d. h., sie führt alle Animationen parallel aus. Die Animationsgruppe endet, sobald die am längsten dauernde Animation beendet ist.

Sie können `QParallelAnimationGroup` wie jede andere ` QAbstractAnimation` behandeln, z. B. anhalten, fortsetzen oder zu anderen Animationsgruppen hinzufügen.

    QParallelAnimationGroup *group = new QParallelAnimationGroup;
    group->addAnimation(anim1);
    group->addAnimation(anim2);

    group->start();

In diesem Beispiel sind „ anim1 “ und „ anim2 “ zwei bereits eingerichtete „ QPropertyAnimation“.

Siehe auch „ QAnimationGroup “, „ QPropertyAnimation “ und „Das Animations-Framework“.

Dokumentation zu Mitgliedsfunktionen

QParallelAnimationGroup::QParallelAnimationGroup(QObject *parent = nullptr)

Erstellt eine `QParallelAnimationGroup`. ` parent ` wird an den Konstruktor von ` QObject` übergeben.

[virtual noexcept] QParallelAnimationGroup::~QParallelAnimationGroup()

Löscht die Animationsgruppe. Dabei werden auch alle zugehörigen Animationen gelöscht.

[override virtual] int QParallelAnimationGroup::duration() const

Implementiert: ` QAbstractAnimation::duration()` const.

[override virtual protected] bool QParallelAnimationGroup::event(QEvent *event)

Umsetzt: ` QAnimationGroup::event(QEvent *event)`.

[override virtual protected] void QParallelAnimationGroup::updateCurrentTime(int currentTime)

Implementiert: QAbstractAnimation::updateCurrentTime(int currentTime).

[override virtual protected] void QParallelAnimationGroup::updateDirection(QAbstractAnimation::Direction direction)

Implementiert: ` QAbstractAnimation::updateDirection` (`QAbstractAnimation::Direction direction`).

[override virtual protected] void QParallelAnimationGroup::updateState(QAbstractAnimation::State newState, QAbstractAnimation::State oldState)

Implementiert: ` QAbstractAnimation::updateState` (`QAbstractAnimation::State newState, QAbstractAnimation::State oldState`).

© 2026 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.