Solved How to get absolute location of mouse click on widget?
-
Hey,
the widget is a QGraphicsView and it is able to zoom in it.
When I click with the mouse anywhere on this widget, I want to display a picture there.
The problem is, that I don't know how I can get the absolute location of the mouse on the widget.
This is a problem, because when I zoom in and click, I also want to spawn the picture exactely where the mouse was over the widget.
Any ideas?
Thanks for answers -
Hi,
Are you thinking about something like the QGraphicsView::mapToScene method ?
-
@SGaist
Yes, this was exactely what I wanted.
StackOverflow gave me the answer just now.
Thank you!