Skip to content

Commit

Permalink
Turn off layer caching for composer prints
Browse files Browse the repository at this point in the history
git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@11852 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
mhugent committed Oct 26, 2009
1 parent 8ec28fe commit 8bb6da6
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/core/composer/qgscomposermap.cpp
Expand Up @@ -146,7 +146,15 @@ void QgsComposerMap::draw( QPainter *painter, const QgsRectangle& extent, const
//force composer map scale for scale dependent visibility
double bk_scale = theMapRenderer.scale();
theMapRenderer.setScale( scale() );

//layer caching (as QImages) cannot be done for composer prints
QSettings s;
bool bkLayerCaching = s.value( "/qgis/enable_render_caching", false ).toBool();
s.setValue( "/qgis/enable_render_caching", false );

theMapRenderer.render( painter );
s.setValue( "/qgis/enable_render_caching", bkLayerCaching );

theMapRenderer.setScale( bk_scale );
}

Expand Down

0 comments on commit 8bb6da6

Please sign in to comment.