Action generated when the mouse moves.


int function(Ihandle *ih, int x, int y, char *status); [in C]
ih:motion_cb(x, y: number, status: string) -> (ret: number) [in Lua]

ih: identifier of the element that activated the event.
x, y: position in the canvas where the event has occurred, in pixels.
status: status of mouse buttons and certain keyboard keys at the moment the event was generated. The same macros used for BUTTON_CB can be used for this status.


Between press and release all mouse events are redirected only to this control, even if the cursor moves outside the element. So the BUTTON_CB callback when released and the MOTION_CB callback can be called with coordinates outside the element rectangle.


IupCanvas, IupGLCanvas