From 6173be1a58d2433962bda50059d9043b37c85205 Mon Sep 17 00:00:00 2001 From: xero Date: Sun, 9 Mar 2014 21:14:10 -0400 Subject: add awesome ghost config variable to enable sloppy focus, since i guess some people like that type of thing. --- .config/awesome/config.lua | 1 + .config/awesome/rc.lua | 9 +++++++++ 2 files changed, 10 insertions(+) (limited to '.config/awesome') diff --git a/.config/awesome/config.lua b/.config/awesome/config.lua index efa6e3e..eeb466f 100644 --- a/.config/awesome/config.lua +++ b/.config/awesome/config.lua @@ -18,6 +18,7 @@ tag_icon = "◊" tag_icon_active = "◆" clock_format = " %a %m/%d %H:%M " -- http://linux.die.net/man/3/strftime battery_id = "BAT1" +sloppy_focus = false -- █▓▒░ preffered apps terminal = "urxvtc" diff --git a/.config/awesome/rc.lua b/.config/awesome/rc.lua index b8a7d4b..7e8aba3 100755 --- a/.config/awesome/rc.lua +++ b/.config/awesome/rc.lua @@ -834,6 +834,15 @@ client.connect_signal("manage", function (c, startup) awful.placement.no_overlap(c) awful.placement.no_offscreen(c) end + -- sloppy focus + if sloppy_focus then + c:connect_signal("mouse::enter", function(c) + if awful.layout.get(c.screen) ~= awful.layout.suit.magnifier + and awful.client.focus.filter(c) then + client.focus = c + end + end) + end end) -- closed client -- cgit v1.2.1