TwiceAsNice  2019-02-18
Public Slots | Signals | Public Member Functions | Properties | Private Slots | Private Member Functions | Private Attributes | Friends | List of all members
Led2 Class Reference

#include <Led2.h>

Inheritance diagram for Led2:
Inheritance graph
Collaboration diagram for Led2:
Collaboration graph

Public Slots

void setTristate (bool _tristate)
 
void setTristate (bool _tristate)
 
void setTristate (bool _tristate)
 
- Public Slots inherited from LedWidget
void toggle ()
 Toggles the state of the led from Off to On or vice versa. More...
 
void on ()
 Sets the state of the widget to On. More...
 
void off ()
 Sets the state of the widget to Off. More...
 
void toggle ()
 Toggles the state of the led from Off to On or vice versa. More...
 
void on ()
 Sets the state of the widget to On. More...
 
void off ()
 Sets the state of the widget to Off. More...
 
void toggle ()
 Toggles the state of the led from Off to On or vice versa. More...
 
void on ()
 Sets the state of the widget to On. More...
 
void off ()
 Sets the state of the widget to Off. More...
 

Signals

void valueChanged ()
 
void valueChanged ()
 
void valueChanged ()
 

Public Member Functions

 Led2 (QWidget *parent, bool _connect=false)
 
bool tristate ()
 
void mousePressEvent (QMouseEvent *event)
 
bool clickable ()
 
void setClickable (bool _clickable)
 
 Led2 (QWidget *parent, bool _connect=false)
 
bool tristate ()
 
void mousePressEvent (QMouseEvent *event)
 
bool clickable ()
 
void setClickable (bool _clickable)
 
 Led2 (QWidget *parent, bool _connect=false)
 
bool tristate ()
 
void mousePressEvent (QMouseEvent *event)
 
bool clickable ()
 
void setClickable (bool _clickable)
 
- Public Member Functions inherited from LedWidget
 LedWidget (QWidget *parent=0)
 Constructs a green, round LED widget which will initially be turned on. More...
 
 LedWidget (const QColor &color, QWidget *parent=0)
 Constructs a round LED widget with the supplied color which will initially be turned on. More...
 
 LedWidget (const QColor &color, LedWidget::State state, LedWidget::Look look, LedWidget::Shape shape, QWidget *parent=0)
 Constructor with the color, state and look. More...
 
 ~LedWidget ()
 Destroys the LED widget. More...
 
QColor color () const
 Returns the current color of the widget. More...
 
State state () const
 Returns the current state of the widget (on/off). More...
 
Look look () const
 Returns the current look of the widget. More...
 
Shape shape () const
 Returns the current shape of the widget. More...
 
int darkFactor () const
 Returns the factor to darken the LED. More...
 
void setColor (const QColor &color)
 Set the color of the widget. More...
 
void setState (State state)
 Sets the state of the widget to On or Off. More...
 
void setLook (Look look)
 Sets the look of the widget. More...
 
void setShape (Shape shape)
 Set the shape of the LED. More...
 
void setDarkFactor (int darkFactor)
 Sets the factor to darken the LED in LedWidget::Off state. More...
 
virtual QSize sizeHint () const
 
virtual QSize minimumSizeHint () const
 
 LedWidget (QWidget *parent=0)
 Constructs a green, round LED widget which will initially be turned on. More...
 
 LedWidget (const QColor &color, QWidget *parent=0)
 Constructs a round LED widget with the supplied color which will initially be turned on. More...
 
 LedWidget (const QColor &color, LedWidget::State state, LedWidget::Look look, LedWidget::Shape shape, QWidget *parent=0)
 Constructor with the color, state and look. More...
 
 ~LedWidget ()
 Destroys the LED widget. More...
 
QColor color () const
 Returns the current color of the widget. More...
 
State state () const
 Returns the current state of the widget (on/off). More...
 
Look look () const
 Returns the current look of the widget. More...
 
