ICS

QicsTable Documentation Set

QicsDataBool Class Reference

An boolean data item. More...

#include <QicsDataItem.h>

Inherits QicsDataItem.

List of all members.

Public Types

enum  QicsSortMode { QicsStableSort = 0, QicsQuickSort }
enum  QicsCellOverflowBehavior { Clip = 0, Overflow, ToolTip }
enum  QicsCurrentCellStyle { Spreadsheet = 0, NormalSelected }
enum  QicsGridCellClipping { AllowPartial = 0, NoDisplayOnPartial, UseClippedSymbol }
enum  QicsGridType { TableGrid = 0, RowHeaderGrid, ColumnHeaderGrid }
enum  QicsHeaderType { RowHeader = 0, ColumnHeader }
enum  QicsIndexType { RowIndex, ColumnIndex }
enum  QicsLineStyle { None = 0, Plain, Raised, Sunken }
enum  QicsRepaintBehavior { RepaintOff = 0, RepaintOn = 1, RepaintCalcOnly = 2 }
enum  QicsScrollBarMode { Auto = 0, AlwaysOff, AlwaysOn }
enum  QicsScrollDirection {
  ScrollNone = 0, ScrollUp, ScrollDown, ScrollLeft,
  ScrollRight, ScrollToRow, ScrollToColumn
}
enum  QicsSelectionPolicy {
  SelectNone = 0, SelectSingle, SelectMultiple, SelectSingleRow,
  SelectMultipleRow
}
enum  QicsSelectionType {
  SelectionNone = 0, SelectionBegin, SelectionDrag, SelectionEnd,
  SelectionExtend, SelectionAdd
}
enum  QicsSortOrder { Ascending = 0, Descending }
enum  QicsTableDisplayOption { DisplayNever = 0, DisplayAlways, DisplayFirstPage }
enum  QicsTraversalKeyEditBehavior { TraverseWithinCell = 0, TraverseBetweenCells }

Public Member Functions

 QicsDataBool ()
 QicsDataBool (bool v, QString ts=QICS_DEFAULT_TRUE_STRING, QString fs=QICS_DEFAULT_FALSE_STRING)
 QicsDataBool (const QicsDataBool &db)
QicsDataItemcreate (void) const
QicsDataItemclone (void) const
virtual QicsDataItemType type (void) const
virtual QString typeString (void) const
virtual QicsDataBooloperator= (const bool &b)
virtual const QString string (void) const
virtual bool setString (const QString &qs)
bool data (void) const
void setData (bool b)
virtual QString format (const char *fmt_string) const
int compareTo (const QicsDataItem &x) const
void encode (QDataStream &ds) const
QString trueString () const
QString falseString () const
bool setTrueString (const QString &qs)
bool setFalseString (const QString &qs)

Static Public Member Functions

static QString typeName (void)
static QicsDataItemfromString (const QString &str)
static QicsDataItemdecode (QDataStream &ds)
static void registerType (const QString type_name, QicsDataItemParser parser, QicsDataItemDecoder decoder)
static void registerTypeI (const QString type_name, QicsDataItemParser parser, QicsDataItemDecoderWithType decoder)
static void registerParser (QicsDataItemParser parser)

Protected Attributes

bool myData
QString myTrueString
QString myFalseString


Detailed Description

An boolean data item.

Represents an boolean value.


Member Enumeration Documentation

enum Qics::QicsSortMode [inherited]

Denotes the sort algorithm wich used

Enumerator:
QicsStableSort 
QicsQuickSort 

enum Qics::QicsCellOverflowBehavior [inherited]

Denotes the behavior of grids when handling cells whose contents cannot be displayed in the boundaries of the cell.

Enumerator:
Clip 
Overflow 
ToolTip 

enum Qics::QicsCurrentCellStyle [inherited]

Denotes the visual style that the current cell of the table will be drawn with.

Enumerator:
Spreadsheet 
NormalSelected 

enum Qics::QicsGridCellClipping [inherited]

Denotes the policy for displaying text that is too long to fit in its cell

Enumerator:
AllowPartial 
NoDisplayOnPartial 
UseClippedSymbol 

enum Qics::QicsGridType [inherited]

Specifies a type of grid object.

Enumerator:
TableGrid 
RowHeaderGrid 
ColumnHeaderGrid 

enum Qics::QicsHeaderType [inherited]

Specifies the type of table header.

Enumerator:
RowHeader 
ColumnHeader 

enum Qics::QicsIndexType [inherited]

Specifies the type of table index.

Enumerator:
RowIndex 
ColumnIndex 

enum Qics::QicsLineStyle [inherited]

Denotes the style of lines and borders in the table widget.

Enumerator:
None 
Plain 
Raised 
Sunken 

enum Qics::QicsRepaintBehavior [inherited]

Specifies the recalculation and repainting behavior of tables and grids.

Enumerator:
RepaintOff 
RepaintOn 
RepaintCalcOnly 

enum Qics::QicsScrollBarMode [inherited]

Specifies the various modes of QicsTable's scroll bars.

Enumerator:
Auto 
AlwaysOff 
AlwaysOn 

enum Qics::QicsScrollDirection [inherited]

Denotes a direction for scrolling operations, or that an absolute scroll should occur.

Enumerator:
ScrollNone 
ScrollUp 
ScrollDown 
ScrollLeft 
ScrollRight 
ScrollToRow 
ScrollToColumn 

enum Qics::QicsSelectionPolicy [inherited]

Denotes the selection policy for the table.

Enumerator:
SelectNone 
SelectSingle 
SelectMultiple 
SelectSingleRow 
SelectMultipleRow 

enum Qics::QicsSelectionType [inherited]

