diff options
Diffstat (limited to 'editeng/source/items/textitem.cxx')
-rw-r--r-- | editeng/source/items/textitem.cxx | 94 |
1 files changed, 49 insertions, 45 deletions
diff --git a/editeng/source/items/textitem.cxx b/editeng/source/items/textitem.cxx index e242566bd36f..6d6439c4a060 100644 --- a/editeng/source/items/textitem.cxx +++ b/editeng/source/items/textitem.cxx @@ -112,7 +112,7 @@ SfxPoolItem* SvxCharReliefItem::CreateDefault() {return new SvxCharReliefItem(Fo SvxFontListItem::SvxFontListItem( const FontList* pFontLst, const sal_uInt16 nId ) : - SfxPoolItem( nId ), + SfxPoolItem( nId, SfxItemType::SvxFontListItemType ), pFontList( pFontLst ) { if ( pFontList ) @@ -159,30 +159,33 @@ bool SvxFontListItem::GetPresentation // class SvxFontItem ----------------------------------------------------- -SvxFontItem::SvxFontItem( const sal_uInt16 nId ) : - SfxPoolItem( nId ) +SvxFontItem::SvxFontItem( + const sal_uInt16 nId) +: SfxPoolItem( nId, SfxItemType::SvxFontItemType ) +, aFamilyName() +, aStyleName() +, eFamily(FAMILY_SWISS) +, ePitch(PITCH_VARIABLE) +, eTextEncoding(RTL_TEXTENCODING_DONTKNOW) { - eFamily = FAMILY_SWISS; - ePitch = PITCH_VARIABLE; - eTextEncoding = RTL_TEXTENCODING_DONTKNOW; } - -SvxFontItem::SvxFontItem( const FontFamily eFam, OUString aName, - OUString aStName, const FontPitch eFontPitch, - const rtl_TextEncoding eFontTextEncoding, const sal_uInt16 nId ) : - - SfxPoolItem( nId ), - - aFamilyName(std::move(aName)), - aStyleName(std::move(aStName)) +SvxFontItem::SvxFontItem( + const FontFamily eFam, + OUString aName, + OUString aStName, + const FontPitch eFontPitch, + const rtl_TextEncoding eFontTextEncoding, + const sal_uInt16 nId) +: SfxPoolItem( nId, SfxItemType::SvxFontItemType ) +, aFamilyName(std::move(aName)) +, aStyleName(std::move(aStName)) +, eFamily(eFam) +, ePitch(eFontPitch) +, eTextEncoding(eFontTextEncoding) { - eFamily = eFam; - ePitch = eFontPitch; - eTextEncoding = eFontTextEncoding; } - bool SvxFontItem::QueryValue( uno::Any& rVal, sal_uInt8 nMemberId ) const { nMemberId &= ~CONVERT_TWIPS; @@ -329,7 +332,7 @@ void SvxFontItem::dumpAsXml(xmlTextWriterPtr pWriter) const // class SvxPostureItem -------------------------------------------------- SvxPostureItem::SvxPostureItem( const FontItalic ePosture, const sal_uInt16 nId ) : - SfxEnumItem( nId, ePosture ) + SfxEnumItem( nId, SfxItemType::SvxPostureItemType, ePosture ) { } @@ -442,7 +445,7 @@ void SvxPostureItem::dumpAsXml(xmlTextWriterPtr pWriter) const // class SvxWeightItem --------------------------------------------------- SvxWeightItem::SvxWeightItem( const FontWeight eWght, const sal_uInt16 nId ) : - SfxEnumItem( nId, eWght ) + SfxEnumItem( nId, SfxItemType::SvxWeightItemType, eWght ) { } @@ -565,7 +568,7 @@ void SvxWeightItem::dumpAsXml(xmlTextWriterPtr pWriter) const SvxFontHeightItem::SvxFontHeightItem( const sal_uInt32 nSz, const sal_uInt16 nPrp, const sal_uInt16 nId ) : - SfxPoolItem( nId ) + SfxPoolItem( nId, SfxItemType::SvxFontHeightItemType ) { SetHeight( nSz,nPrp ); // calculate in percentage } @@ -899,7 +902,7 @@ void SvxFontHeightItem::dumpAsXml(xmlTextWriterPtr pWriter) const // class SvxTextLineItem ------------------------------------------------ SvxTextLineItem::SvxTextLineItem( const FontLineStyle eSt, const sal_uInt16 nId ) - : SfxEnumItem(nId, eSt) + : SfxEnumItem(nId, SfxItemType::SvxTextLineItemType,eSt) , maColor(COL_TRANSPARENT) { } @@ -1124,7 +1127,7 @@ OUString SvxOverlineItem::GetValueTextByPos( sal_uInt16 nPos ) const // class SvxCrossedOutItem ----------------------------------------------- SvxCrossedOutItem::SvxCrossedOutItem( const FontStrikeout eSt, const sal_uInt16 nId ) - : SfxEnumItem( nId, eSt ) + : SfxEnumItem( nId, SfxItemType::SvxCrossedOutItemType, eSt ) { } @@ -1223,7 +1226,7 @@ bool SvxCrossedOutItem::PutValue( const uno::Any& rVal, sal_uInt8 nMemberId ) // class SvxShadowedItem ------------------------------------------------- SvxShadowedItem::SvxShadowedItem( const bool bShadowed, const sal_uInt16 nId ) : - SfxBoolItem( nId, bShadowed ) + SfxBoolItem( nId, bShadowed, SfxItemType::SvxShadowedItemType ) { } @@ -1251,7 +1254,7 @@ bool SvxShadowedItem::GetPresentation // class SvxAutoKernItem ------------------------------------------------- SvxAutoKernItem::SvxAutoKernItem( const bool bAutoKern, const sal_uInt16 nId ) : - SfxBoolItem( nId, bAutoKern ) + SfxBoolItem( nId, bAutoKern, SfxItemType::SvxAutoKernItemType ) { } @@ -1280,7 +1283,7 @@ bool SvxAutoKernItem::GetPresentation SvxWordLineModeItem::SvxWordLineModeItem( const bool bWordLineMode, const sal_uInt16 nId ) : - SfxBoolItem( nId, bWordLineMode ) + SfxBoolItem( nId, bWordLineMode, SfxItemType::SvxWordLineItemType ) { } @@ -1308,7 +1311,7 @@ bool SvxWordLineModeItem::GetPresentation // class SvxContourItem -------------------------------------------------- SvxContourItem::SvxContourItem( const bool bContoured, const sal_uInt16 nId ) : - SfxBoolItem( nId, bContoured ) + SfxBoolItem( nId, bContoured, SfxItemType::SvxContourItemType ) { } @@ -1335,19 +1338,19 @@ bool SvxContourItem::GetPresentation // class SvxColorItem ---------------------------------------------------- SvxColorItem::SvxColorItem( const sal_uInt16 nId ) : - SfxPoolItem(nId), + SfxPoolItem(nId, SfxItemType::SvxColorItemType), mColor( COL_BLACK ) { } SvxColorItem::SvxColorItem( const Color& rCol, const sal_uInt16 nId ) : - SfxPoolItem( nId ), + SfxPoolItem( nId, SfxItemType::SvxColorItemType ), mColor( rCol ) { } SvxColorItem::SvxColorItem(Color const& rColor, model::ComplexColor const& rComplexColor, const sal_uInt16 nId) - : SfxPoolItem(nId) + : SfxPoolItem(nId, SfxItemType::SvxColorItemType) , mColor(rColor) , maComplexColor(rComplexColor) { @@ -1597,7 +1600,7 @@ void SvxColorItem::dumpAsXml(xmlTextWriterPtr pWriter) const // class SvxKerningItem -------------------------------------------------- SvxKerningItem::SvxKerningItem( const short nKern, const sal_uInt16 nId ) : - SfxInt16Item( nId, nKern ) + SfxInt16Item( nId, nKern, SfxItemType::SvxKerningItemType ) { } @@ -1676,7 +1679,7 @@ bool SvxKerningItem::PutValue( const uno::Any& rVal, sal_uInt8 nMemberId) // class SvxCaseMapItem -------------------------------------------------- SvxCaseMapItem::SvxCaseMapItem( const SvxCaseMap eMap, const sal_uInt16 nId ) : - SfxEnumItem( nId, eMap ) + SfxEnumItem( nId, SfxItemType::SvxCaseMapItemType, eMap ) { } @@ -1756,7 +1759,7 @@ bool SvxCaseMapItem::PutValue( const uno::Any& rVal, sal_uInt8 /*nMemberId*/ ) // class SvxEscapementItem ----------------------------------------------- SvxEscapementItem::SvxEscapementItem( const sal_uInt16 nId ) : - SfxEnumItemInterface( nId ), + SfxEnumItemInterface( nId, SfxItemType::SvxEscapementItemType ), nEsc ( 0 ), nProp ( 100 ) @@ -1766,7 +1769,7 @@ SvxEscapementItem::SvxEscapementItem( const sal_uInt16 nId ) : SvxEscapementItem::SvxEscapementItem( const SvxEscapement eEscape, const sal_uInt16 nId ) : - SfxEnumItemInterface( nId ), + SfxEnumItemInterface( nId, SfxItemType::SvxEscapementItemType ), nProp( 100 ) { SetEscapement( eEscape ); @@ -1778,7 +1781,7 @@ SvxEscapementItem::SvxEscapementItem( const SvxEscapement eEscape, SvxEscapementItem::SvxEscapementItem( const short _nEsc, const sal_uInt8 _nProp, const sal_uInt16 nId ) : - SfxEnumItemInterface( nId ), + SfxEnumItemInterface( nId, SfxItemType::SvxEscapementItemType ), nEsc ( _nEsc ), nProp ( _nProp ) { @@ -1918,7 +1921,7 @@ bool SvxEscapementItem::PutValue( const uno::Any& rVal, sal_uInt8 nMemberId ) // class SvxLanguageItem ------------------------------------------------- SvxLanguageItem::SvxLanguageItem( const LanguageType eLang, const sal_uInt16 nId ) - : SvxLanguageItem_Base( nId , eLang ) + : SvxLanguageItem_Base( nId , SfxItemType::SvxLanguageItemType, eLang ) { } @@ -1995,7 +1998,7 @@ bool SvxLanguageItem::PutValue( const uno::Any& rVal, sal_uInt8 nMemberId ) // class SvxNoHyphenItem ------------------------------------------------- SvxNoHyphenItem::SvxNoHyphenItem( const sal_uInt16 nId ) : - SfxBoolItem( nId , true ) + SfxBoolItem( nId , true, SfxItemType::SvxNoHyphenItemType ) { } @@ -2026,7 +2029,7 @@ bool SvxNoHyphenItem::GetPresentation SvxBlinkItem::SvxBlinkItem( const bool bBlink, const sal_uInt16 nId ) : - SfxBoolItem( nId, bBlink ) + SfxBoolItem( nId, bBlink, SfxItemType::SvxBlinkItemType ) { } @@ -2055,7 +2058,7 @@ bool SvxBlinkItem::GetPresentation SvxEmphasisMarkItem::SvxEmphasisMarkItem( const FontEmphasisMark nValue, TypedWhichId<SvxEmphasisMarkItem> nId ) - : SfxUInt16Item( nId, static_cast<sal_uInt16>(nValue) ) + : SfxUInt16Item( nId, static_cast<sal_uInt16>(nValue), SfxItemType::SvxEmphasisMarkItemType ) { } @@ -2158,7 +2161,7 @@ bool SvxEmphasisMarkItem::PutValue( const uno::Any& rVal, sal_uInt8 nMemberId ) SvxTwoLinesItem::SvxTwoLinesItem( bool bFlag, sal_Unicode nStartBracket, sal_Unicode nEndBracket, sal_uInt16 nW ) - : SfxPoolItem( nW ), + : SfxPoolItem( nW, SfxItemType::SvxTwoLinesItemType ), cStartBracket( nStartBracket ), cEndBracket( nEndBracket ), bOn( bFlag ) { } @@ -2266,7 +2269,7 @@ bool SvxTwoLinesItem::GetPresentation( SfxItemPresentation /*ePres*/, *************************************************************************/ SvxTextRotateItem::SvxTextRotateItem(Degree10 nValue, TypedWhichId<SvxTextRotateItem> nW) - : SfxUInt16Item(nW, nValue.get()) + : SfxUInt16Item(nW, nValue.get(), SfxItemType::SvxTextRotateItemType) { } @@ -2434,7 +2437,7 @@ void SvxCharRotateItem::dumpAsXml(xmlTextWriterPtr pWriter) const SvxCharScaleWidthItem::SvxCharScaleWidthItem( sal_uInt16 nValue, TypedWhichId<SvxCharScaleWidthItem> nW ) - : SfxUInt16Item( nW, nValue ) + : SfxUInt16Item( nW, nValue, SfxItemType::SvxCharScaleWidthItem ) { } @@ -2488,7 +2491,7 @@ bool SvxCharScaleWidthItem::QueryValue( uno::Any& rVal, sal_uInt8 /*nMemberId*/ SvxCharReliefItem::SvxCharReliefItem( FontRelief eValue, const sal_uInt16 nId ) - : SfxEnumItem( nId, eValue ) + : SfxEnumItem( nId, SfxItemType::SvxCharReliefItemType, eValue ) { } @@ -2574,7 +2577,8 @@ bool SvxCharReliefItem::QueryValue( css::uno::Any& rVal, SvxScriptSetItem::SvxScriptSetItem( sal_uInt16 nSlotId, SfxItemPool& rPool ) : SfxSetItem( nSlotId, SfxItemSet( rPool, - svl::Items<SID_ATTR_CHAR_FONT, SID_ATTR_CHAR_FONT> )) + svl::Items<SID_ATTR_CHAR_FONT, SID_ATTR_CHAR_FONT> ), + SfxItemType::SvxScriptSetItemType ) { sal_uInt16 nLatin, nAsian, nComplex; GetWhichIds( nLatin, nAsian, nComplex ); |