From ad10853f082ef927d67beade3b053b301d2fff87 Mon Sep 17 00:00:00 2001 From: odrling Date: Sat, 27 Mar 2021 18:56:05 +0100 Subject: [PATCH 01/30] set up my patches and config --- config.def.h | 120 +++++++++++++++++++++++++++++--------------------- patches.def.h | 50 ++++++++++----------- 2 files changed, 95 insertions(+), 75 deletions(-) diff --git a/config.def.h b/config.def.h index e030ee9..c8057af 100644 --- a/config.def.h +++ b/config.def.h @@ -154,11 +154,11 @@ static void (*bartabmonfns[])(Monitor *) = { NULL /* , customlayoutfn */ }; #endif // MONOCLE_LAYOUT #endif // BAR_TABGROUPS_PATCH #if BAR_PANGO_PATCH -static const char font[] = "monospace 10"; +static const char font[] = "sans 12"; #else -static const char *fonts[] = { "monospace:size=10" }; +static const char *fonts[] = { "sans:size=12" }; #endif // BAR_PANGO_PATCH -static const char dmenufont[] = "monospace:size=10"; +static const char dmenufont[] = "sans:size=12"; static char c000000[] = "#000000"; // placeholder value @@ -168,9 +168,9 @@ static char normbordercolor[] = "#444444"; static char normfloatcolor[] = "#db8fd9"; static char selfgcolor[] = "#eeeeee"; -static char selbgcolor[] = "#005577"; -static char selbordercolor[] = "#005577"; -static char selfloatcolor[] = "#005577"; +static char selbgcolor[] = "#9966cc"; +static char selbordercolor[] = "#9966cc"; +static char selfloatcolor[] = "#9966cc"; static char titlenormfgcolor[] = "#bbbbbb"; static char titlenormbgcolor[] = "#222222"; @@ -178,9 +178,9 @@ static char titlenormbordercolor[] = "#444444"; static char titlenormfloatcolor[] = "#db8fd9"; static char titleselfgcolor[] = "#eeeeee"; -static char titleselbgcolor[] = "#005577"; -static char titleselbordercolor[] = "#005577"; -static char titleselfloatcolor[] = "#005577"; +static char titleselbgcolor[] = "#9966cc"; +static char titleselbordercolor[] = "#9966cc"; +static char titleselfloatcolor[] = "#9966cc"; static char tagsnormfgcolor[] = "#bbbbbb"; static char tagsnormbgcolor[] = "#222222"; @@ -188,14 +188,14 @@ static char tagsnormbordercolor[] = "#444444"; static char tagsnormfloatcolor[] = "#db8fd9"; static char tagsselfgcolor[] = "#eeeeee"; -static char tagsselbgcolor[] = "#005577"; -static char tagsselbordercolor[] = "#005577"; -static char tagsselfloatcolor[] = "#005577"; +static char tagsselbgcolor[] = "#9966cc"; +static char tagsselbordercolor[] = "#9966cc"; +static char tagsselfloatcolor[] = "#9966cc"; -static char hidnormfgcolor[] = "#005577"; -static char hidselfgcolor[] = "#227799"; -static char hidnormbgcolor[] = "#222222"; -static char hidselbgcolor[] = "#222222"; +static char hidnormfgcolor[] = "#9966cc"; +static char hidselfgcolor[] = "#222222"; +static char hidnormbgcolor[] = "#9966cc"; +static char hidselbgcolor[] = "#f76e0c"; static char urgfgcolor[] = "#bbbbbb"; static char urgbgcolor[] = "#222222"; @@ -395,7 +395,7 @@ static const char *layoutmenu_cmd = "layoutmenu.sh"; #if COOL_AUTOSTART_PATCH static const char *const autostart[] = { - "st", NULL, + "dwmblocks", NULL, NULL /* terminate */ }; #endif // COOL_AUTOSTART_PATCH @@ -491,11 +491,10 @@ static const Rule rules[] = { RULE(.wintype = WTYPE "UTILITY", .isfloating = 1) RULE(.wintype = WTYPE "TOOLBAR", .isfloating = 1) RULE(.wintype = WTYPE "SPLASH", .isfloating = 1) - RULE(.class = "Gimp", .tags = 1 << 4) - RULE(.class = "Firefox", .tags = 1 << 7) - #if RENAMED_SCRATCHPADS_PATCH - RULE(.instance = "spterm", .scratchkey = 's', .isfloating = 1) - #elif SCRATCHPADS_PATCH + RULE(.class = "Firefox", .tags = 1 << 7, .switchtag = 2) + RULE(.class = "Ardour", .tags = 1 << 8) + RULE(.class = "mpv", .instance = "syncplay-mpv", .monitor = 1) + #if SCRATCHPADS_PATCH RULE(.instance = "spterm", .tags = SPTAG(0), .isfloating = 1) #endif // SCRATCHPADS_PATCH }; @@ -649,13 +648,13 @@ static const int scrollargs[][2] = { static const Layout layouts[] = { /* symbol arrange function, { nmaster, nstack, layout, master axis, stack axis, secondary stack axis, symbol func } */ { "[]=", flextile, { -1, -1, SPLIT_VERTICAL, TOP_TO_BOTTOM, TOP_TO_BOTTOM, 0, NULL } }, // default tile layout - { "><>", NULL, {0} }, /* no layout function means floating behavior */ { "[M]", flextile, { -1, -1, NO_SPLIT, MONOCLE, MONOCLE, 0, NULL } }, // monocle - { "|||", flextile, { -1, -1, SPLIT_VERTICAL, LEFT_TO_RIGHT, TOP_TO_BOTTOM, 0, NULL } }, // columns (col) layout - { ">M>", flextile, { -1, -1, FLOATING_MASTER, LEFT_TO_RIGHT, LEFT_TO_RIGHT, 0, NULL } }, // floating master - { "[D]", flextile, { -1, -1, SPLIT_VERTICAL, TOP_TO_BOTTOM, MONOCLE, 0, NULL } }, // deck { "TTT", flextile, { -1, -1, SPLIT_HORIZONTAL, LEFT_TO_RIGHT, LEFT_TO_RIGHT, 0, NULL } }, // bstack - { "===", flextile, { -1, -1, SPLIT_HORIZONTAL, LEFT_TO_RIGHT, TOP_TO_BOTTOM, 0, NULL } }, // bstackhoriz + // { "><>", NULL, {0} }, /* no layout function means floating behavior */ + // { "|||", flextile, { -1, -1, SPLIT_VERTICAL, LEFT_TO_RIGHT, TOP_TO_BOTTOM, 0, NULL } }, // columns (col) layout + // { ">M>", flextile, { -1, -1, FLOATING_MASTER, LEFT_TO_RIGHT, LEFT_TO_RIGHT, 0, NULL } }, // floating master + { "[D]", flextile, { -1, -1, SPLIT_VERTICAL, TOP_TO_BOTTOM, MONOCLE, 0, NULL } }, // deck + // { "===", flextile, { -1, -1, SPLIT_HORIZONTAL, LEFT_TO_RIGHT, TOP_TO_BOTTOM, 0, NULL } }, // bstackhoriz { "|M|", flextile, { -1, -1, SPLIT_CENTERED_VERTICAL, LEFT_TO_RIGHT, TOP_TO_BOTTOM, TOP_TO_BOTTOM, NULL } }, // centeredmaster { "-M-", flextile, { -1, -1, SPLIT_CENTERED_HORIZONTAL, TOP_TO_BOTTOM, LEFT_TO_RIGHT, LEFT_TO_RIGHT, NULL } }, // centeredmaster horiz { ":::", flextile, { -1, -1, NO_SPLIT, GAPPLESSGRID, GAPPLESSGRID, 0, NULL } }, // gappless grid @@ -714,7 +713,7 @@ static const Layout layouts[] = { #if TILE_LAYOUT { "[]=", tile }, /* first entry is default */ #endif - { "><>", NULL }, /* no layout function means floating behavior */ + // { "><>", NULL }, /* no layout function means floating behavior */ #if MONOCLE_LAYOUT { "[M]", monocle }, #endif @@ -769,7 +768,7 @@ static const char *xkb_layouts[] = { #endif // XKB_PATCH /* key definitions */ -#define MODKEY Mod1Mask +#define MODKEY Mod4Mask #if COMBO_PATCH && SWAPTAGS_PATCH && TAGOTHERMONITOR_PATCH #define TAGKEYS(KEY,TAG) \ { MODKEY, KEY, comboview, {.ui = 1 << TAG} }, \ @@ -870,6 +869,10 @@ static const char *dmenucmd[] = { NULL }; static const char *termcmd[] = { "st", NULL }; +static const char *passmenucmd[] = { "passmenu", "-m", dmenumon, NULL }; +static const char *webmenucmd[] = { "webmenu", "-m", dmenumon, NULL }; +static const char *screenshot[] = { "screenshot", NULL }; +static const char *screenshots[] = { "screenshot", "-s", "-l", "-c", "0.75,0.5,1.0,0.1", NULL }; #if BAR_STATUSCMD_PATCH #if BAR_DWMBLOCKS_PATCH @@ -900,7 +903,7 @@ static const Key keys[] = { #if KEYMODES_PATCH { MODKEY, XK_Escape, setkeymode, {.ui = COMMANDMODE} }, #endif // KEYMODES_PATCH - { MODKEY, XK_p, spawn, {.v = dmenucmd } }, + { MODKEY, XK_o, spawn, {.v = dmenucmd } }, { MODKEY|ShiftMask, XK_Return, spawn, {.v = termcmd } }, #if RIODRAW_PATCH { MODKEY|ControlMask, XK_p, riospawnsync, {.v = dmenucmd } }, @@ -1044,14 +1047,14 @@ static const Key keys[] = { #if BAR_WINTITLEACTIONS_PATCH { MODKEY|ControlMask, XK_z, showhideclient, {0} }, #endif // BAR_WINTITLEACTIONS_PATCH - { MODKEY|ShiftMask, XK_c, killclient, {0} }, + { MODKEY, XK_q, killclient, {0} }, #if KILLUNSEL_PATCH { MODKEY|ShiftMask, XK_x, killunsel, {0} }, #endif // KILLUNSEL_PATCH #if SELFRESTART_PATCH { MODKEY|ShiftMask, XK_r, self_restart, {0} }, #endif // SELFRESTART_PATCH - { MODKEY|ShiftMask, XK_q, quit, {0} }, + // { MODKEY|ShiftMask, XK_q, quit, {0} }, #if RESTARTSIG_PATCH { MODKEY|ControlMask|ShiftMask, XK_q, quit, {1} }, #endif // RESTARTSIG_PATCH @@ -1067,9 +1070,9 @@ static const Key keys[] = { #if XRDB_PATCH && !BAR_VTCOLORS_PATCH { MODKEY|ShiftMask, XK_F5, xrdb, {.v = NULL } }, #endif // XRDB_PATCH - { MODKEY, XK_t, setlayout, {.v = &layouts[0]} }, - { MODKEY, XK_f, setlayout, {.v = &layouts[1]} }, - { MODKEY, XK_m, setlayout, {.v = &layouts[2]} }, + { MODKEY, XK_t, setlayout, {.v = &layouts[0]} }, // tile + { MODKEY, XK_u, setlayout, {.v = &layouts[1]} }, // monocle + { MODKEY, XK_y, setlayout, {.v = &layouts[2]} }, // bstack #if COLUMNS_LAYOUT { MODKEY, XK_c, setlayout, {.v = &layouts[3]} }, #endif // COLUMNS_LAYOUT @@ -1132,10 +1135,10 @@ static const Key keys[] = { { MODKEY, XK_0, view, {.ui = ~0 } }, { MODKEY|ShiftMask, XK_0, tag, {.ui = ~0 } }, #endif // SCRATCHPAD_ALT_1_PATCH - { MODKEY, XK_comma, focusmon, {.i = -1 } }, - { MODKEY, XK_period, focusmon, {.i = +1 } }, - { MODKEY|ShiftMask, XK_comma, tagmon, {.i = -1 } }, - { MODKEY|ShiftMask, XK_period, tagmon, {.i = +1 } }, + { MODKEY|ControlMask, XK_j, focusmon, {.i = -1 } }, + { MODKEY|ControlMask, XK_k, focusmon, {.i = +1 } }, + { MODKEY|ShiftMask, XK_j, tagmon, {.i = -1 } }, + { MODKEY|ShiftMask, XK_k, tagmon, {.i = +1 } }, #if FOCUSADJACENTTAG_PATCH { MODKEY, XK_Left, viewtoleft, {0} }, // note keybinding conflict with focusdir { MODKEY, XK_Right, viewtoright, {0} }, // note keybinding conflict with focusdir @@ -1275,23 +1278,40 @@ static const Key keys[] = { { MODKEY|ControlMask, XK_numbersign, setborderpx, {.i = 0 } }, #endif // SETBORDERPX_PATCH #if CYCLELAYOUTS_PATCH - { MODKEY|ControlMask, XK_comma, cyclelayout, {.i = -1 } }, - { MODKEY|ControlMask, XK_period, cyclelayout, {.i = +1 } }, + { MODKEY|ShiftMask, XK_Tab, cyclelayout, {.i = -1 } }, + { MODKEY, XK_Tab, cyclelayout, {.i = +1 } }, #endif // CYCLELAYOUTS_PATCH #if MPDCONTROL_PATCH { MODKEY, XK_F1, mpdchange, {.i = -1} }, { MODKEY, XK_F2, mpdchange, {.i = +1} }, { MODKEY, XK_Escape, mpdcontrol, {0} }, #endif // MPDCONTROL_PATCH - TAGKEYS( XK_1, 0) - TAGKEYS( XK_2, 1) - TAGKEYS( XK_3, 2) - TAGKEYS( XK_4, 3) - TAGKEYS( XK_5, 4) - TAGKEYS( XK_6, 5) - TAGKEYS( XK_7, 6) - TAGKEYS( XK_8, 7) - TAGKEYS( XK_9, 8) + TAGKEYS( XK_ampersand, 0) + TAGKEYS( XK_eacute, 1) + TAGKEYS( XK_quotedbl, 2) + TAGKEYS( XK_apostrophe, 3) + TAGKEYS( XK_parenleft, 4) + TAGKEYS( XK_minus, 5) + TAGKEYS( XK_egrave, 6) + TAGKEYS( XK_underscore, 7) + TAGKEYS( XK_ccedilla, 8) + { MODKEY, XK_Up, spawn, SHCMD("omixer +") }, + { MODKEY, XK_Down, spawn, SHCMD("omixer -") }, + { MODKEY, XK_Left, spawn, SHCMD("backlight - 5") }, + { MODKEY, XK_Right, spawn, SHCMD("backlight + 5") }, + { MODKEY|ShiftMask, XK_d, spawn, SHCMD("discord") }, + { MODKEY|ShiftMask, XK_f, spawn, SHCMD("firefox") }, + { MODKEY, XK_a, spawn, SHCMD("anime") }, + { MODKEY, XK_v, spawn, SHCMD("st -e vid") }, + { MODKEY, XK_n, spawn, SHCMD("st -e newsboat") }, + { MODKEY, XK_comma, spawn, SHCMD("st -e weechat") }, + { MODKEY, XK_z, spawn, SHCMD("shortmenu") }, + { MODKEY, XK_m, spawn, SHCMD("dmount") }, + { MODKEY|ShiftMask, XK_m, spawn, SHCMD("dumount") }, + { MODKEY, XK_p, spawn, {.v = passmenucmd } }, + { MODKEY, XK_g, spawn, {.v = webmenucmd } }, + { MODKEY, XK_s, spawn, {.v = screenshot } }, + { MODKEY|ShiftMask, XK_s, spawn, {.v = screenshots } }, }; #if KEYMODES_PATCH diff --git a/patches.def.h b/patches.def.h index 1429aa0..8fdae36 100644 --- a/patches.def.h +++ b/patches.def.h @@ -326,7 +326,7 @@ * https://github.com/bakkeby/dwm-flexipatch/issues/50 (_IS_FLOATING patch) * https://dwm.suckless.org/patches/ewmhtags/ */ -#define BAR_EWMHTAGS_PATCH 0 +#define BAR_EWMHTAGS_PATCH 1 /* Allows the bar height to be explicitly set rather than being derived from font. * https://dwm.suckless.org/patches/bar_height/ @@ -336,7 +336,7 @@ /* This patch prevents dwm from drawing tags with no clients (i.e. vacant) on the bar. * https://dwm.suckless.org/patches/hide_vacant_tags/ */ -#define BAR_HIDEVACANTTAGS_PATCH 0 +#define BAR_HIDEVACANTTAGS_PATCH 1 /* With this patch dwm's built-in status bar is only shown when HOLDKEY is pressed * and the bar will now overlay the display. @@ -491,7 +491,7 @@ * get resized/moved. With this patch, they will. * https://dwm.suckless.org/patches/autoresize/ */ -#define AUTORESIZE_PATCH 0 +#define AUTORESIZE_PATCH 1 /* This patch adds proper support for Right-To-Left languages. (such as Farsi, Arabic or Hebrew). * @@ -521,12 +521,12 @@ * adding wintype as a client rule filter, hence this no longer works out of the box. This * patch restores previous behaviour with the center patch. */ -#define CENTER_TRANSIENT_WINDOWS_PATCH 0 +#define CENTER_TRANSIENT_WINDOWS_PATCH 1 /* As above, except that the transient window is centered within the position of the parent * window, rather than at the center of the screen. This takes precedence over the above patch. */ -#define CENTER_TRANSIENT_WINDOWS_BY_PARENT_PATCH 0 +#define CENTER_TRANSIENT_WINDOWS_BY_PARENT_PATCH 1 /* This patch provides the ability to assign different weights to clients in their * respective stack in tiled layout. @@ -544,18 +544,18 @@ * hold MOD and then press and hold 1 and 3 together. * https://dwm.suckless.org/patches/combo/ */ -#define COMBO_PATCH 0 +#define COMBO_PATCH 1 /* Allow dwm to execute commands from autostart array in your config.h file. When dwm exits * then all processes from autostart array will be killed. * https://dwm.suckless.org/patches/cool_autostart/ */ -#define COOL_AUTOSTART_PATCH 0 +#define COOL_AUTOSTART_PATCH 1 /* The cyclelayouts patch lets you cycle through all your layouts. * https://dwm.suckless.org/patches/cyclelayouts/ */ -#define CYCLELAYOUTS_PATCH 0 +#define CYCLELAYOUTS_PATCH 1 /* Make dwm respect _MOTIF_WM_HINTS property, and not draw borders around windows requesting * for it. Some applications use this property to notify window managers to not draw window @@ -661,7 +661,7 @@ * xdotool selectwindow -- set_window --urgency 1 * https://dwm.suckless.org/patches/focusurgent/ */ -#define FOCUSURGENT_PATCH 0 +#define FOCUSURGENT_PATCH 1 /* By default, dwm responds to _NET_ACTIVE_WINDOW client messages by setting * the urgency bit on the named window. This patch activates the window instead. @@ -706,7 +706,7 @@ * https://github.com/mihirlad55/dwm-ipc * https://dwm.suckless.org/patches/ipc/ */ -#define IPC_PATCH 0 +#define IPC_PATCH 1 /* Adds rule option for clients to avoid accidental termination by killclient for sticky windows. * https://dwm.suckless.org/patches/ispermanent/ @@ -737,7 +737,7 @@ * in such scenarios the previous window loses fullscreen. * https://github.com/bakkeby/patches/blob/master/dwm/dwm-losefullscreen-6.2.diff */ -#define LOSEFULLSCREEN_PATCH 0 +#define LOSEFULLSCREEN_PATCH 1 /* This patch adds helper functions for maximizing, horizontally and vertically, floating * windows using keybindings. @@ -815,12 +815,12 @@ * Zoom video conferencing application. * https://github.com/bakkeby/patches/wiki/netclientliststacking/ */ -#define NET_CLIENT_LIST_STACKING_PATCH 0 +#define NET_CLIENT_LIST_STACKING_PATCH 1 /* Removes the border when there is only one window visible. * https://dwm.suckless.org/patches/noborder/ */ -#define NOBORDER_PATCH 0 +#define NOBORDER_PATCH 1 /* Enable modifying or removing dmenu in config.def.h which resulted previously in a * compilation error because two lines of code hardcode dmenu into dwm. @@ -848,7 +848,7 @@ * https://github.com/szatanjl/dwm/commit/1529909466206016f2101457bbf37c67195714c8 * https://dwm.suckless.org/patches/alpha/dwm-fixborders-6.2.diff */ -#define NO_TRANSPARENT_BORDERS_PATCH 0 +#define NO_TRANSPARENT_BORDERS_PATCH 1 /* Port of InstantWM's on_empty_keys functionality allowing keybindings that apply only when * a tag is empty. An example use case is being able to launch applications with first hand @@ -936,7 +936,7 @@ * This takes precedence over the resizecorners patch. * https://github.com/bakkeby/patches/blob/master/dwm/dwm-resizepoint-6.2.diff */ -#define RESIZEPOINT_PATCH 0 +#define RESIZEPOINT_PATCH 1 /* Adds a keyboard shortcut to restart dwm or alternatively by using kill -HUP dwmpid. * Additionally dwm can quit cleanly by using kill -TERM dwmpid. @@ -1096,7 +1096,7 @@ * comes to focusmon, tagmon and similar functionality. * https://www.mail-archive.com/hackers@suckless.org/msg09400.html */ -#define SORTSCREENS_PATCH 0 +#define SORTSCREENS_PATCH 1 /* Spawns programs from currently focused client's working directory. * https://dwm.suckless.org/patches/spawn_cwd/ @@ -1122,12 +1122,12 @@ * * https://github.com/bakkeby/patches/wiki/steam */ -#define STEAM_PATCH 0 +#define STEAM_PATCH 1 /* Adds toggleable keyboard shortcut to make a client 'sticky', i.e. visible on all tags. * https://dwm.suckless.org/patches/sticky/ */ -#define STICKY_PATCH 0 +#define STICKY_PATCH 1 /* This patch adds "window swallowing" to dwm as known from Plan 9's windowing system rio. * Clients marked with isterminal in config.h swallow a window opened by any child process, @@ -1144,7 +1144,7 @@ * * https://dwm.suckless.org/patches/swallow/ */ -#define SWALLOW_PATCH 0 +#define SWALLOW_PATCH 1 /* This patch depends on the pertag patch and makes it possible to switch focus with a single * shortcut (MOD+s) instead of having to think if you should use mod-j or mod-k for reaching @@ -1180,7 +1180,7 @@ * https://github.com/bakkeby/patches/blob/master/dwm/dwm-switchtag-6.2.diff * Also see https://dwm.suckless.org/patches/switchtotag */ -#define SWITCHTAG_PATCH 0 +#define SWITCHTAG_PATCH 1 /* This patch transforms the monocle layout into a "tabbed" layout if more than one window is * present on the monocle view. This patch has been added for demonstration purposes only and has @@ -1222,7 +1222,7 @@ * while remaining in fullscreen. * https://github.com/bakkeby/patches/blob/master/dwm/dwm-tagmonfixfs-6.2.diff */ -#define TAGMONFIXFS_PATCH 0 +#define TAGMONFIXFS_PATCH 1 /* Add functions and keybindings to tag a window to a desired tag on the next (right) * or previous (left) monitor from the currently selected monitor. @@ -1320,7 +1320,7 @@ * when the mouse cursor is (a) on a different screen or (b) on top of a different window. * https://dwm.suckless.org/patches/warp/ */ -#define WARP_PATCH 0 +#define WARP_PATCH 1 /* Sometimes a single application opens different windows depending on the task * at hand and this is often reflected in the WM_WINDOW_ROLE(STRING) x property. @@ -1348,7 +1348,7 @@ * the float border color, awesomebar, urgentborder and titlecolor patches. * https://dwm.suckless.org/patches/xrdb/ */ -#define XRDB_PATCH 0 +#define XRDB_PATCH 1 /* Simple patch that allows floating windows to be zoomed into the master stack position. * https://www.reddit.com/r/suckless/comments/ie5fe3/zoomfloating_my_own_simple_original_patch/ @@ -1410,7 +1410,7 @@ * A revamped, more flexible, and over-the-top version of the original flextile layout. * https://dwm.suckless.org/patches/flextile/ (original) */ -#define FLEXTILE_DELUXE_LAYOUT 0 +#define FLEXTILE_DELUXE_LAYOUT 1 /* Gappless grid layout. * https://dwm.suckless.org/patches/gaplessgrid/ @@ -1435,7 +1435,7 @@ /* The default tile layout. * This can be optionally disabled in favour of other layouts. */ -#define TILE_LAYOUT 1 +#define TILE_LAYOUT 0 /* Monocle layout (default). * This can be optionally disabled in favour of other layouts. -- 2.38.1 From 472312061df8428fd5aa7958e14f58bf5e2c43af Mon Sep 17 00:00:00 2001 From: odrling Date: Sat, 27 Mar 2021 19:07:22 +0100 Subject: [PATCH 02/30] set urgent color --- config.def.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/config.def.h b/config.def.h index c8057af..c2ae077 100644 --- a/config.def.h +++ b/config.def.h @@ -197,9 +197,9 @@ static char hidselfgcolor[] = "#222222"; static char hidnormbgcolor[] = "#9966cc"; static char hidselbgcolor[] = "#f76e0c"; -static char urgfgcolor[] = "#bbbbbb"; -static char urgbgcolor[] = "#222222"; -static char urgbordercolor[] = "#ff0000"; +static char urgfgcolor[] = "#222222"; +static char urgbgcolor[] = "#bbbbbb"; +static char urgbordercolor[] = "#dddddd"; static char urgfloatcolor[] = "#db8fd9"; #if RENAMED_SCRATCHPADS_PATCH -- 2.38.1 From 452774c3c6a59deff7ce7bcc3dd5ae6dbffcae76 Mon Sep 17 00:00:00 2001 From: odrling Date: Sun, 28 Mar 2021 20:22:05 +0200 Subject: [PATCH 03/30] more config --- config.def.h | 15 +++++++++------ patches.def.h | 10 +++++----- 2 files changed, 14 insertions(+), 11 deletions(-) diff --git a/config.def.h b/config.def.h index c2ae077..b36c6fe 100644 --- a/config.def.h +++ b/config.def.h @@ -491,8 +491,9 @@ static const Rule rules[] = { RULE(.wintype = WTYPE "UTILITY", .isfloating = 1) RULE(.wintype = WTYPE "TOOLBAR", .isfloating = 1) RULE(.wintype = WTYPE "SPLASH", .isfloating = 1) - RULE(.class = "Firefox", .tags = 1 << 7, .switchtag = 2) - RULE(.class = "Ardour", .tags = 1 << 8) + RULE(.class = "Firefox", .tags = 1 << 7, .switchtag = 1) + RULE(.class = "Ardour", .tags = 1 << 8, .monitor = 0) + RULE(.class = "qBittorrent", .tags = 1 << 6, .switchtag = 1, .monitor = 0) RULE(.class = "mpv", .instance = "syncplay-mpv", .monitor = 1) #if SCRATCHPADS_PATCH RULE(.instance = "spterm", .tags = SPTAG(0), .isfloating = 1) @@ -1122,7 +1123,7 @@ static const Key keys[] = { { MODKEY|ShiftMask, XK_f, fullscreen, {0} }, #endif // FULLSCREEN_PATCH #if STICKY_PATCH - { MODKEY|ShiftMask, XK_s, togglesticky, {0} }, + { MODKEY|ShiftMask, XK_t, togglesticky, {0} }, #endif // STICKY_PATCH #if SCRATCHPAD_ALT_1_PATCH { MODKEY, XK_minus, scratchpad_show, {0} }, @@ -1132,8 +1133,8 @@ static const Key keys[] = { { MODKEY, XK_0, view, {.ui = ~SPTAGMASK } }, { MODKEY|ShiftMask, XK_0, tag, {.ui = ~SPTAGMASK } }, #else - { MODKEY, XK_0, view, {.ui = ~0 } }, - { MODKEY|ShiftMask, XK_0, tag, {.ui = ~0 } }, + { MODKEY, XK_agrave, view, {.ui = ~0 } }, + { MODKEY|ShiftMask, XK_agrave, tag, {.ui = ~0 } }, #endif // SCRATCHPAD_ALT_1_PATCH { MODKEY|ControlMask, XK_j, focusmon, {.i = -1 } }, { MODKEY|ControlMask, XK_k, focusmon, {.i = +1 } }, @@ -1600,7 +1601,9 @@ static const Signal signals[] = { /* trigger signals using `xsetroot -name "fsignal:"` */ static Signal signals[] = { /* signum function argument */ - { 1, setlayout, {.v = 0} }, + { 1, spawn, SHCMD("setaudio") }, + { 2, spawn, SHCMD("setoutput") }, + { 3, spawn, SHCMD("sethid") }, }; #endif // DWMC_PATCH diff --git a/patches.def.h b/patches.def.h index 8fdae36..71a2ef8 100644 --- a/patches.def.h +++ b/patches.def.h @@ -460,7 +460,7 @@ * This patch takes precedence over ATTACHASIDE_PATCH. * https://dwm.suckless.org/patches/attachabove/ */ -#define ATTACHABOVE_PATCH 0 +#define ATTACHABOVE_PATCH 1 /* This patch adds new clients on top of the stack. * This patch takes precedence over ATTACHBELOW_PATCH. @@ -667,14 +667,14 @@ * the urgency bit on the named window. This patch activates the window instead. * https://dwm.suckless.org/patches/focusonnetactive/ */ -#define FOCUSONNETACTIVE_PATCH 0 +#define FOCUSONNETACTIVE_PATCH 1 /* Send "fake signals" to dwm for handling, using xsetroot. This will not conflict with the * status bar, which also is managed using xsetroot. * Also see the dwmc patch, which takes precedence over this patch. * https://dwm.suckless.org/patches/fsignal/ */ -#define FSIGNAL_PATCH 0 +#define FSIGNAL_PATCH 1 /* Applies the monocle layout with the focused client on top and hides the bar. When pressed * again it shows the bar and restores the layout that was active before going fullscreen. @@ -820,7 +820,7 @@ /* Removes the border when there is only one window visible. * https://dwm.suckless.org/patches/noborder/ */ -#define NOBORDER_PATCH 1 +#define NOBORDER_PATCH 0 /* Enable modifying or removing dmenu in config.def.h which resulted previously in a * compilation error because two lines of code hardcode dmenu into dwm. @@ -872,7 +872,7 @@ * monitor (default). * https://dwm.suckless.org/patches/pertag/ */ -#define PERTAG_PATCH 0 +#define PERTAG_PATCH 1 /* Option to store gaps on a per tag basis rather than on a per monitor basis. * Depends on both pertag and vanitygaps patches being enabled. -- 2.38.1 From d7dae7579bd42c0f6afd21de3fed7ae47d5a0adb Mon Sep 17 00:00:00 2001 From: odrling Date: Thu, 1 Apr 2021 20:27:49 +0200 Subject: [PATCH 04/30] edit cyclelayout keybinding --- config.def.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/config.def.h b/config.def.h index b36c6fe..d94a1da 100644 --- a/config.def.h +++ b/config.def.h @@ -1088,8 +1088,8 @@ static const Key keys[] = { { MODKEY|Mod5Mask|Mod1Mask, XK_Tab, rotatelayoutaxis, {.i = -4 } }, /* flextile, 4 = secondary stack axis */ { MODKEY|ControlMask, XK_Return, mirrorlayout, {0} }, /* flextile, flip master and stack areas */ #endif // FLEXTILE_DELUXE_LAYOUT - { MODKEY, XK_space, setlayout, {0} }, - { MODKEY|ShiftMask, XK_space, togglefloating, {0} }, + //{ MODKEY, XK_space, setlayout, {0} }, + { MODKEY|ControlMask, XK_space, togglefloating, {0} }, #if MAXIMIZE_PATCH { MODKEY|ControlMask|ShiftMask, XK_h, togglehorizontalmax, {0} }, { MODKEY|ControlMask|ShiftMask, XK_l, togglehorizontalmax, {0} }, @@ -1279,8 +1279,8 @@ static const Key keys[] = { { MODKEY|ControlMask, XK_numbersign, setborderpx, {.i = 0 } }, #endif // SETBORDERPX_PATCH #if CYCLELAYOUTS_PATCH - { MODKEY|ShiftMask, XK_Tab, cyclelayout, {.i = -1 } }, - { MODKEY, XK_Tab, cyclelayout, {.i = +1 } }, + { MODKEY|ShiftMask, XK_space, cyclelayout, {.i = -1 } }, + { MODKEY, XK_space, cyclelayout, {.i = +1 } }, #endif // CYCLELAYOUTS_PATCH #if MPDCONTROL_PATCH { MODKEY, XK_F1, mpdchange, {.i = -1} }, -- 2.38.1 From 545ba57b4707f760b0255034b8376f3625030a8a Mon Sep 17 00:00:00 2001 From: odrling Date: Wed, 21 Apr 2021 23:19:07 +0200 Subject: [PATCH 05/30] I don't think this argument is required --- config.def.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/config.def.h b/config.def.h index d94a1da..705617f 100644 --- a/config.def.h +++ b/config.def.h @@ -870,8 +870,8 @@ static const char *dmenucmd[] = { NULL }; static const char *termcmd[] = { "st", NULL }; -static const char *passmenucmd[] = { "passmenu", "-m", dmenumon, NULL }; -static const char *webmenucmd[] = { "webmenu", "-m", dmenumon, NULL }; +static const char *passmenucmd[] = { "passmenu", NULL }; +static const char *webmenucmd[] = { "webmenu", NULL }; static const char *screenshot[] = { "screenshot", NULL }; static const char *screenshots[] = { "screenshot", "-s", "-l", "-c", "0.75,0.5,1.0,0.1", NULL }; -- 2.38.1 From f901e799f405043a03599bcf0d5d67fba1744b82 Mon Sep 17 00:00:00 2001 From: odrling Date: Wed, 21 Apr 2021 23:36:07 +0200 Subject: [PATCH 06/30] decomment libraries used by enabled patches --- config.mk | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/config.mk b/config.mk index 7db6cba..62add36 100644 --- a/config.mk +++ b/config.mk @@ -39,14 +39,14 @@ XRENDER = -lXrender #PANGOLIB = `pkg-config --libs xft pango pangoxft` # Uncomment for the ipc patch / IPC_PATCH -#YAJLLIBS = -lyajl -#YAJLINC = -I/usr/include/yajl +YAJLLIBS = -lyajl +YAJLINC = -I/usr/include/yajl # Uncomment this for the rounded corners patch / ROUNDED_CORNERS_PATCH #XEXTLIB = -lXext # Uncomment this for the swallow patch / SWALLOW_PATCH -#XCBLIBS = -lX11-xcb -lxcb -lxcb-res +XCBLIBS = -lX11-xcb -lxcb -lxcb-res # This is needed for the winicon and tagpreview patches / BAR_WINICON_PATCH / BAR_TAGPREVIEW_PATCH #IMLIB2LIBS = -lImlib2 -- 2.38.1 From 204c9419c75b7be43065b554c06da625af00bfd9 Mon Sep 17 00:00:00 2001 From: odrling Date: Sat, 24 Apr 2021 15:02:45 +0200 Subject: [PATCH 07/30] runsvdir on startup --- config.def.h | 1 + 1 file changed, 1 insertion(+) diff --git a/config.def.h b/config.def.h index 705617f..daaa034 100644 --- a/config.def.h +++ b/config.def.h @@ -396,6 +396,7 @@ static const char *layoutmenu_cmd = "layoutmenu.sh"; #if COOL_AUTOSTART_PATCH static const char *const autostart[] = { "dwmblocks", NULL, + "sh", "-c", "runsvdir $HOME/.sv", NULL, NULL /* terminate */ }; #endif // COOL_AUTOSTART_PATCH -- 2.38.1 From 2ac7030d87b54cedf97adfec81cb4105b874b35e Mon Sep 17 00:00:00 2001 From: odrling Date: Fri, 14 May 2021 19:58:33 +0200 Subject: [PATCH 08/30] browser config --- config.def.h | 3 ++- patches.def.h | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/config.def.h b/config.def.h index daaa034..771985a 100644 --- a/config.def.h +++ b/config.def.h @@ -493,6 +493,7 @@ static const Rule rules[] = { RULE(.wintype = WTYPE "TOOLBAR", .isfloating = 1) RULE(.wintype = WTYPE "SPLASH", .isfloating = 1) RULE(.class = "Firefox", .tags = 1 << 7, .switchtag = 1) + RULE(.role = "browser", .tags = 1 << 7, .switchtag = 1) RULE(.class = "Ardour", .tags = 1 << 8, .monitor = 0) RULE(.class = "qBittorrent", .tags = 1 << 6, .switchtag = 1, .monitor = 0) RULE(.class = "mpv", .instance = "syncplay-mpv", .monitor = 1) @@ -1302,7 +1303,7 @@ static const Key keys[] = { { MODKEY, XK_Left, spawn, SHCMD("backlight - 5") }, { MODKEY, XK_Right, spawn, SHCMD("backlight + 5") }, { MODKEY|ShiftMask, XK_d, spawn, SHCMD("discord") }, - { MODKEY|ShiftMask, XK_f, spawn, SHCMD("firefox") }, + { MODKEY|ShiftMask, XK_f, spawn, SHCMD("browser") }, { MODKEY, XK_a, spawn, SHCMD("anime") }, { MODKEY, XK_v, spawn, SHCMD("st -e vid") }, { MODKEY, XK_n, spawn, SHCMD("st -e newsboat") }, diff --git a/patches.def.h b/patches.def.h index 71a2ef8..1bc2e44 100644 --- a/patches.def.h +++ b/patches.def.h @@ -1329,7 +1329,7 @@ * or Google-chrome "browser" vs "pop-up". * https://github.com/bakkeby/patches/blob/master/dwm/dwm-windowrolerule-6.2.diff */ -#define WINDOWROLERULE_PATCH 0 +#define WINDOWROLERULE_PATCH 1 /* The winview patch allows switching the view to that of a given client from the all-window * view (Mod-0) using a keyboard shortcut. -- 2.38.1 From da86ba3b12cac731f4349a442408d14ce20b9047 Mon Sep 17 00:00:00 2001 From: odrling Date: Fri, 14 May 2021 20:04:15 +0200 Subject: [PATCH 09/30] discord window rules --- config.def.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/config.def.h b/config.def.h index 771985a..4d41130 100644 --- a/config.def.h +++ b/config.def.h @@ -492,6 +492,8 @@ static const Rule rules[] = { RULE(.wintype = WTYPE "UTILITY", .isfloating = 1) RULE(.wintype = WTYPE "TOOLBAR", .isfloating = 1) RULE(.wintype = WTYPE "SPLASH", .isfloating = 1) + RULE(.class = "discord", .tags = 1 << 0, .switchtag = 1, .monitor = 0) + RULE(.class = "lightcord", .tags = 1 << 0, .switchtag = 1, .monitor = 0) RULE(.class = "Firefox", .tags = 1 << 7, .switchtag = 1) RULE(.role = "browser", .tags = 1 << 7, .switchtag = 1) RULE(.class = "Ardour", .tags = 1 << 8, .monitor = 0) -- 2.38.1 From 0b591fc8a1f745d7425fb66ea25ac8898da3b3e5 Mon Sep 17 00:00:00 2001 From: odrling Date: Fri, 14 May 2021 20:08:27 +0200 Subject: [PATCH 10/30] apply one rule patch --- patches.def.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/patches.def.h b/patches.def.h index 1bc2e44..9da9a57 100644 --- a/patches.def.h +++ b/patches.def.h @@ -860,7 +860,7 @@ #define ON_EMPTY_KEYS_PATCH 0 /* Minor patch that prevents more than one rule being matched for a given client. */ -#define ONLY_ONE_RULE_MATCH_PATCH 0 +#define ONLY_ONE_RULE_MATCH_PATCH 1 /* This patch makes it so dwm will only exit via quit() if no windows are open. * This is to prevent you accidentally losing all your work. -- 2.38.1 From 19fcf9e340695cb419a2d8f4cd4c21cccbb6bf8d Mon Sep 17 00:00:00 2001 From: odrling Date: Sun, 20 Jun 2021 18:13:17 +0200 Subject: [PATCH 11/30] add agordejo rule --- config.def.h | 1 + 1 file changed, 1 insertion(+) diff --git a/config.def.h b/config.def.h index 4d41130..4dea55d 100644 --- a/config.def.h +++ b/config.def.h @@ -497,6 +497,7 @@ static const Rule rules[] = { RULE(.class = "Firefox", .tags = 1 << 7, .switchtag = 1) RULE(.role = "browser", .tags = 1 << 7, .switchtag = 1) RULE(.class = "Ardour", .tags = 1 << 8, .monitor = 0) + RULE(.class = "Agordejo", .tags = 1 << 8, .monitor = 0) RULE(.class = "qBittorrent", .tags = 1 << 6, .switchtag = 1, .monitor = 0) RULE(.class = "mpv", .instance = "syncplay-mpv", .monitor = 1) #if SCRATCHPADS_PATCH -- 2.38.1 From 3fbf2164023e18bcbfcded0d16a8e241582b884d Mon Sep 17 00:00:00 2001 From: odrling Date: Sat, 25 Sep 2021 14:36:07 +0200 Subject: [PATCH 12/30] start easyeffects on tag 9 --- config.def.h | 1 + 1 file changed, 1 insertion(+) diff --git a/config.def.h b/config.def.h index 4dea55d..a5e048a 100644 --- a/config.def.h +++ b/config.def.h @@ -497,6 +497,7 @@ static const Rule rules[] = { RULE(.class = "Firefox", .tags = 1 << 7, .switchtag = 1) RULE(.role = "browser", .tags = 1 << 7, .switchtag = 1) RULE(.class = "Ardour", .tags = 1 << 8, .monitor = 0) + RULE(.class = "easyeffects", .tags = 1 << 8, .monitor = 0) RULE(.class = "Agordejo", .tags = 1 << 8, .monitor = 0) RULE(.class = "qBittorrent", .tags = 1 << 6, .switchtag = 1, .monitor = 0) RULE(.class = "mpv", .instance = "syncplay-mpv", .monitor = 1) -- 2.38.1 From 0be5b62fc9764f45bfa96de5b08b3def438fa0e8 Mon Sep 17 00:00:00 2001 From: odrling Date: Thu, 25 Nov 2021 01:15:38 +0100 Subject: [PATCH 13/30] set carla to tag 9 --- config.def.h | 1 + 1 file changed, 1 insertion(+) diff --git a/config.def.h b/config.def.h index a5e048a..14fcda0 100644 --- a/config.def.h +++ b/config.def.h @@ -496,6 +496,7 @@ static const Rule rules[] = { RULE(.class = "lightcord", .tags = 1 << 0, .switchtag = 1, .monitor = 0) RULE(.class = "Firefox", .tags = 1 << 7, .switchtag = 1) RULE(.role = "browser", .tags = 1 << 7, .switchtag = 1) + RULE(.class = "Carla2", .tags = 1 << 8, .monitor = 0, .switchtag = 0) RULE(.class = "Ardour", .tags = 1 << 8, .monitor = 0) RULE(.class = "easyeffects", .tags = 1 << 8, .monitor = 0) RULE(.class = "Agordejo", .tags = 1 << 8, .monitor = 0) -- 2.38.1 From 06ff8f5cb55d6e6b272277f4e0b860b2e7bafc88 Mon Sep 17 00:00:00 2001 From: odrling Date: Wed, 22 Dec 2021 00:00:07 +0100 Subject: [PATCH 14/30] set dmenucmd to rofi --- config.def.h | 15 +-------------- patches.def.h | 2 +- 2 files changed, 2 insertions(+), 15 deletions(-) diff --git a/config.def.h b/config.def.h index 14fcda0..3ac75f7 100644 --- a/config.def.h +++ b/config.def.h @@ -158,7 +158,6 @@ static const char font[] = "sans 12"; #else static const char *fonts[] = { "sans:size=12" }; #endif // BAR_PANGO_PATCH -static const char dmenufont[] = "sans:size=12"; static char c000000[] = "#000000"; // placeholder value @@ -862,19 +861,7 @@ static const char *xkb_layouts[] = { static char dmenumon[2] = "0"; /* component of dmenucmd, manipulated in spawn() */ #endif // NODMENU_PATCH static const char *dmenucmd[] = { - "dmenu_run", - #if !NODMENU_PATCH - "-m", dmenumon, - #endif // NODMENU_PATCH - "-fn", dmenufont, - "-nb", normbgcolor, - "-nf", normfgcolor, - "-sb", selbgcolor, - "-sf", selfgcolor, - #if BAR_DMENUMATCHTOP_PATCH - topbar ? NULL : "-b", - #endif // BAR_DMENUMATCHTOP_PATCH - NULL + "rofi", "-combi-modi", "window,run", "-show", "combi", NULL }; static const char *termcmd[] = { "st", NULL }; static const char *passmenucmd[] = { "passmenu", NULL }; diff --git a/patches.def.h b/patches.def.h index 9da9a57..b3cd508 100644 --- a/patches.def.h +++ b/patches.def.h @@ -826,7 +826,7 @@ * compilation error because two lines of code hardcode dmenu into dwm. * https://dwm.suckless.org/patches/nodmenu/ */ -#define NODMENU_PATCH 0 +#define NODMENU_PATCH 1 /* This patch allows for toggleable client button bindings that have no modifiers. * This can, for example, allow you to move or resize using the mouse alone without holding -- 2.38.1 From e1ecf93b6a03995a888a33a32a5796ff5ce0b349 Mon Sep 17 00:00:00 2001 From: odrling Date: Wed, 20 Apr 2022 13:30:35 +0200 Subject: [PATCH 15/30] enable no border patch --- patches.def.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/patches.def.h b/patches.def.h index b3cd508..f722a74 100644 --- a/patches.def.h +++ b/patches.def.h @@ -820,7 +820,7 @@ /* Removes the border when there is only one window visible. * https://dwm.suckless.org/patches/noborder/ */ -#define NOBORDER_PATCH 0 +#define NOBORDER_PATCH 1 /* Enable modifying or removing dmenu in config.def.h which resulted previously in a * compilation error because two lines of code hardcode dmenu into dwm. -- 2.38.1 From 9b43d8e26bf97f64154c1df0a7025946fc759dc9 Mon Sep 17 00:00:00 2001 From: odrling Date: Wed, 20 Apr 2022 13:52:04 +0200 Subject: [PATCH 16/30] force swallow from alacritty --- config.def.h | 1 + 1 file changed, 1 insertion(+) diff --git a/config.def.h b/config.def.h index 3ac75f7..1fb36c8 100644 --- a/config.def.h +++ b/config.def.h @@ -501,6 +501,7 @@ static const Rule rules[] = { RULE(.class = "Agordejo", .tags = 1 << 8, .monitor = 0) RULE(.class = "qBittorrent", .tags = 1 << 6, .switchtag = 1, .monitor = 0) RULE(.class = "mpv", .instance = "syncplay-mpv", .monitor = 1) + RULE(.class = "Alacritty", .isterminal = 1) #if SCRATCHPADS_PATCH RULE(.instance = "spterm", .tags = SPTAG(0), .isfloating = 1) #endif // SCRATCHPADS_PATCH -- 2.38.1 From d44627cd5a5f7498c32348d3d4d1f686420f59df Mon Sep 17 00:00:00 2001 From: odrling Date: Wed, 20 Apr 2022 18:18:33 +0200 Subject: [PATCH 17/30] remove browser rules and add permanent --- config.def.h | 12 ++++-------- patches.def.h | 2 +- 2 files changed, 5 insertions(+), 9 deletions(-) diff --git a/config.def.h b/config.def.h index 1fb36c8..0f75c61 100644 --- a/config.def.h +++ b/config.def.h @@ -491,14 +491,10 @@ static const Rule rules[] = { RULE(.wintype = WTYPE "UTILITY", .isfloating = 1) RULE(.wintype = WTYPE "TOOLBAR", .isfloating = 1) RULE(.wintype = WTYPE "SPLASH", .isfloating = 1) - RULE(.class = "discord", .tags = 1 << 0, .switchtag = 1, .monitor = 0) - RULE(.class = "lightcord", .tags = 1 << 0, .switchtag = 1, .monitor = 0) - RULE(.class = "Firefox", .tags = 1 << 7, .switchtag = 1) - RULE(.role = "browser", .tags = 1 << 7, .switchtag = 1) - RULE(.class = "Carla2", .tags = 1 << 8, .monitor = 0, .switchtag = 0) - RULE(.class = "Ardour", .tags = 1 << 8, .monitor = 0) - RULE(.class = "easyeffects", .tags = 1 << 8, .monitor = 0) - RULE(.class = "Agordejo", .tags = 1 << 8, .monitor = 0) + RULE(.class = "Carla2", .tags = 1 << 8, .monitor = 0, .switchtag = 0, .ispermanent = 1) + RULE(.class = "Ardour", .tags = 1 << 8, .monitor = 0, .ispermanent = 1) + RULE(.class = "easyeffects", .tags = 1 << 8, .monitor = 0, .ispermanent = 1) + RULE(.class = "Agordejo", .tags = 1 << 8, .monitor = 0, .ispermanent = 1) RULE(.class = "qBittorrent", .tags = 1 << 6, .switchtag = 1, .monitor = 0) RULE(.class = "mpv", .instance = "syncplay-mpv", .monitor = 1) RULE(.class = "Alacritty", .isterminal = 1) diff --git a/patches.def.h b/patches.def.h index f722a74..a8b02bd 100644 --- a/patches.def.h +++ b/patches.def.h @@ -711,7 +711,7 @@ /* Adds rule option for clients to avoid accidental termination by killclient for sticky windows. * https://dwm.suckless.org/patches/ispermanent/ */ -#define ISPERMANENT_PATCH 0 +#define ISPERMANENT_PATCH 1 /* This patch adds key modes (like in vim or emacs) where chains of keyboard shortcuts * can be performed. -- 2.38.1 From 591dde9fceea670cb6de35a8084da6d722560c22 Mon Sep 17 00:00:00 2001 From: odrling Date: Wed, 20 Apr 2022 19:13:43 +0200 Subject: [PATCH 18/30] sendmon: keeptag patch --- dwm.c | 2 ++ patches.def.h | 4 ++++ 2 files changed, 6 insertions(+) diff --git a/dwm.c b/dwm.c index 60b25ea..3cd0e28 100644 --- a/dwm.c +++ b/dwm.c @@ -3306,11 +3306,13 @@ sendmon(Client *c, Monitor *m) #if SCRATCHPADS_PATCH && !RENAMED_SCRATCHPADS_PATCH if (!(c->tags & SPTAGMASK)) #endif // SCRATCHPADS_PATCH + #if !SENDMON_KEEPTAGS #if EMPTYVIEW_PATCH c->tags = (m->tagset[m->seltags] ? m->tagset[m->seltags] : 1); #else c->tags = m->tagset[m->seltags]; /* assign tags of target monitor */ #endif // EMPTYVIEW_PATCH + #endif // SENDMON_KEEPTAGS #if ATTACHABOVE_PATCH || ATTACHASIDE_PATCH || ATTACHBELOW_PATCH || ATTACHBOTTOM_PATCH attachx(c); #else diff --git a/patches.def.h b/patches.def.h index a8b02bd..1b509d2 100644 --- a/patches.def.h +++ b/patches.def.h @@ -1021,6 +1021,10 @@ */ #define SENDMON_KEEPFOCUS_PATCH 0 +/* This patch allow clients to keep their current tags when sent to another monitor + */ +#define SENDMON_KEEPTAGS 1 + /* This patch allows border pixels to be changed during runtime. * https://dwm.suckless.org/patches/setborderpx/ */ -- 2.38.1 From 2b11bc25a6c1f04d52d61d8036faeee4b5577a4e Mon Sep 17 00:00:00 2001 From: odrling Date: Wed, 20 Apr 2022 19:31:59 +0200 Subject: [PATCH 19/30] taglabels --- patches.def.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/patches.def.h b/patches.def.h index 1b509d2..080a2e3 100644 --- a/patches.def.h +++ b/patches.def.h @@ -170,12 +170,12 @@ #define BAR_SYSTRAY_PATCH 0 /* Show tag symbols in the bar. */ -#define BAR_TAGS_PATCH 1 +#define BAR_TAGS_PATCH 0 /* Show tag symbols + class of master window in the bar. * https://dwm.suckless.org/patches/taglabels/ */ -#define BAR_TAGLABELS_PATCH 0 +#define BAR_TAGLABELS_PATCH 1 /* This patch underlines the selected tag, or optionally all tags. * https://dwm.suckless.org/patches/underlinetags/ -- 2.38.1 From 5032dafe5d36bd4f0ca75a489d6e6cf219f2ee5e Mon Sep 17 00:00:00 2001 From: odrling Date: Wed, 20 Apr 2022 20:26:55 +0200 Subject: [PATCH 20/30] better taglabels --- config.def.h | 8 +++++--- dwm.c | 7 +++++++ patch/bar_taglabels.c | 10 ++++------ 3 files changed, 16 insertions(+), 9 deletions(-) diff --git a/config.def.h b/config.def.h index 0f75c61..2e3e330 100644 --- a/config.def.h +++ b/config.def.h @@ -95,8 +95,8 @@ static const unsigned int systrayspacing = 2; /* systray spacing */ static const int showsystray = 1; /* 0 means no systray */ #endif // BAR_SYSTRAY_PATCH #if BAR_TAGLABELS_PATCH -static const char ptagf[] = "[%s %s]"; /* format of a tag label */ -static const char etagf[] = "[%s]"; /* format of an empty tag */ +static const char ptagf[] = "%s: %s"; /* format of a tag label */ +static const char etagf[] = "%s"; /* format of an empty tag */ static const int lcaselbl = 0; /* 1 means make tag label lowercase */ #endif // BAR_TAGLABELS_PATCH #if BAR_UNDERLINETAGS_PATCH @@ -497,7 +497,9 @@ static const Rule rules[] = { RULE(.class = "Agordejo", .tags = 1 << 8, .monitor = 0, .ispermanent = 1) RULE(.class = "qBittorrent", .tags = 1 << 6, .switchtag = 1, .monitor = 0) RULE(.class = "mpv", .instance = "syncplay-mpv", .monitor = 1) - RULE(.class = "Alacritty", .isterminal = 1) + RULE(.class = "Alacritty", .isterminal = 1, .label = "\uf120") + RULE(.class = "Chromium-browser-chromium", .label = "\uf268") + RULE(.class = "firefox", .label = "\uf269") #if SCRATCHPADS_PATCH RULE(.instance = "spterm", .tags = SPTAG(0), .isfloating = 1) #endif // SCRATCHPADS_PATCH diff --git a/dwm.c b/dwm.c index 3cd0e28..baa0481 100644 --- a/dwm.c +++ b/dwm.c @@ -344,6 +344,7 @@ struct XkbInfo { typedef struct Client Client; struct Client { char name[256]; + char label[48]; float mina, maxa; #if CFACTS_PATCH float cfact; @@ -534,6 +535,7 @@ typedef struct { #endif // WINDOWROLERULE_PATCH const char *instance; const char *title; + const char *label; const char *wintype; unsigned int tags; #if SWITCHTAG_PATCH @@ -880,6 +882,9 @@ applyrules(Client *c) class = ch.res_class ? ch.res_class : broken; instance = ch.res_name ? ch.res_name : broken; wintype = getatomprop(c, netatom[NetWMWindowType], XA_ATOM); + + snprintf(c->label, 48, "%s", class); + #if WINDOWROLERULE_PATCH gettextprop(c->win, wmatom[WMWindowRole], role, sizeof(role)); #endif // WINDOWROLERULE_PATCH @@ -899,6 +904,8 @@ applyrules(Client *c) && (!r->instance || strstr(instance, r->instance)) && (!r->wintype || wintype == XInternAtom(dpy, r->wintype, False))) { + if (r->label) snprintf(c->label, 48, "%s", r->label); + #if CENTER_PATCH c->iscentered = r->iscentered; #endif // CENTER_PATCH diff --git a/patch/bar_taglabels.c b/patch/bar_taglabels.c index 9e6d441..f00a7be 100644 --- a/patch/bar_taglabels.c +++ b/patch/bar_taglabels.c @@ -17,17 +17,15 @@ width_taglabels(Bar *bar, BarArg *a) continue; #endif // BAR_HIDEVACANTTAGS_PATCH icon = tagicon(m, i); - XClassHint ch = { NULL, NULL }; + char *label = NULL; for (c = m->clients; c; c = c->next) { if (c->tags & (1 << i)) { - XGetClassHint(dpy, c->win, &ch); + label = c->label; break; } } - if (ch.res_class) { - if (lcaselbl) - ch.res_class[0] = tolower(ch.res_class[0]); - snprintf(m->taglabel[i], 64, ptagf, icon, ch.res_class); + if (label) { + snprintf(m->taglabel[i], 64, ptagf, icon, label); } else snprintf(m->taglabel[i], 64, etagf, icon); -- 2.38.1 From 03118bebb57bd6cc6cd9d1110f4ed34b56d57a24 Mon Sep 17 00:00:00 2001 From: odrling Date: Thu, 21 Apr 2022 01:55:12 +0200 Subject: [PATCH 21/30] no swallow syncplay mpv --- config.def.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/config.def.h b/config.def.h index 2e3e330..ba812f9 100644 --- a/config.def.h +++ b/config.def.h @@ -496,7 +496,7 @@ static const Rule rules[] = { RULE(.class = "easyeffects", .tags = 1 << 8, .monitor = 0, .ispermanent = 1) RULE(.class = "Agordejo", .tags = 1 << 8, .monitor = 0, .ispermanent = 1) RULE(.class = "qBittorrent", .tags = 1 << 6, .switchtag = 1, .monitor = 0) - RULE(.class = "mpv", .instance = "syncplay-mpv", .monitor = 1) + RULE(.class = "mpv", .instance = "syncplay-mpv", .monitor = 1, .noswallow = 1) RULE(.class = "Alacritty", .isterminal = 1, .label = "\uf120") RULE(.class = "Chromium-browser-chromium", .label = "\uf268") RULE(.class = "firefox", .label = "\uf269") -- 2.38.1 From a105afcd7b834a6e824c81b4e23113190b410ddf Mon Sep 17 00:00:00 2001 From: odrling Date: Thu, 21 Apr 2022 13:39:36 +0200 Subject: [PATCH 22/30] add thunderbird and ardour labels --- config.def.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/config.def.h b/config.def.h index ba812f9..d15a4db 100644 --- a/config.def.h +++ b/config.def.h @@ -492,7 +492,7 @@ static const Rule rules[] = { RULE(.wintype = WTYPE "TOOLBAR", .isfloating = 1) RULE(.wintype = WTYPE "SPLASH", .isfloating = 1) RULE(.class = "Carla2", .tags = 1 << 8, .monitor = 0, .switchtag = 0, .ispermanent = 1) - RULE(.class = "Ardour", .tags = 1 << 8, .monitor = 0, .ispermanent = 1) + RULE(.class = "Ardour", .tags = 1 << 8, .monitor = 0, .ispermanent = 1, .label = "\uf025") RULE(.class = "easyeffects", .tags = 1 << 8, .monitor = 0, .ispermanent = 1) RULE(.class = "Agordejo", .tags = 1 << 8, .monitor = 0, .ispermanent = 1) RULE(.class = "qBittorrent", .tags = 1 << 6, .switchtag = 1, .monitor = 0) @@ -500,6 +500,7 @@ static const Rule rules[] = { RULE(.class = "Alacritty", .isterminal = 1, .label = "\uf120") RULE(.class = "Chromium-browser-chromium", .label = "\uf268") RULE(.class = "firefox", .label = "\uf269") + RULE(.class = "Thunderbird", .label = "\uf01c") #if SCRATCHPADS_PATCH RULE(.instance = "spterm", .tags = SPTAG(0), .isfloating = 1) #endif // SCRATCHPADS_PATCH -- 2.38.1 From 3240907f0977144ed6505de75ed33655feb58149 Mon Sep 17 00:00:00 2001 From: odrling Date: Thu, 5 May 2022 17:29:55 +0200 Subject: [PATCH 23/30] use rofi run --- config.def.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/config.def.h b/config.def.h index d15a4db..5eeab9a 100644 --- a/config.def.h +++ b/config.def.h @@ -861,7 +861,7 @@ static const char *xkb_layouts[] = { static char dmenumon[2] = "0"; /* component of dmenucmd, manipulated in spawn() */ #endif // NODMENU_PATCH static const char *dmenucmd[] = { - "rofi", "-combi-modi", "window,run", "-show", "combi", NULL + "rofi", "-show", "run", NULL }; static const char *termcmd[] = { "st", NULL }; static const char *passmenucmd[] = { "passmenu", NULL }; -- 2.38.1 From 852036b5cc28891cee5f282173c84c569ae297e2 Mon Sep 17 00:00:00 2001 From: odrling Date: Thu, 26 May 2022 22:32:57 +0200 Subject: [PATCH 24/30] add st as terminal --- config.def.h | 1 + 1 file changed, 1 insertion(+) diff --git a/config.def.h b/config.def.h index 5eeab9a..46cf6c4 100644 --- a/config.def.h +++ b/config.def.h @@ -498,6 +498,7 @@ static const Rule rules[] = { RULE(.class = "qBittorrent", .tags = 1 << 6, .switchtag = 1, .monitor = 0) RULE(.class = "mpv", .instance = "syncplay-mpv", .monitor = 1, .noswallow = 1) RULE(.class = "Alacritty", .isterminal = 1, .label = "\uf120") + RULE(.class = "st-256color", .isterminal = 1, .label = "\uf120") RULE(.class = "Chromium-browser-chromium", .label = "\uf268") RULE(.class = "firefox", .label = "\uf269") RULE(.class = "Thunderbird", .label = "\uf01c") -- 2.38.1 From fed1fd27b8ef2c5dda8d87f3048eb1caf668461d Mon Sep 17 00:00:00 2001 From: odrling Date: Mon, 30 May 2022 01:53:40 +0200 Subject: [PATCH 25/30] add discord icon ig --- config.def.h | 1 + 1 file changed, 1 insertion(+) diff --git a/config.def.h b/config.def.h index 46cf6c4..f8fa04b 100644 --- a/config.def.h +++ b/config.def.h @@ -499,6 +499,7 @@ static const Rule rules[] = { RULE(.class = "mpv", .instance = "syncplay-mpv", .monitor = 1, .noswallow = 1) RULE(.class = "Alacritty", .isterminal = 1, .label = "\uf120") RULE(.class = "st-256color", .isterminal = 1, .label = "\uf120") + RULE(.class = "discord", .label = "\uf2ee") RULE(.class = "Chromium-browser-chromium", .label = "\uf268") RULE(.class = "firefox", .label = "\uf269") RULE(.class = "Thunderbird", .label = "\uf01c") -- 2.38.1 From ec27dab9b7b227144f5a7254376476d84d6aaa2a Mon Sep 17 00:00:00 2001 From: odrling Date: Thu, 2 Jun 2022 16:00:25 +0200 Subject: [PATCH 26/30] set correct fontawesome discord character --- config.def.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/config.def.h b/config.def.h index f8fa04b..fc709aa 100644 --- a/config.def.h +++ b/config.def.h @@ -499,7 +499,7 @@ static const Rule rules[] = { RULE(.class = "mpv", .instance = "syncplay-mpv", .monitor = 1, .noswallow = 1) RULE(.class = "Alacritty", .isterminal = 1, .label = "\uf120") RULE(.class = "st-256color", .isterminal = 1, .label = "\uf120") - RULE(.class = "discord", .label = "\uf2ee") + RULE(.class = "discord", .label = "\uf392") RULE(.class = "Chromium-browser-chromium", .label = "\uf268") RULE(.class = "firefox", .label = "\uf269") RULE(.class = "Thunderbird", .label = "\uf01c") -- 2.38.1 From 66c146fb3b3dda568836e571720ee7db193d42af Mon Sep 17 00:00:00 2001 From: odrling Date: Thu, 28 Jul 2022 14:55:49 +0200 Subject: [PATCH 27/30] set pid to rofi --- config.def.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/config.def.h b/config.def.h index fc709aa..81ed9a3 100644 --- a/config.def.h +++ b/config.def.h @@ -863,7 +863,7 @@ static const char *xkb_layouts[] = { static char dmenumon[2] = "0"; /* component of dmenucmd, manipulated in spawn() */ #endif // NODMENU_PATCH static const char *dmenucmd[] = { - "rofi", "-show", "run", NULL + "rofi", "-pid", "/tmp/rofi", "-show", "run", NULL }; static const char *termcmd[] = { "st", NULL }; static const char *passmenucmd[] = { "passmenu", NULL }; -- 2.38.1 From 0b35b663fe896c169f5f891d4589c041809f8f5b Mon Sep 17 00:00:00 2001 From: odrling Date: Tue, 11 Oct 2022 17:52:33 +0200 Subject: [PATCH 28/30] add windowmenu --- config.def.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/config.def.h b/config.def.h index 81ed9a3..a9551f7 100644 --- a/config.def.h +++ b/config.def.h @@ -865,6 +865,9 @@ static char dmenumon[2] = "0"; /* component of dmenucmd, manipulated in spawn() static const char *dmenucmd[] = { "rofi", "-pid", "/tmp/rofi", "-show", "run", NULL }; +static const char *windowmenu[] = { + "rofi", "-modi", "window", "-show", "window", NULL +}; static const char *termcmd[] = { "st", NULL }; static const char *passmenucmd[] = { "passmenu", NULL }; static const char *webmenucmd[] = { "webmenu", NULL }; @@ -902,6 +905,7 @@ static const Key keys[] = { #endif // KEYMODES_PATCH { MODKEY, XK_o, spawn, {.v = dmenucmd } }, { MODKEY|ShiftMask, XK_Return, spawn, {.v = termcmd } }, + { MODKEY, XK_w, spawn, {.v = windowmenu} }, #if RIODRAW_PATCH { MODKEY|ControlMask, XK_p, riospawnsync, {.v = dmenucmd } }, { MODKEY|ControlMask, XK_Return, riospawn, {.v = termcmd } }, -- 2.38.1 From a58a90a6cfdb129edc81c80ca881118616823ece Mon Sep 17 00:00:00 2001 From: odrling Date: Mon, 21 Nov 2022 10:34:44 +0100 Subject: [PATCH 29/30] add connect keybinding --- config.def.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/config.def.h b/config.def.h index a9551f7..4e039fb 100644 --- a/config.def.h +++ b/config.def.h @@ -863,7 +863,7 @@ static const char *xkb_layouts[] = { static char dmenumon[2] = "0"; /* component of dmenucmd, manipulated in spawn() */ #endif // NODMENU_PATCH static const char *dmenucmd[] = { - "rofi", "-pid", "/tmp/rofi", "-show", "run", NULL + "rofi", "-pid", "/tmp/rofi", "-show", "run", NULL }; static const char *windowmenu[] = { "rofi", "-modi", "window", "-show", "window", NULL @@ -873,6 +873,7 @@ static const char *passmenucmd[] = { "passmenu", NULL }; static const char *webmenucmd[] = { "webmenu", NULL }; static const char *screenshot[] = { "screenshot", NULL }; static const char *screenshots[] = { "screenshot", "-s", "-l", "-c", "0.75,0.5,1.0,0.1", NULL }; +static const char *connectcmd[] = { "connect", NULL }; #if BAR_STATUSCMD_PATCH #if BAR_DWMBLOCKS_PATCH @@ -905,7 +906,8 @@ static const Key keys[] = { #endif // KEYMODES_PATCH { MODKEY, XK_o, spawn, {.v = dmenucmd } }, { MODKEY|ShiftMask, XK_Return, spawn, {.v = termcmd } }, - { MODKEY, XK_w, spawn, {.v = windowmenu} }, + { MODKEY, XK_w, spawn, {.v = windowmenu } }, + { MODKEY, XK_c, spawn, {.v = connectcmd } }, #if RIODRAW_PATCH { MODKEY|ControlMask, XK_p, riospawnsync, {.v = dmenucmd } }, { MODKEY|ControlMask, XK_Return, riospawn, {.v = termcmd } }, -- 2.38.1 From 376249965d3c500a6b63615c7946d601fe0c2bb9 Mon Sep 17 00:00:00 2001 From: odrling Date: Mon, 21 Nov 2022 11:01:22 +0100 Subject: [PATCH 30/30] add taskmaster binding --- config.def.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/config.def.h b/config.def.h index 4e039fb..4ab4dec 100644 --- a/config.def.h +++ b/config.def.h @@ -874,6 +874,7 @@ static const char *webmenucmd[] = { "webmenu", NULL }; static const char *screenshot[] = { "screenshot", NULL }; static const char *screenshots[] = { "screenshot", "-s", "-l", "-c", "0.75,0.5,1.0,0.1", NULL }; static const char *connectcmd[] = { "connect", NULL }; +static const char *taskmaster[] = { "taskmaster", NULL }; #if BAR_STATUSCMD_PATCH #if BAR_DWMBLOCKS_PATCH @@ -908,6 +909,7 @@ static const Key keys[] = { { MODKEY|ShiftMask, XK_Return, spawn, {.v = termcmd } }, { MODKEY, XK_w, spawn, {.v = windowmenu } }, { MODKEY, XK_c, spawn, {.v = connectcmd } }, + { MODKEY, XK_t, spawn, {.v = taskmaster } }, #if RIODRAW_PATCH { MODKEY|ControlMask, XK_p, riospawnsync, {.v = dmenucmd } }, { MODKEY|ControlMask, XK_Return, riospawn, {.v = termcmd } }, -- 2.38.1