summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLuke Smith <luke@lukesmith.xyz>2021-03-12 12:55:44 -0500
committerLuke Smith <luke@lukesmith.xyz>2021-03-12 12:55:44 -0500
commit203f90bfb2d8146b61882310017a6a4fe3f13849 (patch)
treebc3b9d01d8a0dad23006fd689ec2e03132e08d00
parent3eb52c30c6f547114cba6917de5a08d1925c4d56 (diff)
always center
-rw-r--r--dwm.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/dwm.c b/dwm.c
index 93d2423..929f878 100644
--- a/dwm.c
+++ b/dwm.c
@@ -1229,6 +1229,8 @@ manage(Window w, XWindowAttributes *wa)
updatewindowtype(c);
updatesizehints(c);
updatewmhints(c);
+ c->x = c->mon->mx + (c->mon->mw - WIDTH(c)) / 2;
+ c->y = c->mon->my + (c->mon->mh - HEIGHT(c)) / 2;
XSelectInput(dpy, w, EnterWindowMask|FocusChangeMask|PropertyChangeMask|StructureNotifyMask);
grabbuttons(c, 0);
if (!c->isfloating)