LibreOffice Module sw (master)  1
Classes | Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes | Friends | List of all members
SwContourCache Class Reference

#include <txtfly.hxx>

Classes

struct  CacheItem
 

Public Member Functions

 SwContourCache ()
 
 ~SwContourCache ()
 
const SdrObjectGetObject (sal_uInt16 nPos) const
 
sal_uInt16 GetCount () const
 
void ClrObject (sal_uInt16 nPos)
 

Static Public Member Functions

static const SwRect CalcBoundRect (const SwAnchoredObject *pAnchoredObj, const SwRect &rLine, const SwTextFrame *pFrame, const long nXPos, const bool bRight)
 Computes the rectangle that will cover the object in the given line. More...
 

Private Member Functions

const SwRect ContourRect (const SwFormat *pFormat, const SdrObject *pObj, const SwTextFrame *pFrame, const SwRect &rLine, const long nXPos, const bool bRight)
 

Private Attributes

std::vector< CacheItemmvItems
 
long nPntCnt
 

Friends

void ClrContourCache ()
 

Detailed Description

Definition at line 52 of file txtfly.hxx.

Constructor & Destructor Documentation

SwContourCache::SwContourCache ( )

Definition at line 125 of file txtfly.cxx.

Referenced by CalcBoundRect().

SwContourCache::~SwContourCache ( )

Definition at line 130 of file txtfly.cxx.

Member Function Documentation

const SwRect SwContourCache::CalcBoundRect ( const SwAnchoredObject pAnchoredObj,
const SwRect rLine,
const SwTextFrame pFrame,
const long  nXPos,
const bool  bRight 
)
static

Computes the rectangle that will cover the object in the given line.

For non contour-flow objects, this is simply the overlap area of BoundRect (including spacing), and the line, for contour-flow, the tools::PolyPolygon of the object gets traversed

Definition at line 161 of file txtfly.cxx.

References ContourRect(), SwAnchoredObject::GetDrawObj(), SwAnchoredObject::GetFrameFormat(), SwAnchoredObject::GetObjRectWithSpaces(), SwFormat::GetSurround(), SwFormatSurround::IsContour(), SwRect::IsOver(), Lower, pContourCache, SwFlyFreeFrame::supportsAutoContour(), SwContourCache(), and SwRect::Width().

Referenced by SwTextFly::AnchoredObjToRect(), SwTextFly::CalcLeftMargin(), and SwTextFly::CalcRightMargin().

void SwContourCache::ClrObject ( sal_uInt16  nPos)

Definition at line 134 of file txtfly.cxx.

References mvItems, and nPntCnt.

Referenced by ClrContourCache().

const SwRect SwContourCache::ContourRect ( const SwFormat pFormat,
const SdrObject pObj,
const SwTextFrame pFrame,
const SwRect rLine,
const long  nXPos,
const bool  bRight 
)
private
sal_uInt16 SwContourCache::GetCount ( ) const
inline

Definition at line 70 of file txtfly.hxx.

Referenced by ClrContourCache(), and ContourRect().

const SdrObject* SwContourCache::GetObject ( sal_uInt16  nPos) const
inline

Definition at line 69 of file txtfly.hxx.

Referenced by ClrContourCache().

Friends And Related Function Documentation

void ClrContourCache ( )
friend

Definition at line 151 of file txtfly.cxx.

Member Data Documentation

std::vector<CacheItem> SwContourCache::mvItems
private

Definition at line 60 of file txtfly.hxx.

Referenced by ClrContourCache(), ClrObject(), and ContourRect().

long SwContourCache::nPntCnt
private

Definition at line 61 of file txtfly.hxx.

Referenced by ClrContourCache(), ClrObject(), and ContourRect().


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