kspread
KSpread::Cell Class Reference
#include <kspread_cell.h>
Detailed Description
For every cell in the spread sheet there is a Cell object.Cell contains format information and algorithm and it contains the calculation algorithm.
However, all empty cells are represented by one instace, called the default cell. isDefault can be used to determine whether or not a Cell object represents the default one.
Definition at line 137 of file kspread_cell.h.
Public Types | |
enum | BorderSides { Border_None = 0x00, Border_Left = 0x01, Border_Right = 0x02, Border_Top = 0x04, Border_Bottom = 0x08, Border_SizeGrip = 0x10 } |
enum | CellFlags { Flag_LayoutDirty = 0x00010000, Flag_CalcDirty = 0x00020000, Flag_Progress = 0x00040000, Flag_UpdatingDeps = 0x00080000, Flag_DisplayDirty = 0x00100000, Flag_Merged = 0x00200000, Flag_CellTooShortX = 0x00400000, Flag_CellTooShortY = 0x00800000, Flag_ParseError = 0x01000000, Flag_CircularCalculation = 0x02000000, Flag_DependancyError = 0x04000000, Flag_PaintingCell = 0x08000000, Flag_TextFormatDirty = 0x10000000 } |
Public Member Functions | |
Cell (Sheet *_sheet, int _column, int _row) | |
Cell (Sheet *_sheet, Style *_style, int _column, int _row) | |
~Cell () | |
Sheet * | sheet () const |
bool | isDefault () const |
bool | isEmpty () const |
int | column () const |
int | row () const |
QString | name () const |
QString | fullName () const |
QString | columnName () const |
KLocale * | locale () const |
bool | isFormula () const |
QString | text () const |
QString | strOutText () const |
Formula * | formula () const |
Format * | format () const |
const Value | value () const |
void | setValue (const Value &value) |
void | setCellValue (const Value &value, FormatType fmtType=No_format, const QString &inputText=QString::null) |
Cell * | previousCell () const |
Cell * | nextCell () const |
void | setPreviousCell (Cell *c) |
void | setNextCell (Cell *c) |
void | move (int column, int row) |
void | sheetDies () |
QDomElement | save (QDomDocument &doc, int _x_offset=0, int _y_offset=0, bool force=false, bool copy=false, bool era=false) |
bool | saveOasis (KoXmlWriter &xmlwriter, KoGenStyles &mainStyles, int row, int column, int &repeated, GenValidationStyles &valStyle) |
void | saveOasisValue (KoXmlWriter &xmlWriter) |
QString | saveOasisCellStyle (KoGenStyle ¤tCellStyle, KoGenStyles &mainStyles) |
bool | load (const QDomElement &cell, int _xshift, int _yshift, Paste::Mode pm=Paste::Normal, Paste::Operation op=Paste::OverWrite, bool paste=false) |
bool | loadOasis (const QDomElement &element, KoOasisLoadingContext &oasisContext, Style *style) |
QTime | toTime (const QDomElement &element) |
QDate | toDate (const QDomElement &element) |
void | copyFormat (const int column, const int row) |
void | copyFormat (const Cell *cell) |
void | copyContent (const Cell *cell) |
void | copyAll (Cell *cell) |
void | paintCell (const KoRect &rect, QPainter &painter, View *view, const KoPoint &coordinate, const QPoint &cellRef, int paintBorder, QPen &rightPen, QPen &bottomPen, QPen &leftPen, QPen &topPen, QValueList< QPoint > &mergedCellsPainted, bool drawCursor=true) |
int | width (int _col=-1, const Canvas *_canvas=0L) const |
int | height (int _row=-1, const Canvas *_canvas=0L) const |
double | dblWidth (int _col=-1, const Canvas *_canvas=0L) const |
double | dblHeight (int _row=-1, const Canvas *_canvas=0L) const |
QRect | cellRect () |
bool | needsPrinting () const |
void | incPrecision () |
void | decPrecision () |
void | setCellText (const QString &_text, bool asString=false) |
void | setDisplayText (const QString &_text) |
void | setLink (const QString &link) |
QString | link () const |
const QPen & | effLeftBorderPen (int col, int row) const |
const QPen & | effTopBorderPen (int col, int row) const |
const QPen & | effRightBorderPen (int col, int row) const |
const QPen & | effBottomBorderPen (int col, int row) const |
const QPen & | effGoUpDiagonalPen (int col, int row) const |
const QPen & | effFallDiagonalPen (int col, int row) const |
const QColor & | effTextColor (int col, int row) const |
uint | effBottomBorderValue (int col, int row) const |
uint | effRightBorderValue (int col, int row) const |
uint | effLeftBorderValue (int col, int row) const |
uint | effTopBorderValue (int col, int row) const |
const QPen & | leftBorderPen (int col, int row) const |
const QPen & | topBorderPen (int col, int row) const |
const QPen & | rightBorderPen (int col, int row) const |
const QPen & | bottomBorderPen (int col, int row) const |
const QColor & | bgColor (int col, int row) const |
const QBrush & | backGroundBrush (int col, int row) const |
void | setLeftBorderPen (const QPen &p) |
void | setTopBorderPen (const QPen &p) |
void | setRightBorderPen (const QPen &p) |
void | setBottomBorderPen (const QPen &p) |
FormatType | formatType () const |
bool | isDate () const |
bool | isTime () const |
void | setNumber (double number) |
double | getDouble () |
void | convertToDouble () |
void | convertToPercent () |
void | convertToMoney () |
void | convertToTime () |
void | convertToDate () |
double | textWidth () const |
double | textHeight () const |
bool | updateChart (bool refresh=true) |
QString | testAnchor (int _x, int _y) const |
bool | calc (bool delay=true) |
void | setCalcDirtyFlag () |
bool | calcDirtyFlag () |
void | NotifyDepending (int col, int row, Sheet *sheet, bool isDepending) |
void | setLayoutDirtyFlag (bool format=false) |
bool | layoutDirtyFlag () const |
void | clearDisplayDirtyFlag () |
void | setDisplayDirtyFlag () |
void | obscure (Cell *cell, bool isForcing=false) |
void | unobscure (Cell *cell) |
bool | isObscured () const |
bool | isPartOfMerged () const |
Cell * | ultimateObscuringCell () const |
QValueList< Cell * > | obscuringCells () const |
void | clearObscuringCells () |
void | mergeCells (int _col, int _row, int _x, int _y) |
bool | doesMergeCells () const |
int | mergedXCells () const |
int | mergedYCells () const |
int | extraXCells () const |
int | extraYCells () const |
double | extraWidth () const |
double | extraHeight () const |
QString | encodeFormula (bool _era=false, int _col=-1, int _row=-1) const |
QString | decodeFormula (const QString &_text, int _col=-1, int _row=-1) const |
QString | pasteOperation (const QString &new_text, const QString &old_text, Paste::Operation op) |
bool | hasError () const |
void | clearAllErrors () |
void | makeLayout (QPainter &_painter, int _col, int _row) |
bool | makeFormula () |
void | defaultStyle () |
QValueList< Conditional > | conditionList () const |
void | setConditionList (const QValueList< Conditional > &newList) |
Validity * | getValidity (int newStruct=-1) |
void | removeValidity () |
bool | testValidity () const |
void | calculateTextParameters (QPainter &painter, int _col, int _row) |
int | defineAlignX () |
bool | operator> (const Cell &) const |
bool | operator< (const Cell &) const |
bool | operator== (const Cell &other) const |
bool | operator!= (const Cell &other) const |
void | freeAllObscuredCells () |
void | clearFlag (CellFlags flag) |
void | setFlag (CellFlags flag) |
bool | testFlag (CellFlags flag) const |
Static Public Member Functions | |
static QString | name (int col, int row) |
static QString | fullName (const Sheet *s, int col, int row) |
static QString | columnName (uint column) |
Protected Member Functions | |
void | applyZoomedFont (QPainter &painter, int _col, int _row) |
void | textSize (QPainter &_paint) |
QString | textDisplaying (QPainter &painter) |
void | clearFormula () |
void | checkTextInput () |
void | checkNumberFormat () |
void | loadOasisCellText (const QDomElement &parent) |
void | loadOasisObjects (const QDomElement &e, KoOasisLoadingContext &oasisContext) |
void | loadOasisValidation (const QString &validationName) |
void | loadOasisValidationCondition (QString &valExpression) |
void | saveOasisAnnotation (KoXmlWriter &xmlwriter) |
void | loadOasisConditional (QDomElement *style) |
Friends | |
class | Conditions |
Constructor & Destructor Documentation
Cell::~Cell | ( | ) |
Member Function Documentation
Sheet * Cell::sheet | ( | ) | const |
bool Cell::isDefault | ( | ) | const |
Returns true if this is a default cell (with row and column equal to zero).
Normally, cell constructed within a sheet can't be a default cell.
Definition at line 328 of file kspread_cell.cc.
bool Cell::isEmpty | ( | ) | const |
Returns true if this cell has no content, i.e no text and no formula.
Definition at line 822 of file kspread_cell.cc.
int Cell::column | ( | ) | const |
Returns the cell's column.
This could be 0 if the cell is the default cell.
Definition at line 352 of file kspread_cell.cc.
int Cell::row | ( | ) | const |
Returns the cell's row.
This could be 0 if the cell is the default cell.
Definition at line 334 of file kspread_cell.cc.
QString Cell::name | ( | ) | const |
Returns the name of the cell.
For example, the cell in first column and first row is "A1".
Definition at line 369 of file kspread_cell.cc.
QString Cell::fullName | ( | ) | const |
Returns the full name of the cell, i.e.
including the worksheet name. Example: "Sheet1!A1"
Definition at line 386 of file kspread_cell.cc.
QString Cell::columnName | ( | ) | const |
Given the cell position, this static function returns the name of the cell.
Example: name(5,4) will return "E4".
Definition at line 377 of file kspread_cell.cc.
Given the sheet and cell position, this static function returns the full name of the cell, i.e.
with the name of the sheet.
Definition at line 394 of file kspread_cell.cc.
QString Cell::columnName | ( | uint | column | ) | [static] |
Given the column number, this static function returns the corresponding column name, i.e.
the first column is "A", the second is "B", and so on.
Definition at line 414 of file kspread_cell.cc.
KLocale * Cell::locale | ( | ) | const |
bool Cell::isFormula | ( | ) | const |
QString Cell::text | ( | ) | const |
Return the text the user entered.
This could be a value (e.g. "14.03") or a formula (e.g. "=SUM(A1:A10)")
Definition at line 448 of file kspread_cell.cc.
Format * Cell::format | ( | ) | const |
const Value Cell::value | ( | ) | const |
Returns the value that this cell holds.
It could be from the user (i.e. when s/he enters a value) or a result of formula.
Definition at line 471 of file kspread_cell.cc.
void Cell::setValue | ( | const Value & | value | ) |
void Cell::setCellValue | ( | const Value & | value, | |
FormatType | fmtType = No_format , |
|||
const QString & | inputText = QString::null | |||
) |
Sets the value for this cell and its formatting and input text, if appropriate.
Can therefore be used as a replacement for setCellText, if we don't need to parse.
If inputText
is empty and the cell has NO formula, the input text is created from value
.
- Parameters:
-
value the new cell value fmtType the formatting type inputText the new input text
- Note:
- Calls setValue() after setting the formatting and input text.
Definition at line 516 of file kspread_cell.cc.
Moves around the cell.
It cares about obscured and obscuring cells and forces, relayout, calculation and redrawing of the cell.
Definition at line 724 of file kspread_cell.cc.
void Cell::sheetDies | ( | ) |
This method notifies the cell that the parent sheet is being deleted.
Definition at line 7062 of file kspread_cell.cc.
QDomElement Cell::save | ( | QDomDocument & | doc, | |
int | _x_offset = 0 , |
|||
int | _y_offset = 0 , |
|||
bool | force = false , |
|||
bool | copy = false , |
|||
bool | era = false | |||
) |
Save this cell.
- Parameters:
-
doc document to save cell in _x_offset x offset _y_offset y offset force if set to true, all the properties of the format are stored (used for "Copy"), otherwise only the non-default properties will be stored. Set this to false if you want smaller files. copy if set to true, all cell formats will be copied instead of referencing the format (style name), thus resulting in larger output (files). Set this to false if you want smaller files. era set this to true if you want to encode relative references as absolutely (they will be switched back to relative references during decoding) - is used for cutting to clipboard Usually this is false, to only store the properties explicitely set.
Definition at line 5151 of file kspread_cell.cc.
QString Cell::saveOasisCellStyle | ( | KoGenStyle & | currentCellStyle, | |
KoGenStyles & | mainStyles | |||
) |
bool Cell::loadOasis | ( | const QDomElement & | element, | |
KoOasisLoadingContext & | oasisContext, | |||
Style * | style | |||
) |
Loads a cell from an OASIS XML element.
- Parameters:
-
element An OASIS XML element oasisContext The loading context assoiated with the XML element
Definition at line 5686 of file kspread_cell.cc.
Copyies the format from the cell at the position (_column|_row).
- See also:
- copyAll
Definition at line 575 of file kspread_cell.cc.
void Cell::copyFormat | ( | const Cell * | cell | ) |
void Cell::copyAll | ( | Cell * | cell | ) |
Copies the format and the content.
It does not copy the m_row and m_column attributes. Besides that all persistent attributes are copied. setCellText is called to set the real content.
- See also:
- copyFormat
Definition at line 632 of file kspread_cell.cc.
void Cell::paintCell | ( | const KoRect & | rect, | |
QPainter & | painter, | |||
View * | view, | |||
const KoPoint & | coordinate, | |||
const QPoint & | cellRef, | |||
int | paintBorder, | |||
QPen & | rightPen, | |||
QPen & | bottomPen, | |||
QPen & | leftPen, | |||
QPen & | topPen, | |||
QValueList< QPoint > & | mergedCellsPainted, | |||
bool | drawCursor = true | |||
) |
Paints the cell.
- Parameters:
-
rect the portion of the canvas that is actually in view painter the painter object to paint on view the view of this data. This may be NULL, but no selection will be included with the painting. coordinate coordinates on the painter where the top left corner of the cell should be painted plus width and height cellRef the column/row coordinates of the cell. paintBorder a combination of flags from the Cell::BorderSides enum which specifies which cell borders to paint rightPen pen to use to draw the right border if paintBorder
includes the Border_Right flagbottomPen pen to use to draw the bottom border if paintBorderBottom
includes the Border_Bottom flagleftPen pen to use to draw the left border if paintBorderLeft
includes the Border_Left flagtopPen pen to use to draw the top border if paintBorderTop
includes the Border_Top flagmergedCellsPainted list of merged cells being painted drawCursor whether to draw the cursor and selection or not
Definition at line 2136 of file kspread_cell.cc.
- Parameters:
-
_col the column this cell is assumed to be in.
This parameter defaults to the return value of column.
- Parameters:
-
_canvas the canvas this cell is assumed to be in.
- Returns:
- the width of this cell as int
Definition at line 4213 of file kspread_cell.cc.
- Parameters:
-
_row the row this cell is assumed to be in.
- Parameters:
-
_canvas the canvas this cell is assumed to be in.
- Returns:
- the height of this cell as int
Definition at line 4239 of file kspread_cell.cc.
- Parameters:
-
_canvas the canvas this cell is assumed to be in.
- Parameters:
-
_col the column this cell is assumed to be in. This parameter defaults to the return value of column.
- Returns:
- the width of this cell as double
Definition at line 4192 of file kspread_cell.cc.
- Parameters:
-
_row the row this cell is assumed to be in.
- Parameters:
-
_canvas the canvas this cell is assumed to be in.
- Returns:
- the height of this cell as double
Definition at line 4218 of file kspread_cell.cc.
QRect Cell::cellRect | ( | ) |
- Returns:
- a QRect for this cell (i.e., a 1x1 rect).
- See also:
- zoomedCellRect
Definition at line 7222 of file kspread_cell.cc.
bool Cell::needsPrinting | ( | ) | const |
- Returns:
- true if the cell should be printed in a print out.
That si the case if it has any content, border, backgroundcolor, or background brush.
- See also:
- Sheet::print
Definition at line 778 of file kspread_cell.cc.
void Cell::incPrecision | ( | ) |
Increases the precison of the value displayed.
Precision means here the amount of digits behind the dot. If the current precision is the default of -1, then it is set to the number of digits behind the dot plus 1.
Definition at line 4539 of file kspread_cell.cc.
void Cell::decPrecision | ( | ) |
Decreases the precison of the value displayed.
Precision means here the amount of digits behind the dot. If the current precision is the default of -1, then it is set to the number of digits behind the dot minus 1.
Definition at line 4575 of file kspread_cell.cc.
void Cell::setCellText | ( | const QString & | _text, | |
bool | asString = false | |||
) |
The high-level method for setting text, when the user inputs it.
It will revert back to the old text if testValidity() returns action==stop.
Definition at line 4621 of file kspread_cell.cc.
void Cell::setDisplayText | ( | const QString & | _text | ) |
Sets the text in the cell when the user inputs it.
Will determine the type of contents automatically. Called by setCellText.
A real formula "=A1+A2*3" was entered.
Some numeric value or a string.
Definition at line 4654 of file kspread_cell.cc.
void Cell::setLink | ( | const QString & | link | ) |
Sets a link for this cell.
For example, setLink( "mailto:joe@somewhere.com" ) will open a new e-mail if this cell is clicked. Possible choices for link are URL (web, ftp), e-mail address, local file, or another cell.
Definition at line 4692 of file kspread_cell.cc.
QString Cell::link | ( | ) | const |
Returns the link associated with cell.
It is empty if this cell contains no link.
Definition at line 4700 of file kspread_cell.cc.
- Returns:
- effective pen for the left border If this cell is merged by another cell, the other cell's left border pen.
If this cell's conditional formatting contains a left border pen and the condition is matched, the conditional formatting's pen. Otherwise, its own left border pen.
Definition at line 4389 of file kspread_cell.cc.
- Returns:
- effective pen for the top border
- See also:
- effLeftBorderPen
Definition at line 4405 of file kspread_cell.cc.
- Returns:
- effective pen for the right border
- See also:
- effLeftBorderPen
Definition at line 4421 of file kspread_cell.cc.
- Returns:
- effective pen for the bottom border
- See also:
- effLeftBorderPen
Definition at line 4437 of file kspread_cell.cc.
- Returns:
- effective pen for the go up diagonal border If this cell's conditional formatting contains a go up diagonal pen and the condition is matched, the conditional formatting's pen.
Otherwise, its own go up diagonal pen.
Definition at line 4453 of file kspread_cell.cc.
- Returns:
- effective pen for the go up diagonal border
- See also:
- effGoUpDiagonalPen
Definition at line 4463 of file kspread_cell.cc.
- Returns:
- "worth" of the effective bottom border pen
- See also:
- Style::calculateValue
Definition at line 4473 of file kspread_cell.cc.
- Returns:
- "worth" of the effective right border pen
- See also:
- Style::calculateValue
Definition at line 4488 of file kspread_cell.cc.
- Returns:
- "worth" of the effective left border pen
- See also:
- Style::calculateValue
Definition at line 4503 of file kspread_cell.cc.
- Returns:
- "worth" of the effective top border pen
- See also:
- Style::calculateValue
Definition at line 4518 of file kspread_cell.cc.
void Cell::setLeftBorderPen | ( | const QPen & | p | ) |
void Cell::setTopBorderPen | ( | const QPen & | p | ) |
void Cell::setRightBorderPen | ( | const QPen & | p | ) |
void Cell::setBottomBorderPen | ( | const QPen & | p | ) |
FormatType Cell::formatType | ( | ) | const |
Return the format of this cell.
Convenience method for Format::getFormatType Note that this is "how the user would like the data to be displayed if possible". If he selects a date format, and the cell contains a string, we won't apply that format.
Definition at line 4929 of file kspread_cell.cc.
bool Cell::isDate | ( | ) | const |
returns true, if cell format is of date type or content is a date
Definition at line 4975 of file kspread_cell.cc.
bool Cell::isTime | ( | ) | const |
returns true, if cell format is of time type or content is a time
Definition at line 4983 of file kspread_cell.cc.
double Cell::getDouble | ( | ) |
void Cell::convertToDouble | ( | ) |
void Cell::convertToPercent | ( | ) |
void Cell::convertToMoney | ( | ) |
void Cell::convertToTime | ( | ) |
void Cell::convertToDate | ( | ) |
double Cell::textWidth | ( | ) | const |
double Cell::textHeight | ( | ) | const |
bool Cell::updateChart | ( | bool | refresh = true |
) |
Refreshing chart.
- Parameters:
-
refresh is default true when it's false it's just for test it's used when you paste cell
Definition at line 5004 of file kspread_cell.cc.
bool Cell::calc | ( | bool | delay = true |
) |
Starts calculating.
- Parameters:
-
delay true if you want to check for delay condition in doc() false if you really have to calculate the value right now e.g. if you sort with formula as key
- Returns:
- true on success and false on error.
Definition at line 2077 of file kspread_cell.cc.
void Cell::setCalcDirtyFlag | ( | ) |
bool Cell::calcDirtyFlag | ( | ) |
Notify this cell that another cell is depending, or no longer depending on this cell's value.
- Parameters:
-
col the column of the cell row the row of the cell sheet the sheet that the cell is on isDepending true if the cell is now depending on this one, false if it is not any longer depending on it.
void Cell::setLayoutDirtyFlag | ( | bool | format = false |
) |
Causes the format to be recalculated when the cell is drawn next time.
This flag is for example set if the width of the column changes or if some cell specific format value like font or text change.
Definition at line 762 of file kspread_cell.cc.
void Cell::obscure | ( | Cell * | cell, | |
bool | isForcing = false | |||
) |
Tells this cell that the Cell 'cell' obscures this one.
If this cell has to be redrawn, then the obscuring cell is redrawn instead.
- Parameters:
-
cell the obscuring cell isForcing whether this is a forced obscuring (merged cells) or just a temporary obscure (text overlap).
Definition at line 925 of file kspread_cell.cc.
void Cell::unobscure | ( | Cell * | cell | ) |
Tells this cell that it is no longer obscured.
- Parameters:
-
cell the cell that is no longer obscuring this one.
Definition at line 944 of file kspread_cell.cc.
bool Cell::isObscured | ( | ) | const |
bool Cell::isPartOfMerged | ( | ) | const |
If this cell is part of a merged cell, then the marker may never reside on this cell.
- Returns:
- true if another cell has this one merged into itself.
Definition at line 842 of file kspread_cell.cc.
Cell * Cell::ultimateObscuringCell | ( | ) | const |
Return the cell that is obscuring this one (merged cells only).
If no obscuring, return the cell itself.
- Returns:
- the cell that decides the format for the cell in question.
Definition at line 875 of file kspread_cell.cc.
QValueList< Cell * > Cell::obscuringCells | ( | ) | const |
Merge a number of cells, i.e.
force the cell to occupy other cells space. If '_x' and '_y' are 0 then the merging is disabled.
- Parameters:
-
_col is the column this cell is assumed to be in. _row is the row this cell is assumed to be in. _x tells to occupy _x additional cells in the horizontal _y tells to occupy _y additional cells in the vertical
Definition at line 676 of file kspread_cell.cc.
bool Cell::doesMergeCells | ( | ) | const |
- Returns:
- true if the cell is forced to obscure other cells.
Definition at line 7282 of file kspread_cell.cc.
int Cell::mergedXCells | ( | ) | const |
- Returns:
- the number of obscured cells in the horizontal direction as a result of cell merging (forced obscuring)
Definition at line 4944 of file kspread_cell.cc.
int Cell::mergedYCells | ( | ) | const |
- Returns:
- the number of obscured cells in the vertical direction as a result of cell merging (forced obscuring)
Definition at line 4949 of file kspread_cell.cc.
int Cell::extraXCells | ( | ) | const |
- Returns:
- the amount of obscured cells in the horizontal direction
Definition at line 4954 of file kspread_cell.cc.
int Cell::extraYCells | ( | ) | const |
- Returns:
- the amount of obscured cells in the vertical direction
Definition at line 4959 of file kspread_cell.cc.
encode a formula into a text representation
- Parameters:
-
_era encode relative references absolutely (this is used for copying a cell to make the paste operation create a formula that points to the original cells, not the cells at the same relative position) _col row the formula is in _row column the formula is in
Definition at line 952 of file kspread_cell.cc.
QString Cell::pasteOperation | ( | const QString & | new_text, | |
const QString & | old_text, | |||
Paste::Operation | op | |||
) |
Merges the new_text
with old_text
during a paste operation.
If both texts represent doubles, then the operation is performed on both values and the result is returned. If both texts represents a formula or one a formula and the other a double value, then a formula is returned. In all other cases new_text
is returned.
- Returns:
- the merged text.
Definition at line 6942 of file kspread_cell.cc.
bool Cell::hasError | ( | ) | const |
- Returns:
- true if the cell contains a formula that could not be evaluated.
These cells usually appear with "####" on the screen.
Definition at line 7248 of file kspread_cell.cc.
void Cell::clearAllErrors | ( | ) |
Calculates the layout of the cell, i,e, determines what should be shown for this cell, m_strOutText.
Definition at line 1221 of file kspread_cell.cc.
bool Cell::makeFormula | ( | ) |
Parses the formula.
Fills dependList and formula.
- Returns:
- false on error.
Definition at line 2041 of file kspread_cell.cc.
QValueList< Conditional > Cell::conditionList | ( | ) | const |
void Cell::setConditionList | ( | const QValueList< Conditional > & | newList | ) |
bool Cell::testValidity | ( | ) | const |
return true if value is good else show a messagebox
Definition at line 4726 of file kspread_cell.cc.
Calculates the text parameters stored in cell Applies font to use to painter
.
Definition at line 2023 of file kspread_cell.cc.
int Cell::defineAlignX | ( | ) |
bool Cell::operator> | ( | const Cell & | ) | const |
void Cell::textSize | ( | QPainter & | _paint | ) | [protected] |
Called from makeFormat() to determine the space needed for the text.
Definition at line 1871 of file kspread_cell.cc.
QString Cell::textDisplaying | ( | QPainter & | painter | ) | [protected] |
Called from paintCell to determine the text wich can be displaying.
Definition at line 4063 of file kspread_cell.cc.
void Cell::clearFormula | ( | ) | [protected] |
Cleans up formula stuff.
Call this before you store a new formula or to delete the formula.
Definition at line 2071 of file kspread_cell.cc.
void Cell::checkTextInput | ( | ) | [protected] |
Check the input from the user, and determine the contents of the cell accordingly (in particular the data type).
This is to be called only when m_content == Text.
Input: m_strText Output: m_dataType
Definition at line 5110 of file kspread_cell.cc.
void Cell::checkNumberFormat | ( | ) | [protected] |
Automatically chooses between a number format and a scientific format (if the number is too big).
Definition at line 5137 of file kspread_cell.cc.
void Cell::loadOasisCellText | ( | const QDomElement & | parent | ) | [protected] |
Load the text paragraphs from an OASIS XML cell description.
- Parameters:
-
parent The DOM element representing the cell.
Definition at line 5961 of file kspread_cell.cc.
The documentation for this class was generated from the following files: