LibreOffice Module sc (master) 1
Classes | Public Types | Public Member Functions | Private Attributes | Static Private Attributes | List of all members
ScPositionHelper Class Reference

#include <viewdata.hxx>

Classes

class  Comp
 

Public Types

typedef SCCOLROW index_type
 
typedef std::pair< index_type, tools::Longvalue_type
 

Public Member Functions

 ScPositionHelper (const ScDocument *pDoc, bool bColumn)
 
void setDocument (const ScDocument &rDoc, bool bColumn)
 
void insert (index_type nIndex, tools::Long nPos)
 
void removeByIndex (index_type nIndex)
 
void invalidateByIndex (index_type nIndex)
 
void invalidateByPosition (tools::Long nPos)
 
const value_typegetNearestByIndex (index_type nIndex) const
 
const value_typegetNearestByPosition (tools::Long nPos) const
 
tools::Long getPosition (index_type nIndex) const
 
tools::Long computePosition (index_type nIndex, const std::function< long(index_type)> &getSizePx)
 

Private Attributes

index_type MAX_INDEX
 
std::set< value_type, CompmData
 

Static Private Attributes

static const index_type null = std::numeric_limits<index_type>::min()
 

Detailed Description

Definition at line 119 of file viewdata.hxx.

Member Typedef Documentation

◆ index_type

Definition at line 122 of file viewdata.hxx.

◆ value_type

Definition at line 123 of file viewdata.hxx.

Constructor & Destructor Documentation

◆ ScPositionHelper()

ScPositionHelper::ScPositionHelper ( const ScDocument pDoc,
bool  bColumn 
)

Definition at line 127 of file viewdata.cxx.

References mData.

Member Function Documentation

◆ computePosition()

tools::Long ScPositionHelper::computePosition ( index_type  nIndex,
const std::function< long(index_type)> &  getSizePx 
)

◆ getNearestByIndex()

const ScPositionHelper::value_type & ScPositionHelper::getNearestByIndex ( index_type  nIndex) const

Definition at line 194 of file viewdata.cxx.

References mData, nIndex, and SAL_INFO.

Referenced by computePosition(), and ScViewData::GetScrPos().

◆ getNearestByPosition()

const ScPositionHelper::value_type & ScPositionHelper::getNearestByPosition ( tools::Long  nPos) const

Definition at line 224 of file viewdata.cxx.

References mData, nPos, null, and SAL_INFO.

◆ getPosition()

tools::Long ScPositionHelper::getPosition ( index_type  nIndex) const

Definition at line 255 of file viewdata.cxx.

References mData, and nIndex.

Referenced by ScViewData::GetLOKDocHeightPixel(), and ScViewData::GetLOKDocWidthPixel().

◆ insert()

void ScPositionHelper::insert ( index_type  nIndex,
tools::Long  nPos 
)

◆ invalidateByIndex()

void ScPositionHelper::invalidateByIndex ( index_type  nIndex)

Definition at line 163 of file viewdata.cxx.

References mData, nIndex, and SAL_INFO.

◆ invalidateByPosition()

void ScPositionHelper::invalidateByPosition ( tools::Long  nPos)

Definition at line 178 of file viewdata.cxx.

References mData, nPos, null, and SAL_INFO.

◆ removeByIndex()

void ScPositionHelper::removeByIndex ( index_type  nIndex)

◆ setDocument()

void ScPositionHelper::setDocument ( const ScDocument rDoc,
bool  bColumn 
)

Definition at line 133 of file viewdata.cxx.

References MAX_INDEX, ScDocument::MaxCol(), and MAXTILEDROW.

Referenced by ScViewDataTable::InitData().

Member Data Documentation

◆ MAX_INDEX

index_type ScPositionHelper::MAX_INDEX
private

Definition at line 135 of file viewdata.hxx.

Referenced by computePosition(), and setDocument().

◆ mData

std::set<value_type, Comp> ScPositionHelper::mData
private

◆ null

const ScPositionHelper::index_type ScPositionHelper::null = std::numeric_limits<index_type>::min()
staticprivate

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