SDRAngel
4.11.5
Developer docs for <a href="https://github.com/f4exb/sdrangel">SDRangel<\a>, an Open Source Qt5 / OpenGL 3.0+ SDR and signal analyzer frontend to various hardware.
|
#include <valuedial.h>
Inherits QWidget.
Signals | |
void | changed (quint64 value) |
Public Member Functions | |
ValueDial (QWidget *parent=NULL, ColorMapper colorMapper=ColorMapper(ColorMapper::Normal)) | |
void | setValue (quint64 value) |
void | setValueRange (uint numDigits, quint64 min, quint64 max) |
void | setFont (const QFont &font) |
void | setBold (bool bold) |
void | setColorMapper (ColorMapper colorMapper) |
quint64 | getValue () const |
quint64 | getValueNew () const |
Private Slots | |
void | animate () |
void | blink () |
Private Member Functions | |
quint64 | findExponent (int digit) |
QChar | digitNeigh (QChar c, bool dir) |
QString | formatText (quint64 value) |
void | paintEvent (QPaintEvent *) |
void | mousePressEvent (QMouseEvent *) |
void | mouseMoveEvent (QMouseEvent *) |
void | wheelEvent (QWheelEvent *) |
void | leaveEvent (QEvent *) |
void | keyPressEvent (QKeyEvent *) |
void | focusInEvent (QFocusEvent *) |
void | focusOutEvent (QFocusEvent *) |
Private Attributes | |
QLinearGradient | m_background |
int | m_numDigits |
int | m_numDecimalPoints |
int | m_digitWidth |
int | m_digitHeight |
int | m_hightlightedDigit |
int | m_cursor |
bool | m_cursorState |
quint64 | m_value |
quint64 | m_valueMax |
quint64 | m_valueMin |
QString | m_text |
quint64 | m_valueNew |
QString | m_textNew |
int | m_animationState |
QTimer | m_animationTimer |
QTimer | m_blinkTimer |
QChar | m_groupSeparator |
ColorMapper | m_colorMapper |
Definition at line 24 of file valuedial.h.
ValueDial::ValueDial | ( | QWidget * | parent = NULL , |
ColorMapper | colorMapper = ColorMapper(ColorMapper::Normal) |
||
) |
Definition at line 28 of file valuedial.cpp.
References animate(), blink(), formatText(), ColorMapper::getDialBackgroundColorMap(), m_animationTimer, m_background, m_blinkTimer, m_colorMapper, m_cursor, m_cursorState, m_digitHeight, m_digitWidth, m_groupSeparator, m_hightlightedDigit, m_numDecimalPoints, m_numDigits, m_text, m_value, m_valueMax, m_valueMin, and m_valueNew.
|
privateslot |
Definition at line 597 of file valuedial.cpp.
References abs(), m_animationState, m_animationTimer, m_text, m_textNew, m_value, and m_valueNew.
Referenced by ValueDial().
|
privateslot |
Definition at line 624 of file valuedial.cpp.
References m_cursor, and m_cursorState.
Referenced by ValueDial().
|
signal |
Referenced by keyPressEvent(), mousePressEvent(), and wheelEvent().
|
private |
Definition at line 157 of file valuedial.cpp.
Referenced by paintEvent().
|
private |
Definition at line 144 of file valuedial.cpp.
References i, m_numDecimalPoints, and m_numDigits.
Referenced by keyPressEvent(), mousePressEvent(), and wheelEvent().
|
private |
|
private |
|
private |
Definition at line 177 of file valuedial.cpp.
References i, m_numDecimalPoints, and m_numDigits.
Referenced by setValue(), setValueRange(), and ValueDial().
|
inline |
Definition at line 35 of file valuedial.h.
|
inline |
Definition at line 36 of file valuedial.h.
|
private |
Definition at line 419 of file valuedial.cpp.
References changed(), findExponent(), m_animationState, m_blinkTimer, m_cursor, m_cursorState, m_groupSeparator, m_hightlightedDigit, m_numDecimalPoints, m_numDigits, m_text, m_value, m_valueMax, m_valueMin, m_valueNew, and setValue().
|
private |
|
private |
Definition at line 337 of file valuedial.cpp.
References i, m_digitWidth, m_groupSeparator, m_hightlightedDigit, and m_text.
|
private |
Definition at line 295 of file valuedial.cpp.
References changed(), findExponent(), i, m_blinkTimer, m_cursor, m_cursorState, m_digitWidth, m_groupSeparator, m_numDecimalPoints, m_numDigits, m_text, m_value, m_valueNew, and setValue().
|
private |
Definition at line 195 of file valuedial.cpp.
References digitNeigh(), ColorMapper::getBoundaryAlphaColor(), ColorMapper::getBoundaryColor(), ColorMapper::getDarkBorderColor(), ColorMapper::getForegroundColor(), ColorMapper::getHighlightColor(), ColorMapper::getLightBorderColor(), ColorMapper::getSecondaryForegroundColor(), i, m_animationState, m_background, m_colorMapper, m_cursor, m_cursorState, m_digitHeight, m_digitWidth, m_groupSeparator, m_hightlightedDigit, m_numDecimalPoints, m_numDigits, m_text, and m_textNew.
void ValueDial::setBold | ( | bool | bold | ) |
Definition at line 85 of file valuedial.cpp.
References setFont().
void ValueDial::setColorMapper | ( | ColorMapper | colorMapper | ) |
Definition at line 92 of file valuedial.cpp.
References ColorMapper::getDialBackgroundColorMap(), m_background, and m_colorMapper.
void ValueDial::setFont | ( | const QFont & | font | ) |
Definition at line 71 of file valuedial.cpp.
References m_digitHeight, m_digitWidth, m_numDecimalPoints, and m_numDigits.
Referenced by setBold().
void ValueDial::setValue | ( | quint64 | value | ) |
Definition at line 104 of file valuedial.cpp.
References formatText(), m_animationState, m_animationTimer, m_textNew, m_value, m_valueMax, m_valueMin, and m_valueNew.
Referenced by keyPressEvent(), mousePressEvent(), setValueRange(), and wheelEvent().
void ValueDial::setValueRange | ( | uint | numDigits, |
quint64 | min, | ||
quint64 | max | ||
) |
Definition at line 126 of file valuedial.cpp.
References formatText(), m_digitWidth, m_numDecimalPoints, m_numDigits, m_text, m_value, m_valueMax, m_valueMin, leansdr::max(), leansdr::min(), and setValue().
|
private |
Definition at line 353 of file valuedial.cpp.
References changed(), findExponent(), i, m_animationState, m_blinkTimer, m_cursor, m_digitWidth, m_groupSeparator, m_hightlightedDigit, m_text, m_value, m_valueMax, m_valueMin, m_valueNew, and setValue().
|
private |
Definition at line 57 of file valuedial.h.
Referenced by animate(), keyPressEvent(), paintEvent(), setValue(), and wheelEvent().
|
private |
Definition at line 58 of file valuedial.h.
Referenced by animate(), setValue(), and ValueDial().
|
private |
Definition at line 42 of file valuedial.h.
Referenced by paintEvent(), setColorMapper(), and ValueDial().
|
private |
Definition at line 59 of file valuedial.h.
Referenced by focusInEvent(), focusOutEvent(), keyPressEvent(), mousePressEvent(), ValueDial(), and wheelEvent().
|
private |
Definition at line 62 of file valuedial.h.
Referenced by paintEvent(), setColorMapper(), and ValueDial().
|
private |
Definition at line 48 of file valuedial.h.
Referenced by blink(), focusInEvent(), focusOutEvent(), keyPressEvent(), mousePressEvent(), paintEvent(), ValueDial(), and wheelEvent().
|
private |
Definition at line 49 of file valuedial.h.
Referenced by blink(), focusInEvent(), keyPressEvent(), mousePressEvent(), paintEvent(), and ValueDial().
|
private |
Definition at line 46 of file valuedial.h.
Referenced by paintEvent(), setFont(), and ValueDial().
|
private |
Definition at line 45 of file valuedial.h.
Referenced by mouseMoveEvent(), mousePressEvent(), paintEvent(), setFont(), setValueRange(), ValueDial(), and wheelEvent().
|
private |
Definition at line 60 of file valuedial.h.
Referenced by keyPressEvent(), mouseMoveEvent(), mousePressEvent(), paintEvent(), ValueDial(), and wheelEvent().
|
private |
Definition at line 47 of file valuedial.h.
Referenced by keyPressEvent(), leaveEvent(), mouseMoveEvent(), paintEvent(), ValueDial(), and wheelEvent().
|
private |
Definition at line 44 of file valuedial.h.
Referenced by findExponent(), formatText(), keyPressEvent(), mousePressEvent(), paintEvent(), setFont(), setValueRange(), and ValueDial().
|
private |
Definition at line 43 of file valuedial.h.
Referenced by findExponent(), formatText(), keyPressEvent(), mousePressEvent(), paintEvent(), setFont(), setValueRange(), and ValueDial().
|
private |
Definition at line 53 of file valuedial.h.
Referenced by animate(), keyPressEvent(), mouseMoveEvent(), mousePressEvent(), paintEvent(), setValueRange(), ValueDial(), and wheelEvent().
|
private |
Definition at line 56 of file valuedial.h.
Referenced by animate(), paintEvent(), and setValue().
|
private |
Definition at line 50 of file valuedial.h.
Referenced by animate(), keyPressEvent(), mousePressEvent(), setValue(), setValueRange(), ValueDial(), and wheelEvent().
|
private |
Definition at line 51 of file valuedial.h.
Referenced by keyPressEvent(), setValue(), setValueRange(), ValueDial(), and wheelEvent().
|
private |
Definition at line 52 of file valuedial.h.
Referenced by keyPressEvent(), setValue(), setValueRange(), ValueDial(), and wheelEvent().
|
private |
Definition at line 55 of file valuedial.h.
Referenced by animate(), keyPressEvent(), mousePressEvent(), setValue(), ValueDial(), and wheelEvent().