diff --git a/dwm/config.def.h b/dwm/config.def.h index b4d36d93d207c33362b9688d3c3daac32983a316..fd63e721ecf863562d53c533980a658b496ec769 100644 --- a/dwm/config.def.h +++ b/dwm/config.def.h @@ -80,6 +80,7 @@ static Key keys[] = { { MODKEY, XK_m, setlayout, {.v = &layouts[2]} }, { MODKEY, XK_space, setlayout, {0} }, { MODKEY|ShiftMask, XK_space, togglefloating, {0} }, + { MODKEY|ShiftMask, XK_f, togglefullscr, {0} }, { MODKEY, XK_0, view, {.ui = ~0 } }, { MODKEY|ShiftMask, XK_0, tag, {.ui = ~0 } }, { MODKEY, XK_comma, focusmon, {.i = -1 } }, diff --git a/dwm/dwm.c b/dwm/dwm.c index 4465af1bf37d03ff16ae0726c55421ebc9ec75a9..c1b899a561ebcb1f221eb4dd537c20bf237e41e7 100644 --- a/dwm/dwm.c +++ b/dwm/dwm.c @@ -211,6 +211,7 @@ static void tagmon(const Arg *arg); static void tile(Monitor *); static void togglebar(const Arg *arg); static void togglefloating(const Arg *arg); +static void togglefullscr(const Arg *arg); static void toggletag(const Arg *arg); static void toggleview(const Arg *arg); static void unfocus(Client *c, int setfocus); @@ -1719,6 +1720,13 @@ togglefloating(const Arg *arg) arrange(selmon); } +void +togglefullscr(const Arg *arg) +{ + if(selmon->sel) + setfullscreen(selmon->sel, !selmon->sel->isfullscreen); +} + void toggletag(const Arg *arg) {