31#ifdef G4VIS_BUILD_OPENGLXM_DRIVER
36#include <X11/Intrinsic.h>
41G4OpenGLXmPushButton::G4OpenGLXmPushButton (
const char* n,
48G4OpenGLXmPushButton::~G4OpenGLXmPushButton ()
51void G4OpenGLXmPushButton::SetName (
const char* n)
54 XmString button_string = XmStringCreateLocalized ((
char*)name);
55 XtVaSetValues (button,
56 XmNlabelString, button_string,
58 XmStringFree (button_string);
61const char* G4OpenGLXmPushButton::GetName ()
66void G4OpenGLXmPushButton::AddYourselfTo (G4OpenGLXmVWidgetContainer* container)
69 pView = container->GetView ();
71 parent = container->GetPointerToWidget ();
73 XmString button_str = XmStringCreateLocalized ((
char*)name);
74 button = XtVaCreateManagedWidget
76 xmPushButtonWidgetClass,
78 XmNlabelString, button_str,
79 XmNalignment, XmALIGNMENT_CENTER,
85 XtNborderColor, borcol,
90 XtAddCallbacks (button,
94 XmStringFree (button_str);
97Widget* G4OpenGLXmPushButton::GetPointerToParent ()
102Widget* G4OpenGLXmPushButton::GetPointerToWidget ()