kexi

KexiDBTimeEdit Class Reference

#include <kexidbtimeedit.h>

Inheritance diagram for KexiDBTimeEdit:

KexiFormDataItemInterface KexiDataItemInterface List of all members.

Detailed Description

A db-aware time editor.

Definition at line 31 of file kexidbtimeedit.h.


Public Slots

void setDataSource (const QString &ds)
void setDataSourceMimeType (const QCString &ds)
virtual void setReadOnly (bool set)

Public Member Functions

 KexiDBTimeEdit (const QTime &time, QWidget *parent, const char *name=0)
virtual ~KexiDBTimeEdit ()
QString dataSource () const
QCString dataSourceMimeType () const
virtual QVariant value ()
virtual void setInvalidState (const QString &displayText)
virtual bool valueIsNull ()
virtual bool valueIsEmpty ()
virtual bool isReadOnly () const
virtual QWidget * widget ()
virtual bool cursorAtStart ()
virtual bool cursorAtEnd ()
virtual void clear ()
virtual void setEnabled (bool enabled)

Protected Slots

void slotValueChanged (const QTime &)

Protected Member Functions

virtual void setValueInternal (const QVariant &add, bool removeOld)

Properties

QString dataSource
QCString dataSourceMimeType
bool readOnly

Member Function Documentation

void KexiDBTimeEdit::clear  )  [virtual]
 

clears item's data, so the data will contain NULL data

Implements KexiDataItemInterface.

Definition at line 142 of file kexidbtimeedit.cpp.

bool KexiDBTimeEdit::cursorAtEnd  )  [virtual]
 

Returns:
true if the item widget's cursor (whatever that means, eg. line edit cursor) is at the end of editor's contents. This can inform table/form view that after pressing "right arrow" key should stop editing and move to a field on the right hand.

Implements KexiDataItemInterface.

Definition at line 132 of file kexidbtimeedit.cpp.

bool KexiDBTimeEdit::cursorAtStart  )  [virtual]
 

Returns:
true if the item widget's cursor (whatever that means, eg. line edit cursor) is at the beginning of editor's contents. This can inform table/form view that after pressing "left arrow" key should stop editing and move to a field on the left hand.

Implements KexiDataItemInterface.

Definition at line 123 of file kexidbtimeedit.cpp.

QString KexiDBTimeEdit::dataSource  )  const [inline]
 

Returns:
the name of the data source for this widget. Data source usually means here a table or query, a field name or an expression.

Reimplemented from KexiFormDataItemInterface.

Definition at line 42 of file kexidbtimeedit.h.

QCString KexiDBTimeEdit::dataSourceMimeType  )  const [inline]
 

Returns:
the mime type of the data source for this widget. Data source mime type means here types like "kexi/table" or "kexi/query" in.the data source is set to object (as within form or subform) or is empty if the data source is set to table field or query column.

Reimplemented from KexiFormDataItemInterface.

Definition at line 43 of file kexidbtimeedit.h.

bool KexiDBTimeEdit::isReadOnly  )  const [virtual]
 

Returns:
'readOnly' flag for this widget.

Reimplemented from KexiDataItemInterface.

Definition at line 105 of file kexidbtimeedit.cpp.

void KexiDBTimeEdit::setDataSource const QString &  ds  )  [inline, slot]
 

Sets the name of the data source for this widget.

Data source usually means here a table or query or field name name.

Reimplemented from KexiFormDataItemInterface.

Definition at line 70 of file kexidbtimeedit.h.

void KexiDBTimeEdit::setDataSourceMimeType const QCString &  ds  )  [inline, slot]
 

Sets the mime type of the data source for this widget. Data source usually means here a "kexi/table" or "kexi/query".

See also:
dataSourceMimeType()

Reimplemented from KexiFormDataItemInterface.

Definition at line 71 of file kexidbtimeedit.h.

void KexiDBTimeEdit::setInvalidState const QString &  displayText  )  [virtual]
 

Todo:
move this to KexiDataItemInterface::setInvalidStateInternal() ?

Implements KexiFormDataItemInterface.

Definition at line 50 of file kexidbtimeedit.cpp.

void KexiDBTimeEdit::setValueInternal const QVariant &  add,
bool  removeOld
[protected, virtual]
 

Initializes this editor with add value, which should be somewhat added to the current value (already storted in m_origValue). If removeOld is true, a value should be set to add, otherwise -it should be set to current m_origValue + add, if possible. Implement this.

Implements KexiDataItemInterface.

Definition at line 69 of file kexidbtimeedit.cpp.

QVariant KexiDBTimeEdit::value  )  [virtual]
 

Returns:
value currently represented by this item.

Implements KexiDataItemInterface.

Definition at line 89 of file kexidbtimeedit.cpp.

bool KexiDBTimeEdit::valueIsEmpty  )  [virtual]
 

Returns:
true if editor's value is empty (not necessary null). Only few data types can accept "EMPTY" property (use KexiDB::Field::hasEmptyProperty() to check this). Used for checking if a given constraint within table or form is met.

Implements KexiDataItemInterface.

Definition at line 100 of file kexidbtimeedit.cpp.

bool KexiDBTimeEdit::valueIsNull  )  [virtual]
 

Returns:
true if editor's value is null (not empty) Used for checking if a given constraint within table of form is met.

Implements KexiDataItemInterface.

Definition at line 95 of file kexidbtimeedit.cpp.

QWidget * KexiDBTimeEdit::widget  )  [virtual]
 

Returns:
the view widget of this item, e.g. line edit widget.

Reimplemented from KexiFormDataItemInterface.

Definition at line 118 of file kexidbtimeedit.cpp.


The documentation for this class was generated from the following files:
KDE Home | KDE Accessibility Home | Description of Access Keys