Loading [MathJax]/jax/output/NativeMML/config.js
Isis 3 Developer Reference
BandSpinBox.h
Go to the documentation of this file.
1 #ifndef BandSpinBox_h
2 #define BandSpinBox_h
3 
4 #include <QSpinBox>
5 #include <QMap>
6 
7 #include "Pvl.h"
8 
9 namespace Isis {
15  class BandSpinBox : public QSpinBox {
16  Q_OBJECT
17 
18  public:
19  BandSpinBox(QWidget *parent = 0);
20  void setBandBin(Pvl &pvl, const QString &key = "BandNumber");
22  QSize sizeHint() const;
23  QValidator::State validate(QString &input, int &pos) const;
24 
25  public slots:
26  void setKey(QString key);
27  void setKey(int key);
28 
29  protected:
30  QString textFromValue(int val) const;
31  int valueFromText(const QString &text) const;
32 
33  private:
34  int p_bands;
35 
37  QString p_lastKey;
38  QStringList p_keys;
39  };
40 }
41 
42 #endif
QValidator::State validate(QString &input, int &pos) const
returns how valid the value from the spin box is.
Definition: BandSpinBox.cpp:208
Definition: BandSpinBox.h:15
void setKey(QString key)
Sets the key to the provided key.
Definition: BandSpinBox.cpp:93
QString textFromValue(int val) const
Gets the text using p_map.
Definition: BandSpinBox.cpp:133
void setBandBin(Pvl &pvl, const QString &key="BandNumber")
Sets the band bin.
Definition: BandSpinBox.cpp:33
int valueFromText(const QString &text) const
gets the value (int) using p_map.
Definition: BandSpinBox.cpp:157
QSize sizeHint() const
returns a size hint for the spin box
Definition: BandSpinBox.cpp:174
Container for cube-like labels.
Definition: Pvl.h:135
BandSpinBox(QWidget *parent=0)
BandSpinBox constructor.
Definition: BandSpinBox.cpp:13
QStringList BandBinKeys()
returns the list of keys.
Definition: BandSpinBox.cpp:82
Namespace for ISIS/Bullet specific routines.
Definition: Apollo.h:31

U.S. Department of the Interior | U.S. Geological Survey
ISIS | Privacy & Disclaimers | Astrogeology Research Program
To contact us, please post comments and questions on the USGS Astrogeology Discussion Board
To report a bug, or suggest a feature go to: ISIS Github
File Modified: 07/12/2023 23:14:48