summaryrefslogtreecommitdiff
path: root/svx
diff options
context:
space:
mode:
authorKurt Zenker <kz@openoffice.org>2010-07-13 14:02:33 +0200
committerKurt Zenker <kz@openoffice.org>2010-07-13 14:02:33 +0200
commita8708cedf6b0f9cf3d18c1e4c6e881185b98accf (patch)
tree55c234e10d47cd7a3f745e6038d332b30712051c /svx
parent910056401972274d3ed4ec6150b68a1bc206fa41 (diff)
parentf5dca43c9a814b8955edf6968443737e521162dc (diff)
CWS-TOOLING: integrate CWS impress192_OOO330
Diffstat (limited to 'svx')
-rw-r--r--svx/inc/svx/svdmodel.hxx6
-rw-r--r--svx/source/sdr/primitive2d/sdrtextprimitive2d.cxx12
-rw-r--r--svx/source/sdr/properties/textproperties.cxx21
-rw-r--r--svx/source/svdraw/svdmodel.cxx1
4 files changed, 28 insertions, 12 deletions
diff --git a/svx/inc/svx/svdmodel.hxx b/svx/inc/svx/svdmodel.hxx
index fc8d401f94e7..328efedd98f0 100644
--- a/svx/inc/svx/svdmodel.hxx
+++ b/svx/inc/svx/svdmodel.hxx
@@ -276,7 +276,7 @@ public:
SdrOutlinerCache* mpOutlinerCache;
SdrModelImpl* mpImpl;
UINT16 mnCharCompressType;
- UINT16 nReserveUInt5;
+ UINT16 mnHandoutPageCount;
UINT16 nReserveUInt6;
UINT16 nReserveUInt7;
FASTBOOL mbModelLocked;
@@ -298,6 +298,10 @@ public:
SvNumberFormatter* mpNumberFormatter;
public:
const SvNumberFormatter& GetNumberFormatter() const;
+
+ UINT16 getHandoutPageCount() const { return mnHandoutPageCount; }
+ void setHandoutPageCount( UINT16 nHandoutPageCount ) { mnHandoutPageCount = nHandoutPageCount; }
+
protected:
virtual ::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface > createUnoModel();
diff --git a/svx/source/sdr/primitive2d/sdrtextprimitive2d.cxx b/svx/source/sdr/primitive2d/sdrtextprimitive2d.cxx
index 2320944afd03..089f75aa8ade 100644
--- a/svx/source/sdr/primitive2d/sdrtextprimitive2d.cxx
+++ b/svx/source/sdr/primitive2d/sdrtextprimitive2d.cxx
@@ -77,8 +77,16 @@ namespace
if(pPage && pPage->GetModel())
{
- const sal_uInt16 nPageCount(pPage->GetModel()->GetPageCount());
- nRetval = ((sal_Int16)nPageCount - 1) / 2;
+ if( (pPage->GetPageNum() == 0) && !pPage->IsMasterPage() )
+ {
+ // handout page!
+ return pPage->GetModel()->getHandoutPageCount();
+ }
+ else
+ {
+ const sal_uInt16 nPageCount(pPage->GetModel()->GetPageCount());
+ nRetval = ((sal_Int16)nPageCount - 1) / 2;
+ }
}
return nRetval;
diff --git a/svx/source/sdr/properties/textproperties.cxx b/svx/source/sdr/properties/textproperties.cxx
index 348c319e256e..091656e1f261 100644
--- a/svx/source/sdr/properties/textproperties.cxx
+++ b/svx/source/sdr/properties/textproperties.cxx
@@ -185,18 +185,21 @@ namespace sdr
{
SdrText* pText = rObj.getText( nCount );
OutlinerParaObject* pParaObj = pText->GetOutlinerParaObject();
- rOutliner.SetText(*pParaObj);
- sal_uInt32 nParaCount(rOutliner.GetParagraphCount());
-
- if(nParaCount)
+ if( pParaObj )
{
- ESelection aSelection( 0, 0, EE_PARA_ALL, EE_PARA_ALL);
- rOutliner.RemoveAttribs(aSelection, sal_True, 0);
+ rOutliner.SetText(*pParaObj);
+ sal_uInt32 nParaCount(rOutliner.GetParagraphCount());
- OutlinerParaObject* pTemp = rOutliner.CreateParaObject(0, (sal_uInt16)nParaCount);
- rOutliner.Clear();
+ if(nParaCount)
+ {
+ ESelection aSelection( 0, 0, EE_PARA_ALL, EE_PARA_ALL);
+ rOutliner.RemoveAttribs(aSelection, sal_True, 0);
- rObj.NbcSetOutlinerParaObjectForText( pTemp, pText );
+ OutlinerParaObject* pTemp = rOutliner.CreateParaObject(0, (sal_uInt16)nParaCount);
+ rOutliner.Clear();
+
+ rObj.NbcSetOutlinerParaObjectForText( pTemp, pText );
+ }
}
}
}
diff --git a/svx/source/svdraw/svdmodel.cxx b/svx/source/svdraw/svdmodel.cxx
index 2fcdfdffbb8a..8ab385fa329c 100644
--- a/svx/source/svdraw/svdmodel.cxx
+++ b/svx/source/svdraw/svdmodel.cxx
@@ -178,6 +178,7 @@ void SdrModel::ImpCtor(SfxItemPool* pPool, ::comphelper::IEmbeddedHelper* _pEmbe
mpOutlinerCache = NULL;
mbKernAsianPunctuation = sal_False;
mbAddExtLeading = sal_False;
+ mnHandoutPageCount = 0;
SvxAsianConfig aAsian;
mnCharCompressType = aAsian.GetCharDistanceCompression();