Skip to content

Commit 956e18d

Browse files
committedApr 21, 2013
Update vector layer properties dialog with vertical tabs
- Following subsections still need work: Labeling (ng), Diagrams and possibly more on Style - Add new SVG icons for Labels, Display and Metadata tabs - Add up/down, plus/minus icons for consistency - Move Metadata tab to bottom of list for vector and raster layer property dialogs - Update report stylesheet (metadata output) to support direct RTF copy/paste (i.e. black-colored fonts) - Update report stylesheet to use light gray backgrounds for headers instead of unpredictable highlight color
1 parent 87288b7 commit 956e18d

18 files changed

+2142
-1289
lines changed
 

‎images/images.qrc

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -374,14 +374,17 @@
374374
<file>themes/default/propertyicons/CRS.png</file>
375375
<file>themes/default/propertyicons/diagram.png</file>
376376
<file>themes/default/propertyicons/digitising.png</file>
377+
<file>themes/default/propertyicons/display.svg</file>
377378
<file>themes/default/propertyicons/gdal.png</file>
378379
<file>themes/default/propertyicons/general.png</file>
379380
<file>themes/default/propertyicons/histogram.png</file>
380381
<file>themes/default/propertyicons/join.png</file>
381382
<file>themes/default/propertyicons/labels.png</file>
383+
<file>themes/default/propertyicons/labels.svg</file>
382384
<file>themes/default/propertyicons/locale.png</file>
383385
<file>themes/default/propertyicons/map_tools.png</file>
384386
<file>themes/default/propertyicons/metadata.png</file>
387+
<file>themes/default/propertyicons/metadata.svg</file>
385388
<file>themes/default/propertyicons/network_and_proxy.png</file>
386389
<file>themes/default/propertyicons/overlay.png</file>
387390
<file>themes/default/propertyicons/pyramids.png</file>
Lines changed: 12 additions & 0 deletions
Loading
Lines changed: 117 additions & 0 deletions
Loading
Lines changed: 18 additions & 0 deletions
Loading

‎src/app/qgsvectorlayerproperties.cpp

Lines changed: 37 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -69,24 +69,35 @@ QgsVectorLayerProperties::QgsVectorLayerProperties(
6969
QWidget * parent,
7070
Qt::WFlags fl
7171
)
72-
: QDialog( parent, fl )
72+
: QgsOptionsDialogBase( "VectorLayerProperties", parent, fl )
7373
, layer( lyr )
7474
, mMetadataFilled( false )
7575
, mRendererDialog( 0 )
7676
{
7777
setupUi( this );
78+
// QgsOptionsDialogBase handles saving/restoring of geometry, splitter and current tab states,
79+
// switching vertical tabs between icon/text to icon-only modes (splitter collapsed to left),
80+
// and connecting QDialogButtonBox's accepted/rejected signals to dialog's accept/reject slots
81+
initOptionsBase( false );
7882

7983
mMaximumScaleIconLabel->setPixmap( QgsApplication::getThemePixmap( "/mActionZoomIn.png" ) );
8084
mMinimumScaleIconLabel->setPixmap( QgsApplication::getThemePixmap( "/mActionZoomOut.png" ) );
8185

82-
connect( buttonBox, SIGNAL( accepted() ), this, SLOT( accept() ) );
83-
connect( buttonBox, SIGNAL( rejected() ), this, SLOT( reject() ) );
8486
connect( buttonBox->button( QDialogButtonBox::Apply ), SIGNAL( clicked() ), this, SLOT( apply() ) );
8587
connect( this, SIGNAL( accepted() ), this, SLOT( apply() ) );
8688

89+
connect( mOptionsStackedWidget, SIGNAL( currentChanged( int ) ), this, SLOT( mOptionsStackedWidget_CurrentChanged( int ) ) );
90+
8791
connect( insertFieldButton, SIGNAL( clicked() ), this, SLOT( insertField() ) );
8892
connect( insertExpressionButton, SIGNAL( clicked() ), this, SLOT( insertExpression() ) );
8993

94+
// connections for Map Tip display
95+
connect( htmlRadio, SIGNAL( toggled( bool ) ), htmlMapTip, SLOT( setEnabled( bool ) ) );
96+
connect( htmlRadio, SIGNAL( toggled( bool ) ), insertFieldButton, SLOT( setEnabled( bool ) ) );
97+
connect( htmlRadio, SIGNAL( toggled( bool ) ), fieldComboBox, SLOT( setEnabled( bool ) ) );
98+
connect( htmlRadio, SIGNAL( toggled( bool ) ), insertExpressionButton, SLOT( setEnabled( bool ) ) );
99+
connect( fieldComboRadio, SIGNAL( toggled( bool ) ), displayFieldComboBox, SLOT( setEnabled( bool ) ) );
100+
90101
QVBoxLayout *layout;
91102

92103
if ( layer->hasGeometryType() )
@@ -95,13 +106,15 @@ QgsVectorLayerProperties::QgsVectorLayerProperties(
95106
layout = new QVBoxLayout( labelingFrame );
96107
layout->setMargin( 0 );
97108
labelingDialog = new QgsLabelingGui( QgisApp::instance()->palLabeling(), layer, QgisApp::instance()->mapCanvas(), labelingFrame );
109+
labelingDialog->layout()->setMargin( 0 );
98110
layout->addWidget( labelingDialog );
99111
labelingFrame->setLayout( layout );
100112

101113
// Create the Labeling (deprecated) dialog tab
102114
layout = new QVBoxLayout( labelOptionsFrame );
103115
layout->setMargin( 0 );
104116
labelDialog = new QgsLabelDialog( layer->label(), labelOptionsFrame );
117+
labelDialog->layout()->setMargin( 0 );
105118
layout->addWidget( labelDialog );
106119
labelOptionsFrame->setLayout( layout );
107120
connect( labelDialog, SIGNAL( labelSourceSet() ), this, SLOT( setLabelCheckBox() ) );
@@ -110,15 +123,16 @@ QgsVectorLayerProperties::QgsVectorLayerProperties(
110123
{
111124
labelingDialog = 0;
112125
labelDialog = 0;
113-
tabWidget->setTabEnabled( 1, false ); // hide labeling item
114-
tabWidget->setTabEnabled( 2, false ); // hide labeling (deprecated) item
126+
mOptsPage_Labels->setEnabled( false ); // disable labeling item
127+
mOptsPage_LabelsOld->setEnabled( false ); // disable labeling (deprecated) item
115128
}
116129

117130
// Create the Actions dialog tab
118131
QVBoxLayout *actionLayout = new QVBoxLayout( actionOptionsFrame );
119132
actionLayout->setMargin( 0 );
120133
const QgsFields &fields = layer->pendingFields();
121134
actionDialog = new QgsAttributeActionDialog( layer->actions(), fields, actionOptionsFrame );
135+
actionDialog->layout()->setMargin( 0 );
122136
actionLayout->addWidget( actionDialog );
123137

124138
// Create the menu for the save style button to choose the output format
@@ -128,7 +142,9 @@ QgsVectorLayerProperties::QgsVectorLayerProperties(
128142
QObject::connect( mSaveAsMenu, SIGNAL( triggered( QAction * ) ), this, SLOT( saveStyleAsMenuTriggered( QAction * ) ) );
129143

130144
mFieldsPropertiesDialog = new QgsFieldsProperties( layer, mFieldsFrame );
145+
mFieldsPropertiesDialog->layout()->setMargin( 0 );
131146
mFieldsFrame->setLayout( new QVBoxLayout( mFieldsFrame ) );
147+
mFieldsFrame->layout()->setMargin( 0 );
132148
mFieldsFrame->layout()->addWidget( mFieldsPropertiesDialog );
133149

134150
connect( mFieldsPropertiesDialog, SIGNAL( toggleEditing() ), this, SLOT( toggleEditing() ) );
@@ -158,8 +174,7 @@ QgsVectorLayerProperties::QgsVectorLayerProperties(
158174
}
159175
else
160176
{
161-
// currently only encoding can be set in this group, so hide it completely
162-
grpProviderOptions->hide();
177+
mDataSourceEncodingFrame->hide();
163178
}
164179
}
165180

@@ -174,7 +189,9 @@ QgsVectorLayerProperties::QgsVectorLayerProperties(
174189
}
175190

176191
diagramPropertiesDialog = new QgsDiagramProperties( layer, mDiagramFrame );
192+
diagramPropertiesDialog->layout()->setMargin( 0 );
177193
mDiagramFrame->setLayout( new QVBoxLayout( mDiagramFrame ) );
194+
mDiagramFrame->layout()->setMargin( 0 );
178195
mDiagramFrame->layout()->addWidget( diagramPropertiesDialog );
179196

180197
//layer title and abstract
@@ -184,26 +201,18 @@ QgsVectorLayerProperties::QgsVectorLayerProperties(
184201
mLayerAbstractTextEdit->setPlainText( layer->abstract() );
185202
}
186203

187-
QSettings settings;
188-
restoreGeometry( settings.value( "/Windows/VectorLayerProperties/geometry" ).toByteArray() );
189-
int tabIndex = settings.value( "/Windows/VectorLayerProperties/row", 0 ).toInt();
204+
setWindowTitle( tr( "Layer Properties - %1" ).arg( layer->name() ) );
190205

191-
// if the last used tab is not enabled display the first enabled one
192-
if ( !tabWidget->isTabEnabled( tabIndex ) )
206+
QSettings settings;
207+
// if dialog hasn't been opened/closed yet, default to Styles tab, which is used most often
208+
// this will be read by restoreOptionsBaseUi()
209+
if ( !settings.contains( QString( "/Windows/VectorLayerProperties/tab" ) ) )
193210
{
194-
tabIndex = 0;
195-
for ( int i = 0; i < tabWidget->count(); i++ )
196-
{
197-
if ( tabWidget->isTabEnabled( i ) )
198-
{
199-
tabIndex = i;
200-
break;
201-
}
202-
}
211+
settings.setValue( QString( "/Windows/VectorLayerProperties/tab" ),
212+
mOptStackedWidget->indexOf( mOptsPage_Style ) );
203213
}
204-
tabWidget->setCurrentIndex( tabIndex );
205214

206-
setWindowTitle( tr( "Layer Properties - %1" ).arg( layer->name() ) );
215+
restoreOptionsBaseUi();
207216
} // QgsVectorLayerProperties ctor
208217

209218

@@ -213,10 +222,6 @@ QgsVectorLayerProperties::~QgsVectorLayerProperties()
213222
{
214223
disconnect( labelDialog, SIGNAL( labelSourceSet() ), this, SLOT( setLabelCheckBox() ) );
215224
}
216-
217-
QSettings settings;
218-
settings.setValue( "/Windows/VectorLayerProperties/geometry", saveGeometry() );
219-
settings.setValue( "/Windows/VectorLayerProperties/row", tabWidget->currentIndex() );
220225
}
221226

222227
void QgsVectorLayerProperties::toggleEditing()
@@ -788,13 +793,15 @@ void QgsVectorLayerProperties::updateSymbologyPage()
788793
}
789794
else
790795
{
791-
tabWidget->setTabEnabled( 0, false ); // hide symbology item
796+
mOptsPage_Style->setEnabled( false ); // hide symbology item
792797
}
793798

