From 42a3e4ae858e11aeb53d6c3c5826aaf08e04011a Mon Sep 17 00:00:00 2001 From: Alex Selimov Date: Fri, 5 Sep 2025 23:46:36 -0400 Subject: [PATCH 1/3] Remove unneeded key binds --- config.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/config.h b/config.h index c05101f..2345860 100644 --- a/config.h +++ b/config.h @@ -170,7 +170,6 @@ static Key keys[] = { {MODKEY, XK_t, setlayout, {.v = &layouts[0]}}, {MODKEY, XK_f, setlayout, {.v = &layouts[1]}}, {MODKEY, XK_m, setlayout, {.v = &layouts[2]}}, - {MODKEY, XK_c, setlayout, {.v = &layouts[3]}}, {MODKEY, XK_space, setlayout, {0}}, {MODKEY | ShiftMask, XK_space, togglefloating, {0}}, {MODKEY, XK_comma, focusmon, {.i = -1}}, @@ -200,7 +199,7 @@ static Button buttons[] = { {ClkWinTitle, 0, Button2, zoom, {0}}, {ClkStatusText, 0, Button2, spawn, {.v = termcmd}}, {ClkClientWin, MODKEY, Button1, movemouse, {0}}, - {ClkClientWin, MODKEY, Button2, togglefloating, {0}}, + // {ClkClientWin, MODKEY, Button2, togglefloating, {0}}, {ClkClientWin, MODKEY, Button3, resizemouse, {0}}, {ClkTagBar, 0, Button1, view, {0}}, {ClkTagBar, 0, Button3, toggleview, {0}}, From 94232212fa711fcf3702f315e85cedf384ba41e7 Mon Sep 17 00:00:00 2001 From: Alex Selimov Date: Mon, 6 Oct 2025 19:16:55 -0400 Subject: [PATCH 2/3] Update to ghostty for terminal --- config.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/config.h b/config.h index 2345860..a94fca4 100644 --- a/config.h +++ b/config.h @@ -99,6 +99,7 @@ static const Rule rules[] = { {"Python3", NULL, NULL, 0, 1, 0, 1, -1}, //{ "" , NULL , NULL , 0 , 1 , 0 , 1 , -1 } , {"St", NULL, NULL, 0, 0, 1, 0, -1}, + {"ghostty", NULL, NULL, 0, 0, 1, 0, -1}, {"Firefox", NULL, NULL, 1 << 4, 0, 0, 0, -1}, {"Navigator", NULL, NULL, 1 << 4, 0, 0, 0, -1}, {"zen", NULL, NULL, 1 << 4, 0, 0, 0, -1}, @@ -145,7 +146,7 @@ static const Layout layouts[] = { static char dmenumon[2] = "0"; /* component of dmenucmd, manipulated in spawn() */ static const char *dmenucmd[] = {"rofi", "-show", "drun", NULL}; -static const char *termcmd[] = {"st", NULL}; +static const char *termcmd[] = {"ghostty", NULL}; static const char scratchpadname[] = "scratchpad"; static const char *scratchpadcmd[] = {"st", "-t", scratchpadname, "-g", "120x34", NULL}; From ffc3dfd6bfd62c08a5ce3fb82b896482218881c3 Mon Sep 17 00:00:00 2001 From: Alex Selimov Date: Mon, 6 Oct 2025 19:29:17 -0400 Subject: [PATCH 3/3] Update dwm center bar to redraw when on configurable setting --- dwm.c | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/dwm.c b/dwm.c index 02892b4..03e4233 100644 --- a/dwm.c +++ b/dwm.c @@ -35,6 +35,7 @@ #include #include #include +#include #include #ifdef XINERAMA #include @@ -52,6 +53,7 @@ /* macros */ #define MAX_LINE_LENGTH 1024 +#define CENTER_UPDATE_INTERVAL 1 /* seconds between updates */ #define BUTTONMASK (ButtonPressMask | ButtonReleaseMask) #define CLEANMASK(mask) \ (mask & ~(numlockmask | LockMask) & \ @@ -1609,10 +1611,18 @@ void run(void) { XEvent ev; /* main event loop */ XSync(dpy, False); - int ticks = 0; + time_t last_update = 0; + while (running && !XNextEvent(dpy, &ev)) { if (handler[ev.type]) handler[ev.type](&ev); /* call handler */ + + // Check for timeout-based center text update + time_t now = time(NULL); + if (now - last_update >= CENTER_UPDATE_INTERVAL) { + last_update = now; + drawbars(); + } } }