CFEL - ASG Software Suite  2.5.0
CASS
Public Slots | Public Member Functions | Protected Member Functions | Properties | Private Attributes | List of all members
LED Class Reference

#include <led.h>

+ Inheritance diagram for LED:
+ Collaboration diagram for LED:

Public Slots

void setState (bool state)
 
void toggleState ()
 
void setFlashing (bool flashing)
 
void setFlashRate (int rate)
 
void startFlashing ()
 
void stopFlashing ()
 

Public Member Functions

 LED (QWidget *parent=0)
 
 ~LED ()
 
double diameter () const
 
void setDiameter (double diameter)
 
QColor color () const
 
void setColor (const QColor &color)
 
Qt::Alignment alignment () const
 
void setAlignment (Qt::Alignment alignment)
 
bool state () const
 
bool isFlashing () const
 
int flashRate () const
 
int heightForWidth (int width) const
 
QSize sizeHint () const
 
QSize minimumSizeHint () const
 
- Public Member Functions inherited from QWidget
 ContextMenuPolicy
 
 FocusPolicy
 
 InputMethodHints
 
 LayoutDirection
 
 WindowFlags
 
 WindowModality
 
 QWidget (QWidget *parent=0, Qt::WindowFlags f=0)
 
 actionEvent (QActionEvent *event)
 
 actions ()
 
 activateWindow ()
 
 addAction (QAction *action)
 
 addActions (QList< QAction * > actions)
 
 adjustSize ()
 
 ColorRole QWidget::backgroundRole()
 
 changeEvent (QEvent *event)
 
 childAt (int x, int y)
 
 childAt (const QPoint &p)
 
 clearFocus ()
 
 clearMask ()
 
 close ()
 
 closeEvent (QCloseEvent *event)
 
 contentsMargins ()
 
 contentsRect ()
 
 contextMenuEvent (QContextMenuEvent *event)
 
 create (WId window=0, bool initializeWindow=true, bool destroyOldWindow=true)
 
 customContextMenuRequested (const QPoint &pos)
 
 destroy (bool destroyWindow=true, bool destroySubWindows=true)
 
 dragEnterEvent (QDragEnterEvent *event)
 
 dragLeaveEvent (QDragLeaveEvent *event)
 
 dragMoveEvent (QDragMoveEvent *event)
 
 dropEvent (QDropEvent *event)
 
 effectiveWinId ()
 
 ensurePolished ()
 
 enterEvent (QEvent *event)
 
 event (QEvent *event)
 
 find (WId id)
 
 focusInEvent (QFocusEvent *event)
 
 focusNextChild ()
 
 focusNextPrevChild (bool next)
 
 focusOutEvent (QFocusEvent *event)
 
 focusPreviousChild ()
 
 focusProxy ()
 
 focusWidget ()
 
 fontInfo ()
 
 fontMetrics ()
 
 ColorRole QWidget::foregroundRole()
 
 getContentsMargins (int *left, int *top, int *right, int *bottom)
 
 getDC ()
 
 grabGesture (Qt::GestureType gesture, Qt::GestureFlags flags=Qt::GestureFlags()
 
 grabKeyboard ()
 
 grabMouse ()
 
 grabMouse (const QCursor &cursor)
 
 grabShortcut (const QKeySequence &key, Qt::ShortcutContext context=Qt::WindowShortcut)
 
 graphicsEffect ()
 
 graphicsProxyWidget ()
 
 hasEditFocus ()
 
 heightForWidth (int w)
 
 hide ()
 
 hideEvent (QHideEvent *event)
 
 inputContext ()
 
 inputMethodEvent (QInputMethodEvent *event)
 
 inputMethodQuery (Qt::InputMethodQuery query)
 
 insertAction (QAction *before, QAction *action)
 
 insertActions (QAction *before, QList< QAction * > actions)
 
 isAncestorOf (const QWidget *child)
 
 isEnabledTo (QWidget *ancestor)
 
 isHidden ()
 
 isVisibleTo (QWidget *ancestor)
 
 isWindow ()
 
 keyPressEvent (QKeyEvent *event)
 
 keyReleaseEvent (QKeyEvent *event)
 
 keyboardGrabber ()
 
 layout ()
 
 leaveEvent (QEvent *event)
 
 lower ()
 
 HANDLE QWidget::macCGHandle()
 
 macEvent (EventHandlerCallRef caller, EventRef event)
 
 HANDLE QWidget::macQDHandle()
 
 mapFrom (QWidget *parent, const QPoint &pos)
 
 mapFromGlobal (const QPoint &pos)
 
 mapFromParent (const QPoint &pos)
 
 mapTo (QWidget *parent, const QPoint &pos)
 
 mapToGlobal (const QPoint &pos)
 
 mapToParent (const QPoint &pos)
 
 mask ()
 
 metric (PaintDeviceMetric m)
 
 mouseDoubleClickEvent (QMouseEvent *event)
 
 mouseGrabber ()
 
 mouseMoveEvent (QMouseEvent *event)
 
 mousePressEvent (QMouseEvent *event)
 
 mouseReleaseEvent (QMouseEvent *event)
 
 moveEvent (QMoveEvent *event)
 
 nativeParentWidget ()
 
 nextInFocusChain ()
 
 overrideWindowFlags (Qt::WindowFlags flags)
 
 paintEngine ()
 
 paintEvent (QPaintEvent *event)
 
 parentWidget ()
 
 previousInFocusChain ()
 
 qwsEvent (QWSEvent *event)
 
 raise ()
 
 releaseDC (HDC hdc)
 
 releaseKeyboard ()
 
 releaseMouse ()
 
 releaseShortcut (int id)
 
 removeAction (QAction *action)
 
 render (QPaintDevice *target, const QPoint &targetOffset=QPoint()
 
 render (QPainter *painter, const QPoint &targetOffset=QPoint()
 
 repaint ()
 
 repaint (int x, int y, int w, int h)
 
 repaint (const QRect &rect)
 
 repaint (const QRegion &rgn)
 
 resizeEvent (QResizeEvent *event)
 
 restoreGeometry (const QByteArray &geometry)
 
 saveGeometry ()
 
 scroll (int dx, int dy)
 
 scroll (int dx, int dy, const QRect &r)
 
 setAttribute (Qt::WidgetAttribute attribute, bool on=true)
 
 setBackgroundRole (QPalette::ColorRole role)
 
 setContentsMargins (int left, int top, int right, int bottom)
 
 setContentsMargins (const QMargins &margins)
 
 setDisabled (bool disable)
 
 setEditFocus (bool enable)
 
 setFixedHeight (int h)
 
 setFixedSize (const QSize &s)
 
 setFixedSize (int w, int h)
 
 setFixedWidth (int w)
 
 setFocus (Qt::FocusReason reason)
 
 setFocus ()
 
 setFocusProxy (QWidget *w)
 
 setForegroundRole (QPalette::ColorRole role)
 
 setGraphicsEffect (QGraphicsEffect *effect)
 
 setHidden (bool hidden)
 
 setInputContext (QInputContext *context)
 
 setLayout (QLayout *layout)
 
 setMask (const QBitmap &bitmap)
 
 setMask (const QRegion &region)
 
 setParent (QWidget *parent)
 
 setParent (QWidget *parent, Qt::WindowFlags f)
 
 setShortcutAutoRepeat (int id, bool enable=true)
 
 setShortcutEnabled (int id, bool enable=true)
 
 setStyle (QStyle *style)
 
 setTabOrder (QWidget *first, QWidget *second)
 
 setWindowRole (const QString &role)
 
 setWindowState (Qt::WindowStates windowState)
 
 setWindowSurface (QWindowSurface *surface)
 
 setupUi (QWidget *widget)
 
 show ()
 
 showEvent (QShowEvent *event)
 
 showFullScreen ()
 
 showMaximized ()
 
 showMinimized ()
 
 showNormal ()
 
 stackUnder (QWidget *w)
 
 style ()
 
 tabletEvent (QTabletEvent *event)
 
 testAttribute (Qt::WidgetAttribute attribute)
 
 underMouse ()
 
 ungrabGesture (Qt::GestureType gesture)
 
 update ()
 
 update (int x, int y, int w, int h)
 
 update (const QRect &rect)
 
 update (const QRegion &rgn)
 
 updateGeometry ()
 
 updateMicroFocus ()
 
 visibleRegion ()
 
 wheelEvent (QWheelEvent *event)
 
 winEvent (MSG *message, long *result)
 
 winId ()
 
 window ()
 
 windowRole ()
 
 WindowStates QWidget::windowState()
 
 windowSurface ()
 
 WindowType QWidget::windowType()
 
 x11Event (XEvent *event)
 
 x11Info ()
 
 HANDLE QWidget::x11PictureHandle()
 

Protected Member Functions

void paintEvent (QPaintEvent *event)
 

Properties

double diameter
 
QColor color
 
Qt::Alignment alignment
 
bool state
 
bool flashing
 
int flashRate
 

Private Attributes

double diameter_
 
QColor color_
 
Qt::Alignment alignment_
 
bool initialState_
 
bool state_
 
int flashRate_
 
bool flashing_
 
int pixX_
 
int pixY_
 
int diamX_
 
int diamY_
 
QRadialGradient gradient_
 
QTimertimer_
 

Detailed Description

Definition at line 15 of file led.h.

Constructor & Destructor Documentation

LED::LED ( QWidget parent = 0)
explicit

Definition at line 17 of file led.cpp.

References diameter_, setDiameter(), timer_, and toggleState().

LED::~LED ( )

Definition at line 33 of file led.cpp.

Member Function Documentation

Qt::Alignment LED::alignment ( ) const

Referenced by setAlignment().

QColor LED::color ( ) const

Referenced by setColor().

double LED::diameter ( ) const

Referenced by setDiameter().

int LED::flashRate ( ) const
int LED::heightForWidth ( int  width) const

Definition at line 118 of file led.cpp.

References cass::ACQIRIS::width.

bool LED::isFlashing ( ) const

Definition at line 186 of file led.cpp.

References flashing_.

QSize LED::minimumSizeHint ( ) const

Definition at line 128 of file led.cpp.

References diamX_, and diamY_.

void LED::paintEvent ( QPaintEvent event)
protected
void LED::setAlignment ( Qt::Alignment  alignment)

Definition at line 74 of file led.cpp.

References alignment(), alignment_, and QWidget::update().

void LED::setColor ( const QColor color)

Definition at line 62 of file led.cpp.

References color(), color_, and QWidget::update().

Referenced by jocassview::StatusLED::setStatus().

void LED::setDiameter ( double  diameter)
void LED::setFlashing ( bool  flashing)
slot

Definition at line 88 of file led.cpp.

References flashing, flashing_, and QWidget::update().

Referenced by startFlashing(), and stopFlashing().

void LED::setFlashRate ( int  rate)
slot

Definition at line 81 of file led.cpp.

References flashRate_, rate, and QWidget::update().

void LED::setState ( bool  state)
slot

Definition at line 106 of file led.cpp.

References state(), state_, and QWidget::update().

Referenced by jocassview::StatusLED::setStatus().

QSize LED::sizeHint ( ) const

Definition at line 123 of file led.cpp.

References diamX_, and diamY_.

void LED::startFlashing ( )
slot

Definition at line 95 of file led.cpp.

References setFlashing().

bool LED::state ( ) const

Referenced by setState().

void LED::stopFlashing ( )
slot

Definition at line 100 of file led.cpp.

References setFlashing().

void LED::toggleState ( )
slot

Definition at line 112 of file led.cpp.

References state_, and QWidget::update().

Referenced by LED().

Member Data Documentation

Qt::Alignment LED::alignment_
private

Definition at line 64 of file led.h.

Referenced by paintEvent(), and setAlignment().

QColor LED::color_
private

Definition at line 63 of file led.h.

Referenced by paintEvent(), and setColor().

double LED::diameter_
private

Definition at line 62 of file led.h.

Referenced by LED(), and setDiameter().

int LED::diamX_
private

Definition at line 78 of file led.h.

Referenced by minimumSizeHint(), paintEvent(), setDiameter(), and sizeHint().

int LED::diamY_
private

Definition at line 78 of file led.h.

Referenced by minimumSizeHint(), paintEvent(), setDiameter(), and sizeHint().

bool LED::flashing_
private

Definition at line 68 of file led.h.

Referenced by isFlashing(), paintEvent(), and setFlashing().

int LED::flashRate_
private

Definition at line 67 of file led.h.

Referenced by paintEvent(), and setFlashRate().

QRadialGradient LED::gradient_
private

Definition at line 80 of file led.h.

bool LED::initialState_
private

Definition at line 65 of file led.h.

int LED::pixX_
private

Definition at line 73 of file led.h.

Referenced by setDiameter().

int LED::pixY_
private

Definition at line 73 of file led.h.

Referenced by setDiameter().

bool LED::state_
private

Definition at line 66 of file led.h.

Referenced by paintEvent(), setState(), and toggleState().

QTimer* LED::timer_
private

Definition at line 81 of file led.h.

Referenced by LED(), and paintEvent().

Property Documentation

Qt::Alignment LED::alignment
readwrite

Definition at line 21 of file led.h.

QColor LED::color
readwrite

Definition at line 20 of file led.h.

double LED::diameter
readwrite

Definition at line 19 of file led.h.

bool LED::flashing
readwrite

Definition at line 23 of file led.h.

Referenced by setFlashing().

int LED::flashRate
readwrite

Definition at line 24 of file led.h.

bool LED::state
readwrite

Definition at line 22 of file led.h.


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