LunaSysMgr
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
ColorRoundRectButton Class Reference

#include <colorroundrectbutton.h>

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

Signals

void signalFirstContact ()
 
void signalContact ()
 
void signalRelease ()
 
void signalLastRelease ()
 
void signalActivated ()
 
void signalStateActiveChanged ()
 
void signalFSMActivate ()
 
void signalFSMDeactivate ()
 

Public Member Functions

 ColorRoundRectButton (const QSize &encompassingRectSize, const QString &label, QColor normalColor)
 
 ColorRoundRectButton (const QSize &encompassingRectSize, const QString &label, QColor normalColor, QColor activeColor)
 
virtual ~ColorRoundRectButton ()
 
virtual void commonCtor (QSize requestedSize)
 
virtual void paint (QPainter *painter, const QStyleOptionGraphicsItem *option=0, QWidget *widget=0)
 
virtual void paintOffscreen (QPainter *painter)
 
virtual bool valid ()
 
virtual bool stateActive () const
 
virtual void setStateActive (bool v)
 
- Public Member Functions inherited from LabeledButton
 LabeledButton (const QRectF &buttonGeometry)
 
virtual ~LabeledButton ()
 
virtual bool resize (const QSize &newSize)
 
virtual bool resize (quint32 newWidth, quint32 newHeight)
 
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 bool touchStartEvent (QTouchEvent *event)
 
virtual bool touchUpdateEvent (QTouchEvent *event)
 
virtual bool touchEndEvent (QTouchEvent *event)
 
virtual bool sceneEvent (QEvent *event)
 
virtual bool tapAndHoldGesture (QTapAndHoldGesture *tapHoldEvent)
 
virtual bool tapGesture (QTapGesture *tapEvent)
 
virtual void mousePressEvent (QGraphicsSceneMouseEvent *event)
 
virtual void mouseMoveEvent (QGraphicsSceneMouseEvent *event)
 
virtual void mouseReleaseEvent (QGraphicsSceneMouseEvent *event)
 
virtual void setupFSM ()
 
- Protected Member Functions inherited from LabeledButton
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)
 

Protected Attributes

QColor m_normalColor
 
QColor m_activeColor
 
QColor m_currentColor
 
int m_xRndFactor
 
int m_yRndFactor
 
bool m_stateActive
 
QStateMachinem_p_buttonFSM
 
qint32 m_touchCount
 
QStatem_p_stateNormal
 
QStatem_p_stateActive
 
bool m_valid
 
- Protected Attributes inherited from LabeledButton
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
 

Properties

bool stateActive
 

Additional Inherited Members

- Public Slots inherited from Thing
virtual void slotEnableIconAutoRepaint ()
 
virtual void slotDisableIconAutoRepaint ()
 
- 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
 
- Static Protected Member Functions inherited from LabeledButton
static QFont staticLabelFontForButtons ()
 

Constructor & Destructor Documentation

ColorRoundRectButton::ColorRoundRectButton ( const QSize &  encompassingRectSize,
const QString &  label,
QColor  normalColor 
)
ColorRoundRectButton::ColorRoundRectButton ( const QSize &  encompassingRectSize,
const QString &  label,
QColor  normalColor,
QColor  activeColor 
)
ColorRoundRectButton::~ColorRoundRectButton ( )
virtual

Member Function Documentation

void ColorRoundRectButton::commonCtor ( QSize  requestedSize)
virtual
void ColorRoundRectButton::mouseMoveEvent ( QGraphicsSceneMouseEvent *  event)
protectedvirtual
void ColorRoundRectButton::mousePressEvent ( QGraphicsSceneMouseEvent *  event)
protectedvirtual
void ColorRoundRectButton::mouseReleaseEvent ( QGraphicsSceneMouseEvent *  event)
protectedvirtual
void ColorRoundRectButton::paint ( QPainter *  painter,
const QStyleOptionGraphicsItem *  option = 0,
QWidget *  widget = 0 
)
virtual

Implements LabeledButton.

void ColorRoundRectButton::paintOffscreen ( QPainter *  painter)
virtual

Implements LabeledButton.

bool ColorRoundRectButton::sceneEvent ( QEvent event)
protectedvirtual
void ColorRoundRectButton::setStateActive ( bool  v)
virtual
void ColorRoundRectButton::setupFSM ( )
protectedvirtual

<-— this one alerts the clients to the action!!

void ColorRoundRectButton::signalActivated ( )
signal
void ColorRoundRectButton::signalContact ( )
signal
void ColorRoundRectButton::signalFirstContact ( )
signal
void ColorRoundRectButton::signalFSMActivate ( )
signal
void ColorRoundRectButton::signalFSMDeactivate ( )
signal
void ColorRoundRectButton::signalLastRelease ( )
signal
void ColorRoundRectButton::signalRelease ( )
signal
void ColorRoundRectButton::signalStateActiveChanged ( )
signal
virtual bool ColorRoundRectButton::stateActive ( ) const
virtual
bool ColorRoundRectButton::tapAndHoldGesture ( QTapAndHoldGesture *  tapHoldEvent)
protectedvirtual
bool ColorRoundRectButton::tapGesture ( QTapGesture *  tapEvent)
protectedvirtual
bool ColorRoundRectButton::touchEndEvent ( QTouchEvent *  event)
protectedvirtual
bool ColorRoundRectButton::touchStartEvent ( QTouchEvent *  event)
protectedvirtual
bool ColorRoundRectButton::touchUpdateEvent ( QTouchEvent *  event)
protectedvirtual
bool ColorRoundRectButton::valid ( )
virtual

Member Data Documentation

QColor ColorRoundRectButton::m_activeColor
protected
QColor ColorRoundRectButton::m_currentColor
protected
QColor ColorRoundRectButton::m_normalColor
protected
QStateMachine* ColorRoundRectButton::m_p_buttonFSM
protected
QState* ColorRoundRectButton::m_p_stateActive
protected
QState* ColorRoundRectButton::m_p_stateNormal
protected
bool ColorRoundRectButton::m_stateActive
protected
qint32 ColorRoundRectButton::m_touchCount
protected
bool ColorRoundRectButton::m_valid
protected
int ColorRoundRectButton::m_xRndFactor
protected
int ColorRoundRectButton::m_yRndFactor
protected

Property Documentation

bool ColorRoundRectButton::stateActive
readwrite

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