Skip to content

Commit ddda7d4

Browse files
committed
Merge pull request #2259 from elpaso/hidpi-improvements4
Scale attribute table cells to content
2 parents d5d7c58 + ff15e84 commit ddda7d4

File tree

3 files changed

+7
-5
lines changed

3 files changed

+7
-5
lines changed

src/gui/attributetable/qgsdualview.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,8 @@ void QgsDualView::init( QgsVectorLayer* layer, QgsMapCanvas* mapCanvas, const Qg
8585
else
8686
columnBoxInit();
8787

88+
mTableView->resizeColumnsToContents();
89+
8890
mFeatureList->setEditSelection( QgsFeatureIds() << mFeatureListModel->idxToFid( mFeatureListModel->index( 0, 0 ) ) );
8991
}
9092

src/gui/attributetable/qgsdualview.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@
1313
* *
1414
***************************************************************************/
1515

16-
#ifndef QGSFEATURELIST_H
17-
#define QGSFEATURELIST_H
16+
#ifndef QGSDUALVIEW_H
17+
#define QGSDUALVIEW_H
1818

1919
#include <QStackedWidget>
2020

@@ -271,4 +271,4 @@ class GUI_EXPORT QgsAttributeTableMapLayerAction : public QAction
271271
QModelIndex mFieldIdx;
272272
};
273273

274-
#endif // QGSFEATURELIST_H
274+
#endif // QGSDUALVIEW_H

src/gui/attributetable/qgsfeaturelistview.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@
1313
* *
1414
***************************************************************************/
1515

16-
#ifndef QGSATTRIBUTELISTVIEW_H
17-
#define QGSATTRIBUTELISTVIEW_H
16+
#ifndef QGSFEATURELISTVIEW_H
17+
#define QGSFEATURELISTVIEW_H
1818

1919
#include <QListView>
2020
#include <qdebug.h>

0 commit comments

Comments
 (0)