I have a class that inherits QGraphicsPathItem, and I'd like it to emit signals when user drags it around a QGraphicsView/QGraphicsScene. Since QGraphicsPathItem doesn't inherit QObject, this isn't possible out of the box. On the other hand, sublclasses of QGraphicsObject provide such signals, but don't have properties from QGraphicsPathItem that I need.
How can I get my QGraphicsPathItem subclass to emit signals when user moves it around? I've tried:
- Multiple inheritance, with my class inheriting both
QGraphicsPathItemandQGraphicsObject - Creating a child
QGraphicsObjectwithin myQGraphicsPathItem
I'm using pyside.