Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

Element QML - Item



  • Hello, everybody. Started learning Qml. In some examples, there is an element called Item. For some reason, examples with this element do not start in Ubuntu do not start Windows. If I'm use element Window everything works. Tell me how to run examples with element Item?


  • Moderators

    Item is a non-graphical element. It won't ever show up on the screen, it is always invisible.


  • Qt Champions 2018

    It's a graphical element that renders nothing, but you can nest other graphical elements inside.
    As in it belongs to the visual hierarchy of the Qt Quick scene and has x, y and z properties.

    @Evgen2016 if you are using a QQmlApplicationEngine or something similar, it doesn't provide you a window. You have to create it yourself in QML.
    That's why you need a Window or an ApplicationWindow to display something on screen.


Log in to reply