Mouse
(require (planet "mouse.ss" ("kazzmir" "allegro.plt")))
Note that it is usually best to prefix the mouse import because it exposes common names. I usually use this:(require (prefix mouse- (planet "mouse.ss" ("kazzmir" "allegro.plt"))))
Function list
left-click?
right-click?
x
y
get-mickeys
top
procedure: (left-click?) :: boolean
Returns #t if the left mouse button is being clicked, otherwise #f.
top
procedure: (right-click?) :: boolean
Returns #t if the right mouse button is being clicked, otherwise #f.
top
procedure: (x) :: num
Returns the current x coordinate of the mouse on the graphics context.
top
procedure: (y) :: num
Returns the current y coordinate of the mouse on the graphics context.
top
procedure: (get-mickeys) :: (values dx dy)
Returns two integers representing how far the mouse has just moved.