diff options
Diffstat (limited to 'sw/source/core/table/swtable.cxx')
-rw-r--r-- | sw/source/core/table/swtable.cxx | 214 |
1 files changed, 107 insertions, 107 deletions
diff --git a/sw/source/core/table/swtable.cxx b/sw/source/core/table/swtable.cxx index b0363a4725f2..bfd91b614bd9 100644 --- a/sw/source/core/table/swtable.cxx +++ b/sw/source/core/table/swtable.cxx @@ -296,8 +296,8 @@ static void lcl_ModifyLines( SwTableLines &rLines, const long nOld, for( size_t i = 0; i < rFormatArr.size(); ++i ) { SwFormat* pFormat = rFormatArr[i]; - const SwTwips nBox = lcl_MulDiv64<SwTwips>(pFormat->GetFrmSize().GetWidth(), nNew, nOld); - SwFormatFrmSize aNewBox( ATT_VAR_SIZE, nBox, 0 ); + const SwTwips nBox = lcl_MulDiv64<SwTwips>(pFormat->GetFrameSize().GetWidth(), nNew, nOld); + SwFormatFrameSize aNewBox( ATT_VAR_SIZE, nBox, 0 ); pFormat->LockModify(); pFormat->SetFormatAttr( aNewBox ); pFormat->UnlockModify(); @@ -320,7 +320,7 @@ static void lcl_ModifyBoxes( SwTableBoxes &rBoxes, const long nOld, } // Adjust the box SwFrameFormat *pFormat = rBox.GetFrameFormat(); - sal_uInt64 nBox = pFormat->GetFrmSize().GetWidth(); + sal_uInt64 nBox = pFormat->GetFrameSize().GetWidth(); nOriginalSum += nBox; nBox *= nNew; nBox /= nOld; @@ -333,7 +333,7 @@ static void lcl_ModifyBoxes( SwTableBoxes &rBoxes, const long nOld, { nBox = nWishedSum; pFormat = rBox.ClaimFrameFormat(); - SwFormatFrmSize aNewBox( ATT_VAR_SIZE, static_cast< SwTwips >(nBox), 0 ); + SwFormatFrameSize aNewBox( ATT_VAR_SIZE, static_cast< SwTwips >(nBox), 0 ); pFormat->LockModify(); pFormat->SetFormatAttr( aNewBox ); pFormat->UnlockModify(); @@ -350,20 +350,20 @@ void SwTable::Modify( const SfxPoolItem* pOld, const SfxPoolItem *pNew ) { // catch SSize changes, to adjust the lines/boxes const sal_uInt16 nWhich = pOld ? pOld->Which() : pNew ? pNew->Which() : 0 ; - const SwFormatFrmSize* pNewSize = nullptr, *pOldSize = nullptr; + const SwFormatFrameSize* pNewSize = nullptr, *pOldSize = nullptr; if( RES_ATTRSET_CHG == nWhich ) { if (pOld && pNew && SfxItemState::SET == static_cast<const SwAttrSetChg*>(pNew)->GetChgSet()->GetItemState( RES_FRM_SIZE, false, reinterpret_cast<const SfxPoolItem**>(&pNewSize))) { - pOldSize = &static_cast<const SwAttrSetChg*>(pOld)->GetChgSet()->GetFrmSize(); + pOldSize = &static_cast<const SwAttrSetChg*>(pOld)->GetChgSet()->GetFrameSize(); } } else if( RES_FRM_SIZE == nWhich ) { - pOldSize = static_cast<const SwFormatFrmSize*>(pOld); - pNewSize = static_cast<const SwFormatFrmSize*>(pNew); + pOldSize = static_cast<const SwFormatFrameSize*>(pOld); + pNewSize = static_cast<const SwFormatFrameSize*>(pNew); } else CheckRegistration( pOld, pNew ); @@ -395,7 +395,7 @@ static void lcl_SortedTabColInsert( SwTabCols &rToFill, const SwTableBox *pBox, const SwFrameFormat *pTabFormat, const bool bHidden, const bool bRefreshHidden ) { - const long nWish = pTabFormat->GetFrmSize().GetWidth(); + const long nWish = pTabFormat->GetFrameSize().GetWidth(); OSL_ENSURE(nWish, "weird <= 0 width frmfrm"); // The value for the left edge of the box is calculated from the @@ -415,7 +415,7 @@ static void lcl_SortedTabColInsert( SwTabCols &rToFill, const SwTableBox *pBox, const SwTableBoxes &rBoxes = pLine->GetTabBoxes(); for ( size_t i = 0; i < rBoxes.size(); ++i ) { - const SwTwips nWidth = rBoxes[i]->GetFrameFormat()->GetFrmSize().GetWidth(); + const SwTwips nWidth = rBoxes[i]->GetFrameFormat()->GetFrameSize().GetWidth(); nSum += nWidth; const long nTmp = lcl_MulDiv64<long>(nSum, nAct, nWish); @@ -674,7 +674,7 @@ static void lcl_ProcessBoxSet( SwTableBox *pBox, Parm &rParm ) for ( size_t i = 0; (i < rBoxes.size()) && (rBoxes[i] != pCur); ++i) { nLeft += lcl_MulDiv64<long>( - rBoxes[i]->GetFrameFormat()->GetFrmSize().GetWidth(), + rBoxes[i]->GetFrameFormat()->GetFrameSize().GetWidth(), nOldAct, rParm.nOldWish); } pCur = pLine->GetUpper(); @@ -686,7 +686,7 @@ static void lcl_ProcessBoxSet( SwTableBox *pBox, Parm &rParm ) { // Right edge is left edge plus width. const long nWidth = lcl_MulDiv64<long>( - pBox->GetFrameFormat()->GetFrmSize().GetWidth(), + pBox->GetFrameFormat()->GetFrameSize().GetWidth(), nOldAct, rParm.nOldWish); const long nRight = nLeft + nWidth; size_t nLeftPos = 0; @@ -720,7 +720,7 @@ static void lcl_ProcessBoxSet( SwTableBox *pBox, Parm &rParm ) { // Calculate the difference to the edge touching the first box. const long nWidth = lcl_MulDiv64<long>( - pBox->GetFrameFormat()->GetFrmSize().GetWidth(), + pBox->GetFrameFormat()->GetFrameSize().GetWidth(), nOldAct, rParm.nOldWish); const long nTmp = nWidth + rParm.rOld.GetLeft(); for ( size_t i = 0; i < rParm.rOld.Count(); ++i ) @@ -764,11 +764,11 @@ static void lcl_ProcessBoxSet( SwTableBox *pBox, Parm &rParm ) // Adjust the box and all superiors by the difference amount. while ( pBox ) { - SwFormatFrmSize aFormatFrmSize( pBox->GetFrameFormat()->GetFrmSize() ); - aFormatFrmSize.SetWidth( aFormatFrmSize.GetWidth() + nDiff ); - if ( aFormatFrmSize.GetWidth() < 0 ) - aFormatFrmSize.SetWidth( -aFormatFrmSize.GetWidth() ); - rParm.aShareFormats.SetSize( *pBox, aFormatFrmSize ); + SwFormatFrameSize aFormatFrameSize( pBox->GetFrameFormat()->GetFrameSize() ); + aFormatFrameSize.SetWidth( aFormatFrameSize.GetWidth() + nDiff ); + if ( aFormatFrameSize.GetWidth() < 0 ) + aFormatFrameSize.SetWidth( -aFormatFrameSize.GetWidth() ); + rParm.aShareFormats.SetSize( *pBox, aFormatFrameSize ); // The outer cells of the last row are responsible to adjust a surrounding cell. // Last line check: @@ -830,10 +830,10 @@ static void lcl_AdjustBox( SwTableBox *pBox, const long nDiff, Parm &rParm ) ::lcl_AdjustLines( pBox->GetTabLines(), nDiff, rParm ); // Adjust the size of the box. - SwFormatFrmSize aFormatFrmSize( pBox->GetFrameFormat()->GetFrmSize() ); - aFormatFrmSize.SetWidth( aFormatFrmSize.GetWidth() + nDiff ); + SwFormatFrameSize aFormatFrameSize( pBox->GetFrameFormat()->GetFrameSize() ); + aFormatFrameSize.SetWidth( aFormatFrameSize.GetWidth() + nDiff ); - rParm.aShareFormats.SetSize( *pBox, aFormatFrmSize ); + rParm.aShareFormats.SetSize( *pBox, aFormatFrameSize ); } void SwTable::SetTabCols( const SwTabCols &rNew, const SwTabCols &rOld, @@ -855,7 +855,7 @@ void SwTable::SetTabCols( const SwTabCols &rNew, const SwTabCols &rOld, // For the size adjustment, we must not make use of the Modify, since that'd // adjust all boxes, which we really don't want. SwFrameFormat *pFormat = GetFrameFormat(); - aParm.nOldWish = aParm.nNewWish = pFormat->GetFrmSize().GetWidth(); + aParm.nOldWish = aParm.nNewWish = pFormat->GetFrameSize().GetWidth(); if ( (rOld.GetLeft() != rNew.GetLeft()) || (rOld.GetRight()!= rNew.GetRight()) ) { @@ -915,7 +915,7 @@ void SwTable::SetTabCols( const SwTabCols &rNew, const SwTabCols &rOld, aParm.nNewWish += nTabDiff; if ( aParm.nNewWish < 0 ) aParm.nNewWish = USHRT_MAX; // Oops! Have to roll back. - SwFormatFrmSize aSz( pFormat->GetFrmSize() ); + SwFormatFrameSize aSz( pFormat->GetFrameSize() ); if ( aSz.GetWidth() != aParm.nNewWish ) { aSz.SetWidth( aParm.nNewWish ); @@ -984,7 +984,7 @@ void SwTable::SetTabCols( const SwTabCols &rNew, const SwTabCols &rOld, #ifdef DBG_UTIL { // do some checking for correct table widths - SwTwips nSize = GetFrameFormat()->GetFrmSize().GetWidth(); + SwTwips nSize = GetFrameFormat()->GetFrameSize().GetWidth(); for (size_t n = 0; n < m_aLines.size(); ++n) { _CheckBoxWidth( *m_aLines[ n ], nSize ); @@ -1008,7 +1008,7 @@ static void lcl_AdjustWidthsInLine( SwTableLine* pLine, ChangeList& rOldNew, for( size_t i = 0; i < nCount; ++i ) { SwTableBox* pBox = pLine->GetTabBoxes()[i]; - SwTwips nWidth = pBox->GetFrameFormat()->GetFrmSize().GetWidth(); + SwTwips nWidth = pBox->GetFrameFormat()->GetFrameSize().GetWidth(); SwTwips nNewWidth = nWidth - nRest; nRest = 0; nBorder += nWidth; @@ -1038,9 +1038,9 @@ static void lcl_AdjustWidthsInLine( SwTableLine* pLine, ChangeList& rOldNew, nRest += 1 - nNewWidth; nNewWidth = 1; } - SwFormatFrmSize aFormatFrmSize( pBox->GetFrameFormat()->GetFrmSize() ); - aFormatFrmSize.SetWidth( nNewWidth ); - rParm.aShareFormats.SetSize( *pBox, aFormatFrmSize ); + SwFormatFrameSize aFormatFrameSize( pBox->GetFrameFormat()->GetFrameSize() ); + aFormatFrameSize.SetWidth( nNewWidth ); + rParm.aShareFormats.SetSize( *pBox, aFormatFrameSize ); } } } @@ -1071,7 +1071,7 @@ static void lcl_CalcNewWidths( std::list<sal_uInt16> &rSpanPos, ChangeList& rCha for( size_t nCurrBox = 0; nCurrBox < nCount; ++nCurrBox ) { SwTableBox* pBox = pLine->GetTabBoxes()[nCurrBox]; - SwTwips nCurrWidth = pBox->GetFrameFormat()->GetFrmSize().GetWidth(); + SwTwips nCurrWidth = pBox->GetFrameFormat()->GetFrameSize().GetWidth(); const long nRowSpan = pBox->getRowSpan(); const bool bCurrRowSpan = bTop ? nRowSpan < 0 : ( nRowSpan > 1 || nRowSpan < -1 ); @@ -1431,11 +1431,11 @@ SwTableBox* SwTable::GetTableBox( sal_uLong nSttIdx ) if ( pTableNd && pTableNd->GetTable().GetFrameFormat() ) pModify = pTableNd->GetTable().GetFrameFormat(); - SwFrm* pFrm = pModify ? SwIterator<SwFrm,SwModify>(*pModify).First() : nullptr; - while ( pFrm && !pFrm->IsCellFrm() ) - pFrm = pFrm->GetUpper(); - if ( pFrm ) - pRet = const_cast<SwTableBox*>(static_cast<SwCellFrm*>(pFrm)->GetTabBox()); + SwFrame* pFrame = pModify ? SwIterator<SwFrame,SwModify>(*pModify).First() : nullptr; + while ( pFrame && !pFrame->IsCellFrame() ) + pFrame = pFrame->GetUpper(); + if ( pFrame ) + pRet = const_cast<SwTableBox*>(static_cast<SwCellFrame*>(pFrame)->GetTabBox()); } // In case the layout doesn't exist yet or anything else goes wrong. @@ -1506,11 +1506,11 @@ SwFrameFormat* SwTableLine::ClaimFrameFormat() SwTableLineFormat *pNewFormat = pRet->GetDoc()->MakeTableLineFormat(); *pNewFormat = *pRet; - // register SwRowFrms that know me as clients at the new Format - SwIterator<SwRowFrm,SwFormat> aFrmIter( *pRet ); - for( SwRowFrm* pFrm = aFrmIter.First(); pFrm; pFrm = aFrmIter.Next() ) - if( pFrm->GetTabLine() == this ) - pFrm->RegisterToFormat( *pNewFormat ); + // register SwRowFrames that know me as clients at the new Format + SwIterator<SwRowFrame,SwFormat> aFrameIter( *pRet ); + for( SwRowFrame* pFrame = aFrameIter.First(); pFrame; pFrame = aFrameIter.Next() ) + if( pFrame->GetTabLine() == this ) + pFrame->RegisterToFormat( *pNewFormat ); // register myself pNewFormat->Add( this ); @@ -1525,10 +1525,10 @@ SwFrameFormat* SwTableLine::ClaimFrameFormat() void SwTableLine::ChgFrameFormat( SwTableLineFormat *pNewFormat ) { SwFrameFormat *pOld = GetFrameFormat(); - SwIterator<SwRowFrm,SwFormat> aIter( *pOld ); + SwIterator<SwRowFrame,SwFormat> aIter( *pOld ); - // First, re-register the Frms. - for( SwRowFrm* pRow = aIter.First(); pRow; pRow = aIter.Next() ) + // First, re-register the Frames. + for( SwRowFrame* pRow = aIter.First(); pRow; pRow = aIter.Next() ) { if( pRow->GetTabLine() == this ) { @@ -1537,11 +1537,11 @@ void SwTableLine::ChgFrameFormat( SwTableLineFormat *pNewFormat ) pRow->InvalidateSize(); pRow->_InvalidatePrt(); pRow->SetCompletePaint(); - pRow->ReinitializeFrmSizeAttrFlags(); + pRow->ReinitializeFrameSizeAttrFlags(); // #i35063# // consider 'split row allowed' attribute - SwTabFrm* pTab = pRow->FindTabFrm(); + SwTabFrame* pTab = pRow->FindTabFrame(); bool bInFollowFlowRow = false; const bool bInFirstNonHeadlineRow = pTab->IsFollow() && pRow == pTab->GetFirstNonHeadlineRow(); @@ -1570,18 +1570,18 @@ SwTwips SwTableLine::GetTableLineHeight( bool& bLayoutAvailable ) const { SwTwips nRet = 0; bLayoutAvailable = false; - SwIterator<SwRowFrm,SwFormat> aIter( *GetFrameFormat() ); + SwIterator<SwRowFrame,SwFormat> aIter( *GetFrameFormat() ); // A row could appear several times in headers/footers so only one chain of master/follow tables // will be accepted... - const SwTabFrm* pChain = nullptr; // My chain - for( SwRowFrm* pLast = aIter.First(); pLast; pLast = aIter.Next() ) + const SwTabFrame* pChain = nullptr; // My chain + for( SwRowFrame* pLast = aIter.First(); pLast; pLast = aIter.Next() ) { if( pLast->GetTabLine() == this ) { - const SwTabFrm* pTab = pLast->FindTabFrm(); + const SwTabFrame* pTab = pLast->FindTabFrame(); bLayoutAvailable = ( pTab && pTab->IsVertical() ) ? - ( 0 < pTab->Frm().Height() ) : - ( 0 < pTab->Frm().Width() ); + ( 0 < pTab->Frame().Height() ) : + ( 0 < pTab->Frame().Width() ); // The first one defines the chain, if a chain is defined, only members of the chain // will be added. @@ -1589,9 +1589,9 @@ SwTwips SwTableLine::GetTableLineHeight( bool& bLayoutAvailable ) const { pChain = pTab; // defines my chain (even it is already) if( pTab->IsVertical() ) - nRet += pLast->Frm().Width(); + nRet += pLast->Frame().Width(); else - nRet += pLast->Frm().Height(); + nRet += pLast->Frame().Height(); // Optimization, if there are no master/follows in my chain, nothing more to add if( !pTab->HasFollow() && !pTab->IsFollow() ) break; @@ -1743,9 +1743,9 @@ SwFrameFormat* SwTableBox::ClaimFrameFormat() pNewFormat->ResetFormatAttr( RES_BOXATR_FORMULA, RES_BOXATR_VALUE ); pNewFormat->UnlockModify(); - // re-register SwCellFrm objects that know me - SwIterator<SwCellFrm,SwFormat> aFrmIter( *pRet ); - for( SwCellFrm* pCell = aFrmIter.First(); pCell; pCell = aFrmIter.Next() ) + // re-register SwCellFrame objects that know me + SwIterator<SwCellFrame,SwFormat> aFrameIter( *pRet ); + for( SwCellFrame* pCell = aFrameIter.First(); pCell; pCell = aFrameIter.Next() ) if( pCell->GetTabBox() == this ) pCell->RegisterToFormat( *pNewFormat ); @@ -1761,10 +1761,10 @@ SwFrameFormat* SwTableBox::ClaimFrameFormat() void SwTableBox::ChgFrameFormat( SwTableBoxFormat* pNewFormat ) { SwFrameFormat *pOld = GetFrameFormat(); - SwIterator<SwCellFrm,SwFormat> aIter( *pOld ); + SwIterator<SwCellFrame,SwFormat> aIter( *pOld ); - // First, re-register the Frms. - for( SwCellFrm* pCell = aIter.First(); pCell; pCell = aIter.Next() ) + // First, re-register the Frames. + for( SwCellFrame* pCell = aIter.First(); pCell; pCell = aIter.Next() ) { if( pCell->GetTabBox() == this ) { @@ -1779,10 +1779,10 @@ void SwTableBox::ChgFrameFormat( SwTableBoxFormat* pNewFormat ) // make sure that the row will be formatted, in order // to have the correct Get(Top|Bottom)MarginForLowers values // set at the row. - const SwTabFrm* pTab = pCell->FindTabFrm(); + const SwTabFrame* pTab = pCell->FindTabFrame(); if ( pTab && pTab->IsCollapsingBorders() ) { - SwFrm* pRow = pCell->GetUpper(); + SwFrame* pRow = pCell->GetUpper(); pRow->_InvalidateSize(); pRow->_InvalidatePrt(); } @@ -1927,7 +1927,7 @@ bool SwTable::GetInfo( SfxPoolItem& rInfo ) const break; case RES_CONTENT_VISIBLE: - static_cast<SwPtrMsgPoolItem&>(rInfo).pObject = SwIterator<SwFrm,SwFormat>( *GetFrameFormat() ).First(); + static_cast<SwPtrMsgPoolItem&>(rInfo).pObject = SwIterator<SwFrame,SwFormat>( *GetFrameFormat() ).First(); return false; } return true; @@ -2566,14 +2566,14 @@ void SwTableBox::ActualiseValueBox() struct SwTableCellInfo::Impl { const SwTable * m_pTable; - const SwCellFrm * m_pCellFrm; - const SwTabFrm * m_pTabFrm; + const SwCellFrame * m_pCellFrame; + const SwTabFrame * m_pTabFrame; typedef ::std::set<const SwTableBox *> TableBoxes_t; TableBoxes_t m_HandledTableBoxes; public: Impl() - : m_pTable(nullptr), m_pCellFrm(nullptr), m_pTabFrm(nullptr) + : m_pTable(nullptr), m_pCellFrame(nullptr), m_pTabFrame(nullptr) { } @@ -2583,42 +2583,42 @@ public: { m_pTable = pTable; SwFrameFormat * pFrameFormat = m_pTable->GetFrameFormat(); - m_pTabFrm = SwIterator<SwTabFrm,SwFormat>(*pFrameFormat).First(); - if (m_pTabFrm && m_pTabFrm->IsFollow()) - m_pTabFrm = m_pTabFrm->FindMaster(true); + m_pTabFrame = SwIterator<SwTabFrame,SwFormat>(*pFrameFormat).First(); + if (m_pTabFrame && m_pTabFrame->IsFollow()) + m_pTabFrame = m_pTabFrame->FindMaster(true); } - const SwCellFrm * getCellFrm() const { return m_pCellFrm; } + const SwCellFrame * getCellFrame() const { return m_pCellFrame; } - const SwFrm * getNextFrmInTable(const SwFrm * pFrm); - const SwCellFrm * getNextCellFrm(const SwFrm * pFrm); - const SwCellFrm * getNextTableBoxsCellFrm(const SwFrm * pFrm); + const SwFrame * getNextFrameInTable(const SwFrame * pFrame); + const SwCellFrame * getNextCellFrame(const SwFrame * pFrame); + const SwCellFrame * getNextTableBoxsCellFrame(const SwFrame * pFrame); bool getNext(); }; -const SwFrm * SwTableCellInfo::Impl::getNextFrmInTable(const SwFrm * pFrm) +const SwFrame * SwTableCellInfo::Impl::getNextFrameInTable(const SwFrame * pFrame) { - const SwFrm * pResult = nullptr; + const SwFrame * pResult = nullptr; - if (((! pFrm->IsTabFrm()) || pFrm == m_pTabFrm) && pFrm->GetLower()) - pResult = pFrm->GetLower(); - else if (pFrm->GetNext()) - pResult = pFrm->GetNext(); + if (((! pFrame->IsTabFrame()) || pFrame == m_pTabFrame) && pFrame->GetLower()) + pResult = pFrame->GetLower(); + else if (pFrame->GetNext()) + pResult = pFrame->GetNext(); else { - while (pFrm->GetUpper() != nullptr) + while (pFrame->GetUpper() != nullptr) { - pFrm = pFrm->GetUpper(); + pFrame = pFrame->GetUpper(); - if (pFrm->IsTabFrm()) + if (pFrame->IsTabFrame()) { - m_pTabFrm = static_cast<const SwTabFrm *>(pFrm)->GetFollow(); - pResult = m_pTabFrm; + m_pTabFrame = static_cast<const SwTabFrame *>(pFrame)->GetFollow(); + pResult = m_pTabFrame; break; } - else if (pFrm->GetNext()) + else if (pFrame->GetNext()) { - pResult = pFrm->GetNext(); + pResult = pFrame->GetNext(); break; } } @@ -2627,15 +2627,15 @@ const SwFrm * SwTableCellInfo::Impl::getNextFrmInTable(const SwFrm * pFrm) return pResult; } -const SwCellFrm * SwTableCellInfo::Impl::getNextCellFrm(const SwFrm * pFrm) +const SwCellFrame * SwTableCellInfo::Impl::getNextCellFrame(const SwFrame * pFrame) { - const SwCellFrm * pResult = nullptr; + const SwCellFrame * pResult = nullptr; - while ((pFrm = getNextFrmInTable(pFrm)) != nullptr) + while ((pFrame = getNextFrameInTable(pFrame)) != nullptr) { - if (pFrm->IsCellFrm()) + if (pFrame->IsCellFrame()) { - pResult = static_cast<const SwCellFrm *>(pFrm); + pResult = static_cast<const SwCellFrame *>(pFrame); break; } } @@ -2643,19 +2643,19 @@ const SwCellFrm * SwTableCellInfo::Impl::getNextCellFrm(const SwFrm * pFrm) return pResult; } -const SwCellFrm * SwTableCellInfo::Impl::getNextTableBoxsCellFrm(const SwFrm * pFrm) +const SwCellFrame * SwTableCellInfo::Impl::getNextTableBoxsCellFrame(const SwFrame * pFrame) { - const SwCellFrm * pResult = nullptr; + const SwCellFrame * pResult = nullptr; - while ((pFrm = getNextCellFrm(pFrm)) != nullptr) + while ((pFrame = getNextCellFrame(pFrame)) != nullptr) { - const SwCellFrm * pCellFrm = static_cast<const SwCellFrm *>(pFrm); - const SwTableBox * pTabBox = pCellFrm->GetTabBox(); + const SwCellFrame * pCellFrame = static_cast<const SwCellFrame *>(pFrame); + const SwTableBox * pTabBox = pCellFrame->GetTabBox(); TableBoxes_t::const_iterator aIt = m_HandledTableBoxes.find(pTabBox); if (aIt == m_HandledTableBoxes.end()) { - pResult = pCellFrm; + pResult = pCellFrame; m_HandledTableBoxes.insert(pTabBox); break; } @@ -2664,22 +2664,22 @@ const SwCellFrm * SwTableCellInfo::Impl::getNextTableBoxsCellFrm(const SwFrm * p return pResult; } -const SwCellFrm * SwTableCellInfo::getCellFrm() const +const SwCellFrame * SwTableCellInfo::getCellFrame() const { - return m_pImpl->getCellFrm(); + return m_pImpl->getCellFrame(); } bool SwTableCellInfo::Impl::getNext() { - if (m_pCellFrm == nullptr) + if (m_pCellFrame == nullptr) { - if (m_pTabFrm != nullptr) - m_pCellFrm = Impl::getNextTableBoxsCellFrm(m_pTabFrm); + if (m_pTabFrame != nullptr) + m_pCellFrame = Impl::getNextTableBoxsCellFrame(m_pTabFrame); } else - m_pCellFrm = Impl::getNextTableBoxsCellFrm(m_pCellFrm); + m_pCellFrame = Impl::getNextTableBoxsCellFrame(m_pCellFrame); - return m_pCellFrm != nullptr; + return m_pCellFrame != nullptr; } SwTableCellInfo::SwTableCellInfo(const SwTable * pTable) @@ -2701,8 +2701,8 @@ SwRect SwTableCellInfo::getRect() const { SwRect aRet; - if (getCellFrm() != nullptr) - aRet = getCellFrm()->Frm(); + if (getCellFrame() != nullptr) + aRet = getCellFrame()->Frame(); return aRet; } @@ -2711,8 +2711,8 @@ const SwTableBox * SwTableCellInfo::getTableBox() const { const SwTableBox * pRet = nullptr; - if (getCellFrm() != nullptr) - pRet = getCellFrm()->GetTabBox(); + if (getCellFrame() != nullptr) + pRet = getCellFrame()->GetTabBox(); return pRet; } @@ -2726,7 +2726,7 @@ bool SwTable::HasLayout() const { const SwFrameFormat* pFrameFormat = GetFrameFormat(); //a table in a clipboard document doesn't have any layout information - return pFrameFormat && SwIterator<SwTabFrm,SwFormat>(*pFrameFormat).First(); + return pFrameFormat && SwIterator<SwTabFrame,SwFormat>(*pFrameFormat).First(); } void SwTableLine::RegisterToFormat( SwFormat& rFormat ) |