summaryrefslogtreecommitdiff
path: root/editeng
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2019-12-11 20:57:45 +0000
committerCaolán McNamara <caolanm@redhat.com>2019-12-12 21:12:10 +0100
commit2431477337f4ac4384ba615f76bfb5904f1a3b47 (patch)
tree6f676441983e9b3c8440600d09a49478353e1faf /editeng
parent23cfd3d1004f5ddda8cd79878c00b6c64f20068c (diff)
use covariant return type for SfxPoolItem::Clone
and can then remove some casting Change-Id: Id821c32ca2cbcdb7f57ef7a5fa1960042e630ffc Reviewed-on: https://gerrit.libreoffice.org/85022 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'editeng')
-rw-r--r--editeng/source/items/bulitem.cxx4
-rw-r--r--editeng/source/items/charhiddenitem.cxx2
-rw-r--r--editeng/source/items/flditem.cxx5
-rw-r--r--editeng/source/items/frmitems.cxx60
-rw-r--r--editeng/source/items/justifyitem.cxx6
-rw-r--r--editeng/source/items/numitem.cxx10
-rw-r--r--editeng/source/items/optitems.cxx5
-rw-r--r--editeng/source/items/paraitem.cxx42
-rw-r--r--editeng/source/items/textitem.cxx100
-rw-r--r--editeng/source/items/writingmodeitem.cxx2
10 files changed, 68 insertions, 168 deletions
diff --git a/editeng/source/items/bulitem.cxx b/editeng/source/items/bulitem.cxx
index 2b87196da1b6..2788572adcc8 100644
--- a/editeng/source/items/bulitem.cxx
+++ b/editeng/source/items/bulitem.cxx
@@ -59,13 +59,11 @@ SvxBulletItem::~SvxBulletItem()
{
}
-
-SfxPoolItem* SvxBulletItem::Clone( SfxItemPool * /*pPool*/ ) const
+SvxBulletItem* SvxBulletItem::Clone( SfxItemPool * /*pPool*/ ) const
{
return new SvxBulletItem( *this );
}
-
void SvxBulletItem::CopyValidProperties( const SvxBulletItem& rCopyFrom )
{
vcl::Font _aFont = GetFont();
diff --git a/editeng/source/items/charhiddenitem.cxx b/editeng/source/items/charhiddenitem.cxx
index ca298c717fef..8d0753c91e68 100644
--- a/editeng/source/items/charhiddenitem.cxx
+++ b/editeng/source/items/charhiddenitem.cxx
@@ -27,7 +27,7 @@ SvxCharHiddenItem::SvxCharHiddenItem( const bool bHidden, const sal_uInt16 nId )
{
}
-SfxPoolItem* SvxCharHiddenItem::Clone( SfxItemPool * ) const
+SvxCharHiddenItem* SvxCharHiddenItem::Clone( SfxItemPool * ) const
{
return new SvxCharHiddenItem( *this );
}
diff --git a/editeng/source/items/flditem.cxx b/editeng/source/items/flditem.cxx
index 873e82380914..3325eec528bb 100644
--- a/editeng/source/items/flditem.cxx
+++ b/editeng/source/items/flditem.cxx
@@ -293,18 +293,15 @@ SvxFieldItem::SvxFieldItem( const SvxFieldItem& rItem ) :
{
}
-
SvxFieldItem::~SvxFieldItem()
{
}
-
-SfxPoolItem* SvxFieldItem::Clone( SfxItemPool* ) const
+SvxFieldItem* SvxFieldItem::Clone( SfxItemPool* ) const
{
return new SvxFieldItem(*this);
}
-
bool SvxFieldItem::operator==( const SfxPoolItem& rItem ) const
{
assert(SfxPoolItem::operator==(rItem));
diff --git a/editeng/source/items/frmitems.cxx b/editeng/source/items/frmitems.cxx
index f74b53732ce2..3c93e0b2266a 100644
--- a/editeng/source/items/frmitems.cxx
+++ b/editeng/source/items/frmitems.cxx
@@ -111,13 +111,11 @@ SfxPoolItem* SvxFormatBreakItem::CreateDefault() { return new SvxFormatBreakIte
SfxPoolItem* SvxFormatKeepItem::CreateDefault() { return new SvxFormatKeepItem(false, 0);}
SfxPoolItem* SvxLineItem::CreateDefault() { return new SvxLineItem(0);}
-
-SfxPoolItem* SvxPaperBinItem::Clone( SfxItemPool* ) const
+SvxPaperBinItem* SvxPaperBinItem::Clone( SfxItemPool* ) const
{
return new SvxPaperBinItem( *this );
}
-
bool SvxPaperBinItem::GetPresentation
(
SfxItemPresentation ePres,
@@ -249,13 +247,11 @@ bool SvxSizeItem::operator==( const SfxPoolItem& rAttr ) const
return ( m_aSize == static_cast<const SvxSizeItem&>( rAttr ).GetSize() );
}
-
-SfxPoolItem* SvxSizeItem::Clone( SfxItemPool* ) const
+SvxSizeItem* SvxSizeItem::Clone( SfxItemPool* ) const
{
return new SvxSizeItem( *this );
}
-
bool SvxSizeItem::GetPresentation
(
SfxItemPresentation ePres,
@@ -503,13 +499,11 @@ bool SvxLRSpaceItem::operator==( const SfxPoolItem& rAttr ) const
bExplicitZeroMarginValLeft == rOther.IsExplicitZeroMarginValLeft() );
}
-
-SfxPoolItem* SvxLRSpaceItem::Clone( SfxItemPool* ) const
+SvxLRSpaceItem* SvxLRSpaceItem::Clone( SfxItemPool* ) const
{
return new SvxLRSpaceItem( *this );
}
-
bool SvxLRSpaceItem::GetPresentation
(
SfxItemPresentation ePres,
@@ -779,13 +773,11 @@ bool SvxULSpaceItem::operator==( const SfxPoolItem& rAttr ) const
nPropLower == rSpaceItem.nPropLower );
}
-
-SfxPoolItem* SvxULSpaceItem::Clone( SfxItemPool* ) const
+SvxULSpaceItem* SvxULSpaceItem::Clone( SfxItemPool* ) const
{
return new SvxULSpaceItem( *this );
}
-
bool SvxULSpaceItem::GetPresentation
(
SfxItemPresentation ePres,
@@ -896,13 +888,11 @@ boost::property_tree::ptree SvxULSpaceItem::dumpAsJSON() const
return aTree;
}
-
-SfxPoolItem* SvxPrintItem::Clone( SfxItemPool* ) const
+SvxPrintItem* SvxPrintItem::Clone( SfxItemPool* ) const
{
return new SvxPrintItem( *this );
}
-
bool SvxPrintItem::GetPresentation
(
SfxItemPresentation /*ePres*/,
@@ -919,13 +909,11 @@ bool SvxPrintItem::GetPresentation
return true;
}
-
-SfxPoolItem* SvxOpaqueItem::Clone( SfxItemPool* ) const
+SvxOpaqueItem* SvxOpaqueItem::Clone( SfxItemPool* ) const
{
return new SvxOpaqueItem( *this );
}
-
bool SvxOpaqueItem::GetPresentation
(
SfxItemPresentation /*ePres*/,
@@ -989,13 +977,11 @@ bool SvxProtectItem::PutValue( const uno::Any& rVal, sal_uInt8 nMemberId )
return true;
}
-
-SfxPoolItem* SvxProtectItem::Clone( SfxItemPool* ) const
+SvxProtectItem* SvxProtectItem::Clone( SfxItemPool* ) const
{
return new SvxProtectItem( *this );
}
-
bool SvxProtectItem::GetPresentation
(
SfxItemPresentation /*ePres*/,
@@ -1155,13 +1141,11 @@ bool SvxShadowItem::operator==( const SfxPoolItem& rAttr ) const
( eLocation == rItem.GetLocation() ) );
}
-
-SfxPoolItem* SvxShadowItem::Clone( SfxItemPool* ) const
+SvxShadowItem* SvxShadowItem::Clone( SfxItemPool* ) const
{
return new SvxShadowItem( *this );
}
-
sal_uInt16 SvxShadowItem::CalcShadowSpace( SvxShadowItemSide nShadow ) const
{
sal_uInt16 nSpace = 0;
@@ -1737,13 +1721,11 @@ bool SvxBoxItem::PutValue( const uno::Any& rVal, sal_uInt8 nMemberId )
return true;
}
-
-SfxPoolItem* SvxBoxItem::Clone( SfxItemPool* ) const
+SvxBoxItem* SvxBoxItem::Clone( SfxItemPool* ) const
{
return new SvxBoxItem( *this );
}
-
bool SvxBoxItem::GetPresentation
(
SfxItemPresentation ePres,
@@ -2143,13 +2125,11 @@ void SvxBoxInfoItem::SetLine( const SvxBorderLine* pNew, SvxBoxInfoItemLine nLin
}
}
-
-SfxPoolItem* SvxBoxInfoItem::Clone( SfxItemPool* ) const
+SvxBoxInfoItem* SvxBoxInfoItem::Clone( SfxItemPool* ) const
{
return new SvxBoxInfoItem( *this );
}
-
bool SvxBoxInfoItem::GetPresentation
(
SfxItemPresentation /*ePres*/,
@@ -2617,25 +2597,21 @@ bool SvxFormatBreakItem::PutValue( const uno::Any& rVal, sal_uInt8 /*nMemberId*/
return true;
}
-
-SfxPoolItem* SvxFormatBreakItem::Clone( SfxItemPool* ) const
+SvxFormatBreakItem* SvxFormatBreakItem::Clone( SfxItemPool* ) const
{
return new SvxFormatBreakItem( *this );
}
-
sal_uInt16 SvxFormatBreakItem::GetValueCount() const
{
return sal_uInt16(SvxBreak::End); // SvxBreak::PageBoth + 1
}
-
-SfxPoolItem* SvxFormatKeepItem::Clone( SfxItemPool* ) const
+SvxFormatKeepItem* SvxFormatKeepItem::Clone( SfxItemPool* ) const
{
return new SvxFormatKeepItem( *this );
}
-
bool SvxFormatKeepItem::GetPresentation
(
SfxItemPresentation /*ePres*/,
@@ -2678,13 +2654,11 @@ bool SvxLineItem::operator==( const SfxPoolItem& rAttr ) const
return CmpBrdLn( pLine, static_cast<const SvxLineItem&>(rAttr).GetLine() );
}
-
-SfxPoolItem* SvxLineItem::Clone( SfxItemPool* ) const
+SvxLineItem* SvxLineItem::Clone( SfxItemPool* ) const
{
return new SvxLineItem( *this );
}
-
bool SvxLineItem::QueryValue( uno::Any& rVal, sal_uInt8 nMemId ) const
{
bool bConvert = 0!=(nMemId&CONVERT_TWIPS);
@@ -3153,13 +3127,11 @@ bool SvxBrushItem::operator==( const SfxPoolItem& rAttr ) const
return bEqual;
}
-
-SfxPoolItem* SvxBrushItem::Clone( SfxItemPool* ) const
+SvxBrushItem* SvxBrushItem::Clone( SfxItemPool* ) const
{
return new SvxBrushItem( *this );
}
-
const GraphicObject* SvxBrushItem::GetGraphicObject(OUString const & referer) const
{
if (bLoadAgain && !maStrLink.isEmpty() && !xGraphicObject)
@@ -3351,13 +3323,11 @@ SvxFrameDirectionItem::~SvxFrameDirectionItem()
{
}
-
-SfxPoolItem* SvxFrameDirectionItem::Clone( SfxItemPool * ) const
+SvxFrameDirectionItem* SvxFrameDirectionItem::Clone( SfxItemPool * ) const
{
return new SvxFrameDirectionItem( *this );
}
-
const char* getFrmDirResId(size_t nIndex)
{
const char* const RID_SVXITEMS_FRMDIR[] =
diff --git a/editeng/source/items/justifyitem.cxx b/editeng/source/items/justifyitem.cxx
index 9b2c2be3b947..b8f2c7bdd102 100644
--- a/editeng/source/items/justifyitem.cxx
+++ b/editeng/source/items/justifyitem.cxx
@@ -165,7 +165,7 @@ OUString SvxHorJustifyItem::GetValueText(SvxCellHorJustify nVal)
return EditResId(RID_SVXITEMS_HORJUST[static_cast<size_t>(nVal)]);
}
-SfxPoolItem* SvxHorJustifyItem::Clone( SfxItemPool* ) const
+SvxHorJustifyItem* SvxHorJustifyItem::Clone( SfxItemPool* ) const
{
return new SvxHorJustifyItem( *this );
}
@@ -290,7 +290,7 @@ OUString SvxVerJustifyItem::GetValueText( SvxCellVerJustify nVal )
return EditResId(RID_SVXITEMS_VERJUST[static_cast<size_t>(nVal)]);
}
-SfxPoolItem* SvxVerJustifyItem::Clone( SfxItemPool* ) const
+SvxVerJustifyItem* SvxVerJustifyItem::Clone( SfxItemPool* ) const
{
return new SvxVerJustifyItem( *this );
}
@@ -359,7 +359,7 @@ OUString SvxJustifyMethodItem::GetValueText( SvxCellJustifyMethod nVal )
return EditResId(RID_SVXITEMS_JUSTMETHOD[static_cast<size_t>(nVal)]);
}
-SfxPoolItem* SvxJustifyMethodItem::Clone( SfxItemPool* ) const
+SvxJustifyMethodItem* SvxJustifyMethodItem::Clone( SfxItemPool* ) const
{
return new SvxJustifyMethodItem( *this );
}
diff --git a/editeng/source/items/numitem.cxx b/editeng/source/items/numitem.cxx
index 67cf0373cc37..599318fa6db9 100644
--- a/editeng/source/items/numitem.cxx
+++ b/editeng/source/items/numitem.cxx
@@ -410,14 +410,10 @@ bool SvxNumberFormat::operator==( const SvxNumberFormat& rFormat) const
void SvxNumberFormat::SetGraphicBrush( const SvxBrushItem* pBrushItem,
const Size* pSize, const sal_Int16* pOrient)
{
- if(!pBrushItem)
- {
+ if (!pBrushItem)
pGraphicBrush.reset();
- }
else if ( !pGraphicBrush || (*pBrushItem != *pGraphicBrush) )
- {
- pGraphicBrush.reset( static_cast<SvxBrushItem*>(pBrushItem->Clone()) );
- }
+ pGraphicBrush.reset(pBrushItem->Clone());
if(pOrient)
eVertOrient = *pOrient;
@@ -942,7 +938,7 @@ bool SvxNumBulletItem::operator==( const SfxPoolItem& rCopy) const
*pNumRule == *static_cast<const SvxNumBulletItem&>(rCopy).pNumRule;
}
-SfxPoolItem* SvxNumBulletItem::Clone( SfxItemPool * ) const
+SvxNumBulletItem* SvxNumBulletItem::Clone( SfxItemPool * ) const
{
return new SvxNumBulletItem(*this);
}
diff --git a/editeng/source/items/optitems.cxx b/editeng/source/items/optitems.cxx
index aeeb15314e01..254da79d91c1 100644
--- a/editeng/source/items/optitems.cxx
+++ b/editeng/source/items/optitems.cxx
@@ -31,7 +31,6 @@ SfxHyphenRegionItem::SfxHyphenRegionItem( const sal_uInt16 nId ) :
nMinLead = nMinTrail = 0;
}
-
bool SfxHyphenRegionItem::operator==( const SfxPoolItem& rAttr ) const
{
assert(SfxPoolItem::operator==(rAttr));
@@ -40,13 +39,11 @@ bool SfxHyphenRegionItem::operator==( const SfxPoolItem& rAttr ) const
( static_cast<const SfxHyphenRegionItem&>( rAttr ).nMinTrail == nMinTrail ) );
}
-
-SfxPoolItem* SfxHyphenRegionItem::Clone( SfxItemPool* ) const
+SfxHyphenRegionItem* SfxHyphenRegionItem::Clone( SfxItemPool* ) const
{
return new SfxHyphenRegionItem( *this );
}
-
bool SfxHyphenRegionItem::GetPresentation
(
SfxItemPresentation /*ePres*/,
diff --git a/editeng/source/items/paraitem.cxx b/editeng/source/items/paraitem.cxx
index da7b7cfcd297..c2ca935be7c5 100644
--- a/editeng/source/items/paraitem.cxx
+++ b/editeng/source/items/paraitem.cxx
@@ -222,8 +222,7 @@ bool SvxLineSpacingItem::PutValue( const uno::Any& rVal, sal_uInt8 nMemberId )
return bRet;
}
-
-SfxPoolItem* SvxLineSpacingItem::Clone( SfxItemPool * ) const
+SvxLineSpacingItem* SvxLineSpacingItem::Clone( SfxItemPool * ) const
{
return new SvxLineSpacingItem( *this );
}
@@ -408,13 +407,11 @@ bool SvxAdjustItem::PutValue( const uno::Any& rVal, sal_uInt8 nMemberId )
return true;
}
-
-SfxPoolItem* SvxAdjustItem::Clone( SfxItemPool * ) const
+SvxAdjustItem* SvxAdjustItem::Clone( SfxItemPool * ) const
{
return new SvxAdjustItem( *this );
}
-
bool SvxAdjustItem::GetPresentation
(
SfxItemPresentation ePres,
@@ -474,13 +471,11 @@ SvxWidowsItem::SvxWidowsItem(const sal_uInt8 nL, const sal_uInt16 nId ) :
{
}
-
-SfxPoolItem* SvxWidowsItem::Clone( SfxItemPool * ) const
+SvxWidowsItem* SvxWidowsItem::Clone( SfxItemPool * ) const
{
return new SvxWidowsItem( *this );
}
-
bool SvxWidowsItem::GetPresentation
(
SfxItemPresentation ePres,
@@ -520,13 +515,11 @@ SvxOrphansItem::SvxOrphansItem(const sal_uInt8 nL, const sal_uInt16 nId ) :
{
}
-
-SfxPoolItem* SvxOrphansItem::Clone( SfxItemPool * ) const
+SvxOrphansItem* SvxOrphansItem::Clone( SfxItemPool * ) const
{
return new SvxOrphansItem( *this );
}
-
bool SvxOrphansItem::GetPresentation
(
SfxItemPresentation ePres,
@@ -641,13 +634,11 @@ bool SvxHyphenZoneItem::operator==( const SfxPoolItem& rAttr ) const
&& rItem.nMaxHyphens == nMaxHyphens );
}
-
-SfxPoolItem* SvxHyphenZoneItem::Clone( SfxItemPool * ) const
+SvxHyphenZoneItem* SvxHyphenZoneItem::Clone( SfxItemPool * ) const
{
return new SvxHyphenZoneItem( *this );
}
-
bool SvxHyphenZoneItem::GetPresentation
(
SfxItemPresentation ePres,
@@ -936,13 +927,11 @@ bool SvxTabStopItem::operator==( const SfxPoolItem& rAttr ) const
return true;
}
-
-SfxPoolItem* SvxTabStopItem::Clone( SfxItemPool * ) const
+SvxTabStopItem* SvxTabStopItem::Clone( SfxItemPool * ) const
{
return new SvxTabStopItem( *this );
}
-
bool SvxTabStopItem::GetPresentation
(
SfxItemPresentation ePres,
@@ -1010,12 +999,11 @@ SvxFormatSplitItem::~SvxFormatSplitItem()
{
}
-SfxPoolItem* SvxFormatSplitItem::Clone( SfxItemPool * ) const
+SvxFormatSplitItem* SvxFormatSplitItem::Clone( SfxItemPool * ) const
{
return new SvxFormatSplitItem( *this );
}
-
bool SvxFormatSplitItem::GetPresentation
(
SfxItemPresentation /*ePres*/,
@@ -1032,13 +1020,11 @@ bool SvxFormatSplitItem::GetPresentation
return true;
}
-
-SfxPoolItem* SvxPageModelItem::Clone( SfxItemPool* ) const
+SvxPageModelItem* SvxPageModelItem::Clone( SfxItemPool* ) const
{
return new SvxPageModelItem( *this );
}
-
bool SvxPageModelItem::QueryValue( css::uno::Any& rVal, sal_uInt8 nMemberId ) const
{
nMemberId &= ~CONVERT_TWIPS;
@@ -1109,7 +1095,7 @@ SvxScriptSpaceItem::SvxScriptSpaceItem( bool bOn, const sal_uInt16 nId )
{
}
-SfxPoolItem* SvxScriptSpaceItem::Clone( SfxItemPool * ) const
+SvxScriptSpaceItem* SvxScriptSpaceItem::Clone( SfxItemPool * ) const
{
return new SvxScriptSpaceItem( *this );
}
@@ -1132,7 +1118,7 @@ SvxHangingPunctuationItem::SvxHangingPunctuationItem(
{
}
-SfxPoolItem* SvxHangingPunctuationItem::Clone( SfxItemPool * ) const
+SvxHangingPunctuationItem* SvxHangingPunctuationItem::Clone( SfxItemPool * ) const
{
return new SvxHangingPunctuationItem( *this );
}
@@ -1155,7 +1141,7 @@ SvxForbiddenRuleItem::SvxForbiddenRuleItem(
{
}
-SfxPoolItem* SvxForbiddenRuleItem::Clone( SfxItemPool * ) const
+SvxForbiddenRuleItem* SvxForbiddenRuleItem::Clone( SfxItemPool * ) const
{
return new SvxForbiddenRuleItem( *this );
}
@@ -1181,7 +1167,7 @@ SvxParaVertAlignItem::SvxParaVertAlignItem( Align nValue,
{
}
-SfxPoolItem* SvxParaVertAlignItem::Clone( SfxItemPool* ) const
+SvxParaVertAlignItem* SvxParaVertAlignItem::Clone( SfxItemPool* ) const
{
return new SvxParaVertAlignItem( *this );
}
@@ -1224,14 +1210,12 @@ bool SvxParaVertAlignItem::PutValue( const css::uno::Any& rVal,
return false;
}
-
-
SvxParaGridItem::SvxParaGridItem( bool bOn, const sal_uInt16 nId )
: SfxBoolItem( nId, bOn )
{
}
-SfxPoolItem* SvxParaGridItem::Clone( SfxItemPool * ) const
+SvxParaGridItem* SvxParaGridItem::Clone( SfxItemPool * ) const
{
return new SvxParaGridItem( *this );
}
diff --git a/editeng/source/items/textitem.cxx b/editeng/source/items/textitem.cxx
index bd39fa4cf3f7..cff724ead921 100644
--- a/editeng/source/items/textitem.cxx
+++ b/editeng/source/items/textitem.cxx
@@ -138,13 +138,11 @@ SvxFontListItem::SvxFontListItem( const FontList* pFontLst,
}
}
-
-SfxPoolItem* SvxFontListItem::Clone( SfxItemPool* ) const
+SvxFontListItem* SvxFontListItem::Clone( SfxItemPool* ) const
{
return new SvxFontListItem( *this );
}
-
bool SvxFontListItem::operator==( const SfxPoolItem& rAttr ) const
{
assert(SfxPoolItem::operator==(rAttr));
@@ -310,13 +308,11 @@ bool SvxFontItem::operator==( const SfxPoolItem& rAttr ) const
return bRet;
}
-
-SfxPoolItem* SvxFontItem::Clone( SfxItemPool * ) const
+SvxFontItem* SvxFontItem::Clone( SfxItemPool * ) const
{
return new SvxFontItem( *this );
}
-
bool SvxFontItem::GetPresentation
(
SfxItemPresentation /*ePres*/,
@@ -349,13 +345,11 @@ SvxPostureItem::SvxPostureItem( const FontItalic ePosture, const sal_uInt16 nId
{
}
-
-SfxPoolItem* SvxPostureItem::Clone( SfxItemPool * ) const
+SvxPostureItem* SvxPostureItem::Clone( SfxItemPool * ) const
{
return new SvxPostureItem( *this );
}
-
sal_uInt16 SvxPostureItem::GetValueCount() const
{
return ITALIC_NORMAL + 1; // ITALIC_NONE also belongs here
@@ -488,13 +482,11 @@ sal_uInt16 SvxWeightItem::GetValueCount() const
return WEIGHT_BLACK; // WEIGHT_DONTKNOW does not belong
}
-
-SfxPoolItem* SvxWeightItem::Clone( SfxItemPool * ) const
+SvxWeightItem* SvxWeightItem::Clone( SfxItemPool * ) const
{
return new SvxWeightItem( *this );
}
-
bool SvxWeightItem::GetPresentation
(
SfxItemPresentation /*ePres*/,
@@ -590,13 +582,11 @@ SvxFontHeightItem::SvxFontHeightItem( const sal_uLong nSz,
SetHeight( nSz,nPrp ); // calculate in percentage
}
-
-SfxPoolItem* SvxFontHeightItem::Clone( SfxItemPool * ) const
+SvxFontHeightItem* SvxFontHeightItem::Clone( SfxItemPool * ) const
{
return new SvxFontHeightItem( *this );
}
-
bool SvxFontHeightItem::operator==( const SfxPoolItem& rItem ) const
{
assert(SfxPoolItem::operator==(rItem));
@@ -942,13 +932,11 @@ void SvxTextLineItem::SetBoolValue( bool bVal )
SetValue( bVal ? LINESTYLE_SINGLE : LINESTYLE_NONE );
}
-
-SfxPoolItem* SvxTextLineItem::Clone( SfxItemPool * ) const
+SvxTextLineItem* SvxTextLineItem::Clone( SfxItemPool * ) const
{
return new SvxTextLineItem( *this );
}
-
sal_uInt16 SvxTextLineItem::GetValueCount() const
{
return LINESTYLE_DOTTED + 1; // LINESTYLE_NONE also belongs here
@@ -1052,13 +1040,11 @@ SvxUnderlineItem::SvxUnderlineItem( const FontLineStyle eSt, const sal_uInt16 nI
{
}
-
-SfxPoolItem* SvxUnderlineItem::Clone( SfxItemPool * ) const
+SvxUnderlineItem* SvxUnderlineItem::Clone( SfxItemPool * ) const
{
return new SvxUnderlineItem( *this );
}
-
OUString SvxUnderlineItem::GetValueTextByPos( sal_uInt16 nPos ) const
{
static const char* RID_SVXITEMS_UL[] =
@@ -1095,13 +1081,11 @@ SvxOverlineItem::SvxOverlineItem( const FontLineStyle eSt, const sal_uInt16 nId
{
}
-
-SfxPoolItem* SvxOverlineItem::Clone( SfxItemPool * ) const
+SvxOverlineItem* SvxOverlineItem::Clone( SfxItemPool * ) const
{
return new SvxOverlineItem( *this );
}
-
OUString SvxOverlineItem::GetValueTextByPos( sal_uInt16 nPos ) const
{
static const char* RID_SVXITEMS_OL[] =
@@ -1162,13 +1146,11 @@ sal_uInt16 SvxCrossedOutItem::GetValueCount() const
return STRIKEOUT_DOUBLE + 1; // STRIKEOUT_NONE belongs also here
}
-
-SfxPoolItem* SvxCrossedOutItem::Clone( SfxItemPool * ) const
+SvxCrossedOutItem* SvxCrossedOutItem::Clone( SfxItemPool * ) const
{
return new SvxCrossedOutItem( *this );
}
-
bool SvxCrossedOutItem::GetPresentation
(
SfxItemPresentation /*ePres*/,
@@ -1239,13 +1221,11 @@ SvxShadowedItem::SvxShadowedItem( const bool bShadowed, const sal_uInt16 nId ) :
{
}
-
-SfxPoolItem* SvxShadowedItem::Clone( SfxItemPool * ) const
+SvxShadowedItem* SvxShadowedItem::Clone( SfxItemPool * ) const
{
return new SvxShadowedItem( *this );
}
-
bool SvxShadowedItem::GetPresentation
(
SfxItemPresentation /*ePres*/,
@@ -1269,13 +1249,11 @@ SvxAutoKernItem::SvxAutoKernItem( const bool bAutoKern, const sal_uInt16 nId ) :
{
}
-
-SfxPoolItem* SvxAutoKernItem::Clone( SfxItemPool * ) const
+SvxAutoKernItem* SvxAutoKernItem::Clone( SfxItemPool * ) const
{
return new SvxAutoKernItem( *this );
}
-
bool SvxAutoKernItem::GetPresentation
(
SfxItemPresentation /*ePres*/,
@@ -1300,13 +1278,11 @@ SvxWordLineModeItem::SvxWordLineModeItem( const bool bWordLineMode,
{
}
-
-SfxPoolItem* SvxWordLineModeItem::Clone( SfxItemPool * ) const
+SvxWordLineModeItem* SvxWordLineModeItem::Clone( SfxItemPool * ) const
{
return new SvxWordLineModeItem( *this );
}
-
bool SvxWordLineModeItem::GetPresentation
(
SfxItemPresentation /*ePres*/,
@@ -1330,13 +1306,11 @@ SvxContourItem::SvxContourItem( const bool bContoured, const sal_uInt16 nId ) :
{
}
-
-SfxPoolItem* SvxContourItem::Clone( SfxItemPool * ) const
+SvxContourItem* SvxContourItem::Clone( SfxItemPool * ) const
{
return new SvxContourItem( *this );
}
-
bool SvxContourItem::GetPresentation
(
SfxItemPresentation /*ePres*/,
@@ -1367,7 +1341,7 @@ SvxBackgroundColorItem::SvxBackgroundColorItem( const Color& rCol,
{
}
-SfxPoolItem* SvxBackgroundColorItem::Clone( SfxItemPool * ) const
+SvxBackgroundColorItem* SvxBackgroundColorItem::Clone( SfxItemPool * ) const
{
return new SvxBackgroundColorItem(*this);
}
@@ -1485,7 +1459,7 @@ bool SvxColorItem::PutValue( const uno::Any& rVal, sal_uInt8 nMemberId )
}
}
-SfxPoolItem* SvxColorItem::Clone( SfxItemPool * ) const
+SvxColorItem* SvxColorItem::Clone( SfxItemPool * ) const
{
return new SvxColorItem( *this );
}
@@ -1532,13 +1506,11 @@ SvxKerningItem::SvxKerningItem( const short nKern, const sal_uInt16 nId ) :
{
}
-
-SfxPoolItem* SvxKerningItem::Clone( SfxItemPool * ) const
+SvxKerningItem* SvxKerningItem::Clone( SfxItemPool * ) const
{
return new SvxKerningItem( *this );
}
-
void SvxKerningItem::ScaleMetrics( long nMult, long nDiv )
{
SetValue( static_cast<sal_Int16>(Scale( GetValue(), nMult, nDiv )) );
@@ -1613,19 +1585,16 @@ SvxCaseMapItem::SvxCaseMapItem( const SvxCaseMap eMap, const sal_uInt16 nId ) :
{
}
-
sal_uInt16 SvxCaseMapItem::GetValueCount() const
{
return sal_uInt16(SvxCaseMap::End); // SvxCaseMap::SmallCaps + 1
}
-
-SfxPoolItem* SvxCaseMapItem::Clone( SfxItemPool * ) const
+SvxCaseMapItem* SvxCaseMapItem::Clone( SfxItemPool * ) const
{
return new SvxCaseMapItem( *this );
}
-
bool SvxCaseMapItem::GetPresentation
(
SfxItemPresentation /*ePres*/,
@@ -1729,13 +1698,11 @@ bool SvxEscapementItem::operator==( const SfxPoolItem& rAttr ) const
nProp == static_cast<const SvxEscapementItem&>(rAttr).nProp );
}
-
-SfxPoolItem* SvxEscapementItem::Clone( SfxItemPool * ) const
+SvxEscapementItem* SvxEscapementItem::Clone( SfxItemPool * ) const
{
return new SvxEscapementItem( *this );
}
-
sal_uInt16 SvxEscapementItem::GetValueCount() const
{
return sal_uInt16(SvxEscapement::End); // SvxEscapement::Subscript + 1
@@ -1870,13 +1837,11 @@ sal_uInt16 SvxLanguageItem::GetValueCount() const
return 0;
}
-
-SfxPoolItem* SvxLanguageItem::Clone( SfxItemPool * ) const
+SvxLanguageItem* SvxLanguageItem::Clone( SfxItemPool * ) const
{
return new SvxLanguageItem( *this );
}
-
bool SvxLanguageItem::GetPresentation
(
SfxItemPresentation /*ePres*/,
@@ -1939,13 +1904,11 @@ SvxNoHyphenItem::SvxNoHyphenItem( const sal_uInt16 nId ) :
{
}
-
-SfxPoolItem* SvxNoHyphenItem::Clone( SfxItemPool* ) const
+SvxNoHyphenItem* SvxNoHyphenItem::Clone( SfxItemPool* ) const
{
return new SvxNoHyphenItem( *this );
}
-
bool SvxNoHyphenItem::GetPresentation
(
SfxItemPresentation /*ePres*/,
@@ -1972,13 +1935,11 @@ SvxBlinkItem::SvxBlinkItem( const bool bBlink, const sal_uInt16 nId ) :
{
}
-
-SfxPoolItem* SvxBlinkItem::Clone( SfxItemPool * ) const
+SvxBlinkItem* SvxBlinkItem::Clone( SfxItemPool * ) const
{
return new SvxBlinkItem( *this );
}
-
bool SvxBlinkItem::GetPresentation
(
SfxItemPresentation /*ePres*/,
@@ -2003,13 +1964,11 @@ SvxEmphasisMarkItem::SvxEmphasisMarkItem( const FontEmphasisMark nValue,
{
}
-
-SfxPoolItem* SvxEmphasisMarkItem::Clone( SfxItemPool * ) const
+SvxEmphasisMarkItem* SvxEmphasisMarkItem::Clone( SfxItemPool * ) const
{
return new SvxEmphasisMarkItem( *this );
}
-
bool SvxEmphasisMarkItem::GetPresentation
(
SfxItemPresentation /*ePres*/,
@@ -2121,7 +2080,7 @@ bool SvxTwoLinesItem::operator==( const SfxPoolItem& rAttr ) const
cEndBracket == static_cast<const SvxTwoLinesItem&>(rAttr).cEndBracket;
}
-SfxPoolItem* SvxTwoLinesItem::Clone( SfxItemPool* ) const
+SvxTwoLinesItem* SvxTwoLinesItem::Clone( SfxItemPool* ) const
{
return new SvxTwoLinesItem( *this );
}
@@ -2216,7 +2175,7 @@ SvxTextRotateItem::SvxTextRotateItem(sal_uInt16 nValue, const sal_uInt16 nW)
{
}
-SfxPoolItem* SvxTextRotateItem::Clone(SfxItemPool*) const
+SvxTextRotateItem* SvxTextRotateItem::Clone(SfxItemPool*) const
{
return new SvxTextRotateItem(*this);
}
@@ -2295,7 +2254,7 @@ SvxCharRotateItem::SvxCharRotateItem( sal_uInt16 nValue,
{
}
-SfxPoolItem* SvxCharRotateItem::Clone( SfxItemPool* ) const
+SvxCharRotateItem* SvxCharRotateItem::Clone( SfxItemPool* ) const
{
return new SvxCharRotateItem( *this );
}
@@ -2384,12 +2343,11 @@ SvxCharScaleWidthItem::SvxCharScaleWidthItem( sal_uInt16 nValue,
{
}
-SfxPoolItem* SvxCharScaleWidthItem::Clone( SfxItemPool* ) const
+SvxCharScaleWidthItem* SvxCharScaleWidthItem::Clone( SfxItemPool* ) const
{
return new SvxCharScaleWidthItem( *this );
}
-
bool SvxCharScaleWidthItem::GetPresentation(
SfxItemPresentation /*ePres*/,
MapUnit /*eCoreMetric*/, MapUnit /*ePresMetric*/,
@@ -2439,7 +2397,7 @@ SvxCharReliefItem::SvxCharReliefItem( FontRelief eValue,
{
}
-SfxPoolItem* SvxCharReliefItem::Clone( SfxItemPool * ) const
+SvxCharReliefItem* SvxCharReliefItem::Clone( SfxItemPool * ) const
{
return new SvxCharReliefItem( *this );
}
@@ -2530,7 +2488,7 @@ SvxScriptSetItem::SvxScriptSetItem( sal_uInt16 nSlotId, SfxItemPool& rPool )
GetItemSet().MergeRange( nComplex, nComplex );
}
-SfxPoolItem* SvxScriptSetItem::Clone( SfxItemPool * ) const
+SvxScriptSetItem* SvxScriptSetItem::Clone( SfxItemPool * ) const
{
SvxScriptSetItem* p = new SvxScriptSetItem( Which(), *GetItemSet().GetPool() );
p->GetItemSet().Put( GetItemSet(), false );
@@ -2731,7 +2689,7 @@ bool SvxRsidItem::PutValue( const uno::Any& rVal, sal_uInt8 )
return true;
}
-SfxPoolItem* SvxRsidItem::Clone( SfxItemPool * ) const
+SvxRsidItem* SvxRsidItem::Clone( SfxItemPool * ) const
{
return new SvxRsidItem( *this );
}
diff --git a/editeng/source/items/writingmodeitem.cxx b/editeng/source/items/writingmodeitem.cxx
index 2fa4ce5ebbd4..d81aec28069f 100644
--- a/editeng/source/items/writingmodeitem.cxx
+++ b/editeng/source/items/writingmodeitem.cxx
@@ -38,7 +38,7 @@ SvxWritingModeItem::~SvxWritingModeItem()
{
}
-SfxPoolItem* SvxWritingModeItem::Clone( SfxItemPool * ) const
+SvxWritingModeItem* SvxWritingModeItem::Clone( SfxItemPool * ) const
{
return new SvxWritingModeItem( *this );
}