diff options
author | Berthold Stoeger <bstoeger@mail.tuwien.ac.at> | 2020-11-07 11:25:42 +0100 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2020-11-07 11:37:51 -0800 |
commit | 68b63534a34a6e0b2af4a99919a439acd3d8be08 (patch) | |
tree | 8675fa9244b2f6dec6101f596a15b043925d5666 | |
parent | 360123d432a9006913146072a2a0be541f2231f2 (diff) | |
download | subsurface-68b63534a34a6e0b2af4a99919a439acd3d8be08.tar.gz |
desktop: maximize size of last column in filter-preset table
This was just ugly: the column with the "trash" symbol and the
name had the same size. On creation of the object, make the last
column expand and adapt the size of the "trash" column according
to its content.
Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
-rw-r--r-- | desktop-widgets/filterwidget.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/desktop-widgets/filterwidget.cpp b/desktop-widgets/filterwidget.cpp index 170b0d1ac..026e222f3 100644 --- a/desktop-widgets/filterwidget.cpp +++ b/desktop-widgets/filterwidget.cpp @@ -30,6 +30,8 @@ FilterWidget::FilterWidget(QWidget* parent) : ui.presetTable->setModel(FilterPresetModel::instance()); ui.presetTable->setSelectionBehavior(QAbstractItemView::SelectRows); ui.presetTable->setSelectionMode(QAbstractItemView::SingleSelection); + ui.presetTable->horizontalHeader()->setStretchLastSection(true); + ui.presetTable->resizeColumnsToContents(); connect(ui.clear, &QToolButton::clicked, this, &FilterWidget::clearFilter); connect(ui.close, &QToolButton::clicked, this, &FilterWidget::closeFilter); |