STOFFCell Class Reference

a structure used to define a cell and its format More...

#include <STOFFCell.hxx>

Inheritance diagram for STOFFCell:
StarObjectSpreadsheetInternal::Cell

List of all members.

Classes

struct  Format
 a structure uses to define the format of a cell content More...

Public Types

enum  FormatType {
  F_TEXT, F_BOOLEAN, F_NUMBER, F_DATE,
  F_TIME, F_DATETIME, F_UNKNOWN
}
 the different format of a cell's content More...
enum  NumberType {
  F_NUMBER_CURRENCY, F_NUMBER_DECIMAL, F_NUMBER_FRACTION, F_NUMBER_GENERIC,
  F_NUMBER_SCIENTIFIC, F_NUMBER_PERCENT, F_NUMBER_UNKNOWN
}
 the different number format of a cell's content More...

Public Member Functions

 STOFFCell ()
 constructor
virtual ~STOFFCell ()
 destructor
void addTo (librevenge::RVNGPropertyList &propList) const
 adds to the propList
virtual bool send (STOFFListenerPtr listener, STOFFTable &table)
 function called when a cell is send by STOFFTable to send a cell to a listener.
virtual bool sendContent (STOFFListenerPtr listener, STOFFTable &table)
 function called when the content of a cell must be send to the listener, ie.
STOFFVec2i const & position () const
 position accessor
void setPosition (STOFFVec2i posi)
 set the cell positions : 0,0 -> A1, 0,1 -> A2
STOFFBox2f const & bdBox () const
 bdbox accessor
void setBdBox (STOFFBox2f box)
 set the bdbox (unit point)
STOFFVec2f const & bdSize () const
 bdbox size accessor
void setBdSize (STOFFVec2f sz)
 set the bdbox size(unit point)
Format const & getFormat () const
 returns the cell format
void setFormat (Format const &format)
 set the cell format
STOFFFont const & getFont () const
 returns the font
void setFont (STOFFFont const &font)
 set the font
STOFFCellStyle const & getCellStyle () const
 returns the cell style
STOFFCellStylegetCellStyle ()
 returns the cell style
void setCellStyle (STOFFCellStyle const &cellStyle)
 set the cell style
librevenge::RVNGPropertyList
const & 
getNumberingStyle () const
 returns the numbering style
librevenge::RVNGPropertyList & getNumberingStyle ()
 returns the numbering style
void setNumberingStyle (librevenge::RVNGPropertyList const &numberStyle)
 set the numbering style

Static Public Member Functions

static std::string getCellName (STOFFVec2i const &pos, STOFFVec2b const &absolute)
 return the name of a cell (given row and column) : 0,0 -> A1, 0,1 -> A2
static std::string getColumnName (int col)
 return the column name

Protected Attributes

STOFFVec2i m_position
 the cell row and column : 0,0 -> A1, 0,1 -> A2
STOFFBox2f m_bdBox
 the cell bounding box (unit in point)
STOFFVec2f m_bdSize
 the cell bounding size : unit point
Format m_format
 the cell format
STOFFFont m_font
 the cell font
STOFFCellStyle m_cellStyle
 the cell cell style
librevenge::RVNGPropertyList m_numberingStyle
 the numbering style

Friends

std::ostream & operator<< (std::ostream &o, STOFFCell const &cell)
 operator<<

Detailed Description

a structure used to define a cell and its format


Member Enumeration Documentation

the different format of a cell's content

Enumerator:
F_TEXT 
F_BOOLEAN 
F_NUMBER 
F_DATE 
F_TIME 
F_DATETIME 
F_UNKNOWN 

the different number format of a cell's content

Enumerator:
F_NUMBER_CURRENCY 
F_NUMBER_DECIMAL 
F_NUMBER_FRACTION 
F_NUMBER_GENERIC 
F_NUMBER_SCIENTIFIC 
F_NUMBER_PERCENT 
F_NUMBER_UNKNOWN 

Constructor & Destructor Documentation

STOFFCell::STOFFCell ( ) [inline]

constructor

virtual STOFFCell::~STOFFCell ( ) [inline, virtual]

destructor


Member Function Documentation

STOFFVec2f const& STOFFCell::bdSize ( ) const [inline]

bdbox size accessor

std::string STOFFCell::getCellName ( STOFFVec2i const &  pos,
STOFFVec2b const &  absolute 
) [static]

return the name of a cell (given row and column) : 0,0 -> A1, 0,1 -> A2

Referenced by operator<<().

STOFFCellStyle const& STOFFCell::getCellStyle ( ) const [inline]

returns the cell style

Referenced by StarFormatManager::updateNumberingProperties().

returns the cell style

std::string STOFFCell::getColumnName ( int  col) [static]

return the column name

STOFFFont const& STOFFCell::getFont ( ) const [inline]

returns the font

librevenge::RVNGPropertyList& STOFFCell::getNumberingStyle ( ) [inline]

returns the numbering style

STOFFVec2i const& STOFFCell::position ( ) const [inline]

position accessor

Referenced by addTo().

bool STOFFCell::send ( STOFFListenerPtr  listener,
STOFFTable table 
) [virtual]

function called when a cell is send by STOFFTable to send a cell to a listener.

By default: calls openTableCell(*this), sendContent and then closeTableCell()

bool STOFFCell::sendContent ( STOFFListenerPtr  listener,
STOFFTable table 
) [virtual]

function called when the content of a cell must be send to the listener, ie.

when STOFFTable::sendTable or STOFFTable::sendAsText is called.

Note:
default behavior: does nothing and prints an error in debug mode.

Referenced by send().

void STOFFCell::setBdBox ( STOFFBox2f  box) [inline]

set the bdbox (unit point)

void STOFFCell::setBdSize ( STOFFVec2f  sz) [inline]

set the bdbox size(unit point)

void STOFFCell::setCellStyle ( STOFFCellStyle const &  cellStyle) [inline]
void STOFFCell::setFont ( STOFFFont const &  font) [inline]

set the font

Referenced by StarObjectSpreadsheet::sendCell().

void STOFFCell::setNumberingStyle ( librevenge::RVNGPropertyList const &  numberStyle) [inline]

set the numbering style

void STOFFCell::setPosition ( STOFFVec2i  posi) [inline]

Friends And Related Function Documentation

std::ostream& operator<< ( std::ostream &  o,
STOFFCell const &  cell 
) [friend]

operator<<


Member Data Documentation

the cell bounding box (unit in point)

Referenced by bdBox(), operator<<(), and setBdBox().

the cell bounding size : unit point

Referenced by bdSize(), operator<<(), and setBdSize().

the cell cell style

Referenced by addTo(), getCellStyle(), and setCellStyle().

the cell font

Referenced by addTo(), getFont(), and setFont().

librevenge::RVNGPropertyList STOFFCell::m_numberingStyle [protected]

the numbering style

Referenced by getNumberingStyle(), and setNumberingStyle().

the cell row and column : 0,0 -> A1, 0,1 -> A2

Referenced by STOFFCellContent::FormulaInstruction::getPropertyList(), operator<<(), position(), and setPosition().


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