viewres - graphical class browser for Xt
viewres [-option ...]
The viewres program displays a tree showing the widget class hierarchy of the Athena Wid-
get Set. Each node in the tree can be expanded to show the resources that the correspond-
ing class adds (i.e. does not inherit from its parent) when a widget is created. This
application allows the user to visually examine the structure and inherited resources for
the Athena Widget Set.
Viewres accepts all of the standard toolkit command line options as well as the following:
This option specifies the name of the highest widget in the hierarchy to display.
This is typically used to limit the display to a subset of the tree. The default
This option indicates that the widget variable names (as declared in header files)
should be displayed in the nodes rather than the widget class name. This is some-
times useful to distinguish widget classes that share the same name (such as
This option indicates that the tree should be displayed top to bottom rather left
The way in which the tree is displayed may be changed through the entries in the View
Show Variable Names
This entry causes the node labels to be set to the variable names used to declare
the corresponding widget class. This operation may also be performed with the
Show Class Names
This entry causes the node labels to be set to the class names used when specify-
ing resources. This operation may also be performed with the SetLabelType(class)
This entry causes the tree to be laid out from left to right. This operation may
also be performed with the SetOrientation(West) translation.
This entry causes the tree to be laid out from top to bottom. This operation may
also be performed with the SetOrientation(North) translation.
Show Resource Boxes
This entry expands the selected nodes (see next section) to show the new widget
and constraint resources. This operation may also be performed with the
Hide Resource Boxes
This entry removes the resource displays from the selected nodes (usually to con-
serve space). This operation may also be performed with the Resources(off) trans-
Resources for a single widget class can be displayed by clicking Button2 on the corre-
sponding node, or by adding the node to the selection list with Button1 and using the Show
Resource Boxes entry in the View menu. Since Button1 actually toggles the selection state
of a node, clicking on a selected node will cause it to be removed from the selected list.
Collections of nodes may also be selected through the various entries in the Select menu:
This entry removes all nodes from the selection list. This operation may also be
performed with the Select(nothing) translation.
This entry adds all nodes to the selection list. This operation may also be per-
formed with the Select(all) translation.
This entry adds unselected nodes to, and removes selected nodes from, the selec-
tion list. This operation may also be performed with the Select(invert) transla-
This entry selects the immediate parents of all selected nodes. This operation
may also be performed with the Select(parent) translation.
This entry recursively selects all parents of all selected nodes. This operation
may also be performed with the Select(ancestors) translation.
This entry selects the immediate children of all selected nodes. This operation
may also be performed with the Select(children) translation.
This entry recursively selects all children of all selected nodes. This operation
may also be performed with the Select(descendants) translation.
Select Has Resources
This entry selects all nodes that add new resources (regular or constraint) to
their corresponding widget classes. This operation may also be performed with the
Select Shown Resource Boxes
This entry selects all nodes whose resource boxes are currently expanded (usually
so that they can be closed with Hide Resource Boxes). This operation may also be
performed with the Select(shown) translation.
The following application actions are provided:
This action causes viewres to exit.
This action sets the node labels to display the widget variable or class names,
according to the argument type.
This action sets the root of the tree to be one of the following areas of the win-
dow: West, North, East, or South.
This action selects the indicated nodes, as described in the VIEW MENU section:
nothing (unselects all nodes), invert, parent, ancestors, children, descendants,
This action turns on, off, or toggles the resource boxes for the selected nodes.
If invoked from within one of the nodes (through the keyboard or pointer), only
that node is used.
Resources may be specified for the following widgets:
where variable-name is the widget variable name of each node.
X(7x), xrdb(1), listres(1), editres(1), appres(1), appropriate widget documents
Copyright ([, X Consortium
See X(7x) for a full statement of rights and permissions.
Jim Fulton, MIT X Consortium
X Version 11 Release 6.6 VIEWRES(1)