Developer Documentation
VSI::NumWidget Class Reference

#include <Plugin-VSI/types/numWidget.hh>

Inheritance diagram for VSI::NumWidget:
VSI::TypeWidget

Public Member Functions

 NumWidget (QMap< QString, QString > &_hints, const QString &_typeName, QWidget *_parent=NULL)
 Constructor. More...
 
 ~NumWidget ()
 Destructor. More...
 
QString toValue () override
 Convert current value to string. More...
 
void fromValue (QString _from) override
 Read value from string. More...
 
void toDefault () override
 Reset to default. More...
 
- Public Member Functions inherited from VSI::TypeWidget
 TypeWidget (QMap< QString, QString > &_hints, const QString &_typeName, QWidget *_parent=NULL)
 Constructor. More...
 
virtual ~TypeWidget ()
 Destructor. More...
 
virtual QString toValue ()=0
 Return the type configuration result to a string. More...
 
virtual void fromValue (QString _from)=0
 Set configuration to the value of the given string. More...
 
virtual void toDefault ()=0
 reset the widget to default More...
 

Private Slots

void sliderValueChanged (int _value)
 
void spinValueChanged (double _value)
 

Private Attributes

double precision_
 
bool isFloat_
 
int numDecimals_
 
double sliderMul_
 
double default_
 
QSlider * slider_
 
QDoubleSpinBox * spin_
 

Detailed Description

Widget to configure number inputs

Definition at line 63 of file numWidget.hh.

Constructor & Destructor Documentation

◆ NumWidget()

VSI::NumWidget::NumWidget ( QMap< QString, QString > &  _hints,
const QString &  _typeName,
QWidget *  _parent = NULL 
)

Constructor.

Definition at line 64 of file numWidget.cc.

◆ ~NumWidget()

VSI::NumWidget::~NumWidget ( )

Destructor.

Definition at line 177 of file numWidget.cc.

Member Function Documentation

◆ fromValue()

void VSI::NumWidget::fromValue ( QString  _from)
overridevirtual

Read value from string.

Implements VSI::TypeWidget.

Definition at line 192 of file numWidget.cc.

◆ sliderValueChanged

void VSI::NumWidget::sliderValueChanged ( int  _value)
privateslot

Definition at line 200 of file numWidget.cc.

◆ spinValueChanged

void VSI::NumWidget::spinValueChanged ( double  _value)
privateslot

Definition at line 211 of file numWidget.cc.

◆ toDefault()

void VSI::NumWidget::toDefault ( )
overridevirtual

Reset to default.

Implements VSI::TypeWidget.

Definition at line 222 of file numWidget.cc.

◆ toValue()

QString VSI::NumWidget::toValue ( )
overridevirtual

Convert current value to string.

Implements VSI::TypeWidget.

Definition at line 184 of file numWidget.cc.

Member Data Documentation

◆ default_

double VSI::NumWidget::default_
private

Definition at line 96 of file numWidget.hh.

◆ isFloat_

bool VSI::NumWidget::isFloat_
private

Definition at line 91 of file numWidget.hh.

◆ numDecimals_

int VSI::NumWidget::numDecimals_
private

Definition at line 93 of file numWidget.hh.

◆ precision_

double VSI::NumWidget::precision_
private

Definition at line 90 of file numWidget.hh.

◆ slider_

QSlider* VSI::NumWidget::slider_
private

Definition at line 98 of file numWidget.hh.

◆ sliderMul_

double VSI::NumWidget::sliderMul_
private

Definition at line 95 of file numWidget.hh.

◆ spin_

QDoubleSpinBox* VSI::NumWidget::spin_
private

Definition at line 99 of file numWidget.hh.


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