Shape shape () const
 Returns the current shape of the widget. More...
 
int darkFactor () const
 Returns the factor to darken the LED. More...
 
void setColor (const QColor &color)
 Set the color of the widget. More...
 
void setState (State state)
 Sets the state of the widget to On or Off. More...
 
void setLook (Look look)
 Sets the look of the widget. More...
 
void setShape (Shape shape)
 Set the shape of the LED. More...
 
void setDarkFactor (int darkFactor)
 Sets the factor to darken the LED in LedWidget::Off state. More...
 
virtual QSize sizeHint () const
 
virtual QSize minimumSizeHint () const
 
 LedWidget (QWidget *parent=0)
 Constructs a green, round LED widget which will initially be turned on. More...
 
 LedWidget (const QColor &color, QWidget *parent=0)
 Constructs a round LED widget with the supplied color which will initially be turned on. More...
 
 LedWidget (const QColor &color, LedWidget::State state, LedWidget::Look look, LedWidget::Shape shape, QWidget *parent=0)
 Constructor with the color, state and look. More...
 
 ~LedWidget ()
 Destroys the LED widget. More...
 
QColor color () const
 Returns the current color of the widget. More...
 
State state () const
 Returns the current state of the widget (on/off). More...
 
Look look () const
 Returns the current look of the widget. More...
 
Shape shape () const
 Returns the current shape of the widget. More...
 
int darkFactor () const
 Returns the factor to darken the LED. More...
 
void setColor (const QColor &color)
 Set the color of the widget. More...
 
void setState (State state)
 Sets the state of the widget to On or Off. More...
 
void setLook (Look look)
 Sets the look of the widget. More...
 
void setShape (Shape shape)
 Set the shape of the LED. More...
 
void setDarkFactor (int darkFactor)
 Sets the factor to darken the LED in LedWidget::Off state. More...
 
virtual QSize sizeHint () const
 
virtual QSize minimumSizeHint () const
 
- Public Member Functions inherited from Nice::BridgeItem
void detach (QWidget *_widget)
 
bool getSynchStatus () const
 Get the sync status. More...
 
const QString & getNodeName ()
 
virtual void setState (CompletionState _state)
 Set the state of the widget (either Nice::OK or Nice::Unsynched ). More...
 
virtual void updateGUI (const ::Nice::Any &)
 Update the widgets data field from the connected Property. More...
 
virtual void setLabels (std::vector< std::string > _vec)
 Set the Labels This function has to be implemented in the derived widget class. More...
 
void setLabel (const QString &_text="")
 Set the text label of this widget. More...
 
QString getLabel ()
 
template<typename E >
std::vector< E * > getBridgeItems ()
 Get all widgets which are connected to the same Property like this one. More...
 
virtual void setShowLabels (bool _show)
 Enables to Labels. More...
 
Nice::JointgetNode () const
 Get the connected Joint node. More...
 
Nice::PropertygetProperty () const
 Get the connected Property. More...
 
virtual void getSessionData (Nice::JointPtr &)
 Fills the passed Joint with the internal session data. More...
 
virtual void setSessionData (Nice::JointPtr)
 Set the internal session data from thge passed Joint. More...
 
virtual void connect (const ::Nice::PropertyPtr _p)
 Connects the widget to a Joint or Property. More...
 
void applyReadOnlyActor ()
 
virtual void connect (const ::Nice::JointPtr _j)
 Connects the widget to a Joint or Property. More...
 
void applyBridge ()
 
QString getPropertyNode () const
 Get the path to the connected Joint. More...
 
virtual bool isReadOnly ()
 Checks if an attribute RO (read only) is set to true. More...
 
virtual void setPropertyNode (QString _nodeName)
 Set the relative path to the displayed Property from the connected Joint. More...
 
void setSynchStatus (bool _on)
 Set the current sync state. More...
 
void setUserConfirmationStatus (bool _on)
 
virtual void setLock (const bool &_locked)
 
