grab_pointer/9
grab_pointer(+Window, +OwnerEvents, +EventsMask, +PointerMode, +KeyboardMode, +WindowConfine, +Cursor, +Time, -GrabStatus)
This predicate actively grabs control of the pointer and
generates enter_notify
and leave_notify
events as
appropriate.
Window is the ProXL window to which events will be reported while the grab is in effect.
OwnerEvents is one of:
true
false
EventsMask is an integer bitmask specifying the events that are selected and should be reported to the client. The valid event mask names are:
button_press
button_release
enter_window
leave_window
pointer_motion
pointer_motion_hint
button1_motion
button2_motion
button3_motion
button4_motion
button5_motion
button_motion
keymap_state
The predicate event_list_mask/2
is useful to translate between
event mask names and integer bitmasks.
PointerMode controls further processing of pointer events:
async
sync
allow_events/[1,2,3]
or the pointer grab is released.
KeyboardMode controls further processing of keyboard events:
async
sync
allow_events/[1,2,3]
or the keyboard grab is released.
WindowConfine is the ProXL window to which the pointer will be
confined while the grab is in effect, or the atom none
.
Cursor is the ProXL cursor to be displayed during the grab, or
the atom none
.
Time is a timestamp in milliseconds (from an event) or the atom
current_time
.
GrabStatus is unified by grab_pointer/9
with one of:
success
already_grabbed
invalid_time
not_viewable
frozen