summaryrefslogtreecommitdiff
path: root/theme.h
diff options
context:
space:
mode:
Diffstat (limited to 'theme.h')
-rw-r--r--theme.h35
1 files changed, 35 insertions, 0 deletions
diff --git a/theme.h b/theme.h
new file mode 100644
index 0000000..36ba3d1
--- /dev/null
+++ b/theme.h
@@ -0,0 +1,35 @@
+/*
+ * $Id: theme.h,v 1.1 2004/06/02 20:43:05 lordjaxom Exp $
+ */
+
+#ifndef VDR_TEXT2SKIN_THEME_H
+#define VDR_TEXT2SKIN_THEME_H
+
+#include "common.h"
+#include "file.h"
+#include <vdr/themes.h>
+
+class cText2SkinTheme: public cText2SkinFile {
+private:
+ cTheme mTheme;
+ map<string,int> mMap;
+
+protected:
+ bool Parse(const char *Text);
+
+public:
+ cText2SkinTheme(const char *Skin);
+ virtual ~cText2SkinTheme();
+
+ cTheme *Theme(void) { return &mTheme; }
+ tColor Color(const string &Name);
+};
+
+inline tColor cText2SkinTheme::Color(const string &Name) {
+ if (mMap.find(Name) != mMap.end())
+ return mTheme.Color(mMap[Name]);
+ else
+ return 0x00000000;
+}
+
+#endif // VDR_TEXT2SKIN_THEME_H