23 #include <osl/diagnose.h>
31 #include <viewimp.hxx>
56 #include <section.hxx>
58 #include <lineinfo.hxx>
74 m_pPrecede( nullptr ),
76 m_bUndersized( false ),
131 if ( bIgnoreMyOwnKeepValue && pFrame->
GetIndPrev() )
186 bool IsNextContentFullPage(
const SwFrame& rThis)
195 if (!pNextDrawObjs || !pNextDrawObjs->
size())
200 for (
const auto& pDrawObj : *pNextDrawObjs)
207 SwTwips nDrawObjHeight = pDrawObj->GetObjRectWithSpaces().Height();
208 const SwPageFrame* pPageFrame = pDrawObj->GetPageFrame();
215 if (nDrawObjHeight < nBodyHeight)
221 if (rSurround.
GetSurround() != text::WrapTextMode_NONE)
237 bool const bCheckIfLastRowShouldKeep)
const
246 bool bKeep = bCheckIfLastRowShouldKeep ||
249 rKeep.GetValue() && !IsNextContentFullPage(
m_rThis));
252 "IsKeep with bCheckIfLastRowShouldKeep should only be used for tabfrms" );
259 case SvxBreak::ColumnAfter:
260 case SvxBreak::ColumnBoth:
261 case SvxBreak::PageAfter:
262 case SvxBreak::PageBoth:
277 if ( bCheckIfLastRowShouldKeep )
284 if ( pThisSectionFrame )
285 pThisSection = pThisSectionFrame->
GetSection();
287 if ( pNextSectionFrame )
288 pNextSection = pNextSectionFrame->
GetSection();
290 if ( pThisSection != pNextSection )
315 case SvxBreak::ColumnBefore:
316 case SvxBreak::ColumnBoth:
317 case SvxBreak::PageBefore:
318 case SvxBreak::PageBoth:
360 }
while ( !nRet && pTmp );
367 for (
size_t i = 0; nRet < 3 &&
i < rObjs.
size(); ++
i )
373 if ( aRect.IsOver( rRect ) &&
379 if(
auto pFly = dynamic_cast<const SwFlyFrame*>(pObj) )
381 if ( pFly->IsAnLower( &
m_rThis ) )
405 if( ULONG_MAX == nIndex )
409 pNode = static_cast<SwTextFrame&>(
m_rThis).GetTextNodeFirst();
411 pNode = static_cast<SwNoTextFrame&>(
m_rThis).GetNode();
413 pNode = static_cast<SwSectionFormat*>(static_cast<SwSectionFrame&>(
m_rThis).
414 GetFormat())->GetSectionNode();
420 GetTabSortBoxes()[0]->GetSttNd()->FindTableNode();
424 if (nIndex < nTmpIndex &&
493 bool bUnlock = !
static_cast<SwFootnoteFrame*
>(pLay)->IsBackMoveLocked();
498 while ( pCnt && pLay->
IsAnLower( pCnt ) )
503 OSL_ENSURE( pCnt->
IsTextFrame(),
"The Graphic has landed." );
504 if ( static_cast<SwTextFrame*>(pCnt)->IsLocked() ||
535 if (
nullptr != pStart->
mpPrev )
545 if (
nullptr == pStart->
mpPrev )
595 if ( static_cast<SwTextFrame*>(pFloat)->GetCacheIdx() !=
USHRT_MAX )
596 static_cast<SwTextFrame*>(pFloat)->Init();
618 pSibling = static_cast<SwSectionFrame*>(pSibling)->ContainsAny();
626 pOldParent->
Shrink( nGrowVal );
627 pParent->
Grow( nGrowVal );
631 static_cast<SwFootnoteFrame*>(pParent)->InvalidateNxtFootnoteCnts( pParent->
FindPageFrame() );
637 OSL_ENSURE( pParent,
"No parent given." );
685 if ( pOldParent && !pOldParent->
Lower() &&
687 !(pSct = pOldParent->
FindSctFrame())->ContainsContent() &&
708 if ( pOldPage != pPage )
717 else if ( pSh && pSh->GetDoc()->GetLineNumberInfo().IsRestartEachPage()
731 {
if ( pAssumed == pFoll )
740 OSL_ENSURE(
IsFollow(),
"SwContentFrame::FindMaster(): !IsFollow" );
746 OSL_ENSURE( pPrec->
IsTextFrame(),
"NoTextFrame with follow found" );
750 OSL_FAIL(
"Follow is lost in Space." );
756 OSL_ENSURE(
IsFollow(),
"SwSectionFrame::FindMaster(): !IsFollow" );
765 if (pSect->GetFollow() ==
this)
767 pSect = aIter.
Next();
770 OSL_FAIL(
"Follow is lost in Space." );
776 OSL_ENSURE(
IsFollow(),
"SwTabFrame::FindMaster(): !IsFollow" );
808 OSL_FAIL(
"Follow is lost in Space." );
827 { pLeaf =
const_cast<SwFrame*
>(pLeaf)->
GetLeaf( eMakePage, bFwd );
830 (!
IsLayoutFrame() || !static_cast<const SwLayoutFrame*>(
this)->IsAnLower( pLeaf )))
838 }
while ( !bFound && pLeaf );
853 if ( bInTab && bInSct )
856 while ( pUpperFrame )
871 pUpperFrame = pUpperFrame->
GetUpper();
910 std::optional<sal_uInt16> oTmp;
938 if( pNewFlow == pFlow )
948 SAL_INFO(
"sw.pageframe",
"WrongPageDesc right: " << isRightPage
949 <<
" first: " << bFirst <<
" " << pNew->
GetFormat() <<
" == "
956 || (pNewDesc && pNewDesc == pDesc);
962 OSL_ENSURE( !
IsInFootnote(),
"GetNextLeaf(), don't call me for Footnote." );
963 OSL_ENSURE( !
IsInSct(),
"GetNextLeaf(), don't call me for Sections." );
1007 pOldLayLeaf = pLayLeaf;
1038 if( pFootnote && pFootnote->
GetRef() )
1055 pPg = static_cast<SwPageFrame*>(pPg->
GetPrev());
1057 if ( !pPg || pPg == pNew )
1062 pOldLayLeaf =
nullptr;
1094 OSL_ENSURE( !
IsInFootnote(),
"GetPrevLeaf(), don't call me for Footnote." );
1110 if ( pLayLeaf->
Lower() )
1112 pPrevLeaf = pLayLeaf;
1122 return pLayLeaf ? pLayLeaf : pPrevLeaf;
1163 if ( pObj->GetFrameFormat().GetDoc()->getIDocumentDrawModelAccess().IsVisibleLayerId(
1164 pObj->GetDrawObj()->GetLayer() ) &&
1165 pObj->GetFrameFormat().GetFollowTextFlow().GetValue() )
1167 const SwLayoutFrame* pVertPosOrientFrame = pObj->GetVertPosOrientFrame();
1168 if ( pVertPosOrientFrame &&
1169 pPreUp != pVertPosOrientFrame &&
1170 !pPreUp->
IsAnLower( pVertPosOrientFrame ) )
1212 OSL_ENSURE( pPrev->
IsInDocBody(),
"IsPageBreak: Not in DocBody?" );
1226 if ( eBreak == SvxBreak::PageBefore ||
1227 eBreak == SvxBreak::PageBoth ||
1228 ( bTreatSingleColumnBreakAsPageBreak && eBreak == SvxBreak::ColumnBefore && !
m_rThis.
FindColFrame() ))
1233 if ( ePrB == SvxBreak::PageAfter ||
1234 ePrB == SvxBreak::PageBoth ||
1283 if ( eBreak == SvxBreak::ColumnBefore ||
1284 eBreak == SvxBreak::ColumnBoth )
1289 if ( ePrB == SvxBreak::ColumnAfter ||
1290 ePrB == SvxBreak::ColumnBoth )
1318 OSL_FAIL(
"HasParaSpaceAtPages: Where's my page?" );
1333 return pTmp && !pTmp->
GetPrev();
1343 const SwFrame* pPrevFrame = _pProposedPrevFrame
1344 ? _pProposedPrevFrame
1348 while ( pPrevFrame &&
1350 static_cast<const SwTextFrame*
>(pPrevFrame)->IsHiddenNow() ) ||
1352 !
static_cast<const SwSectionFrame*
>(pPrevFrame)->GetSection() ) ) )
1354 pPrevFrame = pPrevFrame->
GetPrev();
1366 if ( pPrevFootnoteFrame )
1371 while ( pPrevFrame &&
1373 static_cast<const SwTextFrame*
>(pPrevFrame)->IsHiddenNow() ) ||
1375 !
static_cast<const SwSectionFrame*
>(pPrevFrame)->GetSection() ) ) )
1377 pPrevFrame = pPrevFrame->
GetPrev();
1392 if ( pPrevFrame && pPrevFrame->
IsInTab() )
1395 if ( pPrevSectFrame->
IsAnLower( pTableFrame ) )
1397 pPrevFrame = pTableFrame;
1401 while ( pPrevFrame &&
1403 static_cast<const SwTextFrame*
>(pPrevFrame)->IsHiddenNow() )
1405 pPrevFrame = pPrevFrame->
GetPrev();
1423 bool bIdenticalStyles =
false;
1429 bIdenticalStyles = pPrevFormatColl == pFormatColl;
1431 return bIdenticalStyles;
1437 auto pAccess = std::make_unique<SwBorderAttrAccess>(
SwFrame::GetCache(), pPrevFrame);
1448 const bool _bConsiderGrid )
const
1452 std::unique_ptr<SwBorderAttrAccess> pAccess;
1461 while( !pOwn &&
nullptr != ( pFoll = pFoll->
GetFollow() ) );
1468 pAttrs = pAccess->Get();
1485 const bool bContextualSpacing = bContextualSpacingThis
1486 && bContextualSpacingPrev
1487 && bIdenticalStyles;
1491 const bool bHalfContextualSpacing = !bContextualSpacing
1492 && bContextualSpacingThis
1493 && !bContextualSpacingPrev
1494 && bIdenticalStyles;
1498 const bool bHalfContextualSpacingPrev = !bContextualSpacing
1499 && !bContextualSpacingThis
1500 && bContextualSpacingPrev
1501 && bIdenticalStyles;
1508 bool bPrevLineSpacingProportional =
false;
1510 nPrevLowerSpace, nPrevLineSpacing,
1511 bPrevLineSpacingProportional,
1517 SwTwips nAdd = nPrevLineSpacing;
1520 if ( bUseFormerLineSpacing )
1525 nAdd = std::max( nAdd,
SwTwips(static_cast<SwTextFrame*>(pOwn)->GetLineSpace()) );
1545 if ( bPrevLineSpacingProportional )
1547 nAdd +=
static_cast<SwTextFrame*
>(pOwn)->GetLineSpace(
true );
1551 nAdd = std::max( nAdd,
SwTwips(static_cast<SwTextFrame*>(pOwn)->GetLineSpace(
true )) );
1559 nUpper = bContextualSpacing ? 0 : std::max(
1560 bHalfContextualSpacingPrev ? 0 : static_cast<tools::Long>(nPrevLowerSpace),
1561 bHalfContextualSpacing ? 0 : static_cast<tools::Long>(pAttrs->
GetULSpace().
GetUpper()) );
1565 if ( bUseFormerLineSpacing )
1569 nUpper = std::max( nUpper,
SwTwips(static_cast<SwTextFrame*>(pOwn)->GetLineSpace()) );
1570 if ( nPrevLineSpacing != 0 )
1572 nUpper = std::max( nUpper, nPrevLineSpacing );
1583 SwTwips nAdd = nPrevLineSpacing;
1593 if ( bPrevLineSpacingProportional )
1595 nAdd +=
static_cast<SwTextFrame*
>(pOwn)->GetLineSpace(
true );
1599 nAdd = std::max( nAdd,
SwTwips(static_cast<SwTextFrame*>(pOwn)->GetLineSpace(
true )) );
1636 const SwTwips _nUpperSpaceWithoutGrid )
const
1638 SwTwips nUpperSpaceAmountConsideredForPageGrid = 0;
1654 const SwTwips nProposedPrtTop =
1656 _nUpperSpaceWithoutGrid );
1658 const SwTwips nSpaceAbovePrtTop =
1659 aRectFnSet.
YDiff( nProposedPrtTop, nBodyPrtTop );
1660 const SwTwips nSpaceOfCompleteLinesAbove =
1661 nGridLineHeight * ( nSpaceAbovePrtTop / nGridLineHeight );
1663 aRectFnSet.
YInc( nBodyPrtTop, nSpaceOfCompleteLinesAbove );
1664 if ( aRectFnSet.
YDiff( nProposedPrtTop, nNewPrtTop ) > 0 )
1666 nNewPrtTop = aRectFnSet.
YInc( nNewPrtTop, nGridLineHeight );
1669 const SwTwips nNewUpperSpace =
1670 aRectFnSet.
YDiff( nNewPrtTop,
1673 nUpperSpaceAmountConsideredForPageGrid =
1674 nNewUpperSpace - _nUpperSpaceWithoutGrid;
1676 OSL_ENSURE( nUpperSpaceAmountConsideredForPageGrid >= 0,
1677 "<SwFlowFrame::GetUpperSpaceAmountConsideredForPageGrid(..)> - negative space considered for page grid!" );
1681 return nUpperSpaceAmountConsideredForPageGrid;
1691 SwTwips nUpperSpaceAmountOfPrevFrame = 0;
1699 bool bDummy =
false;
1701 if ( nPrevLowerSpace > 0 || nPrevLineSpacing > 0 )
1707 nUpperSpaceAmountOfPrevFrame = nPrevLowerSpace + nPrevLineSpacing;
1711 nUpperSpaceAmountOfPrevFrame = std::max( nPrevLowerSpace, nPrevLineSpacing );
1716 return nUpperSpaceAmountOfPrevFrame;
1727 SwTwips nUpperSpaceAmountConsideredForPrevFrameAndPageGrid = 0;
1731 nUpperSpaceAmountConsideredForPrevFrameAndPageGrid =
1738 return nUpperSpaceAmountConsideredForPrevFrameAndPageGrid;
1747 std::unique_ptr<SwBorderAttrAccess> pAttrAccess;
1751 _pAttrs = pAttrAccess->Get();
1754 bool bCommonBorder =
true;
1760 nLowerSpace = bCommonBorder ?
1793 SwTwips nAdditionalLowerSpace = 0;
1803 if ( pFrame && pFrame->
IsInTab() )
1806 if ( pSectFrame->
IsAnLower( pTableFrame ) )
1808 pFrame = pTableFrame;
1813 std::unique_ptr<SwBorderAttrAccess> pAttrAccess;
1814 if (pFrame && (!_pAttrs || pFrame != &
m_rThis))
1816 pAttrAccess = std::make_unique<SwBorderAttrAccess>(
SwFrame::GetCache(), pFrame);
1817 _pAttrs = pAttrAccess->Get();
1831 return nAdditionalLowerSpace;
1845 const SwFrame* pTmp =
nullptr;
1848 nullptr == ( pTmp =
static_cast<const SwSectionFrame*
>(pNxt)->ContainsAny() ) ) )
1877 bool bMovedFwd =
false;
1884 if ( !
MoveFwd( rbMakePage,
false ) )
1891 while (
MoveFwd( rbMakePage,
true ) )
1901 {
MoveFwd( rbMakePage,
false );
1936 SAL_WARN(
"sw.core",
"Tables in footnotes are not truly supported");
1970 if ( !pCol || !pCol->
GetPrev() )
1975 std::unique_ptr<SwFrameDeleteGuard> xDeleteGuard(bMakePage ?
new SwFrameDeleteGuard(pOldBoss) :
nullptr);
1977 bool bSamePage =
true;
2010 bool bBossChg = pNewBoss != pOldBoss;
2015 xDeleteGuard.reset();
2018 bool bFootnoteMoved =
false;
2027 const bool bForceSimpleFormat = pSect && pSect->
HasFollow() &&
2030 if ( pNewBoss != pOldBoss )
2033 bSamePage = pNewPage == pOldPage;
2042 "MoveFwd: Missing Content" );
2080 if ( bForceSimpleFormat )
2085 if ( bFootnoteMoved && !bSamePage )
2144 while ( pUpperFrame )
2156 bool bIsFollow =
const_cast<SwLayoutFrame*
>(pUpperFrame)->GetPrevCellLeaf();
2158 if ( ( pUpperFrame->
IsColumnFrame() && pUpperFrame->
IsInSct() ) || bIsFollowSection || bIsFollow )
2162 pUpperFrame = pUpperFrame->
GetUpper();
2172 bool bCheckPageDescs =
false;
2173 bool bCheckPageDescOfNextPage =
false;
2186 if( bEndnote && pFootnote->
IsInSct() )
2201 pRef = pFootnote->
GetRef();
2203 OSL_ENSURE( pRef,
"MoveBwd: Endnote for an empty section?" );
2208 if ( pOldBoss != pRefBoss &&
2233 if ( static_cast<SwPageFrame*>(pOldPage->
GetPrev())->IsEmptyPage() )
2260 if (pNewUpper && pNewUpper->
Lower())
2263 if ( pNewNextUpper &&
2272 pNewUpper = pNewNextUpper;
2273 bCheckPageDescOfNextPage =
true;
2277 bCheckPageDescs =
true;
2296 pNewUpper =
nullptr;
2314 if ( pNewNextUpper &&
2322 pNewUpper = pNewNextUpper;
2352 pNewUpper = pColBody;
2368 if ( pNewNextUpper &&
2377 pNewUpper = pNewNextUpper;
2385 pNewUpper = pColBody;
2408 sal_uInt32 nToPageNum( 0 );
2411 static_cast<SwTextFrame&>(
m_rThis),
2413 if ( bMoveFwdByObjPos &&
2416 pNewUpper =
nullptr;
2425 if ( pAnchoredObj->RestartLayoutProcess() &&
2426 !pAnchoredObj->IsTmpConsiderWrapInfluence() )
2428 pNewUpper =
nullptr;
2442 bool bProposedNewUpperContainsOnlyEmptySections(
true );
2447 if ( pLower->IsSctFrame() &&
2455 bProposedNewUpperContainsOnlyEmptySections =
false;
2460 if ( !bProposedNewUpperContainsOnlyEmptySections )
2470 pNewUpper =
nullptr;
2473 pNewUpper =
nullptr;
2478 if( !pNewUpper->
Lower() )
2498 pNewUpper =
nullptr;
2515 if( static_cast<SwSectionFrame*>(pIndNext)->GetSection() )
2526 OSL_ENSURE( !pIndNext || dynamic_cast<const SwTextFrame*>( pIndNext) !=
nullptr,
2527 "<SwFlowFrame::MovedBwd(..)> - incorrect next found." );
2531 pNewUpper =
nullptr;
2542 *
this, *pNewUpper ) )
2550 OSL_ENSURE( pNextNewUpper,
"<SwFlowFrame::MoveBwd(..)> - missing next new upper" );
2551 if ( pNextNewUpper &&
2561 pNewUpper =
nullptr;
2562 OSL_FAIL(
"<SwFlowFrame::MoveBwd(..)> - layout loop control for layout action <Move Backward> applied!" );
2567 "<SwFlowFrame::MoveBwd(..)> - moving backward to the current upper frame!?" );
2575 pNew->
Paste( pNewUpper );
2599 pSct->
Paste( pNewUpper );
2606 bool bUnlock =
false;
2607 bool bFollow =
false;
2620 #if BOOST_VERSION < 105600
2621 std::list<SwFrameDeleteGuard> g;
2623 ::std::optional<SwFrameDeleteGuard> g;
2629 if ( pTabFrame->IsFollow()
2630 &&
static_cast<SwTabFrame const*
>(pTabFrame->GetPrecede())->HasFollowFlowLine()
2634 #if BOOST_VERSION < 105600
2644 "MoveBwd(): pNewUpper->Calc() moved this frame?");
2651 bool bFormatSect(
false );
2659 if ( pSect == pNewUpper )
2670 if( pNewPage != pOldPage )
2685 if ( bCheckPageDescs && pNewPage->
GetNext() )
2687 SwPageFrame* pStartPage = bCheckPageDescOfNextPage ?
2701 return pNewUpper !=
nullptr;
2707 return static_cast<SwContentFrame*>(pFrame);
2709 return static_cast<SwTabFrame*>(pFrame);
2711 return static_cast<SwSectionFrame*>(pFrame);
2718 return static_cast<const SwContentFrame*>(pFrame);
2720 return static_cast<const SwTabFrame*>(pFrame);
2722 return static_cast<const SwSectionFrame*>(pFrame);
bool IsAnLower(const SwFrame *) const
vcl::RenderContext * GetOut() const
SwFrame * FindFooterOrHeader()
SwSectionFrame * FindMaster() const
bool IsKeepFwdMoveAllowed(bool bIgnoreMyOwnKeepValue=false)
sal_uInt16 CalcBottomLine() const
Base class of the Writer layout elements.
Base class that provides the general functionalities for frames that are allowed at page breaks (flow...
Represents the visualization of a paragraph.
const ::std::optional< sal_uInt16 > & GetNumOffset() const
virtual SwRect GetObjRect() const =0
sal_uLong GetIndex() const
const SwSortedObjs * GetDrawObjs() const
Represents the style of a paragraph.
SwPageDesc * FindPageDesc()
SwContentFrame * GetNextContentFrame() const
Pagedescriptor Client of SwPageDesc that is "described" by the attribute.
SwTwips Grow(SwTwips, bool bTst=false, bool bInfo=false)
sal_uInt16 GetLower() const
static void SetMoveBwdJump(bool bNew)
bool MoveFwd(bool bMakePage, bool bPageBreak, bool bMoveAlways=false)
Return value guarantees that a new page was not created, although false does not NECESSARILY indicate...
SwPageDesc * GetPageDesc()
void DelEmpty(bool bRemove)
static void CheckPageDescs(SwPageFrame *pStart, bool bNotifyFields=true, SwPageFrame **ppPrev=nullptr)
Check all pages (starting from the given one) if they use the appropriate frame format.
bool IsBefore(const SwLayoutFrame *_pCheckRefLayFrame) const
method to check relative position of layout frame to a given layout frame.
bool IsKeep(SvxFormatKeepItem const &rKeep, SvxFormatBreakItem const &rBreak, bool bBreakCheck=false) const
method to determine if a Keep needs to be considered (Breaks!)
const SwTable * GetTable() const
void SetCompletePaint() const
bool IsInFootnote() const
virtual bool Prepare(const PrepareHint ePrep=PrepareHint::Clear, const void *pVoid=nullptr, bool bNotify=true)
SwLayoutFrame * GetPrevLeaf()
Returns the previous layout leaf where we can move the frame.
SwFrameType GetType() const
bool IsPrevObjMove() const
void InvalidateLineNum_()
static SwCache & GetCache()
SwTabFrame is one table in the document layout, containing rows (which contain cells).
SwTwips GetUpperSpaceAmountConsideredForPageGrid_(const SwTwips _nUpperSpaceWithoutGrid) const
method to determine the upper space amount, which is considered for the page grid ...
SwTwips CalcLowerSpace(const SwBorderAttrs *_pAttrs=nullptr) const
calculation of lower space
bool MoveBwd(bool &rbReformat)
Return value tells whether any changes have been made.
SwSectionFormat * GetFormat()
static bool lcl_IdenticalStyles(const SwFrame *pPrevFrame, const SwFrame *pFrame)
Compare styles attached to these text frames.
static void DestroyFrame(SwFrame *const pFrame)
this is the only way to delete a SwFrame instance
virtual void Calc(vcl::RenderContext *pRenderContext) const
bool IsFootnotePage() const
Foot note interface.
Of course Writer needs its own rectangles.
virtual const SvxFormatBreakItem & GetBreakItem() const
SwContentFrame * FindFirstBodyContent()
virtual const SwFormatPageDesc & GetPageDescItem() const
const SwFrame * GetPrevFrameForUpperSpaceCalc_(const SwFrame *_pProposedPrevFrame=nullptr) const
helper method to determine previous frame for calculation of the upper space
static SwFlowFrame * CastFlowFrame(SwFrame *pFrame)
bool IsFootnoteFrame() const
SwLayoutFrame * GetPrevSctLeaf()
Returns the preceding layout sheet where the frame can be moved into.
void CheckDirChange()
checks the layout direction and invalidates the lower frames recursively, if necessary.
sal_uInt16 GetPhyPageNum() const
tools::Long GetTop(const SwRect &rRect) const
IDocumentFieldsAccess const & getIDocumentFieldsAccess() const
SwTwips CalcUpperSpace(const SwBorderAttrs *pAttrs=nullptr, const SwFrame *pPr=nullptr, const bool _bConsiderGrid=true) const
method to determine the upper space hold by the frame
void InvalidateNextPrtArea()
method to invalidate printing area of next frame #i11859#
wrapper class for the positioning of Writer fly frames and drawing objects
const SvxFormatBreakItem & GetBreak(bool=true) const
void SetContentLock(bool bNew)
bool IsMoveable(const SwLayoutFrame *_pLayoutFrame=nullptr) const
determine, if frame is moveable in given environment
const SwLayoutFrame * GetPrevLayoutLeaf() const
const SwRect & getFrameArea() const
const BorderLinePrimitive2D *pCandidateB assert(pCandidateA)
bool getBrowseMode() const
SwLayoutFrame * GetNextLeaf(MakePageType eMakePage)
Returns the next layout leaf in which we can move the frame.
const SwPageFrame * GetLastPage() const
sal_uLong GetIndex() const
bool IsPageBreak(bool bAct) const
|* If there's a hard page break before the Frame AND there's a |* predecessor on the same page...
const SvxFormatKeepItem & GetKeep(bool=true) const
SwLayoutFrame * GetNextCellLeaf()
SwLayoutFrame * GetNextSctLeaf(MakePageType eMakePage)
Returns the next layout sheet where the frame can be moved in.
const SwAttrSet * GetAttrSet() const
WARNING: this may not return correct RES_PAGEDESC/RES_BREAK items for SwTextFrame, use GetBreakItem()/GetPageDescItem() instead.
static bool MoveBwdSuppressed(const SwDoc &p_rDoc, const SwFlowFrame &p_rFlowFrame, const SwLayoutFrame &p_rNewUpperFrame)
const SwFrame & GetFrame() const
virtual void Paste(SwFrame *pParent, SwFrame *pSibling=nullptr)=0
bool IsColumnFrame() const
SwFootnoteFrame * FindFootnoteFrame()
bool FrameContainsNode(SwContentFrame const &rFrame, sal_uLong nNodeIndex)
SwTextNode const * GetTextNodeForParaProps() const
void InvalidateAutoCompleteWords() const
SwTabFrame * FindMaster(bool bFirstMaster=false) const
bool IsContentFrame() const
SwFrame * GetIndPrev() const
const SwContentFrame * GetFollow() const
const SdrObject * GetDrawObj() const
const SwSortedObjs * GetSortedObjs() const
void InvalidateSpelling() const
bool HasParaSpaceAtPages(bool bSct) const
static bool s_bMoveBwdJump
indicates that a backward move was done over multiple pages
bool IsFwdMoveAllowed() const
const SwFrame * GetLastLower() const
virtual bool ShouldBwdMoved(SwLayoutFrame *pNewUpper, bool &rReformat)=0
SwTwips CalcAddLowerSpaceAsLastInTableCell(const SwBorderAttrs *_pAttrs=nullptr) const
calculation of the additional space to be considered, if flow frame is the last inside a table cell ...
sal_uInt16 GetBottomLine(const SwFrame &_rFrame) const
virtual void Paste(SwFrame *pParent, SwFrame *pSibling=nullptr) override
const SwSectionFrame * GetFollow() const
SwPageFrame * FindPageFrame()
virtual bool IsDeleteForbidden() const
virtual void Cut() override
SwFrameFormat * GetLeftFormat(bool const bFirst=false)
tools::Long YInc(tools::Long n1, tools::Long n2) const
const SwFrame * Lower() const
SwContentFrame * FindNextCnt(const bool _bInSameFootnote=false)
SwTextGridItem const * GetGridItem(SwPageFrame const *const)
SwPageDesc * GetPageDesc()
void InvalidatePage(const SwPageFrame *pPage=nullptr) const
Invalidates the page in which the Frame is currently placed.
virtual void SetNewFieldLst(bool bFlag)=0
tools::Long GetHeight(const SwRect &rRect) const
bool IsJoinLocked() const
void SetFollow(SwFlowFrame *const pFollow)
bool IsAction() const
SS for the Lay-/IdleAction and relatives.
SwLayoutFrame * GetUpper()
static bool PasteTree(SwFrame *, SwLayoutFrame *, SwFrame *, SwFrame *)
A specialized form of Paste(), which relocates a whole chain (this and the following, in particular).
void InvalidateSmartTags() const
SwTwips GetUpperSpaceAmountConsideredForPrevFrameAndPageGrid() const
method to determine the upper space amount, which is considered for the previous frame and the page g...
tools::Long GetPrtTop(const SwFrame &rFrame) const
SwFootnoteBossFrame * FindFootnoteBossFrame(bool bFootnotes=false)
Provides access to settings of a document.
bool HasLockedFollow() const
sal_uInt16 GetTopLine(const SwFrame &_rFrame, const SwFrame *_pPrevFrame=nullptr) const
bool isFrameAreaPositionValid() const
tools::Long YDiff(tools::Long n1, tools::Long n2) const
bool isFrameAreaSizeValid() const
SwContentFrame * FindLastContent(SwFindMode nMode=SwFindMode::None)
A page of the document layout.
const SwFormatFootnote & GetFootnote() const
sal_uInt8 BwdMoveNecessary(const SwPageFrame *pPage, const SwRect &rRect)
method to determine overlapping of an object that requests floating
SwTwips Shrink(SwTwips, bool bTst=false, bool bInfo=false)
SwLayoutFrame * GetPrevFootnoteLeaf(MakePageType eMakeFootnote)
Get the preceding layout leaf in that the frame can be moved.
bool CheckMoveFwd(bool &rbMakePage, bool bKeep, bool bIgnoreMyOwnKeepValue)
Moves the Frame forward if it seems necessary regarding the current conditions and attributes...
SwSectionFrame * FindSctFrame()
const SwPageDesc * GetFollow() const
void setFrameAreaPositionValid(bool bNew)
bool IsLayoutFrame() const
const SwFlowFrame * GetPrecede() const
SwContentFrame * FindLastBodyContent()
Searches the last ContentFrame in BodyText below the page.
SwRowFrame * GetFirstNonHeadlineRow() const
void MoveSubTree(SwLayoutFrame *pParent, SwFrame *pSibling=nullptr)
hook tree onto new parent with minimal operations and notifications
SwLayoutFrame * GetLeaf(MakePageType eMakePage, bool bFwd)
bool IsSquaredPageMode() const
SwLayAction & GetLayAction()
bool IsRightPageByNumber(SwRootFrame const &rLayout, sal_uInt16 nPageNum)
sal_uInt16 CalcLineSpacing() const
virtual SwFrameFormat & GetFrameFormat()=0
#define SAL_WARN_IF(condition, area, stream)
SwTextFrame * FindMaster() const
sal_uInt16 GetPhyPageNum() const
bool MoveLowerFootnotes(SwContentFrame *pStart, SwFootnoteBossFrame *pOldBoss, SwFootnoteBossFrame *pNewBoss, const bool bFootnoteNums)
Moving the Footnotes of all Lowers - starting from StartContent.
const SwViewOption * GetViewOptions() const
bool ForbiddenForFootnoteCntFwd() const
const SwFrame * ContainsAny(const bool _bInvestigateFootnoteForSections=false) const
Method doesn't investigate content of footnotes by default.
SwTwips GetUpperSpaceAmountConsideredForPrevFrame() const
method to determine the upper space amount, which is considered for the previous frame ...
const o3tl::enumarray< SvxAdjust, unsigned short > aSvxToUnoAdjust USHRT_MAX
const SvxParaGridItem & GetParaGrid(bool=true) const
#define SAL_INFO(area, stream)
const SwFormatPageDesc & GetPageDesc(bool=true) const
SwFrameFormat * GetRightFormat(bool const bFirst=false)
Layout uses the following methods to obtain a format in order to be able to create a page...
bool IsNoTextFrame() const
static SwLayoutFrame * CutTree(SwFrame *)
A specialized form of Cut(), which relocates a whole chain (this and the following, in particular).
IDocumentSettingAccess const & getIDocumentSettingAccess() const
const SwDoc * GetDoc() const
SwLayoutFrame * GetPrevCellLeaf()
bool IsColBodyFrame() const
These SwFrame inlines are here, so that frame.hxx does not need to include layfrm.hxx.
bool IsColBreak(bool bAct) const
|* If there's a hard column break before the Frame AND there is |* a predecessor in the same column...
virtual bool get(DocumentSettingId id) const =0
Return the specified document setting.
bool IsAnFollow(const SwFlowFrame *pFlow) const
bool IsContentLocked() const
const SwTabFrame * GetFollow() const
SwLayoutFrame * GetNextFootnoteLeaf(MakePageType eMakePage)
Return the next layout leaf in that the frame can be moved.
SwFlowFrame(SwFrame &rFrame)
tools::Long GetBottom(const SwRect &rRect) const
#define SAL_WARN(area, stream)
SwFormatColl * GetFormatColl() const
A layout frame is a frame that contains other frames (m_pLower), e.g. SwPageFrame or SwTabFrame...
const SwFrame * GetAnchorFrame() const
const SwLayoutFrame * GetNextLayoutLeaf() const
SwPageFrame * InsertPage(SwPageFrame *pSibling, bool bFootnote)
static bool FrameMovedFwdByObjPos(const SwDoc &_rDoc, const SwTextFrame &_rTextFrame, sal_uInt32 &_ornToPageNum)
sal_uInt16 GetBaseHeight() const
bool IsFootnoteContFrame() const
bool WrongPageDesc(SwPageFrame *pNew)
const SwContentFrame * ContainsContent() const
Checks if the frame contains one or more ContentFrame's anywhere in his subsidiary structure; if so t...
void InvalidateWordCount() const
const SwFlowFrame * GetFollow() const
SwViewShell * GetCurrShell() const
class for collecting anchored objects
void Height(tools::Long nNew)
Container of body content (i.e.
sal_uInt16 GetRubyHeight() const
bool IsFooterFrame() const
SwRootFrame * getRootFrame()
sal_uInt16 GetUpper() const
bool IsHeaderFrame() const
virtual const SwFrameFormat * GetFormat() const
#define PROTOCOL_ENTER(pFrame, nFunc, nAct, pPar)
const SvxULSpaceItem & GetULSpace() const
SwTabFrame * FindTabFrame()
static bool IsMoveBwdJump()
static bool lcl_getContextualSpacing(const SwFrame *pPrevFrame)
Base class of the Writer document model elements.