void disconnect ()
 Disconnects the widget from the connected Joint or Property. More...
 
void detach (QWidget *_widget)
 
bool getSynchStatus () const
 Get the sync status. More...
 
const QString & getNodeName ()
 
virtual void setState (CompletionState _state)
 Set the state of the widget (either Nice::OK or Nice::Unsynched ). More...
 
virtual void updateGUI (const ::Nice::Any &)
 Update the widgets data field from the connected Property. More...
 
virtual void setLabels (std::vector< std::string > _vec)
 Set the Labels This function has to be implemented in the derived widget class. More...
 
void setLabel (const QString &_text="")
 Set the text label of this widget. More...
 
QString getLabel ()
 
template<typename E >
std::vector< E * > getBridgeItems ()
 Get all widgets which are connected to the same Property like this one. More...
 
virtual void setShowLabels (bool _show)
 Enables to Labels. More...
 
Nice::JointgetNode () const
 Get the connected Joint node. More...
 
Nice::PropertygetProperty () const
 Get the connected Property. More...
 
virtual void getSessionData (Nice::JointPtr &)
 Fills the passed Joint with the internal session data. More...
 
virtual void setSessionData (Nice::JointPtr)
 Set the internal session data from thge passed Joint. More...
 
virtual void connect (const ::Nice::PropertyPtr _p)
 Connects the widget to a Joint or Property. More...
 
void applyReadOnlyActor ()
 
virtual void connect (const ::Nice::JointPtr _j)
 Connects the widget to a Joint or Property. More...
 
void applyBridge ()
 
QString getPropertyNode () const
 Get the path to the connected Joint. More...
 
virtual bool isReadOnly ()
 Checks if an attribute RO (read only) is set to true. More...
 
virtual void setPropertyNode (QString _nodeName)
 Set the relative path to the displayed Property from the connected Joint. More...
 
void setSynchStatus (bool _on)
 Set the current sync state. More...
 
void setUserConfirmationStatus (bool _on)
 
virtual void setLock (const bool &_locked)
 
void disconnect ()
 Disconnects the widget from the connected Joint or Property. More...
 
void detach (QWidget *_widget)
 
bool getSynchStatus () const
 Get the sync status. More...
 
const QString & getNodeName ()
 
virtual void setState (CompletionState _state)
 Set the state of the widget (either Nice::OK or Nice::Unsynched ). More...
 
virtual void updateGUI (const ::Nice::Any &)
 Update the widgets data field from the connected Property. More...
 
virtual void setLabels (std::vector< std::string > _vec)
 Set the Labels This function has to be implemented in the derived widget class. More...
 
void setLabel (const QString &_text="")
 Set the text label of this widget. More...
 
QString getLabel ()
 
template<typename E >
std::vector< E * > getBridgeItems ()
 Get all widgets which are connected to the same Property like this one. More...
 
virtual void setShowLabels (bool _show)
 Enables to Labels. More...
 
Nice::JointgetNode () const
 Get the connected Joint node. More...
 
Nice::PropertygetProperty () const
 Get the connected Property. More...
 
virtual void getSessionData (Nice::JointPtr &)
 Fills the passed Joint with the internal session data. More...
 
virtual void setSessionData (Nice::JointPtr)
 Set the internal session data from thge passed Joint. More...
 
virtual void connect (const ::Nice::PropertyPtr _p)
 Connects the widget to a Joint or Property. More...
 
void applyReadOnlyActor ()
 
virtual void connect (const ::Nice::JointPtr _j)
 Connects the widget to a Joint or Property. More...
 
void applyBridge ()
 
QString getPropertyNode () const
 Get the path to the connected Joint. More...
 
virtual bool isReadOnly ()
 Checks if an attribute RO (read only) is set to true. More...
 
virtual void setPropertyNode (QString _nodeName)
 Set the relative path to the displayed Property from the connected Joint. More...
 
void setSynchStatus (bool _on)
 Set the current sync state. More...
 
