diff options
author | Miklos Vajna <vmiklos@collabora.co.uk> | 2016-12-06 12:13:26 +0100 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.co.uk> | 2016-12-06 12:44:44 +0100 |
commit | 57236961bbc280c401b1788532a1934bd66c54d9 (patch) | |
tree | f0d66cc50c756d2a701e23163106e9308c2dd40b | |
parent | 0ed936cc7400339f6c884f1ba435b4c90947e5ee (diff) |
sw: outline longer SwLineLayout member functions
Change-Id: I8ad38c64eea399e3b682a82f7b1a10ca8c669021
-rw-r--r-- | sw/source/core/text/porlay.cxx | 21 | ||||
-rw-r--r-- | sw/source/core/text/porlay.hxx | 28 |
2 files changed, 24 insertions, 25 deletions
diff --git a/sw/source/core/text/porlay.cxx b/sw/source/core/text/porlay.cxx index ecd1fd73df9f..338506eca272 100644 --- a/sw/source/core/text/porlay.cxx +++ b/sw/source/core/text/porlay.cxx @@ -617,6 +617,27 @@ void SwLineLayout::MaxAscentDescent( SwTwips& _orAscent, } } +void SwLineLayout::ResetFlags() +{ + m_bFormatAdj = m_bDummy = m_bFntChg = m_bTab = m_bEndHyph = m_bMidHyph = m_bFly + = m_bRest = m_bBlinking = m_bClipping = m_bContent = m_bRedline + = m_bForcedLeftMargin = m_bHanging = false; +} + +SwLineLayout::SwLineLayout() + : m_pNext( nullptr ), m_pLLSpaceAdd( nullptr ), m_pKanaComp( nullptr ), m_nRealHeight( 0 ), + m_bUnderscore( false ) +{ + ResetFlags(); + SetWhichPor( POR_LAY ); +} + +SwLinePortion *SwLineLayout::GetFirstPortion() const +{ + const SwLinePortion *pRet = pPortion ? pPortion : this; + return const_cast<SwLinePortion*>(pRet); +} + SwCharRange &SwCharRange::operator+=(const SwCharRange &rRange) { if(0 != rRange.nLen ) { diff --git a/sw/source/core/text/porlay.hxx b/sw/source/core/text/porlay.hxx index 76d0921b8134..f5c90528dcbd 100644 --- a/sw/source/core/text/porlay.hxx +++ b/sw/source/core/text/porlay.hxx @@ -103,10 +103,10 @@ public: // From SwLinePortion virtual SwLinePortion *Insert( SwLinePortion *pPortion ) override; virtual SwLinePortion *Append( SwLinePortion *pPortion ) override; - inline SwLinePortion *GetFirstPortion() const; + SwLinePortion *GetFirstPortion() const; // Flags - inline void ResetFlags(); + void ResetFlags(); inline void SetFormatAdj( const bool bNew ) { m_bFormatAdj = bNew; } inline bool IsFormatAdj() const { return m_bFormatAdj; } inline void SetEndHyph( const bool bNew ) { m_bEndHyph = bNew; } @@ -136,7 +136,7 @@ public: inline void SetClipping( const bool bNew ) { m_bClipping = bNew; } inline bool IsClipping() const { return m_bClipping; } - inline SwLineLayout(); + SwLineLayout(); virtual ~SwLineLayout() override; inline SwLineLayout *GetNext() { return m_pNext; } @@ -308,21 +308,6 @@ public: DECL_FIXEDMEMPOOL_NEWDEL(SwParaPortion) }; -inline void SwLineLayout::ResetFlags() -{ - m_bFormatAdj = m_bDummy = m_bFntChg = m_bTab = m_bEndHyph = m_bMidHyph = m_bFly - = m_bRest = m_bBlinking = m_bClipping = m_bContent = m_bRedline - = m_bForcedLeftMargin = m_bHanging = false; -} - -inline SwLineLayout::SwLineLayout() - : m_pNext( nullptr ), m_pLLSpaceAdd( nullptr ), m_pKanaComp( nullptr ), m_nRealHeight( 0 ), - m_bUnderscore( false ) -{ - ResetFlags(); - SetWhichPor( POR_LAY ); -} - inline void SwParaPortion::ResetPreps() { m_bPrep = m_bPrepWidows = m_bPrepAdjust = m_bPrepMustFit = false; @@ -340,13 +325,6 @@ inline void SwParaPortion::FormatReset() m_bFollowField = m_bFixLineHeight = m_bMargin = false; } -inline SwLinePortion *SwLineLayout::GetFirstPortion() const -{ - const SwLinePortion *pRet = pPortion ? pPortion : this; - return const_cast<SwLinePortion*>(pRet); -} - - #endif /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ |