From 152c0cbf1d6f85fdd0b69798de6b324d8cf5e70b Mon Sep 17 00:00:00 2001 From: OBattler Date: Sat, 8 Jun 2024 05:02:58 +0200 Subject: [PATCH] Settings: Changed the List View to a Table View - now the pages rows are no longer as small as they used to be. --- src/qt/qt_settings.cpp | 4 ++-- src/qt/qt_settings.ui | 21 ++++++++++++++++++--- 2 files changed, 20 insertions(+), 5 deletions(-) diff --git a/src/qt/qt_settings.cpp b/src/qt/qt_settings.cpp index e9767083a..caabdbfca 100644 --- a/src/qt/qt_settings.cpp +++ b/src/qt/qt_settings.cpp @@ -182,8 +182,8 @@ Settings::Settings(QWidget *parent) [this](const QModelIndex ¤t, const QModelIndex &previous) { ui->stackedWidget->setCurrentIndex(current.row()); }); - ui->listView->setMinimumWidth(ui->listView->sizeHintForColumn(0) + - qApp->style()->pixelMetric(QStyle::PM_ScrollBarExtent)); + ui->listView->resizeColumnsToContents(); + ui->listView->horizontalHeader()->setSectionResizeMode(0, QHeaderView::Stretch); ui->listView->setCurrentIndex(model->index(0, 0)); diff --git a/src/qt/qt_settings.ui b/src/qt/qt_settings.ui index 7b4d28bec..fd92f7f58 100644 --- a/src/qt/qt_settings.ui +++ b/src/qt/qt_settings.ui @@ -36,10 +36,25 @@ 0 - - - QListView::ListMode + + + QAbstractItemView::NoEditTriggers + + QAbstractItemView::SingleSelection + + + QAbstractItemView::SelectRows + + + false + + + false + + + false +