From 58d7c0fcfa56a79130f7c23eb0f59a3220a35df4 Mon Sep 17 00:00:00 2001 From: Vincent Bernat Date: Wed, 1 Aug 2012 10:28:30 +0200 Subject: [PATCH] widgets: fix calendar widget --- rc/widgets.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/rc/widgets.lua b/rc/widgets.lua index 1541169..acf2328 100644 --- a/rc/widgets.lua +++ b/rc/widgets.lua @@ -42,14 +42,14 @@ local cal = ( datespec = (datespec % 12 + 1) .. " " .. math.floor(datespec / 12) local cal = awful.util.pread("ncal -w -m " .. datespec) -- Highlight the current date and month - cal = cal:gsub("_.(%d)", + cal = cal:gsub("_.([%d ])", string.format('%%1', beautiful.fg_widget_clock)) cal = cal:gsub("^( +[^ ]+ [0-9]+) *", string.format('%%1', beautiful.fg_widget_clock)) -- Turn anything other than days in labels - cal = cal:gsub("(\n[^%d]+)", + cal = cal:gsub("(\n[^%d ]+)", string.format('%%1', beautiful.fg_widget_label)) cal = cal:gsub("([%d ]+)\n?$",