This example combines an observable ListModel with a viewport-based ListView.
qml6 listview.qml
append, remove, and setProperty notify the view.
ListView.view.width gives a delegate access to its view's width, and clip prevents content drawing outside the viewport.
A ListView creates delegates around the viewport.
Delegate reuse is optional, so durable row state belongs in the model rather than in a delegate instance.
The checkbox and buttons are standard Controls.
Right-click deletion is pointer-only in this teaching example and is not presented as an accessible production interaction.
# 04: ListView
This example combines an observable `ListModel` with a viewport-based `ListView`.
```sh
qml6 listview.qml
```
`append`, `remove`, and `setProperty` notify the view.
`ListView.view.width` gives a delegate access to its view's width, and `clip` prevents content drawing outside the viewport.
A ListView creates delegates around the viewport.
Delegate reuse is optional, so durable row state belongs in the model rather than in a delegate instance.
The checkbox and buttons are standard Controls.
Right-click deletion is pointer-only in this teaching example and is not presented as an accessible production interaction.