Search code examples
qtqmlqt5qt3d

Why Qt Entity type does not support states property?


Does anyone have an explanation on why Qt3D Entity type does not have support for a states property as Item does?


Solution

  • states is specific to Items which are 2D visual elements.

    Entitys are 3D visual elements and not part of the QML 2D visual family so they are designed and work differently. Sounds like you may want to contact the Qt folks and make a feature request to add state functionality to Entitys.

    In the meantime, you might be able to create and attach an invisible Item to your entities and just use it for its state management abilities to drive visual changes on your Entity.