KExtHighscore::Item Class Reference
This class defines how to convert and how to display a highscore element (such as the score, the date, . More...
#include <kexthighscore_item.h>
Inheritance diagram for KExtHighscore::Item:

Public Types | |
enum | Format { NoFormat, OneDecimal, Percentage, MinuteTime, DateTime } |
enum | Special { NoSpecial, ZeroNotDefined, NegativeNotDefined, DefaultNotDefined, Anonymous } |
Public Member Functions | |
Item (const QVariant &def=QVariant::Invalid, const QString &label=QString::null, int alignment=Qt::AlignRight) | |
virtual | ~Item () |
void | setPrettyFormat (Format format) |
void | setPrettySpecial (Special special) |
bool | isVisible () const |
void | setLabel (const QString &label) |
QString | label () const |
int | alignment () const |
void | setDefaultValue (const QVariant &value) |
const QVariant & | defaultValue () const |
virtual QVariant | read (uint i, const QVariant &value) const |
virtual QString | pretty (uint i, const QVariant &value) const |
Detailed Description
This class defines how to convert and how to display a highscore element (such as the score, the date, ...) or a player info (such as the player name, the best score, ...).
Definition at line 40 of file kexthighscore_item.h.
Member Enumeration Documentation
|
Possible display format.
Definition at line 55 of file kexthighscore_item.h. |
|
Possible special value for display format.
Definition at line 72 of file kexthighscore_item.h. |
Constructor & Destructor Documentation
|
Constructor.
Definition at line 38 of file kexthighscore_item.cpp. |
Member Function Documentation
|
Set the display format.
Definition at line 51 of file kexthighscore_item.cpp. Referenced by KExtHighscore::Manager::createItem(), KExtHighscore::DateItem::DateItem(), KExtHighscore::Manager::setScoreType(), and KExtHighscore::SuccessPercentageItem::SuccessPercentageItem(). |
|
Set the special value for display.
Definition at line 75 of file kexthighscore_item.cpp. Referenced by KExtHighscore::Manager::createItem(), KExtHighscore::NameItem::NameItem(), and KExtHighscore::SuccessPercentageItem::SuccessPercentageItem(). |
|
Definition at line 104 of file kexthighscore_item.h. Referenced by KExtHighscore::ItemArray::exportToText(). |
|
Set the label.
Definition at line 109 of file kexthighscore_item.h. |
|
Definition at line 114 of file kexthighscore_item.h. Referenced by KExtHighscore::ItemArray::exportToText(). |
|
Definition at line 119 of file kexthighscore_item.h. |
|
Set default value.
Definition at line 124 of file kexthighscore_item.h. Referenced by KExtHighscore::Manager::setPlayerItem(), and KExtHighscore::Manager::setScoreItem(). |
|
Definition at line 129 of file kexthighscore_item.h. Referenced by KExtHighscore::ItemContainer::read(), and KExtHighscore::Manager::setPlayerItem(). |
|
Reimplemented in KExtHighscore::RankItem. Definition at line 46 of file kexthighscore_item.cpp. Referenced by KExtHighscore::ItemContainer::read(). |
|
Reimplemented in KExtHighscore::RankItem. Definition at line 108 of file kexthighscore_item.cpp. References KExtHighscore::ItemContainer::ANONYMOUS, and KExtHighscore::ItemContainer::ANONYMOUS_LABEL. Referenced by KExtHighscore::HistogramTab::HistogramTab(), and KExtHighscore::ItemContainer::pretty(). |
The documentation for this class was generated from the following files: