update
This commit is contained in:
parent
b84a46a997
commit
4638ee1d6d
|
@ -136,7 +136,7 @@ local myglobalkeys = awful.util.table.join(
|
||||||
if exitcode > 0 then
|
if exitcode > 0 then
|
||||||
mb.grab{keymap=mpdmap, name="MPD", stay_in_mode=true}
|
mb.grab{keymap=mpdmap, name="MPD", stay_in_mode=true}
|
||||||
else
|
else
|
||||||
mb.grab{keymap=mprismap, name="Spotify", stay_in_mode=true}
|
mb.grab{keymap=mprismap, name="MPRIS", stay_in_mode=true}
|
||||||
end
|
end
|
||||||
end)
|
end)
|
||||||
end),
|
end),
|
||||||
|
|
147
rules.lua
147
rules.lua
|
@ -9,9 +9,9 @@ local log = require("talkative")
|
||||||
|
|
||||||
-- create a notification when given client becomes urgent
|
-- create a notification when given client becomes urgent
|
||||||
local function popup_urgent(client, message)
|
local function popup_urgent(client, message)
|
||||||
client:connect_signal("property::urgent", function (c)
|
client:connect_signal("property::urgent", function(c)
|
||||||
if c.urgent and not c.focus then
|
if c.urgent and not c.focus then
|
||||||
naughty.notify({ text=message })
|
naughty.notify({ text = message })
|
||||||
end
|
end
|
||||||
end)
|
end)
|
||||||
end
|
end
|
||||||
|
@ -21,12 +21,12 @@ end
|
||||||
local screen_main = math.min(localconf.screen.main or 1, screen.count())
|
local screen_main = math.min(localconf.screen.main or 1, screen.count())
|
||||||
local screen_chat = math.min(localconf.screen.chat or screen.count(), screen.count())
|
local screen_chat = math.min(localconf.screen.chat or screen.count(), screen.count())
|
||||||
local screen_mail = math.min(localconf.screen.mail or screen.count(), screen.count())
|
local screen_mail = math.min(localconf.screen.mail or screen.count(), screen.count())
|
||||||
print("Screens: main: ".. screen_main .. ", chat: ".. screen_chat .. ", mail: " .. screen_mail)
|
print("Screens: main: " .. screen_main .. ", chat: " .. screen_chat .. ", mail: " .. screen_mail)
|
||||||
|
|
||||||
awful.rules.rules = {
|
awful.rules.rules = {
|
||||||
-- All clients will match this rule.
|
-- All clients will match this rule.
|
||||||
{
|
{
|
||||||
rule = { },
|
rule = {},
|
||||||
properties = {
|
properties = {
|
||||||
border_width = beautiful.border_width,
|
border_width = beautiful.border_width,
|
||||||
border_color = beautiful.border_normal,
|
border_color = beautiful.border_normal,
|
||||||
|
@ -37,75 +37,90 @@ awful.rules.rules = {
|
||||||
keys = binder.client.keys(),
|
keys = binder.client.keys(),
|
||||||
buttons = binder.client.buttons(),
|
buttons = binder.client.buttons(),
|
||||||
screen = awful.screen.preferred,
|
screen = awful.screen.preferred,
|
||||||
placement = awful.placement.no_overlap+awful.placement.no_offscreen
|
placement = awful.placement.no_overlap + awful.placement.no_offscreen,
|
||||||
},
|
},
|
||||||
-- log name and class of new windows for debugging purposes
|
-- log name and class of new windows for debugging purposes
|
||||||
callback = function(c)
|
callback = function(c)
|
||||||
log("-----------\nnew client\n")
|
log("-----------\nnew client\n")
|
||||||
if (c["name"] ~= nil) then log("name: " .. c["name"]) end
|
if c["name"] ~= nil then
|
||||||
if (c["class"] ~= nil) then log("class: " .. c["class"]) end
|
log("name: " .. c["name"])
|
||||||
if (c["type"] ~= nil) then log("type: " .. c["type"]) end
|
end
|
||||||
if (c["instance"] ~= nil) then log("instance: " .. c["instance"]) end
|
if c["class"] ~= nil then
|
||||||
end
|
log("class: " .. c["class"])
|
||||||
|
end
|
||||||
|
if c["type"] ~= nil then
|
||||||
|
log("type: " .. c["type"])
|
||||||
|
end
|
||||||
|
if c["instance"] ~= nil then
|
||||||
|
log("instance: " .. c["instance"])
|
||||||
|
end
|
||||||
|
end,
|
||||||
},
|
},
|
||||||
{ rule = { class = "qutebrowser" }, properties = { tag = "2" }},
|
{ rule = { class = "qutebrowser" }, properties = { tag = "2" } },
|
||||||
{ rule = { class = "Passprompt" },
|
{ rule = { class = "Passprompt" }, properties = { ontop = true, focus = true } },
|
||||||
properties = { ontop = true, focus = true}},
|
{ rule = { class = "Dragon" }, properties = { ontop = true, sticky = true } },
|
||||||
{ rule = { class = "Dragon" },
|
{ rule = { class = "Sm" }, properties = { floating = true, size_hints_honor = true, fullscreen = true } },
|
||||||
properties = { ontop = true, sticky = true}},
|
{
|
||||||
{ rule = { class = "Sm" },
|
rule_any = { class = { "pinentry", "Passprompt", "copyq" } },
|
||||||
properties = { floating = true, size_hints_honor = true, fullscreen = true, }},
|
properties = { floating = true, size_hints_honor = true },
|
||||||
{ rule_any = { class = { "pinentry", "Passprompt", "copyq" }},
|
},
|
||||||
properties = { floating = true, size_hints_honor = true }},
|
{
|
||||||
{ rule_any = { class = {"Pidgin"}, instance = {"Weechat"}, name = {"Weechat"}},
|
rule_any = { class = { "Pidgin" }, instance = { "Weechat" }, name = { "Weechat" } },
|
||||||
properties = { screen = screen_chat, tag = "3", opacity = 0.8 },
|
properties = { screen = screen_chat, tag = "3", opacity = 0.8 },
|
||||||
callback = function(c) popup_urgent(c, "new chat message") end},
|
callback = function(c)
|
||||||
{ rule = { role = "buddy_list" },
|
popup_urgent(c, "new chat message")
|
||||||
callback = awful.client.setmaster},
|
end,
|
||||||
{ rule = { class = "Steam", name = "Friends" },
|
},
|
||||||
|
{ rule = { role = "buddy_list" }, callback = awful.client.setmaster },
|
||||||
|
{
|
||||||
|
rule = { class = "steam", name = "Friends" },
|
||||||
properties = { screen = screen_chat, tag = "3" },
|
properties = { screen = screen_chat, tag = "3" },
|
||||||
callback = awful.client.setmaster},
|
callback = awful.client.setmaster,
|
||||||
{ rule = { class = "Steam", name = "Chat" },
|
},
|
||||||
|
{
|
||||||
|
rule = { class = "steam", name = "Chat" },
|
||||||
properties = { screen = screen_chat, tag = "3" },
|
properties = { screen = screen_chat, tag = "3" },
|
||||||
callback = awful.client.setslave },
|
callback = awful.client.setslave,
|
||||||
{ rule = { class = "Steam", name = "Steam" },
|
},
|
||||||
properties = { tag = "F1" }},
|
{ rule = { class = "steam", name = "Steam" }, properties = { tag = "F1" } },
|
||||||
{ rule_any = { class = {"Rocket.Chat", "rocketchat"}, instance = {"rocket.chat"}},
|
{
|
||||||
properties = { screen = screen_chat, tag = "5" }},
|
rule_any = { class = { "Rocket.Chat", "rocketchat" }, instance = { "rocket.chat" } },
|
||||||
{ rule_any = { class = {"Element"}, instance = {"element"}},
|
properties = { screen = screen_chat, tag = "5" },
|
||||||
properties = { screen = screen_chat, tag = "1" }},
|
},
|
||||||
{ rule = { class = "TelegramDesktop" },
|
{
|
||||||
|
rule_any = { class = { "Element" }, instance = { "element" } },
|
||||||
|
properties = { screen = screen_chat, tag = "1" },
|
||||||
|
},
|
||||||
|
{
|
||||||
|
rule = { class = "TelegramDesktop" },
|
||||||
except = { name = "Media viewer" },
|
except = { name = "Media viewer" },
|
||||||
properties = { screen = screen_chat, tag = "3" }},
|
properties = { screen = screen_chat, tag = "3" },
|
||||||
{ rule = { class = "Telegram", name = "Media viewer" },
|
},
|
||||||
properties = { size_hints_honor = true, floating = true, fullscreen = true }},
|
{
|
||||||
{ rule = { class = "TelegramDesktop", name = "Media viewer" },
|
rule = { class = "Telegram", name = "Media viewer" },
|
||||||
properties = { size_hints_honor = true, floating = true, fullscreen = true }},
|
properties = { size_hints_honor = true, floating = true, fullscreen = true },
|
||||||
{ rule_any = { role ={ "conversation" }, instance = { "Weechat" }},
|
},
|
||||||
callback = awful.client.setslave },
|
{
|
||||||
{ rule = { class = "Irssi"},
|
rule = { class = "TelegramDesktop", name = "Media viewer" },
|
||||||
properties = { tag = "3" } ,
|
properties = { size_hints_honor = true, floating = true, fullscreen = true },
|
||||||
callback = awful.client.setslave },
|
},
|
||||||
{ rule_any = { instance = {"Gmutt"}, name = {"Gmutt"}},
|
{ rule_any = { role = { "conversation" }, instance = { "Weechat" } }, callback = awful.client.setslave },
|
||||||
properties = { tag = "4", screen = screen_mail }},
|
{ rule = { class = "Irssi" }, properties = { tag = "3" }, callback = awful.client.setslave },
|
||||||
{ rule_any = { class = {"Gmpc", "Spotify"}},
|
{ rule_any = { instance = { "Gmutt" }, name = { "Gmutt" } }, properties = { tag = "4", screen = screen_mail } },
|
||||||
properties = { tag = "6" }},
|
{ rule_any = { class = { "Gmpc", "Spotify" } }, properties = { tag = "6" } },
|
||||||
{ rule = { class = "Pdfpc" },
|
{ rule = { class = "Pdfpc" }, properties = { size_hints_honor = true, floating = true, fullscreen = true } },
|
||||||
properties = { size_hints_honor = true, floating = true, fullscreen = true }},
|
{
|
||||||
{ rule = { class = "zoom", instance = "zoom", name = "zoom" },
|
rule = { class = "zoom", instance = "zoom", name = "zoom" },
|
||||||
properties = { size_hints_honor = true, floating = true, border_width = 0 }},
|
properties = { size_hints_honor = true, floating = false, border_width = 0 },
|
||||||
{ rule_any = { class = {"URxvt", "Alacritty", "GVim", "kitty", "handy" }},
|
},
|
||||||
properties = { opacity = 0.9 }},
|
{ rule_any = { class = { "URxvt", "Alacritty", "GVim", "kitty", "handy" } }, properties = { opacity = 0.9 } },
|
||||||
{ rule = { name = "Awesomelog" },
|
{ rule = { name = "Awesomelog" }, properties = { tag = "F4" } },
|
||||||
properties = { tag = "F4" }},
|
{ rule = { class = "Dragon" }, properties = { sticky = true, ontop = true } },
|
||||||
{ rule = { class = "Dragon" },
|
{ rule = { class = "adobe dng converter.exe" }, properties = { floating = true, size_hints_honor = true } },
|
||||||
properties = { sticky = true, ontop = true }},
|
{ rule = { class = "pentablet", type = "normal" }, properties = { floating = true, size_hints_honor = true } },
|
||||||
{ rule = { class = "adobe dng converter.exe" },
|
{
|
||||||
properties = { floating = true, size_hints_honor = true }},
|
rule = { class = "pentablet", type = "utility" },
|
||||||
{ rule = { class = "pentablet", type = "normal"},
|
properties = { floating = true, size_hints_honor = true, focusable = false },
|
||||||
properties = { floating = true, size_hints_honor = true}},
|
},
|
||||||
{ rule = { class = "pentablet", type = "utility"},
|
{ rule = { class = "Onboard" }, properties = { sticky = true, ontop = true, focusable = false } },
|
||||||
properties = { floating = true, size_hints_honor = true, focusable = false}},
|
|
||||||
{ rule = { class = "Onboard" },
|
|
||||||
properties = { sticky = true, ontop = true, focusable = false}},
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -135,7 +135,6 @@ awful.key({ modkey, "Shift" }, "h", screen_move_client_wrapdir("left")),
|
||||||
awful.key({ modkey, "Shift" }, "l", screen_move_client_wrapdir("right")),
|
awful.key({ modkey, "Shift" }, "l", screen_move_client_wrapdir("right")),
|
||||||
awful.key({ modkey, "Control" }, "o", function (c) c.ontop = not c.ontop end),
|
awful.key({ modkey, "Control" }, "o", function (c) c.ontop = not c.ontop end),
|
||||||
awful.key({ modkey, "Shift" }, "a", function (c) c.sticky = not c.sticky end),
|
awful.key({ modkey, "Shift" }, "a", function (c) c.sticky = not c.sticky end),
|
||||||
awful.key({ modkey, "Shift" }, "r", function (c) c:redraw() end),
|
|
||||||
awful.key({ modkey, }, "Up", function(c) client_opacity_set(c, 1, 1, 0.1) end),
|
awful.key({ modkey, }, "Up", function(c) client_opacity_set(c, 1, 1, 0.1) end),
|
||||||
awful.key({ modkey, }, "Down", function(c) client_opacity_set(c, 1, 0, -0.1) end),
|
awful.key({ modkey, }, "Down", function(c) client_opacity_set(c, 1, 0, -0.1) end),
|
||||||
awful.key({ }, "XF86Calculater", awful.client.movetoscreen ),
|
awful.key({ }, "XF86Calculater", awful.client.movetoscreen ),
|
||||||
|
|
Loading…
Reference in a new issue