Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ XtGrabButto(3) — OSF1 1.0

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

XtAddGrab(1)

XtGrabKey(1)

XtGrabKeyboard(1)

XtGrabPointer(1)

XtRegisterGrabAction(1)

XtUngrabButton(1)

XtUngrabKey(1)

XtUngrabKeyboard(1)

XtUngrabPointer(1)

 

Name

XtGrabButton — passively grab a single pointer button. 

Synopsis

void XtGrabButton(widget, button, modifiers, owner_events, event_mask, pointer_mode, keyboard_mode, confine_to, cursor)

      Widget widget;
      int button;
      Modifiers modifiers;
      Boolean owner_events;
      unsigned int event_mask;
      int pointer_mode, keyboard_mode;
      Window confine_to;
      Cursor cursor;

Arguments

widgetSpecifies the widget in whose window the button is to be grabbed. 

buttonSpecifies the mouse button.  May be Button1, Button2, Button3, Button4, Button5, or AnyButton.  The constant AnyButton is equivalent to issuing the grab request for all possible buttons.  The button symbols cannot be ORed. 

modifiersSpecifies a set of keymasks.  This is a bitwise OR of one or more of the following symbols: ShiftMask, LockMask, ControlMask, Mod1Mask, Mod2Mask, Mod3Mask, Mod4Mask, Mod5Mask, or AnyModifier.  AnyModifier is equivalent to issuing the grab key request for all possible modifier combinations (including no modifiers). 

grab_window
Specifies the ID of the window you want to the grab to occur in.

owner_events
Specifies a Boolean value of either True or False.  See Description below. 

event_mask
Specifies the event mask to take effect during the grab. This mask is the bitwise OR of one or more of the event masks listed on the reference page for XSelectInput. 

pointer_mode
Controls processing of pointer events during the grab. Pass one of these constants: GrabModeSync or GrabModeAsync. 

keyboard_mode
Controls processing of keyboard events during the grab. Pass one of these constants: GrabModeSync or GrabModeAsync. 

confine_to
Specifies the ID of the window to confine the pointer. One possible value is the constant None, in which case the pointer is not confined to any window. 

cursorSpecifies the cursor to be displayed during the grab.  One possible value you can pass is the constant None. 

Description

XtGrabButton calls XGrabButton specifying the widget’s window as the grab window, if the widget is realized.  The remaining arguments are exactly as for XGrabButton.  If the widget is not realized, or is later unrealized, the call to XGrabButton will be performed (again) when the widget is realized and its window becomes mapped.  In the future, if a ButtonPress event matching the specified button and modifiers (which may be AnyButton and/or AnyModifier, respectively) arrives for the widget’s window and there is a modal cascade and the widget is not in the active subset of the cascade and the pointer was not previously grabbed, then the Intrinsics will call XtUngrabPointer with the timestamp from the ButtonPress event. 

See Also

XtAddGrab(1), XtGrabKey(1), XtGrabKeyboard(1), XtGrabPointer(1), XtRegisterGrabAction(1), XtUngrabButton(1), XtUngrabKey(1), XtUngrabKeyboard(1), XtUngrabPointer(1). 

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026