


XChangeWindowAttributes(3X11)			XChangeWindowAttributes(3X11)
X11R5									X11R5



NAME
  XChangeWindowAttributes, XSetWindowBackground, XSetWindowBackgroundPixmap,
  XSetWindowBorder, XSetWindowBorderPixmap, XSetWindowColormap - change	win-
  dow attributes

SYNTAX
  XChangeWindowAttributes(_d_i_s_p_l_a_y, _w, _v_a_l_u_e_m_a_s_k, _a_t_t_r_i_b_u_t_e_s)
	Display	*_d_i_s_p_l_a_y;
	Window _w;
	unsigned long _v_a_l_u_e_m_a_s_k;
	XSetWindowAttributes *_a_t_t_r_i_b_u_t_e_s;

  XSetWindowBackground(_d_i_s_p_l_a_y,	_w, _b_a_c_k_g_r_o_u_n_d__p_i_x_e_l)
	Display	*_d_i_s_p_l_a_y;
	Window _w;
	unsigned long _b_a_c_k_g_r_o_u_n_d__p_i_x_e_l;

  XSetWindowBackgroundPixmap(_d_i_s_p_l_a_y, _w, _b_a_c_k_g_r_o_u_n_d__p_i_x_m_a_p)
	Display	*_d_i_s_p_l_a_y;
	Window _w;
	Pixmap _b_a_c_k_g_r_o_u_n_d__p_i_x_m_a_p;

  XSetWindowBorder(_d_i_s_p_l_a_y, _w, _b_o_r_d_e_r__p_i_x_e_l)
	Display	*_d_i_s_p_l_a_y;
	Window _w;
	unsigned long _b_o_r_d_e_r__p_i_x_e_l;

  XSetWindowBorderPixmap(_d_i_s_p_l_a_y, _w, _b_o_r_d_e_r__p_i_x_m_a_p)
	Display	*_d_i_s_p_l_a_y;
	Window _w;
	Pixmap _b_o_r_d_e_r__p_i_x_m_a_p;

  XSetWindowColormap(_d_i_s_p_l_a_y, _w, _c_o_l_o_r_m_a_p)
	Display	*_d_i_s_p_l_a_y;
	Window _w;
	Colormap _c_o_l_o_r_m_a_p;

ARGUMENTS

  _a_t_t_r_i_b_u_t_e_s
	    Specifies the structure from which the values (as specified	by
	    the	value mask) are	to be taken.  The value	mask should have the
	    appropriate	bits set to indicate which attributes have been	set
	    in the structure.

  _b_a_c_k_g_r_o_u_n_d__p_i_x_e_l
	    Specifies the pixel	that is	to be used for the background.

  _b_a_c_k_g_r_o_u_n_d__p_i_x_m_a_p
	    Specifies the background pixmap, _P_a_r_e_n_t_R_e_l_a_t_i_v_e, or	_N_o_n_e.

  _b_o_r_d_e_r__p_i_x_e_l
	    Specifies the entry	in the colormap.

  _b_o_r_d_e_r__p_i_x_m_a_p
	    Specifies the border pixmap	or _C_o_p_y_F_r_o_m_P_a_r_e_n_t.

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

  _v_a_l_u_e_m_a_s_k Specifies which window attributes are defined in the attributes
	    argument.  This mask is the	bitwise	inclusive OR of	the valid
	    attribute mask bits.  If valuemask is zero,	the attributes are
	    ignored and	are not	referenced.

  _w	    Specifies the window.

  _c_o_l_o_r_m_a_p  Specifies the colormap.

