Hi,

I'm trying to port KDAB's DeclarativeWidgets[1] to Qt5. I've got it running 
for trivial QML files, however as soon as there are child widgets the 
running program aborts.

The abort is caused by QObject::setParent, which contains this little gem: 
Q_ASSERT(!d->isWidget);

Apart from not understanding why there is a significant difference between 
QObjects and QWidgets in regards to parenting...

There used to be code that handled this in qqmlvme.cpp[2], but it has been 
disabled by an #if 0 . Apparently to remove dependencies on QtWidgets from 
QtQml.

I kind of ran out of ideas on how to solve this. Should I consider 
setParent, qqmlvme or the direct use of QWidgets as a bug?



        Konrad


[1] It enables you to create widget based GUIs using QML. 
git://github.com/KDAB/DeclarativeWidgets

[2] In 5.2 beta this is line 627 in qqmlvme.cpp. It's Halloween. Go ahead, 
look at scary code! ;-)

Attachment: signature.asc
Description: This is a digitally signed message part.

_______________________________________________
Development mailing list
Development@qt-project.org
http://lists.qt-project.org/mailman/listinfo/development

Reply via email to