This commit is contained in:
2019-07-12 18:24:23 +02:00
parent 5e24591295
commit 0f2641f9fa
11 changed files with 48 additions and 34 deletions

View File

@ -200,14 +200,15 @@ void qDrawPlot::SetupPlots() {
// default display data
for (unsigned int px = 0; px < nPixelsX; ++px) {
datax1d[px] = px;
datay1d[0][px] = 0;
datay1d[0][px] = px;
}
// add a hist
DetachHists();
SlsQtH1D *h = new SlsQtH1D("", nPixelsX, datax1d, datay1d[0]);
h->SetLineColor(0);
SetStyleandSymbol(h);
hists1d.append(h);
h->Attach(plot1d);
plot1d->DisableZoom(true);
// setup 2d plot
plot2d = new SlsQt2DPlotLayout(boxPlot);
@ -792,7 +793,7 @@ void qDrawPlot::Get1dData(double* rawData) {
if (currentPersistency) {
// allocate
for(int i = datay1d.size(); i <= persistency; ++i) {
datay1d[i] = new double [nPixelsX];
datay1d.push_back(new double [nPixelsX]);
SlsQtH1D* h = new SlsQtH1D("", nPixelsX, datax1d, datay1d[i]);
h->SetLineColor(i);
SetStyleandSymbol(h);

View File

@ -159,7 +159,7 @@ void qTabDeveloper::Initialization() {
connect(comboHV, SIGNAL(currentIndexChanged(int)), this, SLOT(SetHighVoltage()));
}
if (spinHV != nullptr) {
connect(spinHV, SIGNAL(valueChanged(int)), this, SLOT(SetHighVoltage()));
connect(spinHV, SIGNAL(editingFinished()), this, SLOT(SetHighVoltage()));
}
}
@ -271,8 +271,8 @@ void qTabDeveloper::CreateHVWidget() {
// jungfrau, moench (range of values)
else {
spinHV = new QSpinBox(boxDacs);
spinDacs[numDACWidgets]->setMinimum(-1);
spinDacs[numDACWidgets]->setMaximum(HV_MAX);
spinHV->setMinimum(-1);
spinHV->setMaximum(HV_MAX);
spinHV->setToolTip("<nobr>Set high voltage to 0 or 60 - 200V</nobr>");
lblHV->setToolTip(spinHV->toolTip());
dacLayout->addWidget(spinHV, (int)(numDACWidgets / 2), 2);
@ -341,7 +341,7 @@ void qTabDeveloper::GetHighVoltage() {
FILE_LOG(logDEBUG) << "Getting High Voltage";
if (spinHV != nullptr) {
disconnect(spinHV, SIGNAL(valueChanged(int)), this, SLOT(SetHighVoltage()));
disconnect(spinHV, SIGNAL(editingFinished()), this, SLOT(SetHighVoltage()));
}
if (comboHV != nullptr) {
disconnect(comboHV, SIGNAL(currentIndexChanged(int)), this, SLOT(SetHighVoltage()));
@ -391,7 +391,7 @@ void qTabDeveloper::GetHighVoltage() {
} CATCH_DISPLAY ("Could not get high voltage.", "qTabDeveloper::GetHighVoltage")
if (spinHV != nullptr) {
connect(spinHV, SIGNAL(valueChanged(int)), this, SLOT(SetHighVoltage()));
connect(spinHV, SIGNAL(editingFinished()), this, SLOT(SetHighVoltage()));
}
if (comboHV != nullptr) {
connect(comboHV, SIGNAL(currentIndexChanged(int)), this, SLOT(SetHighVoltage()));