794799
if ( mRendererDialog )
795800
{
801+
mRendererDialog->layout()->setMargin( 0 );
796802
widgetStackRenderers->addWidget( mRendererDialog );
797803
widgetStackRenderers->setCurrentWidget( mRendererDialog );
804+
widgetStackRenderers->currentWidget()->layout()->setMargin( 0 );
798805
}
799806
}
800807

@@ -804,9 +811,9 @@ void QgsVectorLayerProperties::on_pbnUpdateExtents_clicked()
804811
mMetadataFilled = false;
805812
}
806813

807-
void QgsVectorLayerProperties::on_tabWidget_currentChanged( int index )
814+
void QgsVectorLayerProperties::mOptionsStackedWidget_CurrentChanged( int indx )
808815
{
809-
if ( index != 6 || mMetadataFilled )
816+
if ( indx != mOptStackedWidget->indexOf( mOptsPage_Metadata ) || mMetadataFilled )
810817
return;
811818

812819
//set the metadata contents (which can be expensive)

‎src/app/qgsvectorlayerproperties.h

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
#ifndef QGSVECTORLAYERPROPERTIES
2020
#define QGSVECTORLAYERPROPERTIES
2121

22+
#include "qgsoptionsdialogbase.h"
2223
#include "ui_qgsvectorlayerpropertiesbase.h"
2324
#include "qgisgui.h"
2425
#include "qgsaddattrdialog.h"
@@ -41,7 +42,7 @@ class QgsLabelingGui;
4142
class QgsDiagramProperties;
4243
class QgsFieldsProperties;
4344

44-
class QgsVectorLayerProperties : public QDialog, private Ui::QgsVectorLayerPropertiesBase
45+
class QgsVectorLayerProperties : public QgsOptionsDialogBase, private Ui::QgsVectorLayerPropertiesBase
4546
{
4647
Q_OBJECT
4748

@@ -106,7 +107,7 @@ class QgsVectorLayerProperties : public QDialog, private Ui::QgsVectorLayerPrope
106107
void on_pbnSaveDefaultStyle_clicked();
107108
void on_pbnLoadStyle_clicked();
108109
void on_pbnSaveStyleAs_clicked();
109-
void on_tabWidget_currentChanged( int idx );
110+
void mOptionsStackedWidget_CurrentChanged( int indx );
110111
void on_buttonBox_helpRequested() { QgsContextHelp::run( metaObject()->className() ); }
111112
void on_pbnUpdateExtents_clicked();
112113

‎src/core/qgsapplication.cpp

Lines changed: 36 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -623,30 +623,48 @@ QString QgsApplication::reportStyleSheet()
623623
// Make the style sheet desktop preferences aware by using qappliation
624624
// palette as a basis for colors where appropriate
625625
//
626-
QColor myColor1 = palette().highlight().color();
626+
// QColor myColor1 = palette().highlight().color();
627+
QColor myColor1( Qt::lightGray );
627628
QColor myColor2 = myColor1;
628629
myColor2 = myColor2.lighter( 110 ); //10% lighter
629630
QString myStyle;
630631
myStyle = "p.glossy{ background-color: qlineargradient(x1:0, y1:0, x2:0, y2:1, "
631-
"stop: 0 " + myColor1.name() + ","
632-
"stop: 0.1 " + myColor2.name() + ","
633-
"stop: 0.5 " + myColor1.name() + ","
634-
"stop: 0.9 " + myColor2.name() + ","
635-
"stop: 1 " + myColor1.name() + ");"
636-
"color: white;"
637-
"padding-left: 4px;"
638-
"padding-top: 20px;"
639-
"padding-bottom: 8px;"
640-
"border: 1px solid #6c6c6c;"
632+
" stop: 0 " + myColor1.name() + ","
633+
" stop: 0.1 " + myColor2.name() + ","
634+
" stop: 0.5 " + myColor1.name() + ","
635+
" stop: 0.9 " + myColor2.name() + ","
636+
" stop: 1 " + myColor1.name() + ");"
637+
" color: black;"
638+
" padding-left: 4px;"
639+
" padding-top: 20px;"
640+
" padding-bottom: 8px;"
641+
" border: 1px solid #6c6c6c;"
642+
"}"
643+
"p.subheaderglossy{ background-color: qlineargradient(x1:0, y1:0, x2:0, y2:1, "
644+
" stop: 0 " + myColor1.name() + ","
645+
" stop: 0.1 " + myColor2.name() + ","
646+
" stop: 0.5 " + myColor1.name() + ","
647+
" stop: 0.9 " + myColor2.name() + ","
648+
" stop: 1 " + myColor1.name() + ");"
649+
" font-weight: bold;"
650+
" font-size: medium;"
651+
" line-height: 1.1em;"
652+
" width: 100%;"
653+
" color: black;"
654+
" padding-left: 4px;"
655+
" padding-right: 4px;"
656+
" padding-top: 20px;"
657+
" padding-bottom: 8px;"
658+
" border: 1px solid #6c6c6c;"
641659
"}"
642660
"th.glossy{ background-color: qlineargradient(x1:0, y1:0, x2:0, y2:1, "
643-
"stop: 0 " + myColor1.name() + ","
644-
"stop: 0.1 " + myColor2.name() + ","
645-
"stop: 0.5 " + myColor1.name() + ","
646-
"stop: 0.9 " + myColor2.name() + ","
647-
"stop: 1 " + myColor1.name() + ");"
648-
"color: white;"
649-
"border: 1px solid #6c6c6c;"
661+
" stop: 0 " + myColor1.name() + ","
662+
" stop: 0.1 " + myColor2.name() + ","
663+
" stop: 0.5 " + myColor1.name() + ","
664+
" stop: 0.9 " + myColor2.name() + ","
665+
" stop: 1 " + myColor1.name() + ");"
666+
" color: black;"
667+
" border: 1px solid #6c6c6c;"
650668
"}"
651669
".overview{ font: 1.82em; font-weight: bold;}"
652670
"body{ background: white;"

‎src/core/qgsvectorlayer.cpp

Lines changed: 54 additions & 60 deletions
Original file line numberDiff line numberDiff line change
@@ -3396,31 +3396,33 @@ void QgsVectorLayer::setDiagramLayerSettings( const QgsDiagramLayerSettings& s )
33963396
QString QgsVectorLayer::metadata()
33973397
{
33983398
QString myMetadata = "<html><body>";
3399-
myMetadata += "<table width=\"100%\">";
34003399

34013400
//-------------
34023401

3403-
myMetadata += "<tr class=\"glossy\"><td>";
3404-
myMetadata += tr( "General:" );
3405-
myMetadata += "</td></tr>";
3402+
myMetadata += "<p class=\"subheaderglossy\">";
3403+
myMetadata += tr( "General" );
3404+
myMetadata += "</p>\n";
34063405

34073406
// data comment
34083407
if ( !( dataComment().isEmpty() ) )
34093408
{
3410-
myMetadata += "<tr><td>";
3411-
myMetadata += tr( "Layer comment: %1" ).arg( dataComment() );
3412-
myMetadata += "</td></tr>";
3409+
myMetadata += "<p class=\"glossy\">" + tr( "Layer comment" ) + "</p>\n";
3410+
myMetadata += "<p>";
3411+
myMetadata += dataComment();
3412+
myMetadata += "</p>\n";
34133413
}
34143414

34153415
//storage type
3416-
myMetadata += "<tr><td>";
3417-
myMetadata += tr( "Storage type of this layer: %1" ).arg( storageType() );
3418-
myMetadata += "</td></tr>";
3416+
myMetadata += "<p class=\"glossy\">" + tr( "Storage type of this layer" ) + "</p>\n";
3417+
myMetadata += "<p>";
3418+
myMetadata += storageType();
3419+
myMetadata += "</p>\n";
34193420

34203421
// data source
3421-
myMetadata += "<tr><td>";
3422-
myMetadata += tr( "Source for this layer: %1" ).arg( publicSource() );
3423-
myMetadata += "</td></tr>";
3422+
myMetadata += "<p class=\"glossy\">" + tr( "Source for this layer" ) + "</p>\n";
3423+
myMetadata += "<p>";
3424+
myMetadata += publicSource();
3425+
myMetadata += "</p>\n";
34243426

34253427
//geom type
34263428

@@ -3434,42 +3436,46 @@ QString QgsVectorLayer::metadata()
34343436
{
34353437
QString typeString( QGis::vectorGeometryType( geometryType() ) );
34363438

3437-
myMetadata += "<tr><td>";
3438-
myMetadata += tr( "Geometry type of the features in this layer: %1" ).arg( typeString );
3439-
myMetadata += "</td></tr>";
3439+
myMetadata += "<p class=\"glossy\">" + tr( "Geometry type of the features in this layer" ) + "</p>\n";
3440+
myMetadata += "<p>";
3441+
myMetadata += typeString;
3442+
myMetadata += "</p>\n";
34403443
}
34413444

34423445
QgsAttributeList pkAttrList = pendingPkAttributesList();
34433446
if ( !pkAttrList.isEmpty() )
34443447
{
3445-
myMetadata += "<tr><td>";
3446-
myMetadata += tr( "Primary key attributes: " );
3448+
myMetadata += "<p class=\"glossy\">" + tr( "Primary key attributes" ) + "</p>\n";
3449+
myMetadata += "<p>";
34473450
foreach ( int idx, pkAttrList )
34483451
{
34493452
myMetadata += pendingFields()[ idx ].name() + " ";
34503453
}
3451-
myMetadata += "</td></tr>";
3454+
myMetadata += "</p>\n";
34523455
}
34533456

34543457

34553458
//feature count
3456-
myMetadata += "<tr><td>";
3457-
myMetadata += tr( "The number of features in this layer: %1" ).arg( featureCount() );
3458-
myMetadata += "</td></tr>";
3459+
myMetadata += "<p class=\"glossy\">" + tr( "The number of features in this layer" ) + "</p>\n";
3460+
myMetadata += "<p>";
3461+
myMetadata += QString::number( featureCount() );
3462+
myMetadata += "</p>\n";
34593463
//capabilities
3460-
myMetadata += "<tr><td>";
3461-
myMetadata += tr( "Editing capabilities of this layer: %1" ).arg( capabilitiesString() );
3462-
myMetadata += "</td></tr>";
3464+
myMetadata += "<p class=\"glossy\">" + tr( "Editing capabilities of this layer" ) + "</p>\n";
3465+
myMetadata += "<p>";
3466+
myMetadata += capabilitiesString();
3467+
myMetadata += "</p>\n";
34633468

34643469
//-------------
34653470

34663471
QgsRectangle myExtent = extent();
3467-
myMetadata += "<tr class=\"glossy\"><td>";
3468-
myMetadata += tr( "Extents:" );
3469-
myMetadata += "</td></tr>";
3470-
//extents in layer cs TODO...maybe make a little nested table to improve layout...
3471-
myMetadata += "<tr><td>" + tr( "In layer spatial reference system units : " );
3472+
myMetadata += "<p class=\"subheaderglossy\">";
3473+
myMetadata += tr( "Extents" );
3474+
myMetadata += "</p>\n";
34723475

3476+
//extents in layer cs TODO...maybe make a little nested table to improve layout...
3477+
myMetadata += "<p class=\"glossy\">" + tr( "In layer spatial reference system units" ) + "</p>\n";
3478+
myMetadata += "<p>";
34733479
// Try to be a bit clever over what number format we use for the
34743480
// extents. Some people don't like it using scientific notation when the
34753481
// numbers get large, but for small numbers this is the more practical
@@ -3525,7 +3531,7 @@ QString QgsVectorLayer::metadata()
35253531
myMetadata += tr( "unknown extent" );
35263532
}
35273533

3528-
myMetadata += "</td></tr>";
3534+
myMetadata += "</p>\n";
35293535

35303536
//extents in project cs
35313537

@@ -3534,59 +3540,54 @@ QString QgsVectorLayer::metadata()
35343540
#if 0
35353541
// TODO: currently disabled, will revisit later [MD]
35363542
QgsRectangle myProjectedExtent = coordinateTransform->transformBoundingBox( extent() );
3537-
myMetadata += "<tr><td>";
3538-
myMetadata += tr( "In project spatial reference system units : " )
3539-
+ tr( "xMin,yMin %1,%2 : xMax,yMax %3,%4" )
3543+
myMetadata += "<p class=\"glossy\">" + tr( "In project spatial reference system units" ) + "</p>\n";
3544+
myMetadata += "<p>";
3545+
myMetadata += tr( "xMin,yMin %1,%2 : xMax,yMax %3,%4" )
35403546
.arg( myProjectedExtent.xMinimum() )
35413547
.arg( myProjectedExtent.yMinimum() )
35423548
.arg( myProjectedExtent.xMaximum() )
35433549
.arg( myProjectedExtent.yMaximum() );
3544-
myMetadata += "</td></tr>";
3550+
myMetadata += "</p>\n";
35453551
#endif
35463552

35473553
//
35483554
// Display layer spatial ref system
35493555
//
3550-
myMetadata += "<tr class=\"glossy\"><td>";
3551-
myMetadata += tr( "Layer Spatial Reference System:" );
3552-
myMetadata += "</td></tr>";
3553-
myMetadata += "<tr><td>";
3556+
myMetadata += "<p class=\"glossy\">" + tr( "Layer Spatial Reference System" ) + "</p>\n";
3557+
myMetadata += "<p>";
35543558
myMetadata += crs().toProj4().replace( QRegExp( "\"" ), " \"" );
3555-
myMetadata += "</td></tr>";
3559+
myMetadata += "</p>\n";
35563560

35573561
//
35583562
// Display project (output) spatial ref system
35593563
//
35603564
#if 0
35613565
// TODO: disabled for now, will revisit later [MD]
3562-
myMetadata += "<tr><td bgcolor=\"gray\">";
3563-
myMetadata += tr( "Project (Output) Spatial Reference System:" );
3564-
myMetadata += "</td></tr>";
3565-
myMetadata += "<tr><td>";
3566+
//myMetadata += "<tr><td bgcolor=\"gray\">";
3567+
myMetadata += "<p class=\"glossy\">" + tr( "Project (Output) Spatial Reference System" ) + "</p>\n";
3568+
myMetadata += "<p>";
35663569
myMetadata += coordinateTransform->destCRS().toProj4().replace( QRegExp( "\"" ), " \"" );
3567-
myMetadata += "</td></tr>";
3570+
myMetadata += "</p>\n";
35683571
#endif
35693572
}
35703573
catch ( QgsCsException &cse )
35713574
{
35723575
Q_UNUSED( cse );
35733576
QgsDebugMsg( cse.what() );
35743577

3575-
myMetadata += "<tr><td>";
3576-
myMetadata += tr( "In project spatial reference system units : " )
3577-
+ tr( "(Invalid transformation of layer extents)" );
3578-
myMetadata += "</td></tr>";
3578+
myMetadata += "<p class=\"glossy\">" + tr( "In project spatial reference system units" ) + "</p>\n";
3579+
myMetadata += "<p>";
3580+
myMetadata += tr( "(Invalid transformation of layer extents)" );
3581+
myMetadata += "</p>\n";
35793582

35803583
}
35813584

35823585
#if 0
35833586
//
35843587
// Add the info about each field in the attribute table
35853588
//
3586-
myMetadata += "<tr class=\"glossy\"><td>";
3587-
myMetadata += tr( "Attribute field info:" );
3588-
myMetadata += "</td></tr>";
3589-
myMetadata += "<tr><td>";
3589+
myMetadata += "<p class=\"glossy\">" + tr( "Attribute field info" ) + "</p>\n";
3590+
myMetadata += "<p>";
35903591

35913592
// Start a nested table in this trow
35923593
myMetadata += "<table width=\"100%\">";
@@ -3633,13 +3634,6 @@ QString QgsVectorLayer::metadata()
36333634
myMetadata += "</table>"; //end of nested table
36343635
#endif
36353636

3636-
myMetadata += "</td></tr>"; //end of stats container table row
3637-
//
3638-
// Close the table
3639-
//
3640-
3641-
myMetadata += "</table>";
3642-
36433637
myMetadata += "</body></html>";
36443638
return myMetadata;
36453639
}

