Chameleon

Chameleon Svn Source Tree

Root/branches/xZenu/src/util/doxygen/addon/doxywizard/inputint.h

Source at commit 1396 created 12 years 10 months ago.
By ifabio, Add Bosnian.lproj and sync with trunk
1/******************************************************************************
2 *
3 *
4 *
5 * Copyright (C) 1997-2011 by Dimitri van Heesch.
6 *
7 * Permission to use, copy, modify, and distribute this software and its
8 * documentation under the terms of the GNU General Public License is hereby
9 * granted. No representations are made about the suitability of this software
10 * for any purpose. It is provided "as is" without express or implied warranty.
11 * See the GNU General Public License for more details.
12 *
13 */
14
15#ifndef _INPUTINT_H
16#define _INPUTINT_H
17
18#include "input.h"
19#include <QObject>
20
21class QGridLayout;
22class QLabel;
23class QSpinBox;
24
25class InputInt : public QObject, public Input
26{
27 Q_OBJECT
28
29 public:
30 InputInt( QGridLayout *layout,int &row,
31 const QString &id, int defVal,
32 int minVal, int maxVal,
33 const QString &docs );
34 ~InputInt(){};
35
36 // Input
37 QVariant &value();
38 void update();
39 Kind kind() const { return Int; }
40 QString docs() const { return m_docs; }
41 QString id() const { return m_id; }
42 void addDependency(Input *) { Q_ASSERT(false); }
43 void setEnabled(bool);
44 void updateDependencies() {}
45 void writeValue(QTextStream &t,QTextCodec *codec);
46
47 public slots:
48 void reset();
49 void setValue(int val);
50
51 private slots:
52 void help();
53
54 signals:
55 void changed();
56 void showHelp(Input *);
57
58 private:
59 QLabel *m_lab;
60 QSpinBox *m_sp;
61 int m_val;
62 int m_default;
63 int m_minVal;
64 int m_maxVal;
65 QVariant m_value;
66 QString m_docs;
67 QString m_id;
68};
69
70#endif
71

Archive Download this file

Revision: 1396