mirror of
https://github.com/qgis/QGIS.git
synced 2025-04-17 00:04:02 -04:00
Set view box for svg export explicitely (thanks to JD)
git-svn-id: http://svn.osgeo.org/qgis/trunk@14910 c8812cc2-4d05-0410-92ff-de0c093fc19c
This commit is contained in:
parent
60fda2ab11
commit
3a48287f12
@ -818,6 +818,7 @@ void QgsComposer::on_mActionExportAsSVG_triggered()
|
||||
//height in pixel
|
||||
int height = ( int )( mComposition->paperHeight() * mComposition->printResolution() / 25.4 );
|
||||
generator.setSize( QSize( width, height ) );
|
||||
generator.setViewBox( QRect( 0, 0, width, height ) );
|
||||
generator.setResolution( mComposition->printResolution() ); //because the rendering is done in mm, convert the dpi
|
||||
|
||||
QPainter p( &generator );
|
||||
|
Loading…
x
Reference in New Issue
Block a user