hpux man page for xgetdefault

Query: xgetdefault

OS: hpux

Section: 3

Format: Original Unix Latex Style Formatted with HTML and a Horizontal Scroll Bar

XGetDefault()															     XGetDefault()

Name
  XGetDefault - extract an option value from the resource database.

Synopsis
  char *XGetDefault(display, program, option)
	Display *display;
	char *program;
	char *option;

Arguments
  display  Specifies a connection to an X server; returned from XOpenDisplay().

  program  Specifies  the program name to be looked for in the resource database.  The program name is usually argv[0], the first argument on
	   the UNIX command line.

  option   Specifies the option name or keyword.  Lines containing both the program name and the option name, separated only by a  period  or
	   asterisk, will be matched.

Returns
  The resource value.

Description
  XGetDefault() returns a character string containing the user's default value for the specified program name and option name.	XGetDefault()
  returns NULL if no key can be found that matches option and program.	For a description of the matching rules, see XrmGetResource().

  The strings returned by XGetDefault() are owned by Xlib and should not be modified or freed by the client.

  Lines in the user's resource database look like this:

      xterm.foreground: 	 #c0c0ff
      xterm.geometry:		 =81x28
      xterm.saveLines:		 256
      xterm.font:		 8x13
      xterm.keyMapFile: 	 /usr/black/.keymap
      xterm.activeIcon: 	 on
      xmh.header.font		 9x15

  The portion on the left is known as a key; the portion on the right is the value.  Uppercase or lowercase is important in keys.   The  con-
  vention is to capitalize only the second and successive words in each option, if any.

  Resource  specifications are usually loaded into the XA_RESOURCE_MANAGER property on the root window at login.  If no such property exists,
  a resource file in the user's home directory is loaded.  On a UNIX-based system,  this  file	is  $HOME/.Xdefaults.	After  loading	these
  defaults, XGetDefault() merges additional defaults specified by the XENVIRONMENT environment variable.  If XENVIRONMENT is defined, it con-
  tains a full path name for the additional resource file.  If XENVIRONMENT is not defined, XGetDefault()  looks  for  $HOME/.Xdefaults-name,
  where  name specifies the name of the machine on which the application is running. If length of ".Xdefaults-name" is greater than 255, then
  $HOME/.Xdefaults-IP address is looked for instead, where IP address is the internet address of the host.

  The first invocation of XGetDefault() reads and merges the various resource files into Xlib so that subsequent requests are  fast.   There-
  fore, changes to the resource files from the program will not be felt until the next invocation of the application.

  For more information, see Volume One, Chapter 13, Managing User Preferences.

See Also
  XAutoRepeatOff(), XAutoRepeatOn(), XBell(), XChangeKeyboardControl(), XGetKeyboardControl(), XGetPointerControl().

Xlib - User Preferences 													     XGetDefault()
Related Man Pages
xrefresh(1) - redhat
xrefresh(1) - debian
xrefresh(1) - centos
xchangekeya(3) - hpux
xtdisplayinitialize(1) - hpux
Similar Topics in the Unix Linux Community
Share xterm/kconsole
Display output of one xterm on another
Xlib: connection refused by server
Question about xterm session $HOME
Xterm display immediatly dies in hpux 11.23