void setUserConfirmationStatus (bool _on)
 
virtual void setLock (const bool &_locked)
 
void disconnect ()
 Disconnects the widget from the connected Joint or Property. More...
 

Properties

Shape shape
 
Look look
 
QColor color
 
int darkFactor
 
QString PropertyNode
 
bool AutoSynch
 
bool Tristate
 
bool Clickable
 
- Properties inherited from LedWidget
State state
 
Shape shape
 
Look look
 
QColor color
 
int darkFactor
 

Private Slots

void set ()
 
void set ()
 
void set ()
 

Private Member Functions

virtual void updateGUI (const Nice::Any &_val)
 
virtual void initSlots ()
 
virtual void updateGUI (const Nice::Any &_val)
 
virtual void initSlots ()
 
virtual void updateGUI (const Nice::Any &_val)
 
virtual void initSlots ()
 

Private Attributes

Qt::CheckState m_state
 
bool m_tristate
 
bool m_clickable
 

Friends

template<typename T , typename E >
class AbstractVectorBox
 
class LedBitSetVector
 
template<typename T , typename E >
class AbstractVectorBox
 
template<typename T , typename E >
class AbstractVectorBox
 

Additional Inherited Members

- Public Types inherited from LedWidget
enum  State {
  Off, On, Off, On,
  Off, On
}
 Status of the light is on/off. More...
 
enum  Shape {
  Rectangular, Circular, Rectangular, Circular,
  Rectangular, Circular
}
 Shades of the lamp. More...
 
enum  Look {
  Flat, Raised, Sunken, Flat,
  Raised, Sunken, Flat, Raised,
  Sunken
}
 Displays a flat, round or sunken LED. More...
 
enum  State {
  Off, On, Off, On,
  Off, On
}
 Status of the light is on/off. More...
 
enum  Shape {
  Rectangular, Circular, Rectangular, Circular,
  Rectangular, Circular
}
 Shades of the lamp. More...
 
enum  Look {
  Flat, Raised, Sunken, Flat,
  Raised, Sunken, Flat, Raised,
  Sunken
}
 Displays a flat, round or sunken LED. More...
 
enum  State {
  Off, On, Off, On,
  Off, On
}
 Status of the light is on/off. More...
 
enum  Shape {
  Rectangular, Circular, Rectangular, Circular,
  Rectangular, Circular
}
 Shades of the lamp. More...
 
enum  Look {
  Flat, Raised, Sunken, Flat,
  Raised, Sunken, Flat, Raised,
  Sunken
}
 Displays a flat, round or sunken LED. More...
 
- Public Attributes inherited from Nice::BridgeItem
QGroupBox * m_container
 
bool m_locked
 
- Static Public Attributes inherited from Nice::BridgeItem
static std::map< CompletionState, QString > * s_palette = 0
 
- Protected Member Functions inherited from LedWidget
virtual int ledWidth () const
 Returns the width of the led. More...
 
virtual void paintFlat ()
 Paints a circular, flat LED. More...
 
virtual void paintRaised ()
 Paints a circular, raised LED. More...
 
virtual void paintSunken ()
 Paints a circular, sunken LED. More...
 
virtual void paintRect ()
 Paints a rectangular, flat LED. More...
 
virtual void paintRectFrame (bool raised)
 Paints a rectangular LED, either raised or sunken, depending on its argument. More...
 
void paintEvent (QPaintEvent *)
 
bool paintCachedPixmap ()
 Paint the cached antialiased pixmap corresponding to the state if any. More...
 
virtual int ledWidth () const
 Returns the width of the led. More...
 
virtual void paintFlat ()
 Paints a circular, flat LED. More...
 
virtual void paintRaised ()
 Paints a circular, raised LED. More...
 
virtual void paintSunken ()
 Paints a circular, sunken LED. More...
 
virtual void paintRect ()
 Paints a rectangular, flat LED. More...
 
virtual void paintRectFrame (bool raised)
 Paints a rectangular LED, either raised or sunken, depending on its argument. More...
 
