2013-04-13 15:17:09 +00:00
|
|
|
local beautiful = require("beautiful")
|
|
|
|
local gears = require("gears")
|
2014-08-28 08:58:03 +00:00
|
|
|
local awful = require("awful")
|
2013-04-13 15:17:09 +00:00
|
|
|
|
|
|
|
beautiful.init(awful.util.getdir("config") .. "/theme.lua")
|
|
|
|
|
2017-02-16 08:51:01 +00:00
|
|
|
local wallpaperrc = awful.util.getdir("config") .. "/wallpaperrc.lua"
|
2016-04-07 09:18:14 +00:00
|
|
|
local f=io.open(wallpaperrc,"r")
|
|
|
|
if f~=nil then
|
2017-01-10 16:45:32 +00:00
|
|
|
io.close(f)
|
|
|
|
require("wallpaperrc")
|
2017-02-16 08:51:01 +00:00
|
|
|
for s in screen do
|
|
|
|
set_wallpaper(s)
|
|
|
|
end
|
2017-01-10 16:45:32 +00:00
|
|
|
screen.connect_signal("property::geometry", set_wallpaper)
|
2017-02-16 08:51:01 +00:00
|
|
|
elseif beautiful.wallpaper then
|
|
|
|
f = io.open(beautiful.wallpaper)
|
|
|
|
if f ~= nil then
|
|
|
|
io.close(f)
|
|
|
|
screen.connect_signal("property::geometry", function(s)
|
|
|
|
gears.wallpaper.maximized(beautiful.wallpaper, s, true)
|
|
|
|
end)
|
2016-07-26 12:47:46 +00:00
|
|
|
end
|
2013-04-13 15:17:09 +00:00
|
|
|
end
|
|
|
|
|
|
|
|
return beautiful
|