change from slider to spinner for threshold
[mussa.git] / qui / ThresholdWidget.hpp
1 #ifndef _THRESHOLD_WIDGET_H_ 
2 #define _THRESHOLD_WIDGET_H_
3
4 #include <QSpinBox>
5 #include <QWidget>
6
7 class ThresholdWidget : public QWidget
8 {
9   Q_OBJECT 
10
11 public: 
12   ThresholdWidget(QWidget *parent = 0, int min=21, int max=30);
13
14   //! return what percent of our maximum threshold we are.
15   float percent() const;
16   //! return our current threshold
17   int threshold() const;
18
19 public slots:
20   void setThreshold(int threshold);
21   void setRange(int min, int max);
22
23 signals:
24   void thresholdChanged(int new_threshold);
25
26 protected:
27   QSpinBox basepair_spinner;
28
29 };
30 const int threshold_max_display_digits = 2;
31
32 #endif