5.4.2 MouseButtonEvent object

The MouseButtonEvent class is passed as argument whenever a mouse button was pressed or released.

class MouseButtonEvent( button, x, y, x0, y0)

button is the mouse button number (1 = left button, 2 = middle button, 3 = right button).

x/y is the pixel position of the mouse where 0/0 is the upper left corner.

x0/y0 is the normalized position of the mouse where each component lies in the range [0,1).