[PyQt] PyQt4 question

Detlev Offenbach detlev at die-offenbachs.de
Mon May 28 08:34:46 BST 2007


On Montag, 28. Mai 2007, David Boddie wrote:
> On Sun May 27 22:57:23 BST 2007, Andreas Pakulat wrote:
> > On 27.05.07 14:53:08, Detlev Offenbach wrote:
> > > On Sonntag, 27. Mai 2007, Giovanni Bajo wrote:
> > > > Uh? Does QDesignerFormEditorPluginInterface inherit from QObject?
> > > > Otherwise, I can't see how the qobject_cast can work.
> > >
> > > I have no idea. I had a look into edyuk, and they do it that way and it
> > > works there (unless there is some magic somewhere else in their code).
> >
> > One reason could be that the QDesignerFormEditorPluginInterface is a
> > Q_INTERFACE and the real QObject-derived implementation declares its
> > inheritance from that interface. I guess qobject_cast<> takes that into
> > account.
>
> That makes sense. Those classes are supposed to be subclassed (mixed in)
> with QObject in C++ in order to declare interfaces. You would never
> subclass them alone.
>

So, how can I check, if a QObject is of the interface type? How can stuff like 
this be wrapped? See my other post about the "qt_extension" function of 
QExtensionManager not being wrapped? All that stuff need to be available in 
order to tightly integrate designer into eric4.

Detlev
-- 
Detlev Offenbach
detlev at die-offenbachs.de


More information about the PyQt mailing list