source: flair-src/trunk/lib/FlairCore/src/SpinBox.h@ 13

Last change on this file since 13 was 2, checked in by Sanahuja Guillaume, 9 years ago

flaircore

File size: 2.4 KB
Line 
1// %flair:license{
2// This file is part of the Flair framework distributed under the
3// CECILL-C License, Version 1.0.
4// %flair:license}
5/*!
6 * \file SpinBox.h
7 * \brief Class displaying a QSpinBox on the ground station
8 * \author Guillaume Sanahuja, Copyright Heudiasyc UMR UTC/CNRS 7253
9 * \date 2011/10/07
10 * \version 4.0
11 */
12
13#ifndef SPINBOX_H
14#define SPINBOX_H
15
16#include <Box.h>
17
18namespace flair
19{
20namespace gui
21{
22
23 class LayoutPosition;
24
25 /*! \class SpinBox
26 *
27 * \brief Class displaying a QSpinBox on the ground station
28 *
29 */
30 class SpinBox : public Box
31 {
32 public:
33 /*!
34 * \brief Constructor
35 *
36 * Construct a QSpinBox at given position. \n
37 * The QSpinBox is saturated to min and max values.
38 *
39 * \param position position to display the QSpinBox
40 * \param name name
41 * \param min minimum value
42 * \param max maximum value
43 * \param step step
44 * \param default_value default value if not in the xml config file
45 */
46 SpinBox(const LayoutPosition* position,std::string name,int min,int max,int step,int default_value=0);/*!
47
48 * \brief Constructor
49 *
50 * Construct a QSpinBox at given position. \n
51 * The QSpinBox is saturated to min and max values.
52 *
53 * \param position position to display the QSpinBox
54 * \param name name
55 * \param suffix suffix for the value (eg unit)
56 * \param min minimum value
57 * \param max maximum value
58 * \param step step
59 * \param default_value default value if not in the xml config file
60 */
61 SpinBox(const LayoutPosition* position,std::string name,std::string suffix,int min,int max,int step,int default_value=0);
62
63 /*!
64 * \brief Destructor
65 *
66 */
67 ~SpinBox();
68
69 /*!
70 * \brief Value
71 *
72 * \return value
73 */
74 int Value(void) const;
75
76 private:
77 /*!
78 * \brief XmlEvent from ground station
79 *
80 * Reimplemented from Widget.
81 *
82 */
83 void XmlEvent(void);
84
85 int box_value;
86 };
87
88} // end namespace gui
89} // end namespace flair
90
91#endif // SPINBOX_H
Note: See TracBrowser for help on using the repository browser.