


XQueryPointer(3X11)					  XQueryPointer(3X11)
X11R5									X11R5



NAME
  XQueryPointer	- get pointer coordinates

SYNTAX
  Bool XQueryPointer(_d_i_s_p_l_a_y, _w, _r_o_o_t__r_e_t_u_r_n, _c_h_i_l_d__r_e_t_u_r_n, _r_o_o_t__x__r_e_t_u_r_n,
  _r_o_o_t__y__r_e_t_u_r_n,
		       _w_i_n__x__r_e_t_u_r_n, _w_i_n__y__r_e_t_u_r_n, _m_a_s_k__r_e_t_u_r_n)
	Display	*_d_i_s_p_l_a_y;
	Window _w;
	Window *_r_o_o_t__r_e_t_u_r_n, *_c_h_i_l_d__r_e_t_u_r_n;
	int *_r_o_o_t__x__r_e_t_u_r_n, *_r_o_o_t__y__r_e_t_u_r_n;
	int *_w_i_n__x__r_e_t_u_r_n, *_w_i_n__y__r_e_t_u_r_n;
	unsigned int *_m_a_s_k__r_e_t_u_r_n;

ARGUMENTS

  _c_h_i_l_d__r_e_t_u_r_n
	    Returns the	child window that the pointer is located in, if	any.

  _d_i_s_p_l_a_y   Specifies the connection to	the X server.

  _m_a_s_k__r_e_t_u_r_n
	    Returns the	current	state of the modifier keys and pointer but-
	    tons.

  _r_o_o_t__r_e_t_u_r_n
	    Returns the	root window that the pointer is	in.

  _r_o_o_t__x__r_e_t_u_r_n
  _r_o_o_t__y__r_e_t_u_r_n
	    Return the pointer coordinates relative to the root	window's ori-
	    gin.

  _w	    Specifies the window.

  _w_i_n__x__r_e_t_u_r_n
  _w_i_n__y__r_e_t_u_r_n
	    Return the pointer coordinates relative to the specified window.

DESCRIPTION
  The _X_Q_u_e_r_y_P_o_i_n_t_e_r function returns the root window the pointer is logically
  on and the pointer coordinates relative to the root window's origin.	If
  _X_Q_u_e_r_y_P_o_i_n_t_e_r	returns	_F_a_l_s_e, the pointer is not on the same screen as	the
  specified window, and	_X_Q_u_e_r_y_P_o_i_n_t_e_r returns _N_o_n_e to child_return and zero
  to win_x_return and win_y_return.  If	_X_Q_u_e_r_y_P_o_i_n_t_e_r returns _T_r_u_e, the
  pointer coordinates returned to win_x_return and win_y_return	are relative
  to the origin	of the specified window.  In this case,	_X_Q_u_e_r_y_P_o_i_n_t_e_r returns
  the child that contains the pointer, if any, or else _N_o_n_e to child_return.

  _X_Q_u_e_r_y_P_o_i_n_t_e_r	returns	the current logical state of the keyboard buttons and
  the modifier keys in mask_return.  It	sets mask_return to the	bitwise
  inclusive OR of one or more of the button or modifier	key bitmasks to	match
  the current state of the mouse buttons and the modifier keys.

  _X_Q_u_e_r_y_P_o_i_n_t_e_r	can generate a _B_a_d_W_i_n_d_o_w error.



DIAGNOSTICS

  _B_a_d_W_i_n_d_o_w A value for	a Window argument does not name	a defined Window.

SEE ALSO
  XGetWindowAttributes(3X11), XQueryTree(3X11)
  _X_l_i_b - _C _L_a_n_g_u_a_g_e _X _I_n_t_e_r_f_a_c_e



























































