Path: utzoo!utgpu!jarvis.csri.toronto.edu!clyde.concordia.ca!uunet!samsung!usc!snorkelwacker!bloom-beacon!EXPO.LCS.MIT.EDU!kit From: kit@EXPO.LCS.MIT.EDU (Chris D. Peterson) Newsgroups: comp.windows.x Subject: (none) Message-ID: <9001091856.AA10010@expo.lcs.mit.edu> Date: 9 Jan 90 18:56:11 GMT References: <900109063047.22e00127@CCC.NMFECC.GOV> Sender: daemon@athena.mit.edu (Mr Background) Organization: The Internet Lines: 28 > Is there some standard way of getting a widget name and/or classname? To get the widget name use: XtName(widget); There is no convience routine to return the class name of a widget, since the class names do not change dynamically it is not clear to me why you would ever need to query a widget about its class name unless you are writing a User Interface Mangager, or a Class Browser. Therefore the only way to get the class name of a widget is to look into its "private" structure. > Is dotting into the core widget structure sufficient (ie could the > core widget change in future releases?) The core widget structure is defined in the Xt Specification, and it would take a change to the Specification to modify it, I think you can count on it not changing. Although looking into these internal Xt structures from an application is considered bad form, since it sort of breaks the abstraction barrier. Chris D. Peterson MIT X Consortium Net: kit@expo.lcs.mit.edu Phone: (617) 253 - 9608 Address: MIT - Room NE43-213