From 234bf9a03da71d2731db8c09a6f4d509f8a44fd9 Mon Sep 17 00:00:00 2001 From: David Runge Date: Wed, 29 Mar 2017 15:01:52 +0200 Subject: .config/qtile/config.py: Fixing syntax. --- .config/qtile/config.py | 43 +++++++++++++++++++++++++++++-------------- 1 file changed, 29 insertions(+), 14 deletions(-) (limited to '.config') diff --git a/.config/qtile/config.py b/.config/qtile/config.py index 70e6bdb..fdd53a9 100644 --- a/.config/qtile/config.py +++ b/.config/qtile/config.py @@ -25,16 +25,18 @@ audio_next = home+"/bin/notify_mpd next" audio_toggle = home+"/bin/notify_mpd toggle" audio_stop = home+"/bin/notify_mpd stop" + # startup @hook.subscribe.startup def autostart(): background = ['feh', - '--randomize', - '--recursive', - '--bg-fill', - home+'/cloud/photos/desktop/'] + '--randomize', + '--recursive', + '--bg-fill', + home+'/cloud/photos/desktop/'] subprocess.call(background) + colors = { "grey": "#555555", "red": "#DD1144", @@ -43,9 +45,11 @@ colors = { "green": "#008080", } + # kick a window to another screen (handy during presentations) def move_to_other_screen(qtile, direction=1): - other_scr_index = (qtile.screens.index(qtile.currentScreen) + direction) % len(qtile.screens) + other_scr_index = (qtile.screens.index(qtile.currentScreen) + direction) \ + % len(qtile.screens) othergroup = None for group in qtile.cmd_groups().values(): if group['screen'] == other_scr_index: @@ -54,6 +58,7 @@ def move_to_other_screen(qtile, direction=1): if othergroup: qtile.moveToGroup(othergroup) + keys = [ # base commands # restart qtile @@ -245,10 +250,10 @@ layouts = [ ), layout.TreeTab( active_bg=colors["red"][1:], - #active_fg=colors["grey"][1:], + # active_fg=colors["grey"][1:], active_fg='ffffff', inactive_bg=colors["green"][1:], - #inactive_fg=colors["lgrey"][1:], + # inactive_fg=colors["lgrey"][1:], inactive_fg='ffffff', border_focus=colors["red"][1:], border_normal=colors["green"][1:], @@ -337,8 +342,7 @@ screens = [ timezone="Europe/Berlin", format="%Y%m%d %a %H:%M:%S" ), - ], - 20 + ], 20 ), ), Screen( @@ -361,17 +365,27 @@ screens = [ timezone="Europe/Berlin", format="%Y%m%d %a %H:%M:%S" ), - ], - 20 + ], 20 ), ), ] # Drag floating layouts. mouse = [ - Drag([mod], "Button1", lazy.window.set_position_floating(), start=lazy.window.get_position()), - Drag([mod], "Button3", lazy.window.set_size_floating(), start=lazy.window.get_size()), - Click([mod], "Button2", lazy.window.bring_to_front()) + Click([mod], + "Button2", + lazy.window.bring_to_front() + ), + Drag([mod], + "Button1", + lazy.window.set_position_floating(), + start=lazy.window.get_position() + ), + Drag([mod], + "Button3", + lazy.window.set_size_floating(), + start=lazy.window.get_size() + ) ] dgroups_key_binder = None @@ -392,6 +406,7 @@ def main(qtile): def restart_on_randr(qtile, ev): qtile.cmd_restart() + @hook.subscribe.client_new def floating_dialogs(window): float_clients = [ -- cgit v1.2.3-54-g00ecf