void paintEvent (QPaintEvent *)
 
bool paintCachedPixmap ()
 Paint the cached antialiased pixmap corresponding to the state if any. More...
 
virtual int ledWidth () const
 Returns the width of the led. More...
 
virtual void paintFlat ()
 Paints a circular, flat LED. More...
 
virtual void paintRaised ()
 Paints a circular, raised LED. More...
 
virtual void paintSunken ()
 Paints a circular, sunken LED. More...
 
virtual void paintRect ()
 Paints a rectangular, flat LED. More...
 
virtual void paintRectFrame (bool raised)
 Paints a rectangular LED, either raised or sunken, depending on its argument. More...
 
void paintEvent (QPaintEvent *)
 
bool paintCachedPixmap ()
 Paint the cached antialiased pixmap corresponding to the state if any. More...
 
- Protected Member Functions inherited from Nice::BridgeItem
template<typename E >
void set (const E &_value)
 Set the value from the derived widget to the Property. More...
 
void init (QWidget *_widget)
 Initialize the widget. More...
 
 BridgeItem ()
 Constructor. More...
 
virtual ~BridgeItem ()
 Destructor. More...
 
void setWidgetName ()
 
virtual void initAttributes ()
 virtual function is called after connecting to a property. More...
 
CompletionState getState ()
 Get the current state of the widget. More...
 
void resetGUI ()
 Update the widgets data field from the connected Property. More...
 
virtual int requestUserConfirmation ()
 
virtual void trySetFocus ()
 
void setBuffered (bool _buf)
 
virtual void set ()
 Slot is called when the date of the widget is changed. More...
 
virtual void updateProperty ()
 Set the gui value to the Property. More...
 
template<typename E >
void set (const E &_value)
 Set the value from the derived widget to the Property. More...
 
void init (QWidget *_widget)
 Initialize the widget. More...
 
 BridgeItem ()
 Constructor. More...
 
virtual ~BridgeItem ()
 Destructor. More...
 
void setWidgetName ()
 
virtual void initAttributes ()
 virtual function is called after connecting to a property. More...
 
CompletionState getState ()
 Get the current state of the widget. More...
 
void resetGUI ()
 Update the widgets data field from the connected Property. More...
 
virtual int requestUserConfirmation ()
 
virtual void trySetFocus ()
 
void setBuffered (bool _buf)
 
virtual void set ()
 Slot is called when the date of the widget is changed. More...
 
virtual void updateProperty ()
 Set the gui value to the Property. More...
 
template<typename E >
void set (const E &_value)
 Set the value from the derived widget to the Property. More...
 
void init (QWidget *_widget)
 Initialize the widget. More...
 
 BridgeItem ()
 Constructor. More...
 
virtual ~BridgeItem ()
 Destructor. More...
 
void setWidgetName ()
 
virtual void initAttributes ()
 virtual function is called after connecting to a property. More...
 
CompletionState getState ()
 Get the current state of the widget. More...
 
void resetGUI ()
 Update the widgets data field from the connected Property. More...
 
virtual int requestUserConfirmation ()
 
virtual void trySetFocus ()
 
void setBuffered (bool _buf)
 
virtual void set ()
 Slot is called when the date of the widget is changed. More...
 
virtual void updateProperty ()
 Set the gui value to the Property. More...
 
- Protected Attributes inherited from Nice::BridgeItem
bool m_inited
 
CompletionState m_state
 
bool m_autoSynch
 
bool m_isUserConfirmationNeeded
 
Nice::Jointm_root
 
Nice::Propertym_prop
 
WaveBreakerPtr m_breaker
 
bool m_showLabels
 
Nice::I64 m_id
 
QString m_nodeName
 
std::vector< Nice::PropertyPtrm_connectedProps
 

Constructor & Destructor Documentation

◆ Led2() [1/3]

Led2::Led2 ( QWidget *  parent,
bool  _connect = false 
)

