From 28621f679328965ab9c4ed5672c610b0f429560c Mon Sep 17 00:00:00 2001 From: Suleyman Farajli Date: Sat, 17 Aug 2024 13:27:18 +0400 Subject: moveresize patched and keybinds changed --- dwm.c | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) (limited to 'dwm.c') diff --git a/dwm.c b/dwm.c index 29b279b..8f7b775 100644 --- a/dwm.c +++ b/dwm.c @@ -184,6 +184,7 @@ static void mappingnotify(XEvent *e); static void maprequest(XEvent *e); static void motionnotify(XEvent *e); static void movemouse(const Arg *arg); +static void moveresize(const Arg *arg); static Client *nexttiled(Client *c); static void pop(Client *c); static void propertynotify(XEvent *e); @@ -277,6 +278,22 @@ static Window root, wmcheckwin; struct NumTags { char limitexceeded[LENGTH(tags) > 31 ? -1 : 1]; }; /* function implementations */ + +static void +moveresize(const Arg *arg) +{ + XEvent ev; + Monitor *m = selmon; + if(!(m->sel && arg && arg->v && m->sel->isfloating)) + return; + resize(m->sel, m->sel->x + ((int *)arg->v)[0], + m->sel->y + ((int *)arg->v)[1], + m->sel->w + ((int *)arg->v)[2], + m->sel->h + ((int *)arg->v)[3], + True); + while(XCheckMaskEvent(dpy, EnterWindowMask, &ev)); +} + void applyrules(Client *c) { -- cgit v1.2.3