-
Notifications
You must be signed in to change notification settings - Fork 0
/
rc.lua
executable file
·60 lines (47 loc) · 1.52 KB
/
rc.lua
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
require("capi")
local beautiful = require("beautiful")
local theme = require("theme")
beautiful.init(theme)
local keybinds = require("keys.keybinds")
capi.root.keys(keybinds.globalkeys)
capi.root.buttons(keybinds.buttonkeys)
require("notifications")
local awful = require("awful")
awful.rules.rules = require("rules")(keybinds.clientkeys, keybinds.buttonkeys)
local apps = require("autostart")
apps:start()
require("widgets.titlebar")
local wibar = require("wibar")
local wallpaper = require("wallpaper")
awful.screen.connect_for_each_screen(
function(s)
wallpaper(s)
wibar(s)
for i, icon in pairs(theme.taglist_icons) do
awful.tag.add(i, {
icon = icon,
icon_only = true,
layout = awful.layout.suit.tile,
screen = s,
selected = i == 1
})
end
end
)
capi.tag.connect_signal("property::layout", function(t)
local current_layout = awful.tag.getproperty(t, "layout")
if (current_layout == awful.layout.suit.max) then
t.gap = 0
else
t.gap = beautiful.useless_gap
end
end)
capi.client.connect_signal("manage", function(c)
if not capi.awesome.startup then
awful.client.setslave(c)
end
if capi.awesome.startup and not c.size_hints.user_position and not c.size_hints.program_position then
awful.placement.no_offscreen(c)
end
end)
require("awful.autofocus")