◆ Led2() [2/3]

Led2::Led2 ( QWidget *  parent,
bool  _connect = false 
)

◆ Led2() [3/3]

Led2::Led2 ( QWidget *  parent,
bool  _connect = false 
)

Member Function Documentation

◆ clickable() [1/3]

bool Led2::clickable ( )
inline

◆ clickable() [2/3]

bool Led2::clickable ( )
inline

◆ clickable() [3/3]

bool Led2::clickable ( )
inline

◆ initSlots() [1/3]

void Led2::initSlots ( )
privatevirtual

Reimplemented from Nice::BridgeItem.

◆ initSlots() [2/3]

virtual void Led2::initSlots ( )
privatevirtual

Reimplemented from Nice::BridgeItem.

◆ initSlots() [3/3]

virtual void Led2::initSlots ( )
privatevirtual

Reimplemented from Nice::BridgeItem.

◆ mousePressEvent() [1/3]

void Led2::mousePressEvent ( QMouseEvent *  event)

◆ mousePressEvent() [2/3]

void Led2::mousePressEvent ( QMouseEvent *  event)

◆ mousePressEvent() [3/3]

void Led2::mousePressEvent ( QMouseEvent *  event)

◆ set [1/3]

void Led2::set ( )
privateslot

◆ set [2/3]

void Led2::set ( )
privateslot

◆ set [3/3]

void Led2::set ( )
privateslot

◆ setClickable() [1/3]

void Led2::setClickable ( bool  _clickable)
inline

◆ setClickable() [2/3]

void Led2::setClickable ( bool  _clickable)
inline

◆ setClickable() [3/3]

void Led2::setClickable ( bool  _clickable)
inline

◆ setTristate [1/3]

void Led2::setTristate ( bool  _tristate)
inlineslot

◆ setTristate [2/3]

void Led2::setTristate ( bool  _tristate)
inlineslot

◆ setTristate [3/3]

void Led2::setTristate ( bool  _tristate)
inlineslot

◆ tristate() [1/3]

bool Led2::tristate ( )
inline

◆ tristate() [2/3]

bool Led2::tristate ( )
inline

◆ tristate() [3/3]

bool Led2::tristate ( )
inline

◆ updateGUI() [1/3]

virtual void Led2::updateGUI ( const Nice::Any _val)
privatevirtual

◆ updateGUI() [2/3]

void Led2::updateGUI ( const Nice::Any _val)
privatevirtual

◆ updateGUI() [3/3]

virtual void Led2::updateGUI ( const Nice::Any _val)
privatevirtual

◆ valueChanged [1/3]

void Led2::valueChanged ( )
signal

◆ valueChanged [2/3]

void Led2::valueChanged ( )
signal

◆ valueChanged [3/3]

void Led2::valueChanged ( )
signal

Friends And Related Function Documentation

◆ AbstractVectorBox [1/3]

template<typename T , typename E >
friend class AbstractVectorBox
friend

◆ AbstractVectorBox [2/3]

template<typename T , typename E >
class AbstractVectorBox ( )
friend

◆ AbstractVectorBox [3/3]

template<typename T , typename E >
class AbstractVectorBox ( )
friend

◆ LedBitSetVector

LedBitSetVector
friend

Member Data Documentation

◆ m_clickable

bool Led2::m_clickable
private

◆ m_state

Qt::CheckState Led2::m_state
private

◆ m_tristate

bool Led2::m_tristate
private

Property Documentation

◆ AutoSynch

bool Led2::AutoSynch
readwrite

◆ Clickable

bool Led2::Clickable
readwrite

◆ color

QColor Led2::color
readwrite

◆ darkFactor

int Led2::darkFactor
readwrite

◆ look

Look Led2::look
readwrite

◆ PropertyNode

QString Led2::PropertyNode
readwrite

◆ shape

Shape Led2::shape
readwrite

◆ Tristate

bool Led2::Tristate
readwrite

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