33 #ifdef G4VIS_BUILD_OIX_DRIVER
38 #include <Inventor/Xt/SoXt.h>
45 inline bool soxt_dispatch_event(
void* a_event) {
46 return SoXt::dispatchEvent((XEvent*)a_event);
61 RemoveDispatcher(G4Xt::xt_dispatch_event);
65 AddDispatcher(soxt_dispatch_event);
71 if(getenv(
"XENVIRONMENT")==NULL) {
72 XrmDatabase database = XrmGetDatabase(XtDisplay(top));
74 XrmPutLineResource(&database,
"*topShadowColor:white");
75 XrmPutLineResource(&database,
"*bottomShadowColor:black");
76 XrmPutLineResource(&database,
"*foreground:black");
77 XrmPutLineResource(&database,
"*background:lightgrey");
78 XrmPutLineResource(&database,
"*borderColor:lightgrey");
79 XrmPutLineResource(&database,
"*fontList:-*-helvetica-bold-r-*-*-*-120-*-*-*-*-iso8859-1");
80 XrmPutLineResource(&database,
"*help_popup.title:Help");
81 XrmPutLineResource(&database,
"*helpCancel.labelString:Cancel");
82 XrmPutLineResource(&database,
"*helpText.editMode:multi_line_edit");
83 XrmPutLineResource(&database,
"*helpText.columns:60");
84 XrmPutLineResource(&database,
"*helpText.rows:20");
85 XrmPutLineResource(&database,
"*helpText.background:white");
86 XrmPutLineResource(&database,
"*helpText.fontList:*courier*-r-*--14-*");
87 XrmPutLineResource(&database,
"*helpText.maxLength:8000");
91 if(!SoXt::getTopLevelWidget()) SoXt::init(top);
102 G4OpenInventorSceneHandler* pScene = (G4OpenInventorSceneHandler*)&scene;
103 return new G4OpenInventorXtViewer (*pScene, name);
G4VViewer * CreateViewer(G4VSceneHandler &, const G4String &name="")
void SetInteractorManager(G4VInteractorManager *)
virtual void Initialize()
G4VInteractorManager * GetInteractorManager()
virtual ~G4OpenInventorXt()
G4Interactor GetMainInteractor()