r18900 by fschmid - Fixed Bug #12137: Opening Master Page dialog changes page orientation of imported Publisher file
scribus-commit
scribus-commit at lists.scribus.net
Tue Mar 11 20:08:58 UTC 2014
Author: fschmid
Date: Tue Mar 11 20:08:57 2014
New Revision: 18900
URL: http://scribus.net/websvn/listing.php?repname=Scribus&sc=1&rev=18900
Log:
Fixed Bug #12137: Opening Master Page dialog changes page orientation of imported Publisher file
Modified:
trunk/Scribus/scribus/scribus.cpp
Modified: trunk/Scribus/scribus/scribus.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=18900&path=/trunk/Scribus/scribus/scribus.cpp
==============================================================================
--- trunk/Scribus/scribus/scribus.cpp (original)
+++ trunk/Scribus/scribus/scribus.cpp Tue Mar 11 20:08:57 2014
@@ -4294,7 +4294,21 @@
// propertiesPalette->updateCList();
doc->hasName = true;
if (doc->MasterPages.count() == 0)
- doc->addMasterPage(0, CommonStrings::masterPageNormal);
+ {
+ ScPage *docPage = doc->Pages->at(0);
+ ScPage *addedPage = doc->addMasterPage(0, CommonStrings::masterPageNormal);
+ addedPage->m_pageSize = docPage->m_pageSize;
+ addedPage->setInitialHeight(docPage->height());
+ addedPage->setInitialWidth(docPage->width());
+ addedPage->setHeight(docPage->height());
+ addedPage->setWidth(docPage->width());
+ addedPage->initialMargins.Top = docPage->initialMargins.Top;
+ addedPage->initialMargins.Bottom = docPage->initialMargins.Bottom;
+ addedPage->initialMargins.Left = docPage->initialMargins.Left;
+ addedPage->initialMargins.Right = docPage->initialMargins.Right;
+ addedPage->LeftPg = docPage->LeftPg;
+ addedPage->setOrientation(docPage->orientation());
+ }
//Add doc sections if we have none
if (doc->sections().count()==0)
{
More information about the scribus-commit
mailing list