]> Dogcows Code - chaz/openbox/blob - render/theme.h
22bf7e10b162727610405e1bb7d879dbbbd148a2
[chaz/openbox] / render / theme.h
1 /* -*- indent-tabs-mode: nil; tab-width: 4; c-basic-offset: 4; -*-
2
3 theme.h for the Openbox window manager
4 Copyright (c) 2006 Mikael Magnusson
5 Copyright (c) 2003 Ben Jansens
6
7 This program is free software; you can redistribute it and/or modify
8 it under the terms of the GNU General Public License as published by
9 the Free Software Foundation; either version 2 of the License, or
10 (at your option) any later version.
11
12 This program is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 GNU General Public License for more details.
16
17 See the COPYING file for a copy of the GNU General Public License.
18 */
19
20 #ifndef __theme_h
21 #define __theme_h
22
23 #include "render.h"
24
25 G_BEGIN_DECLS
26
27 typedef struct _RrTheme RrTheme;
28
29 struct _RrTheme {
30 gchar *path;
31 gchar *name;
32
33 const RrInstance *inst;
34
35 /* style settings - optional decor */
36 gboolean show_handle;
37
38 /* style settings - geometry */
39 gint padding;
40 gint handle_height;
41 gint bwidth;
42 gint cbwidth;
43 gint label_height;
44 gint title_height;
45 gint menu_title_height;
46 gint button_size;
47 gint grip_width;
48 gint menu_overlap;
49
50 /* style settings - colors */
51 RrColor *b_color;
52 RrColor *cb_focused_color;
53 RrColor *cb_unfocused_color;
54 RrColor *title_focused_color;
55 RrColor *title_unfocused_color;
56 RrColor *titlebut_disabled_focused_color;
57 RrColor *titlebut_disabled_unfocused_color;
58 RrColor *titlebut_hover_focused_color;
59 RrColor *titlebut_hover_unfocused_color;
60 RrColor *titlebut_toggled_focused_color;
61 RrColor *titlebut_toggled_unfocused_color;
62 RrColor *titlebut_focused_pressed_color;
63 RrColor *titlebut_unfocused_pressed_color;
64 RrColor *titlebut_focused_unpressed_color;
65 RrColor *titlebut_unfocused_unpressed_color;
66 RrColor *menu_title_color;
67 RrColor *menu_color;
68 RrColor *menu_disabled_color;
69 RrColor *menu_selected_color;
70
71 /* style settings - fonts */
72 gint win_font_height;
73 RrFont *win_font_focused;
74 RrFont *win_font_unfocused;
75 gint menu_title_font_height;
76 RrFont *menu_title_font;
77 gint menu_font_height;
78 RrFont *menu_font;
79
80 /* style settings - pics */
81 RrPixel32 *def_win_icon; /* 48x48 RGBA */
82
83 /* style settings - masks */
84 RrPixmapMask *max_mask;
85 RrPixmapMask *max_toggled_mask;
86 RrPixmapMask *max_hover_mask;
87 RrPixmapMask *max_disabled_mask;
88 RrPixmapMask *max_pressed_mask;
89 RrPixmapMask *iconify_mask;
90 RrPixmapMask *iconify_hover_mask;
91 RrPixmapMask *iconify_disabled_mask;
92 RrPixmapMask *iconify_pressed_mask;
93 RrPixmapMask *desk_mask;
94 RrPixmapMask *desk_toggled_mask;
95 RrPixmapMask *desk_hover_mask;
96 RrPixmapMask *desk_disabled_mask;
97 RrPixmapMask *desk_pressed_mask;
98 RrPixmapMask *shade_mask;
99 RrPixmapMask *shade_toggled_mask;
100 RrPixmapMask *shade_hover_mask;
101 RrPixmapMask *shade_disabled_mask;
102 RrPixmapMask *shade_pressed_mask;
103 RrPixmapMask *close_mask;
104 RrPixmapMask *close_hover_mask;
105 RrPixmapMask *close_disabled_mask;
106 RrPixmapMask *close_pressed_mask;
107
108 RrPixmapMask *menu_bullet_mask; /* submenu pointer */
109 RrPixmapMask *menu_toggle_mask; /* menu boolean */
110
111 /* global appearances */
112 RrAppearance *a_disabled_focused_max;
113 RrAppearance *a_disabled_unfocused_max;
114 RrAppearance *a_hover_focused_max;
115 RrAppearance *a_hover_unfocused_max;
116 RrAppearance *a_toggled_focused_max;
117 RrAppearance *a_toggled_unfocused_max;
118 RrAppearance *a_focused_unpressed_max;
119 RrAppearance *a_focused_pressed_max;
120 RrAppearance *a_unfocused_unpressed_max;
121 RrAppearance *a_unfocused_pressed_max;
122 RrAppearance *a_disabled_focused_close;
123 RrAppearance *a_disabled_unfocused_close;
124 RrAppearance *a_hover_focused_close;
125 RrAppearance *a_hover_unfocused_close;
126 RrAppearance *a_focused_unpressed_close;
127 RrAppearance *a_focused_pressed_close;
128 RrAppearance *a_unfocused_unpressed_close;
129 RrAppearance *a_unfocused_pressed_close;
130 RrAppearance *a_disabled_focused_desk;
131 RrAppearance *a_disabled_unfocused_desk;
132 RrAppearance *a_hover_focused_desk;
133 RrAppearance *a_hover_unfocused_desk;
134 RrAppearance *a_toggled_focused_desk;
135 RrAppearance *a_toggled_unfocused_desk;
136 RrAppearance *a_focused_unpressed_desk;
137 RrAppearance *a_focused_pressed_desk;
138 RrAppearance *a_unfocused_unpressed_desk;
139 RrAppearance *a_unfocused_pressed_desk;
140 RrAppearance *a_disabled_focused_shade;
141 RrAppearance *a_disabled_unfocused_shade;
142 RrAppearance *a_hover_focused_shade;
143 RrAppearance *a_hover_unfocused_shade;
144 RrAppearance *a_toggled_focused_shade;
145 RrAppearance *a_toggled_unfocused_shade;
146 RrAppearance *a_focused_unpressed_shade;
147 RrAppearance *a_focused_pressed_shade;
148 RrAppearance *a_unfocused_unpressed_shade;
149 RrAppearance *a_unfocused_pressed_shade;
150 RrAppearance *a_disabled_focused_iconify;
151 RrAppearance *a_disabled_unfocused_iconify;
152 RrAppearance *a_hover_focused_iconify;
153 RrAppearance *a_hover_unfocused_iconify;
154 RrAppearance *a_focused_unpressed_iconify;
155 RrAppearance *a_focused_pressed_iconify;
156 RrAppearance *a_unfocused_unpressed_iconify;
157 RrAppearance *a_unfocused_pressed_iconify;
158 RrAppearance *a_focused_grip;
159 RrAppearance *a_unfocused_grip;
160 RrAppearance *a_focused_title;
161 RrAppearance *a_unfocused_title;
162 RrAppearance *a_focused_label;
163 RrAppearance *a_unfocused_label;
164 /* always parentrelative, so no focused/unfocused */
165 RrAppearance *a_icon;
166 RrAppearance *a_focused_handle;
167 RrAppearance *a_unfocused_handle;
168 RrAppearance *a_menu_title;
169 RrAppearance *a_menu;
170 RrAppearance *a_menu_normal;
171 RrAppearance *a_menu_disabled;
172 RrAppearance *a_menu_selected;
173 RrAppearance *a_menu_text_normal;
174 RrAppearance *a_menu_text_disabled;
175 RrAppearance *a_menu_text_selected;
176 RrAppearance *a_menu_bullet_normal;
177 RrAppearance *a_menu_bullet_selected;
178 RrAppearance *a_clear; /* clear with no texture */
179 RrAppearance *a_clear_tex; /* clear with a texture */
180
181 RrAppearance *app_hilite_bg;
182 RrAppearance *app_unhilite_bg;
183 RrAppearance *app_hilite_fg; /* never parent relative */
184 RrAppearance *app_unhilite_fg; /* never parent relative */
185 RrAppearance *app_hilite_label; /* can be parent relative */
186 RrAppearance *app_unhilite_label; /* can be parent relative */
187
188 };
189
190 /*! The font values are all optional. If a NULL is used for any of them, then
191 the default font will be used. */
192 RrTheme* RrThemeNew(const RrInstance *inst, gchar *theme,
193 RrFont *active_window_font, RrFont *inactive_window_font,
194 RrFont *menu_title_font, RrFont *menu_item_font);
195 void RrThemeFree(RrTheme *theme);
196
197 G_END_DECLS
198
199 #endif
This page took 0.039864 seconds and 3 git commands to generate.