[GRASS-dev] function to get mouse position

Zoltan zoltans at geograph.co.za
Wed Jul 21 08:07:27 PDT 2021


Hi Devs,

Is there a function that will return the coordinates of the mouse 
pointer, if it is inside a graphics window?
This on mouse-click.

Ideally the return value would be:   button,x,y(,z)

Even more ideally, if mouse hovers inside a graphics window, and a 
keyboard key is press (say the letter 'k'), then the return value would 
be "k,x,y(,z)"

If any of you are old enough to have used Genamap, then I am looking to 
emulate its 'gloc' command.

TIA,
Zoltan

-- 

=============================================
Zoltan Szecsei GPrGISc 0031
Geograph (Pty) Ltd.
GIS and Photogrammetric Services

Cape Town, South Africa.

Mobile: +27-83-6004028 (Signal, not WhatsApp)
www.geograph.co.za
=============================================



More information about the grass-dev mailing list