From 41be59ba27f6e611b73d90e7e2de5260ac89588c Mon Sep 17 00:00:00 2001 From: Luca Capezzuto Date: Mon, 15 Apr 2019 11:05:10 +0100 Subject: [PATCH] #261: added screen arrange signal too --- rc.lua.template | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/rc.lua.template b/rc.lua.template index d09c678..9b412df 100644 --- a/rc.lua.template +++ b/rc.lua.template @@ -227,6 +227,18 @@ screen.connect_signal("property::geometry", function(s) gears.wallpaper.maximized(wallpaper, s, true) end end) + +-- No borders when rearranging only 1 non-floating or maximized client +screen.connect_signal("arrange", function (s) + local only_one = #s.tiled_clients == 1 + for _, c in pairs(s.clients) do + if only_one and not c.floating or c.maximized then + c.border_width = 0 + else + c.border_width = beautiful.border_width + end + end +end) -- Create a wibox for each screen and add it awful.screen.connect_for_each_screen(function(s) beautiful.at_screen_connect(s) end) -- }}}