diff options
| author | bakkeby <[email protected]> | 2020-06-21 15:33:29 +0200 |
|---|---|---|
| committer | bakkeby <[email protected]> | 2020-06-21 15:33:29 +0200 |
| commit | 6a683c729e1e0f9eb8901421ef596ef2423ae92b (patch) | |
| tree | 80c2c36d724fd7940341369103171eb06c1aebc8 /config.def.h | |
| parent | 8645b2ce3568b4628f40fb99466c154edc0e338f (diff) | |
| download | dwm-flexipatch-6a683c729e1e0f9eb8901421ef596ef2423ae92b.tar.gz dwm-flexipatch-6a683c729e1e0f9eb8901421ef596ef2423ae92b.zip | |
Adding floatpos patch.
Diffstat (limited to 'config.def.h')
| -rw-r--r-- | config.def.h | 46 |
1 files changed, 46 insertions, 0 deletions
diff --git a/config.def.h b/config.def.h index 0a43c48..34850a3 100644 --- a/config.def.h +++ b/config.def.h @@ -28,6 +28,10 @@ static const int sidepad = 10; /* horizontal padding of bar */ #if FOCUSONCLICK_PATCH static const int focusonwheel = 0; #endif // FOCUSONCLICK_PATCH +#if FLOATPOS_PATCH +static int floatposgrid_x = 5; /* float grid columns */ +static int floatposgrid_y = 5; /* float grid rows */ +#endif // FLOATPOS_PATCH #if STATUSPADDING_PATCH static const int horizpadbar = 2; /* horizontal padding for statusbar */ static const int vertpadbar = 0; /* vertical padding for statusbar */ @@ -1033,6 +1037,48 @@ static Key keys[] = { { MODKEY|ControlMask, XK_KP_7, togglemaximize, {.i = +1} }, /* XK_KP_Home, */ { MODKEY|ControlMask, XK_KP_5, togglemaximize, {.i = 0} }, /* XK_KP_Begin, */ #endif // EXRESIZE_PATCH + #if FLOATPOS_PATCH + /* Note that due to key limitations the below example kybindings are defined with a Mod3Mask, + * which is not always readily available. Refer to the patch wiki for more details. */ + /* Client position is limited to monitor window area */ + { Mod3Mask, XK_u, floatpos, {.v = "-26x -26y" } }, + { Mod3Mask, XK_i, floatpos, {.v = " 0x -26y" } }, + { Mod3Mask, XK_o, floatpos, {.v = " 26x -26y" } }, + { Mod3Mask, XK_j, floatpos, {.v = "-26x 0y" } }, + { Mod3Mask, XK_l, floatpos, {.v = " 26x 0y" } }, + { Mod3Mask, XK_m, floatpos, {.v = "-26x 26y" } }, + { Mod3Mask, XK_comma, floatpos, {.v = " 0x 26y" } }, + { Mod3Mask, XK_period, floatpos, {.v = " 26x 26y" } }, + /* Absolute positioning (allows moving windows between monitors) */ + { Mod3Mask|ControlMask, XK_u, floatpos, {.v = "-26a -26a" } }, + { Mod3Mask|ControlMask, XK_i, floatpos, {.v = " 0a -26a" } }, + { Mod3Mask|ControlMask, XK_o, floatpos, {.v = " 26a -26a" } }, + { Mod3Mask|ControlMask, XK_j, floatpos, {.v = "-26a 0a" } }, + { Mod3Mask|ControlMask, XK_l, floatpos, {.v = " 26a 0a" } }, + { Mod3Mask|ControlMask, XK_m, floatpos, {.v = "-26a 26a" } }, + { Mod3Mask|ControlMask, XK_comma, floatpos, {.v = " 0a 26a" } }, + { Mod3Mask|ControlMask, XK_period, floatpos, {.v = " 26a 26a" } }, + /* Resize client, client center position is fixed which means that client expands in all directions */ + { Mod3Mask|ShiftMask, XK_u, floatpos, {.v = "-26w -26h" } }, + { Mod3Mask|ShiftMask, XK_i, floatpos, {.v = " 0w -26h" } }, + { Mod3Mask|ShiftMask, XK_o, floatpos, {.v = " 26w -26h" } }, + { Mod3Mask|ShiftMask, XK_j, floatpos, {.v = "-26w 0h" } }, + { Mod3Mask|ShiftMask, XK_k, floatpos, {.v = "800W 800H" } }, + { Mod3Mask|ShiftMask, XK_l, floatpos, {.v = " 26w 0h" } }, + { Mod3Mask|ShiftMask, XK_m, floatpos, {.v = "-26w 26h" } }, + { Mod3Mask|ShiftMask, XK_comma, floatpos, {.v = " 0w 26h" } }, + { Mod3Mask|ShiftMask, XK_period, floatpos, {.v = " 26w 26h" } }, + /* Client is positioned in a floating grid, movement is relative to client's current position */ + { Mod3Mask|Mod1Mask, XK_u, floatpos, {.v = "-1p -1p" } }, + { Mod3Mask|Mod1Mask, XK_i, floatpos, {.v = " 0p -1p" } }, + { Mod3Mask|Mod1Mask, XK_o, floatpos, {.v = " 1p -1p" } }, + { Mod3Mask|Mod1Mask, XK_j, floatpos, {.v = "-1p 0p" } }, + { Mod3Mask|Mod1Mask, XK_k, floatpos, {.v = " 0p 0p" } }, + { Mod3Mask|Mod1Mask, XK_l, floatpos, {.v = " 1p 0p" } }, + { Mod3Mask|Mod1Mask, XK_m, floatpos, {.v = "-1p 1p" } }, + { Mod3Mask|Mod1Mask, XK_comma, floatpos, {.v = " 0p 1p" } }, + { Mod3Mask|Mod1Mask, XK_period, floatpos, {.v = " 1p 1p" } }, + #endif // FLOATPOS_PATCH #if SETBORDERPX_PATCH { MODKEY|ControlMask, XK_minus, setborderpx, {.i = -1 } }, { MODKEY|ControlMask, XK_plus, setborderpx, {.i = +1 } }, |