‎src/core/raster/qgsrasterlayer.cpp

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -487,7 +487,7 @@ QList< QPair< QString, QColor > > QgsRasterLayer::legendSymbologyItems() const
487487
QString QgsRasterLayer::metadata()
488488
{
489489
QString myMetadata ;
490-
myMetadata += "<p class=\"glossy\">" + tr( "Driver:" ) + "</p>\n";
490+
myMetadata += "<p class=\"glossy\">" + tr( "Driver" ) + "</p>\n";
491491
myMetadata += "<p>";
492492
myMetadata += mDataProvider->description();
493493
myMetadata += "</p>\n";
@@ -513,7 +513,7 @@ QString QgsRasterLayer::metadata()
513513

514514
myMetadata += "</p>\n";
515515
myMetadata += "<p class=\"glossy\">";
516-
myMetadata += tr( "Data Type:" );
516+
myMetadata += tr( "Data Type" );
517517
myMetadata += "</p>\n";
518518
myMetadata += "<p>";
519519
//just use the first band
@@ -558,19 +558,19 @@ QString QgsRasterLayer::metadata()
558558
myMetadata += "</p>\n";
559559

560560
myMetadata += "<p class=\"glossy\">";
561-
myMetadata += tr( "Pyramid overviews:" );
561+
myMetadata += tr( "Pyramid overviews" );
562562
myMetadata += "</p>\n";
563563
myMetadata += "<p>";
564564

565565
myMetadata += "<p class=\"glossy\">";
566-
myMetadata += tr( "Layer Spatial Reference System: " );
566+
myMetadata += tr( "Layer Spatial Reference System" );
567567
myMetadata += "</p>\n";
568568
myMetadata += "<p>";
569569
myMetadata += crs().toProj4();
570570
myMetadata += "</p>\n";
571571

572572
myMetadata += "<p class=\"glossy\">";
573-
myMetadata += tr( "Layer Extent (layer original source projection): " );
573+
myMetadata += tr( "Layer Extent (layer original source projection)" );
574574
myMetadata += "</p>\n";
575575
myMetadata += "<p>";
576576
myMetadata += mDataProvider->extent().toString();
@@ -580,7 +580,7 @@ QString QgsRasterLayer::metadata()
580580
// TODO: this is not related to layer, to be removed? [MD]
581581
#if 0
582582
myMetadata += "<tr><td class=\"glossy\">";
583-
myMetadata += tr( "Project Spatial Reference System: " );
583+
myMetadata += tr( "Project Spatial Reference System" );
584584
myMetadata += "</p>\n";
585585
myMetadata += "<p>";
586586
myMetadata += mCoordinateTransform->destCRS().toProj4();

‎src/gui/qgsoptionsdialogbase.cpp

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,23 @@ void QgsOptionsDialogBase::restoreOptionsBaseUi()
9595
settings.value( QString( "/Windows/%1/splitState" ).arg( mOptsKey ) ).isNull() ? 150 : 16777215 );
9696
mOptSplitter->restoreState( settings.value( QString( "/Windows/%1/splitState" ).arg( mOptsKey ) ).toByteArray() );
9797
int curIndx = settings.value( QString( "/Windows/%1/tab" ).arg( mOptsKey ), 0 ).toInt();
98+
99+
// if the last used tab is not enabled, or is missing, display the first enabled one
100+
if ( !mOptStackedWidget->widget( curIndx )->isEnabled()
101+
|| mOptStackedWidget->count() < ( curIndx + 1 ) )
102+
{
103+
curIndx = 0;
104+
for ( int i = 0; i < mOptStackedWidget->count(); i++ )
105+
{
106+
if ( mOptStackedWidget->widget( i )->isEnabled() )
107+
{
108+
curIndx = i;
109+
break;
110+
}
111+
}
112+
curIndx = -1; // default fallback
113+
}
114+
98115
mOptStackedWidget->setCurrentIndex( curIndx );
99116
mOptListWidget->setCurrentRow( curIndx );
100117

