[Interest] Is it possible to define and inherit component in the same QML file?

Alexander Ivash elderorb at gmail.com
Wed Sep 12 18:01:35 CEST 2018


Like this:

property Component baseDelegate: Item {
}

property Component textDelegate: baseDelegate {
}

property Component imageDelegate: baseDelegate {
}
.....

Currently it doesn't work, but maybe there are some tricks to achieve
behaviour like this without moving baseDelegate to 'BaseDelegate.qml'.
And yes, I'm aware of composition, but the question is about
inheritance.



More information about the Interest mailing list