summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAdrian C. (anrxc) <anrxc@sysphere.org>2024-05-29 17:23:48 +0200
committerAdrian C. (anrxc) <anrxc@sysphere.org>2024-05-29 17:24:13 +0200
commit85ee18e88f6e9ee3f6a902a004d0000aea0fc541 (patch)
tree44f19c7310f92c2c40ad1162e81537f106530be6
parent38c18f7b3dd3bee4678058ec226538ff91075fda (diff)
downloadawesome-configs-85ee18e88f6e9ee3f6a902a004d0000aea0fc541.tar.xz
rc.lua: launch calendar on date widget click
-rw-r--r--rc.lua10
1 files changed, 9 insertions, 1 deletions
diff --git a/rc.lua b/rc.lua
index 0a2a47b..cc83f6b 100644
--- a/rc.lua
+++ b/rc.lua
@@ -116,8 +116,16 @@ mydateicon = wibox.widget.imagebox(home .. "/.config/awesome/icons/time.png", fa
mydatewidget = wibox.widget.textbox()
mydatestwidget = wibox.widget.textbox()
-- Register widgets
-vicious.register(mydatewidget, vicious.widgets.date, "%R", 61) -- Amsterdam
+vicious.register(mydatewidget, vicious.widgets.date, "%R", 61) -- Amsterdam
vicious.register(mydatestwidget, vicious.widgets.date, "%R", 61, -21600) -- New York
+-- Register buttons
+mydatewidget:buttons(gears.table.join(
+ -- GTK3 calendar applet with holidays: https://sysphere.org/~anrxc/local/sources/pylendar.py
+ awful.button({ }, 1, function () exec(home .. "/code/bin/pylendar.py") end)
+))
+mydatestwidget:buttons(gears.table.join(
+ awful.button({ }, 1, function () exec(home .. "/code/bin/pylendar.py") end)
+))
-- }}}
-- {{{ Flexible widget