itom  4.1.0
ColorCombo.h
1 // *************************************************************************************************
2 //
3 // QPropertyEditor v 0.3
4 //
5 // --------------------------------------
6 // Copyright (C) 2007 Volker Wiendl
7 // Acknowledgements to Roman alias banal from qt-apps.org for the Enum enhancement
8 //
9 //
10 // The QPropertyEditor Library is free software; you can redistribute it and/or modify
11 // it under the terms of the GNU Lesser General Public License as published by the Free Software
12 // Foundation; either version 2 of the License, or (at your option) any later
13 // version.
14 //
15 // This program is distributed in the hope that it will be useful, but WITHOUT
16 // ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
17 // FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
18 //
19 // You should have received a copy of the GNU Lesser General Public License along with
20 // this program; if not, write to the Free Software Foundation, Inc., 59 Temple
21 // Place - Suite 330, Boston, MA 02111-1307, USA, or go to
22 // http://www.gnu.org/copyleft/lesser.txt.
23 //
24 // *************************************************************************************************
25 
26 #ifndef COLORCOMBO_H_
27 #define COLORCOMBO_H_
28 
29 #include <qcombobox.h>
30 
31 class ColorCombo : public QComboBox
32 {
33  Q_OBJECT
34 public:
35  ColorCombo(QWidget* parent = 0);
36  virtual ~ColorCombo();
37 
38  QColor color() const;
39  void setColor(QColor c);
40 
41 signals:
43  void colorChanged(QColor c);
44 
45 private slots:
46  void currentChanged(int index);
47 
48 private:
49  QColor m_init;
50 
51 };
52 #endif
void colorChanged(QColor c)
Definition: ColorCombo.h:31