72{
73
74 QWidget* parent = SoQt::getTopLevelWidget();
75
76
77
78
79
81
82
83
84
85
86
88 auto uiQt =
dynamic_cast<G4UIQt*
>(UI->GetG4UIWindow());
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
109
110
111
112
113
114
115
116
117
118
119
120 fViewer->setSize(SbVec2s(width, height));
122
123
124
125
129
130
131
132 FileWritePS = new QAction("Write PostScript (gl2ps)", this);
133 FileWritePS->setFont(*font);
134 connect(FileWritePS, SIGNAL(triggered()), this,
135 SLOT(FileWritePSCB()));
136 filemenu->addAction(FileWritePS);
137
138 FileWritePDF = new QAction("Write PDF (gl2ps)", this);
139 FileWritePDF->setFont(*font);
140 connect(FileWritePDF, SIGNAL(triggered()), this,
141 SLOT(FileWritePDFCB()));
142 filemenu->addAction(FileWritePDF);
143
144 FileWriteIV = new QAction("Write IV", this);
145 FileWriteIV->setFont(*font);
146 connect(FileWriteIV, SIGNAL(triggered()), this,
147 SLOT(FileWriteIVCB()));
148 filemenu->addAction(FileWriteIV);
149
150 FileEscape = new QAction("Escape", this);
151 FileEscape->setFont(*font);
152 connect(FileEscape, SIGNAL(triggered()), this,
153 SLOT(FileEscapeCB()));
154 filemenu->addAction(FileEscape);
155
156
157
160
161
162
163
164
165
166
167 EtcEraseDetector = new QAction("Erase detector", this);
168 EtcEraseDetector->setFont(*font);
169 connect(EtcEraseDetector, SIGNAL(triggered()), this,
170 SLOT(EtcEraseDetectorCB()));
171 etcmenu->addAction(EtcEraseDetector);
172
173 EtcEraseEvent = new QAction("Erase event", this);
174 EtcEraseEvent->setFont(*font);
175 connect(EtcEraseEvent, SIGNAL(triggered()), this,
176 SLOT(EtcEraseEventCB()));
177 etcmenu->addAction(EtcEraseEvent);
178
179 EtcSetSolid = new QAction("Set solid", this);
180 EtcSetSolid->setFont(*font);
181 connect(EtcSetSolid, SIGNAL(triggered()), this, SLOT(EtcSetSolidCB()));
182 etcmenu->addAction(EtcSetSolid);
183
184 EtcSetReducedWireframe = new QAction("Set (G4) reduced wireframe", this);
185 EtcSetReducedWireframe->setFont(*font);
186 connect(EtcSetReducedWireframe, SIGNAL(triggered()), this,
187 SLOT(EtcSetReducedWireframeCB()));
188 etcmenu->addAction(EtcSetReducedWireframe);
189
190 EtcSetFullWireframe = new QAction("Set full wireframe", this);
191 EtcSetFullWireframe->setFont(*font);
192 connect(EtcSetFullWireframe, SIGNAL(triggered()), this,
193 SLOT(EtcSetFullWireframeCB()));
194 etcmenu->addAction(EtcSetFullWireframe);
195
196 EtcVisibMInvisibD = new QAction("Visible mothers + invisible daughters",
197 this);
198 EtcVisibMInvisibD->setFont(*font);
199 connect(EtcVisibMInvisibD, SIGNAL(triggered()), this,
200 SLOT(EtcVisibMInvisibDCB()));
201 etcmenu->addAction(EtcVisibMInvisibD);
202
203 EtcVisibMVisibD = new QAction("Visible mothers + visible daughters", this);
204 EtcVisibMVisibD->setFont(*font);
205 connect(EtcVisibMVisibD, SIGNAL(triggered()), this,
206 SLOT(EtcVisibMVisibDCB()));
207 etcmenu->addAction(EtcVisibMVisibD);
208
209 EtcUpdateScene = new QAction("Update scene", this);
210 EtcUpdateScene->setFont(*font);
211 connect(EtcUpdateScene, SIGNAL(triggered()), this,
212 SLOT(EtcUpdateSceneCB()));
213 etcmenu->addAction(EtcUpdateScene);
214
215 EtcSceneGraphStats = new QAction("Scene graph stats", this);
216 EtcSceneGraphStats->setFont(*font);
217 connect(EtcSceneGraphStats, SIGNAL(triggered()), this,
218 SLOT(EtcSceneGraphStatsCB()));
219 etcmenu->addAction(EtcSceneGraphStats);
220
221
222
223 const SbViewportRegion& vpRegion =
fViewer->getViewportRegion();
226
227
228
229
230
231
232
233
234
236 fViewer->setTransparencyType(SoGLRenderAction::SORTED_OBJECT_ADD);
239
242
243
244
245
246 QWidget* mainWin = SoQt::getTopLevelWidget();
247
248
249
250
251
252 SoQt::show(mainWin);
254
255
257}
void setOrigWindowSize(int w, int h)
SoSelection * fSoSelection
G4VInteractorManager * fInteractorManager
Geant4_SoGL2PSAction * fGL2PSAction
static G4UImanager * GetUIpointer()
void SetCreatedInteractor(G4Interactor)
virtual void FlushAndWaitExecution()=0
unsigned int GetWindowSizeHintX() const
unsigned int GetWindowSizeHintY() const