31 #ifdef G4VIS_BUILD_OPENGLXM_DRIVER
36 #include <X11/Intrinsic.h>
41 G4OpenGLXmPushButton::G4OpenGLXmPushButton (
const char*
n,
50 G4OpenGLXmPushButton::~G4OpenGLXmPushButton ()
53 void G4OpenGLXmPushButton::SetName (
const char*
n)
56 XmString button_string = XmStringCreateLocalized ((
char*)
name);
57 XtVaSetValues (button,
58 XmNlabelString, button_string,
60 XmStringFree (button_string);
63 const char* G4OpenGLXmPushButton::GetName ()
68 void G4OpenGLXmPushButton::AddYourselfTo (G4OpenGLXmVWidgetContainer* container)
71 pView = container->GetView ();
73 parent = container->GetPointerToWidget ();
75 XmString button_str = XmStringCreateLocalized ((
char*)
name);
76 button = XtVaCreateManagedWidget
78 xmPushButtonWidgetClass,
80 XmNlabelString, button_str,
81 XmNalignment, XmALIGNMENT_CENTER,
87 XtNborderColor, borcol,
92 XtAddCallbacks (button,
96 XmStringFree (button_str);
99 Widget* G4OpenGLXmPushButton::GetPointerToParent ()
104 Widget* G4OpenGLXmPushButton::GetPointerToWidget ()