summaryrefslogtreecommitdiff
path: root/sw/source/core/layout/tabfrm.cxx
diff options
context:
space:
mode:
authorArmin Le Grand <Armin.Le.Grand@cib.de>2017-10-26 10:54:03 +0200
committerArmin Le Grand <Armin.Le.Grand@cib.de>2017-10-30 12:13:16 +0100
commit75d4e779e408bd532ddeda2b18923806c920b4a7 (patch)
tree7c24e614b8c54d38f650b7ceb96f07beeeb446f8 /sw/source/core/layout/tabfrm.cxx
parentf6edddfa230d6478571ef67ebdc506c54f589648 (diff)
Adapted to get/setSwFrame and get/setSwPrint
Change-Id: I6cce40ec49dd5bd32d94fe06b9d2dabd368448be
Diffstat (limited to 'sw/source/core/layout/tabfrm.cxx')
-rw-r--r--sw/source/core/layout/tabfrm.cxx350
1 files changed, 175 insertions, 175 deletions
diff --git a/sw/source/core/layout/tabfrm.cxx b/sw/source/core/layout/tabfrm.cxx
index c422b89fac71..e2c096ba561c 100644
--- a/sw/source/core/layout/tabfrm.cxx
+++ b/sw/source/core/layout/tabfrm.cxx
@@ -199,7 +199,7 @@ static SwTwips lcl_GetHeightOfRows( const SwFrame* pStart, long nCount )
SwRectFnSet aRectFnSet(pStart);
while ( pStart && nCount > 0 )
{
- nRet += aRectFnSet.GetHeight(pStart->FrameRA());
+ nRet += aRectFnSet.GetHeight(pStart->getSwFrame());
pStart = pStart->GetNext();
--nCount;
}
@@ -266,7 +266,7 @@ static void lcl_InvalidateLowerObjs( SwLayoutFrame& _rLayoutFrame,
// modification of the anchored object resp. it's attributes
// due to the movement
SwObjPositioningInProgress aObjPosInProgress( *pAnchoredObj );
- pAnchoredObj->SetObjLeft( _pPageFrame->FrameRA().Right() );
+ pAnchoredObj->SetObjLeft( _pPageFrame->getSwFrame().Right() );
// #115759# - reset character rectangle,
// top of line and relative position in order to assure,
// that anchored object is correctly positioned.
@@ -344,7 +344,7 @@ static void lcl_ShrinkCellsAndAllContent( SwRowFrame& rRow )
{
lcl_ShrinkCellsAndAllContent( *pTmpRow );
- if (aRectFnSet.GetHeight(pTmpRow->FrameRA()) > 0)
+ if (aRectFnSet.GetHeight(pTmpRow->getSwFrame()) > 0)
bAllRowsCollapsed = false;
pTmpRow = static_cast<SwRowFrame*>(pTmpRow->GetNext());
@@ -353,31 +353,31 @@ static void lcl_ShrinkCellsAndAllContent( SwRowFrame& rRow )
if (bAllRowsCollapsed)
{
// All rows of this table have 0 height -> set height of the table itself as well.
- SwRect aFrm(pTmp->FrameRA());
+ SwRect aFrm(pTmp->getSwFrame());
aRectFnSet.SetHeight(aFrm, 0);
- pTmp->setFrame(aFrm);
+ pTmp->setSwFrame(aFrm);
- SwRect aPrt(pTmp->PrintRA());
+ SwRect aPrt(pTmp->getSwPrint());
aRectFnSet.SetTop(aPrt, 0);
aRectFnSet.SetHeight(aPrt, 0);
- pTmp->setPrint(aPrt);
+ pTmp->setSwPrint(aPrt);
}
else
bAllLowersCollapsed = false;
}
else
{
- pTmp->Shrink(aRectFnSet.GetHeight(pTmp->FrameRA()));
- SwRect aPrt(pTmp->PrintRA());
+ pTmp->Shrink(aRectFnSet.GetHeight(pTmp->getSwFrame()));
+ SwRect aPrt(pTmp->getSwPrint());
aRectFnSet.SetTop(aPrt, 0);
aRectFnSet.SetHeight(aPrt, 0);
- if (aRectFnSet.GetHeight(pTmp->FrameRA()) > 0)
+ if (aRectFnSet.GetHeight(pTmp->getSwFrame()) > 0)
{
bAllLowersCollapsed = false;
}
- pTmp->setPrint(aPrt);
+ pTmp->setSwPrint(aPrt);
}
pTmp = pTmp->GetPrev();
@@ -392,14 +392,14 @@ static void lcl_ShrinkCellsAndAllContent( SwRowFrame& rRow )
if (bAllLowersCollapsed)
{
// All lower frame of this cell have 0 height -> set height of the cell itself as well.
- SwRect aFrm(pCurrMasterCell->FrameRA());
+ SwRect aFrm(pCurrMasterCell->getSwFrame());
aRectFnSet.SetHeight(aFrm, 0);
- pCurrMasterCell->setFrame(aFrm);
+ pCurrMasterCell->setSwFrame(aFrm);
- SwRect aPrt(pCurrMasterCell->PrintRA());
+ SwRect aPrt(pCurrMasterCell->getSwPrint());
aRectFnSet.SetTop(aPrt, 0);
aRectFnSet.SetHeight(aPrt, 0);
- pCurrMasterCell->setPrint(aPrt);
+ pCurrMasterCell->setSwPrint(aPrt);
}
else
bAllCellsCollapsed = false;
@@ -410,14 +410,14 @@ static void lcl_ShrinkCellsAndAllContent( SwRowFrame& rRow )
if (bAllCellsCollapsed)
{
// All cells have 0 height -> set height of row as well.
- SwRect aFrm(rRow.FrameRA());
+ SwRect aFrm(rRow.getSwFrame());
aRectFnSet.SetHeight(aFrm, 0);
- rRow.setFrame(aFrm);
+ rRow.setSwFrame(aFrm);
- SwRect aPrt(rRow.PrintRA());
+ SwRect aPrt(rRow.getSwPrint());
aRectFnSet.SetTop(aPrt, 0);
aRectFnSet.SetHeight(aPrt, 0);
- rRow.setPrint(aPrt);
+ rRow.setSwPrint(aPrt);
}
}
@@ -540,7 +540,7 @@ static void lcl_PreprocessRowsInCells( SwTabFrame& rTab, SwRowFrame& rLastLine,
// 2. The borders of the cells inside the row
// 3. The minimum height of the row
if ( pTmpLastLineRow->HasFixSize() )
- nMinHeight = aRectFnSet.GetHeight(pTmpLastLineRow->FrameRA());
+ nMinHeight = aRectFnSet.GetHeight(pTmpLastLineRow->getSwFrame());
else
{
{
@@ -594,8 +594,8 @@ static void lcl_PreprocessRowsInCells( SwTabFrame& rTab, SwRowFrame& rLastLine,
lcl_MoveFootnotes( rTab, *rTab.GetFollow(), *pTmpLastLineRow );
pTmpLastLineRow->RemoveFromLayout();
pTmpLastLineRow->InsertBefore( pCurrFollowFlowLineCell, nullptr );
- pTmpLastLineRow->Shrink( aRectFnSet.GetHeight(pTmpLastLineRow->FrameRA()) );
- pCurrFollowFlowLineCell->Grow( aRectFnSet.GetHeight(pTmpLastLineRow->FrameRA()) );
+ pTmpLastLineRow->Shrink( aRectFnSet.GetHeight(pTmpLastLineRow->getSwFrame()) );
+ pCurrFollowFlowLineCell->Grow( aRectFnSet.GetHeight(pTmpLastLineRow->getSwFrame()) );
pTmpLastLineRow = pTmp;
}
}
@@ -649,7 +649,7 @@ static bool lcl_RecalcSplitLine( SwRowFrame& rLastLine, SwRowFrame& rFollowLine,
vcl::RenderContext* pRenderContext = rLastLine.getRootFrame()->GetCurrShell()->GetOut();
SwTabFrame& rTab = static_cast<SwTabFrame&>(*rLastLine.GetUpper());
SwRectFnSet aRectFnSet(rTab.GetUpper());
- SwTwips nCurLastLineHeight = aRectFnSet.GetHeight(rLastLine.FrameRA());
+ SwTwips nCurLastLineHeight = aRectFnSet.GetHeight(rLastLine.getSwFrame());
// If there are nested cells in rLastLine, the recalculation of the last
// line needs some preprocessing.
@@ -726,7 +726,7 @@ static bool lcl_RecalcSplitLine( SwRowFrame& rLastLine, SwRowFrame& rFollowLine,
// 1. Check if table fits to its upper.
// #i26945# - include check, if objects fit
const SwTwips nDistanceToUpperPrtBottom =
- aRectFnSet.BottomDist(rTab.FrameRA(), aRectFnSet.GetPrtBottom(*rTab.GetUpper()));
+ aRectFnSet.BottomDist(rTab.getSwFrame(), aRectFnSet.GetPrtBottom(*rTab.GetUpper()));
if ( nDistanceToUpperPrtBottom < 0 || !rTab.DoesObjsFit() )
bRet = false;
@@ -801,13 +801,13 @@ static void lcl_AdjustRowSpanCells( SwRowFrame* pRow )
{
// calculate height of cell:
const long nNewCellHeight = lcl_GetHeightOfRows( pRow, nLayoutRowSpan );
- const long nDiff = nNewCellHeight - aRectFnSet.GetHeight(pCellFrame->FrameRA());
+ const long nDiff = nNewCellHeight - aRectFnSet.GetHeight(pCellFrame->getSwFrame());
if ( nDiff )
{
- SwRect aFrm(pCellFrame->FrameRA());
+ SwRect aFrm(pCellFrame->getSwFrame());
aRectFnSet.AddBottom(aFrm, nDiff);
- pCellFrame->setFrame(aFrm);
+ pCellFrame->setSwFrame(aFrm);
}
}
@@ -889,7 +889,7 @@ bool SwTabFrame::RemoveFollowFlowLine()
while ( pRow && nRowsToMove-- > 1 )
{
SwFrame* pNxt = pRow->GetNext();
- nGrow += aRectFnSet.GetHeight(pRow->FrameRA());
+ nGrow += aRectFnSet.GetHeight(pRow->getSwFrame());
// The footnotes have to be moved:
lcl_MoveFootnotes( *GetFollow(), *this, static_cast<SwRowFrame&>(*pRow) );
@@ -1005,20 +1005,20 @@ bool SwTabFrame::Split( const SwTwips nCutPos, bool bTryToSplit, bool bTableRowK
sal_uInt16 nRowCount = 0; // pRow currently points to the first row
SwTwips nRemainingSpaceForLastRow =
- aRectFnSet.YDiff(nCutPos, aRectFnSet.GetTop(FrameRA()));
+ aRectFnSet.YDiff(nCutPos, aRectFnSet.GetTop(getSwFrame()));
nRemainingSpaceForLastRow -= aRectFnSet.GetTopMargin(*this);
// Make pRow point to the line that does not fit anymore:
while( pRow->GetNext() &&
- nRemainingSpaceForLastRow >= ( aRectFnSet.GetHeight(pRow->FrameRA()) +
+ nRemainingSpaceForLastRow >= ( aRectFnSet.GetHeight(pRow->getSwFrame()) +
(IsCollapsingBorders() ?
pRow->GetBottomLineSize() :
0 ) ) )
{
if( bTryToSplit || !pRow->IsRowSpanLine() ||
- 0 != aRectFnSet.GetHeight(pRow->FrameRA()) )
+ 0 != aRectFnSet.GetHeight(pRow->getSwFrame()) )
++nRowCount;
- nRemainingSpaceForLastRow -= aRectFnSet.GetHeight(pRow->FrameRA());
+ nRemainingSpaceForLastRow -= aRectFnSet.GetHeight(pRow->getSwFrame());
pRow = static_cast<SwRowFrame*>(pRow->GetNext());
}
@@ -1070,7 +1070,7 @@ bool SwTabFrame::Split( const SwTwips nCutPos, bool bTryToSplit, bool bTableRowK
{
const SwRowFrame* pLowerRow = static_cast<SwRowFrame*>(pLowerCell->Lower());
if ( !pLowerRow->IsRowSplitAllowed() &&
- aRectFnSet.GetHeight(pLowerRow->FrameRA()) > nRemainingSpaceForLastRow )
+ aRectFnSet.GetHeight(pLowerRow->getSwFrame()) > nRemainingSpaceForLastRow )
{
bKeepNextRow = true;
break;
@@ -1087,7 +1087,7 @@ bool SwTabFrame::Split( const SwTwips nCutPos, bool bTryToSplit, bool bTableRowK
if ( bKeepNextRow )
{
pRow = GetFirstNonHeadlineRow();
- if ( pRow && pRow->IsRowSpanLine() && 0 == aRectFnSet.GetHeight(pRow->FrameRA()) )
+ if ( pRow && pRow->IsRowSpanLine() && 0 == aRectFnSet.GetHeight(pRow->getSwFrame()) )
pRow = static_cast<SwRowFrame*>(pRow->GetNext());
if ( pRow )
{
@@ -1164,14 +1164,14 @@ bool SwTabFrame::Split( const SwTwips nCutPos, bool bTryToSplit, bool bTableRowK
pFoll = new SwTabFrame( *this );
// We give the follow table an initial width.
- SwRect aFrm(pFoll->FrameRA());
- aRectFnSet.AddWidth(aFrm, aRectFnSet.GetWidth(FrameRA()));
- aRectFnSet.SetLeft(aFrm, aRectFnSet.GetLeft(FrameRA()));
- pFoll->setFrame(aFrm);
+ SwRect aFrm(pFoll->getSwFrame());
+ aRectFnSet.AddWidth(aFrm, aRectFnSet.GetWidth(getSwFrame()));
+ aRectFnSet.SetLeft(aFrm, aRectFnSet.GetLeft(getSwFrame()));
+ pFoll->setSwFrame(aFrm);
- SwRect aPrt(pFoll->PrintRA());
- aRectFnSet.AddWidth(aPrt, aRectFnSet.GetWidth(PrintRA()));
- pFoll->setPrint(aPrt);
+ SwRect aPrt(pFoll->getSwPrint());
+ aRectFnSet.AddWidth(aPrt, aRectFnSet.GetWidth(getSwPrint()));
+ pFoll->setSwPrint(aPrt);
// Insert the new follow table
pFoll->InsertBehind( GetUpper(), this );
@@ -1255,7 +1255,7 @@ bool SwTabFrame::Split( const SwTwips nCutPos, bool bTryToSplit, bool bTableRowK
while ( pRow )
{
SwFrame* pNxt = pRow->GetNext();
- nShrink += aRectFnSet.GetHeight(pRow->FrameRA());
+ nShrink += aRectFnSet.GetHeight(pRow->getSwFrame());
// The footnotes do not have to be moved, this is done in the
// MoveFwd of the follow table!!!
pRow->RemoveFromLayout();
@@ -1274,7 +1274,7 @@ bool SwTabFrame::Split( const SwTwips nCutPos, bool bTryToSplit, bool bTableRowK
while ( pRow )
{
SwFrame* pNxt = pRow->GetNext();
- nShrink += aRectFnSet.GetHeight(pRow->FrameRA());
+ nShrink += aRectFnSet.GetHeight(pRow->getSwFrame());
// The footnotes have to be moved:
lcl_MoveFootnotes( *this, *GetFollow(), *pRow );
@@ -1333,7 +1333,7 @@ bool SwTabFrame::Join()
while ( pRow )
{
pNxt = pRow->GetNext();
- nHeight += aRectFnSet.GetHeight(pRow->FrameRA());
+ nHeight += aRectFnSet.GetHeight(pRow->getSwFrame());
pRow->RemoveFromLayout();
pRow->InvalidateAll_();
pRow->InsertBehind( this, pPrv );
@@ -1374,7 +1374,7 @@ void SwInvalidatePositions( SwFrame *pFrame, long nBottom )
pFrame = pFrame->GetNext();
} while ( pFrame &&
( bAll ||
- aRectFnSet.YDiff( aRectFnSet.GetTop(pFrame->FrameRA()), nBottom ) < 0 ) );
+ aRectFnSet.YDiff( aRectFnSet.GetTop(pFrame->getSwFrame()), nBottom ) < 0 ) );
}
void SwInvalidateAll( SwFrame *pFrame, long nBottom )
@@ -1409,7 +1409,7 @@ void SwInvalidateAll( SwFrame *pFrame, long nBottom )
pFrame = pFrame->GetNext();
} while ( pFrame &&
( bAll ||
- aRectFnSet.YDiff( aRectFnSet.GetTop(pFrame->FrameRA()), nBottom ) < 0 ) );
+ aRectFnSet.YDiff( aRectFnSet.GetTop(pFrame->getSwFrame()), nBottom ) < 0 ) );
}
// #i29550#
@@ -1519,7 +1519,7 @@ bool SwContentFrame::CalcLowers( SwLayoutFrame* pLay, const SwLayoutFrame* pDont
}
pCnt->GetUpper()->Calc(pRenderContext);
}
- if( ! bAll && aRectFnSet.YDiff(aRectFnSet.GetTop(pCnt->FrameRA()), nBottom) > 0 )
+ if( ! bAll && aRectFnSet.YDiff(aRectFnSet.GetTop(pCnt->getSwFrame()), nBottom) > 0 )
break;
pCnt = pCnt->GetNextContentFrame();
}
@@ -1567,7 +1567,7 @@ static bool lcl_InnerCalcLayout( SwFrame *pFrame,
pFrame = pFrame->GetNext();
} while( pFrame &&
( bAll ||
- aRectFnSet.YDiff(aRectFnSet.GetTop(pFrame->FrameRA()), nBottom) < 0 )
+ aRectFnSet.YDiff(aRectFnSet.GetTop(pFrame->getSwFrame()), nBottom) < 0 )
&& pFrame->GetUpper() == pOldUp );
return bRet;
}
@@ -1910,7 +1910,7 @@ void SwTabFrame::MakeAll(vcl::RenderContext* pRenderContext)
}
// a new one is moved forwards immediately
- if ( !FrameRA().Top() && IsFollow() )
+ if ( !getSwFrame().Top() && IsFollow() )
{
SwFrame *pPre = GetPrev();
if ( pPre && pPre->IsTabFrame() && static_cast<SwTabFrame*>(pPre)->GetFollow() == this)
@@ -1939,12 +1939,12 @@ void SwTabFrame::MakeAll(vcl::RenderContext* pRenderContext)
bSplit = false;
}
- Point aOldPos( aRectFnSet.GetPos(FrameRA()) );
+ Point aOldPos( aRectFnSet.GetPos(getSwFrame()) );
MakePos();
- if ( aOldPos != aRectFnSet.GetPos(FrameRA()) )
+ if ( aOldPos != aRectFnSet.GetPos(getSwFrame()) )
{
- if ( aOldPos.Y() != aRectFnSet.GetTop(FrameRA()) )
+ if ( aOldPos.Y() != aRectFnSet.GetTop(getSwFrame()) )
{
SwHTMLTableLayout *pLayout = GetTable()->GetHTMLTableLayout();
if( pLayout )
@@ -1978,20 +1978,20 @@ void SwTabFrame::MakeAll(vcl::RenderContext* pRenderContext)
{
SwFrame* pFrame = GetFirstNonHeadlineRow();
if ( pFrame )
- n1StLineHeight = aRectFnSet.GetHeight(pFrame->FrameRA());
+ n1StLineHeight = aRectFnSet.GetHeight(pFrame->getSwFrame());
}
if ( !mbValidSize || !mbValidPrtArea )
{
- const long nOldPrtWidth = aRectFnSet.GetWidth(PrintRA());
- const long nOldFrameWidth = aRectFnSet.GetWidth(FrameRA());
- const Point aOldPrtPos = aRectFnSet.GetPos(PrintRA());
+ const long nOldPrtWidth = aRectFnSet.GetWidth(getSwPrint());
+ const long nOldFrameWidth = aRectFnSet.GetWidth(getSwFrame());
+ const Point aOldPrtPos = aRectFnSet.GetPos(getSwPrint());
Format( getRootFrame()->GetCurrShell()->GetOut(), pAttrs );
SwHTMLTableLayout *pLayout = GetTable()->GetHTMLTableLayout();
if ( pLayout &&
- (aRectFnSet.GetWidth(PrintRA()) != nOldPrtWidth ||
- aRectFnSet.GetWidth(FrameRA()) != nOldFrameWidth) )
+ (aRectFnSet.GetWidth(getSwPrint()) != nOldPrtWidth ||
+ aRectFnSet.GetWidth(getSwFrame()) != nOldFrameWidth) )
{
pAccess.reset();
m_bCalcLowers |= pLayout->Resize(
@@ -1999,7 +1999,7 @@ void SwTabFrame::MakeAll(vcl::RenderContext* pRenderContext)
pAccess = o3tl::make_unique<SwBorderAttrAccess>(SwFrame::GetCache(), this);
pAttrs = pAccess->Get();
}
- if ( aOldPrtPos != aRectFnSet.GetPos(PrintRA()) )
+ if ( aOldPrtPos != aRectFnSet.GetPos(getSwPrint()) )
aNotify.SetLowersComplete( false );
}
@@ -2015,7 +2015,7 @@ void SwTabFrame::MakeAll(vcl::RenderContext* pRenderContext)
{
// Only if the height of the first line got smaller.
SwFrame *pFrame = GetFirstNonHeadlineRow();
- if( pFrame && n1StLineHeight >aRectFnSet.GetHeight(pFrame->FrameRA()) )
+ if( pFrame && n1StLineHeight >aRectFnSet.GetHeight(pFrame->getSwFrame()) )
{
SwTabFrame *pMaster = FindMaster();
bool bDummy;
@@ -2034,9 +2034,9 @@ void SwTabFrame::MakeAll(vcl::RenderContext* pRenderContext)
MoveLowerFootnotes( nullptr, pOldBoss, nullptr, true );
if ( bReformat || bKeep )
{
- long nOldTop = aRectFnSet.GetTop(FrameRA());
+ long nOldTop = aRectFnSet.GetTop(getSwFrame());
MakePos();
- if( nOldTop != aRectFnSet.GetTop(FrameRA()) )
+ if( nOldTop != aRectFnSet.GetTop(getSwFrame()) )
{
SwHTMLTableLayout *pHTMLLayout =
GetTable()->GetHTMLTableLayout();
@@ -2084,7 +2084,7 @@ void SwTabFrame::MakeAll(vcl::RenderContext* pRenderContext)
// table frame bottom to the bottom of the upper printing area.
// Note: negative values denotes the situation that table frame doesn't fit in its upper.
SwTwips nDistanceToUpperPrtBottom =
- aRectFnSet.BottomDist(FrameRA(), aRectFnSet.GetPrtBottom(*GetUpper()));
+ aRectFnSet.BottomDist(getSwFrame(), aRectFnSet.GetPrtBottom(*GetUpper()));
/// In online layout try to grow upper of table frame, if table frame doesn't fit in its upper.
const SwViewShell *pSh = getRootFrame()->GetCurrShell();
@@ -2094,7 +2094,7 @@ void SwTabFrame::MakeAll(vcl::RenderContext* pRenderContext)
if ( GetUpper()->Grow( -nDistanceToUpperPrtBottom ) )
{
// upper is grown --> recalculate <nDistanceToUpperPrtBottom>
- nDistanceToUpperPrtBottom = aRectFnSet.BottomDist(FrameRA(), aRectFnSet.GetPrtBottom(*GetUpper()));
+ nDistanceToUpperPrtBottom = aRectFnSet.BottomDist(getSwFrame(), aRectFnSet.GetPrtBottom(*GetUpper()));
}
}
@@ -2115,7 +2115,7 @@ void SwTabFrame::MakeAll(vcl::RenderContext* pRenderContext)
SwTwips nDeadLine = aRectFnSet.GetPrtBottom(*pTmp);
if ( bBrowseMode )
nDeadLine += pTmp->Grow( LONG_MAX, true );
- if( aRectFnSet.BottomDist( FrameRA(), nDeadLine ) > 0 )
+ if( aRectFnSet.BottomDist( getSwFrame(), nDeadLine ) > 0 )
{
// First, we remove an existing follow flow line.
if ( HasFollowFlowLine() )
@@ -2151,7 +2151,7 @@ void SwTabFrame::MakeAll(vcl::RenderContext* pRenderContext)
continue;
}
- const SwTwips nOld = aRectFnSet.GetHeight(FrameRA());
+ const SwTwips nOld = aRectFnSet.GetHeight(getSwFrame());
long nRowsToMove = lcl_GetMaximumLayoutRowSpan( *pRow );
SwFrame* pRowToMove = pRow;
@@ -2184,7 +2184,7 @@ void SwTabFrame::MakeAll(vcl::RenderContext* pRenderContext)
pRowToMove = pNextRow;
}
- if ( nOld != aRectFnSet.GetHeight(FrameRA()) )
+ if ( nOld != aRectFnSet.GetHeight(getSwFrame()) )
lcl_RecalcTable( *this, static_cast<SwLayoutFrame*>(pRow), aNotify );
continue;
@@ -2322,7 +2322,7 @@ void SwTabFrame::MakeAll(vcl::RenderContext* pRenderContext)
// all kinds of unexpected things could happen.
if ( !bEmulateTableKeepFwdMoveAllowed ||
( IsInSct() && (FindSctFrame())->Lower()->IsColumnFrame() &&
- 0 == aRectFnSet.GetHeight(GetUpper()->FrameRA())
+ 0 == aRectFnSet.GetHeight(GetUpper()->getSwFrame())
) )
{
bTryToSplit = false;
@@ -2348,7 +2348,7 @@ void SwTabFrame::MakeAll(vcl::RenderContext* pRenderContext)
// One more check if its really necessary to split the table.
// 1. The table either has to exceed the deadline or
// 2. We explicitly want to cut off the last row.
- if( aRectFnSet.BottomDist( FrameRA(), nDeadLine ) > 0 && !bLastRowHasToMoveToFollow )
+ if( aRectFnSet.BottomDist( getSwFrame(), nDeadLine ) > 0 && !bLastRowHasToMoveToFollow )
{
continue;
}
@@ -2385,7 +2385,7 @@ void SwTabFrame::MakeAll(vcl::RenderContext* pRenderContext)
++nMinNumOfLines;
const SwTwips nBreakLine = aRectFnSet.YInc(
- aRectFnSet.GetTop(FrameRA()),
+ aRectFnSet.GetTop(getSwFrame()),
aRectFnSet.GetTopMargin(*this) +
lcl_GetHeightOfRows( GetLower(), nMinNumOfLines ) );
@@ -2478,7 +2478,7 @@ void SwTabFrame::MakeAll(vcl::RenderContext* pRenderContext)
const bool bOldJoinLock = GetFollow()->IsJoinLocked();
GetFollow()->LockJoin();
::lcl_RecalcRow( static_cast<SwRowFrame&>(*GetFollow()->Lower()),
- fnRectX.GetBottom(GetFollow()->GetUpper()->FrameRA()) );
+ fnRectX.GetBottom(GetFollow()->GetUpper()->getSwFrame()) );
// #i43913#
// #i63632# Do not unlock the
// follow if it wasn't locked before.
@@ -2581,7 +2581,7 @@ void SwTabFrame::MakeAll(vcl::RenderContext* pRenderContext)
// and can cause layout loops, if table doesn't fit and isn't
// allowed to split.
SwTwips nDistToUpperPrtBottom =
- aRectFnSet.BottomDist( FrameRA(), aRectFnSet.GetPrtBottom(*GetUpper()));
+ aRectFnSet.BottomDist( getSwFrame(), aRectFnSet.GetPrtBottom(*GetUpper()));
if ( nDistToUpperPrtBottom >= 0 || bTryToSplit )
{
lcl_RecalcTable( *this, nullptr, aNotify );
@@ -2636,10 +2636,10 @@ bool SwTabFrame::CalcFlyOffsets( SwTwips& rUpper,
{
SwRectFnSet aRectFnSet(this);
const bool bConsiderWrapOnObjPos = rIDSA.get(DocumentSettingId::CONSIDER_WRAP_ON_OBJECT_POSITION);
- long nPrtPos = aRectFnSet.GetTop(FrameRA());
+ long nPrtPos = aRectFnSet.GetTop(getSwFrame());
nPrtPos = aRectFnSet.YInc( nPrtPos, rUpper );
- SwRect aRect( FrameRA() );
- long nYDiff = aRectFnSet.YDiff( aRectFnSet.GetTop(PrintRA()), rUpper );
+ SwRect aRect( getSwFrame() );
+ long nYDiff = aRectFnSet.YDiff( aRectFnSet.GetTop(getSwPrint()), rUpper );
if( nYDiff > 0 )
aRectFnSet.AddBottom( aRect, -nYDiff );
for ( size_t i = 0; i < pPage->GetSortedObjs()->size(); ++i )
@@ -2726,7 +2726,7 @@ bool SwTabFrame::CalcFlyOffsets( SwTwips& rUpper,
{
const long nWidth = aRectFnSet.XDiff(
aRectFnSet.GetRight(aFlyRect),
- aRectFnSet.GetLeft(pFly->GetAnchorFrame()->FrameRA()) );
+ aRectFnSet.GetLeft(pFly->GetAnchorFrame()->getSwFrame()) );
rLeftOffset = std::max( rLeftOffset, nWidth );
bInvalidatePrtArea = true;
}
@@ -2735,7 +2735,7 @@ bool SwTabFrame::CalcFlyOffsets( SwTwips& rUpper,
text::HoriOrientation::RIGHT == rHori.GetHoriOrient() )
{
const long nWidth = aRectFnSet.XDiff(
- aRectFnSet.GetRight(pFly->GetAnchorFrame()->FrameRA()),
+ aRectFnSet.GetRight(pFly->GetAnchorFrame()->getSwFrame()),
aRectFnSet.GetLeft(aFlyRect) );
rRightOffset = std::max( rRightOffset, nWidth );
bInvalidatePrtArea = true;
@@ -2743,7 +2743,7 @@ bool SwTabFrame::CalcFlyOffsets( SwTwips& rUpper,
}
}
}
- rUpper = aRectFnSet.YDiff( nPrtPos, aRectFnSet.GetTop(FrameRA()) );
+ rUpper = aRectFnSet.YDiff( nPrtPos, aRectFnSet.GetTop(getSwFrame()) );
}
return bInvalidatePrtArea;
@@ -2758,13 +2758,13 @@ void SwTabFrame::Format( vcl::RenderContext* /*pRenderContext*/, const SwBorderA
SwRectFnSet aRectFnSet(this);
if ( !mbValidSize )
{
- long nDiff = aRectFnSet.GetWidth(GetUpper()->PrintRA()) -
- aRectFnSet.GetWidth(FrameRA());
+ long nDiff = aRectFnSet.GetWidth(GetUpper()->getSwPrint()) -
+ aRectFnSet.GetWidth(getSwFrame());
if( nDiff )
{
- SwRect aFrm(FrameRA());
+ SwRect aFrm(getSwFrame());
aRectFnSet.AddRight( aFrm, nDiff );
- setFrame(aFrm);
+ setSwFrame(aFrm);
}
}
@@ -2800,8 +2800,8 @@ void SwTabFrame::Format( vcl::RenderContext* /*pRenderContext*/, const SwBorderA
//If the adjustment is 0, the borders are set according to the border
//attributes.
- const SwTwips nOldHeight = aRectFnSet.GetHeight(PrintRA());
- const SwTwips nMax = aRectFnSet.GetWidth(FrameRA());
+ const SwTwips nOldHeight = aRectFnSet.GetHeight(getSwPrint());
+ const SwTwips nMax = aRectFnSet.GetWidth(getSwFrame());
// OD 14.03.2003 #i9040# - adjust variable names.
const SwTwips nLeftLine = pAttrs->CalcLeftLine();
@@ -2981,15 +2981,15 @@ void SwTabFrame::Format( vcl::RenderContext* /*pRenderContext*/, const SwBorderA
//The page width can be bigger because objects with
//"over-size" are possible (RootFrame::ImplCalcBrowseWidth())
long nWidth = pSh->GetBrowseWidth();
- nWidth -= PrintRA().Left();
+ nWidth -= getSwPrint().Left();
nWidth -= pAttrs->CalcRightLine();
- SwRect aPrt(PrintRA());
+ SwRect aPrt(getSwPrint());
aPrt.Width( std::min( nWidth, aPrt.Width() ) );
- setPrint(aPrt);
+ setSwPrint(aPrt);
}
- if ( nOldHeight != aRectFnSet.GetHeight(PrintRA()) )
+ if ( nOldHeight != aRectFnSet.GetHeight(getSwPrint()) )
mbValidSize = false;
}
@@ -3002,13 +3002,13 @@ void SwTabFrame::Format( vcl::RenderContext* /*pRenderContext*/, const SwBorderA
SwFrame *pFrame = m_pLower;
while ( pFrame )
{
- nRemaining += aRectFnSet.GetHeight(pFrame->FrameRA());
+ nRemaining += aRectFnSet.GetHeight(pFrame->getSwFrame());
pFrame = pFrame->GetNext();
}
//And now add the borders
nRemaining += nUpper + nLower;
- nDiff = aRectFnSet.GetHeight(FrameRA()) - nRemaining;
+ nDiff = aRectFnSet.GetHeight(getSwFrame()) - nRemaining;
if ( nDiff > 0 )
Shrink( nDiff );
else if ( nDiff < 0 )
@@ -3019,7 +3019,7 @@ void SwTabFrame::Format( vcl::RenderContext* /*pRenderContext*/, const SwBorderA
SwTwips SwTabFrame::GrowFrame( SwTwips nDist, bool bTst, bool bInfo )
{
SwRectFnSet aRectFnSet(this);
- SwTwips nHeight = aRectFnSet.GetHeight(FrameRA());
+ SwTwips nHeight = aRectFnSet.GetHeight(getSwFrame());
if( nHeight > 0 && nDist > ( LONG_MAX - nHeight ) )
nDist = LONG_MAX - nHeight;
@@ -3028,15 +3028,15 @@ SwTwips SwTabFrame::GrowFrame( SwTwips nDist, bool bTst, bool bInfo )
if ( GetUpper() )
{
- SwRect aOldFrame( FrameRA() );
+ SwRect aOldFrame( getSwFrame() );
//The upper only grows as far as needed. nReal provides the distance
//which is already available.
- SwTwips nReal = aRectFnSet.GetHeight(GetUpper()->PrintRA());
+ SwTwips nReal = aRectFnSet.GetHeight(GetUpper()->getSwPrint());
SwFrame *pFrame = GetUpper()->Lower();
while ( pFrame && GetFollow() != pFrame )
{
- nReal -= aRectFnSet.GetHeight(pFrame->FrameRA());
+ nReal -= aRectFnSet.GetHeight(pFrame->getSwFrame());
pFrame = pFrame->GetNext();
}
@@ -3053,9 +3053,9 @@ SwTwips SwTabFrame::GrowFrame( SwTwips nDist, bool bTst, bool bInfo )
if ( !bTst )
{
- SwRect aFrm(FrameRA());
+ SwRect aFrm(getSwFrame());
aRectFnSet.AddBottom( aFrm, nDist );
- setFrame(aFrm);
+ setSwFrame(aFrm);
SwRootFrame *pRootFrame = getRootFrame();
if( pRootFrame && pRootFrame->IsAnyShellAccessible() &&
@@ -3209,7 +3209,7 @@ void SwTabFrame::UpdateAttr_( const SfxPoolItem *pOld, const SfxPoolItem *pNew,
CheckPageDescs( pPage );
if (GetFormat()->GetPageDesc().GetNumOffset())
static_cast<SwRootFrame*>(pPage->GetUpper())->SetVirtPageNum( true );
- SwDocPosUpdate aMsgHint( pPage->FrameRA().Top() );
+ SwDocPosUpdate aMsgHint( pPage->getSwFrame().Top() );
GetFormat()->GetDoc()->getIDocumentFieldsAccess().UpdatePageFields( &aMsgHint );
}
}
@@ -3376,33 +3376,33 @@ bool SwTabFrame::ShouldBwdMoved( SwLayoutFrame *pNewUpper, bool, bool &rReformat
if ( !SwFlowFrame::IsMoveBwdJump() )
{
- long nOldWidth = aRectFnSet.GetWidth(GetUpper()->PrintRA());
+ long nOldWidth = aRectFnSet.GetWidth(GetUpper()->getSwPrint());
SwRectFnSet fnRectX(pNewUpper);
- long nNewWidth = fnRectX.GetWidth(pNewUpper->PrintRA());
+ long nNewWidth = fnRectX.GetWidth(pNewUpper->getSwPrint());
if( std::abs( nNewWidth - nOldWidth ) < 2 )
{
- bMoveAnyway = BwdMoveNecessary( pOldPage, FrameRA() ) > 1;
+ bMoveAnyway = BwdMoveNecessary( pOldPage, getSwFrame() ) > 1;
if( !bMoveAnyway )
{
- SwRect aRect( pNewUpper->PrintRA() );
- aRect.Pos() += pNewUpper->FrameRA().Pos();
+ SwRect aRect( pNewUpper->getSwPrint() );
+ aRect.Pos() += pNewUpper->getSwFrame().Pos();
const SwFrame *pPrevFrame = pNewUpper->Lower();
while ( pPrevFrame && pPrevFrame != this )
{
- fnRectX.SetTop( aRect, fnRectX.GetBottom(pPrevFrame->FrameRA()) );
+ fnRectX.SetTop( aRect, fnRectX.GetBottom(pPrevFrame->getSwFrame()) );
pPrevFrame = pPrevFrame->GetNext();
}
bMoveAnyway = BwdMoveNecessary( pNewPage, aRect) > 1;
// #i54861# Due to changes made in PrepareMake,
// the tabfrm may not have a correct position. Therefore
- // it is possible that pNewUpper->PrintRA().Height == 0. In this
+ // it is possible that pNewUpper->getSwPrint().Height == 0. In this
// case the above calculation of nSpace might give wrong
// results and we really do not want to MoveBackward into a
// 0 height frame. If nTmpSpace is already <= 0, we take this
// value:
const SwTwips nTmpSpace = fnRectX.GetHeight(aRect);
- if ( fnRectX.GetHeight(pNewUpper->PrintRA()) > 0 || nTmpSpace <= 0 )
+ if ( fnRectX.GetHeight(pNewUpper->getSwPrint()) > 0 || nTmpSpace <= 0 )
nSpace = nTmpSpace;
const SwViewShell *pSh = getRootFrame()->GetCurrShell();
@@ -3536,11 +3536,11 @@ void SwTabFrame::Cut()
SwFrame::DestroyFrame(pUp);
}
}
- else if( aRectFnSet.GetHeight(FrameRA()) )
+ else if( aRectFnSet.GetHeight(getSwFrame()) )
{
// OD 26.08.2003 #i18103# - *no* 'ColUnlock' of section -
// undo changes of fix for #104992#
- pUp->Shrink( FrameRA().Height() );
+ pUp->Shrink( getSwFrame().Height() );
}
}
@@ -3574,10 +3574,10 @@ void SwTabFrame::Paste( SwFrame* pParent, SwFrame* pSibling )
}
SwRectFnSet aRectFnSet(this);
- if( aRectFnSet.GetHeight(FrameRA()) )
- pParent->Grow( aRectFnSet.GetHeight(FrameRA()) );
+ if( aRectFnSet.GetHeight(getSwFrame()) )
+ pParent->Grow( aRectFnSet.GetHeight(getSwFrame()) );
- if( aRectFnSet.GetWidth(FrameRA()) != aRectFnSet.GetWidth(pParent->PrintRA()) )
+ if( aRectFnSet.GetWidth(getSwFrame()) != aRectFnSet.GetWidth(pParent->getSwPrint()) )
Prepare( PREP_FIXSIZE_CHG );
if ( GetPrev() )
{
@@ -3779,14 +3779,14 @@ long CalcHeightWithFlys( const SwFrame *pFrame )
const SwTwips nFrameDiff =
aRectFnSet.YDiff(
- aRectFnSet.GetTop(pTmp->FrameRA()),
- aRectFnSet.GetTop(pFrame->FrameRA()) );
+ aRectFnSet.GetTop(pTmp->getSwFrame()),
+ aRectFnSet.GetTop(pFrame->getSwFrame()) );
nHeight = std::max( nHeight, nDistOfFlyBottomToAnchorTop + nFrameDiff -
- aRectFnSet.GetHeight(pFrame->FrameRA()) );
+ aRectFnSet.GetHeight(pFrame->getSwFrame()) );
// #i56115# The first height calculation
- // gives wrong results if pFrame->PrintRA().Y() > 0. We do
+ // gives wrong results if pFrame->getSwPrint().Y() > 0. We do
// a second calculation based on the actual rectangles of
// pFrame and pAnchoredObj, and use the maximum of the results.
// I do not want to remove the first calculation because
@@ -3794,7 +3794,7 @@ long CalcHeightWithFlys( const SwFrame *pFrame )
// might be the better option to calculate nHeight.
const SwTwips nDistOfFlyBottomToAnchorTop2 = aRectFnSet.YDiff(
aRectFnSet.GetBottom(pAnchoredObj->GetObjRect()),
- aRectFnSet.GetBottom(pFrame->FrameRA()) );
+ aRectFnSet.GetBottom(pFrame->getSwFrame()) );
nHeight = std::max( nHeight, nDistOfFlyBottomToAnchorTop2 );
}
@@ -3865,7 +3865,7 @@ static SwTwips lcl_CalcMinCellHeight( const SwLayoutFrame *_pCell,
}
else
{
- long nLowHeight = aRectFnSet.GetHeight(pLow->FrameRA());
+ long nLowHeight = aRectFnSet.GetHeight(pLow->getSwFrame());
nHeight += nLowHeight;
// #i26945#
if ( _bConsiderObjs )
@@ -3945,7 +3945,7 @@ static SwTwips lcl_CalcMinRowHeight( const SwRowFrame* _pRow,
const SwFrame* pMasterRow = rMaster.GetUpper();
while ( pMasterRow && pMasterRow != _pRow )
{
- nTmp -= aRectFnSet.GetHeight(pMasterRow->FrameRA());
+ nTmp -= aRectFnSet.GetHeight(pMasterRow->getSwFrame());
pMasterRow = pMasterRow->GetNext();
}
}
@@ -4082,7 +4082,7 @@ static SwTwips lcl_calcHeightOfRowBeforeThisFrame(const SwRowFrame& rRow)
{
// The found row frame belongs to a table frame that precedes
// (above) this one in chain. So, include it in the sum
- nResult += aRectFnSet.GetHeight(pCurRow->FrameRA());
+ nResult += aRectFnSet.GetHeight(pCurRow->getSwFrame());
}
}
}
@@ -4101,12 +4101,12 @@ void SwRowFrame::Format( vcl::RenderContext* /*pRenderContext*/, const SwBorderA
//RowFrames don't have borders and so on therefore the PrtArea always
//matches the Frame.
mbValidPrtArea = true;
- SwRect aPrt(PrintRA());
+ SwRect aPrt(getSwPrint());
aPrt.Left( 0 );
aPrt.Top( 0 );
- aPrt.Width ( FrameRA().Width() );
- aPrt.Height( FrameRA().Height() );
- setPrint(aPrt);
+ aPrt.Width ( getSwFrame().Width() );
+ aPrt.Height( getSwFrame().Height() );
+ setSwPrint(aPrt);
// #i29550#
// Here we calculate the top-printing area for the lower cell frames
@@ -4219,7 +4219,7 @@ void SwRowFrame::Format( vcl::RenderContext* /*pRenderContext*/, const SwBorderA
OSL_ENSURE( rFrameSize.GetSize().Height() > 0, "Has it" );
}
#endif
- const SwTwips nDiff = aRectFnSet.GetHeight(FrameRA()) -
+ const SwTwips nDiff = aRectFnSet.GetHeight(getSwFrame()) -
( HasFixSize() && !IsRowSpanLine()
? pAttrs->GetSize().Height()
// #i26945#
@@ -4240,10 +4240,10 @@ void SwRowFrame::Format( vcl::RenderContext* /*pRenderContext*/, const SwBorderA
if ( !GetNext() )
{
//The last fills the remaining space in the upper.
- SwTwips nDiff = aRectFnSet.GetHeight(GetUpper()->PrintRA());
+ SwTwips nDiff = aRectFnSet.GetHeight(GetUpper()->getSwPrint());
SwFrame *pSibling = GetUpper()->Lower();
do
- { nDiff -= aRectFnSet.GetHeight(pSibling->FrameRA());
+ { nDiff -= aRectFnSet.GetHeight(pSibling->getSwFrame());
pSibling = pSibling->GetNext();
} while ( pSibling );
if ( nDiff > 0 )
@@ -4280,12 +4280,12 @@ void SwRowFrame::AdjustCells( const SwTwips nHeight, const bool bHeight )
if ( pCellFrame->GetTabBox()->getRowSpan() < 1 )
{
// Set height of current (covered) cell to new line height.
- const long nDiff = nHeight - aRectFnSet.GetHeight(pCellFrame->FrameRA());
+ const long nDiff = nHeight - aRectFnSet.GetHeight(pCellFrame->getSwFrame());
if ( nDiff )
{
- SwRect aFrm(pCellFrame->FrameRA());
+ SwRect aFrm(pCellFrame->getSwFrame());
aRectFnSet.AddBottom( aFrm, nDiff );
- pCellFrame->setFrame(aFrm);
+ pCellFrame->setSwFrame(aFrm);
pCellFrame->InvalidatePrt_();
}
@@ -4315,7 +4315,7 @@ void SwRowFrame::AdjustCells( const SwTwips nHeight, const bool bHeight )
// Use new height for the current row:
nSumRowHeight += pToAdjustRow == this ?
nHeight :
- aRectFnSet.GetHeight(pToAdjustRow->FrameRA());
+ aRectFnSet.GetHeight(pToAdjustRow->getSwFrame());
if ( nRowSpan-- == 1 )
break;
@@ -4326,14 +4326,14 @@ void SwRowFrame::AdjustCells( const SwTwips nHeight, const bool bHeight )
if ( pToAdjustRow && pToAdjustRow != this )
pToAdjustRow->InvalidateSize_();
- const long nDiff = nSumRowHeight - aRectFnSet.GetHeight(pToAdjust->FrameRA());
+ const long nDiff = nSumRowHeight - aRectFnSet.GetHeight(pToAdjust->getSwFrame());
if ( nDiff )
{
- aOldFrame = pToAdjust->FrameRA();
+ aOldFrame = pToAdjust->getSwFrame();
- SwRect aFrm(pToAdjust->FrameRA());
+ SwRect aFrm(pToAdjust->getSwFrame());
aRectFnSet.AddBottom( aFrm, nDiff );
- pToAdjust->setFrame(aFrm);
+ pToAdjust->setSwFrame(aFrm);
pNotify = pToAdjust;
}
@@ -4394,16 +4394,16 @@ SwTwips SwRowFrame::GrowFrame( SwTwips nDist, bool bTst, bool bInfo )
// There may still be some space left in my direct upper:
const SwTwips nAdditionalSpace =
- aRectFnSet.BottomDist( FrameRA(), aRectFnSet.GetPrtBottom(*GetUpper()->GetUpper()) );
+ aRectFnSet.BottomDist( getSwFrame(), aRectFnSet.GetPrtBottom(*GetUpper()->GetUpper()) );
if ( bRestrictTableGrowth && nAdditionalSpace > 0 )
{
nReal = std::min( nAdditionalSpace, nDist );
nDist -= nReal;
if ( !bTst )
{
- SwRect aFrm(FrameRA());
+ SwRect aFrm(getSwFrame());
aRectFnSet.AddBottom( aFrm, nReal );
- setFrame(aFrm);
+ setSwFrame(aFrm);
}
}
}
@@ -4430,7 +4430,7 @@ SwTwips SwRowFrame::GrowFrame( SwTwips nDist, bool bTst, bool bInfo )
if ( !bTst )
{
SwRectFnSet fnRectX(this);
- AdjustCells( fnRectX.GetHeight(PrintRA()) + nReal, true );
+ AdjustCells( fnRectX.GetHeight(getSwPrint()) + nReal, true );
if ( nReal )
SetCompletePaint();
}
@@ -4443,7 +4443,7 @@ SwTwips SwRowFrame::ShrinkFrame( SwTwips nDist, bool bTst, bool bInfo )
SwRectFnSet aRectFnSet(this);
if( HasFixSize() )
{
- AdjustCells( aRectFnSet.GetHeight(PrintRA()), true );
+ AdjustCells( aRectFnSet.GetHeight(getSwPrint()), true );
return 0L;
}
@@ -4465,7 +4465,7 @@ SwTwips SwRowFrame::ShrinkFrame( SwTwips nDist, bool bTst, bool bInfo )
// Only necessary to calculate minimal row height if height
// of pRow is at least nMinHeight. Otherwise nMinHeight is the
// minimum height.
- if( nMinHeight < aRectFnSet.GetHeight(FrameRA()) )
+ if( nMinHeight < aRectFnSet.GetHeight(getSwFrame()) )
{
// #i26945#
OSL_ENSURE( FindTabFrame(), "<SwRowFrame::ShrinkFrame(..)> - no table frame -> crash." );
@@ -4473,8 +4473,8 @@ SwTwips SwRowFrame::ShrinkFrame( SwTwips nDist, bool bTst, bool bInfo )
nMinHeight = lcl_CalcMinRowHeight( this, bConsiderObjs );
}
- if ( (aRectFnSet.GetHeight(FrameRA()) - nRealDist) < nMinHeight )
- nRealDist = aRectFnSet.GetHeight(FrameRA()) - nMinHeight;
+ if ( (aRectFnSet.GetHeight(getSwFrame()) - nRealDist) < nMinHeight )
+ nRealDist = aRectFnSet.GetHeight(getSwFrame()) - nMinHeight;
}
if ( nRealDist < 0 )
nRealDist = 0;
@@ -4484,8 +4484,8 @@ SwTwips SwRowFrame::ShrinkFrame( SwTwips nDist, bool bTst, bool bInfo )
{
if ( !bTst )
{
- SwTwips nHeight = aRectFnSet.GetHeight(FrameRA());
- SwRect aFrm(FrameRA());
+ SwTwips nHeight = aRectFnSet.GetHeight(getSwFrame());
+ SwRect aFrm(getSwFrame());
aRectFnSet.SetHeight( aFrm, nHeight - nReal );
if( IsVertical() && !IsVertLR() && !aRectFnSet.IsRev() )
@@ -4493,7 +4493,7 @@ SwTwips SwRowFrame::ShrinkFrame( SwTwips nDist, bool bTst, bool bInfo )
aFrm.Pos().X() += nReal;
}
- setFrame(aFrm);
+ setSwFrame(aFrm);
}
SwLayoutFrame* pFrame = GetUpper();
@@ -4505,8 +4505,8 @@ SwTwips SwRowFrame::ShrinkFrame( SwTwips nDist, bool bTst, bool bInfo )
if ( !bTst )
{
nReal -= nTmp;
- SwTwips nHeight = aRectFnSet.GetHeight(FrameRA());
- SwRect aFrm(FrameRA());
+ SwTwips nHeight = aRectFnSet.GetHeight(getSwFrame());
+ SwRect aFrm(getSwFrame());
aRectFnSet.SetHeight( aFrm, nHeight + nReal );
if( IsVertical() && !IsVertLR() && !aRectFnSet.IsRev() )
@@ -4514,7 +4514,7 @@ SwTwips SwRowFrame::ShrinkFrame( SwTwips nDist, bool bTst, bool bInfo )
aFrm.Pos().X() -= nReal;
}
- setFrame(aFrm);
+ setSwFrame(aFrm);
}
nReal = nTmp;
}
@@ -4540,7 +4540,7 @@ SwTwips SwRowFrame::ShrinkFrame( SwTwips nDist, bool bTst, bool bInfo )
pMasterTab->InvalidatePos();
}
}
- AdjustCells( aRectFnSet.GetHeight(PrintRA()) - nReal, true );
+ AdjustCells( aRectFnSet.GetHeight(getSwPrint()) - nReal, true );
}
return nReal;
}
@@ -4640,16 +4640,16 @@ static bool lcl_ArrangeLowers( SwLayoutFrame *pLay, long lYStart, bool bInva )
SwRectFnSet aRectFnSet(pLay);
while ( pFrame )
{
- long nFrameTop = aRectFnSet.GetTop(pFrame->FrameRA());
+ long nFrameTop = aRectFnSet.GetTop(pFrame->getSwFrame());
if( nFrameTop != lYStart )
{
bRet = true;
const long lDiff = aRectFnSet.YDiff( lYStart, nFrameTop );
const long lDiffX = lYStart - nFrameTop;
- SwRect aFrm(pFrame->FrameRA());
+ SwRect aFrm(pFrame->getSwFrame());
aRectFnSet.SubTop( aFrm, -lDiff );
aRectFnSet.AddBottom( aFrm, lDiff );
- pFrame->setFrame(aFrm);
+ pFrame->setSwFrame(aFrm);
pFrame->SetCompletePaint();
if ( !pFrame->GetNext() )
@@ -4658,7 +4658,7 @@ static bool lcl_ArrangeLowers( SwLayoutFrame *pLay, long lYStart, bool bInva )
pFrame->Prepare( PREP_POS_CHGD );
if ( pFrame->IsLayoutFrame() && static_cast<SwLayoutFrame*>(pFrame)->Lower() )
lcl_ArrangeLowers( static_cast<SwLayoutFrame*>(pFrame),
- aRectFnSet.GetTop(static_cast<SwLayoutFrame*>(pFrame)->Lower()->FrameRA())
+ aRectFnSet.GetTop(static_cast<SwLayoutFrame*>(pFrame)->Lower()->getSwFrame())
+ lDiffX, bInva );
if ( pFrame->GetDrawObjs() )
{
@@ -4700,15 +4700,15 @@ static bool lcl_ArrangeLowers( SwLayoutFrame *pLay, long lYStart, bool bInva )
// #i52904# - no direct move of objects,
// whose vertical position doesn't depend on anchor frame.
const bool bDirectMove =
- FAR_AWAY != pFly->FrameRA().Top() &&
+ FAR_AWAY != pFly->getSwFrame().Top() &&
bVertPosDepOnAnchor &&
!pFly->ConsiderObjWrapInfluenceOnObjPos();
if ( bDirectMove )
{
- SwRect aFrm(pFly->FrameRA());
+ SwRect aFrm(pFly->getSwFrame());
aRectFnSet.SubTop( aFrm, -lDiff );
aRectFnSet.AddBottom( aFrm, lDiff );
- pFly->setFrame(aFrm);
+ pFly->setSwFrame(aFrm);
pFly->GetVirtDrawObj()->SetRectsDirty();
// --> OD 2004-08-17 - also notify view of <SdrObject>
@@ -4833,7 +4833,7 @@ static bool lcl_ArrangeLowers( SwLayoutFrame *pLay, long lYStart, bool bInva )
// Columns and cells are ordered horizontal, not vertical
if( !pFrame->IsColumnFrame() && !pFrame->IsCellFrame() )
lYStart = aRectFnSet.YInc( lYStart,
- aRectFnSet.GetHeight(pFrame->FrameRA()) );
+ aRectFnSet.GetHeight(pFrame->getSwFrame()) );
// Nowadays, the content inside a cell can flow into the follow table.
// Thus, the cell may only grow up to the end of the environment.
@@ -4841,7 +4841,7 @@ static bool lcl_ArrangeLowers( SwLayoutFrame *pLay, long lYStart, bool bInva )
// Therefore we have to trigger a formatting for the frames, which do
// not fit into the cell anymore:
SwTwips nDistanceToUpperPrtBottom =
- aRectFnSet.BottomDist( pFrame->FrameRA(), aRectFnSet.GetPrtBottom(*pLay) );
+ aRectFnSet.BottomDist( pFrame->getSwFrame(), aRectFnSet.GetPrtBottom(*pLay) );
// #i56146# - Revise fix of issue #i26945#
// do *not* consider content inside fly frames, if it's an undersized paragraph.
// #i26945# - consider content inside fly frames
@@ -4920,7 +4920,7 @@ void SwCellFrame::Format( vcl::RenderContext* /*pRenderContext*/, const SwBorder
OSL_ENSURE( nWidth <= nWish, "Width of cell larger than table." );
OSL_ENSURE( nWidth > 0, "Box without width" );
- const long nPrtWidth = aRectFnSet.GetWidth(pTab->PrintRA());
+ const long nPrtWidth = aRectFnSet.GetWidth(pTab->getSwPrint());
if ( nWish != nPrtWidth )
{
// Avoid rounding problems, at least for the new table model
@@ -4951,7 +4951,7 @@ void SwCellFrame::Format( vcl::RenderContext* /*pRenderContext*/, const SwBorder
SwTwips nSumFrameWidths = 0;
while ( pTmpCell != this )
{
- nSumFrameWidths += aRectFnSet.GetWidth(pTmpCell->FrameRA());
+ nSumFrameWidths += aRectFnSet.GetWidth(pTmpCell->getSwFrame());
pTmpCell = pTmpCell->GetNext();
}
@@ -4971,16 +4971,16 @@ void SwCellFrame::Format( vcl::RenderContext* /*pRenderContext*/, const SwBorder
else
{
OSL_ENSURE( pAttrs->GetSize().Width() > 0, "Box without width" );
- nWidth = aRectFnSet.GetWidth(GetUpper()->PrintRA());
+ nWidth = aRectFnSet.GetWidth(GetUpper()->getSwPrint());
SwFrame *pPre = GetUpper()->Lower();
while ( pPre != this )
{
- nWidth -= aRectFnSet.GetWidth(pPre->FrameRA());
+ nWidth -= aRectFnSet.GetWidth(pPre->getSwFrame());
pPre = pPre->GetNext();
}
}
- const long nDiff = nWidth - aRectFnSet.GetWidth(FrameRA());
- SwRect aFrm(FrameRA());
+ const long nDiff = nWidth - aRectFnSet.GetWidth(getSwFrame());
+ SwRect aFrm(getSwFrame());
if( IsNeighbourFrame() && IsRightToLeft() )
{
@@ -4991,14 +4991,14 @@ void SwCellFrame::Format( vcl::RenderContext* /*pRenderContext*/, const SwBorder
aRectFnSet.AddRight( aFrm, nDiff );
}
- setFrame(aFrm);
+ setSwFrame(aFrm);
- SwRect aPrt(PrintRA());
+ SwRect aPrt(getSwPrint());
aRectFnSet.AddRight( aPrt, nDiff );
- setPrint(aPrt);
+ setSwPrint(aPrt);
//Adjust the height, it's defined through the content and the border.
- const long nDiffHeight = nRemaining - aRectFnSet.GetHeight(FrameRA());
+ const long nDiffHeight = nRemaining - aRectFnSet.GetHeight(getSwFrame());
if ( nDiffHeight )
{
if ( nDiffHeight > 0 )
@@ -5045,7 +5045,7 @@ void SwCellFrame::Format( vcl::RenderContext* /*pRenderContext*/, const SwBorder
//No alignment if border with flow overlaps the cell.
if ( pPg->GetSortedObjs() )
{
- SwRect aRect( PrintRA() ); aRect += FrameRA().Pos();
+ SwRect aRect( getSwPrint() ); aRect += getSwFrame().Pos();
for (SwAnchoredObject* pAnchoredObj : *pPg->GetSortedObjs())
{
SwRect aTmp( pAnchoredObj->GetObjRect() );
@@ -5085,11 +5085,11 @@ void SwCellFrame::Format( vcl::RenderContext* /*pRenderContext*/, const SwBorder
}
}
- long nPrtHeight = aRectFnSet.GetHeight(PrintRA());
+ long nPrtHeight = aRectFnSet.GetHeight(getSwPrint());
if( ( bVertDir && ( nRemaining -= lcl_CalcTopAndBottomMargin( *this, *pAttrs ) ) < nPrtHeight ) ||
- aRectFnSet.GetTop(Lower()->FrameRA()) != aRectFnSet.GetPrtTop(*this) )
+ aRectFnSet.GetTop(Lower()->getSwFrame()) != aRectFnSet.GetPrtTop(*this) )
{
- long nDiff = aRectFnSet.GetHeight(PrintRA()) - nRemaining;
+ long nDiff = aRectFnSet.GetHeight(getSwPrint()) - nRemaining;
if ( nDiff >= 0 )
{
long lTopOfst = 0;
@@ -5370,12 +5370,12 @@ static SwTwips lcl_CalcHeightOfFirstContentLine( const SwRowFrame& rSourceLine )
// If we are in a split row, there may be some space
// left in the cell frame of the master row.
// We look for the minimum of all first line heights;
- SwTwips nReal = aRectFnSet.GetHeight(pPrevCell->PrintRA());
+ SwTwips nReal = aRectFnSet.GetHeight(pPrevCell->getSwPrint());
const SwFrame* pFrame = pPrevCell->Lower();
const SwFrame* pLast = pFrame;
while ( pFrame )
{
- nReal -= aRectFnSet.GetHeight(pFrame->FrameRA());
+ nReal -= aRectFnSet.GetHeight(pFrame->getSwFrame());
pLast = pFrame;
pFrame = pFrame->GetNext();
}
@@ -5461,7 +5461,7 @@ SwTwips SwTabFrame::CalcHeightOfFirstContentLine() const
if ( bDontSplit )
{
// Table is not allowed to split: Take the whole height, that's all
- return aRectFnSet.GetHeight(FrameRA());
+ return aRectFnSet.GetHeight(getSwFrame());
}
SwTwips nTmpHeight = 0;
@@ -5512,7 +5512,7 @@ SwTwips SwTabFrame::CalcHeightOfFirstContentLine() const
if ( pFirstRow )
{
const bool bSplittable = pFirstRow->IsRowSplitAllowed();
- const SwTwips nFirstLineHeight = aRectFnSet.GetHeight(pFirstRow->FrameRA());
+ const SwTwips nFirstLineHeight = aRectFnSet.GetHeight(pFirstRow->getSwFrame());
if ( !bSplittable )
{