The XAnimator type animates the x position of an Item. More...
Import Statement: | import QtQuick 2.11 |
Since: | Qt 5.2 |
Inherits: |
Animator types are different from normal Animation types. When using an Animator, the animation can be run in the render thread and the property value will jump to the end when the animation is complete.
The value of Item::x is updated after the animation has finished.
The following snippet shows how to use a XAnimator together with a Rectangle item.
Rectangle { id: xmovingBox width: 50 height: 50 color: "lightsteelblue" XAnimator { target: xmovingBox; from: 10; to: 0; duration: 1000 running: true } }
It is also possible to use the on
keyword to tie the XAnimator directly to an Item instance.
Rectangle { width: 50 height: 50 color: "lightsteelblue" XAnimator on x { from: 10; to: 0; duration: 1000 } }
As part of the free Business evaluation, we offer a free welcome call for companies, to talk about your requirements, and how the Felgo SDK & Services can help you. Just sign up and schedule your call.
Sign up now to start your free Business evaluation: