beautiful: set wallpaper of each screen
Signed-off-by: Julien Danjou <julien@danjou.info>
This commit is contained in:
parent
62370ecb87
commit
fd35fc6d11
|
@ -824,10 +824,11 @@ end
|
||||||
|
|
||||||
--- Spawn a program.
|
--- Spawn a program.
|
||||||
-- @param cmd The command.
|
-- @param cmd The command.
|
||||||
|
-- @param screen The screen where to spawn window.
|
||||||
-- @return The awesome.spawn return value.
|
-- @return The awesome.spawn return value.
|
||||||
function spawn(cmd)
|
function spawn(cmd, screen)
|
||||||
if cmd and cmd ~= "" then
|
if cmd and cmd ~= "" then
|
||||||
return capi.awesome.spawn(cmd .. "&", capi.mouse.screen)
|
return capi.awesome.spawn(cmd .. "&", screen or capi.mouse.screen)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
@ -11,7 +11,11 @@ local print = print
|
||||||
local setmetatable = setmetatable
|
local setmetatable = setmetatable
|
||||||
local awful = require("awful")
|
local awful = require("awful")
|
||||||
local package = package
|
local package = package
|
||||||
local capi = { awesome = awesome }
|
local capi =
|
||||||
|
{
|
||||||
|
screen = screen,
|
||||||
|
awesome = awesome
|
||||||
|
}
|
||||||
|
|
||||||
local module_name = "beautiful"
|
local module_name = "beautiful"
|
||||||
|
|
||||||
|
@ -64,7 +68,9 @@ function init(path)
|
||||||
key, value = split_line(line)
|
key, value = split_line(line)
|
||||||
if key then
|
if key then
|
||||||
if key == "wallpaper_cmd" then
|
if key == "wallpaper_cmd" then
|
||||||
awful.spawn(value)
|
for s = 1, capi.screen.count() do
|
||||||
|
awful.spawn(value, s)
|
||||||
|
end
|
||||||
elseif key == "font" then
|
elseif key == "font" then
|
||||||
capi.awesome.font_set(value)
|
capi.awesome.font_set(value)
|
||||||
elseif key == "fg_normal" then
|
elseif key == "fg_normal" then
|
||||||
|
|
Loading…
Reference in New Issue