extern qreal g_n;
extern qreal a_max;
-extern qreal filter_k;
+extern int smoothing;
extern int angle_step;
extern int divisions;
extern int data_rate;
editRate->setInputMethodHints(Qt::ImhDigitsOnly);
editRate->setText(QString::number(data_rate));
label->setBuddy(editRate);
- label = new QLabel(QString::fromUtf8("&Filter depth"), this);
+ label = new QLabel(QString::fromUtf8("&Smoothing"), this);
hbox->addWidget(label);
- editFilter = new QLineEdit(this);
- hbox->addWidget(editFilter);
- editFilter->setInputMethodHints(Qt::ImhFormattedNumbersOnly);
- editFilter->setText(QString::number(filter_k));
- label->setBuddy(editFilter);
+ comboSmoothing = new QComboBox(this);
+ comboSmoothing->addItem("None");
+ comboSmoothing->addItem("Light");
+ comboSmoothing->addItem("Medium");
+ comboSmoothing->addItem("Strong");
+ comboSmoothing->setCurrentIndex(smoothing);
+ hbox->addWidget(comboSmoothing);
+ label->setBuddy(comboSmoothing);
vbox->addLayout(hbox);
buttonOk = new QPushButton("Ok");
setLayout(vbox);
- layout()->setSizeConstraint( QLayout::SetFixedSize );
+ layout()->setSizeConstraint(QLayout::SetFixedSize);
}
SettingsDialog::~SettingsDialog()
{
g_n = editG->text().toDouble();
a_max = editMax->text().toDouble();
- filter_k = editFilter->text().toDouble();
+ smoothing = comboSmoothing->currentIndex();
divisions = editDiv->text().toInt();
angle_step = editAngle->text().toInt();
data_rate = editRate->text().toInt();
QDialog::accept();
}
+