diff --git a/client.c b/client.c index fc01f978..d03a5b85 100644 --- a/client.c +++ b/client.c @@ -350,7 +350,7 @@ client_manage(xcb_window_t w, xcb_get_geometry_reply_t *wgeom, int screen) bool rettrans, retloadprops; uint32_t config_win_val; Tag *tag; - Rule *rule; + rule_t *rule; xcb_size_hints_t *u_size_hints; c = p_new(Client, 1); diff --git a/config.c b/config.c index bb469533..0b63a350 100644 --- a/config.c +++ b/config.c @@ -486,7 +486,7 @@ config_parse(const char *confpatharg) cfg_t *cfg, *cfg_rules, *cfg_keys, *cfg_mouse, *cfgsectmp; int ret, screen, i; char *confpath; - Rule *rule = NULL; + rule_t *rule = NULL; FILE *defconfig = NULL; if(confpatharg) @@ -533,7 +533,7 @@ config_parse(const char *confpatharg) rule_list_init(&globalconf.rules); for(i = cfg_size(cfg_rules, "rule") - 1; i >= 0; i--) { - rule = p_new(Rule, 1); + rule = p_new(rule_t, 1); cfgsectmp = cfg_getnsec(cfg_rules, "rule", i); rule->prop_r = rules_compile_regex(cfg_getstr(cfgsectmp, "name")); rule->tags_r = rules_compile_regex(cfg_getstr(cfgsectmp, "tags")); diff --git a/rules.c b/rules.c index ef783a46..9f087611 100644 --- a/rules.c +++ b/rules.c @@ -42,7 +42,7 @@ rules_compile_regex(char *val) } bool -tag_match_rule(Tag *t, Rule *r) +tag_match_rule(Tag *t, rule_t *r) { regmatch_t tmp; @@ -52,10 +52,10 @@ tag_match_rule(Tag *t, Rule *r) return false; } -Rule * +rule_t * rule_matching_client(Client *c) { - Rule *r; + rule_t *r; char *prop = NULL, buf[512]; regmatch_t tmp; ssize_t len; diff --git a/rules.h b/rules.h index d6f1c284..f1fcaaff 100644 --- a/rules.h +++ b/rules.h @@ -27,10 +27,10 @@ #define RULE_NOSCREEN -1 regex_t * rules_compile_regex(char *); -bool tag_match_rule(Tag *, Rule *); -Rule * rule_matching_client(Client *); +bool tag_match_rule(Tag *, rule_t *); +rule_t * rule_matching_client(Client *); -DO_SLIST(Rule, rule, p_delete) +DO_SLIST(rule_t, rule, p_delete) #endif // vim: filetype=c:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:encoding=utf-8:textwidth=80 diff --git a/structs.h b/structs.h index da4dbd60..a1a02661 100644 --- a/structs.h +++ b/structs.h @@ -63,8 +63,8 @@ typedef struct } titlebar_t; /** Rule type */ -typedef struct Rule Rule; -struct Rule +typedef struct rule_t rule_t; +struct rule_t { char *icon; char *xprop; @@ -77,7 +77,7 @@ struct Rule regex_t *tags_r; regex_t *xpropval_r; /** Next and previous rules */ - Rule *prev, *next; + rule_t *prev, *next; }; /** Key bindings */ @@ -347,7 +347,7 @@ struct AwesomeConf /** Screens info */ ScreensInfo *screens_info; /** Rules list */ - Rule *rules; + rule_t *rules; /** Keys bindings list */ Key *keys; /** Mouse bindings list */ diff --git a/tag.c b/tag.c index a7a5cad8..f6302a8e 100644 --- a/tag.c +++ b/tag.c @@ -174,7 +174,7 @@ tag_client_with_current_selected(Client *c) * \param r the rule */ void -tag_client_with_rule(Client *c, Rule *r) +tag_client_with_rule(Client *c, rule_t *r) { Tag *tag; bool matched = false; diff --git a/tag.h b/tag.h index fc65f7a0..c1d457ed 100644 --- a/tag.h +++ b/tag.h @@ -35,7 +35,7 @@ Tag ** tags_get_current(int); void tag_client(Client *, Tag *); void untag_client(Client *, Tag *); bool is_client_tagged(Client *, Tag *); -void tag_client_with_rule(Client *, Rule *r); +void tag_client_with_rule(Client *, rule_t *r); void tag_client_with_current_selected(Client *); void tag_view_only_byindex(int, int); void tag_append_to_screen(Tag *, int); diff --git a/widgets/focusicon.c b/widgets/focusicon.c index 71860cc7..5848fb8c 100644 --- a/widgets/focusicon.c +++ b/widgets/focusicon.c @@ -34,7 +34,7 @@ focusicon_draw(Widget *widget, DrawCtx *ctx, int offset, int used __attribute__ ((unused))) { area_t area; - Rule* r; + rule_t *r; Client *sel = focus_get_current_client(widget->statusbar->screen); NetWMIcon *icon; diff --git a/widgets/tasklist.c b/widgets/tasklist.c index 42d090e7..a482ddad 100644 --- a/widgets/tasklist.c +++ b/widgets/tasklist.c @@ -75,7 +75,7 @@ tasklist_draw(Widget *widget, DrawCtx *ctx, int offset, int used) { Client *c; Data *d = widget->data; - Rule *r; + rule_t *r; area_t area; style_t style; int n = 0, i = 0, box_width = 0, icon_width = 0, box_width_rest = 0;