Skip to content
Permalink
Browse files
Tweak the way column widths are set in the identify results dialog box
to ensure they are always wide enough for their data.


git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@5655 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
g_j_m committed Aug 2, 2006
1 parent b571290 commit 4c5da0e
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 12 deletions.
@@ -37,7 +37,9 @@ QgsIdentifyResults::QgsIdentifyResults(const QgsAttributeAction& actions,
mActionPopup(0)
{
setupUi(this);
lstResults->setResizeMode(Q3ListView::AllColumns);
lstResults->setResizeMode(Q3ListView::LastColumn);
lstResults->setColumnWidthMode(0, Q3ListView::Maximum);
lstResults->setColumnWidthMode(1, Q3ListView::Maximum);

connect( buttonCancel, SIGNAL(clicked()),
this, SLOT(close()) );
@@ -233,14 +235,6 @@ void QgsIdentifyResults::showAllAttributes() {
lstResults->setOpen(*qlvii, true);
}

/** adjust all of the colums to show their contents */
void QgsIdentifyResults::adjustColumnWidths()
{
lstResults->adjustColumn(0);
lstResults->adjustColumn(1);
}


void QgsIdentifyResults::clear()
{
lstResults->clear();
@@ -67,7 +67,6 @@ class QgsIdentifyResults: public QDialog, private Ui::QgsIdentifyResultsBase
void restorePosition();
void closeEvent(QCloseEvent *e);
void showAllAttributes();
void adjustColumnWidths();

/** Remove results */
void clear();
@@ -312,8 +312,6 @@ void QgsMapToolIdentify::identifyVectorLayer(QgsVectorLayer* layer, const QgsPoi

QApplication::restoreOverrideCursor();

mResults->adjustColumnWidths();

mResults->show();
}
else

0 comments on commit 4c5da0e

Please sign in to comment.