IUP_MOTION_CB

IUP - Portable User Interface

MOTION_CB

Action generated when the mouse moves.

Callback

int function(Ihandle *self, int x, int y, char *r); [in C]
elem:motion(x, y: number, r: string) -> (ret: number) [in IupLua3]
elem:motion_cb(x, y: number, r: string) -> (ret: number) [in IupLua5]

self: identifier of the canvas that activated the function's execution.
x, y: position in the canvas where the event has occurred, in pixels.
r: status of mouse buttons and certain keyboard keys at the moment the event was generated. The following macros must be used for verification:

isshift(r)
iscontrol(r)
isbutton1(r)
isbutton2(r)
isbutton3(r)
isdouble(r)

Affects

IupCanvas