Skip to content
Permalink
Browse files

[style manager] inform users of successful import

  • Loading branch information
nirvn committed Nov 20, 2016
1 parent 08f8ca7 commit 19368cfbee257d3a4b3d34a8828eb9f1fd831834
Showing with 21 additions and 6 deletions.
  1. +8 −2 src/gui/symbology-ng/qgsstyleexportimportdialog.cpp
  2. +13 −4 src/ui/qgsstyleexportimportdialogbase.ui
@@ -151,6 +151,12 @@ void QgsStyleExportImportDialog::doExportImport()
.arg( mTempStyle->errorString() ) );
return;
}
else
{
QMessageBox::information( this, tr( "Export successful" ),
tr( "The selected symbols were successfully exported to file:\n%1" )
.arg( mFileName ) );
}
}
else // import
{
@@ -192,7 +198,7 @@ bool QgsStyleExportImportDialog::populateStyles( QgsStyle* style )
name = styleNames[i];
QgsSymbol* symbol = style->symbol( name );
QStandardItem* item = new QStandardItem( name );
QIcon icon = QgsSymbolLayerUtils::symbolPreviewIcon( symbol, listItems->iconSize() );
QIcon icon = QgsSymbolLayerUtils::symbolPreviewIcon( symbol, listItems->iconSize(), 15 );
item->setIcon( icon );
model->appendRow( item );
delete symbol;
@@ -207,7 +213,7 @@ bool QgsStyleExportImportDialog::populateStyles( QgsStyle* style )
QScopedPointer< QgsColorRamp > ramp( style->colorRamp( name ) );

QStandardItem* item = new QStandardItem( name );
QIcon icon = QgsSymbolLayerUtils::colorRampPreviewIcon( ramp.data(), listItems->iconSize() );
QIcon icon = QgsSymbolLayerUtils::colorRampPreviewIcon( ramp.data(), listItems->iconSize(), 15 );
item->setIcon( icon );
model->appendRow( item );
}
@@ -111,12 +111,15 @@
</property>
<property name="iconSize">
<size>
<width>48</width>
<height>48</height>
<width>77</width>
<height>70</height>
</size>
</property>
<property name="movement">
<enum>QListView::Static</enum>
<property name="textElideMode">
<enum>Qt::ElideNone</enum>
</property>
<property name="flow">
<enum>QListView::LeftToRight</enum>
</property>
<property name="resizeMode">
<enum>QListView::Adjust</enum>
@@ -127,6 +130,12 @@
<property name="viewMode">
<enum>QListView::IconMode</enum>
</property>
<property name="uniformItemSizes">
<bool>true</bool>
</property>
<property name="wordWrap">
<bool>true</bool>
</property>
</widget>
</item>
<item row="3" column="0">

0 comments on commit 19368cf

Please sign in to comment.
You can’t perform that action at this time.