Skip to content

Commit 07e13be

Browse files
author
mhugent
committed
Avoid overwriting of printing page with width/height from composition
git-svn-id: http://svn.osgeo.org/qgis/trunk@14082 c8812cc2-4d05-0410-92ff-de0c093fc19c
1 parent 3ccbb98 commit 07e13be

File tree

1 file changed

+1
-13
lines changed

1 file changed

+1
-13
lines changed

src/app/composer/qgscomposer.cpp

Lines changed: 1 addition & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -495,19 +495,7 @@ void QgsComposer::on_mActionExportAsPDF_triggered()
495495

496496
void QgsComposer::on_mActionPrint_triggered()
497497
{
498-
//QPrinter printer;
499-
if ( mComposition )
500-
{
501-
if ( mComposition->paperWidth() >= mComposition->paperHeight() )
502-
{
503-
mPrinter.setOrientation( QPrinter::Landscape );
504-
}
505-
else
506-
{
507-
mPrinter.setOrientation( QPrinter::Portrait );
508-
}
509-
}
510-
mPrinter.setPaperSize( QSizeF( mComposition->paperWidth(), mComposition->paperHeight() ), QPrinter::Millimeter );
498+
//orientation and page size are already set to QPrinter in the page setup dialog
511499
QPrintDialog printDialog( &mPrinter, 0 );
512500
if ( printDialog.exec() != QDialog::Accepted )
513501
{

0 commit comments

Comments
 (0)