X-Git-Url: https://jasonwoof.com/gitweb/?a=blobdiff_plain;f=dwm.c;h=9dd501a6ed836194fa07f7d550fda2ee6408eac1;hb=721b208478a907e21193a738e8c3ed3f91048c1a;hp=ef241a3c04f65e064757717a87d4752f994c4606;hpb=6229ed20c2af107305eccb8b536afd8620443647;p=dwm.git diff --git a/dwm.c b/dwm.c index ef241a3..9dd501a 100644 --- a/dwm.c +++ b/dwm.c @@ -261,9 +261,9 @@ applyrules(Client *c) { XGetClassHint(dpy, c->win, &ch); for(i = 0; i < LENGTH(rules); i++) { r = &rules[i]; - if((r->title && strstr(c->name, r->title)) - || (ch.res_class && r->class && strstr(ch.res_class, r->class)) - || (ch.res_name && r->instance && strstr(ch.res_name, r->instance))) + if((!r->title || strstr(c->name, r->title)) + && (!ch.res_class || !r->class || strstr(ch.res_class, r->class)) + && (!ch.res_name || !r->instance || strstr(ch.res_name, r->instance))) { c->isfloating = r->isfloating; if(r->tag) {