diff options
author | Ken Moore <ken@ixsystems.com> | 2017-10-27 11:09:40 -0400 |
---|---|---|
committer | Ken Moore <ken@ixsystems.com> | 2017-10-27 11:09:40 -0400 |
commit | df0a6abc4622e4527fb8ef6f618485bb4fdc4cb1 (patch) | |
tree | f9d4dc81bff5cac2e30c324d8e94993cb72b0327 /src-qt5/desktop-utils/lumina-fm/BrowserWidget.cpp | |
parent | Fix a couple theme engine holdovers in lumina-open, and turn off debugging ag... (diff) | |
download | lumina-df0a6abc4622e4527fb8ef6f618485bb4fdc4cb1.tar.gz lumina-df0a6abc4622e4527fb8ef6f618485bb4fdc4cb1.tar.bz2 lumina-df0a6abc4622e4527fb8ef6f618485bb4fdc4cb1.zip |
Fix the column width resizing for lumina-fm tree widget.
Diffstat (limited to 'src-qt5/desktop-utils/lumina-fm/BrowserWidget.cpp')
-rw-r--r-- | src-qt5/desktop-utils/lumina-fm/BrowserWidget.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src-qt5/desktop-utils/lumina-fm/BrowserWidget.cpp b/src-qt5/desktop-utils/lumina-fm/BrowserWidget.cpp index 6229749c..ab25d5e7 100644 --- a/src-qt5/desktop-utils/lumina-fm/BrowserWidget.cpp +++ b/src-qt5/desktop-utils/lumina-fm/BrowserWidget.cpp @@ -82,6 +82,7 @@ void BrowserWidget::showDetails(bool show){ connect(treeWidget, SIGNAL(GotFocus()), this, SLOT(selectionChanged()) ); retranslate(); treeWidget->sortItems(0, Qt::AscendingOrder); + treeWidget->setColumnWidth(0, treeWidget->fontMetrics().width("W")*20); if(!BROWSER->currentDirectory().isEmpty()){ emit dirChange("", true); } }else if(!show && listWidget==0){ listWidget = new DDListWidget(this); @@ -384,7 +385,9 @@ void BrowserWidget::itemDataAvailable(QIcon ico, LFileInfo *info){ }else{ if(freshload && treeWidget!=0){ //qDebug() << "Resize Tree Widget Contents"; - for(int i=0; i<treeWidget->columnCount(); i++){ treeWidget->resizeColumnToContents(i); } + //for(int i=treeWidget->columnCount()-1; i>0; i--){ treeWidget->resizeColumnToContents(i); } + treeWidget->resizeColumnToContents(1); + //treeWidget->resizeColumnToContents(0); } freshload = false; //any further changes are updates - not a fresh load of a dir //Done loading items |