diff -r 2902c669f75b config.def.h --- a/config.def.h Wed Jun 11 17:01:30 2008 +0100 +++ b/config.def.h Wed Jun 11 17:05:27 2008 +0100 @@ -32,6 +32,17 @@ static Layout layouts[] = { { "><>", NULL }, /* no layout function means floating behavior */ }; +static void +kbmvresize(const Arg *arg) { + if(!sel || (lt->arrange && !sel->isfloating)) + return; + + resize(sel, sel->x + ((int *)arg->v)[0], + sel->y + ((int *)arg->v)[1], + sel->w + ((int *)arg->v)[2], + sel->h + ((int *)arg->v)[3], True); +} + /* key definitions */ #define MODKEY Mod1Mask #define TAGKEYS(KEY,TAG) \ @@ -45,6 +56,14 @@ static Layout layouts[] = { static Key keys[] = { /* modifier key function argument */ + { MODKEY, XK_Left, kbmvresize, {.v = (int []){ -40, 0, 0, 0 } } }, + { MODKEY, XK_Up, kbmvresize, {.v = (int []){ 0, -40, 0, 0 } } }, + { MODKEY, XK_Right, kbmvresize, {.v = (int []){ 40, 0, 0, 0 } } }, + { MODKEY, XK_Down, kbmvresize, {.v = (int []){ 0, 40, 0, 0 } } }, + { MODKEY|ShiftMask, XK_Left, kbmvresize, {.v = (int []){ 0, 0, -40, 0 } } }, + { MODKEY|ShiftMask, XK_Up, kbmvresize, {.v = (int []){ 0, 0, 0, -40 } } }, + { MODKEY|ShiftMask, XK_Right, kbmvresize, {.v = (int []){ 0, 0, 40, 0 } } }, + { MODKEY|ShiftMask, XK_Down, kbmvresize, {.v = (int []){ 0, 0, 0, 40 } } }, { MODKEY, XK_p, spawn, {.v = (char *[]){"dmenu_run", "-fn", FONT, "-nb", NORMBGCOLOR, "-nf", NORMFGCOLOR, "-sb", SELBGCOLOR, "-sf", SELFGCOLOR, NULL}} }, { MODKEY|ShiftMask, XK_Return, spawn, {.v = (char *[]){"uxterm", NULL}} }, { MODKEY, XK_b, togglebar, {0}},