Skip to content
Permalink
Browse files
Make save as image work for new histogram implementation
  • Loading branch information
timlinux committed Nov 21, 2011
1 parent 8d465ec commit 6191319ac9c694613da5236fbc81cb6c9d638446
Showing with 2 additions and 2 deletions.
  1. +2 −2 src/app/qgsrasterlayerproperties.cpp
@@ -1915,12 +1915,12 @@ void QgsRasterLayerProperties::refreshHistogram()
void QgsRasterLayerProperties::on_mSaveAsImageButton_clicked()
{

QPixmap myPixmap( 600, 600 );
QPixmap myPixmap( mWebPlot->width(), mWebPlot->height() );
myPixmap.fill( Qt::white ); // Qt::transparent ?

QPainter painter;
painter.begin( &myPixmap );
//mWebPlot->drawCanvas( &painter );
mWebPlot->render( &painter );
painter.end();
QPair< QString, QString> myFileNameAndFilter = QgisGui::getSaveAsImageName( this, tr( "Choose a file name to save the map image as" ) );
if ( myFileNameAndFilter.first != "" )

0 comments on commit 6191319

Please sign in to comment.