From a0d0a1cc5072eb3d96f1c1212034d72608fbd5e5 Mon Sep 17 00:00:00 2001 From: Guilherme Rugai Freire <41879254+GRFreire@users.noreply.github.com> Date: Fri, 6 Aug 2021 08:05:41 -0300 Subject: [PATCH] qtile: add exceptions rules to disable floating --- .config/qtile/config.py | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/.config/qtile/config.py b/.config/qtile/config.py index bf6cce8..1a481a4 100644 --- a/.config/qtile/config.py +++ b/.config/qtile/config.py @@ -352,6 +352,18 @@ floating_layout = layout.Floating( Match(wm_class="gnome-calendar"), # Calendar ] ) + +# Exceptions rules to disable floating in default config +@hook.subscribe.client_new +def disable_floating(window): + rules = [ + Match(wm_class="mpv") + ] + + if any(window.match(rule) for rule in rules): + window.togroup(qtile.current_group.name) + window.cmd_disable_floating() + auto_fullscreen = True focus_on_window_activation = "smart" reconfigure_screens = True