[Interest] Why wrap Rectangle/Image with Item

Sadika Sumanapala sadikahs at gmail.com
Sun Jan 18 08:52:28 CET 2015


Hi,

What is the advantage of wrapping Rectangle/Image QML types with Item type.
I came across several wrapping when following  QML Advanced Tutorial (
http://doc.qt.io/qt-5/qtquick-tutorials-samegame-samegame1-example.html)

For example:

Item {
    id: block
    Image {
        id: img
        anchors.fill: parent
        source: "../shared/pics/redStone.png"
    }
}

Thank you,
Sadika
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/interest/attachments/20150118/d7ceda41/attachment.html>


More information about the Interest mailing list