DESCRIPTION
  Depending on the valuemask, the _X_C_h_a_n_g_e_W_i_n_d_o_w_A_t_t_r_i_b_u_t_e_s function uses	the
  window attributes in the _X_S_e_t_W_i_n_d_o_w_A_t_t_r_i_b_u_t_e_s	structure to change the
  specified window attributes.	Changing the background	does not cause the
  window contents to be	changed.  To repaint the window	and its	background,
  use _X_C_l_e_a_r_W_i_n_d_o_w.  Setting the border	or changing the	background such	that
  the border tile origin changes causes	the border to be repainted.  Changing
  the background of a root window to _N_o_n_e or _P_a_r_e_n_t_R_e_l_a_t_i_v_e restores the
  default background pixmap.  Changing the border of a root window to _C_o_p_y_-
  _F_r_o_m_P_a_r_e_n_t restores the default border pixmap.  Changing the win-gravity
  does not affect the current position of the window.  Changing	the backing-
  store	of an obscured window to _W_h_e_n_M_a_p_p_e_d or _A_l_w_a_y_s, or changing the
  backing-planes, backing-pixel, or save-under of a mapped window may have no
  immediate effect.  Changing the colormap of a	window (that is, defining a
  new map, not changing	the contents of	the existing map) generates a _C_o_l_o_r_-
  _m_a_p_N_o_t_i_f_y event.  Changing the colormap of a visible window may have no
  immediate effect on the screen because the map may not be installed (see
  _X_I_n_s_t_a_l_l_C_o_l_o_r_m_a_p).  Changing the cursor of a root window to _N_o_n_e restores
  the default cursor.  Whenever	possible, you are encouraged to	share color-
  maps.

  Multiple clients can select input on the same	window.	Their event masks are
  maintained separately.  When an event	is generated, it is reported to	all
  interested clients. However, only one	client at a time can select for	_S_u_b_-
  _s_t_r_u_c_t_u_r_e_R_e_d_i_r_e_c_t_M_a_s_k, _R_e_s_i_z_e_R_e_d_i_r_e_c_t_M_a_s_k, and _B_u_t_t_o_n_P_r_e_s_s_M_a_s_k.  If a
  client attempts to select any	of these event masks and some other client
  has already selected one, a _B_a_d_A_c_c_e_s_s	error results.	There is only one
  do-not-propagate-mask	for a window, not one per client.

  _X_C_h_a_n_g_e_W_i_n_d_o_w_A_t_t_r_i_b_u_t_e_s can generate _B_a_d_A_c_c_e_s_s, _B_a_d_C_o_l_o_r, _B_a_d_C_u_r_s_o_r, _B_a_d_-
  _M_a_t_c_h, _B_a_d_P_i_x_m_a_p, _B_a_d_V_a_l_u_e, and _B_a_d_W_i_n_d_o_w errors.

  The _X_S_e_t_W_i_n_d_o_w_B_a_c_k_g_r_o_u_n_d function sets the background	of the window to the
  specified pixel value.  Changing the background does not cause the window
  contents to be changed.  _X_S_e_t_W_i_n_d_o_w_B_a_c_k_g_r_o_u_n_d	uses a pixmap of undefined
  size filled with the pixel value you passed.	If you try to change the
  background of	an _I_n_p_u_t_O_n_l_y window, a _B_a_d_M_a_t_c_h	error results.

  _X_S_e_t_W_i_n_d_o_w_B_a_c_k_g_r_o_u_n_d can generate _B_a_d_M_a_t_c_h and _B_a_d_W_i_n_d_o_w errors.

  The _X_S_e_t_W_i_n_d_o_w_B_a_c_k_g_r_o_u_n_d_P_i_x_m_a_p function sets the background pixmap of	the
  window to the	specified pixmap.  The background pixmap can immediately be
  freed	if no further explicit references to it	are to be made.	 If _P_a_r_e_n_t_R_e_-
  _l_a_t_i_v_e is specified, the background pixmap of	the window's parent is used,
  or on	the root window, the default background	is restored.  If you try to
  change the background	of an _I_n_p_u_t_O_n_l_y	window,	a _B_a_d_M_a_t_c_h error results.  If
  the background is set	to _N_o_n_e, the window has	no defined background.

  _X_S_e_t_W_i_n_d_o_w_B_a_c_k_g_r_o_u_n_d_P_i_x_m_a_p can generate _B_a_d_M_a_t_c_h, _B_a_d_P_i_x_m_a_p, and _B_a_d_W_i_n_d_o_w
  errors.

  The _X_S_e_t_W_i_n_d_o_w_B_o_r_d_e_r function	sets the border	of the window to the pixel
  value	you specify.  If you attempt to	perform	this on	an _I_n_p_u_t_O_n_l_y window,
  a _B_a_d_M_a_t_c_h error results.


  _X_S_e_t_W_i_n_d_o_w_B_o_r_d_e_r can generate	_B_a_d_M_a_t_c_h and _B_a_d_W_i_n_d_o_w errors.

  The _X_S_e_t_W_i_n_d_o_w_B_o_r_d_e_r_P_i_x_m_a_p function sets the border pixmap of	the window to
  the pixmap you specify.  The border pixmap can be freed immediately if no
  further explicit references to it are	to be made.  If	you specify _C_o_p_y_F_r_o_m_-
  _P_a_r_e_n_t, a copy of the	parent window's	border pixmap is used.	If you
  attempt to perform this on an	_I_n_p_u_t_O_n_l_y window, a _B_a_d_M_a_t_c_h error results.

  _X_S_e_t_W_i_n_d_o_w_B_o_r_d_e_r_P_i_x_m_a_p can generate _B_a_d_M_a_t_c_h,	_B_a_d_P_i_x_m_a_p, and _B_a_d_W_i_n_d_o_w
  errors.

  The _X_S_e_t_W_i_n_d_o_w_C_o_l_o_r_m_a_p function sets the specified colormap of the speci-
  fied window.	The colormap must have the same	visual type as the window, or
  a _B_a_d_M_a_t_c_h error results.

  _X_S_e_t_W_i_n_d_o_w_C_o_l_o_r_m_a_p can generate _B_a_d_C_o_l_o_r, _B_a_d_M_a_t_c_h, and _B_a_d_W_i_n_d_o_w errors.

DIAGNOSTICS

  _B_a_d_A_c_c_e_s_s A client attempted to free a color map entry that it did not
	    already allocate.

  _B_a_d_A_c_c_e_s_s A client attempted to store	into a read-only color map entry.

  _B_a_d_C_o_l_o_r  A value for	a Colormap argument does not name a defined Colormap.

  _B_a_d_C_u_r_s_o_r A value for	a Cursor argument does not name	a defined Cursor.

  _B_a_d_M_a_t_c_h  Some argument or pair of arguments has the correct type and	range
	    but	fails to match in some other way required by the request.

  _B_a_d_M_a_t_c_h  An _I_n_p_u_t_O_n_l_y window	locks this attribute.

  _B_a_d_P_i_x_m_a_p A value for	a Pixmap argument does not name	a defined Pixmap.

  _B_a_d_V_a_l_u_e  Some numeric value falls outside the range of values accepted by
	    the	request.  Unless a specific range is specified for an argu-
	    ment, the full range defined by the	argument's type	is accepted.
	    Any	argument defined as a set of alternatives can generate this
	    error.

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

SEE ALSO
  XConfigureWindow(3X11), XCreateWindow(3X11), XDestroyWindow(3X11),
  XInstallColormap(3X11), XMapWindow(3X11), XRaiseWindow(3X11),
  XUnmapWindow(3X11)
  _X_l_i_b - _C _L_a_n_g_u_a_g_e _X _I_n_t_e_r_f_a_c_e	delim off


















