LibreOffice Module sw (master) 1
Public Types | Public Member Functions | Private Member Functions | Private Attributes | List of all members
SwRegionRects Class Reference

#include <swregion.hxx>

Inheritance diagram for SwRegionRects:
Collaboration diagram for SwRegionRects:

Public Types

enum  CompressType {
  CompressExact ,

Public Member Functions

 SwRegionRects (const SwRect &rStartRect, sal_uInt16 nInit=20)
 SwRegionRects (sal_uInt16 nInit=20)
void operator-= (const SwRect &rRect)
 Delete all overlaps of the Rects in array with the given <rRect> More...
void operator+= (const SwRect &rRect)
void Invert ()
 invert current rectangle More...
void LimitToOrigin ()
void Compress (CompressType type)
const SwRectGetOrigin () const
void ChangeOrigin (const SwRect &rRect)

Private Member Functions

void InsertRect (const SwRect &rRect, const sal_uInt16 nPos, bool &rDel)

Private Attributes

SwRect m_aOrigin

Detailed Description

Definition at line 35 of file swregion.hxx.

Member Enumeration Documentation

◆ CompressType


Definition at line 58 of file swregion.hxx.

Constructor & Destructor Documentation

◆ SwRegionRects() [1/2]

SwRegionRects::SwRegionRects ( const SwRect rStartRect,
sal_uInt16  nInit = 20 

Definition at line 24 of file swregion.cxx.

References m_aOrigin.

◆ SwRegionRects() [2/2]

SwRegionRects::SwRegionRects ( sal_uInt16  nInit = 20)

Definition at line 31 of file swregion.cxx.

Member Function Documentation

◆ ChangeOrigin()

void SwRegionRects::ChangeOrigin ( const SwRect rRect)

Definition at line 63 of file swregion.hxx.

References m_aOrigin.

Referenced by SwLayAction::FormatLayout().

◆ Compress()

void SwRegionRects::Compress ( CompressType  type)

◆ GetOrigin()

const SwRect & SwRegionRects::GetOrigin ( ) const

◆ InsertRect()

void SwRegionRects::InsertRect ( const SwRect rRect,
const sal_uInt16  nPos,
bool &  rDel 

Definition at line 39 of file swregion.cxx.

References nPos.

Referenced by operator-=().

◆ Invert()

void SwRegionRects::Invert ( )

invert current rectangle

Change the shape, such that holes with be areas and areas are holes now.

Note: If no rects were removed, then the shape is identical to the original shape. As a result, it will be a NULL-SRectangle after inverting.

Definition at line 126 of file swregion.cxx.

References begin, end, m_aOrigin, size, and swap().

Referenced by SwRootFrame::CalcFrameRects(), and SwShellTableCursor::FillRects().

◆ LimitToOrigin()

void SwRegionRects::LimitToOrigin ( )

Definition at line 148 of file swregion.cxx.

References i, m_aOrigin, and size.

◆ operator+=()

void SwRegionRects::operator+= ( const SwRect rRect)

Definition at line 53 of file swregion.cxx.

◆ operator-=()

void SwRegionRects::operator-= ( const SwRect rRect)

Delete all overlaps of the Rects in array with the given <rRect>

To do so, all existing rectangles have to be either split or deleted.

rRectrectangle with the area that should be deleted

Definition at line 64 of file swregion.cxx.

References begin, SwRect::Bottom(), SwRect::Height(), i, InsertRect(), SwRect::Intersection_(), SwRect::Left(), SwRect::Overlaps(), size, SwRect::Top(), and SwRect::Width().

Member Data Documentation

◆ m_aOrigin

SwRect SwRegionRects::m_aOrigin

Definition at line 37 of file swregion.hxx.

Referenced by ChangeOrigin(), GetOrigin(), Invert(), LimitToOrigin(), and SwRegionRects().

The documentation for this class was generated from the following files: