Home · All Namespaces · All Classes · Grouped Classes · Modules · Functions codeless banner

ThemeLevelItem Class Reference
[QtBaseModule]

The ThemeLevelItem class represents a level indicator in a ThemedView. More...

    #include <ThemeLevelItem>

Inherits ThemeAnimationItem.

Public Functions

Additional Inherited Members


Detailed Description

The ThemeLevelItem class represents a level indicator in a ThemedView.

The ThemeLevelItem class implements the level element from the theme XML.

Examples of level indicators are the battery level or signal quality indicators in Qtopia. A ThemeLevelItem has a range given by minValue() and maxValue(). It displays an indicator showing a current value within that range. The range can be manually set using setRange(), and the current value using setValue().

Normally you do not want to call this item's functions directly, but rather specify the relevant attributes and data for this item in the themed view XML.

See also level element.


Member Function Documentation

ThemeLevelItem::ThemeLevelItem ( ThemeItem * parent, ThemedView * view, const ThemeAttributes & atts )

Constructs a ThemeLevelItem. parent, view and atts are passed to the base class constructor.

ThemeLevelItem::~ThemeLevelItem ()

Destroys the ThemeLevelItem

int ThemeLevelItem::maxValue () const

Returns the maximum value of the level, as set through the max attribute in the theme XML or setRange().

int ThemeLevelItem::minValue () const

Returns the minimum value of the level, as set through the min attribute in the theme XML or setRange().

void ThemeLevelItem::setRange ( int min, int max )

Sets the minimum and maximum value of the level to be min and max respectively.

void ThemeLevelItem::setValue ( int value )

Sets the current level of the level item to value.

See also value().

int ThemeLevelItem::value () const

Returns the current value of the level.

See also setValue().


Copyright © 2009 Trolltech Trademarks
Qt Extended 4.4.3