Re: how to move mouse?



Hello,

You should try to have a look at the Gdk type of event : GDK_MOTION_NOTIFY
You have to set the bit of the events the object (window...) can receive via
GDK_POINTER_MOTION_MASK. In that case the X Server is generating as many
events as he can about the movement of the mouse (see the doc for more
details) You can use also the GDK_POINTER_MOTION_HINT_MASK and then use
gdk_window_get_pointer to get the X Server generating an event about the
moving of the mouse. (in this event you'll get the position of the mouse)
But I don't know how to tell the mouse to move to a certain position.
If your aim is to let the mouse inside the borders of an object, you can use
gdk_pointer_grab...


Best regards,
---
Jean-Christophe Berthon

Cap Gemini -- Ernst & Young
France
Skill IS -- Image Quality
Email: Jean-Christophe Berthon cgey com
Tel: (+33) 561 31 6671


----- Original Message -----
From: "huzheng" <forlinux 263 net>
To: <gtk-app-devel-list gnome org>
Sent: Monday, March 04, 2002 11:56 AM
Subject: how to move mouse?


i want to get mouse's position and move it to the other position.
can anyone tell me how to do this useing gtk or gdk.

_______________________________________________
gtk-app-devel-list mailing list
gtk-app-devel-list gnome org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]