[Development] QML Component inheriting?
Tomasz Siekierda
sierdzio at gmail.com
Thu Oct 4 12:27:05 CEST 2012
> What i really miss in QML is the ability to let a component inherit
functionality from another component.
This is already a feature: just create your components in separate files
and use this:
// BaseButton.qml
Item
{
property int someNum: 100
... the basics for a button.
}
// SpecialButton.qml
BaseButton // SpecialButton
{
somenum: 500
... A BaseButton adjusted for special cases
}
// FancyButton.qml
BaseButton //FancyButton
{
... Fancy button with special effects, shaders and whatever you can
think of
}
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/development/attachments/20121004/1ea1ea2b/attachment.html>
More information about the Development
mailing list