Thats not quite what I'm getting at.  That will emit the signal, which
is the 'old style' but the new style is a bit different, and after you
set it up you emit the signal by using:

        mysignal.emit(args)

My question is that the only way I know how to make a 'new style' signal
emittable is via creating a class attribute, ie:

class MyScene(QtGui.QGraphicsScene):
    mysignal = QtCore.pyqtSignal(QtGui.QGraphicsSceneMouseEvent)
    def __init__(self,parent):
        #normal init stuff

thanks
mbs

> From: "Demetrius Cassidy" <dcassid...@mass.rr.com>
> Subject: Re: [PyQt] New Style emit without subclassing
> To: <pyqt@riverbankcomputing.com>
> Message-ID: <285bc363d5e443c4983af69eec852...@rahxephon>
> Content-Type: text/plain; format=flowed; charset="iso-8859-1";
>         reply-type=original
> 
> from PyQt4.QtCore import SIGNAL
> 
> class MyScene(QtGui.QGraphicsScene):
>    def __init__(self,parent=None):
>           QtGui.QGraphicsScene.__init__(self,parent)
> 
> self.emit(SIGNAL(("itemClicked(QGraphicsSceneMouseEvent*)")))
> 

_______________________________________________
PyQt mailing list    PyQt@riverbankcomputing.com
http://www.riverbankcomputing.com/mailman/listinfo/pyqt

Reply via email to