qtile: make (most) keys layout specific

This commit is contained in:
steveej 2022-08-06 22:01:39 +02:00
parent b7117efd37
commit 7e40c222d4

View file

@ -153,16 +153,21 @@ keys = [
Key([key_super, key_control], "l", lazy.layout.client_to_next().when(layout='stack')),
# Columns
Key([key_super], "h", lazy.layout.left().when(layout='columns')),
Key([key_super], "l", lazy.layout.right().when(layout='columns')),
Key([key_super], "j", lazy.layout.down().when(layout='columns')),
Key([key_super], "k", lazy.layout.up().when(layout='columns')),
Key([key_super, key_control], "j", lazy.layout.shuffle_down().when(layout='columns')),
Key([key_super, key_control], "k", lazy.layout.shuffle_up().when(layout='columns')),
Key([key_super, key_control], "h", lazy.layout.shuffle_left().when(layout='columns')),
Key([key_super, key_control], "l", lazy.layout.shuffle_right().when(layout='columns')),
Key([key_super], "h", lazy.layout.left().when(layout="columns")),
Key([key_super], "l", lazy.layout.right().when(layout="columns")),
Key([key_super], "j", lazy.layout.next().when(layout="columns")),
Key([key_super], "k", lazy.layout.previous().when(layout="columns")),
Key([key_super, key_control], "j", lazy.layout.shuffle_down().when(layout="columns")),
Key([key_super, key_control], "k", lazy.layout.shuffle_up().when(layout="columns")),
Key([key_super, key_control], "h", lazy.layout.shuffle_left().when(layout="columns")),
Key([key_super, key_control], "l", lazy.layout.shuffle_right().when(layout="columns")),
Key([key_super, key_control], "space", lazy.layout.toggle_split().when(layout="columns")),
# Max
Key([key_super], "j", lazy.layout.down().when(layout="max")),
Key([key_super], "k", lazy.layout.up().when(layout="max")),
# TODO: these are required to make the 'columns' layout work, but why?
Key([key_super], "j", lazy.layout.next()),
Key([key_super], "k", lazy.layout.previous()),