[PyQt] Is the result of SIGNAL() a constant?
Phil Thompson
phil at riverbankcomputing.co.uk
Tue Jan 8 22:15:19 GMT 2008
On Tuesday 08 January 2008, Aaron Digulla wrote:
> Hello,
>
> >From the documentation, I got the impression that the result of SIGNAL()
>
> is more or less a constant. Is this code valid?
>
> signal = SIGNAL()
> self.connect(w1, signal, self.w1Clicked)
> self.connect(w2, signal, self.w2Clicked)
Yes - given a correct call to SIGNAL().
> ie. can I predefine all signals in my app, save them somewhere (to save
> typos) and avoid the additional SIGNAL() calls? Or do I have to call
> SIGNAL() every time?
type(SIGNAL('')) would show that it is just a string.
Phil
More information about the PyQt
mailing list