prefsettings.h
00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022 #ifndef PREFSETTINGS_H
00023 #define PREFSETTINGS_H
00024
00025 #include <qobject.h>
00026 #include <qcolor.h>
00027 #include <qfont.h>
00028 #include <qdatetime.h>
00029 class QWidget;
00030
00031 #include "recurrenceedit.h"
00032
00033
00034
00035 class Settings : public QObject
00036 {
00037 Q_OBJECT
00038 public:
00039 Settings(QWidget* parent);
00040
00041 QColor defaultBgColour() const { return mDefaultBgColour; }
00042 const QFont& messageFont() const { return mMessageFont; }
00043 bool runInSystemTray() const { return mRunInSystemTray; }
00044 bool disableAlarmsIfStopped() const { return mDisableAlarmsIfStopped; }
00045 bool autostartTrayIcon() const { return mAutostartTrayIcon; }
00046 bool confirmAlarmDeletion() const { return mConfirmAlarmDeletion; }
00047 int daemonTrayCheckInterval() const { return mDaemonTrayCheckInterval; }
00048 const QTime& startOfDay() const { return mStartOfDay; }
00049 bool startOfDayChanged() const { return mStartOfDayChanged; }
00050 bool defaultLateCancel() const { return mDefaultLateCancel; }
00051 bool defaultConfirmAck() const { return mDefaultConfirmAck; }
00052 bool defaultBeep() const { return mDefaultBeep; }
00053 bool defaultEmailBcc() const { return mDefaultEmailBcc; }
00054 RecurrenceEdit::RepeatType
00055 defaultRecurPeriod() const { return mDefaultRecurPeriod; }
00056
00057 void loadSettings();
00058 void saveSettings(bool syncToDisc = true);
00059 void updateStartOfDayCheck();
00060 void emitSettingsChanged();
00061
00062 static const QColor default_defaultBgColour;
00063 static const QFont default_messageFont;
00064 static const QTime default_startOfDay;
00065 static const bool default_runInSystemTray;
00066 static const bool default_disableAlarmsIfStopped;
00067 static const bool default_autostartTrayIcon;
00068 static const bool default_confirmAlarmDeletion;
00069 static const int default_daemonTrayCheckInterval;
00070 static const bool default_defaultLateCancel;
00071 static const bool default_defaultConfirmAck;
00072 static const bool default_defaultBeep;
00073 static const bool default_defaultEmailBcc;
00074 static const RecurrenceEdit::RepeatType
00075 default_defaultRecurPeriod;
00076 bool mRunInSystemTray;
00077 bool mDisableAlarmsIfStopped;
00078 bool mAutostartTrayIcon;
00079 bool mConfirmAlarmDeletion;
00080 int mDaemonTrayCheckInterval;
00081 QTime mStartOfDay;
00082 QColor mDefaultBgColour;
00083 QFont mMessageFont;
00084
00085 bool mDefaultLateCancel;
00086 bool mDefaultConfirmAck;
00087 bool mDefaultBeep;
00088 bool mDefaultEmailBcc;
00089 RecurrenceEdit::RepeatType mDefaultRecurPeriod;
00090 bool mStartOfDayChanged;
00091
00092 signals:
00093 void settingsChanged();
00094 private:
00095 int startOfDayCheck() const;
00096 };
00097
00098 #endif // PREFSETTINGS_H
This file is part of the documentation for kdelibs Version 3.1.4.