LIDL Soundboard  1.9.0
A simple soundboard, yet better than EXP Soundboard forsenE
SliderSpin Class Reference

#include <SliderSpin.h>

Inheritance diagram for SliderSpin:
Inheritance graph
Collaboration diagram for SliderSpin:
Collaboration graph

Signals

void valueChanged (int value)
 valueChanged Signal emitted when the value is changed. More...
 

Public Member Functions

 SliderSpin (QWidget *parent=nullptr)
 SliderSpin. More...
 
 SliderSpin (int min=0, int max=100, QString suffix="", QString prefix="", QWidget *parent=nullptr)
 SliderSpin Construct a slider + spinbox obect. More...
 
void setRange (int min, int max)
 setRange Sets the range of the slider and spin box. More...
 
void setSuffix (const QString &suffix)
 setSuffix Sets the suffix of the QSpinBox. More...
 
void setPrefix (const QString &prefix)
 setPrefix Sets the prefix of the QSpinBox. More...
 
void setValue (int value)
 setValue Sets the current value of both the QSlider and the QSpinBox. More...
 
void setEnabled (bool state)
 setEnabled More...
 
int value () const
 value More...
 
int specialValue () const
 specialValue More...
 

Private Attributes

QGridLayout * _layout
 
QSlider * _slider
 
QSpinBox * _spinbox
 

Constructor & Destructor Documentation

◆ SliderSpin() [1/2]

SliderSpin::SliderSpin ( QWidget *  parent = nullptr)
explicit

SliderSpin.

Parameters
parent

References _layout, _slider, _spinbox, value(), and valueChanged().

Here is the call graph for this function:

◆ SliderSpin() [2/2]

SliderSpin::SliderSpin ( int  min = 0,
int  max = 100,
QString  suffix = "",
QString  prefix = "",
QWidget *  parent = nullptr 
)

SliderSpin Construct a slider + spinbox obect.

Constructs both of the QSlider and the QSpinBox widget and add them to a QGridLayout. The Slider will take 80% of the horizontal space. The SpinBox will take the remaining 20%.

Parameters
minThe minimum value (int).
maxThe maximum value (int).
suffixA suffix to append to the QSpinBox.
prefixA prefix to prepend to the QSpinBox.
parentThe parent. (usually null since this widget will be in a layout).

References _spinbox, and setRange().

Here is the call graph for this function:

Member Function Documentation

◆ setEnabled()

void SliderSpin::setEnabled ( bool  state)

setEnabled

Parameters
state

References _slider, and _spinbox.

◆ setPrefix()

void SliderSpin::setPrefix ( const QString &  prefix)

setPrefix Sets the prefix of the QSpinBox.

Parameters
prefixThe prefix.

References _spinbox.

◆ setRange()

void SliderSpin::setRange ( int  min,
int  max 
)

setRange Sets the range of the slider and spin box.

Parameters
minMinimum value (int).
maxMaximum value (int).

References _slider, and _spinbox.

Referenced by SliderSpin().

Here is the caller graph for this function:

◆ setSuffix()

void SliderSpin::setSuffix ( const QString &  suffix)

setSuffix Sets the suffix of the QSpinBox.

Parameters
suffixThe suffix.

References _spinbox.

◆ setValue()

void SliderSpin::setValue ( int  value)

setValue Sets the current value of both the QSlider and the QSpinBox.

Parameters
valueThe new value.

References _slider, and _spinbox.

◆ specialValue()

int SliderSpin::specialValue ( ) const

specialValue

Returns

◆ value()

int SliderSpin::value ( ) const

value

Returns

References _slider.

Referenced by SliderSpin().

Here is the caller graph for this function:

◆ valueChanged

void SliderSpin::valueChanged ( int  value)
signal

valueChanged Signal emitted when the value is changed.

Parameters
value

Referenced by SfxSettingsWidget::addSlider(), and SliderSpin().

Here is the caller graph for this function:

Member Data Documentation

◆ _layout

QGridLayout* SliderSpin::_layout
private

The GridLayout this widget uses.

Referenced by SliderSpin().

◆ _slider

QSlider* SliderSpin::_slider
private

The QSlider this widget uses.

Referenced by setEnabled(), setRange(), setValue(), SliderSpin(), and value().

◆ _spinbox

QSpinBox* SliderSpin::_spinbox
private

The QSpinBox this widget uses.

Referenced by setEnabled(), setPrefix(), setRange(), setSuffix(), setValue(), and SliderSpin().


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