gameui

view src/theme.h @ 4:e0916bb20b7f

changed the name to goatkit
author John Tsiombikas <nuclear@member.fsf.org>
date Fri, 21 Mar 2014 21:45:37 +0200
parents f1014234dece
children 5a84873185ff
line source
1 #ifndef THEME_H_
2 #define THEME_H_
4 #include <string>
5 #include <map>
7 namespace goatkit {
9 class Widget;
11 typedef void (*widget_draw_func)(const Widget*);
13 void default_draw_func(const Widget *w);
15 class Theme {
16 private:
17 void *so;
18 std::map<std::string, widget_draw_func> draw_func;
20 public:
21 Theme();
22 ~Theme();
24 bool load(const char *name);
26 widget_draw_func get_draw_func(const char *type) const;
27 };
29 extern Theme *theme; // the current theme
31 } // namespace goatkit
33 #endif // THEME_H_