Skip to content

Commit

Permalink
fix: The effect of checkbox is not fully displayed
Browse files Browse the repository at this point in the history
勾选框高度以文本高度计算,低字号下导致选中
效果无法完全展示,设置最小高度避免此问题

Log: 修复勾选框在低字号下选中效果显示不全
Bug: https://pms.uniontech.com/bug-view-248145.html
Influence: UI
  • Loading branch information
rb-union committed Mar 25, 2024
1 parent 7eee7c9 commit c9d07af
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/deb-installer/view/pages/packageselectview.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@
#include <QHBoxLayout>
#include <QVBoxLayout>

// 选中框最低高度(低字号下可能使得选中框显示不全)
static const int s_MinimumBoxHeight = 32;

PackageSelectView::PackageSelectView(QWidget *parent)
: QWidget(parent)
, packageListWidget(new QListWidget)
Expand All @@ -24,6 +27,8 @@ PackageSelectView::PackageSelectView(QWidget *parent)
installButton->setFocusPolicy(Qt::StrongFocus);
installButton->setDefault(true);

selectAllBox->setMinimumHeight(s_MinimumBoxHeight);

//全选+安装
auto bottomLayout = new QHBoxLayout;
bottomLayout->addWidget(selectAllBox);
Expand Down

0 comments on commit c9d07af

Please sign in to comment.