diff options
Diffstat (limited to 'sw/source/core/txtnode')
-rw-r--r-- | sw/source/core/txtnode/SwGrammarContact.cxx | 1 | ||||
-rw-r--r-- | sw/source/core/txtnode/atrfld.cxx | 14 | ||||
-rw-r--r-- | sw/source/core/txtnode/atrflyin.cxx | 4 | ||||
-rw-r--r-- | sw/source/core/txtnode/atrftn.cxx | 13 | ||||
-rw-r--r-- | sw/source/core/txtnode/atrref.cxx | 1 | ||||
-rw-r--r-- | sw/source/core/txtnode/atrtox.cxx | 4 | ||||
-rw-r--r-- | sw/source/core/txtnode/chrfmt.cxx | 3 | ||||
-rw-r--r-- | sw/source/core/txtnode/fmtatr2.cxx | 32 | ||||
-rw-r--r-- | sw/source/core/txtnode/fntcache.cxx | 30 | ||||
-rw-r--r-- | sw/source/core/txtnode/fntcap.cxx | 1 | ||||
-rw-r--r-- | sw/source/core/txtnode/modeltoviewhelper.cxx | 1 | ||||
-rw-r--r-- | sw/source/core/txtnode/ndhints.cxx | 4 | ||||
-rw-r--r-- | sw/source/core/txtnode/ndtxt.cxx | 14 | ||||
-rw-r--r-- | sw/source/core/txtnode/swfntcch.cxx | 1 | ||||
-rw-r--r-- | sw/source/core/txtnode/swfont.cxx | 1 | ||||
-rw-r--r-- | sw/source/core/txtnode/thints.cxx | 30 | ||||
-rw-r--r-- | sw/source/core/txtnode/txatritr.cxx | 4 | ||||
-rw-r--r-- | sw/source/core/txtnode/txtatr2.cxx | 6 | ||||
-rw-r--r-- | sw/source/core/txtnode/txtedt.cxx | 12 |
19 files changed, 20 insertions, 156 deletions
diff --git a/sw/source/core/txtnode/SwGrammarContact.cxx b/sw/source/core/txtnode/SwGrammarContact.cxx index 9138b02bfca1..058f74a53216 100644 --- a/sw/source/core/txtnode/SwGrammarContact.cxx +++ b/sw/source/core/txtnode/SwGrammarContact.cxx @@ -17,7 +17,6 @@ * the License at http://www.apache.org/licenses/LICENSE-2.0 . */ - #include <vcl/timer.hxx> #include <hints.hxx> #include <IGrammarContact.hxx> diff --git a/sw/source/core/txtnode/atrfld.cxx b/sw/source/core/txtnode/atrfld.cxx index eb5833e04a5f..6b1ea52bd253 100644 --- a/sw/source/core/txtnode/atrfld.cxx +++ b/sw/source/core/txtnode/atrfld.cxx @@ -17,7 +17,6 @@ * the License at http://www.apache.org/licenses/LICENSE-2.0 . */ - #include "fldbas.hxx" #include <fmtfld.hxx> #include <txtfld.hxx> @@ -152,7 +151,6 @@ void SwFmtFld::RegisterToFieldType( SwFieldType& rType ) rType.Add(this); } - // #111840# void SwFmtFld::SetField(SwField * _pField) { @@ -292,7 +290,6 @@ bool SwFmtFld::GetInfo( SfxPoolItem& rInfo ) const return false; } - bool SwFmtFld::IsFldInDoc() const { return mpTxtFld != NULL @@ -306,7 +303,6 @@ sal_Bool SwFmtFld::IsProtect() const && mpTxtFld->GetpTxtNode()->IsProtect(); } - SwTxtFld::SwTxtFld( SwFmtFld & rAttr, sal_Int32 const nStartPos, @@ -330,7 +326,6 @@ SwTxtFld::~SwTxtFld( ) } } - bool SwTxtFld::IsFldInDoc() const { return GetpTxtNode() != NULL @@ -369,7 +364,6 @@ void SwTxtFld::ExpandTxtFld() const const_cast<SwTxtFld*>(this)->NotifyContentChange( const_cast<SwFmtFld&>(GetFmtFld()) ); } - void SwTxtFld::CopyTxtFld( SwTxtFld *pDest ) const { OSL_ENSURE( m_pTxtNode, "SwTxtFld: where is my TxtNode?" ); @@ -443,7 +437,6 @@ void SwTxtFld::NotifyContentChange(SwFmtFld& rFmtFld) } } - // input field in-place editing SwTxtInputFld::SwTxtInputFld( SwFmtFld & rAttr, @@ -474,19 +467,16 @@ sal_Int32* SwTxtInputFld::GetEnd() return &m_nEnd; } - void SwTxtInputFld::LockNotifyContentChange() { m_bLockNotifyContentChange = true; } - void SwTxtInputFld::UnlockNotifyContentChange() { m_bLockNotifyContentChange = false; } - void SwTxtInputFld::NotifyContentChange( SwFmtFld& rFmtFld ) { if ( !m_bLockNotifyContentChange ) @@ -546,9 +536,6 @@ void SwTxtInputFld::UpdateTextNodeContent( const OUString& rNewContent ) GetTxtNode().ReplaceText( aIdx, nDelLen, rNewContent ); } - - - // text annotation field SwTxtAnnotationFld::SwTxtAnnotationFld( SwFmtFld & rAttr, @@ -562,7 +549,6 @@ SwTxtAnnotationFld::~SwTxtAnnotationFld() { } - ::sw::mark::IMark* SwTxtAnnotationFld::GetAnnotationMark( SwDoc* pDoc ) const { diff --git a/sw/source/core/txtnode/atrflyin.cxx b/sw/source/core/txtnode/atrflyin.cxx index 1ee3f8f7d304..add6e4f6cc32 100644 --- a/sw/source/core/txtnode/atrflyin.cxx +++ b/sw/source/core/txtnode/atrflyin.cxx @@ -17,7 +17,6 @@ * the License at http://www.apache.org/licenses/LICENSE-2.0 . */ - #include "hintids.hxx" #include "cntfrm.hxx" #include "doc.hxx" @@ -62,8 +61,6 @@ SwTxtFlyCnt::SwTxtFlyCnt( SwFmtFlyCnt& rAttr, sal_Int32 nStartPos ) SetHasDummyChar(true); } - - /************************************************************************* * SwTxtFlyCnt::MakeTxtHint() * @@ -270,5 +267,4 @@ SwFlyInCntFrm *SwTxtFlyCnt::_GetFlyFrm( const SwFrm *pCurrFrm ) return pFly; } - /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sw/source/core/txtnode/atrftn.cxx b/sw/source/core/txtnode/atrftn.cxx index a3408bd3dce7..65acb83b60dc 100644 --- a/sw/source/core/txtnode/atrftn.cxx +++ b/sw/source/core/txtnode/atrftn.cxx @@ -118,7 +118,6 @@ namespace { |* *************************************************************************/ - SwFmtFtn::SwFmtFtn( bool bEndNote ) : SfxPoolItem( RES_TXTATR_FTN ), m_pTxtAttr( 0 ), @@ -127,7 +126,6 @@ SwFmtFtn::SwFmtFtn( bool bEndNote ) { } - bool SwFmtFtn::operator==( const SfxPoolItem& rAttr ) const { OSL_ENSURE( SfxPoolItem::operator==( rAttr ), "keine gleichen Attribute" ); @@ -136,7 +134,6 @@ bool SwFmtFtn::operator==( const SfxPoolItem& rAttr ) const m_bEndNote == ((SwFmtFtn&)rAttr).m_bEndNote; } - SfxPoolItem* SwFmtFtn::Clone( SfxItemPool* ) const { SwFmtFtn* pNew = new SwFmtFtn; @@ -162,7 +159,6 @@ SwFmtFtn::~SwFmtFtn() { } - void SwFmtFtn::GetFtnText( OUString& rStr ) const { if( m_pTxtAttr->GetStartNode() ) @@ -248,14 +244,11 @@ SwTxtFtn::SwTxtFtn( SwFmtFtn& rAttr, sal_Int32 nStartPos ) SetHasDummyChar(true); } - SwTxtFtn::~SwTxtFtn() { SetStartNode( 0 ); } - - void SwTxtFtn::SetStartNode( const SwNodeIndex *pNewNode, sal_Bool bDelNode ) { if( pNewNode ) @@ -324,7 +317,6 @@ void SwTxtFtn::SetStartNode( const SwNodeIndex *pNewNode, sal_Bool bDelNode ) } } - void SwTxtFtn::SetNumber( const sal_uInt16 nNewNum, const OUString &sNumStr ) { SwFmtFtn& rFtn = (SwFmtFtn&)GetFtn(); @@ -397,7 +389,6 @@ void SwTxtFtn::CopyFtn( } } - // lege eine neue leere TextSection fuer diese Fussnote an void SwTxtFtn::MakeNewTextSection( SwNodes& rNodes ) { @@ -428,7 +419,6 @@ void SwTxtFtn::MakeNewTextSection( SwNodes& rNodes ) m_pStartNode = new SwNodeIndex( *pSttNd ); } - void SwTxtFtn::DelFrms( const SwFrm* pSib ) { // delete the FtnFrames from the pages @@ -534,7 +524,4 @@ void SwTxtFtn::CheckCondColl() //FEATURE::CONDCOLL } - - - /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sw/source/core/txtnode/atrref.cxx b/sw/source/core/txtnode/atrref.cxx index e019c338742a..94646a4cb278 100644 --- a/sw/source/core/txtnode/atrref.cxx +++ b/sw/source/core/txtnode/atrref.cxx @@ -22,7 +22,6 @@ #include <fmtrfmrk.hxx> #include <swfont.hxx> - /**************************************************************************** * * class SwFmtRefMark diff --git a/sw/source/core/txtnode/atrtox.cxx b/sw/source/core/txtnode/atrtox.cxx index 9cdaa14f2a3d..46379ba01bac 100644 --- a/sw/source/core/txtnode/atrtox.cxx +++ b/sw/source/core/txtnode/atrtox.cxx @@ -72,14 +72,14 @@ void SwTxtTOXMark::CopyTOXMark( SwDoc* pDoc ) } } // kein entsprechender Typ vorhanden -> neu erzeugen - // + if(!pType) { pDoc->InsertTOXType( SwTOXType( eType, rNm ) ); pType = pDoc->GetTOXType(eType, 0); } // Verzeichnistyp umhaengen - // + ((SwTOXType*)pType)->Add( &rTOX ); } diff --git a/sw/source/core/txtnode/chrfmt.cxx b/sw/source/core/txtnode/chrfmt.cxx index 328ce9a98833..86359ff7740e 100644 --- a/sw/source/core/txtnode/chrfmt.cxx +++ b/sw/source/core/txtnode/chrfmt.cxx @@ -19,9 +19,6 @@ #include <charfmt.hxx> - TYPEINIT1( SwCharFmt, SwFmt ); //rtti fuer SwCharFmt - - /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sw/source/core/txtnode/fmtatr2.cxx b/sw/source/core/txtnode/fmtatr2.cxx index 8b7567c8165d..8782fdd41dfd 100644 --- a/sw/source/core/txtnode/fmtatr2.cxx +++ b/sw/source/core/txtnode/fmtatr2.cxx @@ -17,7 +17,6 @@ * the License at http://www.apache.org/licenses/LICENSE-2.0 . */ - #include <hintids.hxx> #include <poolfmt.hxx> #include "unomid.h" @@ -51,7 +50,6 @@ #include <boost/bind.hpp> #include <algorithm> - using namespace ::com::sun::star; TYPEINIT1_AUTOFACTORY(SwFmtINetFmt, SfxPoolItem); @@ -70,8 +68,6 @@ SwFmtCharFmt::SwFmtCharFmt( SwCharFmt *pFmt ) { } - - SwFmtCharFmt::SwFmtCharFmt( const SwFmtCharFmt& rAttr ) : SfxPoolItem( RES_TXTATR_CHARFMT ), SwClient( rAttr.GetCharFmt() ), @@ -79,27 +75,19 @@ SwFmtCharFmt::SwFmtCharFmt( const SwFmtCharFmt& rAttr ) { } - - SwFmtCharFmt::~SwFmtCharFmt() {} - - bool SwFmtCharFmt::operator==( const SfxPoolItem& rAttr ) const { OSL_ENSURE( SfxPoolItem::operator==( rAttr ), "keine gleichen Attribute" ); return GetCharFmt() == ((SwFmtCharFmt&)rAttr).GetCharFmt(); } - - SfxPoolItem* SwFmtCharFmt::Clone( SfxItemPool* ) const { return new SwFmtCharFmt( *this ); } - - // weiterleiten an das TextAttribut void SwFmtCharFmt::Modify( const SfxPoolItem* pOld, const SfxPoolItem* pNew ) { @@ -107,8 +95,6 @@ void SwFmtCharFmt::Modify( const SfxPoolItem* pOld, const SfxPoolItem* pNew ) pTxtAttr->ModifyNotification( pOld, pNew ); } - - // weiterleiten an das TextAttribut bool SwFmtCharFmt::GetInfo( SfxPoolItem& rInfo ) const { @@ -228,8 +214,6 @@ SwFmtINetFmt::~SwFmtINetFmt() delete mpMacroTbl; } - - bool SwFmtINetFmt::operator==( const SfxPoolItem& rAttr ) const { OSL_ENSURE( SfxPoolItem::operator==( rAttr ), "keine gleichen Attribute" ); @@ -257,15 +241,11 @@ bool SwFmtINetFmt::operator==( const SfxPoolItem& rAttr ) const return rOwn == rOther; } - - SfxPoolItem* SwFmtINetFmt::Clone( SfxItemPool* ) const { return new SwFmtINetFmt( *this ); } - - void SwFmtINetFmt::SetMacroTbl( const SvxMacroTableDtor* pNewTbl ) { if( pNewTbl ) @@ -279,8 +259,6 @@ void SwFmtINetFmt::SetMacroTbl( const SvxMacroTableDtor* pNewTbl ) delete mpMacroTbl, mpMacroTbl = 0; } - - void SwFmtINetFmt::SetMacro( sal_uInt16 nEvent, const SvxMacro& rMacro ) { if( !mpMacroTbl ) @@ -289,8 +267,6 @@ void SwFmtINetFmt::SetMacro( sal_uInt16 nEvent, const SvxMacro& rMacro ) mpMacroTbl->Insert( nEvent, rMacro ); } - - const SvxMacro* SwFmtINetFmt::GetMacro( sal_uInt16 nEvent ) const { const SvxMacro* pRet = 0; @@ -299,8 +275,6 @@ const SvxMacro* SwFmtINetFmt::GetMacro( sal_uInt16 nEvent ) const return pRet; } - - bool SwFmtINetFmt::QueryValue( uno::Any& rVal, sal_uInt8 nMemberId ) const { nMemberId &= ~CONVERT_TWIPS; @@ -427,7 +401,6 @@ bool SwFmtINetFmt::PutValue( const uno::Any& rVal, sal_uInt8 nMemberId ) return bRet; } - /************************************************************************* |* class SwFmtRuby *************************************************************************/ @@ -558,7 +531,6 @@ bool SwFmtRuby::PutValue( const uno::Any& rVal, return bRet; } - /************************************************************************* class SwFmtMeta ************************************************************************/ @@ -673,7 +645,6 @@ void SwFmtMeta::DoCopy(::sw::MetaFieldManager & i_rTargetDocManager, } } - namespace sw { /************************************************************************* @@ -832,12 +803,10 @@ void MetaField::SetNumberFormat(sal_uInt32 nNumberFormat) m_nNumberFormat = nNumberFormat; } - /************************************************************************* class sw::MetaFieldManager ************************************************************************/ - MetaFieldManager::MetaFieldManager() { } @@ -891,5 +860,4 @@ MetaFieldManager::getMetaFields() } // namespace sw - /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sw/source/core/txtnode/fntcache.cxx b/sw/source/core/txtnode/fntcache.cxx index ccaf3c03181c..78362c372566 100644 --- a/sw/source/core/txtnode/fntcache.cxx +++ b/sw/source/core/txtnode/fntcache.cxx @@ -79,8 +79,6 @@ sal_uInt16 GetDefaultFontHeight( SwDrawTextInfo &rInf ) return (sal_uInt16)aDefaultFontItem.GetHeight(); } - - /************************************************************************* |* |* SwFntCache::Flush() @@ -415,7 +413,6 @@ sal_uInt16 SwFntObj::GetFontLeading( const SwViewShell *pSh, const OutputDevice& return nRet; } - /************************************************************************* * * SwFntObj::CreateScrFont( const SwViewShell& rSh, const OutputDevice& rOut ) @@ -517,7 +514,6 @@ void SwFntObj::CreateScrFont( const SwViewShell& rSh, const OutputDevice& rOut ) pOut->SetFont( aOldOutFont ); } - void SwFntObj::GuessLeading( const SwViewShell& #if defined(WNT) rSh @@ -751,7 +747,6 @@ static void lcl_DrawLineForWrongListData( Point aEnd; lcl_calcLinePos( rCalcLinePosData, aStart, aEnd, nNextStart, nNextEnd - nNextStart ); - sal_uInt16 wrongPos = pWList->GetWrongPos(nNextStart + rInf.GetIdx()); const SwWrongArea* wrongArea = pWList->GetElement(wrongPos); @@ -816,7 +811,6 @@ static void lcl_DrawLineForWrongListData( rInf.GetOut().Pop(); } - void SwFntObj::DrawText( SwDrawTextInfo &rInf ) { OSL_ENSURE( rInf.GetShell(), "SwFntObj::DrawText without shell" ); @@ -847,9 +841,8 @@ void SwFntObj::DrawText( SwDrawTextInfo &rInf ) Font* pTmpFont = bUseScrFont ? pScrFont : pPrtFont; - // // bDirectPrint and bUseScrFont should have these values: - // + // Outdev / RefDef | Printer | VirtPrinter | Window // Printer | 1 - 0 | 0 - 1 | - @@ -857,10 +850,9 @@ void SwFntObj::DrawText( SwDrawTextInfo &rInf ) // VirtPrinter/PDF | 0 - 1 | 0 - 1 | - // Window/VirtWindow| 0 - 1 | 0 - 1 | 1 - 0 - // + // Exception: During painting of a Writer OLE object, we do not have // a window. Therefore bUseSrcFont is always 0 in this case. - // #if OSL_DEBUG_LEVEL > 0 @@ -975,10 +967,7 @@ void SwFntObj::DrawText( SwDrawTextInfo &rInf ) if ( COMPLETE_STRING == rInf.GetLen() ) rInf.SetLen( rInf.GetText().getLength() ); - - // // ASIAN LINE AND CHARACTER GRID MODE START: snap to characters - // if ( rInf.GetFrm() && rInf.SnapToGrid() && rInf.GetFont() && SW_CJK == rInf.GetFont()->GetActual() ) @@ -1069,7 +1058,7 @@ void SwFntObj::DrawText( SwDrawTextInfo &rInf ) // For text grid refactor // ASIAN LINE AND CHARACTER GRID MODE START: not snap to characters - // + if ( rInf.GetFrm() && rInf.SnapToGrid() && rInf.GetFont() && SW_CJK == rInf.GetFont()->GetActual() ) { @@ -1211,9 +1200,7 @@ void SwFntObj::DrawText( SwDrawTextInfo &rInf ) } } - // // DIRECT PAINTING WITHOUT SCREEN ADJUSTMENT - // if ( bDirectPrint ) { @@ -1266,9 +1253,8 @@ void SwFntObj::DrawText( SwDrawTextInfo &rInf ) } } - // // Modify Array for special justifications - // + long nSpaceAdd = rInf.GetSpace() / SPACING_PRECISION_FACTOR; bool bSpecialJust = false; @@ -1435,9 +1421,7 @@ void SwFntObj::DrawText( SwDrawTextInfo &rInf ) rInf.GetIdx(), rInf.GetLen() ); } - // // PAINTING WITH FORMATTING DEVICE/SCREEN ADJUSTMENT - // else { @@ -1475,9 +1459,8 @@ void SwFntObj::DrawText( SwDrawTextInfo &rInf ) rInf.GetIdx(), rInf.GetLen() ); } - // // Modify Printer and ScreenArrays for special justifications - // + long nSpaceAdd = rInf.GetSpace() / SPACING_PRECISION_FACTOR; bool bNoHalfSpace = false; @@ -2057,7 +2040,6 @@ Size SwFntObj::GetTextSize( SwDrawTextInfo& rInf ) return aTxtSize; } - sal_Int32 SwFntObj::GetCrsrOfst( SwDrawTextInfo &rInf ) { long nSpaceAdd = rInf.GetSpace() / SPACING_PRECISION_FACTOR; @@ -2265,7 +2247,6 @@ sal_Int32 SwFntObj::GetCrsrOfst( SwDrawTextInfo &rInf ) return nCnt; } - /************************************************************************* |* |* SwFntAccess::SwFntAccess() @@ -2292,7 +2273,6 @@ SwFntAccess::SwFntAccess( const void* &rMagic, bCheck = sal_False; } - { OutputDevice* pOut = 0; sal_uInt16 nZoom = USHRT_MAX; diff --git a/sw/source/core/txtnode/fntcap.cxx b/sw/source/core/txtnode/fntcap.cxx index f9d9689c0182..3d1c6178e8a7 100644 --- a/sw/source/core/txtnode/fntcap.cxx +++ b/sw/source/core/txtnode/fntcap.cxx @@ -316,7 +316,6 @@ void SwDoDrawCapital::DrawSpace( Point &rPos ) const bool bSwitchL2R = rInf.GetFrm()->IsRightToLeft() && ! rInf.IsIgnoreFrmRTL(); - if ( bSwitchL2R ) rInf.GetFrm()->SwitchLTRtoRTL( aPos ); diff --git a/sw/source/core/txtnode/modeltoviewhelper.cxx b/sw/source/core/txtnode/modeltoviewhelper.cxx index 923e4fb3733f..85390d0e1654 100644 --- a/sw/source/core/txtnode/modeltoviewhelper.cxx +++ b/sw/source/core/txtnode/modeltoviewhelper.cxx @@ -187,7 +187,6 @@ sal_Int32 ModelToViewHelper::ConvertToViewPosition( sal_Int32 nModelPos ) const return nModelPos; } - /** Converts a view position into a model position */ ModelToViewHelper::ModelPosition ModelToViewHelper::ConvertToModelPosition( sal_Int32 nViewPos ) const diff --git a/sw/source/core/txtnode/ndhints.cxx b/sw/source/core/txtnode/ndhints.cxx index 4809b151472f..235dc8d4afa8 100644 --- a/sw/source/core/txtnode/ndhints.cxx +++ b/sw/source/core/txtnode/ndhints.cxx @@ -17,7 +17,6 @@ * the License at http://www.apache.org/licenses/LICENSE-2.0 . */ - #include "txatbase.hxx" #include "ndhints.hxx" #include <txtatr.hxx> @@ -28,7 +27,6 @@ #include <set> #endif - inline void DumpHints(const SwpHtStart &, const SwpHtEnd &) { } /************************************************************************* @@ -163,7 +161,6 @@ sal_uInt16 SwpHintsArray::GetPos( const SwTxtAttr *pHt ) const * SwpHintsArray::Check() *************************************************************************/ - #define CHECK_ERR(cond, text) \ if(!(cond)) \ { \ @@ -408,5 +405,4 @@ void SwpHintsArray::Resort() m_HintEnds.Resort(); } - /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sw/source/core/txtnode/ndtxt.cxx b/sw/source/core/txtnode/ndtxt.cxx index 383500a8f01c..92d70da86bc9 100644 --- a/sw/source/core/txtnode/ndtxt.cxx +++ b/sw/source/core/txtnode/ndtxt.cxx @@ -185,10 +185,8 @@ SwTxtNode *SwNodes::MakeTxtNode( const SwNodeIndex & rWhere, } while( true ); } - // SwTxtNode - SwTxtNode::SwTxtNode( const SwNodeIndex &rWhere, SwTxtFmtColl *pTxtColl, const SfxItemSet* pAutoAttr ) @@ -830,7 +828,6 @@ void SwTxtNode::NewAttrSet( SwAttrPool& rPool ) mpAttrSet = GetDoc()->GetIStyleAccess().getAutomaticStyle( aNewAttrSet, IStyleAccess::AUTO_STYLE_PARA ); } - // override SwIndexReg::Update => text hints do not need SwIndex for start/end! void SwTxtNode::Update( SwIndex const & rPos, @@ -1116,7 +1113,6 @@ void SwTxtNode::_ChgTxtCollUpdateNum( const SwTxtFmtColl *pOldColl, pDoc->GetNodes().UpdateOutlineNode(*this); } - SwNodes& rNds = GetNodes(); // Update beim Level 0 noch die Fussnoten !! if( ( !nNewLevel || !nOldLevel) && !pDoc->GetFtnIdxs().empty() && @@ -1313,7 +1309,6 @@ SwTxtFld* SwTxtNode::GetFldTxtAttrAt( return pTxtFld; } - /************************************************************************* * CopyHint() *************************************************************************/ @@ -1802,7 +1797,6 @@ void SwTxtNode::CopyText( SwTxtNode *const pDest, CHECK_SWPHINTS(this); } - OUString SwTxtNode::InsertText( const OUString & rStr, const SwIndex & rIdx, const IDocumentContentOperations::InsertFlags nMode ) { @@ -1948,7 +1942,6 @@ void SwTxtNode::CutText( SwTxtNode * const pDest, } } - void SwTxtNode::CutImpl( SwTxtNode * const pDest, const SwIndex & rDestStart, const SwIndex & rStart, sal_Int32 nLen, const bool bUpdate ) { @@ -2297,7 +2290,6 @@ void SwTxtNode::CutImpl( SwTxtNode * const pDest, const SwIndex & rDestStart, ModifyNotification( 0, &aDelHint ); } - void SwTxtNode::EraseText(const SwIndex &rIdx, const sal_Int32 nCount, const IDocumentContentOperations::InsertFlags nMode ) { @@ -2802,7 +2794,7 @@ OUString SwTxtNode::GetNumString( const bool _bInclPrefixAndSuffixStrings, SvxNumberType const& rNumberType( pRule->Get( static_cast<sal_uInt16>(nLevel) ) ); if (rNumberType.IsTxtFmt() || - // + (style::NumberingType::NUMBER_NONE == rNumberType.GetNumberingType())) { return pRule->MakeNumString( GetNum()->GetNumberVector(), @@ -2917,7 +2909,6 @@ bool SwTxtNode::GetFirstLineOfsWithNum( short& rFLOffset ) const return false; } -// SwTwips SwTxtNode::GetAdditionalIndentForStartingNewList() const { SwTwips nAdditionalIndent = 0; @@ -4330,7 +4321,7 @@ namespace { { mbAddTxtNodeToList = true; // #i105562# - // + mrTxtNode.ResetEmptyListStyleDueToResetOutlineLevelAttr(); } } @@ -4919,7 +4910,6 @@ sal_uInt16 SwTxtNode::ResetAllAttr() return nRet; } - sal_uInt32 SwTxtNode::GetRsid( sal_Int32 nStt, sal_Int32 nEnd ) const { SfxItemSet aSet( (SfxItemPool&) (GetDoc()->GetAttrPool()), RES_CHRATR_RSID, RES_CHRATR_RSID ); diff --git a/sw/source/core/txtnode/swfntcch.cxx b/sw/source/core/txtnode/swfntcch.cxx index 803891177e03..61e4b888103f 100644 --- a/sw/source/core/txtnode/swfntcch.cxx +++ b/sw/source/core/txtnode/swfntcch.cxx @@ -73,5 +73,4 @@ SwCacheObj *SwFontAccess::NewObj( ) return new SwFontObj( pOwner, pShell ); } - /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sw/source/core/txtnode/swfont.cxx b/sw/source/core/txtnode/swfont.cxx index df3da98565ee..d10a394327f6 100644 --- a/sw/source/core/txtnode/swfont.cxx +++ b/sw/source/core/txtnode/swfont.cxx @@ -1450,7 +1450,6 @@ void SwSubFont::CalcEsc( SwDrawTextInfo& rInf, Point& rPos ) nOfst = pLastFont->GetFontAscent( rInf.GetShell(), rInf.GetOut() ) - nOrgAscent; - switch ( nDir ) { case 0 : diff --git a/sw/source/core/txtnode/thints.cxx b/sw/source/core/txtnode/thints.cxx index 164daf8697f6..b6e23cec0301 100644 --- a/sw/source/core/txtnode/thints.cxx +++ b/sw/source/core/txtnode/thints.cxx @@ -81,7 +81,6 @@ using namespace ::com::sun::star::i18n; - SwpHints::SwpHints() : m_pHistory(0) , m_bFontChange(true) @@ -570,11 +569,10 @@ SwpHints::TryInsertNesting( SwTxtNode & rNode, SwTxtAttrNesting & rNewHint ) return true; } - // This function takes care for the following text attribute: // RES_TXTATR_CHARFMT, RES_TXTATR_AUTOFMT // These attributes have to be handled in a special way (Portion building). -// + // The new attribute will be split by any existing RES_TXTATR_AUTOFMT or // RES_TXTATR_CHARFMT. The new attribute itself will // split any existing RES_TXTATR_AUTOFMT or RES_TXTATR_CHARFMT. @@ -595,10 +593,9 @@ void SwpHints::BuildPortions( SwTxtNode& rNode, SwTxtAttr& rNewHint, RES_TXTATR_AUTOFMT == rNewHint.Which(), "Expecting CHARFMT or AUTOFMT" ); - // // 2. Find the hints which cover the start and end position // of the new hint. These hints have to be split into two portions: - // + if ( !bNoLengthAttribute ) // nothing to do for no length attributes { for ( sal_uInt16 i = 0; i < Count(); ++i ) @@ -658,9 +655,8 @@ void SwpHints::BuildPortions( SwTxtNode& rNode, SwTxtAttr& rNewHint, CHECK_NOTMERGED; // ignore flags not set properly yet, don't check them #endif - // // 4. Split rNewHint into 1 ... n new hints: - // + std::set<sal_Int32> aBounds; aBounds.insert( nThisStart ); aBounds.insert( nThisEnd ); @@ -689,9 +685,8 @@ void SwpHints::BuildPortions( SwTxtNode& rNode, SwTxtAttr& rNewHint, ++aStartIter; bool bDestroyHint = true; - // // Insert the 1...n new parts of the new attribute: - // + while ( aStartIter != aEndIter || bNoLengthAttribute ) { OSL_ENSURE( bNoLengthAttribute || nPorStart < *aStartIter, "AUTOSTYLES: BuildPortion trouble" ); @@ -1112,7 +1107,6 @@ SwTxtAttr* MakeTxtAttr( SwDoc & rDoc, const SfxItemSet& rSet, return pNew; } - // loesche das Text-Attribut (muss beim Pool abgemeldet werden!) void SwTxtNode::DestroyAttr( SwTxtAttr* pAttr ) { @@ -1650,7 +1644,6 @@ bool SwTxtNode::InsertHint( SwTxtAttr * const pAttr, const SetAttrMode nMode ) return bRet; } - /************************************************************************* * SwTxtNode::DeleteAttribute() *************************************************************************/ @@ -1854,7 +1847,6 @@ bool SwTxtNode::TryCharSetExpandToNum(const SfxItemSet& aCharSet) } } - return bRet; } @@ -2298,14 +2290,12 @@ bool SwTxtNode::GetAttr( SfxItemSet& rSet, sal_Int32 nStt, sal_Int32 nEnd, return rSet.Count() != 0; } - namespace { typedef std::pair<sal_uInt16, sal_uInt16> AttrSpan_t; typedef std::multimap<AttrSpan_t, const SwTxtAttr*> AttrSpanMap_t; - struct IsAutoStyle { bool @@ -2316,7 +2306,6 @@ struct IsAutoStyle } }; - /** Removes from io_rAttrSet all items that are set by style on the given span. */ @@ -2359,7 +2348,6 @@ private: SfxItemSet& m_rAttrSet; }; - /** Collects all style-covered spans from i_rHints to o_rSpanMap. In addition inserts dummy spans with pointer to format equal to 0 for all gaps (i.e. spans not covered by any style). This simplifies @@ -2401,7 +2389,6 @@ lcl_CollectHintSpans(const SwpHints& i_rHints, const sal_uInt16 nLength, } } - void lcl_FillWhichIds(const SfxItemSet& i_rAttrSet, std::vector<sal_uInt16>& o_rClearIds) { @@ -2429,7 +2416,6 @@ struct SfxItemSetClearer } - /** Does the hard work of SwTxtNode::FmtToTxtAttr: the real conversion of items to automatic styles. */ @@ -2516,9 +2502,9 @@ void SwTxtNode::FmtToTxtAttr( SwTxtNode* pNd ) { // There are five possible combinations of items from this and // pNd (pNd is the 'main' node): - // + // case pNd this action - // ---------------------------------------------------- + // 1 - - do nothing // 2 - a convert item to attr of this // 3 a - convert item to attr of pNd @@ -2662,7 +2648,6 @@ bool SwpHints::CalcHiddenParaField() return bOldHasHiddenParaField != bNewHasHiddenParaField; } - /************************************************************************* * SwpHints::NoteInHistory() *************************************************************************/ @@ -3219,7 +3204,6 @@ bool SwpHints::TryInsertHint( return true; } - // Ab hier gibt es nur noch pHint mit einem EndIdx !!! if( *pHtEnd < nHtStart ) @@ -3453,7 +3437,6 @@ sal_uInt16 SwTxtNode::GetLang( const sal_Int32 nBegin, const sal_Int32 nLen, return nRet; } - sal_Unicode GetCharOfTxtAttr( const SwTxtAttr& rAttr ) { sal_Unicode cRet = CH_TXTATR_BREAKWORD; @@ -3482,5 +3465,4 @@ sal_Unicode GetCharOfTxtAttr( const SwTxtAttr& rAttr ) return cRet; } - /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sw/source/core/txtnode/txatritr.cxx b/sw/source/core/txtnode/txatritr.cxx index a09bb94344c6..5fc1f4a8255d 100644 --- a/sw/source/core/txtnode/txatritr.cxx +++ b/sw/source/core/txtnode/txatritr.cxx @@ -28,7 +28,6 @@ using namespace ::com::sun::star; - SwScriptIterator::SwScriptIterator( const OUString& rStr, sal_Int32 nStt, bool const bFrwrd) : m_rText(rStr) @@ -94,8 +93,6 @@ bool SwScriptIterator::Next() return bRet; } - - SwTxtAttrIterator::SwTxtAttrIterator( const SwTxtNode& rTNd, sal_uInt16 nWhchId, sal_Int32 nStt, bool bUseGetWhichOfScript ) @@ -231,5 +228,4 @@ void SwTxtAttrIterator::SearchNextChg() } } - /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sw/source/core/txtnode/txtatr2.cxx b/sw/source/core/txtnode/txtatr2.cxx index c553b46d60a9..8b26eb26b793 100644 --- a/sw/source/core/txtnode/txtatr2.cxx +++ b/sw/source/core/txtnode/txtatr2.cxx @@ -17,7 +17,6 @@ * the License at http://www.apache.org/licenses/LICENSE-2.0 . */ - #include <hintids.hxx> #include <hints.hxx> #include <sfx2/objsh.hxx> @@ -34,11 +33,9 @@ #include <fmtruby.hxx> #include <fmtmeta.hxx> - TYPEINIT1(SwTxtINetFmt,SwClient); TYPEINIT1(SwTxtRuby,SwClient); - /************************************************************************* * class SwTxtCharFmt *************************************************************************/ @@ -83,7 +80,6 @@ bool SwTxtCharFmt::GetInfo( SfxPoolItem& rInfo ) const return false; } - /************************************************************************* * class SwTxtAttrNesting *************************************************************************/ @@ -104,7 +100,6 @@ SwTxtAttrNesting::~SwTxtAttrNesting() { } - /************************************************************************* * class SwTxtINetFmt *************************************************************************/ @@ -292,7 +287,6 @@ SwCharFmt* SwTxtRuby::GetCharFmt() return pRet; } - /************************************************************************* * class SwTxtMeta *************************************************************************/ diff --git a/sw/source/core/txtnode/txtedt.cxx b/sw/source/core/txtnode/txtedt.cxx index 9a2e518447ec..81676390aba2 100644 --- a/sw/source/core/txtnode/txtedt.cxx +++ b/sw/source/core/txtnode/txtedt.cxx @@ -717,7 +717,7 @@ SwScanner::SwScanner( const SwTxtNode& rNd, const OUString& rTxt, //MSWord f.e has special emdash and endash behaviour in that they break //words for the purposes of word counting, while a hyphen etc. doesn't. - // + //The default configuration treats emdash/endash as a word break, but //additional ones can be added in under tools->options if (nWordType == i18n::WordType::WORD_COUNT) @@ -947,7 +947,7 @@ sal_uInt16 SwTxtNode::Spell(SwSpellArgs* pArgs) pArgs->xSpellAlt = NULL; // 4 cases: - // + // 1. IsWrongDirty = 0 and GetWrong = 0 // Everything is checked and correct // 2. IsWrongDirty = 0 and GetWrong = 1 @@ -956,7 +956,7 @@ sal_uInt16 SwTxtNode::Spell(SwSpellArgs* pArgs) // Nothing has been checked // 4. IsWrongDirty = 1 and GetWrong = 1 // Text has been checked but there is an invalid range in the wrong list - // + // Nothing has to be done for case 1. if ( ( IsWrongDirty() || GetWrong() ) && m_Text.getLength() ) { @@ -968,7 +968,7 @@ sal_uInt16 SwTxtNode::Spell(SwSpellArgs* pArgs) { nEnd = m_Text.getLength(); } - // + if(!IsWrongDirty()) { const sal_Int32 nTemp = GetWrong()->NextWrong( nBegin ); @@ -1371,9 +1371,8 @@ SwRect SwTxtFrm::_AutoSpell( const SwCntntNode* pActNode, const SwViewOption& rV pNode->GetWrong()->Fresh( nChgStart, nChgEnd, nEnd, 0, nInsertPos, nActPos ); - // // Calculate repaint area: - // + if( nChgStart < nChgEnd ) { aRect = lcl_CalculateRepaintRect( *this, nChgStart, nChgEnd ); @@ -1469,7 +1468,6 @@ SwRect SwTxtFrm::SmartTagScan( SwCntntNode* /*pActNode*/, sal_Int32 /*nActPos*/ rSmartTagMgr.RecognizeTextRange(xRange, xTextMarkup, xController); - sal_Int32 nLangBegin = nBegin; sal_Int32 nLangEnd = nEnd; |