Hello Philipp,
You can do this this by using an event_handler function which updates
two variables in the main workspace:
function event_handler_function(h, x, y, ibut)
if ibut == -1
[MOUSE_X,MOUSE_Y]=resume(x,y);
end
end
gcf().event_handler = "event_handler_function";
gcf().event_handler_enable = "on";
MOUSE_X and MOUSE_Y will always contain the current coordinates of the
mouse pointer
S.
Le 09/06/2019 à 21:26, P M a écrit :
Dear Experts,
is there a way to get the mouse position without waiting for an event?
With xgetmouse and xclick it is possible to get the mouse position,
but the functions return the position only if there was an event.
So the functions wait until the mouse is moved/clicked etc.
I'ld like to get the mouse position even when the mouse is not
moved/clicked etc.
Thank you,
Philipp
_______________________________________________
users mailing list
users@lists.scilab.org
https://antispam.utc.fr/proxy/1/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/lists.scilab.org/mailman/listinfo/users
--
Stéphane Mottelet
Ingénieur de recherche
EA 4297 Transformations Intégrées de la Matière Renouvelable
Département Génie des Procédés Industriels
Sorbonne Universités - Université de Technologie de Compiègne
CS 60319, 60203 Compiègne cedex
Tel : +33(0)344234688
http://www.utc.fr/~mottelet
_______________________________________________
users mailing list
users@lists.scilab.org
http://lists.scilab.org/mailman/listinfo/users