mirror of
https://github.com/qgis/QGIS.git
synced 2025-02-25 00:58:06 -05:00
Merge from 0.7 release branch:
For Mac, don't call QPrinter::setOutputToFile(true) before QPrinter::setup(). Doing so will suppress the Mac Print dialog and disable paper printing. This edit disables Mac eps output but the Mac has a pdf option in its standard Print dialog. git-svn-id: http://svn.osgeo.org/qgis/trunk@4040 c8812cc2-4d05-0410-92ff-de0c093fc19c
This commit is contained in:
parent
7680551320
commit
43ab522519
@ -252,8 +252,16 @@ void QgsComposer::print(void)
|
||||
//mPrinter = new QPrinter ( QPrinter::HighResolution );
|
||||
//mPrinter = new QPrinter ( QPrinter::ScreenResolution );
|
||||
mPrinter->setFullPage ( true );
|
||||
#ifndef Q_OS_MACX
|
||||
// For Qt/Mac 3, don't set outputToFile to true before calling setup
|
||||
// because it wiil suppress the Print dialog and output to file without
|
||||
// giving the user a chance to select a printer instead.
|
||||
// The Mac Print dialog provides an option to create a pdf which is
|
||||
// intended to be invisible to the application. If an eps is desired,
|
||||
// a custom Mac Print dialog is needed.
|
||||
mPrinter->setOutputToFile (true ) ;
|
||||
mPrinter->setOutputFileName ( QDir::convertSeparators ( QDir::home().path() + "/" + "qgis.eps") );
|
||||
#endif
|
||||
|
||||
if ( mComposition->paperOrientation() == QgsComposition::Portrait ) {
|
||||
mPrinter->setOrientation ( QPrinter::Portrait );
|
||||
|
Loading…
x
Reference in New Issue
Block a user