[PyKDE] connectSlotsByName do that really works in python?
Andreas Pakulat
apaku at gmx.de
Mon Dec 18 17:26:36 GMT 2006
On 18.12.06 09:49:38, Miguel Angel Cañedo wrote:
> El Domingo, 17 de Diciembre de 2006 16:16, Carles Pina i Estany escribió:
> > I send a test that I have done now to learn to use Eric but I think that
> > it can help him (if he hasn't finished it :-) )
>
> Thanks, I already got to the same coclusion thanks to the Andreas comment.
> I think that some sample code like yours should be included in the PyQt
> reference, I did not find a place telling where should that autoconect defs
> be declared it only talks about the decorators.
Auto connection is documented in the Qt4 designer docs and its pretty
obvious that you create a qwidget subclass for the functions to be used
as slots. The decorator-thing is not directly related to autoconnect, it
applies to all functions that are used as slots.
As for example code, have yo looked at the examples that come with
PyQt4? IIRC one or two of them use auto-connection.
> > without use eric should be:
> > designer-qt test.ui
> > pyuic -o Ui_test.py test.ui
>
> Can you use pyuic(4) from inside Eric?, where?
Check out the 2nd tab on the "project manager" (left side). There you
can add all your .ui files and if the project is configured to be a Qt4
project eric3 will run pyuic4 when you let it "translate" the forms
(translation from german menu) using the context menu.
Another way to use the .ui's with PyQt4 is to load them dynamically
during the runtime, there are documented functions for that - I don't
have them at hand, sth. with loadUi I think.
Andreas
--
Your motives for doing whatever good deed you may have in mind will be
misinterpreted by somebody.
More information about the PyQt
mailing list