Skip to content

Commit 7e8124d

Browse files
author
mhugent
committed
Fix for problem where paper settings in composer have not been restored properly
git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@11960 c8812cc2-4d05-0410-92ff-de0c093fc19c
1 parent 22d95aa commit 7e8124d

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

src/app/composer/qgscomposer.cpp

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1079,8 +1079,14 @@ void QgsComposer::readXML( const QDomElement& composerElem, const QDomDocument&
10791079
mView = new QgsComposerView( mViewFrame );
10801080
connectSlots();
10811081

1082+
//read composition settings
10821083
mComposition = new QgsComposition( mQgis->mapCanvas()->mapRenderer() );
1083-
mComposition->readXML( composerElem, doc );
1084+
QDomNodeList compositionNodeList = composerElem.elementsByTagName( "Composition" );
1085+
if ( compositionNodeList.size() > 0 )
1086+
{
1087+
QDomElement compositionElem = compositionNodeList.at( 0 ).toElement();
1088+
mComposition->readXML( compositionElem, doc );
1089+
}
10841090

10851091
QGridLayout *l = new QGridLayout( mViewFrame );
10861092
l->setMargin( 0 );

0 commit comments

Comments
 (0)