*** GMX Spamverdacht *** [PyQt] PyQt4 feature request

Andreas Pakulat apaku at gmx.de
Thu May 17 18:04:52 BST 2007

On 17.05.07 15:35:00, Detlev Offenbach wrote:
> Hi Phil,
> I'd like to integrate Qt-Designer into eric4 for version 4.1. In order to do 
> that I would need the class 'QDesignerComponents' to be wrapped, although it 
> is not documented in the Qt help pages. Do you think, that could be done?

I guess just wrapping QDesignerComponents is not enough, at least in C++
you need the shared_global_p.h from lib/shared (in designer src) and
qdesigner_integration_p.h from the same dir.

Then the setup is done like this:

m_designer = QDesignerComponents::createFormEditor(this);
m_designer->setWidgetBox(QDesignerComponents::createWidgetBox(m_designer, 0));
m_designer->setPropertyEditor(QDesignerComponents::createPropertyEditor(m_designer, 0));
m_designer->setActionEditor(QDesignerComponents::createActionEditor(m_designer, 0));
m_designer->setObjectInspector(QDesignerComponents::createObjectInspector(m_designer, 0));
new qdesigner_internal::QDesignerIntegration(m_designer, this);

Then all one needs to do is create a formwindow, set its contents and
filename, create a QMdiArea and add the formwindow as subwindow. 

If you need more ideas see 


Although that one is a bit more complicated because it provides the
designer toolviews outside the qmdi area and allows to have multiple
qmdiareas for the same .ui file (i.e. multiple views onto the same


PS: The setup-stuff was originally written by Roberto Raggi, the author
of the Qt4 designer. Especially the new qdesigner_internal-line is

Your life would be very empty if you had nothing to regret.

More information about the PyQt mailing list