x马达扫描速度接受小数

This commit is contained in:
tangchao0503
2025-02-27 14:18:02 +08:00
parent b779118d72
commit 5af6a039c2
2 changed files with 5 additions and 4 deletions

View File

@ -178,7 +178,8 @@ HPPA::HPPA(QWidget *parent)
connect(this->ui.ymotor_backward_btn, SIGNAL(released()), this, SLOT(onyMotorStop()));
//<2F>ٶ<EFBFBD>
QRegExp rx("\\d{0,3}[1-9]$");
//QRegExp rx("\\d{0,3}.[1-9]$");
QRegExp rx("^\\d+(\\.\\d+)?$");
ui.xmotor_speed_lineEdit->setValidator(new QRegExpValidator(rx));
//<2F><>ȡ<EFBFBD><C8A1><EFBFBD><EFBFBD><EFBFBD>ļ<EFBFBD>

View File

@ -9,7 +9,7 @@
<rect>
<x>0</x>
<y>0</y>
<width>756</width>
<width>523</width>
<height>463</height>
</rect>
</property>
@ -25,7 +25,7 @@
<rect>
<x>90</x>
<y>250</y>
<width>578</width>
<width>341</width>
<height>134</height>
</rect>
</property>
@ -70,7 +70,7 @@
</rect>
</property>
<property name="text">
<string>版本1.8.4</string>
<string>版本1.8.5</string>
</property>
</widget>
<widget class="QLabel" name="label_4">