get mouse click position

Asked by N3rz on 2007-05-15

Hi,
I'm trying to draw with QPainter a simple chess board ontop of a QT form. First thing I need to know how to get the left mouse button down position (click) so I can calculate from there the position on the array the user clicked... etc
Second thing is that what I draw isn't persistent... so is there a method like... OnDraw or OnPaint?
One more thing to mention is that I made previously gui's in mfc and windows sdk.

Question information

Language:
English Edit question
Status:
Solved
For:
Ubuntu kdevelop Edit question
Assignee:
No assignee Edit question
Solved by:
Markus Thielmann
Solved:
2007-05-16
Last query:
2007-05-16
Last reply:
2007-05-16
Markus Thielmann (thielmann) said : #1

Thanks for your question.

You might get an answer in this forum, but I still would strongly encourage you to ask your question in a Qt related developer forum. Like http://www.qtforum.org/ for example.

N3rz (nerzhul-de) said : #2

Thanks I'll try there :)

Best Markus Thielmann (thielmann) said : #3

Would you mind closing the question in the next days? Thanks!

N3rz (nerzhul-de) said : #4

Thanks Markus Thielmann, that solved my question.