QtDesigner container plugin with custom page class
-
Hi, everyone! I develop a custom multi-page widget. I want to be able to manage a page list in QtDesigner. As I know, the best is to use QDesignerContainerExtension class to archive this goal. But I need that pages be custom classes, not a QWidget. How can I archive this? Thank in advance!
-
Thank you for this suggestion! Will I see the actual type of a page widget in the object tree and the property editor? It would be perfect :)
[quote author="Olivier Goffart" date="1324648773"]In your impementation of QDesignerContainerExtension::insertWidget, you can create your own custom widget instead of using directly the one passed as parametter (maybe you can just ignore it or you need to call deleteLater on it)[/quote] -
In your impementation of QDesignerContainerExtension::insertWidget, you can create your own custom widget instead of using directly the one passed as parametter (maybe you can just ignore it or you need to call deleteLater on it)
@ogoffart In your impementation of QDesignerContainerExtension::insertWidget, you can create your own custom widget instead of using directly the one passed as parametter (maybe you can just ignore it or you need to call deleteLater on it)
I tried this and I'm pretty sure you can't do it in Qt 5.15 at least, you end up with a Qt Designer warning dialog saying that that's an unmanaged widget and you should use the domXml() instead (Heaven knows how); at some point later it makes crash the designer when adding a child to the custom widget page.