This commit is contained in:
parent
fa2d0482ac
commit
3f965140f9
|
@ -695,12 +695,12 @@ void MainWindow::on_pushButton_getDistortion_clicked()
|
|||
float distortion = 0.0;
|
||||
unsigned int len = sizeof(int);
|
||||
SANE_Status ret = sane_io_control(m_curDevHandle, IO_CTRL_CODE_GET_DISTORTION_DEVS_CHECK_VAL, &distortion, &len);
|
||||
if (ret != SANE_STATUS_GOOD)
|
||||
if (distortion > 1.2 || distortion < 0.8 || ret != SANE_STATUS_GOOD)
|
||||
{
|
||||
QMessageBox::information(this, tr("Prompt"), tr("Get failed"));
|
||||
return;
|
||||
}
|
||||
ui->lineEdit_distortion->setText(QString::number(distortion));
|
||||
ui->lineEdit_distortion->setText(QString::number(distortion, 'f', 4));
|
||||
}
|
||||
|
||||
void MainWindow::on_pushButton_setDistortion_clicked()
|
||||
|
|
|
@ -70,7 +70,7 @@
|
|||
<item>
|
||||
<widget class="QTabWidget" name="tabWidget">
|
||||
<property name="currentIndex">
|
||||
<number>1</number>
|
||||
<number>0</number>
|
||||
</property>
|
||||
<widget class="QWidget" name="tab">
|
||||
<attribute name="title">
|
||||
|
@ -79,8 +79,8 @@
|
|||
<widget class="QLabel" name="labelDevInfo">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>80</x>
|
||||
<y>170</y>
|
||||
<x>70</x>
|
||||
<y>30</y>
|
||||
<width>391</width>
|
||||
<height>20</height>
|
||||
</rect>
|
||||
|
@ -93,7 +93,7 @@
|
|||
<property name="geometry">
|
||||
<rect>
|
||||
<x>70</x>
|
||||
<y>30</y>
|
||||
<y>80</y>
|
||||
<width>501</width>
|
||||
<height>111</height>
|
||||
</rect>
|
||||
|
@ -322,6 +322,21 @@
|
|||
<string>Speed mode:</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QTreeWidget" name="treeWidget">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>240</x>
|
||||
<y>250</y>
|
||||
<width>256</width>
|
||||
<height>192</height>
|
||||
</rect>
|
||||
</property>
|
||||
<column>
|
||||
<property name="text">
|
||||
<string notr="true">1</string>
|
||||
</property>
|
||||
</column>
|
||||
</widget>
|
||||
</widget>
|
||||
<widget class="QWidget" name="tab_4">
|
||||
<attribute name="title">
|
||||
|
|
Loading…
Reference in New Issue