I’m wondering if it is possible to create a grid of elements in qml which completely and evenly fill the width and height of the grid/parent:
Grid {
columns: 2
Repeater {
model: 4
Rectangle {
width: /* ??? */
height: / * ??? */
}
}
}
I think a have to set absolute values here. Using anchors.fill: parent won’t work, as well as something like width: parent.width / 2.
I think you forgot to set parent’s (
Gridelement) anchors. Also you can always reference an element by it’ id.