WKS4SpreadsheetInternal::Spreadsheet Class Reference documentation

Public Types | Public Member Functions | Public Attributes | List of all members
WKS4SpreadsheetInternal::Spreadsheet Class Reference

the spreadsheet of a WPS4Spreadsheet More...

## Public Types
enum | Type { T_Spreadsheet, T_Filter, T_Report }
| the spreadsheet type More...

## Public Member Functions
| Spreadsheet (Type type=T_Spreadsheet, int id=0)
| a constructor More...
Cell & | getCell (Vec2i const &pos)
| return a cell corresponding to a spreadsheet, create one if needed More...
Cell * | getLastCell ()
| returns the last cell More...
void | setColumnWidth (int col, int w=-1)
| set the columns size More...
float | getRowHeight (int row) const
| returns the row size in point More...
float | getRowHeight (int row, int &numRepeated) const
| returns the height of a row in point and updated repeated row More...
void | setRowHeight (int row, int h)
| set the rows size More...
void | compressRowHeights ()
| try to compress the list of row height More...
std::vector< WPSColumnFormat > | getWidths (float defSize=72) const
| return the columns format More...
bool | empty () const
| returns true if the spreedsheet is empty More...

## Public Attributes
Type | m_type
| the spreadsheet type More...
int | m_id
| the spreadsheet id More...
int | m_numCols
| the number of columns More...
int | m_numRows
| the number of rows More...
std::vector< int > | m_widthCols
| the column size in TWIP (?) More...
std::map< Vec2i, int > | m_rowHeightMap
| the map Vec2i(min row, max row) to size in TWIP (?) More...
int | m_heightDefault
| the default row size in point More...
std::map< Vec2i, Cell > | m_positionToCellMap
| a map cell to not empty cells More...
Vec2i | m_lastCellPos
| the last cell position More...
std::vector< int > | m_rowPageBreaksList
| the list of row page break More...

## Detailed Description

the spreadsheet of a WPS4Spreadsheet

## Member Enumeration Documentation

## ◆ Type

enum WKS4SpreadsheetInternal::Spreadsheet::Type

the spreadsheet type

Enumerator
T_Spreadsheet |
T_Filter |
T_Report |

## Constructor & Destructor Documentation

## ◆ Spreadsheet()

WKS4SpreadsheetInternal::Spreadsheet::Spreadsheet | ( | Type | type = `T_Spreadsheet`,
|  | int | id = `0`
| ) |  |
| inline

a constructor

## Member Function Documentation

## ◆ compressRowHeights()

void WKS4SpreadsheetInternal::Spreadsheet::compressRowHeights | ( |  | ) |
| inline

try to compress the list of row height

## ◆ empty()

bool WKS4SpreadsheetInternal::Spreadsheet::empty | ( |  | ) | const
| inline

returns true if the spreedsheet is empty

## ◆ getCell()

Cell& WKS4SpreadsheetInternal::Spreadsheet::getCell | ( | Vec2i const & | pos | ) |
| inline

return a cell corresponding to a spreadsheet, create one if needed

## ◆ getLastCell()

Cell* WKS4SpreadsheetInternal::Spreadsheet::getLastCell | ( |  | ) |
| inline

returns the last cell

## ◆ getRowHeight() [1/2]

float WKS4SpreadsheetInternal::Spreadsheet::getRowHeight | ( | int | row | ) | const
| inline

returns the row size in point

## ◆ getRowHeight() [2/2]

float WKS4SpreadsheetInternal::Spreadsheet::getRowHeight | ( | int | row,
|  | int & | numRepeated
| ) |  | const
| inline

returns the height of a row in point and updated repeated row

Note
  : you must first call compressRowHeigths

## ◆ getWidths()

std::vector<WPSColumnFormat> WKS4SpreadsheetInternal::Spreadsheet::getWidths | ( | float | defSize = `72` | ) | const
| inline

return the columns format

## ◆ setColumnWidth()

void WKS4SpreadsheetInternal::Spreadsheet::setColumnWidth | ( | int | col,
|  | int | w = `-1`
| ) |  |
| inline

set the columns size

## ◆ setRowHeight()

void WKS4SpreadsheetInternal::Spreadsheet::setRowHeight | ( | int | row,
|  | int | h
| ) |  |
| inline

set the rows size

## Member Data Documentation

## ◆ m_heightDefault

int WKS4SpreadsheetInternal::Spreadsheet::m_heightDefault

the default row size in point

## ◆ m_id

int WKS4SpreadsheetInternal::Spreadsheet::m_id

the spreadsheet id

## ◆ m_lastCellPos

Vec2i WKS4SpreadsheetInternal::Spreadsheet::m_lastCellPos

the last cell position

## ◆ m_numCols

int WKS4SpreadsheetInternal::Spreadsheet::m_numCols

the number of columns

## ◆ m_numRows

int WKS4SpreadsheetInternal::Spreadsheet::m_numRows

the number of rows

## ◆ m_positionToCellMap

std::map<Vec2i, Cell> WKS4SpreadsheetInternal::Spreadsheet::m_positionToCellMap

a map cell to not empty cells

## ◆ m_rowHeightMap

std::map<Vec2i,int> WKS4SpreadsheetInternal::Spreadsheet::m_rowHeightMap

the map Vec2i(min row, max row) to size in TWIP (?)

## ◆ m_rowPageBreaksList

std::vector<int> WKS4SpreadsheetInternal::Spreadsheet::m_rowPageBreaksList

the list of row page break

## ◆ m_type

Type WKS4SpreadsheetInternal::Spreadsheet::m_type

the spreadsheet type

## ◆ m_widthCols

std::vector<int> WKS4SpreadsheetInternal::Spreadsheet::m_widthCols

the column size in TWIP (?)

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

- WKS4Spreadsheet.cpp