Kaydet (Commit) f23d092c authored tarafından Miklos Vajna's avatar Miklos Vajna

sw: prefix members of SwLineLayout

Change-Id: If6ced6d33dbb9c82c75aa05a9f7b018926c0ffb0
üst 97355c22
...@@ -124,11 +124,11 @@ static bool lcl_HasStrongLTR ( const OUString& rText, sal_Int32 nStart, sal_Int ...@@ -124,11 +124,11 @@ static bool lcl_HasStrongLTR ( const OUString& rText, sal_Int32 nStart, sal_Int
SwLineLayout::~SwLineLayout() SwLineLayout::~SwLineLayout()
{ {
Truncate(); Truncate();
delete pNext; delete m_pNext;
if( pBlink ) if( pBlink )
pBlink->Delete( this ); pBlink->Delete( this );
delete pLLSpaceAdd; delete m_pLLSpaceAdd;
delete pKanaComp; delete m_pKanaComp;
} }
SwLinePortion *SwLineLayout::Insert( SwLinePortion *pIns ) SwLinePortion *SwLineLayout::Insert( SwLinePortion *pIns )
...@@ -220,7 +220,7 @@ SwMarginPortion *SwLineLayout::CalcLeftMargin() ...@@ -220,7 +220,7 @@ SwMarginPortion *SwLineLayout::CalcLeftMargin()
void SwLineLayout::InitSpaceAdd() void SwLineLayout::InitSpaceAdd()
{ {
if ( !pLLSpaceAdd ) if ( !m_pLLSpaceAdd )
CreateSpaceAdd(); CreateSpaceAdd();
else else
SetLLSpaceAdd( 0, 0 ); SetLLSpaceAdd( 0, 0 );
...@@ -228,7 +228,7 @@ void SwLineLayout::InitSpaceAdd() ...@@ -228,7 +228,7 @@ void SwLineLayout::InitSpaceAdd()
void SwLineLayout::CreateSpaceAdd( const long nInit ) void SwLineLayout::CreateSpaceAdd( const long nInit )
{ {
pLLSpaceAdd = new std::vector<long>; m_pLLSpaceAdd = new std::vector<long>;
SetLLSpaceAdd( nInit, 0 ); SetLLSpaceAdd( nInit, 0 );
} }
......
...@@ -77,25 +77,25 @@ public: ...@@ -77,25 +77,25 @@ public:
class SwLineLayout : public SwTextPortion class SwLineLayout : public SwTextPortion
{ {
private: private:
SwLineLayout *pNext; // The next Line SwLineLayout *m_pNext; // The next Line
std::vector<long>* pLLSpaceAdd; // Used for justified alignment std::vector<long>* m_pLLSpaceAdd; // Used for justified alignment
std::deque<sal_uInt16>* pKanaComp; // Used for Kana compression std::deque<sal_uInt16>* m_pKanaComp; // Used for Kana compression
sal_uInt16 nRealHeight; // The height resulting from line spacing and register sal_uInt16 m_nRealHeight; // The height resulting from line spacing and register
bool bFormatAdj : 1; bool m_bFormatAdj : 1;
bool bDummy : 1; bool m_bDummy : 1;
bool bFntChg : 1; bool m_bFntChg : 1;
bool bEndHyph : 1; bool m_bEndHyph : 1;
bool bMidHyph : 1; bool m_bMidHyph : 1;
bool bTab : 1; bool m_bTab : 1;
bool bFly : 1; bool m_bFly : 1;
bool bRest : 1; bool m_bRest : 1;
bool bBlinking : 1; bool m_bBlinking : 1;
bool bClipping : 1; // Clipping needed for exact line height bool m_bClipping : 1; // Clipping needed for exact line height
bool bContent : 1; // Text for line numbering bool m_bContent : 1; // Text for line numbering
bool bRedline : 1; // The Redlining bool m_bRedline : 1; // The Redlining
bool bForcedLeftMargin : 1; // Left adjustment moved by the Fly bool m_bForcedLeftMargin : 1; // Left adjustment moved by the Fly
bool bHanging : 1; // Contains a hanging portion in the margin bool m_bHanging : 1; // Contains a hanging portion in the margin
bool bUnderscore : 1; bool m_bUnderscore : 1;
SwTwips _GetHangingMargin() const; SwTwips _GetHangingMargin() const;
...@@ -107,49 +107,49 @@ public: ...@@ -107,49 +107,49 @@ public:
// Flags // Flags
inline void ResetFlags(); inline void ResetFlags();
inline void SetFormatAdj( const bool bNew ) { bFormatAdj = bNew; } inline void SetFormatAdj( const bool bNew ) { m_bFormatAdj = bNew; }
inline bool IsFormatAdj() const { return bFormatAdj; } inline bool IsFormatAdj() const { return m_bFormatAdj; }
inline void SetEndHyph( const bool bNew ) { bEndHyph = bNew; } inline void SetEndHyph( const bool bNew ) { m_bEndHyph = bNew; }
inline bool IsEndHyph() const { return bEndHyph; } inline bool IsEndHyph() const { return m_bEndHyph; }
inline void SetMidHyph( const bool bNew ) { bMidHyph = bNew; } inline void SetMidHyph( const bool bNew ) { m_bMidHyph = bNew; }
inline bool IsMidHyph() const { return bMidHyph; } inline bool IsMidHyph() const { return m_bMidHyph; }
inline void SetFly( const bool bNew ) { bFly = bNew; } inline void SetFly( const bool bNew ) { m_bFly = bNew; }
inline bool IsFly() const { return bFly; } inline bool IsFly() const { return m_bFly; }
inline void SetRest( const bool bNew ) { bRest = bNew; } inline void SetRest( const bool bNew ) { m_bRest = bNew; }
inline bool IsRest() const { return bRest; } inline bool IsRest() const { return m_bRest; }
inline void SetBlinking( const bool bNew = true ) { bBlinking = bNew; } inline void SetBlinking( const bool bNew = true ) { m_bBlinking = bNew; }
inline bool IsBlinking() const { return bBlinking; } inline bool IsBlinking() const { return m_bBlinking; }
inline void SetContent( const bool bNew = true ) { bContent = bNew; } inline void SetContent( const bool bNew = true ) { m_bContent = bNew; }
inline bool HasContent() const { return bContent; } inline bool HasContent() const { return m_bContent; }
inline void SetRedline( const bool bNew = true ) { bRedline = bNew; } inline void SetRedline( const bool bNew = true ) { m_bRedline = bNew; }
inline bool HasRedline() const { return bRedline; } inline bool HasRedline() const { return m_bRedline; }
inline void SetForcedLeftMargin( const bool bNew = true ) { bForcedLeftMargin = bNew; } inline void SetForcedLeftMargin( const bool bNew = true ) { m_bForcedLeftMargin = bNew; }
inline bool HasForcedLeftMargin() const { return bForcedLeftMargin; } inline bool HasForcedLeftMargin() const { return m_bForcedLeftMargin; }
inline void SetHanging( const bool bNew = true ) { bHanging = bNew; } inline void SetHanging( const bool bNew = true ) { m_bHanging = bNew; }
inline void SetUnderscore( const bool bNew = true ) { bUnderscore = bNew; } inline void SetUnderscore( const bool bNew = true ) { m_bUnderscore = bNew; }
inline bool HasUnderscore() const { return bUnderscore; } inline bool HasUnderscore() const { return m_bUnderscore; }
// Respecting empty dummy lines // Respecting empty dummy lines
inline void SetDummy( const bool bNew ) { bDummy = bNew; } inline void SetDummy( const bool bNew ) { m_bDummy = bNew; }
inline bool IsDummy() const { return bDummy; } inline bool IsDummy() const { return m_bDummy; }
inline void SetClipping( const bool bNew ) { bClipping = bNew; } inline void SetClipping( const bool bNew ) { m_bClipping = bNew; }
inline bool IsClipping() const { return bClipping; } inline bool IsClipping() const { return m_bClipping; }
inline SwLineLayout(); inline SwLineLayout();
virtual ~SwLineLayout(); virtual ~SwLineLayout();
inline SwLineLayout *GetNext() { return pNext; } inline SwLineLayout *GetNext() { return m_pNext; }
inline const SwLineLayout *GetNext() const { return pNext; } inline const SwLineLayout *GetNext() const { return m_pNext; }
inline void SetNext( SwLineLayout *pNew ) { pNext = pNew; } inline void SetNext( SwLineLayout *pNew ) { m_pNext = pNew; }
void Init( SwLinePortion *pNextPortion = nullptr); void Init( SwLinePortion *pNextPortion = nullptr);
// Collects the data for the line // Collects the data for the line
void CalcLine( SwTextFormatter &rLine, SwTextFormatInfo &rInf ); void CalcLine( SwTextFormatter &rLine, SwTextFormatInfo &rInf );
inline void SetRealHeight( sal_uInt16 nNew ) { nRealHeight = nNew; } inline void SetRealHeight( sal_uInt16 nNew ) { m_nRealHeight = nNew; }
inline sal_uInt16 GetRealHeight() const { return nRealHeight; } inline sal_uInt16 GetRealHeight() const { return m_nRealHeight; }
// Creates the glue chain for short lines // Creates the glue chain for short lines
SwMarginPortion *CalcLeftMargin(); SwMarginPortion *CalcLeftMargin();
...@@ -161,27 +161,27 @@ public: ...@@ -161,27 +161,27 @@ public:
virtual bool Format( SwTextFormatInfo &rInf ) override; virtual bool Format( SwTextFormatInfo &rInf ) override;
// Stuff for justified alignment // Stuff for justified alignment
inline bool IsSpaceAdd() { return pLLSpaceAdd != nullptr; } inline bool IsSpaceAdd() { return m_pLLSpaceAdd != nullptr; }
void InitSpaceAdd(); // Creates pLLSpaceAdd if necessary void InitSpaceAdd(); // Creates pLLSpaceAdd if necessary
void CreateSpaceAdd( const long nInit = 0 ); void CreateSpaceAdd( const long nInit = 0 );
inline void FinishSpaceAdd() { delete pLLSpaceAdd; pLLSpaceAdd = nullptr; } inline void FinishSpaceAdd() { delete m_pLLSpaceAdd; m_pLLSpaceAdd = nullptr; }
inline sal_uInt16 GetLLSpaceAddCount() const { return sal::static_int_cast< sal_uInt16 >(pLLSpaceAdd->size()); } inline sal_uInt16 GetLLSpaceAddCount() const { return sal::static_int_cast< sal_uInt16 >(m_pLLSpaceAdd->size()); }
inline void SetLLSpaceAdd( long nNew, sal_uInt16 nIdx ) inline void SetLLSpaceAdd( long nNew, sal_uInt16 nIdx )
{ {
if ( nIdx == GetLLSpaceAddCount() ) if ( nIdx == GetLLSpaceAddCount() )
pLLSpaceAdd->push_back( nNew ); m_pLLSpaceAdd->push_back( nNew );
else else
(*pLLSpaceAdd)[ nIdx ] = nNew; (*m_pLLSpaceAdd)[ nIdx ] = nNew;
} }
inline long GetLLSpaceAdd( sal_uInt16 nIdx ) { return (*pLLSpaceAdd)[ nIdx ]; } inline long GetLLSpaceAdd( sal_uInt16 nIdx ) { return (*m_pLLSpaceAdd)[ nIdx ]; }
inline void RemoveFirstLLSpaceAdd() { pLLSpaceAdd->erase( pLLSpaceAdd->begin() ); } inline void RemoveFirstLLSpaceAdd() { m_pLLSpaceAdd->erase( m_pLLSpaceAdd->begin() ); }
inline std::vector<long>* GetpLLSpaceAdd() const { return pLLSpaceAdd; } inline std::vector<long>* GetpLLSpaceAdd() const { return m_pLLSpaceAdd; }
// Stuff for Kana compression // Stuff for Kana compression
inline void SetKanaComp( std::deque<sal_uInt16>* pNew ){ pKanaComp = pNew; } inline void SetKanaComp( std::deque<sal_uInt16>* pNew ){ m_pKanaComp = pNew; }
inline void FinishKanaComp() { delete pKanaComp; pKanaComp = nullptr; } inline void FinishKanaComp() { delete m_pKanaComp; m_pKanaComp = nullptr; }
inline std::deque<sal_uInt16>* GetpKanaComp() const { return pKanaComp; } inline std::deque<sal_uInt16>* GetpKanaComp() const { return m_pKanaComp; }
inline std::deque<sal_uInt16>& GetKanaComp() { return *pKanaComp; } inline std::deque<sal_uInt16>& GetKanaComp() { return *m_pKanaComp; }
/** determine ascent and descent for positioning of as-character anchored /** determine ascent and descent for positioning of as-character anchored
object object
...@@ -318,14 +318,14 @@ public: ...@@ -318,14 +318,14 @@ public:
inline void SwLineLayout::ResetFlags() inline void SwLineLayout::ResetFlags()
{ {
bFormatAdj = bDummy = bFntChg = bTab = bEndHyph = bMidHyph = bFly m_bFormatAdj = m_bDummy = m_bFntChg = m_bTab = m_bEndHyph = m_bMidHyph = m_bFly
= bRest = bBlinking = bClipping = bContent = bRedline = m_bRest = m_bBlinking = m_bClipping = m_bContent = m_bRedline
= bForcedLeftMargin = bHanging = false; = m_bForcedLeftMargin = m_bHanging = false;
} }
inline SwLineLayout::SwLineLayout() inline SwLineLayout::SwLineLayout()
: pNext( nullptr ), pLLSpaceAdd( nullptr ), pKanaComp( nullptr ), nRealHeight( 0 ), : m_pNext( nullptr ), m_pLLSpaceAdd( nullptr ), m_pKanaComp( nullptr ), m_nRealHeight( 0 ),
bUnderscore( false ) m_bUnderscore( false )
{ {
ResetFlags(); ResetFlags();
SetWhichPor( POR_LAY ); SetWhichPor( POR_LAY );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment