


XSetCommand(3X11)					    XSetCommand(3X11)
X11R5									X11R5



NAME
  XSetCommand, XGetCommand - set or read a window's WM_COMMAND property

SYNTAX
  XSetCommand(_d_i_s_p_l_a_y, _w, _a_r_g_v,	_a_r_g_c)
	Display	*_d_i_s_p_l_a_y;
	Window _w;
	char **_a_r_g_v;
	int _a_r_g_c;

  Status XGetCommand(_d_i_s_p_l_a_y, _w, _a_r_g_v__r_e_t_u_r_n, _a_r_g_c__r_e_t_u_r_n)
	Display	*_d_i_s_p_l_a_y;
	Window _w;
	char ***_a_r_g_v__r_e_t_u_r_n;
	int *_a_r_g_c__r_e_t_u_r_n;

ARGUMENTS

  _a_r_g_c	    Specifies the number of arguments.

  _a_r_g_c__r_e_t_u_r_n
	    Returns the	number of arguments returned.

  _a_r_g_v	    Specifies the application's	argument list.

  _a_r_g_v__r_e_t_u_r_n
	    Returns the	application's argument list.

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

  _w	    Specifies the window.

DESCRIPTION
  The _X_S_e_t_C_o_m_m_a_n_d function sets	the command and	arguments used to invoke the
  application.	(Typically, argv is the	argv array of your main	program.) If
  the strings are not in the Host Portable Character Encoding the result is
  implementation dependent.

  _X_S_e_t_C_o_m_m_a_n_d can generate _B_a_d_A_l_l_o_c and	_B_a_d_W_i_n_d_o_w errors.

  The _X_G_e_t_C_o_m_m_a_n_d function reads the WM_COMMAND	property from the specified
  window and returns a string list.  If	the WM_COMMAND property	exists,	it is
  of type STRING and format 8.	If sufficient memory can be allocated to con-
  tain the string list,	_X_G_e_t_C_o_m_m_a_n_d fills in the argv_return and argc_return
  arguments and	returns	a nonzero status.  Otherwise, it returns a zero
  status.  If the data returned	by the server is in the	Latin Portable Char-
  acter	Encoding, then the returned strings are	in the Host Portable Charac-
  ter Encoding.	 Otherwise, the	result is implementation dependent.  To	free
  the memory allocated to the string list, use _X_F_r_e_e_S_t_r_i_n_g_L_i_s_t.



PROPERTIES

  WM_COMMAND
	    The	command	and arguments, null-separated, used to invoke the
	    application.

DIAGNOSTICS

  _B_a_d_A_l_l_o_c  The	server failed to allocate the requested	resource or server
	    memory.

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

SEE ALSO
  XAllocClassHint(3X11), XAllocIconSize(3X11), XAllocSizeHints(3X11),
  XAllocWMHints(3X11), XSetTransientForHint(3X11), XSetTextProperty(3X11),
  XSetWMClientMachine(3X11), XSetWMColormapWindows(3X11),
  XSetWMIconName(3X11),	XSetWMName(3X11), XSetWMProperties(3X11),
  XSetWMProtocols(3X11), XStringListToTextProperty(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




















































