SCO Visual Tcl Reference Guide
Chapter 3, SCO Visual Tcl - graphical scripting language

Graphics resource files used by SCO Visual Tcl

Graphics resource files used by SCO Visual Tcl

SCO Visual Tcl reads the standard SCO and OSF/Motif resource files during startup. See the Graphical Environment Guide for details. In addition, corresponding resource files are used by the character mode environment.

When the graphical server process starts up, it reads the resources in /usr/lib/X11/app-defaults/Vtcl. Then it checks xrdb(XC), and finally $HOME/.Xdefaults-hostname. If scosession is running (that is, if you are using the Desktop) then xrdb is already loaded with the resources found in /usr/lib/X11/sco/startup/ and $HOME/.odtpref/ScoSession/display:0.0.

When the character server starts, it reads resources from /usr/lib/charm/app-defaults/Vtcl and from $HOME/.Cdefaults.

To specify resources for both the graphical and character servers, use the classname Vtcl. For example, to specify a foreground of gold and a background of blue:

   Vtclforeground: gold
   Vtclbackground: blue
To specify resources for an individual vtcl script, use the name passed to VtOpen(VTCL) as the application's classname. For example, this script puts up a dialog with the label ``Hello World!'' and an OK button:
   set app [VtOpen myprog]
   set form [VtStartForm $app.form -ok]
   set lab [VtLabel $form.label -label "Hello World"]
   VtShow $form
   VtMainLoop
To specify that the OK button should turn green when armed (pressed and held down) for this script, this line should be added to the resource
   myprogarmColor:  green
Because the graphical server is a daemon and only reads resources at startup, it must be killed and restarted for new resources to take effect. This can be done using kill(C) or VtQuitServer(VTCL).