Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
|
@@ -721,7 +721,8 @@ void QgsRasterLayerProperties::sync() |
|
|
} |
|
|
|
|
|
//get the thumbnail for the layer |
|
|
pixmapThumbnail->setPixmap( mRasterLayer->previewAsPixmap( pixmapThumbnail->size() ) ); |
|
|
QPixmap thumbnail = QPixmap::fromImage( mRasterLayer->previewAsImage( pixmapThumbnail->size() ) ); |
|
|
pixmapThumbnail->setPixmap( thumbnail ); |
|
|
|
|
|
// TODO fix legend + palette pixmap |
|
|
|
|
@@ -927,7 +928,8 @@ void QgsRasterLayerProperties::apply() |
|
|
mRasterLayer->setBlendMode( mBlendModeComboBox->blendMode() ); |
|
|
|
|
|
//get the thumbnail for the layer |
|
|
pixmapThumbnail->setPixmap( mRasterLayer->previewAsPixmap( pixmapThumbnail->size() ) ); |
|
|
QPixmap thumbnail = QPixmap::fromImage( mRasterLayer->previewAsImage( pixmapThumbnail->size() ) ); |
|
|
pixmapThumbnail->setPixmap( thumbnail ); |
|
|
|
|
|
mRasterLayer->setTitle( mLayerTitleLineEdit->text() ); |
|
|
mRasterLayer->setAbstract( mLayerAbstractTextEdit->toPlainText() ); |
|
|
|
@@ -192,7 +192,7 @@ QVariant QgsLayerTreeModel::data( const QModelIndex &index, int role ) const |
|
|
if ( testFlag( ShowRasterPreviewIcon ) ) |
|
|
{ |
|
|
QgsRasterLayer* rlayer = qobject_cast<QgsRasterLayer *>( layer ); |
|
|
return QIcon( rlayer->previewAsPixmap( QSize( 32, 32 ) ) ); |
|
|
return QIcon( QPixmap::fromImage( rlayer->previewAsImage( QSize( 32, 32 ) ) ) ); |
|
|
} |
|
|
else |
|
|
{ |
|
|
You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session.
You signed out in another tab or window. Reload to refresh your session.
This comment has been minimized.
1516e63
@m-kuhn nice!