summaryrefslogtreecommitdiff
path: root/oox
diff options
context:
space:
mode:
authorMuthu Subramanian <sumuthu@suse.com>2012-02-10 14:52:05 +0530
committerMuthu Subramanian <sumuthu@suse.com>2012-02-10 14:54:46 +0530
commitb93463bcfe79a80773c622bc27ccffc54d3eb71e (patch)
tree0aae0f897f40f12858de4195da59aa5276f37923 /oox
parent1ae7ac2a031b037174f03f170af013e0d4736424 (diff)
n744512: Fixed formatting of tables.
otherStyle needs to be used to format tables. removed wrong defaultStyling. added using masterslide style info correctly.
Diffstat (limited to 'oox')
-rw-r--r--oox/source/ppt/pptshape.cxx17
-rw-r--r--oox/source/ppt/slidepersist.cxx2
2 files changed, 16 insertions, 3 deletions
diff --git a/oox/source/ppt/pptshape.cxx b/oox/source/ppt/pptshape.cxx
index 17ceb301a7fc..0bd2ce453886 100644
--- a/oox/source/ppt/pptshape.cxx
+++ b/oox/source/ppt/pptshape.cxx
@@ -308,9 +308,22 @@ void PPTShape::addShape(
if ( !sServiceName.isEmpty() )
{
- // use style from master slide for placeholders only, otherwise use slide's style, which might be the default style from presentation
if ( !aMasterTextListStyle.get() )
- aMasterTextListStyle = ( mnSubType && rSlidePersist.getMasterPersist().get() ) ? rSlidePersist.getMasterPersist()->getOtherTextStyle() : rSlidePersist.getOtherTextStyle();
+ {
+ bool isOther = !getTextBody().get();
+ TextListStylePtr aSlideStyle = isOther ? rSlidePersist.getOtherTextStyle() : rSlidePersist.getDefaultTextStyle();
+ // Combine from MasterSlide details as well.
+ if( rSlidePersist.getMasterPersist().get() )
+ {
+ aMasterTextListStyle = isOther ? rSlidePersist.getMasterPersist()->getOtherTextStyle() : rSlidePersist.getMasterPersist()->getDefaultTextStyle();
+ if( aSlideStyle.get() )
+ aMasterTextListStyle->apply( *aSlideStyle.get() );
+ }
+ else
+ {
+ aMasterTextListStyle = aSlideStyle;
+ }
+ }
if( aMasterTextListStyle.get() && getTextBody().get() ) {
TextListStylePtr aCombinedTextListStyle (new TextListStyle());
diff --git a/oox/source/ppt/slidepersist.cxx b/oox/source/ppt/slidepersist.cxx
index 91f773457a03..77432aee694d 100644
--- a/oox/source/ppt/slidepersist.cxx
+++ b/oox/source/ppt/slidepersist.cxx
@@ -71,8 +71,8 @@ SlidePersist::SlidePersist( XmlFilterBase& rFilter, sal_Bool bMaster, sal_Bool b
maTitleTextStylePtr->apply( *pDefaultTextStyle.get() );
maBodyTextStylePtr->apply( *pDefaultTextStyle.get() );
maNotesTextStylePtr->apply( *pDefaultTextStyle.get() );
- */
maOtherTextStylePtr->apply( *pDefaultTextStyle.get() );
+ */
}
#if OSL_DEBUG_LEVEL > 0
mxDebugPage = mxPage;