monocle and set_layout func
This commit is contained in:
+37
-6
@@ -33,29 +33,60 @@ static const char *workspaces[] = {
|
||||
"3",
|
||||
"4",
|
||||
"5",
|
||||
"6",
|
||||
"7",
|
||||
"8",
|
||||
"9",
|
||||
"10",
|
||||
};
|
||||
|
||||
static const absn_keybind keybinds[] = {
|
||||
{ ALT, XKB_KEY_Escape, quit, { 0 } },
|
||||
|
||||
{ ALT, XKB_KEY_Return, &run, { .v = "alacritty" } },
|
||||
{ ALT, XKB_KEY_q, kill_focus, { 0 } },
|
||||
|
||||
{ ALT, XKB_KEY_j, cycle_focus, { .i = +1 } },
|
||||
{ ALT, XKB_KEY_k, cycle_focus, { .i = -1 } },
|
||||
|
||||
{ ALT, XKB_KEY_f, toggle_fullscreen, { 0 } },
|
||||
|
||||
{ ALT, XKB_KEY_h, increase_master_count, { .i = +1 } },
|
||||
{ ALT, XKB_KEY_l, increase_master_count, { .i = -1 } },
|
||||
|
||||
{ ALT | SHIFT, XKB_KEY_h, increase_master_width, { .f = -0.05 } },
|
||||
{ ALT | SHIFT, XKB_KEY_l, increase_master_width, { .f = +0.05 } },
|
||||
|
||||
{ ALT, XKB_KEY_t, set_layout, { .i = LAYOUT_TILE } },
|
||||
{ ALT, XKB_KEY_m, set_layout, { .i = LAYOUT_MONOCLE } },
|
||||
|
||||
{ ALT, XKB_KEY_1, switch_workspace, { .v = "1" } },
|
||||
{ ALT, XKB_KEY_2, switch_workspace, { .v = "2" } },
|
||||
{ ALT, XKB_KEY_3, switch_workspace, { .v = "3" } },
|
||||
{ ALT, XKB_KEY_4, switch_workspace, { .v = "4" } },
|
||||
{ ALT, XKB_KEY_5, switch_workspace, { .v = "5" } },
|
||||
{ ALT | SHIFT, XKB_KEY_exclam, focus_move_to_workspace, { .v = "1" } },
|
||||
{ ALT | SHIFT, XKB_KEY_2, focus_move_to_workspace, { .v = "2" } },
|
||||
{ ALT | SHIFT, XKB_KEY_3, focus_move_to_workspace, { .v = "3" } },
|
||||
{ ALT | SHIFT, XKB_KEY_4, focus_move_to_workspace, { .v = "4" } },
|
||||
{ ALT | SHIFT, XKB_KEY_5, focus_move_to_workspace, { .v = "5" } },
|
||||
{ ALT, XKB_KEY_Escape, quit, { 0 } },
|
||||
{ ALT, XKB_KEY_6, switch_workspace, { .v = "6" } },
|
||||
{ ALT, XKB_KEY_7, switch_workspace, { .v = "7" } },
|
||||
{ ALT, XKB_KEY_8, switch_workspace, { .v = "8" } },
|
||||
{ ALT, XKB_KEY_9, switch_workspace, { .v = "9" } },
|
||||
{ ALT, XKB_KEY_0, switch_workspace, { .v = "10" } },
|
||||
|
||||
{ ALT | SHIFT, XKB_KEY_exclam, move_focus_to_workspace, { .v = "1" } },
|
||||
{ ALT | SHIFT, XKB_KEY_at, move_focus_to_workspace, { .v = "2" } },
|
||||
{ ALT | SHIFT, XKB_KEY_numbersign, move_focus_to_workspace,
|
||||
{ .v = "3" } },
|
||||
{ ALT | SHIFT, XKB_KEY_dollar, move_focus_to_workspace, { .v = "4" } },
|
||||
{ ALT | SHIFT, XKB_KEY_percent, move_focus_to_workspace, { .v = "5" } },
|
||||
{ ALT | SHIFT, XKB_KEY_asciicircum, move_focus_to_workspace,
|
||||
{ .v = "6" } },
|
||||
{ ALT | SHIFT, XKB_KEY_ampersand, move_focus_to_workspace,
|
||||
{ .v = "7" } },
|
||||
{ ALT | SHIFT, XKB_KEY_asterisk, move_focus_to_workspace,
|
||||
{ .v = "8" } },
|
||||
{ ALT | SHIFT, XKB_KEY_parenleft, move_focus_to_workspace,
|
||||
{ .v = "9" } },
|
||||
{ ALT | SHIFT, XKB_KEY_parenright, move_focus_to_workspace,
|
||||
{ .v = "10" } },
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
+3
-1
@@ -13,7 +13,9 @@ void increase_master_width(absn_server *server, const absn_arg *arg);
|
||||
void increase_master_count(absn_server *server, const absn_arg *arg);
|
||||
|
||||
void switch_workspace(absn_server *server, const absn_arg *arg);
|
||||
void focus_move_to_workspace(absn_server *server, const absn_arg *arg);
|
||||
void move_focus_to_workspace(absn_server *server, const absn_arg *arg);
|
||||
|
||||
void set_layout(absn_server *server, const absn_arg *arg);
|
||||
|
||||
void quit(absn_server *server, const absn_arg *arg);
|
||||
|
||||
|
||||
+1
-2
@@ -79,13 +79,12 @@ static const int layermap[] = {
|
||||
|
||||
enum {
|
||||
LAYOUT_TILE,
|
||||
LAYOUT_FLOAT,
|
||||
LAYOUT_MONOCLE,
|
||||
LAYOUT_TILELEFT,
|
||||
LAYOUT_TILETOP,
|
||||
LAYOUT_TILEBOTTOM,
|
||||
LAYOUT_SPIRAL,
|
||||
LAYOUT_DWINDLE,
|
||||
LAYOUT_MAX,
|
||||
LAYOUT_VGRID,
|
||||
LAYOUT_HGRID,
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user