sw/source/core/text/porlay.cxx | 16 - sw/source/core/text/porlay.hxx | 106 +++++----- sw/source/filter/xml/xmltbli.cxx | 400 +++++++++++++++++++-------------------- sw/source/filter/xml/xmltbli.hxx | 58 ++--- sw/source/ui/envelp/labfmt.cxx | 116 +++++------ sw/source/ui/envelp/labfmt.hxx | 52 ++--- sw/source/uibase/inc/formedt.hxx | 42 ++-- 7 files changed, 395 insertions(+), 395 deletions(-)
New commits: commit 617c72c1516417da0134859e0a8818ce1e0bf60a Author: Miklos Vajna <vmik...@collabora.co.uk> Date: Fri Nov 13 09:09:46 2015 +0100 sw: prefix members of SwIdxFormDlg Change-Id: I8da7fbf28b115d809ebdb8b10532455f0fc871d7 diff --git a/sw/source/uibase/inc/formedt.hxx b/sw/source/uibase/inc/formedt.hxx index cd74b45..9439c4a 100644 --- a/sw/source/uibase/inc/formedt.hxx +++ b/sw/source/uibase/inc/formedt.hxx @@ -39,28 +39,28 @@ class SwIdxFormDlg : public SvxStandardDialog { void Apply() override; - VclPtr<ListBox> aEntryLB; - VclPtr<OKButton> aOKBtn; - VclPtr<CancelButton> aCancelBT; - VclPtr<FixedText> aLevelFT; - VclPtr<Edit> aEntryED; - VclPtr<PushButton> aEntryBT; - VclPtr<PushButton> aTabBT; - VclPtr<PushButton> aPageBT; - VclPtr<PushButton> aJumpBT; - VclPtr<FixedLine> aEntryFL; - VclPtr<FixedText> aLevelFT2; - VclPtr<ListBox> aLevelLB; - VclPtr<FixedText> aTemplateFT; - VclPtr<ListBox> aParaLayLB; - VclPtr<PushButton> aStdBT; - VclPtr<PushButton> aAssignBT; - VclPtr<FixedLine> aFormatFL; + VclPtr<ListBox> m_aEntryLB; + VclPtr<OKButton> m_aOKBtn; + VclPtr<CancelButton> m_aCancelBT; + VclPtr<FixedText> m_aLevelFT; + VclPtr<Edit> m_aEntryED; + VclPtr<PushButton> m_aEntryBT; + VclPtr<PushButton> m_aTabBT; + VclPtr<PushButton> m_aPageBT; + VclPtr<PushButton> m_aJumpBT; + VclPtr<FixedLine> m_aEntryFL; + VclPtr<FixedText> m_aLevelFT2; + VclPtr<ListBox> m_aLevelLB; + VclPtr<FixedText> m_aTemplateFT; + VclPtr<ListBox> m_aParaLayLB; + VclPtr<PushButton> m_aStdBT; + VclPtr<PushButton> m_aAssignBT; + VclPtr<FixedLine> m_aFormatFL; - SwWrtShell &rSh; - SwForm *pForm; - sal_uInt16 nAktLevel; - bool bLastLinkIsEnd; + SwWrtShell &m_rSh; + SwForm *m_pForm; + sal_uInt16 m_nAktLevel; + bool m_bLastLinkIsEnd; public: SwIdxFormDlg( vcl::Window* pParent, SwWrtShell &rShell, const SwForm& rForm ); commit 158eeaec807182af47aeadcf794c571c19a84b30 Author: Miklos Vajna <vmik...@collabora.co.uk> Date: Fri Nov 13 09:08:28 2015 +0100 sw: prefix members of SwXMLTableContext Change-Id: I3c6bf5f4e56a60f2d869844b7c006eb8d6948e73 diff --git a/sw/source/filter/xml/xmltbli.cxx b/sw/source/filter/xml/xmltbli.cxx index d8808ab..8cb7e49 100644 --- a/sw/source/filter/xml/xmltbli.cxx +++ b/sw/source/filter/xml/xmltbli.cxx @@ -1277,22 +1277,22 @@ SwXMLTableContext::SwXMLTableContext( SwXMLImport& rImport, const OUString& rLName, const Reference< xml::sax::XAttributeList > & xAttrList ) : XMLTextTableContext( rImport, nPrfx, rLName ), - pColumnDefaultCellStyleNames( nullptr ), + m_pColumnDefaultCellStyleNames( nullptr ), m_pRows( new SwXMLTableRows_Impl ), - pTableNode( nullptr ), - pBox1( nullptr ), - pSttNd1( nullptr ), - pBoxFormat( nullptr ), - pLineFormat( nullptr ), - pSharedBoxFormats(nullptr), - pDDESource(nullptr), - bFirstSection( true ), - bRelWidth( true ), - bHasSubTables( false ), - nHeaderRows( 0 ), - nCurRow( 0UL ), - nCurCol( 0UL ), - nWidth( 0UL ) + m_pTableNode( nullptr ), + m_pBox1( nullptr ), + m_pSttNd1( nullptr ), + m_pBoxFormat( nullptr ), + m_pLineFormat( nullptr ), + m_pSharedBoxFormats(nullptr), + m_pDDESource(nullptr), + m_bFirstSection( true ), + m_bRelWidth( true ), + m_bHasSubTables( false ), + m_nHeaderRows( 0 ), + m_nCurRow( 0UL ), + m_nCurCol( 0UL ), + m_nWidth( 0UL ) { OUString aName; OUString sXmlId; @@ -1313,11 +1313,11 @@ SwXMLTableContext::SwXMLTableContext( SwXMLImport& rImport, if( XML_NAMESPACE_TABLE == nPrefix ) { if( IsXMLToken( aLocalName, XML_STYLE_NAME ) ) - aStyleName = rValue; + m_aStyleName = rValue; else if( IsXMLToken( aLocalName, XML_NAME ) ) aName = rValue; else if( IsXMLToken( aLocalName, XML_DEFAULT_CELL_STYLE_NAME ) ) - aDfltCellStyleName = rValue; + m_aDfltCellStyleName = rValue; } else if ( (XML_NAMESPACE_XML == nPrefix) && IsXMLToken( aLocalName, XML_ID ) ) @@ -1362,8 +1362,8 @@ SwXMLTableContext::SwXMLTableContext( SwXMLImport& rImport, try { - xTextContent = xTable; - GetImport().GetTextImport()->InsertTextContent( xTextContent ); + m_xTextContent = xTable; + GetImport().GetTextImport()->InsertTextContent( m_xTextContent ); } catch( IllegalArgumentException& ) { @@ -1388,7 +1388,7 @@ SwXMLTableContext::SwXMLTableContext( SwXMLImport& rImport, Reference < XCellRange > xCellRange( xTable, UNO_QUERY ); Reference < XCell > xCell = xCellRange->getCellByPosition( 0, 0 ); Reference < XText> xText( xCell, UNO_QUERY ); - xOldCursor = GetImport().GetTextImport()->GetCursor(); + m_xOldCursor = GetImport().GetTextImport()->GetCursor(); GetImport().GetTextImport()->SetCursor( xText->createTextCursor() ); // take care of open redlines for tables @@ -1400,14 +1400,14 @@ SwXMLTableContext::SwXMLTableContext( SwXMLImport& rImport, OSL_ENSURE( pTableFrameFormat, "table format missing" ); SwTable *pTable = SwTable::FindTable( pTableFrameFormat ); OSL_ENSURE( pTable, "table missing" ); - pTableNode = pTable->GetTableNode(); - OSL_ENSURE( pTableNode, "table node missing" ); + m_pTableNode = pTable->GetTableNode(); + OSL_ENSURE( m_pTableNode, "table node missing" ); pTableFrameFormat->SetName( sTableName ); - SwTableLine *pLine1 = pTableNode->GetTable().GetTabLines()[0U]; - pBox1 = pLine1->GetTabBoxes()[0U]; - pSttNd1 = pBox1->GetSttNd(); + SwTableLine *pLine1 = m_pTableNode->GetTable().GetTabLines()[0U]; + m_pBox1 = pLine1->GetTabBoxes()[0U]; + m_pSttNd1 = m_pBox1->GetSttNd(); } } @@ -1417,30 +1417,30 @@ SwXMLTableContext::SwXMLTableContext( SwXMLImport& rImport, const Reference< xml::sax::XAttributeList > &, SwXMLTableContext *pTable ) : XMLTextTableContext( rImport, nPrfx, rLName ), - pColumnDefaultCellStyleNames( nullptr ), + m_pColumnDefaultCellStyleNames( nullptr ), m_pRows( new SwXMLTableRows_Impl ), - pTableNode( pTable->pTableNode ), - pBox1( nullptr ), - pSttNd1( nullptr ), - pBoxFormat( nullptr ), - pLineFormat( nullptr ), - pSharedBoxFormats(nullptr), - xParentTable( pTable ), - pDDESource(nullptr), - bFirstSection( false ), - bRelWidth( true ), - bHasSubTables( false ), - nHeaderRows( 0 ), - nCurRow( 0UL ), - nCurCol( 0UL ), - nWidth( 0UL ) + m_pTableNode( pTable->m_pTableNode ), + m_pBox1( nullptr ), + m_pSttNd1( nullptr ), + m_pBoxFormat( nullptr ), + m_pLineFormat( nullptr ), + m_pSharedBoxFormats(nullptr), + m_xParentTable( pTable ), + m_pDDESource(nullptr), + m_bFirstSection( false ), + m_bRelWidth( true ), + m_bHasSubTables( false ), + m_nHeaderRows( 0 ), + m_nCurRow( 0UL ), + m_nCurCol( 0UL ), + m_nWidth( 0UL ) { } SwXMLTableContext::~SwXMLTableContext() { - delete pColumnDefaultCellStyleNames; - delete pSharedBoxFormats; + delete m_pColumnDefaultCellStyleNames; + delete m_pSharedBoxFormats; delete m_pRows; // close redlines on table end nodes @@ -1488,14 +1488,14 @@ SvXMLImportContext *SwXMLTableContext::CreateChildContext( sal_uInt16 nPrefix, // save context for later processing (discard old context, if approp.) if( IsValid() ) { - if (pDDESource != nullptr) + if (m_pDDESource != nullptr) { - pDDESource->ReleaseRef(); + m_pDDESource->ReleaseRef(); } - pDDESource = new SwXMLDDETableContext_Impl( GetSwImport(), nPrefix, + m_pDDESource = new SwXMLDDETableContext_Impl( GetSwImport(), nPrefix, rLocalName ); - pDDESource->AddFirstRef(); - pContext = pDDESource; + m_pDDESource->AddFirstRef(); + pContext = m_pDDESource; } break; } @@ -1509,31 +1509,31 @@ SvXMLImportContext *SwXMLTableContext::CreateChildContext( sal_uInt16 nPrefix, void SwXMLTableContext::InsertColumn( sal_Int32 nWidth2, bool bRelWidth2, const OUString *pDfltCellStyleName ) { - OSL_ENSURE( nCurCol < USHRT_MAX, + OSL_ENSURE( m_nCurCol < USHRT_MAX, "SwXMLTableContext::InsertColumn: no space left" ); - if( nCurCol >= USHRT_MAX ) + if( m_nCurCol >= USHRT_MAX ) return; if( nWidth2 < MINLAY ) nWidth2 = MINLAY; else if( nWidth2 > USHRT_MAX ) nWidth2 = USHRT_MAX; - aColumnWidths.push_back( ColumnWidthInfo(nWidth2, bRelWidth2) ); + m_aColumnWidths.push_back( ColumnWidthInfo(nWidth2, bRelWidth2) ); if( (pDfltCellStyleName && !pDfltCellStyleName->isEmpty()) || - pColumnDefaultCellStyleNames ) + m_pColumnDefaultCellStyleNames ) { - if( !pColumnDefaultCellStyleNames ) + if( !m_pColumnDefaultCellStyleNames ) { - pColumnDefaultCellStyleNames = new std::vector<OUString>; - sal_uLong nCount = aColumnWidths.size() - 1; + m_pColumnDefaultCellStyleNames = new std::vector<OUString>; + sal_uLong nCount = m_aColumnWidths.size() - 1; while( nCount-- ) - pColumnDefaultCellStyleNames->push_back(OUString()); + m_pColumnDefaultCellStyleNames->push_back(OUString()); } if(pDfltCellStyleName) - pColumnDefaultCellStyleNames->push_back(*pDfltCellStyleName); + m_pColumnDefaultCellStyleNames->push_back(*pDfltCellStyleName); else - pColumnDefaultCellStyleNames->push_back(OUString()); + m_pColumnDefaultCellStyleNames->push_back(OUString()); } } @@ -1541,20 +1541,20 @@ sal_Int32 SwXMLTableContext::GetColumnWidth( sal_uInt32 nCol, sal_uInt32 nColSpan ) const { sal_uInt32 nLast = nCol+nColSpan; - if( nLast > aColumnWidths.size() ) - nLast = aColumnWidths.size(); + if( nLast > m_aColumnWidths.size() ) + nLast = m_aColumnWidths.size(); sal_Int32 nWidth2 = 0L; for( sal_uInt32 i=nCol; i < nLast; ++i ) - nWidth2 += aColumnWidths[i].width; + nWidth2 += m_aColumnWidths[i].width; return nWidth2; } OUString SwXMLTableContext::GetColumnDefaultCellStyleName( sal_uInt32 nCol ) const { - if( pColumnDefaultCellStyleNames && nCol < pColumnDefaultCellStyleNames->size()) - return (*pColumnDefaultCellStyleNames)[static_cast<size_t>(nCol)]; + if( m_pColumnDefaultCellStyleNames && nCol < m_pColumnDefaultCellStyleNames->size()) + return (*m_pColumnDefaultCellStyleNames)[static_cast<size_t>(nCol)]; return OUString(); } @@ -1570,11 +1570,11 @@ void SwXMLTableContext::InsertCell( const OUString& rStyleName, double fValue, OUString const*const pStringValue ) { - OSL_ENSURE( nCurCol < GetColumnCount(), + OSL_ENSURE( m_nCurCol < GetColumnCount(), "SwXMLTableContext::InsertCell: row is full" ); - OSL_ENSURE( nCurRow < USHRT_MAX, + OSL_ENSURE( m_nCurRow < USHRT_MAX, "SwXMLTableContext::InsertCell: table is full" ); - if( nCurCol >= USHRT_MAX || nCurRow > USHRT_MAX ) + if( m_nCurCol >= USHRT_MAX || m_nCurRow > USHRT_MAX ) return; OSL_ENSURE( nRowSpan >=1UL, "SwXMLTableContext::InsertCell: row span is 0" ); @@ -1585,36 +1585,36 @@ void SwXMLTableContext::InsertCell( const OUString& rStyleName, nColSpan = 1UL; // Until it is possible to add columns here, fix the column span. - sal_uInt32 nColsReq = nCurCol + nColSpan; + sal_uInt32 nColsReq = m_nCurCol + nColSpan; if( nColsReq > GetColumnCount() ) { - nColSpan = GetColumnCount() - nCurCol; + nColSpan = GetColumnCount() - m_nCurCol; nColsReq = GetColumnCount(); } // Check whether there are cells from a previous line already that reach // into the current row. - if( nCurRow > 0UL && nColSpan > 1UL ) + if( m_nCurRow > 0UL && nColSpan > 1UL ) { - SwXMLTableRow_Impl *pCurRow = (*m_pRows)[nCurRow].get(); + SwXMLTableRow_Impl *pCurRow = (*m_pRows)[m_nCurRow].get(); sal_uInt32 nLastCol = GetColumnCount() < nColsReq ? GetColumnCount() : nColsReq; - for( sal_uInt32 i=nCurCol+1UL; i<nLastCol; ++i ) + for( sal_uInt32 i=m_nCurCol+1UL; i<nLastCol; ++i ) { if( pCurRow->GetCell(i)->IsUsed() ) { // If this cell is used, the column span is truncated - nColSpan = i - nCurCol; + nColSpan = i - m_nCurCol; nColsReq = i; break; } } } - sal_uInt32 nRowsReq = nCurRow + nRowSpan; + sal_uInt32 nRowsReq = m_nCurRow + nRowSpan; if( nRowsReq > USHRT_MAX ) { - nRowSpan = USHRT_MAX - nCurRow; + nRowSpan = USHRT_MAX - m_nCurRow; nRowsReq = USHRT_MAX; } @@ -1624,11 +1624,11 @@ void SwXMLTableContext::InsertCell( const OUString& rStyleName, { for( sal_uInt32 i=GetColumnCount(); i<nColsReq; ++i ) { - aColumnWidths.push_back( ColumnWidthInfo(MINLAY, true) ); + m_aColumnWidths.push_back( ColumnWidthInfo(MINLAY, true) ); } // adjust columns in *all* rows, if columns must be inserted for (size_t i = 0; i < m_pRows->size(); ++i) - (*m_pRows)[i]->Expand( nColsReq, i<nCurRow ); + (*m_pRows)[i]->Expand( nColsReq, i<m_nCurRow ); } // Add rows @@ -1642,12 +1642,12 @@ void SwXMLTableContext::InsertCell( const OUString& rStyleName, OUString sStyleName( rStyleName ); if( sStyleName.isEmpty() ) { - sStyleName = (*m_pRows)[nCurRow]->GetDefaultCellStyleName(); + sStyleName = (*m_pRows)[m_nCurRow]->GetDefaultCellStyleName(); if( sStyleName.isEmpty() && HasColumnDefaultCellStyleNames() ) { - sStyleName = GetColumnDefaultCellStyleName( nCurCol ); + sStyleName = GetColumnDefaultCellStyleName( m_nCurCol ); if( sStyleName.isEmpty() ) - sStyleName = aDfltCellStyleName; + sStyleName = m_aDfltCellStyleName; } } @@ -1665,9 +1665,9 @@ void SwXMLTableContext::InsertCell( const OUString& rStyleName, } // Set current col to the next (free) column - nCurCol = nColsReq; - while( nCurCol<GetColumnCount() && GetCell(nCurRow,nCurCol)->IsUsed() ) - nCurCol++; + m_nCurCol = nColsReq; + while( m_nCurCol<GetColumnCount() && GetCell(m_nCurRow,m_nCurCol)->IsUsed() ) + m_nCurCol++; } void SwXMLTableContext::InsertRow( const OUString& rStyleName, @@ -1675,20 +1675,20 @@ void SwXMLTableContext::InsertRow( const OUString& rStyleName, bool bInHead, const OUString & i_rXmlId ) { - OSL_ENSURE( nCurRow < USHRT_MAX, + OSL_ENSURE( m_nCurRow < USHRT_MAX, "SwXMLTableContext::InsertRow: no space left" ); - if( nCurRow >= USHRT_MAX ) + if( m_nCurRow >= USHRT_MAX ) return; // Make sure there is at least one column. - if( 0==nCurRow && 0UL == GetColumnCount() ) + if( 0==m_nCurRow && 0UL == GetColumnCount() ) InsertColumn( USHRT_MAX, true ); - if (nCurRow < m_pRows->size()) + if (m_nCurRow < m_pRows->size()) { // The current row has already been inserted because of a row span // of a previous row. - (*m_pRows)[nCurRow]->Set( + (*m_pRows)[m_nCurRow]->Set( rStyleName, rDfltCellStyleName, i_rXmlId ); } else @@ -1700,29 +1700,29 @@ void SwXMLTableContext::InsertRow( const OUString& rStyleName, } // We start at the first column ... - nCurCol=0UL; + m_nCurCol=0UL; // ... but this cell may be occupied already. - while( nCurCol<GetColumnCount() && GetCell(nCurRow,nCurCol)->IsUsed() ) - nCurCol++; + while( m_nCurCol<GetColumnCount() && GetCell(m_nCurRow,m_nCurCol)->IsUsed() ) + m_nCurCol++; - if( bInHead && nHeaderRows == nCurRow ) - nHeaderRows++; + if( bInHead && m_nHeaderRows == m_nCurRow ) + m_nHeaderRows++; } void SwXMLTableContext::InsertRepRows( sal_uInt32 nCount ) { - const SwXMLTableRow_Impl *pSrcRow = (*m_pRows)[nCurRow-1].get(); + const SwXMLTableRow_Impl *pSrcRow = (*m_pRows)[m_nCurRow-1].get(); while( nCount > 1 && IsInsertRowPossible() ) { InsertRow( pSrcRow->GetStyleName(), pSrcRow->GetDefaultCellStyleName(), false ); - while( nCurCol < GetColumnCount() ) + while( m_nCurCol < GetColumnCount() ) { - if( !GetCell(nCurRow,nCurCol)->IsUsed() ) + if( !GetCell(m_nCurRow,m_nCurCol)->IsUsed() ) { const SwXMLTableCell_Impl *pSrcCell = - GetCell( nCurRow-1, nCurCol ); + GetCell( m_nCurRow-1, m_nCurCol ); InsertCell( pSrcCell->GetStyleName(), 1U, pSrcCell->GetColSpan(), InsertTableSection(), @@ -1741,14 +1741,14 @@ void SwXMLTableContext::InsertRepRows( sal_uInt32 nCount ) void SwXMLTableContext::FinishRow() { // Insert an empty cell at the end of the line if the row is not complete - if( nCurCol < GetColumnCount() ) + if( m_nCurCol < GetColumnCount() ) { - InsertCell( "", 1U, GetColumnCount() - nCurCol, + InsertCell( "", 1U, GetColumnCount() - m_nCurCol, InsertTableSection() ); } // Move to the next row. - nCurRow++; + m_nCurRow++; } const SwStartNode *SwXMLTableContext::GetPrevStartNode( sal_uInt32 nRow, @@ -1828,23 +1828,23 @@ SwTableBox *SwXMLTableContext::NewTableBox( const SwStartNode *pStNd, { // The topmost table is the only table that maintains the two members // pBox1 and bFirstSection. - if( xParentTable.Is() ) - return static_cast<SwXMLTableContext *>(&xParentTable)->NewTableBox( pStNd, + if( m_xParentTable.Is() ) + return static_cast<SwXMLTableContext *>(&m_xParentTable)->NewTableBox( pStNd, pUpper ); SwTableBox *pBox; - if( pBox1 && - pBox1->GetSttNd() == pStNd ) + if( m_pBox1 && + m_pBox1->GetSttNd() == pStNd ) { // if the StartNode is equal to the StartNode of the initially // created box, we use this box - pBox = pBox1; + pBox = m_pBox1; pBox->SetUpper( pUpper ); - pBox1 = nullptr; + m_pBox1 = nullptr; } else - pBox = new SwTableBox( pBoxFormat, *pStNd, pUpper ); + pBox = new SwTableBox( m_pBoxFormat, *pStNd, pUpper ); return pBox; } @@ -1858,14 +1858,14 @@ SwTableBoxFormat* SwXMLTableContext::GetSharedBoxFormat( bool& bNew, bool* pModifyLocked ) { - if ( pSharedBoxFormats == nullptr ) - pSharedBoxFormats = new map_BoxFormat(); + if ( m_pSharedBoxFormats == nullptr ) + m_pSharedBoxFormats = new map_BoxFormat(); SwTableBoxFormat* pBoxFormat2; TableBoxIndex aKey( rStyleName, nColumnWidth, bProtected ); - map_BoxFormat::iterator aIter = pSharedBoxFormats->find( aKey ); - if ( aIter == pSharedBoxFormats->end() ) + map_BoxFormat::iterator aIter = m_pSharedBoxFormats->find( aKey ); + if ( aIter == m_pSharedBoxFormats->end() ) { // unknown format so far -> construct a new one @@ -1879,7 +1879,7 @@ SwTableBoxFormat* SwXMLTableContext::GetSharedBoxFormat( // share this format, if allowed if ( bMayShare ) - (*pSharedBoxFormats)[ aKey ] = pBoxFormat2; + (*m_pSharedBoxFormats)[ aKey ] = pBoxFormat2; } else { @@ -1910,7 +1910,7 @@ SwTableBox *SwXMLTableContext::MakeTableBox( SwTableLine *pUpper, sal_uInt32 nRightCol ) { //FIXME: here would be a great place to handle XmlId for cell - SwTableBox *pBox = new SwTableBox( pBoxFormat, 0, pUpper ); + SwTableBox *pBox = new SwTableBox( m_pBoxFormat, 0, pUpper ); sal_uInt32 nColSpan = nRightCol - nLeftCol; sal_Int32 nColWidth = GetColumnWidth( nLeftCol, nColSpan ); @@ -2018,7 +2018,7 @@ SwTableBox *SwXMLTableContext::MakeTableBox( { // and it is a table: therefore we build a new box and // put the rows of the table into the rows of the box - pBox = new SwTableBox( pBoxFormat, 0, pUpper ); + pBox = new SwTableBox( m_pBoxFormat, 0, pUpper ); pCell->GetSubTable()->MakeTable( pBox, nColWidth ); } @@ -2131,17 +2131,17 @@ SwTableBox *SwXMLTableContext::MakeTableBox( // Solution: the number format will be removed, // the cell gets the default text format. const SfxPoolItem* pItem = nullptr; - if( pBoxFormat->GetItemState( RES_BOXATR_FORMAT, false, &pItem ) + if( m_pBoxFormat->GetItemState( RES_BOXATR_FORMAT, false, &pItem ) == SfxItemState::SET ) { - const SwDoc* pDoc = pBoxFormat->GetDoc(); + const SwDoc* pDoc = m_pBoxFormat->GetDoc(); const SvNumberFormatter* pNumberFormatter = pDoc ? pDoc->GetNumberFormatter() : nullptr; const SwTableBoxNumFormat* pNumFormat = static_cast<const SwTableBoxNumFormat*>( pItem ); if( pNumFormat != nullptr && pNumberFormatter && !pNumberFormatter->GetEntry( pNumFormat->GetValue() )->IsTextFormat() ) - pBoxFormat->ResetFormatAttr( RES_BOXATR_FORMAT ); + m_pBoxFormat->ResetFormatAttr( RES_BOXATR_FORMAT ); } } // always insert value, even if default @@ -2183,11 +2183,11 @@ SwTableLine *SwXMLTableContext::MakeTableLine( SwTableBox *pUpper, SwTableLine *pLine; if( !pUpper && 0UL==nTopRow ) { - pLine = pTableNode->GetTable().GetTabLines()[0U]; + pLine = m_pTableNode->GetTable().GetTabLines()[0U]; } else { - pLine = new SwTableLine( pLineFormat, 0, pUpper ); + pLine = new SwTableLine( m_pLineFormat, 0, pUpper ); } // TODO: Share formats! @@ -2229,7 +2229,7 @@ SwTableLine *SwXMLTableContext::MakeTableLine( SwTableBox *pUpper, bool bHoriSplitMayContinue = false; bool bHoriSplitPossible = false; - if ( bHasSubTables ) + if ( m_bHasSubTables ) { // Convert row spans if the table has subtables: for( sal_uInt32 nRow=nTopRow; nRow<nBottomRow; nRow++ ) @@ -2278,7 +2278,7 @@ SwTableLine *SwXMLTableContext::MakeTableLine( SwTableBox *pUpper, if( nCol == nRightCol-1UL ) { OSL_ENSURE( bSplit, "Split-Flag falsch" ); - if ( bHasSubTables ) + if ( m_bHasSubTables ) { OSL_ENSURE( !bHoriSplitMayContinue, "HoriSplitMayContinue-Flag falsch" ); @@ -2289,7 +2289,7 @@ SwTableLine *SwXMLTableContext::MakeTableLine( SwTableBox *pUpper, } #endif - OSL_ENSURE( !bHasSubTables || !bHoriSplitMayContinue || bHoriSplitPossible, + OSL_ENSURE( !m_bHasSubTables || !bHoriSplitMayContinue || bHoriSplitPossible, "bHoriSplitMayContinue, aber nicht bHoriSplitPossible" ); if( bSplit ) @@ -2297,13 +2297,13 @@ SwTableLine *SwXMLTableContext::MakeTableLine( SwTableBox *pUpper, SwTableBox* pBox = nullptr; SwXMLTableCell_Impl *pCell = GetCell( nTopRow, nStartCol ); // #i95726# - some fault tolerance - if( ( !bHasSubTables || ( pCell->GetRowSpan() == (nBottomRow-nTopRow) ) ) && + if( ( !m_bHasSubTables || ( pCell->GetRowSpan() == (nBottomRow-nTopRow) ) ) && pCell->GetColSpan() == (nCol+1UL-nStartCol) && ( pCell->GetStartNode() || pCell->GetSubTable() ) ) { // insert new empty cell for covered cells: long nBoxRowSpan = 1; - if ( !bHasSubTables ) + if ( !m_bHasSubTables ) { nBoxRowSpan = pCell->GetRowSpan(); if ( pCell->IsCovered() ) @@ -2326,7 +2326,7 @@ SwTableLine *SwXMLTableContext::MakeTableLine( SwTableBox *pUpper, bSplitted = true; } - else if( bHasSubTables && bHoriSplitPossible && bHoriSplitMayContinue ) + else if( m_bHasSubTables && bHoriSplitPossible && bHoriSplitMayContinue ) { // The table fragment could be splitted behind the current // column, and the remaining fragment could be divided @@ -2336,7 +2336,7 @@ SwTableLine *SwXMLTableContext::MakeTableLine( SwTableBox *pUpper, // split. nSplitCol = nCol + 1UL; } - else if ( bHasSubTables ) + else if ( m_bHasSubTables ) { // If the table resulting table fragment could be divided // into lines if spllitting behind the current column, but @@ -2360,7 +2360,7 @@ SwTableLine *SwXMLTableContext::MakeTableLine( SwTableBox *pUpper, bSplitted = true; } - OSL_ENSURE( bHasSubTables || pBox, "Colspan trouble" ); + OSL_ENSURE( m_bHasSubTables || pBox, "Colspan trouble" ); if( pBox ) rBoxes.push_back( pBox ); @@ -2382,18 +2382,18 @@ void SwXMLTableContext::_MakeTable( SwTableBox *pBox ) // If there are empty rows (because of some row span of previous rows) // the have to be deleted. The previous rows have to be truncated. - if (m_pRows->size() > nCurRow) + if (m_pRows->size() > m_nCurRow) { - SwXMLTableRow_Impl *pPrevRow = (*m_pRows)[nCurRow - 1U].get(); + SwXMLTableRow_Impl *pPrevRow = (*m_pRows)[m_nCurRow - 1U].get(); const SwXMLTableCell_Impl *pCell; - for( sal_uLong i = 0; i < aColumnWidths.size(); ++i ) + for( sal_uLong i = 0; i < m_aColumnWidths.size(); ++i ) { if( ( pCell=pPrevRow->GetCell(i), pCell->GetRowSpan() > 1UL ) ) { - FixRowSpan( nCurRow-1UL, i, 1UL ); + FixRowSpan( m_nCurRow-1UL, i, 1UL ); } } - for (sal_uLong i = m_pRows->size() - 1UL; i >= nCurRow; --i) + for (sal_uLong i = m_pRows->size() - 1UL; i >= m_nCurRow; --i) m_pRows->pop_back(); } @@ -2409,7 +2409,7 @@ void SwXMLTableContext::_MakeTable( SwTableBox *pBox ) sal_Int32 nRelWidth = 0L; sal_Int32 nMinRelColWidth = 0L; sal_uInt32 nRelCols = 0UL; - for( colIter = aColumnWidths.begin(); colIter < aColumnWidths.end(); ++colIter) + for( colIter = m_aColumnWidths.begin(); colIter < m_aColumnWidths.end(); ++colIter) { if( colIter->isRelative ) { @@ -2427,7 +2427,7 @@ void SwXMLTableContext::_MakeTable( SwTableBox *pBox ) } sal_uInt32 nAbsCols = nCols - nRelCols; - if( bRelWidth ) + if( m_bRelWidth ) { // If there a columns that have an absolute width, we have to // calculate a relative one for them. @@ -2441,7 +2441,7 @@ void SwXMLTableContext::_MakeTable( SwTableBox *pBox ) if( 0L == nMinRelColWidth ) nMinRelColWidth = nMinAbsColWidth; - for( colIter = aColumnWidths.begin(); nAbsCols > 0UL && colIter < aColumnWidths.end(); ++colIter) + for( colIter = m_aColumnWidths.begin(); nAbsCols > 0UL && colIter < m_aColumnWidths.end(); ++colIter) { if( !colIter->isRelative ) { @@ -2456,25 +2456,25 @@ void SwXMLTableContext::_MakeTable( SwTableBox *pBox ) } } - if( !nWidth ) + if( !m_nWidth ) { // This happens only for percentage values for the table itself. // In this case, the columns get the correct width even if the // the sum of the relative withs is smaller than the available // width in TWIP. Therefore, we can use the relative width. - nWidth = nRelWidth > USHRT_MAX ? USHRT_MAX : nRelWidth; + m_nWidth = nRelWidth > USHRT_MAX ? USHRT_MAX : nRelWidth; } - if( nRelWidth != nWidth && nRelWidth && nCols ) + if( nRelWidth != m_nWidth && nRelWidth && nCols ) { - double n = (double)nWidth / (double)nRelWidth; + double n = (double)m_nWidth / (double)nRelWidth; nRelWidth = 0L; - for( colIter = aColumnWidths.begin(); colIter < aColumnWidths.end() - 1; ++colIter) + for( colIter = m_aColumnWidths.begin(); colIter < m_aColumnWidths.end() - 1; ++colIter) { sal_Int32 nW = (sal_Int32)( colIter->width * n); colIter->width = (sal_uInt16)nW; nRelWidth += nW; } - aColumnWidths.back().width = (nWidth-nRelWidth); + m_aColumnWidths.back().width = (m_nWidth-nRelWidth); } } else @@ -2486,7 +2486,7 @@ void SwXMLTableContext::_MakeTable( SwTableBox *pBox ) // The absolute space that is available for all columns with a // relative width. sal_Int32 nAbsForRelWidth = - nWidth > nAbsWidth ? nWidth - nAbsWidth : (sal_Int32)0L; + m_nWidth > nAbsWidth ? m_nWidth - nAbsWidth : (sal_Int32)0L; // The relative width that has to be distributed in addition to // equally widthed columns. @@ -2522,7 +2522,7 @@ void SwXMLTableContext::_MakeTable( SwTableBox *pBox ) // Otherwise, if there is enough space for every column, every // column gets this space. - for( colIter = aColumnWidths.begin(); nRelCols > 0UL && colIter < aColumnWidths.end(); ++colIter ) + for( colIter = m_aColumnWidths.begin(); nRelCols > 0UL && colIter < m_aColumnWidths.end(); ++colIter ) { if( colIter->isRelative ) { @@ -2561,13 +2561,13 @@ void SwXMLTableContext::_MakeTable( SwTableBox *pBox ) if( nCols && nAbsWidth ) { - if( nAbsWidth < nWidth ) + if( nAbsWidth < m_nWidth ) { // If the table's width is larger than the sum of the absolute // column widths, every column get some extra width. - sal_Int32 nExtraAbs = nWidth - nAbsWidth; - sal_Int32 nAbsLastCol = aColumnWidths.back().width + nExtraAbs; - for( colIter = aColumnWidths.begin(); colIter < aColumnWidths.end()-1UL; ++colIter ) + sal_Int32 nExtraAbs = m_nWidth - nAbsWidth; + sal_Int32 nAbsLastCol = m_aColumnWidths.back().width + nExtraAbs; + for( colIter = m_aColumnWidths.begin(); colIter < m_aColumnWidths.end()-1UL; ++colIter ) { sal_Int32 nAbsCol = colIter->width; sal_Int32 nExtraAbsCol = (nAbsCol * nExtraAbs) / @@ -2576,16 +2576,16 @@ void SwXMLTableContext::_MakeTable( SwTableBox *pBox ) colIter->width = nAbsCol; nAbsLastCol -= nExtraAbsCol; } - aColumnWidths.back().width = nAbsLastCol; + m_aColumnWidths.back().width = nAbsLastCol; } - else if( nAbsWidth > nWidth ) + else if( nAbsWidth > m_nWidth ) { // If the table's width is smaller than the sum of the absolute // column widths, every column needs to shrink. // Every column gets the minimum width plus some extra width. - sal_Int32 nExtraAbs = nWidth - (nCols * MINLAY); + sal_Int32 nExtraAbs = m_nWidth - (nCols * MINLAY); sal_Int32 nAbsLastCol = MINLAY + nExtraAbs; - for( colIter = aColumnWidths.begin(); colIter < aColumnWidths.end()-1UL; ++colIter ) + for( colIter = m_aColumnWidths.begin(); colIter < m_aColumnWidths.end()-1UL; ++colIter ) { sal_Int32 nAbsCol = colIter->width; sal_Int32 nExtraAbsCol = (nAbsCol * nExtraAbs) / @@ -2594,14 +2594,14 @@ void SwXMLTableContext::_MakeTable( SwTableBox *pBox ) colIter->width = nAbsCol; nAbsLastCol -= nExtraAbsCol; } - aColumnWidths.back().width = nAbsLastCol; + m_aColumnWidths.back().width = nAbsLastCol; } } } SwTableLines& rLines = pBox ? pBox->GetTabLines() - : pTableNode->GetTable().GetTabLines(); + : m_pTableNode->GetTable().GetTabLines(); sal_uInt32 nStartRow = 0UL; sal_uInt32 nRows = m_pRows->size(); @@ -2609,7 +2609,7 @@ void SwXMLTableContext::_MakeTable( SwTableBox *pBox ) { // Could we split the table behind the current line? bool bSplit = true; - if ( bHasSubTables ) + if ( m_bHasSubTables ) { SwXMLTableRow_Impl *pRow = (*m_pRows)[i].get(); for( sal_uInt32 j=0UL; j<nCols; j++ ) @@ -2642,29 +2642,29 @@ void SwXMLTableContext::MakeTable() if (!m_pRows || m_pRows->empty() || !GetColumnCount()) { OSL_FAIL("invalid table: no cells; deleting..."); - pTableNode->GetDoc()->getIDocumentContentOperations().DeleteSection( pTableNode ); - pTableNode = nullptr; - pBox1 = nullptr; - pSttNd1 = nullptr; + m_pTableNode->GetDoc()->getIDocumentContentOperations().DeleteSection( m_pTableNode ); + m_pTableNode = nullptr; + m_pBox1 = nullptr; + m_pSttNd1 = nullptr; return; } SwXMLImport& rSwImport = GetSwImport(); - SwFrameFormat *pFrameFormat = pTableNode->GetTable().GetFrameFormat(); + SwFrameFormat *pFrameFormat = m_pTableNode->GetTable().GetFrameFormat(); sal_Int16 eHoriOrient = text::HoriOrientation::FULL; bool bSetHoriOrient = false; sal_uInt8 nPrcWidth = 0U; - pTableNode->GetTable().SetRowsToRepeat( nHeaderRows ); - pTableNode->GetTable().SetTableModel( !bHasSubTables ); + m_pTableNode->GetTable().SetRowsToRepeat( m_nHeaderRows ); + m_pTableNode->GetTable().SetTableModel( !m_bHasSubTables ); const SfxItemSet *pAutoItemSet = nullptr; - if( !aStyleName.isEmpty() && + if( !m_aStyleName.isEmpty() && rSwImport.FindAutomaticStyle( - XML_STYLE_FAMILY_TABLE_TABLE, aStyleName, &pAutoItemSet ) && + XML_STYLE_FAMILY_TABLE_TABLE, m_aStyleName, &pAutoItemSet ) && pAutoItemSet ) { const SfxPoolItem *pItem; @@ -2717,7 +2717,7 @@ void SwXMLTableContext::MakeTable() // twip value is larger than the space that is available. // We don't know that space, so we have to use USHRT_MAX, too. // Even if a size is specified, it will be ignored! - nWidth = USHRT_MAX; + m_nWidth = USHRT_MAX; break; default: if( pSize ) @@ -2729,16 +2729,16 @@ void SwXMLTableContext::MakeTable() } else { - nWidth = pSize->GetWidth(); - if( nWidth < (sal_Int32)GetColumnCount() * MINLAY ) + m_nWidth = pSize->GetWidth(); + if( m_nWidth < (sal_Int32)GetColumnCount() * MINLAY ) { - nWidth = GetColumnCount() * MINLAY; + m_nWidth = GetColumnCount() * MINLAY; } - else if( nWidth > USHRT_MAX ) + else if( m_nWidth > USHRT_MAX ) { - nWidth = USHRT_MAX; + m_nWidth = USHRT_MAX; } - bRelWidth = false; + m_bRelWidth = false; } } else @@ -2746,7 +2746,7 @@ void SwXMLTableContext::MakeTable() eHoriOrient = text::HoriOrientation::LEFT_AND_WIDTH == eHoriOrient ? text::HoriOrientation::NONE : text::HoriOrientation::FULL; bSetHoriOrient = true; - nWidth = USHRT_MAX; + m_nWidth = USHRT_MAX; } break; } @@ -2756,17 +2756,17 @@ void SwXMLTableContext::MakeTable() else { bSetHoriOrient = true; - nWidth = USHRT_MAX; + m_nWidth = USHRT_MAX; } - SwTableLine *pLine1 = pTableNode->GetTable().GetTabLines()[0U]; - OSL_ENSURE( pBox1 == pLine1->GetTabBoxes()[0U], + SwTableLine *pLine1 = m_pTableNode->GetTable().GetTabLines()[0U]; + OSL_ENSURE( m_pBox1 == pLine1->GetTabBoxes()[0U], "Why is box 1 change?" ); - pBox1->m_pStartNode = pSttNd1; + m_pBox1->m_pStartNode = m_pSttNd1; pLine1->GetTabBoxes().erase( pLine1->GetTabBoxes().begin() ); - pLineFormat = static_cast<SwTableLineFormat*>(pLine1->GetFrameFormat()); - pBoxFormat = static_cast<SwTableBoxFormat*>(pBox1->GetFrameFormat()); + m_pLineFormat = static_cast<SwTableLineFormat*>(pLine1->GetFrameFormat()); + m_pBoxFormat = static_cast<SwTableBoxFormat*>(m_pBox1->GetFrameFormat()); _MakeTable(); @@ -2776,7 +2776,7 @@ void SwXMLTableContext::MakeTable() // This must be after the call to _MakeTable, because nWidth might be // changed there. pFrameFormat->LockModify(); - SwFormatFrmSize aSize( ATT_VAR_SIZE, nWidth ); + SwFormatFrmSize aSize( ATT_VAR_SIZE, m_nWidth ); aSize.SetWidthPercent( nPrcWidth ); pFrameFormat->SetFormatAttr( aSize ); pFrameFormat->UnlockModify(); @@ -2785,40 +2785,40 @@ void SwXMLTableContext::MakeTable() (*m_pRows)[i]->Dispose(); // now that table is complete, change into DDE table (if appropriate) - if (nullptr != pDDESource) + if (nullptr != m_pDDESource) { // change existing table into DDE table: // 1) Get DDE field type (get data from dde-source context), - SwDDEFieldType* pFieldType = lcl_GetDDEFieldType( pDDESource, - pTableNode ); + SwDDEFieldType* pFieldType = lcl_GetDDEFieldType( m_pDDESource, + m_pTableNode ); // 2) release the DDE source context, - pDDESource->ReleaseRef(); + m_pDDESource->ReleaseRef(); // 3) create new DDE table, and - SwDDETable* pDDETable = new SwDDETable( pTableNode->GetTable(), + SwDDETable* pDDETable = new SwDDETable( m_pTableNode->GetTable(), pFieldType, false ); // 4) set new (DDE)table at node. - pTableNode->SetNewTable(pDDETable, false); + m_pTableNode->SetNewTable(pDDETable, false); } // ??? this is always false: root frame is only created in SwViewShell::Init - if( pTableNode->GetDoc()->getIDocumentLayoutAccess().GetCurrentViewShell() ) + if( m_pTableNode->GetDoc()->getIDocumentLayoutAccess().GetCurrentViewShell() ) { - pTableNode->DelFrms(); - SwNodeIndex aIdx( *pTableNode->EndOfSectionNode(), 1 ); - pTableNode->MakeFrms( &aIdx ); + m_pTableNode->DelFrms(); + SwNodeIndex aIdx( *m_pTableNode->EndOfSectionNode(), 1 ); + m_pTableNode->MakeFrms( &aIdx ); } } void SwXMLTableContext::MakeTable( SwTableBox *pBox, sal_Int32 nW ) { //FIXME: here would be a great place to handle XmlId for subtable - pLineFormat = GetParentTable()->pLineFormat; - pBoxFormat = GetParentTable()->pBoxFormat; - nWidth = nW; - bRelWidth = GetParentTable()->bRelWidth; + m_pLineFormat = GetParentTable()->m_pLineFormat; + m_pBoxFormat = GetParentTable()->m_pBoxFormat; + m_nWidth = nW; + m_bRelWidth = GetParentTable()->m_bRelWidth; _MakeTable( pBox ); @@ -2835,8 +2835,8 @@ const SwStartNode *SwXMLTableContext::InsertTableSection( { // The topmost table is the only table that maintains the two members // pBox1 and bFirstSection. - if( xParentTable.Is() ) - return static_cast<SwXMLTableContext *>(&xParentTable) + if( m_xParentTable.Is() ) + return static_cast<SwXMLTableContext *>(&m_xParentTable) ->InsertTableSection(pPrevSttNd, pStringValueStyleName); const SwStartNode *pStNd; @@ -2847,11 +2847,11 @@ const SwStartNode *SwXMLTableContext::InsertTableSection( sal::static_int_cast< sal_IntPtr >( xCrsrTunnel->getSomething( OTextCursorHelper::getUnoTunnelId() ))); OSL_ENSURE( pTextCrsr, "SwXTextCursor missing" ); - if( bFirstSection ) + if( m_bFirstSection ) { // The Cursor already is in the first section pStNd = pTextCrsr->GetPaM()->GetNode().FindTableBoxStartNode(); - bFirstSection = false; + m_bFirstSection = false; GetImport().GetTextImport()->SetStyleAndAttrs( GetImport(), GetImport().GetTextImport()->GetCursor(), "Standard", true ); } @@ -2859,7 +2859,7 @@ const SwStartNode *SwXMLTableContext::InsertTableSection( { SwDoc* pDoc = SwImport::GetDocFromXMLImport( GetSwImport() ); const SwEndNode *pEndNd = pPrevSttNd ? pPrevSttNd->EndOfSectionNode() - : pTableNode->EndOfSectionNode(); + : m_pTableNode->EndOfSectionNode(); // #i78921# - make code robust OSL_ENSURE( pDoc, "<SwXMLTableContext::InsertTableSection(..)> - no <pDoc> at <SwXTextCursor> instance - <SwXTextCurosr> doesn't seem to be registered at a <SwUnoCrsr> instance." ); if ( !pDoc ) @@ -2873,10 +2873,10 @@ const SwStartNode *SwXMLTableContext::InsertTableSection( pStNd = pDoc->GetNodes().MakeTextSection( aIdx, SwTableBoxStartNode, pColl ); // Consider the case that a table is defined without a row. - if( !pPrevSttNd && pBox1 != nullptr ) + if( !pPrevSttNd && m_pBox1 != nullptr ) { - pBox1->m_pStartNode = pStNd; + m_pBox1->m_pStartNode = pStNd; SwContentNode *pCNd = pDoc->GetNodes()[ pStNd->GetIndex() + 1 ] ->GetContentNode(); SwPosition aPos( *pCNd ); @@ -2903,10 +2903,10 @@ const SwStartNode *SwXMLTableContext::InsertTableSection( void SwXMLTableContext::EndElement() { - if( IsValid() && !xParentTable.Is() ) + if( IsValid() && !m_xParentTable.Is() ) { MakeTable(); - GetImport().GetTextImport()->SetCursor( xOldCursor ); + GetImport().GetTextImport()->SetCursor( m_xOldCursor ); } } diff --git a/sw/source/filter/xml/xmltbli.hxx b/sw/source/filter/xml/xmltbli.hxx index c3fad16..41f5d9e 100644 --- a/sw/source/filter/xml/xmltbli.hxx +++ b/sw/source/filter/xml/xmltbli.hxx @@ -47,8 +47,8 @@ namespace com { namespace sun { namespace star { class SwXMLTableContext : public XMLTextTableContext { - OUString aStyleName; - OUString aDfltCellStyleName; + OUString m_aStyleName; + OUString m_aDfltCellStyleName; //! Holds basic information about a column's width. struct ColumnWidthInfo { @@ -56,39 +56,39 @@ class SwXMLTableContext : public XMLTextTableContext bool isRelative; //!< True for a relative width, false for absolute. inline ColumnWidthInfo(sal_uInt16 wdth, bool isRel) : width(wdth), isRelative(isRel) {}; }; - std::vector<ColumnWidthInfo> aColumnWidths; - std::vector<OUString> *pColumnDefaultCellStyleNames; + std::vector<ColumnWidthInfo> m_aColumnWidths; + std::vector<OUString> *m_pColumnDefaultCellStyleNames; - css::uno::Reference< css::text::XTextCursor > xOldCursor; - css::uno::Reference< css::text::XTextContent > xTextContent; + css::uno::Reference< css::text::XTextCursor > m_xOldCursor; + css::uno::Reference< css::text::XTextContent > m_xTextContent; SwXMLTableRows_Impl * m_pRows; - SwTableNode *pTableNode; - SwTableBox *pBox1; - const SwStartNode *pSttNd1; + SwTableNode *m_pTableNode; + SwTableBox *m_pBox1; + const SwStartNode *m_pSttNd1; - SwTableBoxFormat *pBoxFormat; - SwTableLineFormat *pLineFormat; + SwTableBoxFormat *m_pBoxFormat; + SwTableLineFormat *m_pLineFormat; // hash map of shared format, indexed by the (XML) style name, // the column width, and protection flag typedef std::unordered_map<TableBoxIndex,SwTableBoxFormat*, TableBoxIndexHasher> map_BoxFormat; - map_BoxFormat* pSharedBoxFormats; + map_BoxFormat* m_pSharedBoxFormats; - SvXMLImportContextRef xParentTable; // if table is a sub table + SvXMLImportContextRef m_xParentTable; // if table is a sub table - SwXMLDDETableContext_Impl *pDDESource; + SwXMLDDETableContext_Impl *m_pDDESource; - bool bFirstSection : 1; - bool bRelWidth : 1; - bool bHasSubTables : 1; + bool m_bFirstSection : 1; + bool m_bRelWidth : 1; + bool m_bHasSubTables : 1; - sal_uInt16 nHeaderRows; - sal_uInt32 nCurRow; - sal_uInt32 nCurCol; - sal_Int32 nWidth; + sal_uInt16 m_nHeaderRows; + sal_uInt32 m_nCurRow; + sal_uInt32 m_nCurCol; + sal_Int32 m_nWidth; SwTableBox *NewTableBox( const SwStartNode *pStNd, SwTableLine *pUpper ); @@ -151,10 +151,10 @@ public: inline sal_uInt32 GetColumnCount() const; inline bool HasColumnDefaultCellStyleNames() const; - bool IsInsertCellPossible() const { return nCurCol < GetColumnCount(); } - bool IsInsertColPossible() const { return nCurCol < USHRT_MAX; } - bool IsInsertRowPossible() const { return nCurRow < USHRT_MAX; } - bool IsValid() const { return pTableNode != nullptr; } + bool IsInsertCellPossible() const { return m_nCurCol < GetColumnCount(); } + bool IsInsertColPossible() const { return m_nCurCol < USHRT_MAX; } + bool IsInsertRowPossible() const { return m_nCurRow < USHRT_MAX; } + bool IsValid() const { return m_pTableNode != nullptr; } void InsertCell( const OUString& rStyleName, sal_uInt32 nRowSpan=1U, sal_uInt32 nColSpan=1U, @@ -179,17 +179,17 @@ public: virtual void EndElement() override; - void SetHasSubTables( bool bNew ) { bHasSubTables = bNew; } + void SetHasSubTables( bool bNew ) { m_bHasSubTables = bNew; } }; inline SwXMLTableContext *SwXMLTableContext::GetParentTable() const { - return static_cast<SwXMLTableContext *>(&xParentTable); + return static_cast<SwXMLTableContext *>(&m_xParentTable); } inline sal_uInt32 SwXMLTableContext::GetColumnCount() const { - return aColumnWidths.size(); + return m_aColumnWidths.size(); } inline const SwStartNode *SwXMLTableContext::GetLastStartNode() const @@ -199,7 +199,7 @@ inline const SwStartNode *SwXMLTableContext::GetLastStartNode() const inline bool SwXMLTableContext::HasColumnDefaultCellStyleNames() const { - return pColumnDefaultCellStyleNames != nullptr; + return m_pColumnDefaultCellStyleNames != nullptr; } #endif commit 059f65b27b65ec86e5941a70e3e8ef89456a7c10 Author: Miklos Vajna <vmik...@collabora.co.uk> Date: Fri Nov 13 09:07:34 2015 +0100 sw: prefix members of SwLabPreview Change-Id: Ic4c9b6309aee6be51aa0b20a26e6dc28930a9879 diff --git a/sw/source/ui/envelp/labfmt.cxx b/sw/source/ui/envelp/labfmt.cxx index d8d8ef4..c92a0cf 100644 --- a/sw/source/ui/envelp/labfmt.cxx +++ b/sw/source/ui/envelp/labfmt.cxx @@ -100,17 +100,17 @@ void DrawArrow(vcl::RenderContext& rRenderContext, const Point &rP1, const Point SwLabPreview::SwLabPreview(vcl::Window* pParent) : Window(pParent, 0) - , aGrayColor(COL_LIGHTGRAY) - , aHDistStr(SW_RESSTR(STR_HDIST)) - , aVDistStr(SW_RESSTR(STR_VDIST)) - , aWidthStr(SW_RESSTR(STR_WIDTH)) - , aHeightStr(SW_RESSTR(STR_HEIGHT)) - , aLeftStr(SW_RESSTR(STR_LEFT)) - , aUpperStr(SW_RESSTR(STR_UPPER)) - , aColsStr(SW_RESSTR(STR_COLS)) - , aRowsStr(SW_RESSTR(STR_ROWS)) - , aPWidthStr(SW_RESSTR(STR_PWIDTH)) - , aPHeightStr(SW_RESSTR(STR_PHEIGHT)) + , m_aGrayColor(COL_LIGHTGRAY) + , m_aHDistStr(SW_RESSTR(STR_HDIST)) + , m_aVDistStr(SW_RESSTR(STR_VDIST)) + , m_aWidthStr(SW_RESSTR(STR_WIDTH)) + , m_aHeightStr(SW_RESSTR(STR_HEIGHT)) + , m_aLeftStr(SW_RESSTR(STR_LEFT)) + , m_aUpperStr(SW_RESSTR(STR_UPPER)) + , m_aColsStr(SW_RESSTR(STR_COLS)) + , m_aRowsStr(SW_RESSTR(STR_ROWS)) + , m_aPWidthStr(SW_RESSTR(STR_PWIDTH)) + , m_aPHeightStr(SW_RESSTR(STR_PHEIGHT)) { SetMapMode(MAP_PIXEL); @@ -125,16 +125,16 @@ SwLabPreview::SwLabPreview(vcl::Window* pParent) aFont.SetWeight(WEIGHT_NORMAL); SetFont(aFont); - lHDistWidth = GetTextWidth(aHDistStr ); - lVDistWidth = GetTextWidth(aVDistStr ); - lHeightWidth = GetTextWidth(aHeightStr); - lLeftWidth = GetTextWidth(aLeftStr ); - lUpperWidth = GetTextWidth(aUpperStr ); - lColsWidth = GetTextWidth(aColsStr ); - lPWidthWidth = GetTextWidth(aPWidthStr); - lPHeightWidth = GetTextWidth(aPHeightStr); - lXHeight = GetTextHeight(); - lXWidth = GetTextWidth(OUString('X')); + m_lHDistWidth = GetTextWidth(m_aHDistStr ); + m_lVDistWidth = GetTextWidth(m_aVDistStr ); + m_lHeightWidth = GetTextWidth(m_aHeightStr); + m_lLeftWidth = GetTextWidth(m_aLeftStr ); + m_lUpperWidth = GetTextWidth(m_aUpperStr ); + m_lColsWidth = GetTextWidth(m_aColsStr ); + m_lPWidthWidth = GetTextWidth(m_aPWidthStr); + m_lPHeightWidth = GetTextWidth(m_aPHeightStr); + m_lXHeight = GetTextHeight(); + m_lXWidth = GetTextWidth(OUString('X')); } Size SwLabPreview::GetOptimalSize() const @@ -152,7 +152,7 @@ void SwLabPreview::Paint(vcl::RenderContext& rRenderContext, const Rectangle&) const long lOutHPix = aSz.Height(); // Scale factor - const double fxpix = double(lOutWPix - (2 * (lLeftWidth + 15))) / double(lOutWPix); + const double fxpix = double(lOutWPix - (2 * (m_lLeftWidth + 15))) / double(lOutWPix); const long lOutWPix23 = long(double(lOutWPix) * fxpix); const long lOutHPix23 = long(double(lOutHPix) * fxpix); @@ -169,19 +169,19 @@ void SwLabPreview::Paint(vcl::RenderContext& rRenderContext, const Rectangle&) rRenderContext.SetBackground(Wallpaper(rWinColor)); rRenderContext.SetLineColor(rWinColor); - rRenderContext.SetFillColor(aGrayColor); + rRenderContext.SetFillColor(m_aGrayColor); vcl::Font aPaintFont(rRenderContext.GetFont()); aPaintFont.SetTransparent(false); rRenderContext.SetFont(aPaintFont); // size of region to be displayed - const long lDispW = aItem.m_lLeft + aItem.m_lHDist + ((aItem.m_nCols == 1) - ? aItem.m_lLeft - : ROUND(aItem.m_lHDist / 10.0)); + const long lDispW = m_aItem.m_lLeft + m_aItem.m_lHDist + ((m_aItem.m_nCols == 1) + ? m_aItem.m_lLeft + : ROUND(m_aItem.m_lHDist / 10.0)); - const long lDispH = aItem.m_lUpper + aItem.m_lVDist + ((aItem.m_nRows == 1) - ? aItem.m_lUpper - : ROUND(aItem.m_lVDist / 10.0)); + const long lDispH = m_aItem.m_lUpper + m_aItem.m_lVDist + ((m_aItem.m_nRows == 1) + ? m_aItem.m_lUpper + : ROUND(m_aItem.m_lVDist / 10.0)); // Scale factor const float fx = float(lOutWPix23) / std::max(1L, lDispW); @@ -194,12 +194,12 @@ void SwLabPreview::Paint(vcl::RenderContext& rRenderContext, const Rectangle&) const long lX0 = (lOutWPix - lOutlineW) / 2; const long lY0 = (lOutHPix - lOutlineH) / 2; - const long lX1 = lX0 + ROUND(f * aItem.m_lLeft ); - const long lY1 = lY0 + ROUND(f * aItem.m_lUpper); - const long lX2 = lX0 + ROUND(f * (aItem.m_lLeft + aItem.m_lWidth )); - const long lY2 = lY0 + ROUND(f * (aItem.m_lUpper + aItem.m_lHeight)); - const long lX3 = lX0 + ROUND(f * (aItem.m_lLeft + aItem.m_lHDist )); - const long lY3 = lY0 + ROUND(f * (aItem.m_lUpper + aItem.m_lVDist )); + const long lX1 = lX0 + ROUND(f * m_aItem.m_lLeft ); + const long lY1 = lY0 + ROUND(f * m_aItem.m_lUpper); + const long lX2 = lX0 + ROUND(f * (m_aItem.m_lLeft + m_aItem.m_lWidth )); + const long lY2 = lY0 + ROUND(f * (m_aItem.m_lUpper + m_aItem.m_lHeight)); + const long lX3 = lX0 + ROUND(f * (m_aItem.m_lLeft + m_aItem.m_lHDist )); + const long lY3 = lY0 + ROUND(f * (m_aItem.m_lUpper + m_aItem.m_lVDist )); // draw outline (area) rRenderContext.DrawRect(Rectangle(Point(lX0, lY0), Size(lOutlineW, lOutlineH))); @@ -208,86 +208,86 @@ void SwLabPreview::Paint(vcl::RenderContext& rRenderContext, const Rectangle&) rRenderContext.SetLineColor(rFieldTextColor); rRenderContext.DrawLine(Point(lX0, lY0), Point(lX0 + lOutlineW - 1, lY0)); // Up rRenderContext.DrawLine(Point(lX0, lY0), Point(lX0, lY0 + lOutlineH - 1)); // Left - if (aItem.m_nCols == 1) + if (m_aItem.m_nCols == 1) rRenderContext.DrawLine(Point(lX0 + lOutlineW - 1, lY0), Point(lX0 + lOutlineW - 1, lY0 + lOutlineH - 1)); // Right - if (aItem.m_nRows == 1) + if (m_aItem.m_nRows == 1) rRenderContext.DrawLine(Point(lX0, lY0 + lOutlineH - 1), Point(lX0 + lOutlineW - 1, lY0 + lOutlineH - 1)); // Down // Labels rRenderContext.SetClipRegion(vcl::Region(Rectangle(Point(lX0, lY0), Size(lOutlineW, lOutlineH)))); rRenderContext.SetFillColor(COL_LIGHTGRAYBLUE); - const sal_Int32 nRows = std::min<sal_Int32>(2, aItem.m_nRows); - const sal_Int32 nCols = std::min<sal_Int32>(2, aItem.m_nCols); + const sal_Int32 nRows = std::min<sal_Int32>(2, m_aItem.m_nRows); + const sal_Int32 nCols = std::min<sal_Int32>(2, m_aItem.m_nCols); for (sal_Int32 nRow = 0; nRow < nRows; ++nRow) for (sal_Int32 nCol = 0; nCol < nCols; ++nCol) - rRenderContext.DrawRect(Rectangle(Point(lX0 + ROUND(f * (aItem.m_lLeft + nCol * aItem.m_lHDist)), - lY0 + ROUND(f * (aItem.m_lUpper + nRow * aItem.m_lVDist))), - Size(ROUND(f * aItem.m_lWidth), - ROUND(f * aItem.m_lHeight)))); + rRenderContext.DrawRect(Rectangle(Point(lX0 + ROUND(f * (m_aItem.m_lLeft + nCol * m_aItem.m_lHDist)), + lY0 + ROUND(f * (m_aItem.m_lUpper + nRow * m_aItem.m_lVDist))), + Size(ROUND(f * m_aItem.m_lWidth), + ROUND(f * m_aItem.m_lHeight)))); rRenderContext.SetClipRegion(); // annotation: left border - if (aItem.m_lLeft) + if (m_aItem.m_lLeft) { long lX = (lX0 + lX1) / 2; DrawArrow(rRenderContext, Point(lX0, lY0 - 5), Point(lX1, lY0 - 5), false); DrawArrow(rRenderContext, Point(lX, lY0 - 10), Point(lX, lY0 - 5), true); - rRenderContext.DrawText(Point(lX1 - lLeftWidth, lY0 - 10 - lXHeight), aLeftStr); + rRenderContext.DrawText(Point(lX1 - m_lLeftWidth, lY0 - 10 - m_lXHeight), m_aLeftStr); } // annotation: upper border - if (aItem.m_lUpper) + if (m_aItem.m_lUpper) { DrawArrow(rRenderContext, Point(lX0 - 5, lY0), Point(lX0 - 5, lY1), false); - rRenderContext.DrawText(Point(lX0 - 10 - lUpperWidth, lY0 + ROUND(f*aItem.m_lUpper/2.0 - lXHeight/2.0)), aUpperStr); + rRenderContext.DrawText(Point(lX0 - 10 - m_lUpperWidth, lY0 + ROUND(f*m_aItem.m_lUpper/2.0 - m_lXHeight/2.0)), m_aUpperStr); } // annotation: width and height { - long lX = lX2 - lXWidth / 2 - lHeightWidth / 2; - long lY = lY1 + lXHeight; + long lX = lX2 - m_lXWidth / 2 - m_lHeightWidth / 2; + long lY = lY1 + m_lXHeight; rRenderContext.DrawLine(Point(lX1, lY), Point(lX2 - 1, lY)); rRenderContext.DrawLine(Point(lX, lY1), Point(lX, lY2 - 1)); - rRenderContext.DrawText(Point(lX1 + lXWidth / 2, lY - lXHeight / 2), aWidthStr); - rRenderContext.DrawText(Point(lX - lHeightWidth / 2, lY2 - lXHeight - lXHeight / 2), aHeightStr); + rRenderContext.DrawText(Point(lX1 + m_lXWidth / 2, lY - m_lXHeight / 2), m_aWidthStr); + rRenderContext.DrawText(Point(lX - m_lHeightWidth / 2, lY2 - m_lXHeight - m_lXHeight / 2), m_aHeightStr); } // annotation: horizontal gap - if (aItem.m_nCols > 1) + if (m_aItem.m_nCols > 1) { long lX = (lX1 + lX3) / 2; DrawArrow(rRenderContext, Point(lX1, lY0 - 5), Point(lX3, lY0 - 5), false); DrawArrow(rRenderContext, Point(lX, lY0 - 10), Point(lX, lY0 - 5), true); - rRenderContext.DrawText(Point(lX - lHDistWidth / 2, lY0 - 10 - lXHeight), aHDistStr); + rRenderContext.DrawText(Point(lX - m_lHDistWidth / 2, lY0 - 10 - m_lXHeight), m_aHDistStr); } // annotation: vertical gap - if (aItem.m_nRows > 1) + if (m_aItem.m_nRows > 1) { DrawArrow(rRenderContext, Point(lX0 - 5, lY1), Point(lX0 - 5, lY3), false); - rRenderContext.DrawText(Point(lX0 - 10 - lVDistWidth, lY1 + ROUND(f*aItem.m_lVDist/2.0 - lXHeight/2.0)), aVDistStr); + rRenderContext.DrawText(Point(lX0 - 10 - m_lVDistWidth, lY1 + ROUND(f*m_aItem.m_lVDist/2.0 - m_lXHeight/2.0)), m_aVDistStr); } // annotation: columns { long lY = lY0 + lOutlineH + 4; DrawArrow(rRenderContext, Point(lX0, lY), Point(lX0 + lOutlineW - 1, lY), true); - rRenderContext.DrawText(Point((lX0 + lX0 + lOutlineW - 1) / 2 - lColsWidth / 2, lY + 5), aColsStr); + rRenderContext.DrawText(Point((lX0 + lX0 + lOutlineW - 1) / 2 - m_lColsWidth / 2, lY + 5), m_aColsStr); } // annotation: lines { long lX = lX0 + lOutlineW + 4; DrawArrow(rRenderContext, Point(lX, lY0), Point(lX, lY0 + lOutlineH - 1), true); - rRenderContext.DrawText(Point(lX + 5, (lY0 + lY0 + lOutlineH - 1 - lXHeight / 2) / 2), aRowsStr); + rRenderContext.DrawText(Point(lX + 5, (lY0 + lY0 + lOutlineH - 1 - m_lXHeight / 2) / 2), m_aRowsStr); } } void SwLabPreview::UpdateItem(const SwLabItem& rItem) { - aItem = rItem; + m_aItem = rItem; Invalidate(); } diff --git a/sw/source/ui/envelp/labfmt.hxx b/sw/source/ui/envelp/labfmt.hxx index da68089..2e87bbd 100644 --- a/sw/source/ui/envelp/labfmt.hxx +++ b/sw/source/ui/envelp/labfmt.hxx @@ -27,32 +27,32 @@ class SwLabFormatPage; class SwLabPreview : public vcl::Window { - Color aGrayColor; - - OUString aHDistStr; - OUString aVDistStr; - OUString aWidthStr; - OUString aHeightStr; - OUString aLeftStr; - OUString aUpperStr; - OUString aColsStr; - OUString aRowsStr; - OUString aPWidthStr; - OUString aPHeightStr; - - long lHDistWidth; - long lVDistWidth; - long lHeightWidth; - long lLeftWidth; - long lUpperWidth; - long lColsWidth; - long lPWidthWidth; - long lPHeightWidth; - - long lXWidth; - long lXHeight; - - SwLabItem aItem; + Color m_aGrayColor; + + OUString m_aHDistStr; + OUString m_aVDistStr; + OUString m_aWidthStr; + OUString m_aHeightStr; + OUString m_aLeftStr; + OUString m_aUpperStr; + OUString m_aColsStr; + OUString m_aRowsStr; + OUString m_aPWidthStr; + OUString m_aPHeightStr; + + long m_lHDistWidth; + long m_lVDistWidth; + long m_lHeightWidth; + long m_lLeftWidth; + long m_lUpperWidth; + long m_lColsWidth; + long m_lPWidthWidth; + long m_lPHeightWidth; + + long m_lXWidth; + long m_lXHeight; + + SwLabItem m_aItem; virtual void Paint(vcl::RenderContext& rRenderContext, const Rectangle&) override; commit 7038c15e123eeff440df26ebc54dcf8c5455ebeb Author: Miklos Vajna <vmik...@collabora.co.uk> Date: Fri Nov 13 09:06:48 2015 +0100 sw: prefix members of SwParaPortion Change-Id: Id7d181c46b8504dbd8c82dd89009ef74015cc396 diff --git a/sw/source/core/text/porlay.cxx b/sw/source/core/text/porlay.cxx index ac8a87d..ae62a55 100644 --- a/sw/source/core/text/porlay.cxx +++ b/sw/source/core/text/porlay.cxx @@ -1955,16 +1955,16 @@ SwScriptInfo* SwScriptInfo::GetScriptInfo( const SwTextNode& rTNd, } SwParaPortion::SwParaPortion() - : bFlag00(false) - , bFlag11(false) - , bFlag12(false) - , bFlag13(false) - , bFlag14(false) - , bFlag15(false) - , bFlag16(false) + : m_bFlag00(false) + , m_bFlag11(false) + , m_bFlag12(false) + , m_bFlag13(false) + , m_bFlag14(false) + , m_bFlag15(false) + , m_bFlag16(false) { FormatReset(); - bFlys = bFootnoteNum = bMargin = false; + m_bFlys = m_bFootnoteNum = m_bMargin = false; SetWhichPor( POR_PARA ); } diff --git a/sw/source/core/text/porlay.hxx b/sw/source/core/text/porlay.hxx index e5640a7..2e090cc 100644 --- a/sw/source/core/text/porlay.hxx +++ b/sw/source/core/text/porlay.hxx @@ -230,33 +230,33 @@ public: class SwParaPortion : public SwLineLayout { // Area that needs repainting - SwRepaint aRepaint; + SwRepaint m_aRepaint; // Area that needs reformatting - SwCharRange aReformat; - SwScriptInfo aScriptInfo; + SwCharRange m_aReformat; + SwScriptInfo m_aScriptInfo; // Fraction aZoom; - long nDelta; + long m_nDelta; // If a SwTextFrm is locked, no changes occur to the formatting data (under // pLine) (compare with Orphans) - bool bFlys : 1; // Overlapping Flys? - bool bPrep : 1; // PREP_* - bool bPrepWidows : 1; // PREP_WIDOWS - bool bPrepAdjust : 1; // PREP_ADJUST_FRM - bool bPrepMustFit : 1; // PREP_MUST_FIT - bool bFollowField : 1; // We have a bit of field left for the Follow - - bool bFixLineHeight : 1; // Fixed line height - bool bFootnoteNum : 1; // contains a footnotenumberportion - bool bMargin : 1; // contains a hanging punctuation in the margin - - bool bFlag00 : 1; - bool bFlag11 : 1; - bool bFlag12 : 1; - bool bFlag13 : 1; - bool bFlag14 : 1; - bool bFlag15 : 1; - bool bFlag16 : 1; + bool m_bFlys : 1; // Overlapping Flys? + bool m_bPrep : 1; // PREP_* + bool m_bPrepWidows : 1; // PREP_WIDOWS + bool m_bPrepAdjust : 1; // PREP_ADJUST_FRM + bool m_bPrepMustFit : 1; // PREP_MUST_FIT + bool m_bFollowField : 1; // We have a bit of field left for the Follow + + bool m_bFixLineHeight : 1; // Fixed line height + bool m_bFootnoteNum : 1; // contains a footnotenumberportion + bool m_bMargin : 1; // contains a hanging punctuation in the margin + + bool m_bFlag00 : 1; + bool m_bFlag11 : 1; + bool m_bFlag12 : 1; + bool m_bFlag13 : 1; + bool m_bFlag14 : 1; + bool m_bFlag15 : 1; + bool m_bFlag16 : 1; public: SwParaPortion(); @@ -269,14 +269,14 @@ public: inline void ResetPreps(); // Get/Set methods - inline SwRepaint& GetRepaint() { return aRepaint; } - inline const SwRepaint& GetRepaint() const { return aRepaint; } - inline SwCharRange& GetReformat() { return aReformat; } - inline const SwCharRange& GetReformat() const { return aReformat; } - inline long& GetDelta() { return nDelta; } - inline const long& GetDelta() const { return nDelta; } - inline SwScriptInfo& GetScriptInfo() { return aScriptInfo; } - inline const SwScriptInfo& GetScriptInfo() const { return aScriptInfo; } + inline SwRepaint& GetRepaint() { return m_aRepaint; } + inline const SwRepaint& GetRepaint() const { return m_aRepaint; } + inline SwCharRange& GetReformat() { return m_aReformat; } + inline const SwCharRange& GetReformat() const { return m_aReformat; } + inline long& GetDelta() { return m_nDelta; } + inline const long& GetDelta() const { return m_nDelta; } + inline SwScriptInfo& GetScriptInfo() { return m_aScriptInfo; } + inline const SwScriptInfo& GetScriptInfo() const { return m_aScriptInfo; } // For SwTextFrm::Format: returns the paragraph's current length sal_Int32 GetParLen() const; @@ -285,27 +285,27 @@ public: bool UpdateQuoVadis( const OUString &rQuo ); // Flags - inline void SetFly( const bool bNew = true ) { bFlys = bNew; } - inline bool HasFly() const { return bFlys; } + inline void SetFly( const bool bNew = true ) { m_bFlys = bNew; } + inline bool HasFly() const { return m_bFlys; } // Preps - inline void SetPrep( const bool bNew = true ) { bPrep = bNew; } - inline bool IsPrep() const { return bPrep; } - inline void SetPrepWidows( const bool bNew = true ) { bPrepWidows = bNew; } - inline bool IsPrepWidows() const { return bPrepWidows; } - inline void SetPrepMustFit( const bool bNew = true ) { bPrepMustFit = bNew; } - inline bool IsPrepMustFit() const { return bPrepMustFit; } - inline void SetPrepAdjust( const bool bNew = true ) { bPrepAdjust = bNew; } - inline bool IsPrepAdjust() const { return bPrepAdjust; } - inline void SetFollowField( const bool bNew = true ) { bFollowField = bNew; } - inline bool IsFollowField() const { return bFollowField; } - inline void SetFixLineHeight( const bool bNew = true ) { bFixLineHeight = bNew; } - inline bool IsFixLineHeight() const { return bFixLineHeight; } - - inline void SetFootnoteNum( const bool bNew = true ) { bFootnoteNum = bNew; } - inline bool IsFootnoteNum() const { return bFootnoteNum; } - inline void SetMargin( const bool bNew = true ) { bMargin = bNew; } - inline bool IsMargin() const { return bMargin; } + inline void SetPrep( const bool bNew = true ) { m_bPrep = bNew; } + inline bool IsPrep() const { return m_bPrep; } + inline void SetPrepWidows( const bool bNew = true ) { m_bPrepWidows = bNew; } + inline bool IsPrepWidows() const { return m_bPrepWidows; } + inline void SetPrepMustFit( const bool bNew = true ) { m_bPrepMustFit = bNew; } + inline bool IsPrepMustFit() const { return m_bPrepMustFit; } + inline void SetPrepAdjust( const bool bNew = true ) { m_bPrepAdjust = bNew; } + inline bool IsPrepAdjust() const { return m_bPrepAdjust; } + inline void SetFollowField( const bool bNew = true ) { m_bFollowField = bNew; } + inline bool IsFollowField() const { return m_bFollowField; } + inline void SetFixLineHeight( const bool bNew = true ) { m_bFixLineHeight = bNew; } + inline bool IsFixLineHeight() const { return m_bFixLineHeight; } + + inline void SetFootnoteNum( const bool bNew = true ) { m_bFootnoteNum = bNew; } + inline bool IsFootnoteNum() const { return m_bFootnoteNum; } + inline void SetMargin( const bool bNew = true ) { m_bMargin = bNew; } + inline bool IsMargin() const { return m_bMargin; } // Set nErgo in the QuoVadisPortion void SetErgoSumNum( const OUString &rErgo ); @@ -333,19 +333,19 @@ inline SwLineLayout::SwLineLayout() inline void SwParaPortion::ResetPreps() { - bPrep = bPrepWidows = bPrepAdjust = bPrepMustFit = false; + m_bPrep = m_bPrepWidows = m_bPrepAdjust = m_bPrepMustFit = false; } inline void SwParaPortion::FormatReset() { - nDelta = 0; - aReformat = SwCharRange(0, COMPLETE_STRING); + m_nDelta = 0; + m_aReformat = SwCharRange(0, COMPLETE_STRING); // bFlys needs to be retained in SwTextFrm::_Format() so that empty // paragraphs that needed to avoid Frames with no flow, reformat // when the Frame disappears from the Area // bFlys = false; ResetPreps(); - bFollowField = bFixLineHeight = bMargin = false; + m_bFollowField = m_bFixLineHeight = m_bMargin = false; } inline SwLinePortion *SwLineLayout::GetFirstPortion() const _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits