LibreOffice Module sw (master)  1
frmtool.hxx
Go to the documentation of this file.
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3  * This file is part of the LibreOffice project.
4  *
5  * This Source Code Form is subject to the terms of the Mozilla Public
6  * License, v. 2.0. If a copy of the MPL was not distributed with this
7  * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8  *
9  * This file incorporates work covered by the following license notice:
10  *
11  * Licensed to the Apache Software Foundation (ASF) under one or more
12  * contributor license agreements. See the NOTICE file distributed
13  * with this work for additional information regarding copyright
14  * ownership. The ASF licenses this file to you under the Apache
15  * License, Version 2.0 (the "License"); you may not use this file
16  * except in compliance with the License. You may obtain a copy of
17  * the License at http://www.apache.org/licenses/LICENSE-2.0 .
18  */
19 
20 #ifndef INCLUDED_SW_SOURCE_CORE_INC_FRMTOOL_HXX
21 #define INCLUDED_SW_SOURCE_CORE_INC_FRMTOOL_HXX
22 
23 #include <swtypes.hxx>
24 #include "frame.hxx"
25 #include "swcache.hxx"
26 #include <swatrset.hxx>
27 
28 class SwLayoutFrame;
29 class SwFont;
30 class SwTextFrame;
31 class SwFormatAnchor;
32 class SwViewShell;
33 class SwPageFrame;
34 class SwFlyFrame;
35 class SwContentFrame;
36 class SwRootFrame;
37 class SwDoc;
38 class SdrObject;
39 class SvxBrushItem;
40 class SdrMarkList;
41 class SwNodeIndex;
42 class GraphicObject;
43 class GraphicAttr;
44 class SwPageDesc;
45 class SwFrameFormats;
46 class SwRegionRects;
47 class SwTextNode;
48 namespace sw { struct Extent; }
49 namespace basegfx { namespace utils { class B2DClipState; } }
50 
51 #define FAR_AWAY (SAL_MAX_INT32 - 20000) // initial position of a Fly
52 #define BROWSE_HEIGHT (56700L * 10L) // 10 Meters
53 #define GRFNUM_NO 0
54 #define GRFNUM_YES 1
55 #define GRFNUM_REPLACE 2
56 
57 void AppendObjs( const SwFrameFormats *pTable, sal_uLong nIndex,
58  SwFrame *pFrame, SwPageFrame *pPage, SwDoc* doc );
59 
60 void AppendObjsOfNode(SwFrameFormats const* pTable, sal_uLong nIndex,
61  SwFrame * pFrame, SwPageFrame * pPage, SwDoc * pDoc,
62  std::vector<sw::Extent>::const_iterator const* pIter,
63  std::vector<sw::Extent>::const_iterator const* pEnd);
64 
65 void RemoveHiddenObjsOfNode(SwTextNode const& rNode,
66  std::vector<sw::Extent>::const_iterator const* pIter,
67  std::vector<sw::Extent>::const_iterator const* pEnd);
68 
69 bool IsAnchoredObjShown(SwTextFrame const& rFrame, SwFormatAnchor const& rAnchor);
70 
71 void AppendAllObjs(const SwFrameFormats* pTable, const SwFrame* pSib);
72 
73 // draw background with brush or graphics
74 // The 6th parameter indicates that the method should consider background
75 // transparency, saved in the color of the brush item.
76 void DrawGraphic(
77  const SvxBrushItem *,
79  const SwRect &rOrg,
80  const SwRect &rOut,
81  const sal_uInt8 nGrfNum = GRFNUM_NO,
82  const bool bConsiderBackgroundTransparency = false );
85  const SwRect& rOriginalLayoutRect,
86  const SwRegionRects& rPaintRegion,
87  const basegfx::utils::B2DClipState& rClipState,
88  vcl::RenderContext& rOut);
89 
90 // RotGrfFlyFrame: Adapted to rotation
92  vcl::RenderContext & rOutputDevice,
93  GraphicObject const& rGraphicObj,
94  GraphicAttr const& rGraphicAttr,
95  const basegfx::B2DHomMatrix& rGraphicTransform,
96  const OUString& rName,
97  const OUString& rTitle,
98  const OUString& rDescription);
99 
100 // method to align rectangle.
101 // Created declaration here to avoid <extern> declarations
102 void SwAlignRect( SwRect &rRect, const SwViewShell *pSh, const vcl::RenderContext* pRenderContext );
103 
104 // method to align graphic rectangle
105 // Created declaration here to avoid <extern> declarations
106 void SwAlignGrfRect( SwRect *pGrfRect, const vcl::RenderContext &rOut );
107 
118 void PaintCharacterBorder(const SwFont& rFont, const SwRect& rPaintArea, const bool bVerticalLayout,
119  const bool bVerticalLayoutLRBT, const bool bJoinWithPrev,
120  const bool bJoinWithNext);
121 
122 // get Fly, if no List is given use the current shell
123 // Implementation in feshview.cxx
124 SwFlyFrame *GetFlyFromMarked( const SdrMarkList *pLst, SwViewShell *pSh );
125 
126 SwFrame *SaveContent( SwLayoutFrame *pLay, SwFrame *pStart = nullptr );
127 void RestoreContent( SwFrame *pSav, SwLayoutFrame *pParent, SwFrame *pSibling );
128 
129 // Get ContentNodes, create ContentFrames, and add them to LayFrame.
130 void InsertCnt_( SwLayoutFrame *pLay, SwDoc *pDoc, sal_uLong nIndex,
131  bool bPages = false, sal_uLong nEndIndex = 0,
132  SwFrame *pPrv = nullptr );
133 
134 // Creation of frames for a specific section (uses InsertCnt_)
135 void MakeFrames( SwDoc *pDoc, const SwNodeIndex &rSttIdx,
136  const SwNodeIndex &rEndIdx );
137 
138 extern bool bObjsDirect;
139 
140 // prevent creation of Flys in InsertCnt_, e.g. for table headlines
141 extern bool bDontCreateObjects;
142 
143 // for FlyCnts, see SwFlyAtContentFrame::MakeAll()
145 
146 // for table settings via keyboard
148 long CalcHeightWithFlys( const SwFrame *pFrame );
149 
150 SwPageFrame *InsertNewPage( SwPageDesc &rDesc, SwFrame *pUpper,
151  bool bOdd, bool bFirst, bool bInsertEmpty, bool bFootnote,
152  SwFrame *pSibling );
153 
154 // connect Flys with page
155 void RegistFlys( SwPageFrame*, const SwLayoutFrame* );
156 
157 // notification of Fly's background if needed
158 void Notify( SwFlyFrame *pFly, SwPageFrame *pOld, const SwRect &rOld,
159  const SwRect* pOldRect = nullptr );
160 
161 void Notify_Background( const SdrObject* pObj,
162  SwPageFrame* pPage,
163  const SwRect& rRect,
164  const PrepareHint eHint,
165  const bool bInva );
166 
167 const SwFrame* GetVirtualUpper( const SwFrame* pFrame, const Point& rPos );
168 
169 bool Is_Lower_Of( const SwFrame *pCurrFrame, const SdrObject* pObj );
170 
171 // FIXME: EasyHack (refactoring): rename method and parameter name in all files
172 const SwFrame *FindContext( const SwFrame *pFrame, SwFrameType nAdditionalContextTyp );
173 
174 bool IsFrameInSameContext( const SwFrame *pInnerFrame, const SwFrame *pFrame );
175 
176 const SwFrame * FindPage( const SwRect &rRect, const SwFrame *pPage );
177 
190 SwFrame* GetFrameOfModify( const SwRootFrame* pLayout,
191  SwModify const&,
192  SwFrameType const nFrameType,
193  const SwPosition *pPos = nullptr,
194  std::pair<Point, bool> const* pViewPosAndCalcFrame = nullptr);
195 
196 // Should extra data (redline stroke, line numbers) be painted?
197 bool IsExtraData( const SwDoc *pDoc );
198 
199 // #i11760# - method declaration <CalcContent(..)>
200 void CalcContent( SwLayoutFrame *pLay, bool bNoColl = false );
201 
202 // Notify classes memorize the current sizes in their constructor and do
203 // the necessary notifications in their destructor if needed
205 {
206 protected:
209  const SwRect maPrt;
214  bool const mbValidSize;
215 
216 public:
217  SwFrameNotify( SwFrame *pFrame );
218  ~SwFrameNotify() COVERITY_NOEXCEPT_FALSE;
219 
220  const SwRect &getFrameArea() const { return maFrame; }
221  void SetInvaKeep() { mbInvaKeep = true; }
222 };
223 
225 {
227 
228 public:
229  SwLayNotify( SwLayoutFrame *pLayFrame );
230  ~SwLayNotify();
231 
232  void SetLowersComplete( bool b ) { m_bLowersComplete = b; }
234 };
235 
236 class SwFlyNotify : public SwLayNotify
237 {
240 
241 public:
242  SwFlyNotify( SwFlyFrame *pFlyFrame );
243  ~SwFlyNotify();
244 };
245 
247 {
248 private:
249  // #i11859#
252 
253  // #i25029#
256 
257 public:
258  SwContentNotify( SwContentFrame *pContentFrame );
260 
261  // #i25029#
263  {
264  mbInvalidatePrevPrtArea = true;
265  }
266 
268  {
269  mbBordersJoinedWithPrev = true;
270  }
271 };
272 
273 // SwBorderAttrs encapsulates the calculation for margin attributes including
274 // border. The whole class is cached.
275 
276 // WARNING! If more attributes should be cached also adjust the method
277 // Modify::Modify!
278 class SwBorderAttrs : public SwCacheObj
279 {
282  // #i96772#
283  std::shared_ptr<SvxLRSpaceItem> m_rLR;
287 
288  // the following bool values set the cached values to INVALID - until they
289  // are calculated for the first time
290  bool m_bTopLine : 1;
291  bool m_bBottomLine : 1;
292  bool m_bLeftLine : 1;
293  bool m_bRightLine : 1;
294  bool m_bTop : 1;
295  bool m_bBottom : 1;
296  bool m_bLine : 1;
297 
298  bool m_bIsLine : 1; // border on at least one side?
299 
300  bool m_bCacheGetLine : 1; // cache GetTopLine(), GetBottomLine()?
301  bool m_bCachedGetTopLine : 1; // is GetTopLine() cached?
302  bool m_bCachedGetBottomLine : 1; // is GetBottomLine() cached?
303  // Booleans indicate that <m_bJoinedWithPrev> and <m_bJoinedWithNext> are
304  // cached and valid.
305  // Caching depends on value of <m_bCacheGetLine>.
306  mutable bool m_bCachedJoinedWithPrev : 1;
307  mutable bool m_bCachedJoinedWithNext : 1;
308  // Booleans indicate that borders are joined with previous/next frame.
311 
312  // The cached values (un-defined until calculated for the first time)
313  sal_uInt16 m_nTopLine,
315  m_nLeftLine,
316  m_nRightLine,
317  m_nTop,
318  m_nBottom,
321 
322  // only calculate lines and shadow
323  void CalcTopLine_();
324  void CalcBottomLine_();
325  void CalcLeftLine_();
326  void CalcRightLine_();
327 
328  // lines + shadow + margin
329  void CalcTop_();
330  void CalcBottom_();
331 
332  void IsLine_();
333 
334  // #i25029# - If <_pPrevFrame> is set, its value is taken for testing, if
335  // borders/shadow have to be joined with previous frame.
336  void GetTopLine_ ( const SwFrame& _rFrame,
337  const SwFrame* _pPrevFrame );
338  void GetBottomLine_( const SwFrame& _rFrame );
339 
340  // calculate cached values <m_bJoinedWithPrev> and <m_bJoinedWithNext>
341  // #i25029# - If <_pPrevFrame> is set, its value is taken for testing, if
342  // borders/shadow have to be joined with previous frame.
343  void CalcJoinedWithPrev( const SwFrame& _rFrame,
344  const SwFrame* _pPrevFrame );
345  void CalcJoinedWithNext( const SwFrame& _rFrame );
346 
347  // internal helper method for CalcJoinedWithPrev and CalcJoinedWithNext
348  bool JoinWithCmp( const SwFrame& _rCallerFrame,
349  const SwFrame& _rCmpFrame ) const;
350 
351  // Are the left and right line and the LRSpace equal?
352  bool CmpLeftRight( const SwBorderAttrs &rCmpAttrs,
353  const SwFrame *pCaller,
354  const SwFrame *pCmp ) const;
355 
356 public:
357  SwBorderAttrs( const SwModify *pOwner, const SwFrame *pConstructor );
358  virtual ~SwBorderAttrs() override;
359 
360  const SwAttrSet &GetAttrSet() const { return m_rAttrSet; }
361  const SvxULSpaceItem &GetULSpace() const { return m_rUL; }
362  const SvxBoxItem &GetBox() const { return m_rBox; }
363  const SvxShadowItem &GetShadow() const { return m_rShadow; }
364 
365  inline sal_uInt16 CalcTopLine() const;
366  inline sal_uInt16 CalcBottomLine() const;
367  inline sal_uInt16 CalcLeftLine() const;
368  inline sal_uInt16 CalcRightLine() const;
369  inline sal_uInt16 CalcTop() const;
370  inline sal_uInt16 CalcBottom() const;
371  long CalcLeft( const SwFrame *pCaller ) const;
372  long CalcRight( const SwFrame *pCaller ) const;
373 
374  inline bool IsLine() const;
375 
376  const Size &GetSize() const { return m_aFrameSize; }
377 
378  // Should upper (or lower) border be evaluated for this frame?
379  // #i25029# - If <_pPrevFrame> is set, its value is taken for testing, if
380  // borders/shadow have to be joined with previous frame.
381  inline sal_uInt16 GetTopLine ( const SwFrame& _rFrame,
382  const SwFrame* _pPrevFrame = nullptr ) const;
383  inline sal_uInt16 GetBottomLine( const SwFrame& _rFrame ) const;
384  inline void SetGetCacheLine( bool bNew ) const;
385 
386  // Accessors for cached values <m_bJoinedWithPrev> and <m_bJoinedWithNext>
387  // #i25029# - If <_pPrevFrame> is set, its value is taken for testing, if
388  // borders/shadow have to be joined with previous frame.
389  bool JoinedWithPrev( const SwFrame& _rFrame,
390  const SwFrame* _pPrevFrame = nullptr ) const;
391  bool JoinedWithNext( const SwFrame& _rFrame ) const;
392 };
393 
395 {
396  const SwFrame *m_pConstructor; //opt: for passing on to SwBorderAttrs
397 
398 protected:
399  virtual SwCacheObj *NewObj() override;
400 
401 public:
402  SwBorderAttrAccess( SwCache &rCache, const SwFrame *pOwner );
403 
404  SwBorderAttrs *Get();
405 };
406 
407 // Iterator for draw objects of a page. The objects will be iterated sorted by
408 // their Z-order. Iterating is not cheap since for each operation the _whole_
409 // SortArray needs to be traversed.
411 {
414 
415 public:
416  SwOrderIter( const SwPageFrame *pPage );
417 
418  void Current( const SdrObject *pNew ) { m_pCurrent = pNew; }
419  const SdrObject *operator()() const { return m_pCurrent; }
420  void Top();
421  const SdrObject *Bottom();
422  const SdrObject *Next();
423  void Prev();
424 };
425 
427 {
428  static sal_uInt8 nCnt;
429  static bool bLocked;
430 
431 public:
433  {
434  if ( ++StackHack::nCnt > 50 )
435  StackHack::bLocked = true;
436  }
438  {
439  if ( --StackHack::nCnt < 5 )
440  StackHack::bLocked = false;
441  }
442 
443  static bool IsLocked() { return StackHack::bLocked; }
444  static sal_uInt8 Count() { return StackHack::nCnt; }
445 };
446 
447 // Should upper (or lower) border be evaluated for this frame?
448 // #i25029# - If <_pPrevFrame> is set, its value is taken for testing, if
449 // borders/shadow have to be joined with previous frame.
450 inline sal_uInt16 SwBorderAttrs::GetTopLine ( const SwFrame& _rFrame,
451  const SwFrame* _pPrevFrame ) const
452 {
453  if ( !m_bCachedGetTopLine || _pPrevFrame )
454  {
455  const_cast<SwBorderAttrs*>(this)->GetTopLine_( _rFrame, _pPrevFrame );
456  }
457  return m_nGetTopLine;
458 }
459 inline sal_uInt16 SwBorderAttrs::GetBottomLine( const SwFrame& _rFrame ) const
460 {
461  if ( !m_bCachedGetBottomLine )
462  const_cast<SwBorderAttrs*>(this)->GetBottomLine_( _rFrame );
463  return m_nGetBottomLine;
464 }
465 inline void SwBorderAttrs::SetGetCacheLine( bool bNew ) const
466 {
467  const_cast<SwBorderAttrs*>(this)->m_bCacheGetLine = bNew;
468  const_cast<SwBorderAttrs*>(this)->m_bCachedGetBottomLine =
469  const_cast<SwBorderAttrs*>(this)->m_bCachedGetTopLine = false;
470  // invalidate cache for values <m_bJoinedWithPrev> and <m_bJoinedWithNext>
471  m_bCachedJoinedWithPrev = false;
472  m_bCachedJoinedWithNext = false;
473 }
474 
475 inline sal_uInt16 SwBorderAttrs::CalcTopLine() const
476 {
477  if ( m_bTopLine )
478  const_cast<SwBorderAttrs*>(this)->CalcTopLine_();
479  return m_nTopLine;
480 }
481 inline sal_uInt16 SwBorderAttrs::CalcBottomLine() const
482 {
483  if ( m_bBottomLine )
484  const_cast<SwBorderAttrs*>(this)->CalcBottomLine_();
485  return m_nBottomLine;
486 }
487 inline sal_uInt16 SwBorderAttrs::CalcLeftLine() const
488 {
489  if ( m_bLeftLine )
490  const_cast<SwBorderAttrs*>(this)->CalcLeftLine_();
491  return m_nLeftLine;
492 }
493 inline sal_uInt16 SwBorderAttrs::CalcRightLine() const
494 {
495  if ( m_bRightLine )
496  const_cast<SwBorderAttrs*>(this)->CalcRightLine_();
497  return m_nRightLine;
498 }
499 inline sal_uInt16 SwBorderAttrs::CalcTop() const
500 {
501  if ( m_bTop )
502  const_cast<SwBorderAttrs*>(this)->CalcTop_();
503  return m_nTop;
504 }
505 inline sal_uInt16 SwBorderAttrs::CalcBottom() const
506 {
507  if ( m_bBottom )
508  const_cast<SwBorderAttrs*>(this)->CalcBottom_();
509  return m_nBottom;
510 }
511 inline bool SwBorderAttrs::IsLine() const
512 {
513  if ( m_bLine )
514  const_cast<SwBorderAttrs*>(this)->IsLine_();
515  return m_bIsLine;
516 }
517 
537 void GetSpacingValuesOfFrame( const SwFrame& rFrame,
538  SwTwips& onLowerSpacing,
539  SwTwips& onLineSpacing,
540  bool& obIsLineSpacingProportional );
541 
554 const SwContentFrame* GetCellContent( const SwLayoutFrame& rCell_ );
555 
562 {
563 private:
564  const SwFrame* mpFrame;
566 
567 public:
568  SwDeletionChecker(const SwFrame* pFrame);
569 
575  bool HasBeenDeleted();
576 };
577 
578 #endif
579 
580 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
bool m_bJoinedWithPrev
Definition: frmtool.hxx:309
SwTwips mnFlyAnchorOfstNoWrap
Definition: frmtool.hxx:211
void SetInvalidatePrevPrtArea()
Definition: frmtool.hxx:262
sal_uInt16 CalcBottomLine() const
Definition: frmtool.hxx:481
Base class of the Writer layout elements.
Definition: frame.hxx:295
SwFlyNotify(SwFlyFrame *pFlyFrame)
Definition: frmtool.cxx:626
Represents the visualization of a paragraph.
Definition: txtfrm.hxx:149
bool m_bBottom
Definition: frmtool.hxx:295
void RestoreContent(SwFrame *pSav, SwLayoutFrame *pParent, SwFrame *pSibling)
Definition: frmtool.cxx:2719
const SdrObject * Next()
Definition: frmtool.cxx:2441
const SvxBoxItem & m_rBox
Definition: frmtool.hxx:284
sal_uInt16 m_nLeftLine
Definition: frmtool.hxx:313
bool m_bTopLine
Definition: frmtool.hxx:290
void SetInvaKeep()
Definition: frmtool.hxx:221
Marks a position in the document model.
Definition: pam.hxx:35
SwFrame * mpFrame
Definition: frmtool.hxx:207
const SwFrame * m_pConstructor
Definition: frmtool.hxx:396
const SwFrame * FindContext(const SwFrame *pFrame, SwFrameType nAdditionalContextTyp)
provides the area of a frame in that no Fly from another area can overlap
Definition: frmtool.cxx:3314
void DrawGraphic(const SvxBrushItem *, vcl::RenderContext *, const SwRect &rOrg, const SwRect &rOut, const sal_uInt8 nGrfNum=GRFNUM_NO, const bool bConsiderBackgroundTransparency=false)
Definition: paintfrm.cxx:1793
const SwPageFrame * m_pPage
Definition: frmtool.hxx:412
bool m_bRightLine
Definition: frmtool.hxx:293
void Notify(SwFlyFrame *pFly, SwPageFrame *pOld, const SwRect &rOld, const SwRect *pOldRect=nullptr)
Notify the background based on the difference between old and new rectangle.
Definition: frmtool.cxx:2924
const SwRect & getFrameArea() const
Definition: frmtool.hxx:220
~SwFrameNotify() COVERITY_NOEXCEPT_FALSE
Definition: frmtool.cxx:107
SwTwips mnHeightOfLastLine
Definition: frmtool.hxx:251
bool bDontCreateObjects
Definition: frmtool.cxx:80
void Current(const SdrObject *pNew)
Definition: frmtool.hxx:418
const SwFrame * FindPage(const SwRect &rRect, const SwFrame *pPage)
Definition: frmtool.cxx:3412
sal_uIntPtr sal_uLong
std::shared_ptr< SvxLRSpaceItem > m_rLR
Definition: frmtool.hxx:283
bool IsAnchoredObjShown(SwTextFrame const &rFrame, SwFormatAnchor const &rAnchor)
Definition: frmtool.cxx:1207
bool JoinedWithPrev(const SwFrame &_rFrame, const SwFrame *_pPrevFrame=nullptr) const
Definition: frmtool.cxx:2297
static sal_uInt8 nCnt
Definition: frmtool.hxx:428
Definition: doc.hxx:185
SwLayNotify(SwLayoutFrame *pLayFrame)
Definition: frmtool.cxx:414
bool m_bJoinedWithNext
Definition: frmtool.hxx:310
void Prev()
Definition: frmtool.cxx:2469
const SvxShadowItem & GetShadow() const
Definition: frmtool.hxx:363
SwFrameNotify(SwFrame *pFrame)
Definition: frmtool.cxx:86
bool JoinWithCmp(const SwFrame &_rCallerFrame, const SwFrame &_rCmpFrame) const
Definition: frmtool.cxx:2209
void RemoveHiddenObjsOfNode(SwTextNode const &rNode, std::vector< sw::Extent >::const_iterator const *pIter, std::vector< sw::Extent >::const_iterator const *pEnd)
Definition: frmtool.cxx:1086
~StackHack()
Definition: frmtool.hxx:437
long CalcHeightWithFlys(const SwFrame *pFrame)
Definition: tabfrm.cxx:3802
long SwTwips
Definition: swtypes.hxx:49
sal_uInt16 CalcTopLine() const
Definition: frmtool.hxx:475
void SetBordersJoinedWithPrev()
Definition: frmtool.hxx:267
Dialog to specify the properties of drop-down form field.
Definition: accfrmobj.cxx:40
sal_uInt16 m_nRightLine
Definition: frmtool.hxx:313
void Top()
Definition: frmtool.cxx:2388
Of course Writer needs its own rectangles.
Definition: swrect.hxx:34
long CalcRight(const SwFrame *pCaller) const
Definition: frmtool.cxx:2045
void Notify_Background(const SdrObject *pObj, SwPageFrame *pPage, const SwRect &rRect, const PrepareHint eHint, const bool bInva)
Definition: frmtool.cxx:3072
The root element of a Writer document layout.
Definition: rootfrm.hxx:79
SwFlyFrame * GetFlyFromMarked(const SdrMarkList *pLst, SwViewShell *pSh)
Definition: feshview.cxx:147
void AppendObjsOfNode(SwFrameFormats const *pTable, sal_uLong nIndex, SwFrame *pFrame, SwPageFrame *pPage, SwDoc *pDoc, std::vector< sw::Extent >::const_iterator const *pIter, std::vector< sw::Extent >::const_iterator const *pEnd)
Definition: frmtool.cxx:1111
static bool bFootnote
Definition: insfnote.cxx:40
bool bSetCompletePaintOnInvalidate
Definition: frmtool.cxx:81
virtual SwCacheObj * NewObj() override
Can be use in NewObj.
Definition: frmtool.cxx:2371
void CalcBottomLine_()
Definition: frmtool.cxx:2151
long CalcLeft(const SwFrame *pCaller) const
Definition: frmtool.cxx:2093
sal_uInt16 CalcLeftLine() const
Definition: frmtool.hxx:487
void InsertCnt_(SwLayoutFrame *pLay, SwDoc *pDoc, sal_uLong nIndex, bool bPages=false, sal_uLong nEndIndex=0, SwFrame *pPrv=nullptr)
Definition: frmtool.cxx:1322
void SwAlignRect(SwRect &rRect, const SwViewShell *pSh, const vcl::RenderContext *pRenderContext)
Function is also used outside this file.
Definition: paintfrm.cxx:1103
SwBorderAttrs(const SwModify *pOwner, const SwFrame *pConstructor)
Definition: frmtool.cxx:1973
bool m_bCachedGetBottomLine
Definition: frmtool.hxx:302
bool DrawFillAttributes(const drawinglayer::attribute::SdrAllFillAttributesHelperPtr &rFillAttributes, const SwRect &rOriginalLayoutRect, const SwRegionRects &rPaintRegion, const basegfx::utils::B2DClipState &rClipState, vcl::RenderContext &rOut)
Definition: paintfrm.cxx:1696
const SvxShadowItem & m_rShadow
Definition: frmtool.hxx:285
bool IsFrameInSameContext(const SwFrame *pInnerFrame, const SwFrame *pFrame)
Definition: frmtool.cxx:3328
std::shared_ptr< SdrAllFillAttributesHelper > SdrAllFillAttributesHelperPtr
Definition: format.hxx:38
void CalcJoinedWithNext(const SwFrame &_rFrame)
Definition: frmtool.cxx:2266
void CalcTopLine_()
Definition: frmtool.cxx:2144
void CalcJoinedWithPrev(const SwFrame &_rFrame, const SwFrame *_pPrevFrame)
Definition: frmtool.cxx:2231
bool mbHadFollow
Definition: frmtool.hxx:212
void GetSpacingValuesOfFrame(const SwFrame &rFrame, SwTwips &onLowerSpacing, SwTwips &onLineSpacing, bool &obIsLineSpacingProportional)
method to determine the spacing values of a frame
Definition: frmtool.cxx:3609
void GetTopLine_(const SwFrame &_rFrame, const SwFrame *_pPrevFrame)
Definition: frmtool.cxx:2321
bool m_bLeftLine
Definition: frmtool.hxx:292
const SwAttrSet & m_rAttrSet
Definition: frmtool.hxx:280
bool mbInvaKeep
Definition: frmtool.hxx:213
const SwRect aFrameAndSpace
Definition: frmtool.hxx:239
const SwRect maPrt
Definition: frmtool.hxx:209
const SwRect maFrame
Definition: frmtool.hxx:208
SwFrame * SaveContent(SwLayoutFrame *pLay, SwFrame *pStart=nullptr)
Definition: frmtool.cxx:2556
helper class to check if a frame has been deleted during an operation WARNING! This should only be us...
Definition: frmtool.hxx:561
void MakeFrames(SwDoc *pDoc, const SwNodeIndex &rSttIdx, const SwNodeIndex &rEndIdx)
Definition: frmtool.cxx:1770
SwPageFrame *const pOldPage
Definition: frmtool.hxx:238
Specific frame formats (frames, DrawObjects).
Definition: docary.hxx:201
SwPageFrame * InsertNewPage(SwPageDesc &rDesc, SwFrame *pUpper, bool bOdd, bool bFirst, bool bInsertEmpty, bool bFootnote, SwFrame *pSibling)
Definition: frmtool.cxx:2807
void CalcContent(SwLayoutFrame *pLay, bool bNoColl=false)
Definition: fly.cxx:1366
void SetGetCacheLine(bool bNew) const
Definition: frmtool.hxx:465
PrepareHint
Definition: swtypes.hxx:204
sal_uInt16 GetBottomLine(const SwFrame &_rFrame) const
Definition: frmtool.hxx:459
SwFrameType
Definition: frame.hxx:72
bool m_bLowersComplete
Definition: frmtool.hxx:226
sal_uInt16 m_nTopLine
Definition: frmtool.hxx:313
bool CmpLeftRight(const SwBorderAttrs &rCmpAttrs, const SwFrame *pCaller, const SwFrame *pCmp) const
Definition: frmtool.cxx:2198
SwOrderIter(const SwPageFrame *pPage)
Definition: frmtool.cxx:2382
FlyAnchors.
Definition: fmtanchr.hxx:34
const SvxBoxItem & GetBox() const
Definition: frmtool.hxx:362
const SwFrame * mpFrame
Definition: frmtool.hxx:564
SwBorderAttrAccess(SwCache &rCache, const SwFrame *pOwner)
Definition: frmtool.cxx:2363
static sal_uInt8 Count()
Definition: frmtool.hxx:444
void PaintCharacterBorder(const SwFont &rFont, const SwRect &rPaintArea, const bool bVerticalLayout, const bool bVerticalLayoutLRBT, const bool bJoinWithPrev, const bool bJoinWithNext)
Paint border around a run of characters using frame painting code.
Definition: paintfrm.cxx:4707
static bool bLocked
Definition: frmtool.hxx:429
const SwAttrSet & GetAttrSet() const
Definition: frmtool.hxx:360
sal_uInt16 m_nBottom
Definition: frmtool.hxx:313
sal_uInt16 GetTopLine(const SwFrame &_rFrame, const SwFrame *_pPrevFrame=nullptr) const
Definition: frmtool.hxx:450
const SdrObject * m_pCurrent
Definition: frmtool.hxx:413
Marks a node in the document model.
Definition: ndindex.hxx:31
bool IsExtraData(const SwDoc *pDoc)
Definition: frmtool.cxx:3566
bool m_bCachedJoinedWithNext
Definition: frmtool.hxx:307
bool IsLine() const
Definition: frmtool.hxx:511
bool bObjsDirect
Definition: frmtool.cxx:79
SwContentNotify(SwContentFrame *pContentFrame)
Definition: frmtool.cxx:731
bool mbBordersJoinedWithPrev
Definition: frmtool.hxx:255
A page of the document layout.
Definition: pagefrm.hxx:40
bool mbChkHeightOfLastLine
Definition: frmtool.hxx:250
SwDeletionChecker(const SwFrame *pFrame)
Definition: frmtool.cxx:3662
bool IsLowersComplete()
Definition: frmtool.hxx:233
void CalcRightLine_()
Definition: frmtool.cxx:2165
sal_uInt16 CalcTop() const
Definition: frmtool.hxx:499
SwBorderAttrs * Get()
Definition: frmtool.cxx:2377
bool m_bCacheGetLine
Definition: frmtool.hxx:300
SwTwips mnFlyAnchorOfst
Definition: frmtool.hxx:210
void CalcTop_()
Definition: frmtool.cxx:2033
const SwContentFrame * GetCellContent(const SwLayoutFrame &rCell_)
method to get the content of the table cell
Definition: frmtool.cxx:3640
SwTextNode is a paragraph in the document model.
Definition: ndtxt.hxx:79
const SwModify * mpRegIn
Definition: frmtool.hxx:565
bool Is_Lower_Of(const SwFrame *pCurrFrame, const SdrObject *pObj)
Definition: frmtool.cxx:3282
general base class for all free-flowing frames
Definition: flyfrm.hxx:60
void IsLine_()
Definition: frmtool.cxx:2172
const Size m_aFrameSize
Definition: frmtool.hxx:286
void AppendAllObjs(const SwFrameFormats *pTable, const SwFrame *pSib)
Definition: frmtool.cxx:1247
const SvxULSpaceItem & m_rUL
Definition: frmtool.hxx:281
unsigned char sal_uInt8
const SdrObject * operator()() const
Definition: frmtool.hxx:419
The Cache object base class Users of the Cache must derrive a class from the SwCacheObj and store the...
Definition: swcache.hxx:133
void SetLowersComplete(bool b)
Definition: frmtool.hxx:232
void SwAlignGrfRect(SwRect *pGrfRect, const vcl::RenderContext &rOut)
Method to pixel-align rectangle for drawing graphic object.
Definition: paintfrm.cxx:1209
sal_uInt16 CalcBottom() const
Definition: frmtool.hxx:505
sal_uInt16 m_nBottomLine
Definition: frmtool.hxx:313
void GetBottomLine_(const SwFrame &_rFrame)
Definition: frmtool.cxx:2338
void CalcLeftLine_()
Definition: frmtool.cxx:2158
bool JoinedWithNext(const SwFrame &_rFrame) const
Definition: frmtool.cxx:2309
bool mbInvalidatePrevPrtArea
Definition: frmtool.hxx:254
const SwFrame * GetVirtualUpper(const SwFrame *pFrame, const Point &rPos)
Provides the Upper of an anchor in paragraph-bound objects.
Definition: frmtool.cxx:3250
bool m_bBottomLine
Definition: frmtool.hxx:291
bool HasBeenDeleted()
return true if mpFrame != 0 and mpFrame is not client of pRegIn false otherwise
Definition: frmtool.cxx:3674
static bool IsLocked()
Definition: frmtool.hxx:443
const Size & GetSize() const
Definition: frmtool.hxx:376
void paintGraphicUsingPrimitivesHelper(vcl::RenderContext &rOutputDevice, GraphicObject const &rGraphicObj, GraphicAttr const &rGraphicAttr, const basegfx::B2DHomMatrix &rGraphicTransform, const OUString &rName, const OUString &rTitle, const OUString &rDescription)
Definition: notxtfrm.cxx:930
bool m_bIsLine
Definition: frmtool.hxx:298
Access class for the Cache.
Definition: swcache.hxx:194
void RegistFlys(SwPageFrame *, const SwLayoutFrame *)
Definition: frmtool.cxx:2908
bool m_bCachedGetTopLine
Definition: frmtool.hxx:301
#define GRFNUM_NO
Definition: frmtool.hxx:53
sal_uInt16 m_nGetBottomLine
Definition: frmtool.hxx:313
virtual ~SwBorderAttrs() override
Definition: frmtool.cxx:2023
sal_uInt16 m_nTop
Definition: frmtool.hxx:313
void AppendObjs(const SwFrameFormats *pTable, sal_uLong nIndex, SwFrame *pFrame, SwPageFrame *pPage, SwDoc *doc)
Definition: frmtool.cxx:1157
sal_uInt16 m_nGetTopLine
Definition: frmtool.hxx:313
SwFrame * GetFrameOfModify(const SwRootFrame *pLayout, SwModify const &, SwFrameType const nFrameType, const SwPosition *pPos=nullptr, std::pair< Point, bool > const *pViewPosAndCalcFrame=nullptr)
const SdrObject * Bottom()
Definition: frmtool.cxx:2414
bool m_bCachedJoinedWithPrev
Definition: frmtool.hxx:306
const SvxULSpaceItem & GetULSpace() const
Definition: frmtool.hxx:361
sal_uInt16 CalcRightLine() const
Definition: frmtool.hxx:493
void CalcBottom_()
Definition: frmtool.cxx:2039
bool const mbValidSize
Definition: frmtool.hxx:214
SwTwips CalcRowRstHeight(SwLayoutFrame *pRow)
Definition: frmtool.cxx:3396