27#include <Inventor/Qt/OivQtCompat.h>
28#include <Inventor/misc/SoCallbackList.h>
29#include <Inventor/Qt/SoQtComponent.h>
30#include <Inventor/Qt/SoQtBasicSlider.h>
34class SoFloatCallbackList;
41typedef void SoQtSliderCB(
void *userData,
float val);
58 SoQtSlider( QWidget* parent = NULL,
59 const char *name = NULL,
60 SbBool buildInsideParent = TRUE);
64 float getValue()
const;
65 void setLabel(
const QString&);
66 const QString& getLabel()
const;
71 void setNumericFieldVisible(
SbBool b = TRUE);
72 SbBool isNumericFieldVisible()
const {
return numberVisible; }
78 void addStartCallback (SoQtSliderCB *f,
void *userData = NULL);
79 void addValueChangedCallback (SoQtSliderCB *f,
void *userData = NULL);
80 void addFinishCallback (SoQtSliderCB *f,
void *userData = NULL);
82 void removeStartCallback (SoQtSliderCB *f,
void *userData = NULL);
83 void removeValueChangedCallback (SoQtSliderCB *f,
void *userData = NULL);
84 void removeFinishCallback (SoQtSliderCB *f,
void *userData = NULL);
87 void interactivity(
SbBool flag ) { sliderWidget->interactivity(flag); }
88 SbBool isInteractive() {
return sliderWidget->isInteractive(); }
98 void setSliderSize(
const SbVec2s &size);
106 SoEXTENDER SoQtSlider (QWidget* parent,
112 QWidget* buildWidget(QWidget* parent, SoQtBasicSlider::Type t = SoQtBasicSlider::PLAIN_SLIDER);
115 SoQtBasicSlider* sliderWidget;
119 QPointer<QWidget> mgrWidget;
120 QPointer<QLineEdit> numberWidget;
121 QPointer<QLabel> labelWidget;
128 void constructorCommon(
SbBool buildNow);
133 void sliderChanged(
float val);
134 static void sliderChangedCB(
void *p,
float val) { ((SoQtSlider*)p)->sliderChanged (val); };
136 static void sliderStartCB(
void *p,
float val);
138 static void sliderStopCB(
void *p,
float val);
139 static void textFieldCB(QWidget*, SoQtSlider *,
XtPointer);
143 void textChangedSlot();
147 void setValue(
float v);
152 void valueChanged (
float value);
158SoQtSlider::sliderStartCB(
void *p,
float )
160 ((SoQtSlider*)p)->sliderStart ();
164SoQtSlider::sliderStopCB(
void *p,
float )
166 ((SoQtSlider*)p)->sliderStop ();