Grid Mode Layout & Rule Changes

- Enable grid mode layout patch
- Add keybinding to switch to grid mode w/ and w/o floating window flattening
- Remove Gimp and Firefox tag rules
- Add Picture in picture floating rule
This commit is contained in:
Sravan Balaji 2021-06-18 21:32:15 -04:00
parent eb144c8789
commit 5f2b977c1e
3 changed files with 9 additions and 8 deletions

View File

@ -2949,7 +2949,7 @@ Gridmode (grid) layout.
https://dwm.suckless.org/patches/gridmode/
#+begin_src c :tangle patches.def.h
#define GRIDMODE_LAYOUT 0
#define GRIDMODE_LAYOUT 1
#+end_src
**** Gapless
@ -3691,8 +3691,7 @@ The RULE macro has the default values set for each field allowing you to only sp
RULE(.class = "Firefox", .tags = 1 << 7)
#+end_example
Refer to the Rule struct definition for the list of available fields depending on
the patches you enable.
Refer to the Rule struct definition for the list of available fields depending on the patches you enable.
#+begin_example
xprop(1):
@ -3708,9 +3707,8 @@ The RULE macro has the default values set for each field allowing you to only sp
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)
RULE(.title = "Origin", .isfloating = 1)
RULE(.title = "Picture in picture", .isfloating = 1)
#if SCRATCHPADS_PATCH
RULE(.instance = "spterm", .tags = SPTAG(0), .isfloating = 1)
#endif // SCRATCHPADS_PATCH
@ -4392,6 +4390,7 @@ name - does nothing, intended for visual clue and for logging / debugging
{ MODKEY, XK_t, setlayout, {.v = &layouts[0]} },
{ MODKEY, XK_f, setlayout, {.v = &layouts[1]} },
{ MODKEY, XK_m, setlayout, {.v = &layouts[2]} },
{ MODKEY, XK_g, setlayout, {.v = &layouts[3]} },
#if COLUMNS_LAYOUT
{ MODKEY, XK_c, setlayout, {.v = &layouts[3]} },
@ -4434,6 +4433,7 @@ name - does nothing, intended for visual clue and for logging / debugging
{ MODKEY|Mod1Mask, XK_space, unfloatvisible, {0} },
{ MODKEY|ShiftMask, XK_t, unfloatvisible, {.v = &layouts[0]} },
{ MODKEY|ShiftMask, XK_m, unfloatvisible, {.v = &layouts[2]} },
{ MODKEY|ShiftMask, XK_g, unfloatvisible, {.v = &layouts[3]} },
#endif // UNFLOATVISIBLE_PATCH
#if TOGGLEFULLSCREEN_PATCH

View File

@ -390,9 +390,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 = "Gimp", .tags = 1 << 4)
RULE(.class = "Firefox", .tags = 1 << 7)
RULE(.title = "Origin", .isfloating = 1)
RULE(.title = "Picture in picture", .isfloating = 1)
#if SCRATCHPADS_PATCH
RULE(.instance = "spterm", .tags = SPTAG(0), .isfloating = 1)
#endif // SCRATCHPADS_PATCH
@ -1009,6 +1008,7 @@ 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_g, setlayout, {.v = &layouts[3]} },
#if COLUMNS_LAYOUT
{ MODKEY, XK_c, setlayout, {.v = &layouts[3]} },
@ -1051,6 +1051,7 @@ static Key keys[] = {
{ MODKEY|Mod1Mask, XK_space, unfloatvisible, {0} },
{ MODKEY|ShiftMask, XK_t, unfloatvisible, {.v = &layouts[0]} },
{ MODKEY|ShiftMask, XK_m, unfloatvisible, {.v = &layouts[2]} },
{ MODKEY|ShiftMask, XK_g, unfloatvisible, {.v = &layouts[3]} },
#endif // UNFLOATVISIBLE_PATCH
#if TOGGLEFULLSCREEN_PATCH

View File

@ -353,7 +353,7 @@
#define FLEXTILE_DELUXE_LAYOUT 0
#define GRIDMODE_LAYOUT 0
#define GRIDMODE_LAYOUT 1
#define GAPPLESSGRID_LAYOUT 0