36 #ifdef G4VIS_BUILD_OIX_DRIVER
41 #include <Inventor/Xt/SoXt.h>
49 inline bool soxt_dispatch_event(
void* a_event) {
50 return SoXt::dispatchEvent((XEvent*)a_event);
67 RemoveDispatcher(G4Xt::xt_dispatch_event);
71 AddDispatcher(soxt_dispatch_event);
76 G4cout <<
"TOP LEVEL WIDGET FOR SoXt::init() = " << top <<
G4endl;
78 if(getenv(
"XENVIRONMENT")==NULL) {
79 XrmDatabase database = XrmGetDatabase(XtDisplay(top));
81 XrmPutLineResource(&database,
"*topShadowColor:white");
82 XrmPutLineResource(&database,
"*bottomShadowColor:black");
83 XrmPutLineResource(&database,
"*foreground:black");
84 XrmPutLineResource(&database,
"*background:lightgrey");
85 XrmPutLineResource(&database,
"*borderColor:lightgrey");
86 XrmPutLineResource(&database,
"*fontList:-*-helvetica-bold-r-*-*-*-120-*-*-*-*-iso8859-1");
87 XrmPutLineResource(&database,
"*help_popup.title:Help");
88 XrmPutLineResource(&database,
"*helpCancel.labelString:Cancel");
89 XrmPutLineResource(&database,
"*helpText.editMode:multi_line_edit");
90 XrmPutLineResource(&database,
"*helpText.columns:60");
91 XrmPutLineResource(&database,
"*helpText.rows:20");
92 XrmPutLineResource(&database,
"*helpText.background:white");
93 XrmPutLineResource(&database,
"*helpText.fontList:*courier*-r-*--14-*");
94 XrmPutLineResource(&database,
"*helpText.maxLength:8000");
98 if(!SoXt::getTopLevelWidget()) SoXt::init(top);
111 G4OpenInventorSceneHandler* pScene = (G4OpenInventorSceneHandler*)&scene;
112 return new G4OpenInventorXtExtendedViewer (*pScene, name);
void SetInteractorManager(G4VInteractorManager *)
G4OpenInventorXtExtended()
G4VInteractorManager * GetInteractorManager()
std::map< G4String, G4AttDef > * GetInstance(const G4String &storeKey, G4bool &isNew)
virtual ~G4OpenInventorXtExtended()
G4GLOB_DLL std::ostream G4cout
G4Interactor GetMainInteractor()
virtual void Initialize()
G4VViewer * CreateViewer(G4VSceneHandler &, const G4String &name="")