Skip to content

Commit

Permalink
fs widget disabled by default; #235
Browse files Browse the repository at this point in the history
  • Loading branch information
lcpz committed Sep 17, 2018
1 parent 398a658 commit a013123
Show file tree
Hide file tree
Showing 10 changed files with 64 additions and 47 deletions.
2 changes: 1 addition & 1 deletion rc.lua.template
Expand Up @@ -383,7 +383,7 @@ globalkeys = my_table.join(
{description = "dropdown application", group = "launcher"}),

-- Widgets popups
awful.key({ altkey, }, "c", function () beautiful.cal.show(7) end,
awful.key({ altkey, }, "c", function () if beautiful.cal then beautiful.cal.show(7) end end,
{description = "show calendar", group = "widgets"}),
awful.key({ altkey, }, "h", function () if beautiful.fs then beautiful.fs.show(7) end end,
{description = "show filesystem", group = "widgets"}),
Expand Down
11 changes: 6 additions & 5 deletions themes/blackburn/theme.lua
Expand Up @@ -88,11 +88,12 @@ theme.cal = lain.widget.cal({
font = "Misc Tamsyn 11",
fg = theme.fg_normal,
bg = theme.bg_normal
}})
}
})
-- Mail IMAP check
--[[ commented because it needs to be set before use
local mail = lain.widget.imap({
theme.mail = lain.widget.imap({
timeout = 180,
server = "server",
mail = "mail",
Expand Down Expand Up @@ -132,7 +133,7 @@ theme.mpd = lain.widget.mpd({
})
-- /home fs
--[[ commented because it uses
--[[ commented because it needs Gio/Glib >= 2.54
theme.fs = lain.widget.fs({
notification_preset = { fg = white, bg = theme.bg_normal, font = "Misc Tamsyn 10.5" },
settings = function()
Expand Down Expand Up @@ -257,10 +258,10 @@ function theme.at_screen_connect(s)
wibox.widget.systray(),
first,
theme.mpd.widget,
--mail.widget,
--theme.mail.widget,
theme.weather.icon,
theme.weather.widget,
theme.fs.widget,
--theme.fs.widget,
bat,
theme.volume.widget,
mytextclock,
Expand Down
14 changes: 8 additions & 6 deletions themes/copland/theme.lua
Expand Up @@ -108,9 +108,9 @@ theme.cal = lain.widget.cal({
}
})
--[[ Mail IMAP check
-- commented because it needs to be set before use
local mail = lain.widget.imap({
-- Mail IMAP check
--[[ commented because it needs to be set before use
theme.mail = lain.widget.imap({
timeout = 180,
server = "server",
mail = "mail",
Expand Down Expand Up @@ -202,6 +202,7 @@ local batbg = wibox.container.background(batbar, "#474747", gears.shape.rectangl
local batwidget = wibox.container.margin(batbg, 2, 7, 4, 4)
-- /home fs
--[[ commented because it needs Gio/Glib >= 2.54
local fsicon = wibox.widget.imagebox(theme.disk)
local fsbar = wibox.widget {
forced_height = 1,
Expand All @@ -227,6 +228,7 @@ theme.fs = lain.widget.fs {
}
local fsbg = wibox.container.background(fsbar, "#474747", gears.shape.rectangle)
local fswidget = wibox.container.margin(fsbg, 2, 7, 4, 4)
--]]
-- ALSA volume bar
local volicon = wibox.widget.imagebox(theme.vol)
Expand Down Expand Up @@ -349,14 +351,14 @@ function theme.at_screen_connect(s)
layout = wibox.layout.fixed.horizontal,
wibox.widget.systray(),
small_spr,
--mail.widget,
--theme.mail.widget,
mpdicon,
theme.mpd.widget,
baticon,
batwidget,
bar_spr,
fsicon,
fswidget,
--fsicon,
--fswidget,
bar_spr,
volicon,
volumewidget,
Expand Down
12 changes: 7 additions & 5 deletions themes/dremora/theme.lua
Expand Up @@ -91,9 +91,9 @@ theme.cal = lain.widget.cal({
bg = theme.bg_normal
}})
--[[ Mail IMAP check
-- commented because it needs to be set before use
local mail = lain.widget.imap({
-- Mail IMAP check
--[[ commented because it needs to be set before use
theme.mail = lain.widget.imap({
timeout = 180,
server = "server",
mail = "mail",
Expand Down Expand Up @@ -133,6 +133,7 @@ theme.mpd = lain.widget.mpd({
})
-- /home fs
--[[ commented because it needs Gio/Glib >= 2.54
theme.fs = lain.widget.fs({
notification_preset = { fg = white, bg = theme.bg_normal, font = "Misc Tamsyn 10.5" },
settings = function()
Expand All @@ -147,6 +148,7 @@ theme.fs = lain.widget.fs({
widget:set_markup(markup.font(theme.font, markup(gray, fs_header) .. markup(white, fs_p)))
end
})
--]]
-- Battery
local bat = lain.widget.bat({
Expand Down Expand Up @@ -237,8 +239,8 @@ function theme.at_screen_connect(s)
wibox.widget.systray(),
first,
theme.mpd.widget,
--mail.widget,
theme.fs.widget,
--theme.mail.widget,
--theme.fs.widget,
bat.widget,
theme.volume.widget,
mytextclock,
Expand Down
12 changes: 7 additions & 5 deletions themes/holo/theme.lua
Expand Up @@ -122,9 +122,9 @@ theme.cal = lain.widget.cal({
}
})
--[[ Mail IMAP check
-- commented because it needs to be set before use
local mail = lain.widget.imap({
-- Mail IMAP check
--[[ commented because it needs to be set before use
theme.mail = lain.widget.imap({
timeout = 180,
server = "server",
mail = "mail",
Expand Down Expand Up @@ -212,10 +212,12 @@ local bat = lain.widget.bat({
end
})
-- fs
-- / fs
--[[ commented because it needs Gio/Glib >= 2.54
theme.fs = lain.widget.fs({
notification_preset = { bg = theme.bg_normal, font = "Monospace 9" },
})
--]]
-- ALSA volume bar
theme.volume = lain.widget.alsabar({
Expand Down Expand Up @@ -335,7 +337,7 @@ function theme.at_screen_connect(s)
{ -- Right widgets
layout = wibox.layout.fixed.horizontal,
wibox.widget.systray(),
--mail.widget,
--theme.mail.widget,
--bat.widget,
spr_right,
musicwidget,
Expand Down
14 changes: 8 additions & 6 deletions themes/multicolor/theme.lua
Expand Up @@ -122,18 +122,20 @@ theme.weather = lain.widget.weather({
})
-- / fs
--[[ commented because it needs Gio/Glib >= 2.54
local fsicon = wibox.widget.imagebox(theme.widget_fs)
theme.fs = lain.widget.fs({
notification_preset = { font = "xos4 Terminus 10", fg = theme.fg_normal },
settings = function()
widget:set_markup(markup.fontfg(theme.font, "#80d9d8", string.format("%.1f", fs_now["/"].used) .. "% "))
end
})
--]]
--[[ Mail IMAP check
-- commented because it needs to be set before use
-- Mail IMAP check
--[[ commented because it needs to be set before use
local mailicon = wibox.widget.imagebox()
local mail = lain.widget.imap({
theme.mail = lain.widget.imap({
timeout = 180,
server = "server",
mail = "mail",
Expand Down Expand Up @@ -298,7 +300,7 @@ function theme.at_screen_connect(s)
layout = wibox.layout.fixed.horizontal,
wibox.widget.systray(),
--mailicon,
--mail.widget,
--theme.mail.widget,
netdownicon,
netdowninfo,
netupicon,
Expand All @@ -309,8 +311,8 @@ function theme.at_screen_connect(s)
memory.widget,
cpuicon,
cpu.widget,
fsicon,
theme.fs.widget,
--fsicon,
--theme.fs.widget,
weathericon,
theme.weather.widget,
tempicon,
Expand Down
8 changes: 5 additions & 3 deletions themes/powerarrow-dark/theme.lua
Expand Up @@ -113,7 +113,7 @@ theme.cal = lain.widget.cal({
local mailicon = wibox.widget.imagebox(theme.widget_mail)
--[[ commented because it needs to be set before use
mailicon:buttons(my_table.join(awful.button({ }, 1, function () awful.spawn(mail) end)))
local mail = lain.widget.imap({
theme.mail = lain.widget.imap({
timeout = 180,
server = "server",
mail = "mail",
Expand Down Expand Up @@ -192,12 +192,14 @@ local temp = lain.widget.temp({
-- / fs
local fsicon = wibox.widget.imagebox(theme.widget_hdd)
--[[ commented because it needs Gio/Glib >= 2.54
theme.fs = lain.widget.fs({
notification_preset = { fg = theme.fg_normal, bg = theme.bg_normal, font = "xos4 Terminus 10" },
settings = function()
widget:set_markup(markup.font(theme.font, " " .. fs_now["/"].percentage .. "% "))
end
})
--]]
-- Battery
local baticon = wibox.widget.imagebox(theme.widget_battery)
Expand Down Expand Up @@ -313,7 +315,7 @@ function theme.at_screen_connect(s)
theme.volume.widget,
arrl_ld,
wibox.container.background(mailicon, theme.bg_focus),
--wibox.container.background(mail.widget, theme.bg_focus),
--wibox.container.background(theme.mail.widget, theme.bg_focus),
arrl_dl,
memicon,
mem.widget,
Expand All @@ -325,7 +327,7 @@ function theme.at_screen_connect(s)
temp.widget,
arrl_ld,
wibox.container.background(fsicon, theme.bg_focus),
wibox.container.background(theme.fs.widget, theme.bg_focus),
--wibox.container.background(theme.fs.widget, theme.bg_focus),
arrl_dl,
baticon,
bat.widget,
Expand Down
14 changes: 8 additions & 6 deletions themes/powerarrow/theme.lua
Expand Up @@ -131,10 +131,10 @@ local scissors = wibox.widget.imagebox(theme.widget_scissors)
scissors:buttons(my_table.join(awful.button({}, 1, function() awful.spawn.with_shell("xsel | xsel -i -b") end)))
-- Mail IMAP check
local mailicon = wibox.widget.imagebox(theme.widget_mail)
--[[ commented because it needs to be set before use
local mailicon = wibox.widget.imagebox(theme.widget_mail)
mailicon:buttons(my_table.join(awful.button({ }, 1, function () awful.spawn(mail) end)))
local mail = lain.widget.imap({
theme.mail = lain.widget.imap({
timeout = 180,
server = "server",
mail = "mail",
Expand Down Expand Up @@ -228,13 +228,15 @@ local tempicon = wibox.widget.imagebox(theme.widget_temp)
-- / fs
local fsicon = wibox.widget.imagebox(theme.widget_hdd)
--[[ commented because it needs Gio/Glib >= 2.54
theme.fs = lain.widget.fs({
notification_preset = { fg = theme.fg_normal, bg = theme.bg_normal, font = "xos4 Terminus 10" },
settings = function()
local fsp = string.format(" %3.2f %s ", fs_now["/"].free, fs_now["/"].units)
widget:set_markup(markup.font(theme.font, fsp))
end
})
--]]
-- Battery
local baticon = wibox.widget.imagebox(theme.widget_battery)
Expand Down Expand Up @@ -345,18 +347,18 @@ function theme.at_screen_connect(s)
--[[ using shapes
pl(wibox.widget { mpdicon, theme.mpd.widget, layout = wibox.layout.align.horizontal }, "#343434"),
pl(task, "#343434"),
--pl(wibox.widget { mailicon, mail and mail.widget, layout = wibox.layout.align.horizontal }, "#343434"),
--pl(wibox.widget { mailicon, mail and theme.mail.widget, layout = wibox.layout.align.horizontal }, "#343434"),
pl(wibox.widget { memicon, mem.widget, layout = wibox.layout.align.horizontal }, "#777E76"),
pl(wibox.widget { cpuicon, cpu.widget, layout = wibox.layout.align.horizontal }, "#4B696D"),
pl(wibox.widget { tempicon, temp.widget, layout = wibox.layout.align.horizontal }, "#4B3B51"),
pl(wibox.widget { fsicon, theme.fs.widget, layout = wibox.layout.align.horizontal }, "#CB755B"),
--pl(wibox.widget { fsicon, fs and fs.widget, layout = wibox.layout.align.horizontal }, "#CB755B"),
pl(wibox.widget { baticon, bat.widget, layout = wibox.layout.align.horizontal }, "#8DAA9A"),
pl(wibox.widget { neticon, net.widget, layout = wibox.layout.align.horizontal }, "#C0C0A2"),
pl(binclock.widget, "#777E76"),
--]]
-- using separators
arrow(theme.bg_normal, "#343434"),
wibox.container.background(wibox.container.margin(wibox.widget { mailicon, mail and mail.widget, layout = wibox.layout.align.horizontal }, 4, 7), "#343434"),
wibox.container.background(wibox.container.margin(wibox.widget { mailicon, theme.mail and theme.mail.widget, layout = wibox.layout.align.horizontal }, 4, 7), "#343434"),
arrow("#343434", theme.bg_normal),
wibox.container.background(wibox.container.margin(wibox.widget { mpdicon, theme.mpd.widget, layout = wibox.layout.align.horizontal }, 3, 6), theme.bg_focus),
arrow(theme.bg_normal, "#343434"),
Expand All @@ -368,7 +370,7 @@ function theme.at_screen_connect(s)
arrow("#4B696D", "#4B3B51"),
wibox.container.background(wibox.container.margin(wibox.widget { tempicon, temp.widget, layout = wibox.layout.align.horizontal }, 4, 4), "#4B3B51"),
arrow("#4B3B51", "#CB755B"),
wibox.container.background(wibox.container.margin(wibox.widget { fsicon, theme.fs.widget, layout = wibox.layout.align.horizontal }, 3, 3), "#CB755B"),
wibox.container.background(wibox.container.margin(wibox.widget { fsicon, fs and fs.widget, layout = wibox.layout.align.horizontal }, 3, 3), "#CB755B"),
arrow("#CB755B", "#8DAA9A"),
wibox.container.background(wibox.container.margin(wibox.widget { baticon, bat.widget, layout = wibox.layout.align.horizontal }, 3, 3), "#8DAA9A"),
arrow("#8DAA9A", "#C0C0A2"),
Expand Down
14 changes: 8 additions & 6 deletions themes/rainbow/theme.lua
Expand Up @@ -101,9 +101,9 @@ theme.cal = lain.widget.cal({
}
})
--[[ Mail IMAP check
-- commented because it needs to be set before use
local mail = lain.widget.imap({
-- Mail IMAP check
--[[ commented because it needs to be set before use
theme.mail = lain.widget.imap({
timeout = 180,
server = "server",
mail = "mail",
Expand All @@ -122,7 +122,7 @@ local mail = lain.widget.imap({
widget:set_markup(markup.font(theme.font, markup(gray, mail) .. markup(white, count)))
end
})
]]
--]]
-- MPD
theme.mpd = lain.widget.mpd({
Expand All @@ -145,6 +145,7 @@ theme.mpd = lain.widget.mpd({
})
-- /home fs
--[[ commented because it needs Gio/Glib >= 2.54
theme.fs = lain.widget.fs({
notification_preset = { fg = white, bg = theme.bg_normal, font = "Misc Tamsyn 10.5" },
settings = function()
Expand All @@ -158,6 +159,7 @@ theme.fs = lain.widget.fs({
widget:set_markup(markup.font(theme.font, markup(gray, fs_header) .. markup(white, fs_p)))
end
})
--]]
-- ALSA volume bar
theme.volume = lain.widget.alsabar({
Expand Down Expand Up @@ -261,8 +263,8 @@ function theme.at_screen_connect(s)
wibox.widget.systray(),
spr,
theme.mpd.widget,
--mail.widget,
theme.fs.widget,
--theme.mail.widget,
--theme.fs.widget,
volumewidget,
mytextclock,
},
Expand Down
10 changes: 6 additions & 4 deletions themes/steamburn/theme.lua
Expand Up @@ -94,9 +94,9 @@ theme.cal = lain.widget.cal({
}
})
--[[ Mail IMAP check
-- commented because it needs to be set before use
local mail = lain.widget.imap({
-- Mail IMAP check
--[[ commented because it needs to be set before use
theme.mail = lain.widget.imap({
timeout = 180,
server = "server",
mail = "mail",
Expand Down Expand Up @@ -148,10 +148,12 @@ local mem = lain.widget.mem({
})
-- /home fs
--[[ commented because it needs Gio/Glib >= 2.54
theme.fs = lain.widget.fs({
partition = "/home",
notification_preset = { fg = theme.fg_normal, bg = theme.bg_normal, font = "Misc Tamsyn 10.5" },
})
--]]
-- Battery
local bat = lain.widget.bat({
Expand Down Expand Up @@ -257,7 +259,7 @@ function theme.at_screen_connect(s)
wibox.widget.systray(),
spr,
theme.mpd.widget,
--mail.widget,
--theme.mail.widget,
cpu.widget,
mem.widget,
bat.widget,
Expand Down

0 comments on commit a013123

Please sign in to comment.