Kaydet (Commit) 07dde826 authored tarafından Zhe Wang's avatar Zhe Wang Kaydeden (comit) Caolán McNamara

Resolves: #i120345# Textbox's position in template file...

(only title) is displayed incorrectly

* subversion/main/sd/source/core/sdpage.cxx

[]Should check the subtitle in master page firstly, and set it to layout if exist

Patch by: Ma Bingbing <jiazema@gmail.com>
Suggested by: Wang Zhe <kingwisemmx@gmail.com>
Found by: Ma Bingbing <jiazema@gmail.com>
Review by: Wang Zhe <kingwisemmx@gmail.com>

(cherry picked from commit d07b6ad5)

Change-Id: Id1843a0e856a1bf98378868c68b1f9216ce71d1b
üst 8465cb8e
...@@ -1169,6 +1169,7 @@ static void CalcAutoLayoutRectangles( SdPage& rPage, int nLayout, Rectangle* rRe ...@@ -1169,6 +1169,7 @@ static void CalcAutoLayoutRectangles( SdPage& rPage, int nLayout, Rectangle* rRe
{ {
SdPage& rMasterPage = static_cast<SdPage&>(rPage.TRG_GetMasterPage()); SdPage& rMasterPage = static_cast<SdPage&>(rPage.TRG_GetMasterPage());
SdrObject* pMasterTitle = rMasterPage.GetPresObj( PRESOBJ_TITLE ); SdrObject* pMasterTitle = rMasterPage.GetPresObj( PRESOBJ_TITLE );
SdrObject* pMasterSubTitle = rMasterPage.GetPresObj( PRESOBJ_TEXT );
SdrObject* pMasterOutline = rMasterPage.GetPresObj( rPage.GetPageKind()==PK_NOTES ? PRESOBJ_NOTES : PRESOBJ_OUTLINE ); SdrObject* pMasterOutline = rMasterPage.GetPresObj( rPage.GetPageKind()==PK_NOTES ? PRESOBJ_NOTES : PRESOBJ_OUTLINE );
if( pMasterTitle ) if( pMasterTitle )
...@@ -1176,8 +1177,9 @@ static void CalcAutoLayoutRectangles( SdPage& rPage, int nLayout, Rectangle* rRe ...@@ -1176,8 +1177,9 @@ static void CalcAutoLayoutRectangles( SdPage& rPage, int nLayout, Rectangle* rRe
if (aTitleRect.IsEmpty() ) if (aTitleRect.IsEmpty() )
aTitleRect = rPage.GetTitleRect(); aTitleRect = rPage.GetTitleRect();
if( pMasterSubTitle )
if( pMasterOutline ) aLayoutRect = pMasterSubTitle->GetLogicRect();
else if( pMasterOutline )
aLayoutRect = pMasterOutline->GetLogicRect(); aLayoutRect = pMasterOutline->GetLogicRect();
if (aLayoutRect.IsEmpty() ) if (aLayoutRect.IsEmpty() )
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment