2 * config.h - configuration management header
4 * Copyright © 2007-2008 Julien Danjou <julien@danjou.info>
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; either version 2 of the License, or
9 * (at your option) any later version.
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
16 * You should have received a copy of the GNU General Public License along
17 * with this program; if not, write to the Free Software Foundation, Inc.,
18 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
22 #ifndef AWESOME_CONFIG_H
23 #define AWESOME_CONFIG_H
29 /** Bar possible position */
41 { ColBorder
, ColFG
, ColBG
, ColLast
};
44 { CurNormal
, CurResize
, CurMove
, CurLast
}; /* cursor */
46 typedef struct Rule Rule
;
60 typedef struct AwesomeConf AwesomeConf
;
62 typedef struct Layout Layout
;
66 LayoutArrange
*arrange
;
70 typedef struct Key Key
;
80 typedef struct Button Button
;
91 typedef struct Widget Widget
;
92 typedef struct Statusbar Statusbar
;
98 int (*draw
)(Widget
*, DrawCtx
*, int, int);
99 /** Update function */
100 void (*tell
)(Widget
*, char *);
101 /** ButtonPressedEvent handler */
102 void (*button_press
)(Widget
*, XButtonPressedEvent
*);
104 Statusbar
*statusbar
;
107 /** Misc private data */
109 /** True if user supplied coords */
110 Bool user_supplied_x
;
111 Bool user_supplied_y
;
114 /** Buttons bindings */
125 /** Statusbar name */
131 /** Layout txt width */
133 /** Default position */
145 /** Next statusbar */
149 typedef struct Client Client
;
154 /** Window geometry */
156 /** Real window geometry for floating */
158 int basew
, baseh
, incw
, inch
, maxw
, maxh
, minw
, minh
;
159 int minax
, maxax
, minay
, maxay
;
161 int border
, oldborder
;
162 /** Has urgency hint */
164 /** Store previous floating state before maximizing */
166 /** True if the window is floating */
168 /** True if the window is fixed */
170 /** True if the window is maximized */
172 /** True if the client must be skipped from client list */
174 /** True if the client must be skipped from task bar client list */
178 /** Previous client */
180 /** Window of the client */
182 /** Client logical screen */
186 typedef struct FocusList FocusList
;
194 typedef struct Tag Tag
;
199 /** True if selected */
201 /** True if was selected before selecting others tags */
203 /** Current tag layout */
205 /** Master width factor */
207 /** Number of master windows */
209 /** Number of columns in tile layout */
215 /** TagClientLink type */
216 typedef struct TagClientLink TagClientLink
;
227 /** Padding at top */
229 /** Padding at bottom */
231 /** Padding at left */
233 /** Padding at right */
239 /** Number of pixels to snap windows */
243 /** Transparency of unfocused clients */
244 int opacity_unfocused
;
245 /** Focus move pointer */
246 Bool focus_move_pointer
;
247 /** Allow floats to be lowered on focus change */
248 Bool allow_lower_floats
;
249 /** Respect resize hints */
251 /** Sloppy focus: focus follow mouse */
253 /** True if new clients should become master */
254 Bool new_become_master
;
256 XColor colors_normal
[ColLast
];
257 /** Selected colors */
258 XColor colors_selected
[ColLast
];
259 /** Urgency colors */
260 XColor colors_urgent
[ColLast
];
266 Statusbar
*statusbar
;
273 /** Main configuration structure */
278 /** Logical screens */
282 /** Keys bindings list */
284 /** Mouse bindings list */
291 unsigned int numlockmask
;
292 /** Check for XShape extension */
294 /** Check for XRandR extension */
297 Cursor cursor
[CurLast
];
300 /** Path to config file */
302 /** Selected clients on this tag */
304 /** Link between tags and clients */
305 TagClientLink
*tclink
;
308 void config_parse(const char *);
311 // vim: filetype=c:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:encoding=utf-8:textwidth=80