


XtDisplayInitialize(3Xt)			     XtDisplayInitialize(3Xt)
X11R5									X11R5



NAME
  XtDisplayInitialize, XtOpenDisplay, XtDatabase, XtCloseDisplay - initial-
  ize, open, or	close a	display

SYNTAX
  void XtToolkitInitialize()

  void XtDisplayInitialize(_a_p_p__c_o_n_t_e_x_t,	_d_i_s_p_l_a_y, _a_p_p_l_i_c_a_t_i_o_n__n_a_m_e,
  _a_p_p_l_i_c_a_t_i_o_n__c_l_a_s_s,
			 _o_p_t_i_o_n_s, _n_u_m__o_p_t_i_o_n_s, _a_r_g_c, _a_r_g_v)
	XtAppContext _a_p_p__c_o_n_t_e_x_t;
	Display	*_d_i_s_p_l_a_y;
	String _a_p_p_l_i_c_a_t_i_o_n__n_a_m_e;
	String _a_p_p_l_i_c_a_t_i_o_n__c_l_a_s_s;
	XrmOptionDescRec *_o_p_t_i_o_n_s;
	Cardinal _n_u_m__o_p_t_i_o_n_s;
	Cardinal *_a_r_g_c;
	String *_a_r_g_v;

  Display *XtOpenDisplay(_a_p_p__c_o_n_t_e_x_t, _d_i_s_p_l_a_y__s_t_r_i_n_g, _a_p_p_l_i_c_a_t_i_o_n__n_a_m_e,
  _a_p_p_l_i_c_a_t_i_o_n__c_l_a_s_s,
			 _o_p_t_i_o_n_s, _n_u_m__o_p_t_i_o_n_s, _a_r_g_c, _a_r_g_v)
	 XtAppContext _a_p_p__c_o_n_t_e_x_t;
	 String	_d_i_s_p_l_a_y__s_t_r_i_n_g;
	 String	_a_p_p_l_i_c_a_t_i_o_n__n_a_m_e;
	 String	_a_p_p_l_i_c_a_t_i_o_n__c_l_a_s_s;
	 XrmOptionDescRec *_o_p_t_i_o_n_s;
	 Cardinal _n_u_m__o_p_t_i_o_n_s;
	 Cardinal *_a_r_g_c;
	 String	*_a_r_g_v;

  void XtCloseDisplay(_d_i_s_p_l_a_y)
	Display	*_d_i_s_p_l_a_y;

  XrmDatabase XtDatabase(_d_i_s_p_l_a_y)
	Display	*_d_i_s_p_l_a_y;

ARGUMENTS

  _a_r_g_c	    Specifies a	pointer	to the number of command line parameters.

  _a_r_g_v	    Specifies the command line parameters.

  _a_p_p__c_o_n_t_e_x_t
	    Specifies the application context.

  _a_p_p_l_i_c_a_t_i_o_n__c_l_a_s_s
	    Specifies the class	name of	this application, which	usually	is
	    the	generic	name for all instances of this application.

  _a_p_p_l_i_c_a_t_i_o_n__n_a_m_e
	    Specifies the name of the application instance.

  _d_i_s_p_l_a_y   Specifies the display.  Note that a	display	can be in at most one
	    application	context.

  _n_u_m__o_p_t_i_o_n_s
	    Specifies the number of entries in the options list.

  _o_p_t_i_o_n_s   Specifies how to parse the command line for	any application-
	    specific resources.	 The options argument is passed	as a parame-
	    ter	to _X_r_m_P_a_r_s_e_C_o_m_m_a_n_d.  For further information, see _X_l_i_b - _C
	    _L_a_n_g_u_a_g_e _X _I_n_t_e_r_f_a_c_e.

DESCRIPTION
  The _X_t_D_i_s_p_l_a_y_I_n_i_t_i_a_l_i_z_e function builds the resource database, calls the
  Xlib _X_r_m_P_a_r_s_e_C_o_m_m_a_n_d function	to parse the command line, and performs	other
  per display initialization.  After _X_r_m_P_a_r_s_e_C_o_m_m_a_n_d has been called, argc
  and argv contain only	those parameters that were not in the standard option
  table	or in the table	specified by the options argument.  If the modified
  argc is not zero, most applications simply print out the modified argv
  along	with a message listing the allowable options.  On UNIX-based systems,
  the application name is usually the final component of argv[0].  If the
  synchronize resource is _T_r_u_e for the specified application, _X_t_D_i_s_p_l_a_y_I_n_i_-
  _t_i_a_l_i_z_e calls	the Xlib _X_S_y_n_c_h_r_o_n_i_z_e function to put Xlib into	synchronous
  mode for this	display	connection.  If	the reverseVideo resource is _T_r_u_e,
  the Intrinsics exchange _X_t_D_e_f_a_u_l_t_F_o_r_e_g_r_o_u_n_d and _X_t_D_e_f_a_u_l_t_B_a_c_k_g_r_o_u_n_d for
  widgets created on this display.  (See Section 9.6.1).

  The _X_t_O_p_e_n_D_i_s_p_l_a_y function calls _X_O_p_e_n_D_i_s_p_l_a_y	the specified display name.
  If display_string is NULL, _X_t_O_p_e_n_D_i_s_p_l_a_y uses	the current value of the
  -display option specified in argv and	if no display is specified in argv,
  uses the user's default display (on UNIX-based systems, this is the value
  of the DISPLAY environment variable).

  If this succeeds, it then calls _X_t_D_i_s_p_l_a_y_I_n_i_t_i_a_l_i_z_e and pass it the opened
  display and the value	of the -name option specified in argv as the applica-
  tion name.  If no name option	is specified, it uses the application name
  passed to _X_t_O_p_e_n_D_i_s_p_l_a_y.  If the application name is NULL, it	uses the last
  component of argv[0].	 _X_t_O_p_e_n_D_i_s_p_l_a_y returns the newly opened	display	or
  NULL if it failed.

  _X_t_O_p_e_n_D_i_s_p_l_a_y	is provided as a convenience to	the application	programmer.

  The _X_t_C_l_o_s_e_D_i_s_p_l_a_y function closes the specified display as soon as it is
  safe to do so.  If called from within	an event dispatch (for example,	a
  callback procedure), _X_t_C_l_o_s_e_D_i_s_p_l_a_y does not close the display until the
  dispatch is complete.	 Note that applications	need only call _X_t_C_l_o_s_e_D_i_s_p_l_a_y
  if they are to continue executing after closing the display; otherwise,
  they should call _X_t_D_e_s_t_r_o_y_A_p_p_l_i_c_a_t_i_o_n_C_o_n_t_e_x_t or just exit.

  The _X_t_D_a_t_a_b_a_s_e function returns the fully merged resource database that was
  built	by _X_t_D_i_s_p_l_a_y_I_n_i_t_i_a_l_i_z_e associated with the display that	was passed
  in.  If this display has not been initialized	by _X_t_D_i_s_p_l_a_y_I_n_i_t_i_a_l_i_z_e,	the
  results are not defined.

SEE ALSO
  XtAppCreateShell(3Xt), XtCreateApplicationContext(3Xt)
  _X _T_o_o_l_k_i_t _I_n_t_r_i_n_s_i_c_s - _C _L_a_n_g_u_a_g_e _I_n_t_e_r_f_a_c_e
  _X_l_i_b - _C _L_a_n_g_u_a_g_e _X _I_n_t_e_r_f_a_c_e














