diff options
author | Sun Ying <sunying@apache.org> | 2012-08-17 07:56:17 +0000 |
---|---|---|
committer | Sun Ying <sunying@apache.org> | 2012-08-17 07:56:17 +0000 |
commit | 8d04823a6038d32f6ac9821925616da7c5cc44c9 (patch) | |
tree | a0710adf241970dbffaf4a1b1d413610bfb00531 /sd | |
parent | 5a98c86e2be861fe3c9d3976e60dddbed67d693e (diff) |
#119866# fix the bullet in default outline area lost when open .ppt file
Reported by: Li Feng Wang
Patch by: Ying Sun
Review by: Jian Yuan Li
Notes
Notes:
merged as: 28f2af669f01cd304994f1907de0b61245b3d37a
Diffstat (limited to 'sd')
-rw-r--r-- | sd/source/filter/ppt/pptin.cxx | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/sd/source/filter/ppt/pptin.cxx b/sd/source/filter/ppt/pptin.cxx index 7f4d9bb898be..b85068ba0a4a 100644 --- a/sd/source/filter/ppt/pptin.cxx +++ b/sd/source/filter/ppt/pptin.cxx @@ -2392,7 +2392,10 @@ SdrObject* ImplSdPPTImport::ApplyTextObj( PPTTextObj* pTextObj, SdrTextObj* pObj sal_Bool bVertical = sal_False; if ( ( pTextObj->GetShapeType() == mso_sptRectangle ) || ( pTextObj->GetShapeType() == mso_sptTextBox ) ) { - if ( pTextObj->Count() ) + //if a placeholder with some custom attribute,the pTextObj will keep those attr,whose text size is zero, + //so sdPage should renew a PresObj to process placeholder. + if ( pTextObj->Count() > 1 || + ( pTextObj->Count() == 1 &&(pTextObj->First()) && pTextObj->First()->GetTextSize()>0 )) bEmptyPresObj = sal_False; switch ( nPlaceholderId ) { @@ -2454,6 +2457,16 @@ SdrObject* ImplSdPPTImport::ApplyTextObj( PPTTextObj* pTextObj, SdrTextObj* pObj ApplyAttributes( rStCtrl, aSet ); pPresObj->SetLogicRect(pText->GetLogicRect()); ApplyTextAnchorAttributes( *pTextObj, aSet ); + //set custom font attribute of the placeholder + if ( pTextObj->Count() == 1 ) + { + PPTParagraphObj* pPara = pTextObj->First(); + PPTPortionObj* pPor = NULL; + if ( pPara && pPara->GetTextSize() == 0 && (pPor = pPara->First())) + { + pPor->ApplyTo(aSet, (SdrPowerPointImport&)*this, pTextObj->GetDestinationInstance()); + } + } pPresObj->SetMergedItemSet(aSet); if ( ( eAktPageKind != PPT_NOTEPAGE ) && ( pSlideLayout->aPlacementId[ i ] != (sal_uLong)-1 ) ) |