File indexing completed on 2024-04-28 04:32:07
0001 /* 0002 * Copyright (C) 2010-2015 by Stephen Allewell 0003 * steve.allewell@gmail.com 0004 * 0005 * This program is free software; you can redistribute it and/or modify 0006 * it under the terms of the GNU General Public License as published by 0007 * the Free Software Foundation; either version 2 of the License, or 0008 * (at your option) any later version. 0009 */ 0010 0011 #ifndef SchemeManager_H 0012 #define SchemeManager_H 0013 0014 #include <QColor> 0015 #include <QList> 0016 #include <QStringList> 0017 0018 #include <KDirWatch> 0019 0020 class FlossScheme; 0021 0022 class SchemeManager : private QObject 0023 { 0024 Q_OBJECT 0025 0026 public: 0027 ~SchemeManager(); 0028 0029 static FlossScheme *createScheme(QString schemeName); 0030 static FlossScheme *readScheme(QString name); 0031 static bool writeScheme(QString name); 0032 static QStringList schemes(); 0033 static FlossScheme *scheme(QString name); 0034 0035 private: 0036 static SchemeManager &self(); 0037 SchemeManager(); 0038 0039 void refresh(); 0040 0041 static SchemeManager *schemeManager; 0042 typedef QMap<QString, QColor> CalibratedColor; 0043 QList<FlossScheme *> m_flossSchemes; 0044 }; 0045 0046 #endif // SchemeManager_H