summary refs log tree commit diff
path: root/conf.c
diff options
context:
space:
mode:
authorokan <okan>2013-12-16 19:02:17 +0000
committerokan <okan>2013-12-16 19:02:17 +0000
commit19fc7f666bd8e2d5956a7a3958bf6be4f5fea137 (patch)
treea54a15eb8c86a88dd67c98f241a0ceb05d93ec96 /conf.c
parentf98f4615c0bf2fbf3f6229ccb9cb46284f3dd18a (diff)
downloadcwm-19fc7f666bd8e2d5956a7a3958bf6be4f5fea137.tar.gz
cwm-19fc7f666bd8e2d5956a7a3958bf6be4f5fea137.tar.xz
cwm-19fc7f666bd8e2d5956a7a3958bf6be4f5fea137.zip
Implement support for EWMH's _NET_WM_STATE_FULLSCREEN hint.
Since we already have a form of 'maximize', we need to differentiate
between 'maximize' and the new 'fullscreen' mode.  The 'maximize' mode
will continue to honor gap but now *retains* the border, matching the
'vert/horz maximize' behaviour.  The new 'fullscreen' mode supports and
follows the _NET_WM_STATE_FULLSCREEN hint, allowing the client perform
additional window modifications; in this mode, cwm(1) will *ignore* gap,
remove borders and freeze(move/resize) the client.  Additionally,
'fullscreen' mode will remember various combinations of previous states.

* default keybinding changes: CM-f 'fullscreen', CM-m 'maximize' (re-map
  as desired).

Positive feedback from a few, testing and ok sthen@
Diffstat (limited to 'conf.c')
-rw-r--r--conf.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/conf.c b/conf.c
index 445571b..9ac0414 100644
--- a/conf.c
+++ b/conf.c
@@ -178,7 +178,8 @@ static struct {
 	{ "M-Right",	"cyclegroup" },
 	{ "M-Left",	"rcyclegroup" },
 	{ "CM-g",	"grouptoggle" },
-	{ "CM-f",	"maximize" },
+	{ "CM-f",	"fullscreen" },
+	{ "CM-m",	"maximize" },
 	{ "CM-equal",	"vmaximize" },
 	{ "CMS-equal",	"hmaximize" },
 	{ "CMS-f",	"freeze" },
@@ -376,6 +377,7 @@ static struct {
 	{ "rcycleingroup", kbfunc_client_cycle, KBFLAG_NEEDCLIENT,
 	    {.i = CWM_RCYCLE|CWM_INGROUP} },
 	{ "grouptoggle", kbfunc_client_grouptoggle, KBFLAG_NEEDCLIENT, {0}},
+	{ "fullscreen", kbfunc_client_fullscreen, KBFLAG_NEEDCLIENT, {0} },
 	{ "maximize", kbfunc_client_maximize, KBFLAG_NEEDCLIENT, {0} },
 	{ "vmaximize", kbfunc_client_vmaximize, KBFLAG_NEEDCLIENT, {0} },
 	{ "hmaximize", kbfunc_client_hmaximize, KBFLAG_NEEDCLIENT, {0} },
@@ -688,6 +690,7 @@ static char *ewmhints[] = {
 	"_NET_WM_STATE",
 	"_NET_WM_STATE_MAXIMIZED_VERT",
 	"_NET_WM_STATE_MAXIMIZED_HORZ",
+	"_NET_WM_STATE_FULLSCREEN",
 	"_NET_WM_STATE_DEMANDS_ATTENTION",
 };