svgui
1.9
|
#include <LEDButton.h>
Classes | |
class | LEDButtonPrivate |
Public Slots | |
void | toggle () |
void | on () |
void | off () |
void | setState (bool) |
void | toggleState () |
void | setColor (const QColor &color) |
void | setDarkFactor (int darkfactor) |
Signals | |
void | stateChanged (bool) |
void | mouseEntered () |
void | mouseLeft () |
Public Member Functions | |
LEDButton (QWidget *parent=0) | |
LEDButton (const QColor &col, QWidget *parent=0) | |
LEDButton (const QColor &col, bool state, QWidget *parent=0) | |
~LEDButton () | |
bool | state () const |
QColor | color () const |
int | darkFactor () const |
virtual QSize | sizeHint () const |
virtual QSize | minimumSizeHint () const |
Protected Member Functions | |
void | paintEvent (QPaintEvent *) |
void | mousePressEvent (QMouseEvent *) |
void | enterEvent (QEvent *) |
void | leaveEvent (QEvent *) |
Protected Attributes | |
bool | led_state |
QColor | led_color |
LEDButtonPrivate * | d |
Properties | |
QColor | color |
int | darkFactor |
Definition at line 36 of file LEDButton.h.
LEDButton::LEDButton | ( | QWidget * | parent = 0 | ) |
Definition at line 46 of file LEDButton.cpp.
References d, LEDButton::LEDButtonPrivate::dark_factor, LEDButton::LEDButtonPrivate::off_map, LEDButton::LEDButtonPrivate::offcolor, LEDButton::LEDButtonPrivate::on_map, and setColor().
LEDButton::LEDButton | ( | const QColor & | col, |
QWidget * | parent = 0 |
||
) |
Definition at line 61 of file LEDButton.cpp.
References d, LEDButton::LEDButtonPrivate::dark_factor, LEDButton::LEDButtonPrivate::off_map, LEDButton::LEDButtonPrivate::offcolor, LEDButton::LEDButtonPrivate::on_map, and setColor().
LEDButton::LEDButton | ( | const QColor & | col, |
bool | state, | ||
QWidget * | parent = 0 |
||
) |
Definition at line 74 of file LEDButton.cpp.
References d, LEDButton::LEDButtonPrivate::dark_factor, LEDButton::LEDButtonPrivate::off_map, LEDButton::LEDButtonPrivate::offcolor, LEDButton::LEDButtonPrivate::on_map, and setColor().
Definition at line 87 of file LEDButton.cpp.
References d, LEDButton::LEDButtonPrivate::off_map, and LEDButton::LEDButtonPrivate::on_map.
bool LEDButton::state | ( | ) | const |
Definition at line 271 of file LEDButton.cpp.
References led_state.
Referenced by mousePressEvent(), and setState().
QColor LEDButton::color | ( | ) | const |
Referenced by paintEvent().
int LEDButton::darkFactor | ( | ) | const |
QSize LEDButton::sizeHint | ( | ) | const [virtual] |
Definition at line 349 of file LEDButton.cpp.
QSize LEDButton::minimumSizeHint | ( | ) | const [virtual] |
Definition at line 355 of file LEDButton.cpp.
void LEDButton::stateChanged | ( | bool | ) | [signal] |
Referenced by mousePressEvent().
void LEDButton::mouseEntered | ( | ) | [signal] |
Referenced by enterEvent().
void LEDButton::mouseLeft | ( | ) | [signal] |
Referenced by leaveEvent().
void LEDButton::toggle | ( | ) | [slot] |
Definition at line 331 of file LEDButton.cpp.
References toggleState().
Referenced by mousePressEvent().
void LEDButton::on | ( | ) | [slot] |
Definition at line 337 of file LEDButton.cpp.
References setState().
void LEDButton::off | ( | ) | [slot] |
Definition at line 343 of file LEDButton.cpp.
References setState().
void LEDButton::setState | ( | bool | state | ) | [slot] |
Definition at line 283 of file LEDButton.cpp.
References led_state, and state().
Referenced by PropertyBox::layerVisibilityChanged(), off(), on(), PropertyBox::playAudibleChanged(), and PropertyBox::populateViewPlayFrame().
void LEDButton::toggleState | ( | ) | [slot] |
void LEDButton::setColor | ( | const QColor & | color | ) | [slot] |
Definition at line 301 of file LEDButton.cpp.
References d, LEDButton::LEDButtonPrivate::dark_factor, led_color, LEDButton::LEDButtonPrivate::off_map, LEDButton::LEDButtonPrivate::offcolor, and LEDButton::LEDButtonPrivate::on_map.
Referenced by LEDButton().
void LEDButton::setDarkFactor | ( | int | darkfactor | ) | [slot] |
Definition at line 315 of file LEDButton.cpp.
References d, LEDButton::LEDButtonPrivate::dark_factor, led_color, and LEDButton::LEDButtonPrivate::offcolor.
void LEDButton::paintEvent | ( | QPaintEvent * | ) | [protected] |
Definition at line 120 of file LEDButton.cpp.
References color(), d, led_color, led_state, LEDButton::LEDButtonPrivate::off_map, LEDButton::LEDButtonPrivate::offcolor, and LEDButton::LEDButtonPrivate::on_map.
void LEDButton::mousePressEvent | ( | QMouseEvent * | e | ) | [protected] |
Definition at line 95 of file LEDButton.cpp.
References state(), stateChanged(), and toggle().
void LEDButton::enterEvent | ( | QEvent * | ) | [protected] |
Definition at line 108 of file LEDButton.cpp.
References mouseEntered().
void LEDButton::leaveEvent | ( | QEvent * | ) | [protected] |
Definition at line 114 of file LEDButton.cpp.
References mouseLeft().
bool LEDButton::led_state [protected] |
Definition at line 77 of file LEDButton.h.
Referenced by paintEvent(), setState(), state(), and toggleState().
QColor LEDButton::led_color [protected] |
Definition at line 78 of file LEDButton.h.
Referenced by paintEvent(), setColor(), and setDarkFactor().
LEDButtonPrivate* LEDButton::d [protected] |
Definition at line 80 of file LEDButton.h.
Referenced by LEDButton(), paintEvent(), setColor(), setDarkFactor(), and ~LEDButton().
QColor LEDButton::color [read, write] |
Definition at line 39 of file LEDButton.h.
int LEDButton::darkFactor [read, write] |
Definition at line 40 of file LEDButton.h.