net@TUB.BITNET (Oliver Laumann) (02/23/89)
I don't understand why it is possible to set the ``edit type'' resource of an AsciiDisk or AsciiString widget (i.e. by passing an argument with the name XtNeditType to XtCreateWidget()). Neither the AsciiDisk (or AsciiString) nor the Text widget class declares such a resource, nor does a call to XtGetResourceList() return an ``edit type'' resource. It is obviously possible to set resources for a widget that are neither defined in the widget's class nor in a super class nor by the parent widget's constraints. Is there a way for the application programmer to obtain a list of these resources similar to XtGetResourceList() for ``normal'' resources? Don't tell me ``by looking at the source code''; I want to get a list of resources from within a program. Thanks, -- Oliver Laumann net@TUB.BITNET net@tub.UUCP
swick@ATHENA.MIT.EDU (Ralph R Swick) (02/23/89)
Date: Wed, 22 Feb 89 17:56:11 +0100 From: Oliver Laumann <net%TUB.BITNET@mitvma.mit.edu> I don't understand why it is possible to set the ``edit type'' resource of an AsciiDisk or AsciiString widget (i.e. by passing an argument with the name XtNeditType to XtCreateWidget()). Look at XtSetSubvalues() and Core.set_values_hook Neither the AsciiDisk (or AsciiString) nor the Text widget class declares such a resource, nor does a call to XtGetResourceList() return an ``edit type'' resource. Correct. It is obviously possible to set resources for a widget that are neither defined in the widget's class nor in a super class nor by the parent widget's constraints. Yes, the hooks are put there for many purposes, not all of them benign. Is there a way for the application programmer to obtain a list of these resources similar to XtGetResourceList() for ``normal'' resources? No, not in general. Such resources are effectively hidden from the Intrinsics and unless the widget class itself exports a way to retrieve the list of extra resources, you're out of luck.