HPlogo Using the X Window System > Chapter 5 Application Resources

Changing the RESOURCE_MANAGER Property with `xrdb'

» 

Technical documentation

Complete book in PDF

 » Table of Contents

 » Glossary

 » Index

The RESOURCE_MANAGER property is a property on the root window that is treated the same way as a resource file by the resource manager.

During a session, the RESOURCE_MANAGER property may be modified by the the xrdb client.

You can use xrdb to load resources into the server's RESOURCE_MANAGER property.

The syntax for xrdb is:

   xrdb options [filename]

Where options are:

-help

Displays a list of options for xrdb.

-display host:display

Specifies the host and display of the server to be loaded with the configuration information.

-query

Displays the current contents of the server's RESOURCE_MANAGER property.

-load path/filename

Specifies that xrdb should load the file named on the command line into the RESOURCE_MANAGER property, overwriting the current resources listed there. This is the default action.

-merge path/filename

Specifies that xrdb should load the file named on the command line into the RESOURCE_MANAGER property, merging the new resources with the current resources instead of overwriting them.

-remove

Removes the current configuration file from the RESOURCE_MANAGER property.

-edit path/filename

Places the contents of the RESOURCE_MANAGER property into the named file, overwriting resources specified there.

-backup string

Specifies a suffix to be appended to the filename used in the -edit option to create a backup file.

-cpp path/filename

Specifies the path and filename of the C preprocessor to use when loading a configuration file containing #ifdef or #includeents. xrdb works with CPP and other preprocessors as long as they accept the -D, -U, and -I options.

-nocpp path/filename

Specifies that xrdb should not use a preprocessor before loading the configuration file (the file contains no statements that need preprocessing).

-symbols

Displays the symbols currently defined for the preprocessor.

-Dname[=value]

Defines a symbol for use with conditional statements in the configuration file used by the RESOURCE_MANAGER property.

-Uname

Removes a defined symbol from the RESOURCE_MANAGER property.

-Ipath/directory

Specifies the search path and directory of #include files used in the RESOURCE_MANAGER.

To add resources interactively:

  1. Execute:

       xrdb -merge -nocpp
    
    in a local terminal emulation window.

  2. Type in the resource specifications. Each resource must be on a separate line.

  3. When you've typed all the resources, press CTRL d to merge the resources and restore the shell prompt.

To add resources by typing the resources into a file that is then merged into the database:

  1. Create a file containing the resources you want to add.

  2. Execute:

       xrdb -merge -nocpp filename
    

© 1995 Hewlett-Packard Development Company, L.P.