diff --git a/slsDetectorGui/forms/form_tab_plot.ui b/slsDetectorGui/forms/form_tab_plot.ui
index 241c8e944..e16c6ae46 100644
--- a/slsDetectorGui/forms/form_tab_plot.ui
+++ b/slsDetectorGui/forms/form_tab_plot.ui
@@ -99,7 +99,7 @@
- 0
+ 4
@@ -548,7 +548,7 @@
25
5
- 314
+ 335
26
@@ -587,7 +587,7 @@ Displays minimum, maximum and sum of values for each plot.
- 100
+ 10
10
@@ -596,7 +596,7 @@ Displays minimum, maximum and sum of values for each plot.
-
- true
+ false
@@ -614,6 +614,43 @@ Displays minimum, maximum and sum of values for each plot.
+ -
+
+
+ Qt::Horizontal
+
+
+ QSizePolicy::Fixed
+
+
+
+ 10
+ 10
+
+
+
+
+ -
+
+
+ false
+
+
+
+ 0
+ 0
+
+
+
+ <nobr>
+Displays minimum, maximum and sum of values for each plot.
+<nobr>
+
+
+ Gap Pixels
+
+
+
@@ -1695,7 +1732,7 @@ Displays minimum, maximum and sum of values for each plot.
10
20
- 331
+ 357
26
@@ -2522,7 +2559,7 @@ Interval between plots has 2 modes. A condition to be satisfied, in order to avo
10
12
- 331
+ 365
36
diff --git a/slsDetectorGui/include/qTabPlot.h b/slsDetectorGui/include/qTabPlot.h
index 92fcae92a..b2dbbd208 100644
--- a/slsDetectorGui/include/qTabPlot.h
+++ b/slsDetectorGui/include/qTabPlot.h
@@ -174,6 +174,9 @@ private slots:
/** Set histogram options */
void SetHistogramOptions();
+ /** Enable Gap pixels */
+ void EnableGapPixels(bool enable);
+
signals:
void DisableZoomSignal(bool);
void ResetZMinZMaxSignal(bool,bool,double,double);
diff --git a/slsDetectorGui/src/qTabPlot.cpp b/slsDetectorGui/src/qTabPlot.cpp
index 3f599ed78..cbcda6ec5 100644
--- a/slsDetectorGui/src/qTabPlot.cpp
+++ b/slsDetectorGui/src/qTabPlot.cpp
@@ -156,9 +156,6 @@ void qTabPlot::SetupWidgetWindow(){
stackedWidget->setCurrentIndex(0);
stackedWidget_2->setCurrentIndex(0);
- //gain plot
- chkGainPlot->setEnabled(false);
-
// Depending on whether the detector is 1d or 2d
switch(myDet->getDetectorsType()){
case slsDetectorDefs::MYTHEN:
@@ -174,6 +171,7 @@ void qTabPlot::SetupWidgetWindow(){
pagePedestal_2->setEnabled(false);
chkBinary->setEnabled(false);
chkBinary_2->setEnabled(false);
+ chkGapPixels->setEnabled(true);
break;
case slsDetectorDefs::GOTTHARD:
isOriginallyOneD = true;
@@ -202,6 +200,12 @@ void qTabPlot::SetupWidgetWindow(){
//disable histogram initially
boxHistogram->hide();
+ if (chkGapPixels->isEnabled()) {
+ int ret = myDet->enableGapPixels(-1);
+ qDefs::checkErrorMessage(myDet,"qTabPlot::SetupWidgetWindow");
+ chkGapPixels->setChecked((ret == 1) ? true : false);
+ }
+
qDefs::checkErrorMessage(myDet,"qTabPlot::SetupWidgetWindow");
}
@@ -376,6 +380,10 @@ void qTabPlot::Initialization(){
//gainplot
if (chkGainPlot->isEnabled())
connect(chkGainPlot, SIGNAL(toggled(bool)),myPlot, SIGNAL(GainPlotSignal(bool)));
+
+ // gap pixels
+ if (chkGapPixels->isEnabled())
+ connect(chkGapPixels, SIGNAL(toggled(bool)),this, SLOT(EnableGapPixels(bool)));
}
@@ -1471,6 +1479,24 @@ void qTabPlot::SetHistogramOptions(){
+//-------------------------------------------------------------------------------------------------------------------------------------------------
+
+
+void qTabPlot::EnableGapPixels(bool enable) {
+#ifdef VERBOSE
+ cout << "Setting Gap pixels to " << enable << endl;
+#endif
+ disconnect(chkGapPixels, SIGNAL(toggled(bool)),this, SLOT(EnableGapPixels(bool)));
+
+ myDet->enableGapPixels(enable);
+ int ret = myDet->enableGapPixels(-1);
+ qDefs::checkErrorMessage(myDet,"qTabPlot::SetScanArgument");
+ chkGapPixels->setChecked((ret == 1) ? true : false);
+
+ connect(chkGapPixels, SIGNAL(toggled(bool)),this, SLOT(EnableGapPixels(bool)));
+}
+
+
//-------------------------------------------------------------------------------------------------------------------------------------------------
@@ -1487,6 +1513,14 @@ void qTabPlot::Refresh(){
comboFrequency->setCurrentIndex(1);*/
SetFrequency();
+ if (chkGapPixels->isEnabled()) {
+ disconnect(chkGapPixels, SIGNAL(toggled(bool)),this, SLOT(EnableGapPixels(bool)));
+ int ret = myDet->enableGapPixels(-1);
+ qDefs::checkErrorMessage(myDet,"qTabPlot::Refresh");
+ chkGapPixels->setChecked((ret == 1) ? true : false);
+ connect(chkGapPixels, SIGNAL(toggled(bool)),this, SLOT(EnableGapPixels(bool)));
+ }
+
}else{
boxFrequency->setEnabled(false);
disconnect(boxScan, SIGNAL(toggled(bool)), this, SLOT(EnableScanBox()));