summaryrefslogtreecommitdiff
path: root/.config/qtile
diff options
context:
space:
mode:
Diffstat (limited to '.config/qtile')
-rw-r--r--.config/qtile/keys.py80
1 files changed, 40 insertions, 40 deletions
diff --git a/.config/qtile/keys.py b/.config/qtile/keys.py
index 1cb3d6e..efd1bb0 100644
--- a/.config/qtile/keys.py
+++ b/.config/qtile/keys.py
@@ -7,124 +7,124 @@ from libqtile.command import lazy
class MyKeys():
- def init_keys(self,
- mod="mod4",
- browser="qutebrowser",
- term="alacritty",
- ):
+ def __init__(self,mod,browser,term):
+ self.mod = mod
+ self.browser = browser
+ self.term = term
+ def init_keys(self):
my_keys = [
- Key([mod], "Return",
- lazy.spawn(term),
+ Key([self.mod], "Return",
+ lazy.spawn(self.term),
desc='Launches My Terminal'
),
- Key([mod, "shift"], "a",
+ Key([self.mod, "shift"], "a",
lazy.spawn('anki'),
desc='Launch anki'),
- Key([mod, "shift"], "m",
+ Key([self.mod, "shift"], "m",
lazy.spawn("spotify"),
desc="Laucnh spotify"),
- Key([mod], "Tab",
+ Key([self.mod], "Tab",
lazy.spawn("dmenu_run -p 'Run: '"),
desc='Run Launcher'
),
- Key([mod], "p",
+ Key([self.mod], "p",
lazy.spawn("passmenu -p 'Password for: '"),
),
- Key([mod], "b",
- lazy.spawn(browser),
- desc='Qutebrowser'
+ Key([self.mod], "b",
+ lazy.spawn(self.browser),
+ desc="Open browser"
),
- Key([mod, "shift"], "c",
+ Key([self.mod, "shift"], "c",
lazy.next_layout(),
desc='Toggle through layouts'
),
- Key([mod], "q",
+ Key([self.mod], "q",
lazy.window.kill(),
desc='Kill active window'
),
- Key([mod, "shift"], "r",
+ Key([self.mod, "shift"], "r",
lazy.restart(),
desc='Restart Qtile'
),
- Key([mod, "shift"], "0",
+ Key([self.mod, "shift"], "0",
lazy.shutdown(),
desc='Shutdown Qtile'
),
- Key([mod, "shift"], "e",
+ Key([self.mod, "shift"], "e",
lazy.spawn("emacsclient -c -a 'emacs'"),
desc='Doom Emacs'
),
### Switch focus of monitors
- Key([mod], "period",
+ Key([self.mod], "period",
lazy.next_screen(),
desc='Move focus to next monitor'
),
- Key([mod], "comma",
+ Key([self.mod], "comma",
lazy.prev_screen(),
desc='Move focus to prev monitor'
),
### Treetab controls
- Key([mod, "shift"], "h",
+ Key([self.mod, "shift"], "h",
lazy.layout.move_left(),
desc='Move up a section in treetab'
),
- Key([mod, "shift"], "l",
+ Key([self.mod, "shift"], "l",
lazy.layout.move_right(),
desc='Move down a section in treetab'
),
### Window controls
- Key([mod], "j",
+ Key([self.mod], "j",
lazy.layout.down(),
desc='Move focus down in current stack pane'
),
- Key([mod], "k",
+ Key([self.mod], "k",
lazy.layout.up(),
desc='Move focus up in current stack pane'
),
- Key([mod, "shift"], "j",
+ Key([self.mod, "shift"], "j",
lazy.layout.shuffle_down(),
lazy.layout.section_down(),
desc='Move windows down in current stack'
),
- Key([mod, "shift"], "k",
+ Key([self.mod, "shift"], "k",
lazy.layout.shuffle_up(),
lazy.layout.section_up(),
desc='Move windows up in current stack'
),
- Key([mod], "h",
+ Key([self.mod], "h",
lazy.layout.shrink(),
lazy.layout.decrease_nmaster(),
desc='Shrink window (MonadTall), decrease number in master pane (Tile)'
),
- Key([mod], "l",
+ Key([self.mod], "l",
lazy.layout.grow(),
lazy.layout.increase_nmaster(),
desc='Expand window (MonadTall), increase number in master pane (Tile)'
),
- Key([mod], "n",
+ Key([self.mod], "n",
lazy.layout.normalize(),
desc='normalize window size ratios'
),
- Key([mod], "m",
+ Key([self.mod], "m",
lazy.layout.maximize(),
desc='toggle window between minimum and maximum sizes'
),
- Key([mod, "shift"], "f",
+ Key([self.mod, "shift"], "f",
lazy.window.toggle_floating(),
desc='toggle floating'
),
- Key([mod], "f",
+ Key([self.mod], "f",
lazy.window.toggle_fullscreen(),
desc='toggle fullscreen'
),
### Stack controls
- Key([mod, "shift"], "Tab",
+ Key([self.mod, "shift"], "Tab",
lazy.layout.rotate(),
lazy.layout.flip(),
desc='Switch which side main pane occupies (XmonadTall)'
),
- Key([mod, "shift"], "space",
+ Key([self.mod, "shift"], "space",
lazy.layout.toggle_split(),
desc='Toggle between split and unsplit sides of stack'
),
@@ -138,24 +138,24 @@ class MyKeys():
desc="Increase volume"
),
### Spotify
- Key([mod, "shift"], "p",
+ Key([self.mod, "shift"], "p",
lazy.spawn("spotify-control play-pause"),
desc="play/pause music"
),
- Key([mod, "shift"], "n",
+ Key([self.mod, "shift"], "n",
lazy.spawn("spotify-control next"),
desc="next song"
),
- Key([mod, "shift"], "b",
+ Key([self.mod, "shift"], "b",
lazy.spawn("spotify-control previous"),
desc="previous song"
),
### Change languages
- Key([mod], "F1",
+ Key([self.mod], "F1",
lazy.spawn("setxkbmap us -option caps:swapescape"),
desc= "change to US layout"
),
- Key([mod],"F2",
+ Key([self.mod],"F2",
lazy.spawn("setxkbmap gr"),
desc= "change to greek layout"
),