From b32351e7b62424fbc02143538a35c595e6f85395 Mon Sep 17 00:00:00 2001 From: Martin Kleusberg Date: Fri, 26 Jul 2019 15:10:32 +0200 Subject: [PATCH] Try to avoid automatic column resizing in Browse Data tab See issue #1941. --- src/FilterTableHeader.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/FilterTableHeader.cpp b/src/FilterTableHeader.cpp index 9e4d4bac..fa43bcc6 100644 --- a/src/FilterTableHeader.cpp +++ b/src/FilterTableHeader.cpp @@ -10,9 +10,13 @@ FilterTableHeader::FilterTableHeader(QTableView* parent) : { // Activate the click signals to allow sorting setSectionsClickable(true); + // But use our own indicators allowing multi-column sorting setSortIndicatorShown(false); + // Make sure to not automatically resize the columns according to the contents + setSectionResizeMode(QHeaderView::Interactive); + // Do some connects: Basically just resize and reposition the input widgets whenever anything changes connect(this, SIGNAL(sectionResized(int,int,int)), this, SLOT(adjustPositions())); connect(parent->horizontalScrollBar(), SIGNAL(valueChanged(int)), this, SLOT(adjustPositions()));