LunaSysMgr
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
LabeledButton Class Referenceabstract

#include <labeledbutton.h>

Inheritance diagram for LabeledButton:
[legend]
Collaboration diagram for LabeledButton:
[legend]

Public Member Functions

 LabeledButton (const QRectF &buttonGeometry)
 
virtual ~LabeledButton ()
 
virtual bool resize (const QSize &newSize)
 
virtual bool resize (quint32 newWidth, quint32 newHeight)
 
virtual void paint (QPainter *painter, const QStyleOptionGraphicsItem *option=0, QWidget *widget=0)=0
 
virtual void paintOffscreen (QPainter *painter)=0
 
virtual void setLabel (const QString &v)
 
- Public Member Functions inherited from ThingPaintable
 ThingPaintable (const QRectF &geom)
 
virtual ~ThingPaintable ()
 
virtual QString readUiState () const
 
virtual void writeUiState (const QString &s)
 
virtual void resetUiState ()
 
virtual QRectF geometry () const
 
virtual QRectF positionRelativeGeometry () const
 
virtual QRectF untranslateFromPosition (const QRectF &rect) const
 
virtual QRectF boundingRect () const
 
virtual void paint (QPainter *painter, const QRectF &sourceRect)
 
virtual void paint (QPainter *painter, const QRectF &sourceRect, qint32 renderOpt)
 
virtual void paint (QPainter *painter, const QRectF &sourceRect, const QPointF &painterTranslate)
 
virtual void paint (QPainter *painter, const QRectF &sourceRect, const QPointF &painterTranslate, qint32 renderOpt)
 
virtual void paintOffscreen (QPainter *painter, const QRect &sourceRect, const QPoint &targetOrigin)
 
virtual void paintOffscreen (QPainter *painter, const QRect &sourceRect, const QRect &targetRect)
 
- Public Member Functions inherited from Thing
 Thing ()
 
virtual ~Thing ()
 
virtual QUuid uid () const
 
virtual bool offer (Thing *p_offer, Thing *p_offeringThing)
 
virtual bool take (Thing *p_takerThing)
 
virtual bool taking (Thing *p_victimThing, Thing *p_takerThing)
 
virtual void taken (Thing *p_takenThing, Thing *p_takerThing)
 
virtual uint hashValue () const
 
virtual void touchTrackedPointStarted (int id, const QPointF &scenePosition, const QPointF &lastScenePosition, const QPointF &initialPosition)
 
virtual void touchTrackedPointMoved (int id, const QPointF &scenePosition, const QPointF &lastScenePosition, const QPointF &initialPosition)
 
virtual void touchTrackedPointReleased (int id, const QPointF &scenePosition, const QPointF &lastScenePosition, const QPointF &initialPosition)
 
virtual void redirectTouchPrepare (Thing *p_sourceThing, const TouchRegister &touchRegister, int contextHint=0)
 
virtual void redirectedTouchTrackedPointMoved (Thing *p_sourceThing, int id, const QPointF &scenePosition, const QPointF &lastScenePosition, const QPointF &initialPosition, const RedirectContext &redirContext)
 
virtual void redirectedTouchTrackedPointReleased (Thing *p_sourceThing, int id, const QPointF &scenePosition, const QPointF &lastScenePosition, const QPointF &initialPosition, const RedirectContext &redirContext)
 

Protected Member Functions

virtual void recalculateLabelBoundsForCurrentGeom ()
 
virtual void redoLabelTextLayout ()
 
virtual void recalculateLabelPosition ()
 
- Protected Member Functions inherited from ThingPaintable
 ThingPaintable (const QUuid &specificUid, const QRectF &geom)
 
virtual void recomputeBoundingRect ()
 
virtual void recomputeBoundingRect (const QRectF &virtualGeom)
 
- Protected Member Functions inherited from Thing
 Thing (const QUuid &specificUid)
 

Static Protected Member Functions

static QFont staticLabelFontForButtons ()
 

Protected Attributes

QString m_label
 
QFont m_textFont
 
QColor m_selectedColor
 
QColor m_unselectedColor
 
QTextLayout m_textLayoutObject
 
QPointF m_labelPosICS
 
QPoint m_labelPosPntCS
 
QRect m_labelMaxGeom
 
QRect m_labelGeom
 
- Protected Attributes inherited from ThingPaintable
QRectF m_geom
 
QRectF m_boundingRect
 
QString m_uiState
 
- Protected Attributes inherited from Thing
QPointer< Thingm_qp_takerOwner
 

Additional Inherited Members

- Public Slots inherited from Thing
virtual void slotEnableIconAutoRepaint ()
 
virtual void slotDisableIconAutoRepaint ()
 
- Signals inherited from ThingPaintable
void signalGeometryChanged (const QRectF &, const QRectF &)
 
void signalGeometryChanged ()
 
void signalUiStateChanged ()
 
void signalPositionChanged ()
 
- Static Public Member Functions inherited from ThingPaintable
static bool isItemThingPaintable (QGraphicsItem *p_qgitem)
 
static ThingPaintablethingpaintable_cast (QGraphicsItem *p_qgitem)
 
- Static Public Attributes inherited from ThingPaintable
static int MagicTypePropertyKey = 1111
 
static int MagicTypePropertyValue = 2222
 
- Properties inherited from ThingPaintable
QString uistate
 
QPointF animatePosition
 

Constructor & Destructor Documentation

LabeledButton::LabeledButton ( const QRectF &  buttonGeometry)
LabeledButton::~LabeledButton ( )
virtual

Member Function Documentation

virtual void LabeledButton::paint ( QPainter *  painter,
const QStyleOptionGraphicsItem *  option = 0,
QWidget *  widget = 0 
)
pure virtual

Implements ThingPaintable.

Implemented in ColorRoundRectButton.

virtual void LabeledButton::paintOffscreen ( QPainter *  painter)
pure virtual

Implements ThingPaintable.

Implemented in ColorRoundRectButton.

void LabeledButton::recalculateLabelBoundsForCurrentGeom ( )
protectedvirtual
void LabeledButton::recalculateLabelPosition ( )
protectedvirtual
void LabeledButton::redoLabelTextLayout ( )
protectedvirtual
bool LabeledButton::resize ( const QSize &  newSize)
virtual

Reimplemented from ThingPaintable.

bool LabeledButton::resize ( quint32  newWidth,
quint32  newHeight 
)
virtual

Reimplemented from ThingPaintable.

void LabeledButton::setLabel ( const QString &  v)
virtual
QFont LabeledButton::staticLabelFontForButtons ( )
staticprotected

Member Data Documentation

QString LabeledButton::m_label
protected
QRect LabeledButton::m_labelGeom
protected
QRect LabeledButton::m_labelMaxGeom
protected
QPointF LabeledButton::m_labelPosICS
protected
QPoint LabeledButton::m_labelPosPntCS
protected
QColor LabeledButton::m_selectedColor
protected
QFont LabeledButton::m_textFont
protected
QTextLayout LabeledButton::m_textLayoutObject
protected
QColor LabeledButton::m_unselectedColor
protected

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