From 057df92af90a756ec27bea0e2de3be611f093d9f Mon Sep 17 00:00:00 2001 From: Reg Tiangha Date: Sat, 4 May 2024 15:32:13 -0600 Subject: [PATCH] game_list.cpp: Resize columns to fit the size of their contents --- src/lime_qt/game_list.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/lime_qt/game_list.cpp b/src/lime_qt/game_list.cpp index 8e5533aed..b4628e43a 100644 --- a/src/lime_qt/game_list.cpp +++ b/src/lime_qt/game_list.cpp @@ -475,6 +475,12 @@ void GameList::DonePopulating(const QStringList& watch_list) { item_model->sort(tree_view->header()->sortIndicatorSection(), tree_view->header()->sortIndicatorOrder()); + // resize all columns except for Name to fit their contents + for (int i = 1; i <= COLUMN_COUNT; i++) { + tree_view->resizeColumnToContents(i); + } + tree_view->header()->setStretchLastSection(true); + emit PopulatingCompleted(); }