Enumerator:
SelectionNone 
SelectionBegin 
SelectionDrag 
SelectionEnd 
SelectionExtend 
SelectionAdd 

enum Qics::QicsSortOrder [inherited]

Specifies if ordering should be ascending or descending.

Enumerator:
Ascending 
Descending 

enum Qics::QicsTableDisplayOption [inherited]

Specifies a printing display policy for elements of the table

Enumerator:
DisplayNever 
DisplayAlways 
DisplayFirstPage 

enum Qics::QicsTraversalKeyEditBehavior [inherited]

Specifies the behavior of the traversal keys (left, right, up, down, etc) while editing a cell.

Enumerator:
TraverseWithinCell 
TraverseBetweenCells 


Constructor & Destructor Documentation

QicsDataBool::QicsDataBool (  )  [inline]

Constructs a new data item. The initial value of this item is false.

QicsDataBool::QicsDataBool ( bool  v,
QString  ts = QICS_DEFAULT_TRUE_STRING,
QString  fs = QICS_DEFAULT_FALSE_STRING 
) [inline]

Constructs a new data item with value v.

QicsDataBool::QicsDataBool ( const QicsDataBool db  ) 

Copy Constructor


Member Function Documentation

QicsDataItem* QicsDataBool::create ( void   )  const [inline, virtual]

A "virtual constructor". Returns an empty, newly allocated object of the same type as this object.

Implements QicsDataItem.

QicsDataItem* QicsDataBool::clone ( void   )  const [inline, virtual]

A "virtual copy constructor". Returns a newly allocated copy of this object.

Implements QicsDataItem.

virtual QicsDataItemType QicsDataBool::type ( void   )  const [inline, virtual]

Returns the data type of the item, QicsDataItem_Bool

Implements QicsDataItem.

static QString QicsDataBool::typeName ( void   )  [inline, static]

Returns "bool".

virtual QString QicsDataBool::typeString ( void   )  const [inline, virtual]

Returns QicsDataBool::typeName()

Implements QicsDataItem.

virtual QicsDataBool& QicsDataBool::operator= ( const bool &  b  )  [inline, virtual]

Assigns the value b to this data item. Returns a reference to the data item.

virtual const QString QicsDataBool::string ( void   )  const [inline, virtual]

Converts (if necessary) the contents of the data item to a QString and returns that string.

Implements QicsDataItem.

virtual bool QicsDataBool::setString ( const QString &  qs  )  [inline, virtual]

Converts (if necessary) qs to the appropriate data type and sets the contents of the data item to that value.

Implements QicsDataItem.

bool QicsDataBool::data ( void   )  const [inline]

Returns a copy of the value of this data item.

void QicsDataBool::setData ( bool  b  )  [inline]

Sets the value of this data item to i.

virtual QString QicsDataBool::format ( const char *  fmt_string  )  const [inline, virtual]

Converts (if necessary) the contents of the data item to a formatted QString using the supplied formatting string, and returns the formatted string. The exact definition of the formatting string varies among data types.

Reimplemented from QicsDataItem.

int QicsDataBool::compareTo ( const QicsDataItem x  )  const [virtual]

Compare another data item x to me for the purpose of sorting. compareTo returns a value < 0 if this items is less than x, 0 if this item == x, and > 0 if this item is greater than x.

Reimplemented from QicsDataItem.

void QicsDataBool::encode ( QDataStream &  ds  )  const [inline, virtual]

Encodes the value of the data item onto stream ds.

Implements QicsDataItem.

static QicsDataItem* QicsDataBool::fromString ( const QString &  str  )  [static]

Returns a new integer data item if str can be interpreted as an integer, or 0 if it cannot be.

Reimplemented from QicsDataItem.

static QicsDataItem* QicsDataBool::decode ( QDataStream &  ds  )  [inline, static]

Returns a new integer data item based on the data encoded in ds.

Reimplemented from QicsDataItem.

QString QicsDataBool::trueString (  )  const [inline]

Returns a string equal true.

QString QicsDataBool::falseString (  )  const [inline]

Returns a string equal false.

bool QicsDataBool::setTrueString ( const QString &  qs  )  [inline]

Sets a string equal true to qs.

bool QicsDataBool::setFalseString ( const QString &  qs  )  [inline]

Sets a string equal false to qs.

static void QicsDataItem::registerType ( const QString  type_name,
QicsDataItemParser  parser,
QicsDataItemDecoder  decoder 
) [static, inherited]

Used to register a new, user-defined type so that the type can be used in streaming, drag and drop, and cut and paste operations. User-defined data item parsers will be called in the order that their types are registered.

Parameters:
type_name name of the new type
parser static member function of the new type that parses an item from a QString
decoder static member function of the new type that decodes an item from a QDataStream
See also:
registerParser

static void QicsDataItem::registerTypeI ( const QString  type_name,
QicsDataItemParser  parser,
QicsDataItemDecoderWithType  decoder 
) [static, inherited]

static void QicsDataItem::registerParser ( QicsDataItemParser  parser  )  [static, inherited]

Used to register a new data item parser algorithm. This parser can be used to reimplement the default parsing "algorithm" of QicsDataItem. If a user defined parser method cannot successfully parse a string, it should return 0. If the user defined parser cannot parse a string, the default QicsDataItem parsing algorithm will be used. The default algorithm first tries any individual user defined type parsers (see registerType()), then attempts to parse the built in types.

Parameters:
parser the new data item parser method
See also:
registerType


Member Data Documentation

bool QicsDataBool::myData [protected]

QString QicsDataBool::myTrueString [protected]

QString QicsDataBool::myFalseString [protected]


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

All trademarks and copyrights on this page are properties of their respective owners.
The rest is copyright 1999-2006 Integrated Computer Solutions, Inc.