[PyKDE] Auto-Connection supported in PyQt4
Torsten Marek
shlomme at gmx.net
Wed Jan 11 19:02:33 GMT 2006
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Andreas Pakulat schrieb:
> On 11.01.06 03:25:23, Andreas Pakulat wrote:
>
>>is the auto-connection feature of QObject supported with PyQt4? Will it
>>be supported in the future?
>>
>>I just tried with a function that is called:
>>
>>on_removePictureFormat_clicked(self)
>>
>>in a widget that uses a ui created with designer and inheriting from
>>that ui. So removePictureFormat is in fact a member of the class.
>>
>>This doesn't work, i.e. the function is not called when clicking the
>>button, thus my question.
>
>
> I tried to dig a bit into this, it seems there are 2 things missing for
> auto-connection to work:
>
> 1. The wrapper for QMetaObject needs to expose connectSlotsByName, this
> is in qobjectdefs.sip (and qobjectdefs.h in the qt source).
>
> 2. pyuic needs to generate something like:
> QtCore.QMetaObject.connectSlotsByName(widget) in the setupUi(self,
> widget) function.
>
> However I'm not sure it's that simple, because I don't know how PyQt4
> wraps all the Meta-Object stuff. That means, maybe a pythonic
> implementation for connectSlotsByName needs to be provided.
>
> Phil can you comment on this, if it's possible to have auto-connection
> at all and if you want to do it? (I can provide a patch for pyuic4 to
> generate that one extra line of code).
>
Hi,
I'm going to look into that once I'm back in Germany and have some free time on
my hand, possibly next week.
greetings
Torsten
- --
Torsten Marek <shlomme at gmx.net>
ID: A244C858 -- FP: 1902 0002 5DFC 856B F146 894C 7CC5 451E A244 C858
Keyserver: subkeys.pgp.net
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org
iD8DBQFDxVZJfMVFHqJEyFgRAkNMAKDC1dVQjqFyePPtwUzKuQlXomKy3wCgv3z/
RdR7Sy3/h7Ma+EsRueD9Gmo=
=s6tL
-----END PGP SIGNATURE-----
More information about the PyQt
mailing list