ATLAS Offline Software
IVP13DStandardChannelWidget.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2023 CERN for the benefit of the ATLAS collaboration
3 */
4 
6 // //
7 // Implementation of class IVP13DStandardChannelWidget //
8 // //
9 // Author: Thomas Kittelmann <Thomas.Kittelmann@cern.ch> //
10 // //
11 // Initial version: April 2007 //
12 // //
14 
18 #include "VP1Base/VP1Msg.h"
19 #include "ui_vp13dstandardchannelsnapshotgroupbox.h"
20 
22 #include "VP1Base/VP1QtUtils.h"
23 #include "VP1Base/IVP13DSystem.h"
26 #include "VP1Base/VP1TabWidget.h"
27 
28 #include <Inventor/C/errors/debugerror.h>
29 #include <Inventor/actions/SoLineHighlightRenderAction.h>
30 #include <Inventor/actions/SoBoxHighlightRenderAction.h>
31 #include <Inventor/nodes/SoPerspectiveCamera.h>
32 #include <Inventor/SoOffscreenRenderer.h>
33 
34 #include <QSplitter>
35 #include <QVBoxLayout>
36 #include <QMap>
37 #include <QTimer>
38 #include <QBuffer>
39 #include <QByteArray>
40 #include <QDir>
41 #include <QFile>
42 #include <QFileInfo>
43 
44 #include <cassert>
45 
47 public:
50  SoSeparator * root;
53  QMap<IVP13DSystem*,SoSeparator*> system2rootNodes;
54 
55  QMap<QCheckBox*,IVP1System*> checkbox2system;
56  QList<IVP1System*> systemsAllowedControllers;
57  QList<IVP13DSystem*> systemsAllowedExtraDisplayWidgets;
58  QList<QPair<IVP1System*,bool> > system2switchable;
59  QMap<IVP1System*,bool> system2startdisabled;
60  QList<IVP13DSystem*> systemsAllowedCameraList;
61  void updateSystemState(QCheckBox*);
62 
63  //Snapshots:
64  Ui::VP13DStandardChannelSnapShotGroupBox uisnapshot;
65 
66  void setupSplitter(QWidget * rightwidget);
67 
68  void autoSnapshot();
69 
70  static const int min3dx = 150;
71  static const int min3dy = 180;
72 
73 
74  QMap<IVP1System*,QWidget*> sys2tabpage;
76 
78 
79  // restoreFromState versions
80  void restoreFromState_v7(QDataStream& state);
81 
82 
83 };
84 
85 //___________________________________________________________________________
87 {
89 }
90 
91 
92 //___________________________________________________________________________
94 {
96  return true;
97 }
98 
99 //___________________________________________________________________________
101 {
102  return m_d->viewer->isAntiAlias();
103 }
104 
105 //___________________________________________________________________________
106 IVP13DStandardChannelWidget::IVP13DStandardChannelWidget(const QString & name, const QString & information,
107  const QString & contact_info, bool detectorViewButtons)
108  : IVP13DChannelWidget(name,information,contact_info), m_d(new Imp)
109 {
110  m_d->detectorViewButtons = detectorViewButtons;
112  m_d->channel=this;
113  m_d->uisnapshot.checkBox_as_shown = 0;//Use this to see if the uisnapshot pointers are initialised/
114 
116 
117  m_d->root= new SoSeparator;
118  m_d->root->setName("StandardChannelWidgetSceneRoot");
119  m_d->root->ref();
120  m_d->viewer = 0;
121 
122  m_d->tabwidget = 0;
123 
125 }
126 
127 //___________________________________________________________________________
129 {
130  m_d->root->unref();
131  delete m_d;
132 }
133 
134 //___________________________________________________________________________
135 void IVP13DStandardChannelWidget::addSystem( IVP13DSystem*system, const SystemOptions& options ) {
136 
137 
138  bool switchable = ! (options & DisallowSwitchable);
139  bool allowController = ! (options & DisallowController);
140  bool allowExtraDisplayWidget = ! (options & DisallowExtraDisplayWidget);
141  bool startDisabled = (options & StartDisabled);
142 
143  registerSystem(system);
144  if (!( options & DisallowCameraAccess ))
145  m_d->systemsAllowedCameraList << system;
146 
147  SoSeparator * sysroot = system->getSceneGraph();
148  assert(!m_d->system2rootNodes.contains(system));
149  m_d->system2rootNodes.insert(system,sysroot);
150  m_d->root->addChild(sysroot);
151 
152  m_d->system2switchable << QPair<IVP1System*,bool>(system,switchable);
153 
154  assert(!m_d->system2startdisabled.contains(system));
155  m_d->system2startdisabled.insert(system,startDisabled);
156  assert(m_d->system2startdisabled.contains(system));
157 
158  if (allowController) {
159  m_d->systemsAllowedControllers << system;
160  connect(system,SIGNAL(itemFromSystemSelected()),this,SLOT(showControlsForSystem()));
161  }
162 
163  if (allowExtraDisplayWidget)
165 }
166 
167 //___________________________________________________________________________
169 
170  //Set up the controller.
171  QWidget * snapshotgroupbox = new QWidget();
172  m_d->uisnapshot.setupUi(snapshotgroupbox);
173 
174  VP1ColorSelectButton * colorselectbutton_dummy;
179  colorselectbutton_dummy,
180  snapshotgroupbox,true ));
181  short x,y;
182  SoOffscreenRenderer::getMaximumResolution().getValue(x,y);
183 
184  // now the range is set in the ui file.
185 // m_d->uisnapshot.spinBox_width->setRange ( 1, x/4 - 10 );
186 // m_d->uisnapshot.spinBox_height->setRange ( 1, y/4 - 10 );
187 
188  connect(m_d->uisnapshot.checkBox_as_shown,SIGNAL(toggled(bool)),this,SLOT(updateSnapshotDim()));
189  connect(m_d->uisnapshot.spinBox_width,SIGNAL(valueChanged(int)),this,SLOT(updateSnapshotDim()));
190  connect(m_d->uisnapshot.spinBox_height,SIGNAL(valueChanged(int)),this,SLOT(updateSnapshotDim()));
191  connect(m_d->uisnapshot.radioButton_width,SIGNAL(toggled(bool)),this,SLOT(updateSnapshotDim()));
192  connect(m_d->uisnapshot.radioButton_height,SIGNAL(toggled(bool)),this,SLOT(updateSnapshotDim()));
193 
194  connect(m_d->uisnapshot.groupBox_imagePresets,SIGNAL(toggled(bool)),this,SLOT(setImageFromPresets()));
195  connect(m_d->uisnapshot.radioButton_720p,SIGNAL(toggled(bool)),this,SLOT(setImageFromPresets()));
196  connect(m_d->uisnapshot.radioButton_1080p,SIGNAL(toggled(bool)),this,SLOT(setImageFromPresets()));
197  connect(m_d->uisnapshot.radioButton_4K,SIGNAL(toggled(bool)),this,SLOT(setImageFromPresets()));
198  connect(m_d->uisnapshot.radioButton_8K,SIGNAL(toggled(bool)),this,SLOT(setImageFromPresets()));
199 
200 
201  // m_d->systemsAllowedControllers.clear();
202  m_d->system2switchable.clear();
203 
204  QMapIterator<QCheckBox*,IVP1System*> it(m_d->checkbox2system);
205  while (it.hasNext()) {
206  it.next();
207 
208  assert(m_d->system2startdisabled.contains(it.value()));
209  if (m_d->system2startdisabled[it.value()]) {
210  it.key()->setChecked(false);
211  m_d->updateSystemState(it.key());
212  }
213 
214  connect(it.key(),SIGNAL(toggled(bool)),this,SLOT(toggleSystemActive()));
215 
216  }
217 
218  QTimer::singleShot(0, this, SLOT(updateSnapshotDim()));
219 
220 
221  //Setup viewer (with possible splitter for extra widgets):
222  QList<QPair<QString,QWidget*> > sysname2extradisplay;
224  QWidget * edwidget = sys->buildExtraDisplayWidget();
225  if (edwidget)
226  sysname2extradisplay << QPair<QString,QWidget*>(sys->name(),edwidget);
227  }
228 
229  if (sysname2extradisplay.count()==0) {
231  setMinimumSize(m_d->min3dx,m_d->min3dy);
232  } else if (sysname2extradisplay.count()==1) {
233  m_d->setupSplitter(sysname2extradisplay.front().second);
234  } else if (sysname2extradisplay.count()>1) {
235  VP1TabWidget * tabWidget = new VP1TabWidget();
236  for (int i = 0; i < sysname2extradisplay.count(); ++i) {
237  tabWidget->addTab(sysname2extradisplay.at(i).second,sysname2extradisplay.at(i).first);
238  }
239  tabWidget->setCurrentIndex(0);
240  m_d->setupSplitter(tabWidget);
241  }
242 
243  registerRenderArea(m_d->viewer);//remember this...
244 
246  m_d->viewer->setGLRenderAction(new SoLineHighlightRenderAction());
247  //m_d->viewer->setGLRenderAction(new SoBoxHighlightRenderAction());
248 
249  // Default Transparency Type
250  // m_d->viewer->setTransparencyType( SoGLRenderAction::DELAYED_BLEND ); // old
251  m_d->viewer->setTransparencyType( SoGLRenderAction::BLEND ); // this looks better for geometry volumes
252 
253  //Setup camera info:
255  sys->registerViewer(m_d->viewer);
256 
257 
258  /* We want to change the default value for the "As shown" option
259  * At the beginning the option was set to True by default, but
260  * the most used setting when creating event displays for ATLAS is
261  * False, because we want to save the full image as a snapshot,
262  * without the frame and buttons from VP1.
263  * So we now set it to False by default.
264  * (We do that with setChecked() in order to not having to change
265  * the whole logics behind.
266  */
267  m_d->uisnapshot.checkBox_as_shown->setChecked(false); // fixme: check if that works, or if it's still TRUE
268 
269 }
270 
271 //___________________________________________________________________________
273 {
274  QVBoxLayout * vboxLayout = new QVBoxLayout(channel);
275  vboxLayout->setContentsMargins(0, 0, 0, 0);
276  extradisplaywidget_splitter = new QSplitter(channel);
277  extradisplaywidget_splitter->setObjectName("3DchannelSplitter");
278  extradisplaywidget_splitter->setOrientation(Qt::Horizontal);
279  QWidget * widget_viewer = new QWidget(extradisplaywidget_splitter);
280  widget_viewer->setObjectName("widget_viewer");
281  extradisplaywidget_splitter->addWidget(widget_viewer);
282  rightwidget->setParent(extradisplaywidget_splitter);
283  extradisplaywidget_splitter->addWidget(rightwidget);
284  vboxLayout->addWidget(extradisplaywidget_splitter);
285  viewer = new VP1ExaminerViewer(widget_viewer);
286  widget_viewer->setMinimumSize(min3dx,min3dy);
287  connect(extradisplaywidget_splitter,SIGNAL(splitterMoved (int,int)),channel,SLOT(updateSnapshotDim()));
288 }
289 
290 //___________________________________________________________________________
292 {
293  VP1Msg::messageVerbose("IVP13DStandardChannelWidget::Imp::autoSnapshot()");
294 
295  int runnumber(0);
296  unsigned long long eventnumber(0);
297  channel->getRunEvtNumber(runnumber,eventnumber);
298 
299  #if defined BUILDVP1LIGHT
300  QString snapshotDirName = VP1QtUtils::expertSettingValue("general","ExpertSettings/VP1_SCREENSHOTS_DIR");
301  #else
302  QString snapshotDirName = VP1QtUtils::environmentVariableValue("VP1_SCREENSHOTS_DIR");
303  #endif
304 
305  QFileInfo snapshotDir(snapshotDirName);
306  if(!snapshotDir.exists()||!snapshotDir.isDir()||!snapshotDir.isReadable()||!snapshotDir.isWritable()) {
307  channel->message("The directory for storing VP1 snapshots "+snapshotDirName+" either does not exist or is not writable");
308  return;
309  }
310 
311  QString guess;
312  QString chnlname = channel->name().toLower();
313  chnlname.replace(' ','_');
314  QString base=snapshotDirName+QDir::separator()+"vp1_"+chnlname+"_run"+QString::number(runnumber)+"_evt"+QString::number(eventnumber);
315  guess=base;
316  int i(2);
317  while (QFile::exists(guess+".png")) {
318  guess=base+"_"+QString::number(i++);
319  }
320  guess+=".png";
321 
322  QPixmap pm = channel->getSnapshot();
323  if (pm.isNull()) {
324  VP1Msg::messageVerbose("pm==NULL, return...");
325  return;
326  }
327  pm.save(guess);
328 }
329 
330 //___________________________________________________________________________
332 {
333  VP1Msg::messageVerbose("IVP13DStandardChannelWidget::lastOfActiveSystemsRefreshed() called.");
334 
335  if (m_d->need_initial_viewall) {
336  m_d->viewer->viewAll();
338  m_d->need_initial_viewall=false;
339  }
340 
341  if(VP1QtUtils::environmentVariableIsSet("VP1_SCREENSHOTS_DIR"))
342  m_d->autoSnapshot();
343 
344  if (m_d->viewer->startTourEachEvent())
345  m_d->viewer->startTour();
346 
347  // apparently this is the last method called when all systems have been drawn
348  // so we call here the renderPixmap() method is we are in "batch-mode"
349 
350 
351 
352 }
353 
354 //___________________________________________________________________________
356 {
357 }
358 
359 //___________________________________________________________________________
361 {
362  IVP13DSystem * sys3d = static_cast<IVP13DSystem*>(sys);
363  if (sys3d)
364  sys3d->deselectAll();
365 }
366 
367 //___________________________________________________________________________
369 {
370  QCheckBox * cb = static_cast<QCheckBox*>(sender()); assert(cb);
371  m_d->updateSystemState(cb);
372 }
373 
374 
375 //___________________________________________________________________________
377 {
378 
379  assert(checkbox2system.contains(cb));
380  IVP13DSystem*sys = static_cast<IVP13DSystem*>(checkbox2system.value(cb)); assert(sys);
381 
382  assert(system2rootNodes.contains(sys));
383  SoSeparator * sysroot = system2rootNodes.value(sys);
384  int ichild = root->findChild(sysroot);
385  if (cb->isChecked()) {
386  channel->turnOn(sys);
387  if (ichild==-1)
388  root->addChild(sysroot);
389  sysroot->unref();
390  if (tabwidget&&sys2tabpage.contains(sys)) {
391  int sysindex = systemsAllowedControllers.indexOf(sys);
392  if (sysindex>=0) {
393  IVP1System*nextsystem(0);
394  for (int i=sysindex+1;i<systemsAllowedControllers.count();++i) {
395  //Loop through latter systems with controllers in order and
396  //find the first of those which currently has an active
397  //controller:
398  IVP1System* testsys = systemsAllowedControllers.at(i);
399  if (sys2tabpage.contains(testsys)&&tabwidget->indexOf(sys2tabpage[testsys])>-1) {
400  nextsystem=testsys;
401  break;
402  }
403  }
404  //put before tab of "nextsystem" (or at the end if no nextsystem):
405  int index = (nextsystem?tabwidget->indexOf(sys2tabpage[nextsystem]):99999);
406  tabwidget->insertTab(index,sys2tabpage[sys],sys->name());
407  int index2 = tabwidget->indexOf(sys2tabpage[sys]);
408  if (index2!=-1) {
409  tabwidget->setTabEnabled(index2,true);
410  }
411  }
412  }
413  } else {
414  //Fixme: if system being turned off has selections, we should deselect!!
415  channel->turnOff(sys,false);
416  assert(ichild!=-1);
417  sysroot->ref();
418  root->removeChild(ichild);
419  if (tabwidget&&sys2tabpage.contains(sys)) {
420  int index = tabwidget->indexOf(sys2tabpage[sys]);
421  if (index!=-1) {
422  tabwidget->setTabEnabled(index,false);
423  tabwidget->removeTab(index);
424  }
425  }
426  }
427 }
428 
429 //___________________________________________________________________________
431 {
433 }
434 
435 //___________________________________________________________________________
437 {
438  if (m_d->viewer->isAnimating())
439  m_d->viewer->stopAnimating();
440 }
441 
442 //___________________________________________________________________________
443 QPixmap IVP13DStandardChannelWidget::getSnapshot(bool transp, int width, bool batch)
444 {
445  VP1Msg::messageDebug("IVP13DStandardChannelWidget::getSnapshot() - transparent bkg: "+QString::number(transp)+" , width: "+QString::number(width)+" , batch: "+QString::number(batch));
446  // SoToVRML2Action tovrml2;
447  // tovrml2.apply(m_d->selection);
448  // SoVRMLGroup *newroot = tovrml2.getVRML2SceneGraph();
449  // newroot->ref();
450  // SoOutput out;
451  // out.openFile("out.wrl");
452  // out.setHeaderString("#VRML V2.0 utf8");
453  // SoWriteAction wra(&out);
454  // wra.apply(newroot);
455  // out.closeFile();
456 
457 
458  VP1Msg::messageVerbose("checkBox_as_shown: " + QString::number(m_d->uisnapshot.checkBox_as_shown->isChecked()) );
459  VP1Msg::messageVerbose("spinBox_width: " + QString::number(m_d->uisnapshot.spinBox_width->value()) );
460  VP1Msg::messageVerbose("spinBox_height: " + QString::number(m_d->uisnapshot.spinBox_height->value()) );
461  VP1Msg::messageVerbose("checkBox_transp: " + QString::number(m_d->uisnapshot.checkBox_transp->isChecked()) );
462 
463  if (m_d->uisnapshot.checkBox_as_shown->isChecked()) {
464  VP1Msg::messageVerbose("'As shown' option checked - using IVP13DChannelWidget::getSnapshot()");
466  }
467  VP1Msg::messageVerbose("'As shown' option NOT checked");
468 
469  // if width is set programmatically, we set the new value in the GUI field
470  int original_width = 0;
471  if (width) {
472  VP1Msg::messageVerbose("'width' passed at function call. Setting the value of the GUI field to: " + QString::number(width));
473  original_width = m_d->uisnapshot.spinBox_width->value();
474  m_d->uisnapshot.spinBox_width->setValue( width );
475  }
476 
477 
478  // if transparent bkg is requested programmatically, we force it
479  if (transp) {
480  VP1Msg::messageVerbose("'transp' option set - using VP1QtInventorUtils::renderToPixmap() with transp set to 'true'");
482  m_d->uisnapshot.spinBox_width->value(),
483  m_d->uisnapshot.spinBox_height->value(),
484  true);
485  }
486 
487  // if changed programatically, set the width back to the original value set by the user
488  if (width) m_d->uisnapshot.spinBox_width->setValue( original_width );
489 
490  // default, with user's preferences from the GUI
491  VP1Msg::messageVerbose("save the screenshot with the default tool (with settings from GUI) - using VP1QtInventorUtils::renderToPixmap()");
493  m_d->uisnapshot.spinBox_width->value(),
494  m_d->uisnapshot.spinBox_height->value(),
495  m_d->uisnapshot.checkBox_transp->isChecked());
496 
497  //return QPixmap(); // for DEBUG
498 
499 }
500 
501 //___________________________________________________________________________
503 {
504  VP1Msg::messageDebug("IVP13DStandardChannelWidget::setImageFromPresets()");
505 
506  disconnect(m_d->uisnapshot.spinBox_width,SIGNAL(valueChanged(int)),this,SLOT(updateSnapshotDim()));
507  disconnect(m_d->uisnapshot.spinBox_height,SIGNAL(valueChanged(int)),this,SLOT(updateSnapshotDim()));
508 
509  if (m_d->uisnapshot.radioButton_720p->isChecked()) {
510  m_d->uisnapshot.spinBox_width->setValue(1280);
511  m_d->uisnapshot.spinBox_height->setValue(720);
512  }
513  else if (m_d->uisnapshot.radioButton_1080p->isChecked()) {
514  m_d->uisnapshot.spinBox_width->setValue(1920);
515  m_d->uisnapshot.spinBox_height->setValue(1080);
516  }
517  else if (m_d->uisnapshot.radioButton_4K->isChecked()) {
518  m_d->uisnapshot.spinBox_width->setValue(4096);
519  m_d->uisnapshot.spinBox_height->setValue(2160);
520  }
521  else if (m_d->uisnapshot.radioButton_8K->isChecked()) {
522  m_d->uisnapshot.spinBox_width->setValue(8192);
523  m_d->uisnapshot.spinBox_height->setValue(4320);
524  }
525  else {
526  VP1Msg::messageDebug("ERROR! Sender unknown!!");
527  }
528 
529  connect(m_d->uisnapshot.spinBox_width,SIGNAL(valueChanged(int)),this,SLOT(updateSnapshotDim()));
530  connect(m_d->uisnapshot.spinBox_height,SIGNAL(valueChanged(int)),this,SLOT(updateSnapshotDim()));
531 
532  // update
534 }
535 
536 
537 //___________________________________________________________________________
539 {
540  VP1Msg::messageDebug("IVP13DStandardChannelWidget::updateSnapshotDim()");
541 
542  // if (!m_d->uisnapshot.checkBox_as_shown)
543 // return;
544 // if (sender()==m_d->uisnapshot.spinBox_width)
545 // m_d->uisnapshot.radioButton_width->setChecked(true);
546 // else if (sender()==m_d->uisnapshot.spinBox_height)
547 // m_d->uisnapshot.radioButton_height->setChecked(true);
548 
549  if (!m_d->uisnapshot.checkBox_as_shown)
550  return;
551 
552  if (sender()==m_d->uisnapshot.spinBox_width)
553  m_d->uisnapshot.radioButton_width->setChecked(true);
554  else if (sender()==m_d->uisnapshot.spinBox_height)
555  m_d->uisnapshot.radioButton_height->setChecked(true);
556 
557  /*
558  * Get widget width and height
559  * Note: the method "getNormalWidget" is from the "SoQtGLWidget" class
560  * and it returns a QWidget object
561  */
562  int onscreen_width = m_d->viewer->getNormalWidget()->geometry().width();
563  int onscreen_height = m_d->viewer->getNormalWidget()->geometry().height();
564 
565  if ( m_d->uisnapshot.checkBox_as_shown->isChecked() ) {
566  disconnect(m_d->uisnapshot.spinBox_width,SIGNAL(valueChanged(int)),this,SLOT(updateSnapshotDim()));
567  disconnect(m_d->uisnapshot.spinBox_height,SIGNAL(valueChanged(int)),this,SLOT(updateSnapshotDim()));
568  m_d->uisnapshot.spinBox_width->setValue(onscreen_width);
569  m_d->uisnapshot.spinBox_height->setValue(onscreen_height);
570  connect(m_d->uisnapshot.spinBox_width,SIGNAL(valueChanged(int)),this,SLOT(updateSnapshotDim()));
571  connect(m_d->uisnapshot.spinBox_height,SIGNAL(valueChanged(int)),this,SLOT(updateSnapshotDim()));
572  } else {
573  if (m_d->uisnapshot.checkBox_lockRatio->isChecked()) {
574  VP1Msg::messageDebug("checkBox_lockRatio is checked - updating only rendering size");
575  if (m_d->uisnapshot.radioButton_width->isChecked()) {
576  disconnect(m_d->uisnapshot.spinBox_height,SIGNAL(valueChanged(int)),this,SLOT(updateSnapshotDim()));
577  m_d->uisnapshot.spinBox_height->setValue(static_cast<int>(m_d->uisnapshot.spinBox_width->value()*static_cast<double>(onscreen_height)/onscreen_width+0.5));
578  connect(m_d->uisnapshot.spinBox_height,SIGNAL(valueChanged(int)),this,SLOT(updateSnapshotDim()));
579  } else {
580  disconnect(m_d->uisnapshot.spinBox_width,SIGNAL(valueChanged(int)),this,SLOT(updateSnapshotDim()));
581  m_d->uisnapshot.spinBox_width->setValue(static_cast<int>(m_d->uisnapshot.spinBox_height->value()*static_cast<double>(onscreen_width)/onscreen_height+0.5));
582  connect(m_d->uisnapshot.spinBox_width,SIGNAL(valueChanged(int)),this,SLOT(updateSnapshotDim()));
583  }
584  }
585  else {
586  VP1Msg::messageDebug("checkBox_lockRatio is NOT checked - Updating the widget size as well");
587 
588 // if (m_d->uisnapshot.radioButton_width->isChecked() ) {
589 // int newWidth = static_cast<int>(m_d->uisnapshot.spinBox_width->value() * static_cast<double>(onscreen_height) / m_d->uisnapshot.spinBox_height->value() + 0.5);
590 // m_d->viewer->getNormalWidget()->resize(newWidth, onscreen_height);
591 // } else if (m_d->uisnapshot.radioButton_height->isChecked()) {
592 // int newHeight = static_cast<int>( onscreen_width * static_cast<double>(m_d->uisnapshot.spinBox_height->value()) / m_d->uisnapshot.spinBox_width->value() + 0.5);
593 // m_d->viewer->resize(onscreen_width, newHeight);
594 // }
595 
596  }
597  }
598 
599  //Finally, ensure that we are within the ranges:
600  if (m_d->uisnapshot.spinBox_width->value()>=m_d->uisnapshot.spinBox_width->maximum()) {
601  disconnect(m_d->uisnapshot.spinBox_width,SIGNAL(valueChanged(int)),this,SLOT(updateSnapshotDim()));
602  disconnect(m_d->uisnapshot.spinBox_height,SIGNAL(valueChanged(int)),this,SLOT(updateSnapshotDim()));
603  m_d->uisnapshot.spinBox_width->setValue(m_d->uisnapshot.spinBox_width->maximum());
604  m_d->uisnapshot.spinBox_height->setValue(static_cast<int>(m_d->uisnapshot.spinBox_width->value()*static_cast<double>(onscreen_height)/onscreen_width+0.5));
605  connect(m_d->uisnapshot.spinBox_width,SIGNAL(valueChanged(int)),this,SLOT(updateSnapshotDim()));
606  connect(m_d->uisnapshot.spinBox_height,SIGNAL(valueChanged(int)),this,SLOT(updateSnapshotDim()));
607  }
608  if (m_d->uisnapshot.spinBox_height->value()>=m_d->uisnapshot.spinBox_height->maximum()) {
609  disconnect(m_d->uisnapshot.spinBox_width,SIGNAL(valueChanged(int)),this,SLOT(updateSnapshotDim()));
610  disconnect(m_d->uisnapshot.spinBox_height,SIGNAL(valueChanged(int)),this,SLOT(updateSnapshotDim()));
611  m_d->uisnapshot.spinBox_height->setValue(m_d->uisnapshot.spinBox_height->maximum());
612  m_d->uisnapshot.spinBox_width->setValue(static_cast<int>(m_d->uisnapshot.spinBox_height->value()*static_cast<double>(onscreen_width)/onscreen_width+0.5));
613  connect(m_d->uisnapshot.spinBox_width,SIGNAL(valueChanged(int)),this,SLOT(updateSnapshotDim()));
614  connect(m_d->uisnapshot.spinBox_height,SIGNAL(valueChanged(int)),this,SLOT(updateSnapshotDim()));
615  }
616 
617 }
618 
619 //___________________________________________________________________________
621 {
622  VP1Msg::messageVerbose("IVP13DStandardChannelWidget::dockResized()");
623  QTimer::singleShot(0, this, SLOT(updateSnapshotDim()));
625 }
626 
627 //___________________________________________________________________________
629 {
630  VP1Msg::messageVerbose("IVP13DStandardChannelWidget::saveState");
631 
632 
633  // NEW VERSION
634 
635 //
636 // // ===> Setup stream writing to a byteArray:
637 // QByteArray byteArray;
638 // QBuffer buffer(&byteArray);
639 // buffer.open(QIODevice::WriteOnly);
640 // QDataStream out(&buffer);
641 //
642 // /*
643 // * --- GET DATA TO BE SAVED ---
644 // */
645 //
646 // //Systems turned on/off:
647 // //Fixme: Make sure that if you have two copies of the same system,
648 // //that the text in the checkbox gets appended some stuff like [1],
649 // //[2], etc., so that the strings used here will be unique.
650 // QMap<QString, bool> sysname2turnedon;
651 // QMap<QCheckBox*,IVP1System*>::const_iterator it = m_d->checkbox2system.constBegin();
652 // while (it != m_d->checkbox2system.constEnd()) {
653 // sysname2turnedon.insert(it.key()->text(),it.key()->isChecked());
654 // ++it;
655 // }
656 //
657 //
658 // // snapshot settings
659 // bool transp_checked = m_d->uisnapshot.checkBox_transp->isChecked();
660 // bool widthfixed = m_d->uisnapshot.radioButton_width->isChecked();
661 // bool as_shown = m_d->uisnapshot.checkBox_as_shown->isChecked();
662 //
663 // bool locked_ratio = m_d->uisnapshot.checkBox_lockRatio->isChecked();
664 //
665 // qint32 width = (qint32)(m_d->uisnapshot.spinBox_width->value());
666 // qint32 height = (qint32)(m_d->uisnapshot.spinBox_height->value());
667 //
668 // // image presets
669 // bool isUsingPreset = m_d->uisnapshot.groupBox_imagePresets->isChecked();
670 // bool is720p = m_d->uisnapshot.radioButton_720p->isChecked();
671 // bool is1080p = m_d->uisnapshot.radioButton_1080p->isChecked();
672 // bool is4K = m_d->uisnapshot.radioButton_4K->isChecked();
673 // bool is8K = m_d->uisnapshot.radioButton_8K->isChecked();
674 //
675 // // active tab
676 // QString tab_index = (m_d->tabwidget ? m_d->tabwidget->tabText(m_d->tabwidget->currentIndex()) : QString("") );
677 //
678 //
679 // /*
680 // * --- WRITE DATA ---
681 // */
682 //
683 // // ------- SAVE -------
684 // out << (qint32)7; //version
685 // out << IVP13DChannelWidget::saveState();//Always include state info from the base class.
686 // out << sysname2turnedon;
687 // out << ( m_d->extradisplaywidget_splitter ? m_d->extradisplaywidget_splitter->saveState() : QByteArray() );
688 // out << m_d->viewer->saveState();
689 // out << transp_checked;
690 // out << widthfixed;
691 // out << as_shown;
692 // out << locked_ratio; // new in v. 7
693 // out << width; // new in v. 7
694 // out << height; // new in v. 7
695 // out << isUsingPreset; // new in v. 7
696 // out << is720p; // new in v. 7
697 // out << is1080p; // new in v. 7
698 // out << is4K; // new in v. 7
699 // out << is8K; // new in v. 7
700 // out << tab_index;
701 // // --------------------
702 //
703 // // ===> Finish up:
704 // buffer.close();
705 // return byteArray;
706 //
707 //
708 
709 
710 
711  // OLD VERSION
712 
713  // ===> Setup stream writing to a byteArray:
714  QByteArray byteArray;
715  QBuffer buffer(&byteArray);
716  buffer.open(QIODevice::WriteOnly);
717  QDataStream out(&buffer);
718 
719  // ===> Write Data:
720 
721  //Version & base state:
722  out << (qint32)6; //version
723  out << IVP13DChannelWidget::saveState();//Always include state info from the base class.
724 
725  //version 3 had bgd color output here;
726 
727  //Systems turned on/off:
728  //Fixme: Make sure that if you have two copies of the same system,
729  //that the text in the checkbox gets appended some stuff like [1],
730  //[2], etc., so that the strings used here will be unique.
731  QMap<QString, bool> sysname2turnedon;
732  QMap<QCheckBox*,IVP1System*>::const_iterator it = m_d->checkbox2system.constBegin();
733  while (it != m_d->checkbox2system.constEnd()) {
734  sysname2turnedon.insert(it.key()->text(),it.key()->isChecked());
735  ++it;
736  }
737 
738  //Versions 3+ follow here.
739 
740  out << sysname2turnedon;
741 
742  out << ( m_d->extradisplaywidget_splitter ? m_d->extradisplaywidget_splitter->saveState() : QByteArray() );
743 
744  out << m_d->viewer->saveState();
745 
746  //version <=3 had bool here.
747 
748  out << m_d->uisnapshot.checkBox_transp->isChecked();
749  bool widthfixed = m_d->uisnapshot.radioButton_width->isChecked();
750  bool as_shown = m_d->uisnapshot.checkBox_as_shown->isChecked();
751  out << widthfixed;
752  out << as_shown;
753  if (!as_shown)
754  out << (qint32)(widthfixed ? m_d->uisnapshot.spinBox_width->value() : m_d->uisnapshot.spinBox_height->value());
755 
756  if (m_d->tabwidget)
757  out << m_d->tabwidget->tabText(m_d->tabwidget->currentIndex());
758  else
759  out << QString("");
760 
761  //In version 5 we output a bool here.
762 
763  // ===> Finish up:
764  buffer.close();
765  return byteArray;
766 
767 
768 }
769 
770 //___________________________________________________________________________
772 {
773  VP1Msg::messageVerbose("IVP13DStandardChannelWidget::restoreFromState");
774 
775  // ===> Setup stream for getting the contents of the byteArray:
776  QBuffer buffer(&ba);
777  buffer.open(QIODevice::ReadOnly);
778  QDataStream state(&buffer);
779  // ===> Check version and pass on state info to base class:
780  qint32 version;
781  state >> version;
782 
783  message("Configuration file version: " + QString::number(version) );
784 
785  if (version<0||version>7) {
786  message("Warning: State data in .vp1 file is in wrong format - ignoring!");
787  return;
788  }
789 
790  QByteArray basestate;
791  state >> basestate;
793 
794 
795  // ===> Decode the state info:
796 
797  if (version == 7)
799 
800  if (version<=3) {
801  QColor bgdcol_dummy;
802  state >> bgdcol_dummy;
803  }
804 
805  //Switch systems on/off:
806  QMap<QString, bool> sysname2turnedon;
807  state >> sysname2turnedon;
808  QMap<QCheckBox*,IVP1System*>::const_iterator it = m_d->checkbox2system.constBegin();
809  while (it != m_d->checkbox2system.constEnd()) {
810  if (sysname2turnedon.contains(it.key()->text())) {
811  if (sysname2turnedon[it.key()->text()]!=it.key()->isChecked())
812  it.key()->setChecked(sysname2turnedon[it.key()->text()]);
813  } else {
814  message("Warning: Config data does not contain information about switched state of subsystem '"+it.key()->text()+"'");
815  }
816  ++it;
817  }
818 
819  if (version<=2) {
820  // We stop here to avoid too messy code.
821  buffer.close();
822  return;
823  }
824 
825  //Splitter:
826  QByteArray splitstate;
827  state >> splitstate;
829  m_d->extradisplaywidget_splitter->restoreState(splitstate);
830 
831  //Viewer settings:
832  QByteArray ba_viewer;
833  state >> ba_viewer;
834  m_d->viewer->restoreFromState(ba_viewer);//Fixme: reset camera???
835  m_d->need_initial_viewall = false;
836 
837  //Snapshot parameters:
838  bool aa_dummy, transp, widthfixed, as_shown;
839  if (version<=3)
840  state >> aa_dummy;
841  state >> transp; state >> widthfixed; state >> as_shown;
842  m_d->uisnapshot.checkBox_transp->setChecked(transp);
843  m_d->uisnapshot.checkBox_as_shown->setChecked(as_shown);
844  if (widthfixed) {
845  m_d->uisnapshot.radioButton_width->setChecked(true);
846  m_d->uisnapshot.radioButton_height->setChecked(false);
847  } else {
848  m_d->uisnapshot.radioButton_width->setChecked(false);
849  m_d->uisnapshot.radioButton_height->setChecked(true);
850  }
851  if (!as_shown) {
852  qint32 fixval;
853  state >> fixval;
854  if (widthfixed)
855  m_d->uisnapshot.spinBox_width->setValue(fixval);
856  else
857  m_d->uisnapshot.spinBox_height->setValue(fixval);
858  }
859 
860  QString tabname;
861  state >> tabname;
862  if (m_d->tabwidget) {
863  for (int i = 0; i < m_d->tabwidget->count(); ++i) {
864  if (m_d->tabwidget->tabText(i) == tabname) {
865  m_d->tabwidget->setCurrentIndex(i);
866  break;
867  }
868  }
869  }
870 
871  if (version==5) {
872  bool b;
873  state >> b;
874  }
875 
876 
877  // ===> Finish up:
878  buffer.close();
879 }
880 
881 //___________________________________________________________________________
883 {
884  if (!m_d->tabwidget)
885  return;
886  IVP1System * sys = static_cast<IVP1System*>(sender());
887  if (!sys) {
888  message("showControlsForSystem Error: Unable to determine system identity.");
889  return;
890  }
891  if (!m_d->sys2tabpage.contains(sys)) {
892  //Dont send warning here. The system in question might simply not have a controller!
893  return;
894  }
895 
896  int index = m_d->tabwidget->indexOf(m_d->sys2tabpage[sys]);
897  if (index<0||!m_d->tabwidget->isTabEnabled(index)) {
898  message("Warning: Asked to show controller for a disabled system. Surely you jest?");
899  return;
900  }
901  m_d->tabwidget->setCurrentIndex(index);
902 }
903 
904 
905 //___________________________________________________________________________
907 
908  VP1Msg::messageVerbose("IVP13DStandardChannelWidget::Imp::restoreFromState_v7");
909 
910  /*
911  * --- VARIABLES TO BE RESTORED ---
912  */
913  //Switch systems on/off:
914  QMap<QString, bool> sysname2turnedon;
915  //Splitter:
916  QByteArray splitstate;
917  //Viewer settings:
918  QByteArray ba_viewer;
919  // Snapshot parameters:
920  bool transp, widthfixed, as_shown;
921  bool locked_ratio;
922  qint32 width, height;
923  // image format presets
924  bool isUsingPresets;
925  bool is720p;
926  bool is1080p;
927  bool is4K;
928  bool is8K;
929  // Active tab
930  QString tabname;
931 
932 
933  /*
934  * ------- GET STATE -------
935  */
936  // 'version' restored already
937  // 'basestate' restored already
938  state >> sysname2turnedon;
939  state >> splitstate;
940  state >> ba_viewer;
941  state >> transp;
942  state >> widthfixed;
943  state >> as_shown;
944  state >> locked_ratio;
945  state >> width;
946  state >> height;
947  state >> isUsingPresets;
948  state >> is720p;
949  state >> is1080p;
950  state >> is4K;
951  state >> is8K;
952  state >> tabname;
953  // -------------------------
954 
955 
956 
957 
958  /*
959  * --- RESTORE VARIABLES ---
960  */
961 
962  //Switch systems on/off:
963  QMap<QCheckBox*,IVP1System*>::const_iterator it = checkbox2system.constBegin();
964  while (it != checkbox2system.constEnd()) {
965  if (sysname2turnedon.contains(it.key()->text())) {
966  if (sysname2turnedon[it.key()->text()]!=it.key()->isChecked())
967  it.key()->setChecked(sysname2turnedon[it.key()->text()]);
968  } else {
969  channel->message("Warning: Config data does not contain information about switched state of subsystem '"+it.key()->text()+"'");
970  }
971  ++it;
972  }
973 
974 
975  //Splitter:
976  if (extradisplaywidget_splitter)
977  extradisplaywidget_splitter->restoreState(splitstate);
978 
979  //Viewer settings:
980  viewer->restoreFromState(ba_viewer);//Fixme: reset camera???
981  need_initial_viewall = false;
982 
983 
984  // Snapshot parameters - Set Width and Height
985  uisnapshot.checkBox_transp->setChecked(transp);
986  uisnapshot.checkBox_as_shown->setChecked(as_shown);
987  if (widthfixed) {
988  uisnapshot.radioButton_width->setChecked(true);
989  uisnapshot.radioButton_height->setChecked(false);
990  } else {
991  uisnapshot.radioButton_width->setChecked(false);
992  uisnapshot.radioButton_height->setChecked(true);
993  }
994  if (!as_shown) {
995  uisnapshot.spinBox_width->setValue(width);
996  uisnapshot.spinBox_height->setValue(height);
997  }
998 
999  // image format presets
1000  if (isUsingPresets)
1001  uisnapshot.groupBox_imagePresets->setChecked(true);
1002  if (is720p)
1003  uisnapshot.radioButton_720p->setChecked(true);
1004  else if (is1080p)
1005  uisnapshot.radioButton_1080p->setChecked(true);
1006  else if (is4K)
1007  uisnapshot.radioButton_4K->setChecked(true);
1008  else if (is8K)
1009  uisnapshot.radioButton_8K->setChecked(true);
1010 
1011 
1012  // Set active tab
1013  if (tabwidget) {
1014  for (int i = 0; i < tabwidget->count(); ++i) {
1015  if (tabwidget->tabText(i) == tabname) {
1016  tabwidget->setCurrentIndex(i);
1017  break;
1018  }
1019  }
1020  }
1021 }
1022 
1023 
IVP1ChannelWidget::registerSystem
void registerSystem(IVP1System *)
Definition: IVP1ChannelWidget.cxx:221
IVP13DStandardChannelWidget::DisallowExtraDisplayWidget
@ DisallowExtraDisplayWidget
Definition: IVP13DStandardChannelWidget.h:35
base
std::string base
Definition: hcg.cxx:78
IVP13DStandardChannelWidget::Imp::detectorViewButtons
bool detectorViewButtons
Definition: IVP13DStandardChannelWidget.cxx:49
IVP13DStandardChannelWidget::create
void create()
Definition: IVP13DStandardChannelWidget.cxx:168
VP1TabWidget::tabText
QString tabText(int) const
Definition: VP1TabWidget.cxx:291
IVP13DStandardChannelWidget::lastOfActiveSystemsRefreshed
virtual void lastOfActiveSystemsRefreshed()
Definition: IVP13DStandardChannelWidget.cxx:331
IVP13DStandardChannelWidget::setAntiAliasing
bool setAntiAliasing(bool)
Definition: IVP13DStandardChannelWidget.cxx:93
IVP13DSystemSimple
Definition: IVP13DSystemSimple.h:24
plotting.yearwise_efficiency.channel
channel
Definition: yearwise_efficiency.py:24
IVP13DStandardChannelWidget::Imp::extradisplaywidget_splitter
QSplitter * extradisplaywidget_splitter
Definition: IVP13DStandardChannelWidget.cxx:77
IVP13DStandardChannelWidget::Imp::systemsAllowedExtraDisplayWidgets
QList< IVP13DSystem * > systemsAllowedExtraDisplayWidgets
Definition: IVP13DStandardChannelWidget.cxx:57
IVP13DStandardChannelWidget::setImageFromPresets
void setImageFromPresets()
Definition: IVP13DStandardChannelWidget.cxx:502
index
Definition: index.py:1
VP1Msg.h
IVP13DStandardChannelWidget::updateSnapshotDim
void updateSnapshotDim()
Definition: IVP13DStandardChannelWidget.cxx:538
IVP13DStandardChannelWidget::Imp::need_initial_viewall
bool need_initial_viewall
Definition: IVP13DStandardChannelWidget.cxx:52
fillPileUpNoiseLumi.connect
string connect
Definition: fillPileUpNoiseLumi.py:70
IVP13DStandardChannelWidget::StartDisabled
@ StartDisabled
Definition: IVP13DStandardChannelWidget.h:38
IVP13DStandardChannelWidget::Imp::sys2tabpage
QMap< IVP1System *, QWidget * > sys2tabpage
Definition: IVP13DStandardChannelWidget.cxx:74
IVP13DStandardChannelWidget::saveState
virtual QByteArray saveState()
Definition: IVP13DStandardChannelWidget.cxx:628
VP1ExaminerViewer::setSceneGraph
virtual void setSceneGraph(SoNode *)
Definition: VP1ExaminerViewer.cxx:3115
CSV_InDetExporter.new
new
Definition: CSV_InDetExporter.py:145
IVP1ChannelWidget::dockResized
virtual void dockResized()
Definition: IVP1ChannelWidget.cxx:315
skel.it
it
Definition: skel.GENtoEVGEN.py:396
VP1QtUtils.h
IVP1ChannelWidget::registerController
void registerController(QWidget *)
Definition: IVP1ChannelWidget.cxx:210
IVP13DChannelWidget::saveState
virtual QByteArray saveState()
Definition: IVP13DChannelWidget.cxx:180
python.AthDsoLogger.out
out
Definition: AthDsoLogger.py:71
IVP13DStandardChannelWidget::DisallowSwitchable
@ DisallowSwitchable
Definition: IVP13DStandardChannelWidget.h:36
IVP13DStandardChannelWidget::systemRefreshed
virtual void systemRefreshed(IVP1System *)
Definition: IVP13DStandardChannelWidget.cxx:355
IVP13DStandardChannelWidget::launchStereoEditor
void launchStereoEditor()
Definition: IVP13DStandardChannelWidget.cxx:86
IVP13DChannelWidget
Definition: IVP13DChannelWidget.h:25
sendEI_SPB.root
root
Definition: sendEI_SPB.py:34
Preparation.batch
batch
Definition: Preparation.py:49
VP1QtUtils::expertSettingValue
static QString expertSettingValue(const QString &type, const QString &name)
Definition: VP1QtUtils.cxx:43
IVP13DStandardChannelWidget::systemErased
virtual void systemErased(IVP1System *)
Definition: IVP13DStandardChannelWidget.cxx:360
IVP13DSystemSimple.h
VP1ExaminerViewer::setTransparencyType
virtual void setTransparencyType(SoGLRenderAction::TransparencyType)
Definition: VP1ExaminerViewer.cxx:1731
IVP13DStandardChannelWidget::Imp::setupSplitter
void setupSplitter(QWidget *rightwidget)
Definition: IVP13DStandardChannelWidget.cxx:272
IVP13DStandardChannelWidget::Imp::uisnapshot
Ui::VP13DStandardChannelSnapShotGroupBox uisnapshot
Definition: IVP13DStandardChannelWidget.cxx:64
x
#define x
VP1ColorSelectButton
Definition: VP1ColorSelectButton.h:20
mapkey::sys
@ sys
Definition: TElectronEfficiencyCorrectionTool.cxx:42
VP1ExaminerViewer::viewAll
virtual void viewAll()
Definition: VP1ExaminerViewer.cxx:1457
VP1QtUtils::environmentVariableValue
static QString environmentVariableValue(const QString &name)
Definition: VP1QtUtils.cxx:117
IVP13DStandardChannelWidget::isAntiAliasing
bool isAntiAliasing()
Definition: IVP13DStandardChannelWidget.cxx:100
IVP13DSystem::getSceneGraph
virtual SoSeparator * getSceneGraph() const =0
VP1TabWidget
Definition: VP1TabWidget.h:45
IVP13DStandardChannelWidget::DisallowController
@ DisallowController
Definition: IVP13DStandardChannelWidget.h:37
VP1QtInventorUtils.h
IVP13DStandardChannelWidget::DisallowCameraAccess
@ DisallowCameraAccess
Definition: IVP13DStandardChannelWidget.h:39
IVP13DStandardChannelWidget::Imp::system2rootNodes
QMap< IVP13DSystem *, SoSeparator * > system2rootNodes
Definition: IVP13DStandardChannelWidget.cxx:53
IVP13DStandardChannelWidget::toggleSystemActive
void toggleSystemActive()
Definition: IVP13DStandardChannelWidget.cxx:368
IVP13DStandardChannelWidget::Imp::root
SoSeparator * root
Definition: IVP13DStandardChannelWidget.cxx:50
IVP1System
Definition: IVP1System.h:36
createCoolChannelIdFile.buffer
buffer
Definition: createCoolChannelIdFile.py:12
VP1ExaminerViewer.h
IVP13DChannelWidget::restoreFromState
virtual void restoreFromState(QByteArray)
Definition: IVP13DChannelWidget.cxx:214
IVP13DStandardChannelWidget::dockResized
void dockResized()
Definition: IVP13DStandardChannelWidget.cxx:620
lumiFormat.i
int i
Definition: lumiFormat.py:85
IVP13DStandardChannelWidget::Imp::systemsAllowedCameraList
QList< IVP13DSystem * > systemsAllowedCameraList
Definition: IVP13DStandardChannelWidget.cxx:60
IVP13DStandardChannelWidget.h
IVP13DStandardChannelWidget
Definition: IVP13DStandardChannelWidget.h:24
IVP13DSystem.h
VP1ExaminerViewer::startTour
void startTour()
Definition: VP1ExaminerViewer.cxx:1164
VP1ExaminerViewer::restoreFromState
virtual void restoreFromState(QByteArray)
Definition: VP1ExaminerViewer.cxx:764
IVP13DStandardChannelWidget::IVP13DStandardChannelWidget
IVP13DStandardChannelWidget(const QString &name, const QString &information, const QString &contact_info, bool detectorViewButtons=true)
Definition: IVP13DStandardChannelWidget.cxx:106
VP1QtUtils::environmentVariableIsSet
static bool environmentVariableIsSet(const QString &name)
Definition: VP1QtUtils.cxx:108
IVP1ChannelWidget::message
void message(QString)
python.AtlRunQueryLib.options
options
Definition: AtlRunQueryLib.py:379
IVP13DStandardChannelWidget::Imp::system2startdisabled
QMap< IVP1System *, bool > system2startdisabled
Definition: IVP13DStandardChannelWidget.cxx:59
IVP13DStandardChannelWidget::Imp::autoSnapshot
void autoSnapshot()
Definition: IVP13DStandardChannelWidget.cxx:291
VP1ExaminerViewer::launchStereoEditor
void launchStereoEditor()
Definition: VP1ExaminerViewer.cxx:2944
DeMoScan.runnumber
runnumber
Definition: DeMoScan.py:266
IVP13DChannelWidget::getSnapshot
virtual QPixmap getSnapshot(bool transp=false, int width=0, bool batch=false)
Definition: IVP13DChannelWidget.cxx:131
IVP13DStandardChannelWidget::Imp
Definition: IVP13DStandardChannelWidget.cxx:46
IVP13DStandardChannelWidget::Imp::viewer
VP1ExaminerViewer * viewer
Definition: IVP13DStandardChannelWidget.cxx:51
IVP13DStandardChannelWidget::Imp::checkbox2system
QMap< QCheckBox *, IVP1System * > checkbox2system
Definition: IVP13DStandardChannelWidget.cxx:55
VP1ExaminerViewer::startTourEachEvent
bool startTourEachEvent() const
Definition: VP1ExaminerViewer.cxx:1172
SoCooperativeSelection::ensureInitClass
static void ensureInitClass()
Definition: SoCooperativeSelection.cxx:26
IVP1ChannelWidget::state
State state() const
Definition: IVP1ChannelWidget.cxx:102
SoCooperativeSelection.h
Trk::index2
@ index2
Definition: BoundarySurfaceFace.h:49
IVP13DStandardChannelWidget::addSystem
void addSystem(IVP13DSystem *, const SystemOptions &options=AllowAll)
Definition: IVP13DStandardChannelWidget.cxx:135
VP1ExaminerViewer::setAntiAlias
void setAntiAlias(bool)
Definition: VP1ExaminerViewer.cxx:1752
python.selection.number
number
Definition: selection.py:20
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:221
plotBeamSpotMon.b
b
Definition: plotBeamSpotMon.py:77
IVP13DStandardChannelWidget::Imp::channel
IVP13DStandardChannelWidget * channel
Definition: IVP13DStandardChannelWidget.cxx:48
IVP13DStandardChannelWidget::m_d
Imp * m_d
Definition: IVP13DStandardChannelWidget.h:70
VP1Msg::messageVerbose
static void messageVerbose(const QString &)
Definition: VP1Msg.cxx:84
VP1TabWidget.h
IVP13DChannelWidget::registerRenderArea
void registerRenderArea(VP1ExaminerViewer *)
Definition: IVP13DChannelWidget.cxx:94
get_generator_info.version
version
Definition: get_generator_info.py:33
VP1Msg::messageDebug
static void messageDebug(const QString &)
Definition: VP1Msg.cxx:39
y
#define y
IVP13DStandardChannelWidget::Imp::system2switchable
QList< QPair< IVP1System *, bool > > system2switchable
Definition: IVP13DStandardChannelWidget.cxx:58
Base_Fragment.width
width
Definition: Sherpa_i/share/common/Base_Fragment.py:59
IVP13DStandardChannelWidget::Imp::tabwidget
VP1TabWidget * tabwidget
Definition: IVP13DStandardChannelWidget.cxx:75
VP1ControllerHelper::compositionController
static QWidget * compositionController(const QList< IVP1System * > &systemsWithControllersAllowed, QMap< IVP1System *, QWidget * > &sys2tabpage, VP1TabWidget *&tabwidget, const QList< QPair< IVP1System *, bool > > &system2switchable, QMap< QCheckBox *, IVP1System * > &checkbox2system, VP1ColorSelectButton *&colorselectbutton, QWidget *extrawidget=0, bool nobgdcolorsel=false)
Definition: VP1ControllerHelper.cxx:28
IVP13DSystem
Definition: IVP13DSystem.h:31
IVP13DStandardChannelWidget::showControlsForSystem
void showControlsForSystem()
Definition: IVP13DStandardChannelWidget.cxx:882
VP1QtInventorUtils::renderToPixmap
static QPixmap renderToPixmap(VP1ExaminerViewer *ra, int pixels_x, int pixels_y, bool transparent_background=false, double actualRenderedSizeFact=1.0)
Definition: VP1QtInventorUtils.cxx:595
IVP13DStandardChannelWidget::stopSpinning
void stopSpinning()
Definition: IVP13DStandardChannelWidget.cxx:436
IVP13DStandardChannelWidget::restoreFromState
virtual void restoreFromState(QByteArray)
Definition: IVP13DStandardChannelWidget.cxx:771
VP1ExaminerViewer::storeCameraParametersForReset
void storeCameraParametersForReset()
Definition: VP1ExaminerViewer.cxx:1814
python.dummyaccess.exists
def exists(filename)
Definition: dummyaccess.py:9
VP1ExaminerViewer::saveState
virtual QByteArray saveState()
Definition: VP1ExaminerViewer.cxx:638
IVP13DStandardChannelWidget::Imp::restoreFromState_v7
void restoreFromState_v7(QDataStream &state)
Definition: IVP13DStandardChannelWidget.cxx:906
VP1ControllerHelper.h
IVP13DStandardChannelWidget::Imp::min3dx
static const int min3dx
Definition: IVP13DStandardChannelWidget.cxx:70
test_AnalysisBaseEventLoopJob.aa
aa
Definition: test_AnalysisBaseEventLoopJob.py:37
IVP13DStandardChannelWidget::~IVP13DStandardChannelWidget
virtual ~IVP13DStandardChannelWidget()
Definition: IVP13DStandardChannelWidget.cxx:128
IVP13DStandardChannelWidget::getSnapshot
virtual QPixmap getSnapshot(bool transp=false, int width=0, bool batch=false)
Definition: IVP13DStandardChannelWidget.cxx:443
IVP13DStandardChannelWidget::Imp::updateSystemState
void updateSystemState(QCheckBox *)
Definition: IVP13DStandardChannelWidget.cxx:376
IVP13DSystem::deselectAll
virtual void deselectAll(SoCooperativeSelection *exception_sel=0)
Definition: IVP13DSystem.cxx:331
IVP13DStandardChannelWidget::Imp::systemsAllowedControllers
QList< IVP1System * > systemsAllowedControllers
Definition: IVP13DStandardChannelWidget.cxx:56
VP1ExaminerViewer
Definition: VP1ExaminerViewer.h:30
IVP13DStandardChannelWidget::Imp::min3dy
static const int min3dy
Definition: IVP13DStandardChannelWidget.cxx:71
VP1ExaminerViewer::isAntiAlias
bool isAntiAlias() const
Definition: VP1ExaminerViewer.cxx:1743