3 #include <QDoubleSpinBox>
5 #pragma GCC diagnostic push
6 #pragma GCC diagnostic ignored "-Wpedantic"
7 #include <qwt_slider.h>
8 #pragma GCC diagnostic pop
18 #define cmp_or_log(l,c,r) \
21 out << " FAILED: " #l " " #c " " #r " " \
22 << VAROUT(l) << ", " << VAROUT(r) << '\n',\
32 const QObject* stateChangeReceiver,
const char* stateChangeSlot)
37 widget->setToolTip(QString::fromStdString(desc.toolTip));
38 widget->setMinimum(desc.min);
39 widget->setMaximum(desc.max);
40 widget->setDecimals(desc.decimals);
41 widget->setSingleStep((desc.max - desc.min) / desc.steps);
43 QObject::connect(widget, SIGNAL(valueChanged(
double)), stateChangeReceiver, stateChangeSlot);
50 widget->setValue(
value);
55 return widget->value();
63 #define cmp_or_log(l,c,r) \
66 out << " FAILED: " #l " " #c " " #r " " \
67 << VAROUT(l) << ", " << VAROUT(r) << '\n',\
76 const QObject* stateChangeReceiver,
const char* stateChangeSlot)
81 widget->setToolTip(QString::fromStdString(desc.toolTip));
82 widget->setLowerBound(desc.min);
83 widget->setUpperBound(desc.max);
84 widget->setTotalSteps(desc.steps);
85 widget->setOrientation(Qt::Horizontal);
87 QObject::connect(widget, SIGNAL(valueChanged(
double)), stateChangeReceiver, stateChangeSlot);
94 widget->setValue(
value);
99 return widget->value();