Name
MotionNotify — xmotion
When Generated
A MotionNotify event reports that the user
moved the pointer or that a program warped the pointer to a new
position within a single window.
Select With
This event is selected with
ButtonMotionMask,
Button1MotionMask,
Button2MotionMask,
Button3MotionMask,
Button4MotionMask,
Button5MotionMask,
PointerMotionHintMask, and
PointerMotionMask. These masks determine the
specific conditions under which the event is generated.
See 8.3.3.3 The Pointer Motion Masks for a description of selecting button events.
XEvent Structure Name
typedef union _XEvent {
...
XMotionEvent xmotion;
...
} XEvent;Event Structure
typedef struct {
int type; /* of event */
unsigned long serial; /* # of last request processed by server */
Bool send_event; /* True if this came from SendEvent request */
Display *display; /* Display the event was read from */
Window window; /* event window it is reported relative to */
Window root; /* root window that the event occurred on */
Window subwindow; /* child window */
Time time; /* milliseconds */
int x, y; /* pointer coordinates relative to receiving
* window */
int x_root, y_root; /* coordinates relative to root */
unsigned int state; /* button and modifier key mask */
char is_hint; /* is this a motion hint */
Bool same_screen; /* same screen flag */
} XMotionEvent;
typedef XMotionEvent XPointerMovedEvent;Event Structure Members
subwindowIf the source window is the child of the receiving window, then the
subwindowmember is set to the ID ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access