‎src/providers/gdal/qgsgdalprovider.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -289,7 +289,7 @@ QString QgsGdalProvider::metadata()
289289
// end my added code
290290

291291
myMetadata += "<p class=\"glossy\">";
292-
myMetadata += tr( "Dimensions:" );
292+
myMetadata += tr( "Dimensions" );
293293
myMetadata += "</p>\n";
294294
myMetadata += "<p>";
295295
myMetadata += tr( "X: %1 Y: %2 Bands: %3" )
@@ -326,7 +326,7 @@ QString QgsGdalProvider::metadata()
326326
else
327327
{
328328
myMetadata += "<p class=\"glossy\">";
329-
myMetadata += tr( "Origin:" );
329+
myMetadata += tr( "Origin" );
330330
myMetadata += "</p>\n";
331331
myMetadata += "<p>";
332332
myMetadata += QString::number( mGeoTransform[0] );
@@ -335,7 +335,7 @@ QString QgsGdalProvider::metadata()
335335
myMetadata += "</p>\n";
336336

337337
myMetadata += "<p class=\"glossy\">";
338-
myMetadata += tr( "Pixel Size:" );
338+
myMetadata += tr( "Pixel Size" );
339339
myMetadata += "</p>\n";
340340
myMetadata += "<p>";
341341
myMetadata += QString::number( mGeoTransform[1] );

‎src/ui/qgsattributeactiondialogbase.ui

Lines changed: 176 additions & 60 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@
66
<rect>
77
<x>0</x>
88
<y>0</y>
9-
<width>695</width>
10-
<height>476</height>
9+
<width>609</width>
10+
<height>731</height>
1111
</rect>
1212
</property>
1313
<property name="sizePolicy">
@@ -21,12 +21,41 @@
2121
</property>
2222
<layout class="QGridLayout" name="gridLayout_2">
2323
<item row="0" column="0">
24-
<widget class="QGroupBox" name="groupBox_2">
24+
<widget class="QgsCollapsibleGroupBox" name="groupBoxActionList">
25+
<property name="sizePolicy">
26+
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
27+
<horstretch>0</horstretch>
28+
<verstretch>3</verstretch>
29+
</sizepolicy>
30+
</property>
2531
<property name="title">
2632
<string>Action list</string>
2733
</property>
34+
<property name="syncGroup" stdset="0">
35+
<string notr="true">actiongroup</string>
36+
</property>
2837
<layout class="QGridLayout" name="gridLayout_3">
29-
<item row="0" column="0" colspan="5">
38+
<item row="1" column="0">
39+
<widget class="QPushButton" name="moveUpButton">
40+
<property name="sizePolicy">
41+
<sizepolicy hsizetype="Maximum" vsizetype="Fixed">
42+
<horstretch>0</horstretch>
43+
<verstretch>0</verstretch>
44+
</sizepolicy>
45+
</property>
46+
<property name="toolTip">
47+
<string>Move the selected action up</string>
48+
</property>
49+
<property name="text">
50+
<string/>
51+
</property>
52+
<property name="icon">
53+
<iconset resource="../../images/images.qrc">
54+
<normaloff>:/images/themes/default/mActionArrowUp.png</normaloff>:/images/themes/default/mActionArrowUp.png</iconset>
55+
</property>
56+
</widget>
57+
</item>
58+
<item row="0" column="0" colspan="6">
3059
<widget class="QTableWidget" name="attributeActionTable">
3160
<property name="sizePolicy">
3261
<sizepolicy hsizetype="Expanding" vsizetype="Expanding">
@@ -70,60 +99,101 @@
7099
</item>
71100
<item row="1" column="3">
72101
<widget class="QPushButton" name="removeButton">
102+
<property name="sizePolicy">
103+
<sizepolicy hsizetype="Maximum" vsizetype="Fixed">
104+
<horstretch>0</horstretch>
105+
<verstretch>0</verstretch>
106+
</sizepolicy>
107+
</property>
73108
<property name="toolTip">
74109
<string>Remove the selected action</string>
75110
</property>
76111
<property name="text">
77-
<string>Remove action</string>
78-
</property>
79-
</widget>
80-
</item>
81-
<item row="1" column="0">
82-
<widget class="QPushButton" name="moveUpButton">
83-
<property name="toolTip">
84-
<string>Move the selected action up</string>
112+
<string/>
85113
</property>
86-
<property name="text">
87-
<string>Move up</string>
114+
<property name="icon">
115+
<iconset resource="../../images/images.qrc">
116+
<normaloff>:/images/themes/default/symbologyRemove.png</normaloff>:/images/themes/default/symbologyRemove.png</iconset>
88117
</property>
89118
</widget>
90119
</item>
91120
<item row="1" column="1">
92121
<widget class="QPushButton" name="moveDownButton">
122+
<property name="sizePolicy">
123+
<sizepolicy hsizetype="Maximum" vsizetype="Fixed">
124+
<horstretch>0</horstretch>
125+
<verstretch>0</verstretch>
126+
</sizepolicy>
127+
</property>
93128
<property name="toolTip">
94129
<string>Move the selected action down</string>
95130
</property>
96131
<property name="text">
97-
<string>Move down</string>
132+
<string/>
133+
</property>
134+
<property name="icon">
135+
<iconset resource="../../images/images.qrc">
136+
<normaloff>:/images/themes/default/mActionArrowDown.png</normaloff>:/images/themes/default/mActionArrowDown.png</iconset>
98137
</property>
99138
</widget>
100139
</item>
101-
<item row="1" column="4">
140+
<item row="1" column="5">
102141
<widget class="QPushButton" name="addDefaultActionsButton">
103142
<property name="text">
104143
<string>Add default actions</string>
105144
</property>
106145
</widget>
107146
</item>
147+
<item row="1" column="4">
148+
<spacer name="horizontalSpacer_4">
149+
<property name="orientation">
150+
<enum>Qt::Horizontal</enum>
151+
</property>
152+
<property name="sizeHint" stdset="0">
153+
<size>
154+
<width>40</width>
155+
<height>20</height>
156+
</size>
157+
</property>
158+
</spacer>
159+
</item>
160+
<item row="1" column="2">
161+
<spacer name="horizontalSpacer_5">
162+
<property name="orientation">
163+
<enum>Qt::Horizontal</enum>
164+
</property>
165+
<property name="sizeHint" stdset="0">
166+
<size>
167+
<width>40</width>
168+
<height>20</height>
169+
</size>
170+
</property>
171+
</spacer>
172+
</item>
108173
</layout>
109174
</widget>
110175
</item>
111176
<item row="1" column="0">
112-
<widget class="QGroupBox" name="groupBox">
177+
<widget class="QgsCollapsibleGroupBox" name="groupBoxActionProperties">
178+
<property name="sizePolicy">
179+
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
180+
<horstretch>0</horstretch>
181+
<verstretch>3</verstretch>
182+
</sizepolicy>
183+
</property>
113184
<property name="title">
114185
<string>Action properties</string>
115186
</property>
116-
<layout class="QGridLayout" name="gridLayout">
117-
<item row="0" column="0">
118-
<widget class="QLabel" name="label">
119-
<property name="text">
120-
<string>Type</string>
121-
</property>
122-
<property name="buddy">
123-
<cstring>actionType</cstring>
124-
</property>
125-
</widget>
126-
</item>
187+
<property name="syncGroup" stdset="0">
188+
<string notr="true">actiongroup</string>
189+
</property>
190+
<layout class="QFormLayout" name="formLayout">
191+
<property name="fieldGrowthPolicy">
192+
<enum>QFormLayout::AllNonFixedFieldsGrow</enum>
193+
</property>
194+
<property name="labelAlignment">
195+
<set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set>
196+
</property>
127197
<item row="0" column="1">
128198
<layout class="QHBoxLayout" name="horizontalLayout_4">
129199
<item>
@@ -176,7 +246,7 @@
176246
</property>
177247
<property name="sizeHint" stdset="0">
178248
<size>
179-
<width>37</width>
249+
<width>12</width>
180250
<height>24</height>
181251
</size>
182252
</property>
@@ -234,24 +304,8 @@
234304
</widget>
235305
</item>
236306
<item row="2" column="1">
237-
<layout class="QHBoxLayout" name="horizontalLayout">
238-
<item>
239-
<widget class="QPlainTextEdit" name="actionAction">
240-
<property name="sizePolicy">
241-
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
242-
<horstretch>0</horstretch>
243-
<verstretch>0</verstretch>
244-
</sizepolicy>
245-
</property>
246-
<property name="toolTip">
247-
<string>Enter the action command here</string>
248-
</property>
249-
<property name="whatsThis">
250-
<string>Enter the action here. This can be any program, script or command that is available on your system. When the action is invoked any set of characters within [% and %] will be evaluated as expression and replaced by its result. Double quote marks group text into single arguments to the program, script or command. Double quotes will be ignored if prefixed with a backslash</string>
251-
</property>
252-
</widget>
253-
</item>
254-
<item>
307+
<layout class="QGridLayout" name="gridLayout_4">
308+
<item row="0" column="1">
255309
<widget class="QToolButton" name="browseButton">
256310
<property name="toolTip">
257311
<string>Browse for action</string>
@@ -265,6 +319,39 @@
265319
<property name="text">
266320
<string>...</string>
267321
</property>
322+
<property name="icon">
323+
<iconset resource="../../images/images.qrc">
324+
<normaloff>:/images/themes/default/mActionFileOpen.png</normaloff>:/images/themes/default/mActionFileOpen.png</iconset>
325+
</property>
326+
</widget>
327+
</item>
328+
<item row="1" column="1">
329+
<spacer name="verticalSpacer_2">
330+
<property name="orientation">
331+
<enum>Qt::Vertical</enum>
332+
</property>
333+
<property name="sizeHint" stdset="0">
334+
<size>
335+
<width>20</width>
336+
<height>40</height>
337+
</size>
338+
</property>
339+
</spacer>
340+
</item>
341+
<item row="0" column="0" rowspan="2">
342+
<widget class="QPlainTextEdit" name="actionAction">
343+
<property name="sizePolicy">
344+
<sizepolicy hsizetype="Expanding" vsizetype="Expanding">
345+
<horstretch>0</horstretch>
346+
<verstretch>0</verstretch>
347+
</sizepolicy>
348+
</property>
349+
<property name="toolTip">
350+
<string>Enter the action command here</string>
351+
</property>
352+
<property name="whatsThis">
353+
<string>Enter the action here. This can be any program, script or command that is available on your system. When the action is invoked any set of characters within [% and %] will be evaluated as expression and replaced by its result. Double quote marks group text into single arguments to the program, script or command. Double quotes will be ignored if prefixed with a backslash</string>
354+
</property>
268355
</widget>
269356
</item>
270357
</layout>
@@ -297,7 +384,7 @@
297384
</property>
298385
<property name="sizeHint" stdset="0">
299386
<size>
300-
<width>40</width>
387+
<width>12</width>
301388
<height>20</height>
302389
</size>
303390
</property>
@@ -340,7 +427,7 @@
340427
</property>
341428
<property name="sizeHint" stdset="0">
342429
<size>
343-
<width>40</width>
430+
<width>12</width>
344431
<height>20</height>
345432
</size>
346433
</property>
@@ -368,22 +455,49 @@
368455
</item>
369456
</layout>
370457
</item>
371-
<item row="0" column="0">
372-
<widget class="QLabel" name="label_1">
373-
<property name="text">
374-
<string>Type</string>
375-
</property>
376-
<property name="buddy">
377-
<cstring>actionType</cstring>
378-
</property>
379-
</widget>
380-
</item>
381458
</layout>
459+
<widget class="QLabel" name="label">
460+
<property name="geometry">
461+
<rect>
462+
<x>15</x>
463+
<y>33</y>
464+
<width>41</width>
465+
<height>31</height>
466+
</rect>
467+
</property>
468+
<property name="text">
469+
<string>Type</string>
470+
</property>
471+
<property name="buddy">
472+
<cstring>actionType</cstring>
473+
</property>
474+
</widget>
382475
</widget>
383476
</item>
477+
<item row="2" column="0">
478+
<spacer name="verticalSpacer">
479+
<property name="orientation">
480+
<enum>Qt::Vertical</enum>
481+
</property>
482+
<property name="sizeHint" stdset="0">
483+
<size>
484+
<width>20</width>
485+
<height>0</height>
486+
</size>
487+
</property>
488+
</spacer>
489+
</item>
384490
</layout>
385491
</widget>
386492
<layoutdefault spacing="6" margin="11"/>
493+
<customwidgets>
494+
<customwidget>
495+
<class>QgsCollapsibleGroupBox</class>
496+
<extends>QGroupBox</extends>
497+
<header>qgscollapsiblegroupbox.h</header>
498+
<container>1</container>
499+
</customwidget>
500+
</customwidgets>
387501
<tabstops>
388502
<tabstop>attributeActionTable</tabstop>
389503
<tabstop>moveUpButton</tabstop>
@@ -400,6 +514,8 @@
400514
<tabstop>insertButton</tabstop>
401515
<tabstop>updateButton</tabstop>
402516
</tabstops>
403-
<resources/>
517+
<resources>
518+
<include location="../../images/images.qrc"/>
519+
</resources>
404520
<connections/>
405521
</ui>

‎src/ui/qgsdiagrampropertiesbase.ui

Lines changed: 20 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -39,8 +39,8 @@
3939
<rect>
4040
<x>0</x>
4141
<y>0</y>
42-
<width>756</width>
43-
<height>627</height>
42+
<width>752</width>
43+
<height>613</height>
4444
</rect>
4545
</property>
4646
<layout class="QVBoxLayout" name="scrollAreaLayout">
@@ -63,7 +63,7 @@
6363
</property>
6464
<property name="sizeHint" stdset="0">
6565
<size>
66-
<width>40</width>
66+
<width>20</width>
6767
<height>20</height>
6868
</size>
6969
</property>
@@ -124,8 +124,8 @@
124124
<rect>
125125
<x>0</x>
126126
<y>0</y>
127-
<width>725</width>
128-
<height>397</height>
127+
<width>713</width>
128+
<height>394</height>
129129
</rect>
130130
</property>
131131
<attribute name="label">
@@ -307,7 +307,7 @@
307307
</property>
308308
<property name="sizeHint" stdset="0">
309309
<size>
310-
<width>40</width>
310+
<width>0</width>
311311
<height>20</height>
312312
</size>
313313
</property>
@@ -320,8 +320,8 @@
320320
<rect>
321321
<x>0</x>
322322
<y>0</y>
323-
<width>725</width>
324-
<height>293</height>
323+
<width>715</width>
324+
<height>278</height>
325325
</rect>
326326
</property>
327327
<attribute name="label">
@@ -343,7 +343,7 @@
343343
<property name="sizeHint" stdset="0">
344344
<size>
345345
<width>20</width>
346-
<height>40</height>
346+
<height>0</height>
347347
</size>
348348
</property>
349349
</spacer>
@@ -378,7 +378,7 @@
378378
</property>
379379
<property name="sizeHint" stdset="0">
380380
<size>
381-
<width>483</width>
381+
<width>0</width>
382382
<height>20</height>
383383
</size>
384384
</property>
@@ -490,7 +490,7 @@
490490
</property>
491491
<property name="sizeHint" stdset="0">
492492
<size>
493-
<width>40</width>
493+
<width>0</width>
494494
<height>20</height>
495495
</size>
496496
</property>
@@ -509,8 +509,8 @@
509509
<rect>
510510
<x>0</x>
511511
<y>0</y>
512-
<width>725</width>
513-
<height>278</height>
512+
<width>713</width>
513+
<height>271</height>
514514
</rect>
515515
</property>
516516
<attribute name="label">
@@ -638,7 +638,7 @@
638638
</property>
639639
<property name="sizeHint" stdset="0">
640640
<size>
641-
<width>40</width>
641+
<width>0</width>
642642
<height>20</height>
643643
</size>
644644
</property>
@@ -651,7 +651,7 @@
651651
</property>
652652
<property name="sizeHint" stdset="0">
653653
<size>
654-
<width>40</width>
654+
<width>0</width>
655655
<height>20</height>
656656
</size>
657657
</property>
@@ -671,8 +671,8 @@
671671
<rect>
672672
<x>0</x>
673673
<y>0</y>
674-
<width>738</width>
675-
<height>196</height>
674+
<width>728</width>
675+
<height>166</height>
676676
</rect>
677677
</property>
678678
<attribute name="label">
@@ -781,7 +781,7 @@
781781
<property name="sizeHint" stdset="0">
782782
<size>
783783
<width>20</width>
784-
<height>40</height>
784+
<height>0</height>
785785
</size>
786786
</property>
787787
</spacer>
@@ -844,7 +844,7 @@
844844
<property name="sizeHint" stdset="0">
845845
<size>
846846
<width>20</width>
847-
<height>40</height>
847+
<height>0</height>
848848
</size>
849849
</property>
850850
</spacer>
@@ -891,7 +891,7 @@
891891
<property name="sizeHint" stdset="0">
892892
<size>
893893
<width>20</width>
894-
<height>40</height>
894+
<height>0</height>
895895
</size>
896896
</property>
897897
</spacer>

‎src/ui/qgsrasterlayerpropertiesbase.ui

Lines changed: 157 additions & 154 deletions
Large diffs are not rendered by default.

‎src/ui/qgsrulebasedrendererv2widget.ui

Lines changed: 29 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
<rect>
77
<x>0</x>
88
<y>0</y>
9-
<width>643</width>
9+
<width>709</width>
1010
<height>401</height>
1111
</rect>
1212
</property>
@@ -43,34 +43,49 @@
4343
<attribute name="headerStretchLastSection">
4444
<bool>true</bool>
4545
</attribute>
46-
<attribute name="headerMinimumSectionSize">
47-
<number>100</number>
48-
</attribute>
49-
<attribute name="headerStretchLastSection">
50-
<bool>true</bool>
51-
</attribute>
5246
</widget>
5347
</item>
5448
<item>
5549
<layout class="QHBoxLayout" name="horizontalLayout">
5650
<item>
5751
<widget class="QPushButton" name="btnAddRule">
52+
<property name="toolTip">
53+
<string>Add rule</string>
54+
</property>
5855
<property name="text">
59-
<string>Add</string>
56+
<string/>
57+
</property>
58+
<property name="icon">
59+
<iconset resource="../../images/images.qrc">
60+
<normaloff>:/images/themes/default/mActionSignPlus.png</normaloff>:/images/themes/default/mActionSignPlus.png</iconset>
6061
</property>
6162
</widget>
6263
</item>
6364
<item>
6465
<widget class="QPushButton" name="btnEditRule">
66+
<property name="toolTip">
67+
<string>Edit rule</string>
68+
</property>
6569
<property name="text">
66-
<string>Edit</string>
70+
<string/>
71+
</property>
72+
<property name="icon">
73+
<iconset resource="../../images/images.qrc">
74+
<normaloff>:/images/themes/default/symbologyEdit.png</normaloff>:/images/themes/default/symbologyEdit.png</iconset>
6775
</property>
6876
</widget>
6977
</item>
7078
<item>
7179
<widget class="QPushButton" name="btnRemoveRule">
80+
<property name="toolTip">
81+
<string>Remove rule</string>
82+
</property>
7283
<property name="text">
73-
<string>Remove</string>
84+
<string/>
85+
</property>
86+
<property name="icon">
87+
<iconset resource="../../images/images.qrc">
88+
<normaloff>:/images/themes/default/mActionSignMinus.png</normaloff>:/images/themes/default/mActionSignMinus.png</iconset>
7489
</property>
7590
</widget>
7691
</item>
@@ -110,7 +125,7 @@
110125
</property>
111126
<property name="sizeHint" stdset="0">
112127
<size>
113-
<width>40</width>
128+
<width>0</width>
114129
<height>20</height>
115130
</size>
116131
</property>
@@ -127,6 +142,8 @@
127142
</item>
128143
</layout>
129144
</widget>
130-
<resources/>
145+
<resources>
146+
<include location="../../images/images.qrc"/>
147+
</resources>
131148
<connections/>
132149
</ui>

‎src/ui/qgssymbolv2selectordialogbase.ui

Lines changed: 31 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@
66
<rect>
77
<x>0</x>
88
<y>0</y>
9-
<width>509</width>
10-
<height>416</height>
9+
<width>444</width>
10+
<height>383</height>
1111
</rect>
1212
</property>
1313
<property name="windowTitle">
@@ -65,14 +65,17 @@
6565
</widget>
6666
</item>
6767
<item>
68-
<layout class="QHBoxLayout">
68+
<layout class="QHBoxLayout" name="pushBtnBox">
69+
<property name="spacing">
70+
<number>6</number>
71+
</property>
6972
<item>
7073
<widget class="QPushButton" name="btnAddLayer">
71-
<property name="sizePolicy">
72-
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
73-
<horstretch>0</horstretch>
74-
<verstretch>0</verstretch>
75-
</sizepolicy>
74+
<property name="maximumSize">
75+
<size>
76+
<width>50</width>
77+
<height>16777215</height>
78+
</size>
7679
</property>
7780
<property name="toolTip">
7881
<string>Add symbol layer</string>
@@ -81,11 +84,11 @@
8184
</item>
8285
<item>
8386
<widget class="QPushButton" name="btnRemoveLayer">
84-
<property name="sizePolicy">
85-
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
86-
<horstretch>0</horstretch>
87-
<verstretch>0</verstretch>
88-
</sizepolicy>
87+
<property name="maximumSize">
88+
<size>
89+
<width>50</width>
90+
<height>16777215</height>
91+
</size>
8992
</property>
9093
<property name="toolTip">
9194
<string>Remove symbol layer</string>
@@ -94,11 +97,11 @@
9497
</item>
9598
<item>
9699
<widget class="QPushButton" name="btnLock">
97-
<property name="sizePolicy">
98-
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
99-
<horstretch>0</horstretch>
100-
<verstretch>0</verstretch>
101-
</sizepolicy>
100+
<property name="maximumSize">
101+
<size>
102+
<width>50</width>
103+
<height>16777215</height>
104+
</size>
102105
</property>
103106
<property name="toolTip">
104107
<string>Lock layer's color</string>
@@ -110,11 +113,11 @@
110113
</item>
111114
<item>
112115
<widget class="QPushButton" name="btnUp">
113-
<property name="sizePolicy">
114-
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
115-
<horstretch>0</horstretch>
116-
<verstretch>0</verstretch>
117-
</sizepolicy>
116+
<property name="maximumSize">
117+
<size>
118+
<width>50</width>
119+
<height>16777215</height>
120+
</size>
118121
</property>
119122
<property name="toolTip">
120123
<string>Move up</string>
@@ -123,11 +126,11 @@
123126
</item>
124127
<item>
125128
<widget class="QPushButton" name="btnDown">
126-
<property name="sizePolicy">
127-
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
128-
<horstretch>0</horstretch>
129-
<verstretch>0</verstretch>
130-
</sizepolicy>
129+
<property name="maximumSize">
130+
<size>
131+
<width>50</width>
132+
<height>16777215</height>
133+
</size>
131134
</property>
132135
<property name="toolTip">
133136
<string>Move down</string>
@@ -175,8 +178,6 @@
175178
</widget>
176179
</item>
177180
</layout>
178-
<zorder>stackedWidget</zorder>
179-
<zorder>stackedWidget</zorder>
180181
</widget>
181182
</item>
182183
</layout>

‎src/ui/qgsvectorlayerpropertiesbase.ui

Lines changed: 1420 additions & 891 deletions
Large diffs are not rendered by default.

‎src/ui/symbollayer/widget_symbolslist.ui

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -217,7 +217,7 @@
217217
</property>
218218
<property name="sizeHint" stdset="0">
219219
<size>
220-
<width>194</width>
220+
<width>0</width>
221221
<height>20</height>
222222
</size>
223223
</property>
@@ -233,7 +233,7 @@
233233
</property>
234234
<property name="minimumSize">
235235
<size>
236-
<width>150</width>
236+
<width>50</width>
237237
<height>0</height>
238238
</size>
239239
</property>
@@ -300,7 +300,7 @@
300300
</property>
301301
<property name="sizeHint" stdset="0">
302302
<size>
303-
<width>40</width>
303+
<width>0</width>
304304
<height>20</height>
305305
</size>
306306
</property>

0 commit comments

Comments
 (0)
Please sign in to comment.