14 #define VP1IMPVARNAME m_d
17 #include "ui_vp1prdcontrollerform.h"
18 #include "ui_prd_settings_cuts_form.h"
19 #include "ui_prd_settings_display_form.h"
20 #include "ui_prd_settings_interactions_form.h"
26 #include <Inventor/nodes/SoMaterial.h>
35 Ui::VP1PrdControllerForm
ui{};
36 Ui::PRDSysSettingsInteractionsForm
ui_int{};
89 m_d->
ui.setupUi(
this);
103 m_d->
ui_cuts.groupBox_cuts_tracksegmentassociation->setVisible(
false);
105 m_d->
ui_int.groupBox_selectionMode->setVisible(
false);
107 m_d->
ui_disp.widget_drawOptions_PixelSCT->setComplexityDisabled();
108 m_d->
ui_disp.widget_drawOptions_Muons->setPointSizesDisabled();
109 m_d->
ui_disp.widget_drawOptions_PixelSCT->setPointSizes(3.0);
110 m_d->
ui_disp.widget_drawOptions_TRT->setPointSizes(2.0);
112 m_d->
ui_cuts.etaPhiCutWidget->setEtaCutEnabled(
false);
293 return m_d->
ui_disp.widget_drawOptions_TRT->drawOptionsGroup();
297 return m_d->
ui_disp.widget_drawOptions_PixelSCT->drawOptionsGroup();
299 return m_d->
ui_disp.widget_drawOptions_Muons->drawOptionsGroup();
306 QSet<PRDDetType::Type>
s;
319 QList<SoMaterial*> mats =
m_d->
ui_int.matButton_multiselline->handledMaterials();
320 if (mats.count()!=1) {
321 message(
"ERROR: No material in button!");
350 return m_d->
ui_int.checkBox_printinfo->isChecked();
356 return m_d->
ui_int.checkBox_zoom->isChecked();
368 return m_d->
ui_cuts.etaPhiCutWidget->allowedEta();
374 return m_d->
ui_cuts.etaPhiCutWidget->allowedPhi();
391 return m_d->
ui_cuts.checkbox_cut_trt_TotMin->isChecked() ?
m_d->
ui_cuts.spinBox_cut_trt_ToTMin->value() : 0;
397 return m_d->
ui_cuts.checkbox_cut_trt_TotMax->isChecked() ?
m_d->
ui_cuts.spinBox_cut_trt_ToTMax->value() : 24;
403 return m_d->
ui_cuts.checkbox_cut_trt_LeMin->isChecked() ?
m_d->
ui_cuts.spinBox_cut_trt_LEMin->value() : 0;
409 return m_d->
ui_cuts.checkbox_cut_trt_LeMax->isChecked() ?
m_d->
ui_cuts.spinBox_cut_trt_LEMax->value() : 24;
415 return m_d->
ui_cuts.checkbox_cut_trt_needHT->isChecked();
422 return m_d->
ui_cuts.checkBox_cut_pixel_minnrdo->isChecked() ?
m_d->
ui_cuts.spinBox_cut_pixel_minnrdo->value() : 0;
430 return m_d->
ui_cuts.checkBox_cut_sct_excludeisolatedclusters->isChecked();
436 return m_d->
ui_cuts.checkBox_cut_mdt_excludeisolateddrifttubes->isChecked() ? 2 : 0;
442 double lower =
m_d->
ui_cuts.checkBox_cut_mdt_ADClowerbound->isChecked() ?
444 double upper =
m_d->
ui_cuts.checkBox_cut_mdt_ADCupperbound->isChecked() ?
453 return m_d->
ui_cuts.checkBox_cut_mdt_excludemaskedhits->isChecked();
459 return m_d->
ui_cuts.comboBox_mdt_cutMdtDriftCircleStatus->currentText();
465 return m_d->
ui_cuts.checkBox_cut_mdt_limitToActiveChambers->isChecked();
471 if (
m_d->
ui_disp.checkBox_colourByTrack->isChecked()) {
472 if (
m_d->
ui_disp.checkBox_colourBySegment->isChecked())
477 if (
m_d->
ui_disp.checkBox_colourBySegment->isChecked())
487 if (
m_d->
ui_disp.checkBox_drawErrors->isChecked())
return true;
494 if (
m_d->
ui_disp.checkBox_drawRDOs->isChecked())
return true;
503 &&
m_d->
ui_disp.checkBox_highlight_trackoutliers->isChecked() &&
m_d->
ui_disp.checkBox_colourByTrack->isChecked();
509 const bool outlierHLEnabledInGui(
m_d->
ui_disp.checkBox_highlight_trackoutliers->isChecked() &&
m_d->
ui_disp.checkBox_colourByTrack->isChecked());
510 m_d->
ui_disp.checkBox_highlight_trtht->setEnabled(!outlierHLEnabledInGui);
511 m_d->
ui_disp.checkBox_highlight_maskedmdts->setEnabled(!outlierHLEnabledInGui);
512 m_d->
ui_disp.checkBox_highlight_mdt_ADC_below->setEnabled(!outlierHLEnabledInGui);
513 m_d->
ui_disp.spinBox_highlight_mdt_ADC_below->setEnabled(!outlierHLEnabledInGui);
537 ?
m_d->
ui_disp.spinBox_highlight_mdt_ADC_below->value() : -1;
544 int val =
m_d->
ui_disp.horizontalSlider_highlights_intensity->value();
545 if (
val<=1)
return 0.0;
546 if (
val==2)
return 1.0;
547 if (
val==3)
return 1.9;
548 if (
val==4)
return 2.8;
549 if (
val==5)
return 5.0;
610 return m_d->
ui_int.checkBox_selModeMultiple->isChecked();
616 return m_d->
ui_int.checkBox_showSelectionLine->isChecked();
622 std::set<PRDDetType::Type>
s;
624 for(qint32
i :
collWidget()->visibleStdCollectionTypes()) {
630 message(
"shownCollectionTypes ERROR: Could not decode collection type");
647 s.save(
m_d->
ui_disp.checkBox_highlight_trackoutliers);
649 s.save(
m_d->
ui_disp.checkBox_highlight_maskedmdts);
655 s.save(
m_d->
ui_cuts.checkBox_cut_sct_excludeisolatedclusters);
659 s.save(
m_d->
ui_cuts.checkBox_cut_mdt_excludeisolateddrifttubes);
660 s.save(
m_d->
ui_disp.checkBox_highlight_mdt_ADC_below);
661 s.save(
m_d->
ui_cuts.checkBox_cut_mdt_excludemaskedhits);
662 s.save(
m_d->
ui_cuts.checkBox_cut_mdt_ADClowerbound);
663 s.save(
m_d->
ui_cuts.checkBox_cut_mdt_ADCupperbound);
672 s.save(
m_d->
ui_disp.horizontalSlider_highlights_intensity);
676 s.save(
m_d->
ui_disp.spinBox_highlight_mdt_ADC_below);
677 s.save(
m_d->
ui_cuts.spinBox_cut_mdt_ADClowerbound);
678 s.save(
m_d->
ui_cuts.spinBox_cut_mdt_ADCupperbound);
679 s.save(
m_d->
ui_disp.materialbutton_highlights_material);
681 s.save(
m_d->
ui_int.checkBox_showSelectionLine);
689 s.save(
m_d->
ui_int.checkBox_zoom_orientToMuonChamber);
699 s.save(
m_d->
ui_cuts.comboBox_mdt_cutMdtDriftCircleStatus);
700 s.save(
m_d->
ui_cuts.checkBox_cut_mdt_limitToActiveChambers);
703 s.ignoreWidget(
m_d->
ui_cuts.checkBox_cuts_ts_exclude_hits_on_track);
704 s.ignoreWidget(
m_d->
ui_cuts.checkBox_cuts_ts_exclude_hits_not_on_track);
705 s.ignoreWidget(
m_d->
ui_cuts.checkBox_cuts_ts_exclude_hits_on_segments);
706 s.ignoreWidget(
m_d->
ui_cuts.checkBox_cuts_ts_exclude_not_on_segments);
714 if (
s.version()<0||
s.version()>3) {
715 message(
"Warning: State data in .vp1 file has unsupported version ("+
str(
s.version())+
")");
720 s.restore(
m_d->
ui_disp.checkBox_highlight_trackoutliers);
722 s.restore(
m_d->
ui_disp.checkBox_highlight_maskedmdts);
723 s.restore(
m_d->
ui_cuts.checkBox_cut_indet_barrelA);
724 s.restore(
m_d->
ui_cuts.checkBox_cut_indet_barrelC);
725 s.restore(
m_d->
ui_cuts.checkBox_cut_indet_endcapA);
726 s.restore(
m_d->
ui_cuts.checkBox_cut_indet_endcapC);
727 s.restore(
m_d->
ui_cuts.checkBox_cut_pixel_minnrdo);
728 s.restore(
m_d->
ui_cuts.checkBox_cut_sct_excludeisolatedclusters);
732 s.restore(
m_d->
ui_cuts.checkBox_cut_mdt_excludeisolateddrifttubes);
733 s.restore(
m_d->
ui_disp.checkBox_highlight_mdt_ADC_below);
734 s.restore(
m_d->
ui_cuts.checkBox_cut_mdt_excludemaskedhits);
735 s.restore(
m_d->
ui_cuts.checkBox_cut_mdt_ADClowerbound);
736 s.restore(
m_d->
ui_cuts.checkBox_cut_mdt_ADCupperbound);
737 s.restore(
m_d->
ui_disp.checkBox_showpixel_projected);
738 s.restore(
m_d->
ui_disp.checkBox_showsct_projected);
739 s.restore(
m_d->
ui_disp.checkBox_showtrt_projected);
740 s.restore(
m_d->
ui_disp.checkBox_showmdt_projected);
741 s.restore(
m_d->
ui_disp.checkBox_showrpc_projected);
742 s.restore(
m_d->
ui_disp.checkBox_showcsc_projected);
743 s.restore(
m_d->
ui_disp.checkBox_showtgc_projected);
745 s.restore(
m_d->
ui_disp.horizontalSlider_highlights_intensity);
749 s.restore(
m_d->
ui_disp.spinBox_highlight_mdt_ADC_below);
750 s.restore(
m_d->
ui_cuts.spinBox_cut_mdt_ADClowerbound);
751 s.restore(
m_d->
ui_cuts.spinBox_cut_mdt_ADCupperbound);
752 s.restore(
m_d->
ui_disp.materialbutton_highlights_material);
753 s.restore(
m_d->
ui_int.checkBox_selModeMultiple);
754 s.restore(
m_d->
ui_int.checkBox_showSelectionLine);
755 s.restore(
m_d->
ui_int.matButton_multiselline);
757 s.restore(
m_d->
ui_disp.widget_drawOptions_PixelSCT);
762 s.restore(
m_d->
ui_int.checkBox_zoom_orientToMuonChamber);
764 if (
s.version()>=1) {
771 if (
s.version()>=2) {
776 if (
s.version()>=3) {
777 s.restore(
m_d->
ui_cuts.comboBox_mdt_cutMdtDriftCircleStatus);
778 s.restore(
m_d->
ui_cuts.checkBox_cut_mdt_limitToActiveChambers);
782 s.ignoreWidget(
m_d->
ui_cuts.checkBox_cuts_ts_exclude_hits_on_track);
783 s.ignoreWidget(
m_d->
ui_cuts.checkBox_cuts_ts_exclude_hits_not_on_track);
784 s.ignoreWidget(
m_d->
ui_cuts.checkBox_cuts_ts_exclude_hits_on_segments);
785 s.ignoreWidget(
m_d->
ui_cuts.checkBox_cuts_ts_exclude_not_on_segments);
791 #define VP1CONTROLLERCLASSNAME PRDSystemController