I want to fill the colours in the following rectangles created through Repeaters, dynamically.
I am not able to access the bottom Repeater at all.
How should I access "all" the rectangles here?
Row
{
spacing: 20
Repeater
{
id: repeater3
property Repeater repeater2: repeater2
model: head.rows
Column
{
id: columnInBetween
spacing: 20
Repeater
{
id: repeater2
model: head.columns
property Row row1: row1
Row
{
id: row1
property Repeater repeater1: repeater1
Repeater
{
id: repeater1
model: 2
Rectangle
{
width: 20; height: 20
color: "red"
}
}
}
}
}
}
}
I am not able to access the bottom Repeater at all- Why not? What did you try? - Mitchchildrenproperty of their parents (remembeer, Repeater parents what it creates to its own parent -- after itself!) or "register" the items of interest in a property of an item with an id visible at the file scope; - mlvljrproperty var modelData2: modelData-- provided the name of the property Repeater attaches ismodelData-- don't remember right now, can be plainmodel, these things are a bit inconsistent between Repeater and ListView, iirc). - mlvljr