From 00ce50bf43b34ef9a66bc2ba0c64ba3d965ff6ea Mon Sep 17 00:00:00 2001 From: Mitchell Riedstra Date: Tue, 31 Jan 2023 08:52:01 -0500 Subject: Allow regexp matching for window title and class --- dwm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'dwm.c') diff --git a/dwm.c b/dwm.c index f9719ac..4b107d1 100644 --- a/dwm.c +++ b/dwm.c @@ -306,8 +306,8 @@ applyrules(Client *c) for (i = 0; i < LENGTH(rules); i++) { r = &rules[i]; - if ((!r->title || strstr(c->name, r->title)) - && (!r->class || strstr(class, r->class)) + if ((!r->title || reMatch(r->title, c->name) == 0) + && (!r->class || reMatch(r->class, class) == 0) && (!r->instance || strstr(instance, r->instance))) { c->isfloating = r->isfloating; -- cgit v1.2.3