PDA

View Full Version : Implementing paint in a child of a parent



drarem
21st June 2007, 12:43
I followed along in a couple of tutorials and keep stubbing my toes but making progress..

I placed a couple of qgraphicview widgets in a grid layout, in a qvboxlayout. I found out quickly that qgraphicsview doesn't have a 'clicked' signal. I see mousePressEvent and I try to override? what's out there in order to check the mouse press event over the graphics item.

How would I go about using my own mousepressevent function and point to each graphics view?

Thanks.

jacek
21st June 2007, 16:28
I see mousePressEvent and I try to override?
You should rather override QGraphicsScene::mousePressEvent(), not the one from QGraphicsView.


what's out there in order to check the mouse press event over the graphics item.
Take a look at graphicsview/elasticnodes example.