Y
ycyclop
Hi,
I'm trying to find the coordiantes of a mouse event in the window
position. Everyone wrote on privious letters:
Use the GetViewRect, GetWindowRect, do the scaling and you have your
answer.
All that is true ONLY if there are no rulers and no scrollbars visible
in the control.
GetWindowRect gives the whole window rect, including all rules and
scrollbars.
GetViewRect gives the correct visible drawing area rectangle.
So scaling between these two is wrong. they do not relate to the same
rectangle.
Is there a way I can get the drawing area window rect and from there I
can scale and find the mouse position?
Thank you
-- ycyclop
I'm trying to find the coordiantes of a mouse event in the window
position. Everyone wrote on privious letters:
Use the GetViewRect, GetWindowRect, do the scaling and you have your
answer.
All that is true ONLY if there are no rulers and no scrollbars visible
in the control.
GetWindowRect gives the whole window rect, including all rules and
scrollbars.
GetViewRect gives the correct visible drawing area rectangle.
So scaling between these two is wrong. they do not relate to the same
rectangle.
Is there a way I can get the drawing area window rect and from there I
can scale and find the mouse position?
Thank you
-- ycyclop