mirror of
https://github.com/vincentbernat/i3wm-configuration.git
synced 2025-07-01 13:54:22 +02:00
rules: handle browser a bit differently
Only "browser" windows should go to tags.www. Other window can go anywhere. Moreover, recent version of xulrunner do not set correctly the class. We use "Xulrunner-15.0" as an alternative for "Conkeror" and hope this will be fixed soon.
This commit is contained in:
parent
1662b2e280
commit
7e32c7456c
1 changed files with 12 additions and 4 deletions
16
rc/rules.lua
16
rc/rules.lua
|
@ -14,8 +14,19 @@ awful.rules.rules = {
|
|||
{ rule = { class = "Emacs" },
|
||||
properties = { tag = config.tags.emacs }},
|
||||
-- Browser stuff
|
||||
{ rule_any = { class = { "Iceweasel", "Firefox", "Chromium", "Conkeror" } },
|
||||
{ rule = { role = "browser" },
|
||||
properties = { tag = config.tags.www },
|
||||
callback = function(c)
|
||||
if not c.icon then
|
||||
local icon = icons.lookup({ name = "web-browser",
|
||||
type = "apps" })
|
||||
if icon then
|
||||
c.icon = image(icon)
|
||||
end
|
||||
end
|
||||
end },
|
||||
{ rule_any = { class = { "Iceweasel", "Firefox", "Chromium", "Conkeror",
|
||||
"Xulrunner-15.0" } },
|
||||
callback = function(c)
|
||||
-- All windows should be slaves, except the browser windows.
|
||||
if c.role ~= "browser" then awful.client.setslave(c) end
|
||||
|
@ -24,9 +35,6 @@ awful.rules.rules = {
|
|||
properties = { floating = true }}, -- Flash with Firefox
|
||||
{ rule = { instance = "exe", class="Exe", instance="exe" },
|
||||
properties = { floating = true }}, -- Flash with Chromium
|
||||
{ rule = { class = "Conkeror" },
|
||||
properties = { icon = image(icons.lookup({ name = "web-browser",
|
||||
type = "apps" })) }},
|
||||
-- Pidgin
|
||||
{ rule = { class = "Pidgin" },
|
||||
except = { type = "dialog" },
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue