summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--editeng/source/items/paraitem.cxx2
-rw-r--r--editeng/source/items/textitem.cxx2
-rw-r--r--include/editeng/opaqitem.hxx2
-rw-r--r--include/editeng/prntitem.hxx2
-rw-r--r--include/svl/poolitem.hxx44
-rw-r--r--include/svx/sdmetitm.hxx3
-rw-r--r--include/svx/sdooitm.hxx2
-rw-r--r--include/svx/sdtaiitm.hxx4
-rw-r--r--include/svx/sxcecitm.hxx2
-rw-r--r--include/svx/sxcllitm.hxx4
-rw-r--r--include/svx/sxmbritm.hxx2
-rw-r--r--include/svx/sxmtfitm.hxx5
-rw-r--r--include/svx/sxmtritm.hxx4
-rw-r--r--sc/source/core/data/attrib.cxx8
-rw-r--r--svl/source/items/globalpool.cxx10
-rw-r--r--svx/inc/sxopitm.hxx5
-rw-r--r--svx/source/engine3d/svx3ditems.cxx13
-rw-r--r--svx/source/svdraw/svdattr.cxx2
-rw-r--r--svx/source/xoutdev/xattr.cxx2
-rw-r--r--sw/inc/fmtclbl.hxx2
-rw-r--r--sw/inc/fmteiro.hxx2
-rw-r--r--sw/inc/fmtfollowtextflow.hxx2
-rw-r--r--sw/inc/fmtlsplt.hxx2
-rw-r--r--sw/inc/fmtrowsplt.hxx2
-rw-r--r--sw/inc/hfspacingitem.hxx2
-rw-r--r--sw/source/core/attr/formatflysplit.cxx2
-rw-r--r--sw/source/core/attr/formatwraptextatflystart.cxx2
27 files changed, 89 insertions, 45 deletions
diff --git a/editeng/source/items/paraitem.cxx b/editeng/source/items/paraitem.cxx
index ce547ff38d63..c75f236f8246 100644
--- a/editeng/source/items/paraitem.cxx
+++ b/editeng/source/items/paraitem.cxx
@@ -566,7 +566,7 @@ bool SvxOrphansItem::GetPresentation
// class SvxHyphenZoneItem -----------------------------------------------
SvxHyphenZoneItem::SvxHyphenZoneItem( const bool bHyph, const sal_uInt16 nId ) :
- SfxPoolItem( nId, SfxItemType::SvxHyphenZoneItem ),
+ SfxPoolItem( nId, SfxItemType::SvxHyphenZoneItemType ),
bHyphen(bHyph),
bKeep(false),
bNoCapsHyphenation(false),
diff --git a/editeng/source/items/textitem.cxx b/editeng/source/items/textitem.cxx
index 664c5db802ad..196182b3b973 100644
--- a/editeng/source/items/textitem.cxx
+++ b/editeng/source/items/textitem.cxx
@@ -2573,7 +2573,7 @@ void SvxCharRotateItem::dumpAsXml(xmlTextWriterPtr pWriter) const
SvxCharScaleWidthItem::SvxCharScaleWidthItem( sal_uInt16 nValue,
TypedWhichId<SvxCharScaleWidthItem> nW )
- : SfxUInt16Item( nW, nValue, SfxItemType::SvxCharScaleWidthItem )
+ : SfxUInt16Item( nW, nValue, SfxItemType::SvxCharScaleWidthItemType )
{
}
diff --git a/include/editeng/opaqitem.hxx b/include/editeng/opaqitem.hxx
index d38747747c55..112a62e6aaef 100644
--- a/include/editeng/opaqitem.hxx
+++ b/include/editeng/opaqitem.hxx
@@ -45,7 +45,7 @@ public:
};
inline SvxOpaqueItem::SvxOpaqueItem( const sal_uInt16 nId, const bool bOpa )
- : SfxBoolItem( nId, bOpa )
+ : SfxBoolItem( nId, bOpa, SfxItemType::SvxOpaqueItemType )
{}
#endif
diff --git a/include/editeng/prntitem.hxx b/include/editeng/prntitem.hxx
index 8f0e6a8fc855..34f490b46084 100644
--- a/include/editeng/prntitem.hxx
+++ b/include/editeng/prntitem.hxx
@@ -47,7 +47,7 @@ public:
};
inline SvxPrintItem::SvxPrintItem( const sal_uInt16 nId, const bool bPrt )
- : SfxBoolItem( nId, bPrt )
+ : SfxBoolItem( nId, bPrt, SfxItemType::SvxPrintItemType )
{}
#endif
diff --git a/include/svl/poolitem.hxx b/include/svl/poolitem.hxx
index 0d0c4771d429..fb51a7fa3335 100644
--- a/include/svl/poolitem.hxx
+++ b/include/svl/poolitem.hxx
@@ -127,13 +127,16 @@ enum class SfxItemType : sal_uInt16 {
SbxItemType,
ScCondFormatItemType,
ScConsolidateItemType,
+ ScHyphenateCellType,
ScInputStatusItemType,
+ ScLineBreakCellType,
ScMergeAttrType,
ScPageHFItemType,
ScPageScaleToItemType,
ScPivotItemType,
ScProtectionAttrType,
ScQueryItemType,
+ ScShrinkToFitCellType,
ScSolveItemType,
ScSortItemType,
ScSubTotalItemType,
@@ -144,13 +147,16 @@ enum class SfxItemType : sal_uInt16 {
ScTpPrintItemType,
ScTpViewItemType,
ScUserListItemType,
+ ScVerticalStackCellType,
ScViewObjectModeItemType,
SdOptionsMiscItemType,
SdOptionsPrintItemType,
SdOptionsSnapItemType,
SdrAngleItemType,
SdrCaptionEscDirItemType,
- SdrCaptionTypeItem,
+ SdrCaptionEscIsRelItemType,
+ SdrCaptionFitLineLenItemType,
+ SdrCaptionLineLenItemType,
SdrCaptionTypeItemType,
SdrCircKindItemType,
SdrCustomShapeGeometryItemType,
@@ -159,22 +165,34 @@ enum class SfxItemType : sal_uInt16 {
SdrGrafModeItem_Base,
SdrLayerIdItemType,
SdrLayerNameItemType,
+ SdrMeasureBelowRefEdgeItemType,
SdrMeasureFormatStringItemType,
SdrMeasureKindItemType,
SdrMeasureScaleItemType,
SdrMeasureTextAutoAngleItemType,
SdrMeasureTextAutoAngleViewItemType,
+ SdrMeasureTextFixedAngleItemType,
SdrMeasureTextHPosItemType,
+ SdrMeasureTextIsFixedAngleItemType,
+ SdrMeasureTextRota90ItemType,
+ SdrMeasureTextUpsideDownItemType,
SdrMeasureTextVPosItemType,
SdrMeasureUnitItemType,
+ SdrMetricItemType,
+ SdrObjPrintableItemType,
+ SdrObjVisibleItemType,
+ SdrOnOffItemType,
SdrResizeXAllItemType,
SdrResizeXOneItemType,
SdrResizeYAllItemType,
SdrResizeYOneItemType,
SdrScaleItemType,
SdrTextAniDirectionItemType,
+ SdrTextAniStartInsideItemType,
+ SdrTextAniStopInsideItemType,
SdrTextAniKindItemType,
SdrTextFitToSizeTypeItemType,
+ SdrTextFixedCellHeightItemType,
SdrTextHorzAdjustType,
SdrTextVertAdjustType,
SdrYesNoItemType,
@@ -215,6 +233,12 @@ enum class SfxItemType : sal_uInt16 {
SfxVoidItemType,
SfxWatermarkItemType,
SfxZoomItemType,
+ Svx3DCharacterModeItemType,
+ Svx3DCloseBackItemType,
+ Svx3DCloseFrontItemType,
+ Svx3DReducedLineGeometryItemType,
+ Svx3DSmoothLidsItemType,
+ Svx3DSmoothNormalsItemType,
SvXMLAttrContainerItemType,
SvxAdjustItemType,
SvxAutoKernItemType,
@@ -228,7 +252,7 @@ enum class SfxItemType : sal_uInt16 {
SvxCaseMapItemType,
SvxCharHiddenItemType,
SvxCharReliefItemType,
- SvxCharScaleWidthItem,
+ SvxCharScaleWidthItemType,
SvxChartColorTableItemType,
SvxChartIndicateItemType,
SvxChartKindErrorItemType,
@@ -255,9 +279,7 @@ enum class SfxItemType : sal_uInt16 {
SvxGalleryItemType,
SvxGradientListItemType,
SvxGraphicItemType,
- SvxGrfCrop,
SvxGrfCropType,
- SvxGridItem,
SvxGridItemType,
SvxGutterLeftMarginItemType,
SvxGutterRightMarginItemType,
@@ -265,7 +287,6 @@ enum class SfxItemType : sal_uInt16 {
SvxHatchListItemType,
SvxHorJustifyItemType,
SvxHyperlinkItemType,
- SvxHyphenZoneItem,
SvxHyphenZoneItemType,
SvxJustifyMethodItemType,
SvxKerningItemType,
@@ -283,6 +304,7 @@ enum class SfxItemType : sal_uInt16 {
SvxNumBulletItemType,
SvxNumberInfoItemType,
SvxObjectItemType,
+ SvxOpaqueItemType,
SvxOrientationItemType,
SvxOrphansItemType,
SvxPageItemType,
@@ -291,6 +313,7 @@ enum class SfxItemType : sal_uInt16 {
SvxParaVertAlignItemType,
SvxPatternListItemType,
SvxPostureItemType,
+ SvxPrintItemType,
SvxProtectItemType,
SvxRightMarginItemType,
SvxRotateModeItemType,
@@ -299,7 +322,6 @@ enum class SfxItemType : sal_uInt16 {
SvxSearchItemType,
SvxShadowItemType,
SvxShadowedItemType,
- SvxSizeItem ,
SvxSizeItemType,
SvxSmartTagItemType,
SvxTabStopItemType,
@@ -334,26 +356,34 @@ enum class SfxItemType : sal_uInt16 {
SwFormatContentControlType,
SwFormatContentType,
SwFormatDropType,
+ SwFormatEditInReadonly,
SwFormatFieldType,
SwFormatFillOrderType,
SwFormatFlyCntType,
+ SwFormatFlySplitType,
+ SwFormatFollowTextFlowType,
SwFormatFooterType,
SwFormatFootnoteEndAtTextEndType,
SwFormatFootnoteType,
SwFormatHeaderType,
SwFormatHoriOrientType,
SwFormatINetFormatType,
+ SwFormatLayoutSplitType,
SwFormatLineNumberType,
SwFormatLinebreakType,
SwFormatMetaType,
+ SwFormatNoBalancedColumnsType,
SwFormatPageDescType,
SwFormatRefMarkType,
+ SwFormatRowSplitType,
SwFormatRubyType,
SwFormatSurroundType,
SwFormatURLType,
SwFormatVertOrientType,
SwFormatWrapInfluenceOnOjPosType,
+ SwFormatWrapTextAtFlyStartType,
SwGammaGrfType,
+ SwHeaderAndFooterEatSpacingItemType,
SwInvertGrfType,
SwLabItemType,
SwMirrorGrfType,
@@ -388,7 +418,7 @@ enum class SfxItemType : sal_uInt16 {
XFormTextAdjustItemType,
XFormTextDistanceItemType,
XFormTextHideFormItemType,
- XFormTextMirrorItem,
+ XFormTextMirrorItemType,
XFormTextOutlineItemType,
XFormTextShadowItemType,
XFormTextShadowTranspItemType,
diff --git a/include/svx/sdmetitm.hxx b/include/svx/sdmetitm.hxx
index 934c24034d94..751cd769aedc 100644
--- a/include/svx/sdmetitm.hxx
+++ b/include/svx/sdmetitm.hxx
@@ -29,7 +29,8 @@
class SVXCORE_DLLPUBLIC SdrMetricItem: public SfxInt32Item {
public:
- SdrMetricItem(TypedWhichId<SdrMetricItem> nId, sal_Int32 nVal): SfxInt32Item(nId,nVal) {}
+ SdrMetricItem(TypedWhichId<SdrMetricItem> nId, sal_Int32 nVal, SfxItemType eItemType = SfxItemType::SdrMetricItemType)
+ : SfxInt32Item(nId,nVal,eItemType) {}
virtual SdrMetricItem* Clone(SfxItemPool* pPool=nullptr) const override;
virtual bool HasMetrics() const override;
virtual void ScaleMetrics(tools::Long nMul, tools::Long nDiv) override;
diff --git a/include/svx/sdooitm.hxx b/include/svx/sdooitm.hxx
index befd67f749e0..3feae53ed66e 100644
--- a/include/svx/sdooitm.hxx
+++ b/include/svx/sdooitm.hxx
@@ -29,7 +29,7 @@
class SVXCORE_DLLPUBLIC SdrOnOffItem: public SfxBoolItem {
public:
- SdrOnOffItem(TypedWhichId<SdrOnOffItem> nId, bool bOn): SfxBoolItem(nId,bOn) {}
+ SdrOnOffItem(TypedWhichId<SdrOnOffItem> nId, bool bOn): SfxBoolItem(nId,bOn, SfxItemType::SdrOnOffItemType) {}
virtual SdrOnOffItem* Clone(SfxItemPool* pPool=nullptr) const override;
virtual OUString GetValueTextByVal(bool bVal) const override;
diff --git a/include/svx/sdtaiitm.hxx b/include/svx/sdtaiitm.hxx
index d847208a6857..9a09d6a02344 100644
--- a/include/svx/sdtaiitm.hxx
+++ b/include/svx/sdtaiitm.hxx
@@ -24,7 +24,7 @@
class SVXCORE_DLLPUBLIC SdrTextAniStartInsideItem final : public SdrYesNoItem {
public:
- SdrTextAniStartInsideItem(bool bOn=false): SdrYesNoItem(SDRATTR_TEXT_ANISTARTINSIDE,bOn) {}
+ SdrTextAniStartInsideItem(bool bOn=false): SdrYesNoItem(SDRATTR_TEXT_ANISTARTINSIDE,bOn, SfxItemType::SdrTextAniStartInsideItemType) {}
virtual ~SdrTextAniStartInsideItem() override;
virtual SdrTextAniStartInsideItem* Clone(SfxItemPool* pPool=nullptr) const override;
@@ -36,7 +36,7 @@ public:
class SVXCORE_DLLPUBLIC SdrTextAniStopInsideItem final : public SdrYesNoItem {
public:
- SdrTextAniStopInsideItem(bool bOn=false): SdrYesNoItem(SDRATTR_TEXT_ANISTOPINSIDE,bOn) {}
+ SdrTextAniStopInsideItem(bool bOn=false): SdrYesNoItem(SDRATTR_TEXT_ANISTOPINSIDE,bOn, SfxItemType::SdrTextAniStopInsideItemType) {}
virtual ~SdrTextAniStopInsideItem() override;
virtual SdrTextAniStopInsideItem* Clone(SfxItemPool* pPool=nullptr) const override;
diff --git a/include/svx/sxcecitm.hxx b/include/svx/sxcecitm.hxx
index 9f20c10c1a7f..83f4053d7c28 100644
--- a/include/svx/sxcecitm.hxx
+++ b/include/svx/sxcecitm.hxx
@@ -49,7 +49,7 @@ public:
class SVXCORE_DLLPUBLIC SdrCaptionEscIsRelItem final : public SdrYesNoItem {
public:
- SdrCaptionEscIsRelItem(bool bRel=true): SdrYesNoItem(SDRATTR_CAPTIONESCISREL,bRel) {}
+ SdrCaptionEscIsRelItem(bool bRel=true): SdrYesNoItem(SDRATTR_CAPTIONESCISREL,bRel, SfxItemType::SdrCaptionEscIsRelItemType) {}
virtual ~SdrCaptionEscIsRelItem() override;
virtual SdrCaptionEscIsRelItem* Clone(SfxItemPool* pPool=nullptr) const override;
diff --git a/include/svx/sxcllitm.hxx b/include/svx/sxcllitm.hxx
index 8ac03f0eaf84..00ebe20ddfe4 100644
--- a/include/svx/sxcllitm.hxx
+++ b/include/svx/sxcllitm.hxx
@@ -30,7 +30,7 @@
*/
class SVXCORE_DLLPUBLIC SdrCaptionLineLenItem final : public SdrMetricItem {
public:
- SdrCaptionLineLenItem(tools::Long nLineLen=0): SdrMetricItem(SDRATTR_CAPTIONLINELEN,nLineLen) {}
+ SdrCaptionLineLenItem(tools::Long nLineLen=0): SdrMetricItem(SDRATTR_CAPTIONLINELEN,nLineLen, SfxItemType::SdrCaptionLineLenItemType) {}
virtual ~SdrCaptionLineLenItem() override;
virtual SdrCaptionLineLenItem* Clone(SfxItemPool* pPool=nullptr) const override;
@@ -46,7 +46,7 @@ public:
*/
class SVXCORE_DLLPUBLIC SdrCaptionFitLineLenItem final : public SdrYesNoItem {
public:
- SdrCaptionFitLineLenItem(bool bBestFit=true): SdrYesNoItem(SDRATTR_CAPTIONFITLINELEN,bBestFit) {}
+ SdrCaptionFitLineLenItem(bool bBestFit=true): SdrYesNoItem(SDRATTR_CAPTIONFITLINELEN,bBestFit, SfxItemType::SdrCaptionFitLineLenItemType) {}
virtual ~SdrCaptionFitLineLenItem() override;
virtual SdrCaptionFitLineLenItem* Clone(SfxItemPool* pPool=nullptr) const override;
diff --git a/include/svx/sxmbritm.hxx b/include/svx/sxmbritm.hxx
index 022656aaa142..5cdc6e69f3eb 100644
--- a/include/svx/sxmbritm.hxx
+++ b/include/svx/sxmbritm.hxx
@@ -31,7 +31,7 @@
// (SdrMeasureLineDistItem) over the reference edge
class SVXCORE_DLLPUBLIC SdrMeasureBelowRefEdgeItem final : public SdrYesNoItem {
public:
- SdrMeasureBelowRefEdgeItem(bool bOn=false): SdrYesNoItem(SDRATTR_MEASUREBELOWREFEDGE,bOn) {}
+ SdrMeasureBelowRefEdgeItem(bool bOn=false): SdrYesNoItem(SDRATTR_MEASUREBELOWREFEDGE,bOn, SfxItemType::SdrMeasureBelowRefEdgeItemType) {}
virtual ~SdrMeasureBelowRefEdgeItem() override;
virtual SdrMeasureBelowRefEdgeItem* Clone(SfxItemPool* pPool=nullptr) const override;
diff --git a/include/svx/sxmtfitm.hxx b/include/svx/sxmtfitm.hxx
index 11de732865a7..2284ac4db0a3 100644
--- a/include/svx/sxmtfitm.hxx
+++ b/include/svx/sxmtfitm.hxx
@@ -29,7 +29,7 @@
// Abrogate TextUpsideDown, TextRota90 and TextAutoAngle. (n.i.)
class SdrMeasureTextIsFixedAngleItem final : public SdrYesNoItem {
public:
- SdrMeasureTextIsFixedAngleItem(bool bOn=false): SdrYesNoItem(SDRATTR_MEASURETEXTISFIXEDANGLE,bOn) {}
+ SdrMeasureTextIsFixedAngleItem(bool bOn=false): SdrYesNoItem(SDRATTR_MEASURETEXTISFIXEDANGLE,bOn, SfxItemType::SdrMeasureTextIsFixedAngleItemType) {}
virtual ~SdrMeasureTextIsFixedAngleItem() override;
virtual SdrMeasureTextIsFixedAngleItem* Clone(SfxItemPool* pPool=nullptr) const override;
@@ -42,7 +42,8 @@ public:
//Angle of the text in 1/100deg. 0=horizontal; read from left to right. (n.i.)
class SdrMeasureTextFixedAngleItem final : public SdrAngleItem {
public:
- SdrMeasureTextFixedAngleItem(Degree100 nVal=0_deg100): SdrAngleItem(SDRATTR_MEASURETEXTFIXEDANGLE,nVal) {}
+ SdrMeasureTextFixedAngleItem(Degree100 nVal=0_deg100)
+ : SdrAngleItem(SDRATTR_MEASURETEXTFIXEDANGLE,nVal, SfxItemType::SdrMeasureTextFixedAngleItemType) {}
virtual ~SdrMeasureTextFixedAngleItem() override;
virtual SdrMeasureTextFixedAngleItem* Clone(SfxItemPool* pPool=nullptr) const override;
diff --git a/include/svx/sxmtritm.hxx b/include/svx/sxmtritm.hxx
index 184a59f39307..3f0c3579a625 100644
--- a/include/svx/sxmtritm.hxx
+++ b/include/svx/sxmtritm.hxx
@@ -25,7 +25,7 @@
// text across the dimension line (90deg counter-clockwise rotation)
class SVXCORE_DLLPUBLIC SdrMeasureTextRota90Item final : public SdrYesNoItem {
public:
- SdrMeasureTextRota90Item(bool bOn=false): SdrYesNoItem(SDRATTR_MEASURETEXTROTA90,bOn) {}
+ SdrMeasureTextRota90Item(bool bOn=false): SdrYesNoItem(SDRATTR_MEASURETEXTROTA90,bOn, SfxItemType::SdrMeasureTextRota90ItemType) {}
virtual ~SdrMeasureTextRota90Item() override;
virtual SdrMeasureTextRota90Item* Clone(SfxItemPool* pPool=nullptr) const override;
@@ -39,7 +39,7 @@ public:
// Text is also switched to the other side of the dimension line, if not Rota90
class SdrMeasureTextUpsideDownItem final : public SdrYesNoItem {
public:
- SdrMeasureTextUpsideDownItem(bool bOn=false): SdrYesNoItem(SDRATTR_MEASURETEXTUPSIDEDOWN,bOn) {}
+ SdrMeasureTextUpsideDownItem(bool bOn=false): SdrYesNoItem(SDRATTR_MEASURETEXTUPSIDEDOWN,bOn, SfxItemType::SdrMeasureTextUpsideDownItemType) {}
virtual ~SdrMeasureTextUpsideDownItem() override;
virtual SdrMeasureTextUpsideDownItem* Clone(SfxItemPool* pPool=nullptr) const override;
diff --git a/sc/source/core/data/attrib.cxx b/sc/source/core/data/attrib.cxx
index f118ca7d063e..91ea0de1e5a1 100644
--- a/sc/source/core/data/attrib.cxx
+++ b/sc/source/core/data/attrib.cxx
@@ -772,7 +772,7 @@ bool ScRotateValueItem::GetPresentation(SfxItemPresentation ePresentation,
}
ScShrinkToFitCell::ScShrinkToFitCell(bool bShrink)
- : SfxBoolItem(ATTR_SHRINKTOFIT, bShrink)
+ : SfxBoolItem(ATTR_SHRINKTOFIT, bShrink, SfxItemType::ScShrinkToFitCellType)
{
}
@@ -792,7 +792,7 @@ bool ScShrinkToFitCell::GetPresentation(SfxItemPresentation,
}
ScVerticalStackCell::ScVerticalStackCell(bool bStack)
- : SfxBoolItem(ATTR_STACKED, bStack)
+ : SfxBoolItem(ATTR_STACKED, bStack, SfxItemType::ScVerticalStackCellType)
{
}
@@ -812,7 +812,7 @@ bool ScVerticalStackCell::GetPresentation(SfxItemPresentation,
}
ScLineBreakCell::ScLineBreakCell(bool bStack)
- : SfxBoolItem(ATTR_LINEBREAK, bStack)
+ : SfxBoolItem(ATTR_LINEBREAK, bStack, SfxItemType::ScLineBreakCellType)
{
}
@@ -832,7 +832,7 @@ bool ScLineBreakCell::GetPresentation(SfxItemPresentation,
}
ScHyphenateCell::ScHyphenateCell(bool bHyphenate)
- : SfxBoolItem(ATTR_HYPHENATE, bHyphenate)
+ : SfxBoolItem(ATTR_HYPHENATE, bHyphenate, SfxItemType::ScHyphenateCellType)
{
}
diff --git a/svl/source/items/globalpool.cxx b/svl/source/items/globalpool.cxx
index 7ad6abc6a49f..313db586a566 100644
--- a/svl/source/items/globalpool.cxx
+++ b/svl/source/items/globalpool.cxx
@@ -283,6 +283,11 @@ SfxPoolItem const* implCreateItemEntry(SfxItemPool& rPool, SfxPoolItem const* pS
const SfxPoolItem* pAlternative = rItemManager.find(*pSource);
if (pAlternative)
{
+ SAL_WARN_IF(typeid(*pAlternative) != typeid(*pSource), "svl",
+ "wrong item from pool, expected " << typeid(*pSource).name()
+ << " but got "
+ << typeid(*pAlternative).name());
+ assert(typeid(*pAlternative) == typeid(*pSource) && "wrong item from pool");
// Here we do *not* need to check if it is an SfxSetItem
// and cannot be shared if they are in/use another pool:
// The SfxItemSet::operator== will check for SfxItemPools
@@ -324,10 +329,15 @@ SfxPoolItem const* implCreateItemEntry(SfxItemPool& rPool, SfxPoolItem const* pS
// bPassingOwnership is given just use the item, else clone it
if (!bPassingOwnership)
{
+ auto pPreviousSource = pSource;
pSource = pSource->Clone(pMasterPool);
#ifdef DBG_UTIL
assert(pSource->Which() == nWhich && "ITEM: Clone of Item did NOT copy/set WhichID (!)");
#endif
+ SAL_WARN_IF(typeid(*pPreviousSource) != typeid(*pSource), "svl",
+ "wrong item from Clone(), expected " << typeid(*pPreviousSource).name()
+ << " but got " << typeid(*pSource).name());
+ assert(typeid(*pPreviousSource) == typeid(*pSource) && "wrong item from Clone()");
}
// increase RefCnt 0->1
diff --git a/svx/inc/sxopitm.hxx b/svx/inc/sxopitm.hxx
index cd7d2bb1f599..52389b7331c1 100644
--- a/svx/inc/sxopitm.hxx
+++ b/svx/inc/sxopitm.hxx
@@ -24,7 +24,8 @@
class SdrObjPrintableItem final : public SdrYesNoItem {
public:
- SdrObjPrintableItem(bool bOn=false): SdrYesNoItem(SDRATTR_OBJPRINTABLE,bOn) {}
+ SdrObjPrintableItem(bool bOn=false)
+ : SdrYesNoItem(SDRATTR_OBJPRINTABLE,bOn, SfxItemType::SdrObjPrintableItemType) {}
virtual SdrObjPrintableItem* Clone(SfxItemPool*) const override
{
return new SdrObjPrintableItem(*this);
@@ -33,7 +34,7 @@ public:
class SdrObjVisibleItem final : public SdrYesNoItem {
public:
- SdrObjVisibleItem(bool bOn=true): SdrYesNoItem(SDRATTR_OBJVISIBLE,bOn) {}
+ SdrObjVisibleItem(bool bOn=true): SdrYesNoItem(SDRATTR_OBJVISIBLE,bOn, SfxItemType::SdrObjVisibleItemType) {}
virtual SdrObjVisibleItem* Clone(SfxItemPool*) const override
{
return new SdrObjVisibleItem(*this);
diff --git a/svx/source/engine3d/svx3ditems.cxx b/svx/source/engine3d/svx3ditems.cxx
index 1bfa4f559111..599d32a56cb9 100644
--- a/svx/source/engine3d/svx3ditems.cxx
+++ b/svx/source/engine3d/svx3ditems.cxx
@@ -31,7 +31,8 @@ using namespace ::com::sun::star;
// Added extra Item (Bool) for chart2 to be able to show reduced line geometry
Svx3DReducedLineGeometryItem::Svx3DReducedLineGeometryItem(bool bVal)
- : SfxBoolItem(SDRATTR_3DOBJ_REDUCED_LINE_GEOMETRY, bVal)
+ : SfxBoolItem(SDRATTR_3DOBJ_REDUCED_LINE_GEOMETRY, bVal,
+ SfxItemType::Svx3DReducedLineGeometryItemType)
{
}
@@ -76,7 +77,7 @@ Svx3DShadeModeItem::Svx3DShadeModeItem(sal_uInt16 nVal)
}
Svx3DSmoothNormalsItem::Svx3DSmoothNormalsItem(bool bVal)
- : SfxBoolItem(SDRATTR_3DOBJ_SMOOTH_NORMALS, bVal)
+ : SfxBoolItem(SDRATTR_3DOBJ_SMOOTH_NORMALS, bVal, SfxItemType::Svx3DSmoothNormalsItemType)
{
}
@@ -86,7 +87,7 @@ Svx3DSmoothNormalsItem* Svx3DSmoothNormalsItem::Clone(SfxItemPool*) const
}
Svx3DSmoothLidsItem::Svx3DSmoothLidsItem(bool bVal)
- : SfxBoolItem(SDRATTR_3DOBJ_SMOOTH_LIDS, bVal)
+ : SfxBoolItem(SDRATTR_3DOBJ_SMOOTH_LIDS, bVal, SfxItemType::Svx3DSmoothLidsItemType)
{
}
@@ -96,7 +97,7 @@ Svx3DSmoothLidsItem* Svx3DSmoothLidsItem::Clone(SfxItemPool*) const
}
Svx3DCharacterModeItem::Svx3DCharacterModeItem(bool bVal)
- : SfxBoolItem(SDRATTR_3DOBJ_CHARACTER_MODE, bVal)
+ : SfxBoolItem(SDRATTR_3DOBJ_CHARACTER_MODE, bVal, SfxItemType::Svx3DCharacterModeItemType)
{
}
@@ -106,7 +107,7 @@ Svx3DCharacterModeItem* Svx3DCharacterModeItem::Clone(SfxItemPool*) const
}
Svx3DCloseFrontItem::Svx3DCloseFrontItem(bool bVal)
- : SfxBoolItem(SDRATTR_3DOBJ_CLOSE_FRONT, bVal)
+ : SfxBoolItem(SDRATTR_3DOBJ_CLOSE_FRONT, bVal, SfxItemType::Svx3DCloseFrontItemType)
{
}
@@ -116,7 +117,7 @@ Svx3DCloseFrontItem* Svx3DCloseFrontItem::Clone(SfxItemPool*) const
}
Svx3DCloseBackItem::Svx3DCloseBackItem(bool bVal)
- : SfxBoolItem(SDRATTR_3DOBJ_CLOSE_BACK, bVal)
+ : SfxBoolItem(SDRATTR_3DOBJ_CLOSE_BACK, bVal, SfxItemType::Svx3DCloseBackItemType)
{
}
diff --git a/svx/source/svdraw/svdattr.cxx b/svx/source/svdraw/svdattr.cxx
index 1ae7e7eedcab..cb6c197dfcd4 100644
--- a/svx/source/svdraw/svdattr.cxx
+++ b/svx/source/svdraw/svdattr.cxx
@@ -1477,7 +1477,7 @@ bool SdrTextAniAmountItem::GetPresentation(
SdrTextFixedCellHeightItem::SdrTextFixedCellHeightItem( bool bUseFixedCellHeight )
- : SfxBoolItem( SDRATTR_TEXT_USEFIXEDCELLHEIGHT, bUseFixedCellHeight )
+ : SfxBoolItem( SDRATTR_TEXT_USEFIXEDCELLHEIGHT, bUseFixedCellHeight, SfxItemType::SdrTextFixedCellHeightItemType )
{
}
bool SdrTextFixedCellHeightItem::GetPresentation( SfxItemPresentation ePres,
diff --git a/svx/source/xoutdev/xattr.cxx b/svx/source/xoutdev/xattr.cxx
index a228b93e4da2..d8e0a41a6f9d 100644
--- a/svx/source/xoutdev/xattr.cxx
+++ b/svx/source/xoutdev/xattr.cxx
@@ -2987,7 +2987,7 @@ XFormTextStartItem* XFormTextStartItem::Clone(SfxItemPool* /*pPool*/) const
SfxPoolItem* XFormTextMirrorItem::CreateDefault() { return new XFormTextMirrorItem; }
XFormTextMirrorItem::XFormTextMirrorItem(bool bMirror) :
- SfxBoolItem(XATTR_FORMTXTMIRROR, bMirror, SfxItemType::XFormTextMirrorItem)
+ SfxBoolItem(XATTR_FORMTXTMIRROR, bMirror, SfxItemType::XFormTextMirrorItemType)
{
}
diff --git a/sw/inc/fmtclbl.hxx b/sw/inc/fmtclbl.hxx
index c521b45bd8bb..5ffc709896cf 100644
--- a/sw/inc/fmtclbl.hxx
+++ b/sw/inc/fmtclbl.hxx
@@ -29,7 +29,7 @@ class SW_DLLPUBLIC SwFormatNoBalancedColumns final : public SfxBoolItem
{
public:
SwFormatNoBalancedColumns( bool bFlag = false )
- : SfxBoolItem( RES_COLUMNBALANCE, bFlag ) {}
+ : SfxBoolItem( RES_COLUMNBALANCE, bFlag, SfxItemType::SwFormatNoBalancedColumnsType ) {}
/// "pure virtual methods" of SfxPoolItem
virtual SwFormatNoBalancedColumns* Clone( SfxItemPool *pPool = nullptr ) const override;
diff --git a/sw/inc/fmteiro.hxx b/sw/inc/fmteiro.hxx
index 7ec165654c27..a971d71cc2ca 100644
--- a/sw/inc/fmteiro.hxx
+++ b/sw/inc/fmteiro.hxx
@@ -35,7 +35,7 @@ class SW_DLLPUBLIC SwFormatEditInReadonly final : public SfxBoolItem
{
public:
SwFormatEditInReadonly( sal_uInt16 nId = RES_EDIT_IN_READONLY,
- bool bPrt = false ) : SfxBoolItem( nId, bPrt ) {}
+ bool bPrt = false ) : SfxBoolItem( nId, bPrt, SfxItemType::SwFormatEditInReadonly ) {}
/// "pure virtual method" of SfxPoolItem
virtual SwFormatEditInReadonly* Clone( SfxItemPool *pPool = nullptr ) const override;
diff --git a/sw/inc/fmtfollowtextflow.hxx b/sw/inc/fmtfollowtextflow.hxx
index 625f4658207b..b4e1fc599cab 100644
--- a/sw/inc/fmtfollowtextflow.hxx
+++ b/sw/inc/fmtfollowtextflow.hxx
@@ -34,7 +34,7 @@ class SW_DLLPUBLIC SwFormatFollowTextFlow final : public SfxBoolItem
public:
SwFormatFollowTextFlow( bool bFlag = false )
- : SfxBoolItem( RES_FOLLOW_TEXT_FLOW, bFlag )
+ : SfxBoolItem( RES_FOLLOW_TEXT_FLOW, bFlag, SfxItemType::SwFormatFollowTextFlowType )
{}
/// "pure virtual methods" of SfxPoolItem
diff --git a/sw/inc/fmtlsplt.hxx b/sw/inc/fmtlsplt.hxx
index 8038f597d9a9..822ec7af9b98 100644
--- a/sw/inc/fmtlsplt.hxx
+++ b/sw/inc/fmtlsplt.hxx
@@ -31,7 +31,7 @@ class IntlWrapper;
class SW_DLLPUBLIC SwFormatLayoutSplit final : public SfxBoolItem
{
public:
- SwFormatLayoutSplit( bool bSplit = true ) : SfxBoolItem( RES_LAYOUT_SPLIT, bSplit ) {}
+ SwFormatLayoutSplit( bool bSplit = true ) : SfxBoolItem( RES_LAYOUT_SPLIT, bSplit, SfxItemType::SwFormatLayoutSplitType ) {}
/// "pure virtual methods" of SfxPoolItem
virtual SwFormatLayoutSplit* Clone( SfxItemPool *pPool = nullptr ) const override;
diff --git a/sw/inc/fmtrowsplt.hxx b/sw/inc/fmtrowsplt.hxx
index faf168ba2b5e..a3a53e2012a2 100644
--- a/sw/inc/fmtrowsplt.hxx
+++ b/sw/inc/fmtrowsplt.hxx
@@ -31,7 +31,7 @@ class IntlWrapper;
class SW_DLLPUBLIC SwFormatRowSplit final : public SfxBoolItem
{
public:
- SwFormatRowSplit( bool bSplit = true ) : SfxBoolItem( RES_ROW_SPLIT, bSplit ) {}
+ SwFormatRowSplit( bool bSplit = true ) : SfxBoolItem( RES_ROW_SPLIT, bSplit, SfxItemType::SwFormatRowSplitType ) {}
// "pure virtual methods" of SfxPoolItem
virtual SwFormatRowSplit* Clone( SfxItemPool *pPool = nullptr ) const override;
diff --git a/sw/inc/hfspacingitem.hxx b/sw/inc/hfspacingitem.hxx
index a18ae742a3a0..1d1c85693290 100644
--- a/sw/inc/hfspacingitem.hxx
+++ b/sw/inc/hfspacingitem.hxx
@@ -29,7 +29,7 @@ class SW_DLLPUBLIC SwHeaderAndFooterEatSpacingItem final : public SfxBoolItem
{
public:
SwHeaderAndFooterEatSpacingItem( sal_uInt16 nId = RES_HEADER_FOOTER_EAT_SPACING,
- bool bPrt = false ) : SfxBoolItem( nId, bPrt ) {}
+ bool bPrt = false ) : SfxBoolItem( nId, bPrt, SfxItemType::SwHeaderAndFooterEatSpacingItemType ) {}
// "pure virtual methods" of SfxPoolItem
virtual SwHeaderAndFooterEatSpacingItem* Clone( SfxItemPool *pPool = nullptr ) const override;
diff --git a/sw/source/core/attr/formatflysplit.cxx b/sw/source/core/attr/formatflysplit.cxx
index 6bcfd74390e1..76f8eb8ed451 100644
--- a/sw/source/core/attr/formatflysplit.cxx
+++ b/sw/source/core/attr/formatflysplit.cxx
@@ -22,7 +22,7 @@
#include <libxml/xmlwriter.h>
SwFormatFlySplit::SwFormatFlySplit(bool bSplit)
- : SfxBoolItem(RES_FLY_SPLIT, bSplit)
+ : SfxBoolItem(RES_FLY_SPLIT, bSplit, SfxItemType::SwFormatFlySplitType)
{
// Once this pool item is true, a floating table (text frame + table inside it) is meant to
// split across multiple pages.
diff --git a/sw/source/core/attr/formatwraptextatflystart.cxx b/sw/source/core/attr/formatwraptextatflystart.cxx
index 88a17d5ade33..898a24c97f5c 100644
--- a/sw/source/core/attr/formatwraptextatflystart.cxx
+++ b/sw/source/core/attr/formatwraptextatflystart.cxx
@@ -22,7 +22,7 @@
#include <libxml/xmlwriter.h>
SwFormatWrapTextAtFlyStart::SwFormatWrapTextAtFlyStart(bool bAtStart)
- : SfxBoolItem(RES_WRAP_TEXT_AT_FLY_START, bAtStart)
+ : SfxBoolItem(RES_WRAP_TEXT_AT_FLY_START, bAtStart, SfxItemType::SwFormatWrapTextAtFlyStartType)
{
// Once this pool item is true, the text from the anchor text of the fly wraps an all pages, not
// only on the last page of the fly chain.