Path: utzoo!utgpu!news-server.csri.toronto.edu!rutgers!apple!usc!elroy.jpl.nasa.gov!hacgate!luna.dpl.scg.hac.com!sean From: sean@luna.dpl.scg.hac.com (Sean Cohan) Newsgroups: comp.windows.x Subject: Widget Name Message-ID: <10975@hacgate.UUCP> Date: 3 Oct 90 20:40:09 GMT Sender: news@hacgate.UUCP Reply-To: sean@luna.dpl.scg.hac.com (Sean Cohan) Distribution: usa Organization: Hughes Aircraft Co., El Segundo, CA Lines: 21 I am using XQueryPointer and XtWindowToWidget to get the widget at the current location of the pointer. I need to get the name of the returned widget. I am using X11R3 so I can't use XtName that is available in X11R4 and Motif1.01. If I create a widget like: button = XtCreateWidget("Button", XmPushButtonWidgetClass, parent, args, argcnt); How can I retrieve the widget name "Button"? Right now I am trying to access the widget structure like: printf("widget's name: %s\n", button->core.name); but I get a segmentation fault. Looking at it with gdb, I get a valid address for button, but button->core is bogus. Any suggestions? Thanks in advance.