dtor first
[personal-kdebase.git] / workspace / ksysguard / gui / SensorDisplayLib / MultiMeter.h
bloba7b4e855f538171e89923447725403bbddcac30e
1 /*
2 KSysGuard, the KDE System Guard
4 Copyright (c) 1999 - 2001 Chris Schlaeger <cs@kde.org>
6 This program is free software; you can redistribute it and/or
7 modify it under the terms of the GNU General Public
8 License version 2 or at your option version 3 as published by
9 the Free Software Foundation.
11 This program is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU General Public License for more details.
16 You should have received a copy of the GNU General Public License
17 along with this program; if not, write to the Free Software
18 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
22 #ifndef _MultiMeter_h_
23 #define _MultiMeter_h_
25 #include <SensorDisplay.h>
27 class QLCDNumber;
29 class MultiMeter : public KSGRD::SensorDisplay
31 Q_OBJECT
33 public:
34 MultiMeter(QWidget* parent, const QString& title, SharedSettings *workSheetSettings);
35 virtual ~MultiMeter()
39 bool addSensor(const QString& hostName, const QString& sensorName,
40 const QString& sensorType, const QString& sensorDescr);
41 void answerReceived(int id, const QList<QByteArray>& answerlist);
42 bool restoreSettings(QDomElement& element);
43 bool saveSettings(QDomDocument& doc, QDomElement& element);
45 virtual bool hasSettingsDialog() const
47 return true;
50 void configureSettings();
52 public Q_SLOTS:
53 void applyStyle();
55 private:
56 void setDigitColor(const QColor&);
57 void setBackgroundColor(const QColor&);
59 QLCDNumber* mLcd;
60 QColor mNormalDigitColor;
61 QColor mAlarmDigitColor;
62 QColor mBackgroundColor;
64 bool mIsFloat;
66 bool mLowerLimitActive;
67 double mLowerLimit;
68 bool mUpperLimitActive;
69 double mUpperLimit;
72 #endif