79 installEventFilter(
this);
81 fXRangeLow_lineEdit->setValidator(
new QDoubleValidator(fXRangeLow_lineEdit) );
82 fXRangeUp_lineEdit->setValidator(
new QDoubleValidator(fXRangeUp_lineEdit) );
83 fYRangeLow_lineEdit->setValidator(
new QDoubleValidator(fYRangeLow_lineEdit) );
84 fYRangeUp_lineEdit->setValidator(
new QDoubleValidator(fYRangeUp_lineEdit) );
86 fPlot_plainTextEdit->setFont(QFont(
"Courier", 10));
125 if (fPlot_plainTextEdit->toPlainText().isEmpty()) {
126 param =
"###############################################################\n";
131 if (fType_comboBox->currentText() ==
"Single Histo") {
132 param +=
"0 (single histo plot)\n";
133 }
else if (fType_comboBox->currentText() ==
"Asymmetry") {
134 param +=
"2 (asymmetry plot)\n";
135 }
else if (fType_comboBox->currentText() ==
"MuMinus") {
136 param +=
"4 (mu minus plot)\n";
137 }
else if (fType_comboBox->currentText() ==
"NonMusr") {
138 param +=
"8 (non muSR plot)\n";
142 param +=
"runs " + fRunList_lineEdit->text() +
"\n";
147 str = fXRangeLow_lineEdit->text();
149 QMessageBox::critical(
this,
"ERROR",
150 "empty lower time-/x-range name not allowed!",
151 QMessageBox::Ok, QMessageBox::NoButton);
155 if (str.length() < 8)
156 param += spaces.fill(
' ', 8 - str.length());
161 str = fXRangeUp_lineEdit->text();
163 QMessageBox::critical(
this,
"ERROR",
164 "empty upper time-/x-range name not allowed!",
165 QMessageBox::Ok, QMessageBox::NoButton);
169 if (str.length() < 8)
170 param += spaces.fill(
' ', 8 - str.length());
175 if ((fYRangeLow_lineEdit->text().isEmpty() && !fYRangeUp_lineEdit->text().isEmpty()) ||
176 (!fYRangeLow_lineEdit->text().isEmpty() && fYRangeUp_lineEdit->text().isEmpty())) {
177 QMessageBox::critical(
this,
"ERROR",
178 "Only fully empty y-range, or give lower AND upper y-range is acceptable!\n Will ignore the y-range",
179 QMessageBox::Ok, QMessageBox::NoButton);
180 }
else if (!fYRangeLow_lineEdit->text().isEmpty() && !fYRangeUp_lineEdit->text().isEmpty()) {
181 str = fYRangeLow_lineEdit->text();
183 if (str.length() < 8)
184 param += spaces.fill(
' ', 8 - str.length());
187 param += fYRangeUp_lineEdit->text() +
"\n";
193 fPlot_plainTextEdit->appendPlainText(param);
196 fRunList_lineEdit->clear();
197 fXRangeLow_lineEdit->clear();
198 fXRangeUp_lineEdit->clear();
199 fYRangeLow_lineEdit->clear();
200 fYRangeUp_lineEdit->clear();
201 fRunList_lineEdit->setFocus();