Layout/conf: Add toggle_resizehint uicb function.

This commit is contained in:
Martin Duquesnoy 2009-03-29 03:43:05 +02:00
parent c032d24640
commit d1fe3977a7
4 changed files with 18 additions and 0 deletions

View File

@ -55,6 +55,7 @@ conf_init_func_list(void)
{"set_nmaster", uicb_set_nmaster },
{"quit", uicb_quit },
{"toggle_infobar_position", uicb_infobar_togglepos },
{"toggle_resizehint", uicb_toggle_resizehint },
{"mouse_move", uicb_mouse_move },
{"mouse_resize", uicb_mouse_resize },
{"client_raise", uicb_client_raise },

View File

@ -513,6 +513,19 @@ uicb_togglemax(uicb_t cmd)
return;
}
/** Toggle the resizehint
* \param cmd uicb_t type
*/
void
uicb_toggle_resizehint(uicb_t cmd)
{
tags[selscreen][seltag[selscreen]].resizehint = !tags[selscreen][seltag[selscreen]].resizehint;
tags[selscreen][seltag[selscreen]].layout.func(selscreen);
return;
}
/** Set the layout
* \param cmd uicb_t type
*/

View File

@ -276,6 +276,7 @@ void uicb_layout_next(uicb_t);
void uicb_set_mwfact(uicb_t);
void uicb_set_nmaster(uicb_t);
void uicb_set_layout(uicb_t);
void uicb_toggle_resizehint(uicb_t);
/* init.c */
void init(void);

3
wmfsrc
View File

@ -178,6 +178,9 @@ keys
# Toggle the position of the infobar.
key { mod = {"Alt"} key = "b" func = "toggle_infobar_position" }
# Toggle the resizehint of the current tag/screen
key { mod = { "Shift", "Control" } key = "r" func = "toggle_resizehint" }
# Select the next client.
key { mod = {"Alt"} key = "Tab" func = "client_next" }