Details
-
Suggestion
-
Resolution: Unresolved
-
P2: Important
-
None
-
5.11.2
Description
When using Shape, it would be nice to be able to construct a ShapePath using data from a model. For example, something like this:
Shape { ShapePath { Instantiator { model: someModel // Anything which implements Qt model API PathLine { x: xValue // data from item in model y: yValue // data from item in model } } } }
At the moment, this doesn't work, because it tries to add the Instantiator to the pathElements property of ShapePath and can't because it isn't a PathElement itself.
I haven't been able to find any other way of declaratively building up a ShapePath using data from a model. I believe it would make Shape and ShapePath much more flexible: Having to define all the line segments ahead of time is very limiting and rarely useful in practice.
Attachments
Issue Links
- relates to
-
QTBUG-83061 QML Repeater should allow creation of objects
- Closed