#include <map>
#include <string>
#include <msp/datafile/objectloader.h>
-
-struct Color
-{
- unsigned r;
- unsigned g;
- unsigned b;
-
- Color();
- Color(unsigned, unsigned, unsigned);
-};
-
+#include "appearance.h"
+#include "color.h"
class Theme
{
Loader(Theme &);
private:
+ void appearance(const std::string &);
void color(const std::string &, unsigned, unsigned, unsigned);
+ void color_alpha(const std::string &, unsigned, unsigned, unsigned, unsigned);
};
private:
typedef std::map<std::string, Color> ColorMap;
+ typedef std::map<std::string, Appearance> AppearanceMap;
ColorMap colors;
unsigned base_font_size;
+ AppearanceMap appearances;
public:
Theme();
void set_base_font_size(unsigned);
unsigned get_base_font_size() const { return base_font_size; }
+
+ void set_appearance(const std::string &, const Appearance &);
+ const Appearance &get_appearance(const std::string &) const;
+ const Appearance *find_appearance(const std::string &) const;
};
#endif