From 82d4aa066309b80e870a3b0b8e346b888cae4004 Mon Sep 17 00:00:00 2001 From: Luke Bonham Date: Sat, 7 Sep 2013 03:30:54 -0700 Subject: [PATCH] Created calendar (markdown) --- calendar.md | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 calendar.md diff --git a/calendar.md b/calendar.md new file mode 100644 index 0000000..06e1b48 --- /dev/null +++ b/calendar.md @@ -0,0 +1,35 @@ +Attaches a calendar to a ``widget``. Example: + + lain.widgets.calendar:attach(mytextclock) + +- Left click: switch to previous month. +- Right click: switch to next month. + +Optionally you can call the function with background and foreground colors arguments, both or just one: + + lain.widgets.calendar:attach(mytextclock, "#FFFFFF", "#000000") + -- or + lain.widgets.calendar:attach(mytextclock, "#FFFFFF") + -- or + lain.widgets.calendar:attach(mytextclock, nil, "#000000") + +Notification will show an icon displaying current day, and formatted output +from ``cal`` with current day highlighted. + +Calendar icons are placed in [lain/icons/cal](https://github.com/copycat-killer/lain/tree/master/icons/cal), default set being ``white``. + +You can add your own set, and tell lain to use it like this: + + lain.widgets.calendar.icons_dir = lain.widgets.icons_dir .. "cal/myicons" + +also, you can set notification font size: + + lain.widgets.calendar.font_size = 14 + +default is 12. + +Finally, you can call the notification with a key binding like this: + + awful.key({ altkey }, "c", function () lain.widgets.calendar:show(7) end), + +where ``altkey = "Mod1"`` and ``show`` argument is an optional integer, meaning timeout seconds. \ No newline at end of file -- 2.39.5