2020-12-01 20:10:22 +01:00
|
|
|
# {{@@ header() @@}}
|
|
|
|
# _____ ____ _ _ _
|
|
|
|
# / __\ \ /\ / / _` | | | |
|
|
|
|
# \__ \\ V V / (_| | |_| |
|
|
|
|
# |___/ \_/\_/ \__,_|\__, |
|
|
|
|
# |___/
|
|
|
|
|
2020-12-06 17:47:37 +01:00
|
|
|
bindsym --to-code {
|
2020-12-01 20:10:22 +01:00
|
|
|
|
|
|
|
###############################################################
|
|
|
|
# Moving around
|
|
|
|
###############################################################
|
|
|
|
|
2021-04-16 22:33:54 +02:00
|
|
|
{%@@ for prefix in ["","$"] @@%}
|
|
|
|
{%@@ for dir in "Left,Up,Right,Down".split(',') @@%}
|
|
|
|
{%@@ set resize_cmd = "{} {} 20px".format(
|
|
|
|
('shrink' if (loop.index0 < 2) else 'grow'),
|
|
|
|
('height' if (loop.index0 % 2) else 'width'),
|
|
|
|
) @@%}
|
|
|
|
{%@@ set d = "{}{}".format(prefix,dir) @@%}
|
|
|
|
{#@@ Move focus @@#}
|
|
|
|
$mod+{{@@ d @@}} focus {{@@ dir @@}}
|
|
|
|
{#@@ Move window @@#}
|
|
|
|
$mod+Shift+{{@@ d @@}} move {{@@ dir @@}}
|
|
|
|
{#@@ Resize window @@#}
|
|
|
|
$mod+Control+{{@@ d @@}} resize {{@@ resize_cmd @@}}
|
|
|
|
{#@@ focus output @@#}
|
|
|
|
$mod+mod1+{{@@ d @@}} focus output {{@@ dir @@}}
|
|
|
|
{#@@ Move workspace to output @@#}
|
|
|
|
$mod+mod1+Shift+{{@@ d @@}} move workspace output {{@@ dir @@}}
|
|
|
|
{%@@ endfor @@%}
|
2020-12-01 20:10:22 +01:00
|
|
|
{%@@ endfor @@%}
|
|
|
|
|
|
|
|
|
|
|
|
###############################################################
|
|
|
|
# Workspaces
|
|
|
|
###############################################################
|
|
|
|
|
|
|
|
# Switch to workspace
|
|
|
|
# Move focused container to workspace
|
|
|
|
{%@@ for i in range(1,11) @@%}
|
2021-02-17 05:32:24 +01:00
|
|
|
$mod+{{@@ i%10 @@}} workspace {{@@ i @@}}
|
2020-12-01 20:10:22 +01:00
|
|
|
$mod+Shift+{{@@ i%10 @@}} move container workspace {{@@ i @@}}
|
|
|
|
{%@@ endfor @@%}
|
|
|
|
|
|
|
|
# go/move to Workspaces
|
|
|
|
# button8,9 = Mouse next/prev button
|
2020-12-11 18:17:03 +01:00
|
|
|
# Prior,Next = PageUp/Down
|
2020-12-01 20:10:22 +01:00
|
|
|
{%@@ for targ, buttons in {
|
2021-10-23 01:35:29 +02:00
|
|
|
"prev_on_output": [ key.tabL, "bracketleft", "Prior", "button9", "button4", ],
|
|
|
|
"next_on_output": [ key.tabR, "bracketright", "Next", "button8", "button5", ],
|
2020-12-01 20:10:22 +01:00
|
|
|
}.items() @@%}
|
|
|
|
{%@@ for button in buttons @@%}
|
|
|
|
{%@@ set pref = ("--whole-window " if "button" in button) @@%}
|
|
|
|
{{@@ pref @@}}$mod+{{@@ button @@}} workspace {{@@ targ @@}}
|
|
|
|
{{@@ pref @@}}$mod+Shift+{{@@ button @@}} move workspace {{@@ targ @@}}
|
|
|
|
{%@@ endfor @@%}
|
|
|
|
{%@@ endfor @@%}
|
|
|
|
|
2022-02-24 20:59:20 +01:00
|
|
|
$mod+Tab workspace next_on_output
|
|
|
|
$mod+Shift+Tab workspace prev_on_output
|
|
|
|
|
2020-12-01 20:10:22 +01:00
|
|
|
|
|
|
|
###############################################################
|
|
|
|
# Layout
|
|
|
|
###############################################################
|
|
|
|
|
|
|
|
# Splits
|
|
|
|
$mod+v splitv
|
|
|
|
# No splith since we can just mod+r
|
|
|
|
|
|
|
|
# Layout styles
|
2021-06-15 07:43:13 +02:00
|
|
|
$mod+t layout toggle split tabbed stacking
|
2020-12-01 20:10:22 +01:00
|
|
|
$mod+r layout toggle split
|
|
|
|
|
|
|
|
# Make the current focus fullscreen
|
|
|
|
$mod+f fullscreen
|
|
|
|
|
|
|
|
# Floating
|
|
|
|
$mod+Shift+space floating toggle
|
|
|
|
$mod+space focus mode_toggle
|
|
|
|
|
|
|
|
# Move focus to the parent container
|
2021-03-31 02:37:07 +02:00
|
|
|
$mod+equal focus parent
|
|
|
|
$mod+minus focus child
|
2020-12-01 20:10:22 +01:00
|
|
|
|
2022-02-24 20:59:20 +01:00
|
|
|
# $mod+tab scratchpad show
|
|
|
|
# $mod+Shift+tab move container scratchpad
|
2021-03-11 06:21:17 +01:00
|
|
|
|
2020-12-01 20:10:22 +01:00
|
|
|
}
|
|
|
|
|
2020-12-01 20:30:44 +01:00
|
|
|
# vim: ft=i3
|