修改现场设备联调问题

This commit is contained in:
lixiaoyuan
2025-10-26 20:43:51 +08:00
parent 5f6511a3f0
commit ac17c41900
13 changed files with 175 additions and 144 deletions

View File

@@ -5,7 +5,9 @@ static const std::string QSS_GROUP =
"QGroupBox::title { subcontrol-origin: margin; subcontrol-position: top left; left:10px; margin-left: 0px; padding:0 1px; }";
static const std::string QSS_BTN =
"QPushButton {background:rgba(80, 80, 80,80);border-radius:5px;border:1px solid gray;color:white;font:bold 13px;}";
"QPushButton {background:rgba(180,180,180,50);border-radius:2px;border:1px solid gray;color:white;}"
"QPushButton:hover {background-color:rgb(32,164,128);}"
"QPushButton:pressed {border-width:2px 0 0 2px;border-style:inset;}";
static const std::string QSS_BTN_ACTIVE =
"QPushButton {background:rgba(80, 80, 80,80);border-radius:5px;border:1px solid green;color:green;font:bold 15px;}";
@@ -29,7 +31,7 @@ static const std::string QSS_BTN_TAB =
//"QPushButton:disabled {color:rgb(150,150,150);}";
static const std::string QSS_LINE =
"QLineEdit { background-color: rgb(14, 49, 66); color: #ffffff; border: 1px solid gray; border-radius: 5px; font: bold 13px; }";
"QLineEdit { background-color:rgba(180,180,180,36); color:#ffffff; border:1px solid gray; border-radius:3px; font:bold 13px; }"; //14, 49, 66
static const std::string QSS_TABLE = // 表格整体样式
"QTableWidget {"
@@ -70,6 +72,13 @@ MyWidget::MyWidget(QWidget* parent) : QWidget(parent)
setAutoFillBackground(true);
}
shared_ptr<QPushButton> MyQUI::Button(QWidget* parent, int x, int y, int w, int h, std::string title)
{
auto btn = std::make_shared<QPushButton>(title.c_str(), parent);
btn->setGeometry(x, y, w, h);
btn->setStyleSheet(QSS_BTN.c_str());
return btn;
}
std::shared_ptr<QGroupBox> MyQUI::GroupBox(QWidget* parent, int x, int y, int w, int h, std::string title)
{