20#include <config_wasm_strip.h>
23#include <osl/diagnose.h>
75: mbFrameAreaPositionValid(false),
76 mbFrameAreaSizeValid(false),
77 mbFramePrintAreaValid(false),
120 if(mrTarget.maFramePrintArea != *
this)
122 mrTarget.maFramePrintArea = *
this;
134 rFrameArea.
Left(), rFrameArea.
Top());
146 rFramePrintArea.
Left() + rFrameArea.
Left(),
147 rFramePrintArea.
Top() + rFrameArea.
Top());
158 aFrm.
Pos().AdjustX(rOffset.X() );
163 aFrm.
Pos().AdjustY(rOffset.Y() );
173 return mrSwFrameAreaDefinition.getFrameArea();
178 double fRotate, fShearX;
179 rSource.
decompose(aScale, aTranslate, fRotate, fShearX);
197 return mrSwFrameAreaDefinition.getFramePrintArea();
202 double fRotate, fShearX;
203 rSource.
decompose(aScale, aTranslate, fRotate, fShearX);
206 const SwRect aUntransformedFrameArea(getUntransformedFrameArea());
225 const SwRect& rFrameArea(mrSwFrameAreaDefinition.getFrameArea());
226 const SwRect& rFramePrintArea(mrSwFrameAreaDefinition.getFramePrintArea());
230 rFrameArea.
Left(), rFrameArea.
Top());
233 rFramePrintArea.
Left() + rFrameArea.
Left(), rFramePrintArea.
Top() + rFrameArea.
Top());
238 if(!getLocalFrameAreaTransformation().isIdentity())
241 aRangeFrameArea.
transform(getLocalFrameAreaTransformation());
246 if(aNewFrm != mrSwFrameAreaDefinition.getFrameArea())
253 if(getLocalFramePrintAreaTransformation().isIdentity())
257 aRangeFramePrintArea.
transform(getLocalFramePrintAreaTransformation());
264 if(aNewPrt != mrSwFrameAreaDefinition.getFramePrintArea())
275 if(!getLocalFrameAreaTransformation().isIdentity())
278 aFrm.
setSwRect(getUntransformedFrameArea());
281 if(!getLocalFramePrintAreaTransformation().isIdentity())
284 aPrt.
setSwRect(getUntransformedFramePrintArea());
291 maFrameAreaTransformation *= aTransform;
292 maFramePrintAreaTransformation *= aTransform;
297 mpRoot( pSib ? pSib->getRootFrame() : nullptr ),
305 mbRightToLeft(false),
307 mbDerivedVert(false),
311 mbValidLineNum(false),
313 mbCompletePaint(true),
319 mbInfFootnote ( false ),
322 m_isInDestroy(false),
325 OSL_ENSURE( pMod,
"No frame format given." );
345 if( SvxFrameDirection::Environment == nDir || ( bVert && bOnlyBiDi ) )
348 if( SvxFrameDirection::Environment == nDir )
355 if( SvxFrameDirection::Horizontal_LR_TB == nDir || SvxFrameDirection::Horizontal_RL_TB == nDir
365 if(SvxFrameDirection::Vertical_RL_TB == nDir)
370 else if(SvxFrameDirection::Vertical_LR_TB==nDir)
375 else if (nDir == SvxFrameDirection::Vertical_LR_BT)
380 else if (nDir == SvxFrameDirection::Vertical_RL_TB90)
391 if( SvxFrameDirection::Horizontal_RL_TB == nDir )
423 bVert,
true, bBrowseMode );
437 bVert,
false, bBrowseMode );
451 bVert,
true, bBrowseMode );
468 CheckDir( pFrameDirItem->GetValue(), bVert,
false, bBrowseMode );
479 bVert,
true, bBrowseMode);
484 if (rHint.
GetId() != SfxHintId::SwLegacyModify)
489 if(pLegacy->m_pOld && pLegacy->m_pNew &&
RES_ATTRSET_CHG == pLegacy->m_pNew->Which())
524 &&
nullptr != (pNxt =
GetNext()))
537 sal_uInt16 nWhich = pOld ? pOld->
Which() : pNew ? pNew->
Which() : 0;
586 if ( bInFollowFlowRow )
594 OSL_FAIL(
"Columns for new FrameType?" );
635 const_cast<SwFlyFrame*
>(pFlyFrame)->FindPageFrameOfAnchor();
636 if ( pPageFrameOfAnchor && pPageFrameOfAnchor != pPage )
644 if ( !(pPage && pPage->
GetUpper()) )
720 for (
auto const& e : pMergedPara->extents)
722 if (e.pNode != pNode)
746 if ( aNewSize == aOldSize )
776 if ( nReal != nDiff )
779 (aFrm.*fnRect->
fnSetHeight)( nNew - nDiff + nReal );
810 aFrm.
SSize( aNewSize );
843 OSL_ENSURE( pParent,
"No parent for insert." );
844 OSL_ENSURE( (!pBehind || pParent == pBehind->
GetUpper()),
845 "Frame tree is inconsistent." );
879 OSL_ENSURE( pParent,
"No Parent for Insert." );
880 OSL_ENSURE( (!pBefore || pParent == pBefore->
GetUpper()),
881 "Frame tree is inconsistent." );
897 if ( pParent->
Lower() )
918 OSL_ENSURE( pParent,
"No parent for insert." );
919 OSL_ENSURE( (!pBehind || ( (pBehind && (pParent == pBehind->
GetUpper()))
921 "Frame tree inconsistent." );
958 pBehind->
mpPrev =
nullptr;
964 OSL_ENSURE( pTmp,
"InsertGrp: Missing ColBody" );
977 OSL_ENSURE( pSct->
IsSctFrame(),
"InsertGroup: For SectionFrames only" );
1020 OSL_ENSURE(
mpUpper,
"Remove without upper?" );
1040 OSL_ENSURE( pParent,
"No parent for pasting." );
1041 OSL_ENSURE( pParent->
IsLayoutFrame(),
"Parent is ContentFrame." );
1042 OSL_ENSURE( pParent !=
this,
"I'm the parent." );
1043 OSL_ENSURE( pSibling !=
this,
"I'm my own neighbour." );
1045 "I'm still registered somewhere" );
1047 "<SwContentFrame::Paste(..)> - sibling not of expected type." );
1117 if( pFrame &&
nullptr != (pFrame=
static_cast<SwLayoutFrame*
>(pFrame)->ContainsAny()) )
1127 while ( pNxt && pNxt->
IsInTab() )
1130 if(
nullptr != pNxt )
1143 OSL_ENSURE(
GetUpper(),
"Cut without Upper()." );
1169 while ( pNxt && pNxt->
IsInTab() )
1172 if(
nullptr != pNxt )
1207 if( !pSct->IsFollow() )
1219 if (
nullptr != pFrame )
1254 if( !pSct->IsFollow() )
1265 if (pThisTab && pThisTab->IsFollow())
1277 assert(!pMasterTab);
1289 if ( !pUp->
Lower() &&
1345 pUp->
Shrink( nFrameHeight );
1351 OSL_ENSURE( pParent,
"No parent for pasting." );
1352 OSL_ENSURE( pParent->
IsLayoutFrame(),
"Parent is ContentFrame." );
1353 OSL_ENSURE( pParent !=
this,
"I'm the parent oneself." );
1354 OSL_ENSURE( pSibling !=
this,
"I'm my own neighbour." );
1356 "I'm still registered somewhere." );
1403 if(
nullptr != pFrame )
1440 nReal += pParent->
Grow( nGrow - nReal );
1463 if ( pUp && nShrink )
1475 if( nReal < nShrink )
1486 nReal += pUp->
Shrink( nShrink - nReal );
1490 aRectFnSet.
SetHeight( aFrm, nOldHeight );
1508 if( pUp && !pUp->
Lower() )
1517 OSL_ENSURE( nDist >= 0,
"Negative growth?" );
1526 if( nPrtHeight > 0 && nDist > (
LONG_MAX - nPrtHeight) )
1530 return static_cast<SwFlyFrame*
>(
this)->Grow_( nDist, bTst );
1561 OSL_ENSURE( nDist >= 0,
"Negative reduction?" );
1568 return static_cast<SwFlyFrame*
>(
this)->Shrink_( nDist, bTst );
1678 nChg = nTmp <= 0 ? 0 : nTmp;
1684 aInva.
Height( nChg + nTmp );
1692 if ( pViewShell && !pUp->
GetPrev() &&
1697 nInvaAdd = -(nDiff - nChg);
1721 if ( !bTst && nChg )
1761 aPrt.
Height( nOldFrameHeight );
1770 aFrm.
Height( nOldFrameHeight );
1773 aPrt.
Height( nOldPrtHeight );
1834 const bool bFootnotePage = pBoss->
IsPageFrame() &&
static_cast<const SwPageFrame*
>(pBoss)->IsFootnotePage();
1847 if( !bFootnotePage )
1864 nAdd = nDiff - nReal;
1865 if ( nAdd > nAddMax )
1871 aRectFnSet.
SetHeight(aFrm, nAddMax-nAdd);
1875 aFrm.
Pos().AdjustX(nAdd );
1890 if ( !bTst && nReal )
1896 aRectFnSet.
SetHeight( aFrm, nTmp - nReal );
1900 aFrm.
Pos().AdjustX(nReal );
1909 if( nReal < 0 && pFrame->
IsInSct() )
1919 OSL_ENSURE( pBoss->
IsPageFrame(),
"Header/Footer out of page?" );
1922 if (
auto pFly = pAnchoredObj->DynCastFlyFrame() )
1924 OSL_ENSURE( !pFly->IsFlyInContentFrame(),
"FlyInCnt at Page?" );
1939 pFly->InvalidatePos_();
1940 pFly->Invalidate_();
1946 return (nBrowseAdd + nReal + nAdd);
1969 static_cast<SwFlyFrame*
>(
this)->Invalidate_();
1985 static_cast<SwFlyFrame*
>(
this)->Invalidate_();
2003 static_cast<SwFlyFrame*
>(
this)->Invalidate_();
2019 OSL_ENSURE(
IsTextFrame(),
"line numbers are implemented for text only" );
2072 const bool bOnlyObject = 1 == nStage;
2073 const bool bIncludeObjects = 1 <= nStage;
2082 if ( bIncludeObjects )
2087 const size_t nCnt = pObjs->
size();
2088 for (
size_t i = 0;
i < nCnt; ++
i )
2092 pFlyFrame->ValidateThisAndAllLowers( 2 );
2094 pAnchoredDrawObj->ValidateThis();
2115 if( nFrameHeight > 0 &&
2116 nDist > (
LONG_MAX - nFrameHeight ) )
2130 aRectFnSet.
SetHeight( aFrm, nFrameHeight + nDist );
2134 aFrm.
Pos().AdjustX( -nDist );
2157 while( pFrame && nReal > 0 )
2170 aRectFnSet.
SetHeight( aFrm, nOld + nDist );
2174 aFrm.
Pos().AdjustX( -nDist );
2182 !pTab->IsJoinLocked() &&
2192 if ( nReal < nDist )
2197 nReal =
GetUpper()->
Grow( nDist - std::max<tools::Long>(nReal, 0),
2234 OSL_ENSURE( nDist >= 0,
"nDist < 0" );
2236 "nDist > than current size." );
2245 if( nRstHeight < 0 )
2257 nRstHeight = nDist + nRstHeight - nNextHeight;
2270 aFrm.
Pos().AdjustX(nDist );
2279 !pTab->IsJoinLocked() &&
2304 bool bInvalidate =
true;
2312 const SwRect aBound( pAnchoredObj->GetObjRectWithSpaces() );
2319 const SwFrameFormat& rFormat = pAnchoredObj->GetFrameFormat();
2322 const SwFrame* pAnchor = pAnchoredObj->GetAnchorFrame();
2325 bInvalidate =
false;
2354 if (rHint.
GetId() != SfxHintId::SwLegacyModify)
2358 if(pLegacy->m_pNew &&
RES_ATTRSET_CHG == pLegacy->m_pNew->Which() && pLegacy->m_pOld)
2360 auto& rOldSetChg = *
static_cast<const SwAttrSetChg*
>(pLegacy->m_pOld);
2361 auto& rNewSetChg = *
static_cast<const SwAttrSetChg*
>(pLegacy->m_pNew);
2370 UpdateAttr_(pOItem, pNItem, eInvFlags, &aOldSet, &aNewSet);
2378 UpdateAttr_(pLegacy->m_pOld, pLegacy->m_pNew, eInvFlags);
2432 sal_uInt16 nWhich = pOld ? pOld->
Which() : pNew ? pNew->
Which() : 0;
2576 if ( pOldSet || pNewSet )
2654 if ( nFrameHeight > 0 && nDist > (
LONG_MAX - nFrameHeight) )
2671 bool bMoveAccFrame =
false;
2677 aRectFnSet.
SetHeight( aFrm, nFrameHeight + nDist );
2681 aFrm.
Pos().AdjustX( -nDist );
2684 bMoveAccFrame =
true;
2722 nGrow = pToGrow ? pToGrow->
Grow( nReal, bTst, bInfo ) : 0;
2731 SwTwips nSpace = bTst ? 0 : -nDist;
2736 }
while ( pFrame !=
GetNext() );
2741 if ( nReal > nSpace )
2743 if ( nReal && !bTst )
2760 if( nReal != nDist &&
2765 aRectFnSet.
SetHeight( aFrm, nFrameHeight + nReal );
2772 bMoveAccFrame =
true;
2799 std::unique_ptr<SvxBrushItem> aBack(
GetFormat()->makeBackgroundBrushItem());
2806#if !ENABLE_WASM_STRIP_ACCESSIBILITY
2817 (void)bMoveAccFrame;
2849 OSL_ENSURE( nDist >= 0,
"nDist < 0" );
2852 if ( nDist > nFrameHeight )
2853 nDist = nFrameHeight;
2862 while( pFrame && nMin < nTmp )
2870 if( nReal > nMinDiff )
2876 bool bMoveAccFrame =
false;
2882 aRectFnSet.
SetHeight( aFrm, nFrameHeight - nReal );
2886 aFrm.
Pos().AdjustX(nReal );
2889 bMoveAccFrame =
true;
2904 if ( !bTst &&
IsBodyFrame() && nReal < nRealDist )
2911 aFrm.
Pos().AdjustX(nRealDist - nReal );
2921 if ( nTmp != nReal )
2928 aFrm.
Pos().AdjustX(nTmp - nReal );
2950 nReal = pToShrink ? pToShrink->
Shrink( nShrink, bTst, bInfo ) : 0;
2952 && nReal < nShrink )
2956#if !ENABLE_WASM_STRIP_ACCESSIBILITY
2968 (void)bMoveAccFrame;
2980 static_cast<SwTabFrame*
>(
this)->SetComplete();
2987 static_cast<SwTabFrame*
>(
this)->SetComplete();
2996 bool bCompletePaint =
true;
3003 bCompletePaint =
false;
3019 nullptr != (pCnt =
static_cast<SwFootnoteFrame*
>(
this)->GetRefFromAttr() ) )
3021 if ( pCnt->IsFollow() )
3037 SAL_WARN(
"sw.layout",
"footnote frame on different page than ref frame?");
3069 if ( !( aRectFnSet.
IsVert() ? bHeightChgd : bWidthChgd ) &&
3090 pLowerFrame = pLowerFrame->
GetNext();
3099 pLowerFrame = pLowerFrame->
GetPrev();
3105 pLowerFrame =
static_cast<SwSectionFrame*
>(pLowerFrame)->GetSection() &&
3106 !
static_cast<SwSectionFrame*
>(pLowerFrame)->ToMaximize(
false ) ?
3107 static_cast<SwSectionFrame*
>(pLowerFrame)->FindLastContent() :
nullptr;
3123 pLowerFrame = pTableFrame;
3136 !SwFlowFrame::CastFlowFrame( pLowerFrame )->HasFollow() )
3146 if( aRectFnSet.
IsVert() )
3153 pLowerFrame = pLowerFrame->
GetPrev();
3163 pLowerFrame = pLowerFrame->
GetPrev();
3182 if( pSectFrame !=
this &&
IsAnLower( pSectFrame ) )
3194 bool bInvaPageForContent =
true;
3198 bool bFixChgd, bVarChgd;
3201 bFixChgd = bWidthChgd;
3202 bVarChgd = bHeightChgd;
3206 bFixChgd = bHeightChgd;
3207 bVarChgd = bWidthChgd;
3227 while ( pLowerFrame )
3246 if( nLowerType & nFixWidth )
3273 double nNewWidthTmp =
3276 /
double(rOldSize.
Width());
3277 nNewWidth =
SwTwips(nNewWidthTmp);
3286 aFrm.
Width( nNewWidth );
3291 if( nLowerType & nFixHeight )
3306 else if ( rOldSize.
Height() &&
3338 "ChgLowersProp - only for body or foot note container" );
3346 if ( nNewHeight < 0)
3352 "ChgLowersProg - negative height for lower.");
3357 aFrm.
Height( nNewHeight );
3370 double nNewHeightTmp =
3373 /
double(rOldSize.
Height());
3374 nNewHeight =
SwTwips(nNewHeightTmp);
3391 if( nSum - nNewHeight == 1 &&
3397 aFrm.
Height( nNewHeight );
3408 bInvaPageForContent =
false;
3419 pLowerFrame = pLowerFrame->
GetNext();
3425 if ( !(( (aRectFnSet.
IsVert() && bHeightChgd) || (! aRectFnSet.
IsVert() && bWidthChgd) ) &&
3452 OSL_ENSURE( pAttrs,
"LayoutFrame::Format, pAttrs is 0." );
3457 bool bHideWhitespace =
false;
3467 bHideWhitespace =
true;
3471 const sal_uInt16 nLeft = o3tl::narrowing<sal_uInt16>(pAttrs->
CalcLeft(
this));
3472 const sal_uInt16 nUpper = bHideWhitespace ? 0 : pAttrs->
CalcTop();
3474 const sal_uInt16 nRight = o3tl::narrowing<sal_uInt16>(pAttrs->
CalcRight(
this));
3475 const sal_uInt16 nLower = bHideWhitespace ? 0 : pAttrs->
CalcBottom();
3513 nRemaining = std::max( nRemaining, nMinHeight );
3568 OSL_ENSURE( pFrame->
GetDrawObjs(),
"Can't find any Objects" );
3571 if (
auto pFly = pAnchoredObj->DynCastFlyFrame() )
3576 bool bNotify =
true;
3581 const SwFrame *pRel = pFly->IsFlyLayFrame() ? pFly->GetAnchorFrame():
3582 pFly->GetAnchorFrame()->
GetUpper();
3587 if( pFly->getFrameArea().Height()*10 >
3589 pFly->GetFormat()->GetSurround().GetSurround() !=
3590 css::text::WrapTextMode_THROUGH )
3614 OSL_ENSURE( pTmp,
"Where's my TabFrame?" );
3628 }
while ( pFrame &&
IsAnLower( pFrame ) ) ;
3650 nRet = nRel * nPercent / 100;
3661 OSL_ENSURE( pCol,
"Where's the columnframe?" );
3670 if ( nTmp != USHRT_MAX )
3672 if ( pCol == pLayFrame->
Lower() )
3675 nDiff = nDiff ?
std::min( nDiff, nTmp ) : nTmp;
3680 while ( pCol &&
nullptr == (pFrame = pCol->
Lower()) )
3683 }
while ( pFrame && pCol );
3685 return nDiff ? nDiff : nFirstDiff ? nFirstDiff : 240;
3699 for (
size_t i = 0;
i < nCnt; ++
i )
3704 if ( pFly->IsHeightClipped() &&
3705 ( !pFly->IsFlyFreeFrame() || pFly->GetPageFrame() ) )
3730 const sal_uInt16 nNumCols = rCol.
GetNumCols();
3733 bool bBackLock =
false;
3768 bool bNoBalance =
false;
3775 if( nMaximum < nMinimum )
3778 nMinimum = nMaximum = 0;
3780 nMinimum = nMaximum;
3786 GetBalancedColumns().GetValue();
3799 if( nTop > nMaximum )
3803 if( !pAny && !
static_cast<SwSectionFrame*
>(
this)->IsFootnoteLock() )
3828 if (
IsAnLower( pAnchoredObj->GetAnchorFrame() ) )
3830 pAnchoredObj->SetTmpConsiderWrapInfluence(
false );
3851 for ( sal_uInt16
i = 0;
i < nNumCols; ++
i )
3853 pCol->
Calc(pRenderContext);
3864 OSL_ENSURE( pCol && pCol->
GetNext(),
":-( column making holidays?");
3866 bool bMinDiff =
true;
3868 while ( bMinDiff && pCol )
3879 bool bFoundLower =
false;
3890 else if( nInnerHeight < 0 )
3903 if( nInnerHeight > nDiff )
3905 nDiff = nInnerHeight;
3910 if( nMaxFree < -nInnerHeight )
3911 nMaxFree = -nInnerHeight;
3912 if( nAllFree > -nInnerHeight )
3913 nAllFree = -nInnerHeight;
3931 if( nMinimum < nPrtHeight )
3932 nMinimum = nPrtHeight;
3935 if( nMaximum < nPrtHeight )
3936 nMaximum = nPrtHeight;
3941 if (
std::abs(nDiff - nMinDiff) > nNumCols && nDiff >
static_cast<tools::Long>(nNumCols) )
3951 if ( nFrameHeight > nMinHeight || nPrtHeight >= nMinDiff )
3952 nDiff = std::max( nDiff, nMinDiff );
3953 else if( nDiff < nMinDiff )
3954 nDiff = nMinDiff - nPrtHeight + 1;
3959 if( nDiff + nPrtHeight > nMaximum )
3960 nDiff = nMaximum - nPrtHeight;
3962 else if( nMaximum > nMinimum )
3965 if ( nMaximum < nPrtHeight )
3966 nDiff = nMaximum - nPrtHeight;
3971 nMaximum = nPrtHeight;
3982 nMinimum < nPrtHeight - nMinDiff ) )
3984 nMaxFree /= nNumCols;
3985 nDiff = nMaxFree < nMinDiff ? -nMinDiff : -nMaxFree;
3986 if( nPrtHeight + nDiff <= nMinimum )
3987 nDiff = ( nMinimum - nMaximum ) / 2;
3992 if( nPrtHeight + nDiff <= nMinimum )
3993 nDiff = ( nMinimum - nMaximum ) / 2;
4026 if (
IsAnLower( pAnchoredObj->GetAnchorFrame() ) )
4028 pAnchoredObj->SetTmpConsiderWrapInfluence(
false );
4089 SwFlowFrame *pFoll = pSect->
GetFollow();
4091 pSect->SetFollow(
nullptr );
4093 pSect->SetFollow( pFoll );
4125 if( pLastSctCnt == pCnt )
4126 pLastSctCnt =
nullptr;
4128#if OSL_DEBUG_LEVEL > 0
4130 OSL_ENSURE( !pLastSctCnt,
"Where's the last SctContent?" );
4147 pLastSctCnt =
nullptr;
4149 if( pLastTabCnt == pCnt )
4151 pLastTabCnt =
nullptr;
4152 pLastSctCnt =
nullptr;
4155#if OSL_DEBUG_LEVEL > 0
4157 OSL_ENSURE( !pLastTabCnt,
"Where's the last TabContent?" );
4180 if (
auto pFly = pAnchoredObj->DynCastFlyFrame() )
4182 if ( pFly->IsFlyInContentFrame() )
4186 pFly->CheckDirChange();
4210 if (
auto pFly = pAnchoredObj->DynCastFlyFrame() )
4214 pFly->CheckDirChange();
4250 const SwFormatAnchor& rAnch = pAnchoredObj->GetFrameFormat().GetAnchor();
4251 if ((rAnch.
GetAnchorId() != RndStdIds::FLY_AT_PARA) &&
4259 if ( pAnchoredObj->ConsiderObjWrapInfluenceOnObjPos() )
4260 pAnchoredObj->InvalidateObjPosForConsiderWrapInfluence();
4262 pAnchoredObj->InvalidateObjPos();
4272 std::set<SwNodeOffset> *
const pSkipped,
4276 std::vector<sw::Extent>::const_iterator
const& rIterFirst,
4277 std::vector<sw::Extent>::const_iterator
const& rIterEnd,
4280 if (pNode == &rTextNode)
4289 &rIterFirst, &rIterEnd, pFirstNode, pLastNode);
4297 pSkipped->insert(pFly->GetContent().GetContentIdx()->GetIndex());
4311 std::set<SwNodeOffset> *
const pSkipped)
4320 assert(pMerged->pFirstNode->GetIndex() <= rTextNode.
GetIndex()
4321 && rTextNode.
GetIndex() <= pMerged->pLastNode->GetIndex());
4326 std::vector<sw::Extent>::const_iterator iterFirst(pMerged->extents.begin());
4327 std::vector<sw::Extent>::const_iterator iter(iterFirst);
4328 SwTextNode const* pNode(pMerged->pFirstNode);
4331 if (iter == pMerged->extents.end()
4332 || iter->pNode != pNode)
4335 pNode, iterFirst, iter,
4336 pMerged->pFirstNode, pMerged->pLastNode);
4337 SwNodeOffset const until = iter == pMerged->extents.end()
4338 ? pMerged->pLastNode->GetIndex() + 1
4339 : iter->pNode->GetIndex();
4349 pMerged->pFirstNode, pMerged->pLastNode);
4352 if (iter == pMerged->extents.end())
4356 pNode = iter->pNode;
4366 std::set<SwNodeOffset> *
const pSkipped)
4378 std::vector<SwTextFrame*> frames;
4381 if (pFrame->getRootFrame() == &rLayout)
4383 if (pFrame->IsFollow())
4385 frames.push_back(pFrame);
4390 frames.insert(frames.begin(), pFrame);
4400 assert(!pFrame->GetMergedPara() ||
4409 pFrame->SetMergedPara(std::move(pMerged));
4411 auto const pMerged(pFrame->GetMergedPara());
4416 pFrame->InvalidatePage();
4417 if (
auto const pObjs = pFrame->GetDrawObjs())
4420 for (
auto const pObject : *pObjs)
4433 if (
auto const& pMergedPara = pFrame->GetMergedPara())
4437 pFrame->InvalidatePage();
4438 if (
auto const pObjs = pFrame->GetDrawObjs())
4440 for (
auto const pObject : *pObjs)
4448 if (!pFrame->IsFollow())
4453 assert(&rTextNode == pMergedPara->pFirstNode);
4458 j <= pMergedPara->pLastNode->GetIndex(); ++j)
4472 pFormat->DelFrames();
4479 pFrame->SetMergedPara(
nullptr);
4499 && pRedline->
GetType() == RedlineType::Delete
4533 auto const pFrame(
static_cast<SwContentNode&
>(rNode).getLayoutFrame(&rLayout));
4534 assert(!pFrame ||
static_cast<SwTextFrame*
>(pFrame)->GetMergedPara()->pFirstNode != &rNode);
4544 for ( ; j < rEndOfSectionNode.
GetIndex(); ++j)
4546 if (rNodes[j]->IsCreateFrameWhenHidingRedlines())
4565 std::set<SwNodeOffset> *
const pSkipped)
4567 assert(rEndOfExtraSectionNode.
IsEndNode());
4569 + 1;
i < rEndOfExtraSectionNode.
GetIndex(); ++
i)
4571 SwNode const& rStartNode(*rNodes[
i]);
4575 bool bSkip(pSkipped && pSkipped->find(
i) != pSkipped->end());
4581 SwNode const& rNode(*rNodes[j]);
4637 std::set<SwNodeOffset> skippedFlys;
4662 if (bIsShowChangesInMargin || pRedline->GetType() != RedlineType::Delete)
4681 pFootnote->InvalidateNumberInLayout();
4691 pAuthType->UpdateFields();
4768 xmlTextWriterSetIndent(writer,1);
4769 (void)xmlTextWriterSetIndentString(writer, BAD_CAST(
" "));
4770 (void)xmlTextWriterStartDocument( writer,
nullptr,
nullptr,
nullptr );
4776 (void)xmlTextWriterEndDocument( writer );
4777 xmlFreeTextWriter( writer );
4783 bool bCreateWriter = (
nullptr == writer);
4785 writer = lcl_createDefaultWriter();
4787 (void)xmlTextWriterStartElement(writer,
reinterpret_cast<const xmlChar*
>(
"root"));
4790 (void)xmlTextWriterStartElement(writer, BAD_CAST(
"sfxViewShells"));
4798 (void)xmlTextWriterEndElement(writer);
4800 (void)xmlTextWriterStartElement(writer, BAD_CAST(
"infos"));
4802 (void)xmlTextWriterEndElement(writer);
4804 (void)xmlTextWriterEndElement(writer);
4807 lcl_freeWriter(writer);
css::chart::ChartAxisLabelPosition ePos
@ CONSIDER_WRAP_ON_OBJECT_POSITION
@ PARA_SPACE_MAX_AT_PAGES
static sal_uInt8 nFramePos
Document fields related interfaces.
virtual SwFieldType * GetSysFieldType(const SwFieldIds eWhich) const =0
virtual SwFieldType * GetFieldType(SwFieldIds nResId, const OUString &rName, bool bDbFieldMatching) const =0
virtual void UpdateRefFields()=0
virtual void UpdatePageFields(const SwTwips)=0
virtual void UpdateExpFields(SwTextField *pField, bool bUpdateRefFields)=0
virtual const SwRedlineTable & GetRedlineTable() const =0
virtual const SwRangeRedline * GetRedline(const SwPosition &rPos, SwRedlineTable::size_type *pFndPos) const =0
Provides access to settings of a document.
virtual bool get(DocumentSettingId id) const =0
Return the specified document setting.
const SfxPoolItem * GetCurItem() const
const SfxPoolItem * NextItem()
static SAL_WARN_UNUSED_RESULT SfxViewShell * GetNext(const SfxViewShell &rPrev, bool bOnlyVisible=true, const std::function< bool(const SfxViewShell *)> &isViewShell=nullptr)
static SAL_WARN_UNUSED_RESULT SfxViewShell * GetFirst(bool bOnlyVisible=true, const std::function< bool(const SfxViewShell *)> &isViewShell=nullptr)
virtual SfxObjectShell * GetObjectShell() override
constexpr tools::Long Height() const
constexpr tools::Long Width() const
tools::Long GetHeight() const
tools::Long GetWidth() const
class for the positioning of drawing objects
wrapper class for the positioning of Writer fly frames and drawing objects
const SwFrame * GetAnchorFrame() const
virtual const SwFlyFrame * DynCastFlyFrame() const
void InvalidateObjRectWithSpaces() const
void ClearItem(sal_uInt16 nWhichL)
const SwAttrSet * GetChgSet() const
What has changed.
const SwFormatCol & GetCol(bool=true) const
const SwFormatFrameSize & GetFrameSize(bool=true) const
Container of body content (i.e.
const Size & GetSize() const
tools::Long CalcLeft(const SwFrame *pCaller) const
sal_uInt16 CalcTop() const
const SwAttrSet & GetAttrSet() const
tools::Long CalcRight(const SwFrame *pCaller) const
sal_uInt16 CalcBottom() const
SwCellFrame is one table cell in the document layout.
virtual void CheckDirection(bool bVert) override
const SwCellFrame & FindStartEndOfRowSpanCell(bool bStart) const
tools::Long GetLayoutRowSpan() const
const SwTableBox * GetTabBox() const
SwContentFrame is the layout for content nodes: a common base class for text (paragraph) and non-text...
virtual void Cut() override
virtual void Paste(SwFrame *pParent, SwFrame *pSibling=nullptr) override
SwContentFrame * GetNextContentFrame() const
SwTextFrame * FindMaster() const
void UpdateAttr_(const SfxPoolItem *, const SfxPoolItem *, SwContentFrameInvFlags &, SwAttrSetChg *pa=nullptr, SwAttrSetChg *pb=nullptr)
virtual void SwClientNotify(const SwModify &, const SfxHint &) override
virtual SwTwips ShrinkFrame(SwTwips, bool bTst=false, bool bInfo=false) override
virtual SwTwips GrowFrame(SwTwips, bool bTst=false, bool bInfo=false) override
SwContentFrame * getLayoutFrame(const SwRootFrame *, const SwPosition *pPos=nullptr, std::pair< Point, bool > const *pViewPosAndCalcFrame=nullptr) const
const SwFootnoteInfo & GetFootnoteInfo() const
IDocumentFieldsAccess const & getIDocumentFieldsAccess() const
IDocumentRedlineAccess const & getIDocumentRedlineAccess() const
SwFootnoteIdxs & GetFootnoteIdxs()
const SwFrameFormats * GetSpzFrameFormats() const
SwDocShell * GetDocShell()
virtual void UpdateFields()
general base class for all free-flowing frames
virtual const SwFlyFrameFormat * GetFormat() const override
bool IsFlyInContentFrame() const
virtual void CheckDirection(bool bVert) override
SwFrameAreaDefinition & mrTarget
void setSwRect(const SwRect &rNew)
void setSwRect(const SwRect &rNew)
~FramePrintAreaWriteAccess()
Helper class to isolate geometry-defining members of SwFrame and to control their accesses.
const SwRect & getFrameArea() const
bool isFrameAreaDefinitionValid() const
virtual basegfx::B2DHomMatrix getFrameAreaTransformation() const
const SwRect & getFramePrintArea() const
void setFramePrintAreaValid(bool bNew)