home *** CD-ROM | disk | FTP | other *** search
/ Geek Gadgets 1 / ADE-1.bin / ade-bin / x11r6.1 / man / cat3 / xgrabbutton.0 < prev    next >
Encoding:
Text File  |  1996-10-17  |  7.0 KB  |  199 lines

  1.  
  2.  
  3.  
  4. XGrabButton(3X11)      XLIB FUNCTIONS    XGrabButton(3X11)
  5.  
  6.  
  7. NNAAMMEE
  8.        XGrabButton, XUngrabButton - grab pointer buttons
  9.  
  10. SSYYNNTTAAXX
  11.        XGrabButton(_d_i_s_p_l_a_y, _b_u_t_t_o_n, _m_o_d_i_f_i_e_r_s, _g_r_a_b___w_i_n_d_o_w,
  12.        _o_w_n_e_r___e_v_e_n_t_s, _e_v_e_n_t___m_a_s_k,
  13.                _p_o_i_n_t_e_r___m_o_d_e, _k_e_y_b_o_a_r_d___m_o_d_e, _c_o_n_f_i_n_e___t_o,
  14.        _c_u_r_s_o_r)
  15.          Display *_d_i_s_p_l_a_y;
  16.          unsigned int _b_u_t_t_o_n;
  17.          unsigned int _m_o_d_i_f_i_e_r_s;
  18.          Window _g_r_a_b___w_i_n_d_o_w;
  19.          Bool _o_w_n_e_r___e_v_e_n_t_s;
  20.          unsigned int _e_v_e_n_t___m_a_s_k;
  21.          int _p_o_i_n_t_e_r___m_o_d_e, _k_e_y_b_o_a_r_d___m_o_d_e;
  22.          Window _c_o_n_f_i_n_e___t_o;
  23.          Cursor _c_u_r_s_o_r;
  24.  
  25.        XUngrabButton(_d_i_s_p_l_a_y, _b_u_t_t_o_n, _m_o_d_i_f_i_e_r_s, _g_r_a_b___w_i_n_d_o_w)
  26.          Display *_d_i_s_p_l_a_y;
  27.          unsigned int _b_u_t_t_o_n;
  28.          unsigned int _m_o_d_i_f_i_e_r_s;
  29.          Window _g_r_a_b___w_i_n_d_o_w;
  30.  
  31. AARRGGUUMMEENNTTSS
  32.        _b_u_t_t_o_n     Specifies the pointer button that is to be
  33.          grabbed or released or _A_n_y_B_u_t_t_o_n.
  34.  
  35.        _c_o_n_f_i_n_e___t_o
  36.          Specifies the window to confine the pointer in
  37.          or _N_o_n_e.
  38.  
  39.        _c_u_r_s_o_r     Specifies the cursor that is to be displayed or
  40.          _N_o_n_e.
  41.  
  42.        _d_i_s_p_l_a_y     Specifies the connection to the X server.
  43.  
  44.        _e_v_e_n_t___m_a_s_k
  45.          Specifies which pointer events are reported to
  46.          the client.  The mask is the bitwise inclusive
  47.          OR of the valid pointer event mask bits.
  48.  
  49.        _g_r_a_b___w_i_n_d_o_w
  50.          Specifies the grab window.
  51.  
  52.        _k_e_y_b_o_a_r_d___m_o_d_e
  53.          Specifies further processing of keyboard events.
  54.          You can pass _G_r_a_b_M_o_d_e_S_y_n_c or _G_r_a_b_M_o_d_e_A_s_y_n_c.
  55.  
  56.        _m_o_d_i_f_i_e_r_s Specifies the set of keymasks or _A_n_y_M_o_d_i_f_i_e_r.
  57.          The mask is the bitwise inclusive OR of the
  58.          valid keymask bits.
  59.  
  60.  
  61.  
  62.  
  63.  
  64. X Version 11           Release 6.1                1
  65.  
  66.  
  67.  
  68.  
  69.  
  70. XGrabButton(3X11)      XLIB FUNCTIONS    XGrabButton(3X11)
  71.  
  72.  
  73.        _o_w_n_e_r___e_v_e_n_t_s
  74.          Specifies a Boolean value that indicates whether
  75.          the pointer events are to be reported as usual
  76.          or reported with respect to the grab window if
  77.          selected by the event mask.
  78.  
  79.        _p_o_i_n_t_e_r___m_o_d_e
  80.          Specifies further processing of pointer events.
  81.          You can pass _G_r_a_b_M_o_d_e_S_y_n_c or _G_r_a_b_M_o_d_e_A_s_y_n_c.
  82.  
  83. DDEESSCCRRIIPPTTIIOONN
  84.        The _X_G_r_a_b_B_u_t_t_o_n function establishes a passive grab.  In
  85.        the future, the pointer is actively grabbed (as for
  86.        _X_G_r_a_b_P_o_i_n_t_e_r), the last-pointer-grab time is set to the
  87.        time at which the button was pressed (as transmitted in
  88.        the _B_u_t_t_o_n_P_r_e_s_s event), and the _B_u_t_t_o_n_P_r_e_s_s event is
  89.        reported if all of the following conditions are true:
  90.  
  91.        +o    The pointer is not grabbed, and the specified button
  92.         is logically pressed when the specified modifier keys
  93.         are logically down, and no other buttons or modifier
  94.         keys are logically down.
  95.  
  96.        +o    The grab_window contains the pointer.
  97.  
  98.        +o    The confine_to window (if any) is viewable.
  99.  
  100.        +o    A passive grab on the same button/key combination
  101.         does not exist on any ancestor of grab_window.
  102.  
  103.        The interpretation of the remaining arguments is as for
  104.        _X_G_r_a_b_P_o_i_n_t_e_r.  The active grab is terminated automatically
  105.        when the logical state of the pointer has all buttons
  106.        released (independent of the state of the logical modifier
  107.        keys).
  108.  
  109.        Note that the logical state of a device (as seen by client
  110.        applications) may lag the physical state if device event
  111.        processing is frozen.
  112.  
  113.        This request overrides all previous grabs by the same
  114.        client on the same button/key combinations on the same
  115.        window.    A modifiers of _A_n_y_M_o_d_i_f_i_e_r is equivalent to issu-
  116.        ing the grab request for all possible modifier combina-
  117.        tions (including the combination of no modifiers).  It is
  118.        not required that all modifiers specified have currently
  119.        assigned KeyCodes.  A button of _A_n_y_B_u_t_t_o_n is equivalent to
  120.        issuing the request for all possible buttons.  Otherwise,
  121.        it is not required that the specified button currently be
  122.        assigned to a physical button.
  123.  
  124.        If some other client has already issued a _X_G_r_a_b_B_u_t_t_o_n with
  125.        the same button/key combination on the same window, a
  126.        _B_a_d_A_c_c_e_s_s error results.     When using _A_n_y_M_o_d_i_f_i_e_r or
  127.  
  128.  
  129.  
  130. X Version 11           Release 6.1                2
  131.  
  132.  
  133.  
  134.  
  135.  
  136. XGrabButton(3X11)      XLIB FUNCTIONS    XGrabButton(3X11)
  137.  
  138.  
  139.        _A_n_y_B_u_t_t_o_n, the request fails completely, and a _B_a_d_A_c_c_e_s_s
  140.        error results (no grabs are established) if there is a
  141.        conflicting grab for any combination.  _X_G_r_a_b_B_u_t_t_o_n has no
  142.        effect on an active grab.
  143.  
  144.        _X_G_r_a_b_B_u_t_t_o_n can generate _B_a_d_C_u_r_s_o_r, _B_a_d_V_a_l_u_e, and _B_a_d_W_i_n_-
  145.        _d_o_w errors.
  146.  
  147.        The _X_U_n_g_r_a_b_B_u_t_t_o_n function releases the passive button/key
  148.        combination on the specified window if it was grabbed by
  149.        this client.  A modifiers of _A_n_y_M_o_d_i_f_i_e_r is equivalent to
  150.        issuing the ungrab request for all possible modifier com-
  151.        binations, including the combination of no modifiers.  A
  152.        button of _A_n_y_B_u_t_t_o_n is equivalent to issuing the request
  153.        for all possible buttons.  _X_U_n_g_r_a_b_B_u_t_t_o_n has no effect on
  154.        an active grab.
  155.  
  156.        _X_U_n_g_r_a_b_B_u_t_t_o_n can generate _B_a_d_V_a_l_u_e and _B_a_d_W_i_n_d_o_w errors.
  157.  
  158. DDIIAAGGNNOOSSTTIICCSS
  159.        _B_a_d_C_u_r_s_o_r A value for a Cursor argument does not name a
  160.          defined Cursor.
  161.  
  162.        _B_a_d_V_a_l_u_e     Some numeric value falls outside the range of
  163.          values accepted by the request.  Unless a spe-
  164.          cific range is specified for an argument, the
  165.          full range defined by the argument's type is
  166.          accepted.  Any argument defined as a set of
  167.          alternatives can generate this error.
  168.  
  169.        _B_a_d_W_i_n_d_o_w A value for a Window argument does not name a
  170.          defined Window.
  171.  
  172. SSEEEE AALLSSOO
  173.        XAllowEvents(3X11), XGrabPointer(3X11), XGrabKey(3X11),
  174.        XGrabKeyboard(3X11),
  175.        _X_l_i_b _- _C _L_a_n_g_u_a_g_e _X _I_n_t_e_r_f_a_c_e
  176.  
  177.  
  178.  
  179.  
  180.  
  181.  
  182.  
  183.  
  184.  
  185.  
  186.  
  187.  
  188.  
  189.  
  190.  
  191.  
  192.  
  193.  
  194.  
  195.  
  196. X Version 11           Release 6.1                3
  197.  
  198.  
  199.