The UIL compiler checks resource names, so if you specify a resource that is not supported by a widget, the compiler
generates an error message. In contrast, if you try to set an unsupported resource with XtSetValues(), Xt ignores
the resource and does not generate an error. By using UIL, you can also avoid setting a resource to the wrong type of
value because the UIL compiler ensures that the type of resource matches the type of the value you assign to it.
(Appendix C, Table of Motif Resources, in Volume Six B, Motif Reference Manual, contains a complete list of Motif
widget resources and their associated types.) Once again, this type of error is not caught in C code when you use
XtSetValues() or XtVaSetValues(). Unrecognized resource names are also ignored in X resource files.
The disadvantages of specifying resource values in code and in resource files may give you the impression that you
should always set resources from a UIL module. However, there are also disadvantages to setting resources in UIL.
The main disadvantage is that users of your application cannot override UIL settings with their own resource settings.
In Section #suilres we take a closer look at the issues involved in deciding whether to set a resource in UIL,
application code, or an X resource file. The type of a value you assign to a resource must match the type of the
resource. However, there are a few cases in which the UIL compiler automatically converts a value to the appropriate
type. The supported conversions are ...