From 828e6ac15d0b003b15652718bae6d6fa11a02b77 Mon Sep 17 00:00:00 2001 From: Corey Ducharme Date: Tue, 2 Jul 2019 15:06:14 -0400 Subject: [PATCH 1/3] Fix icon error for weekly agenda --- dashboard-widgets.el | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/dashboard-widgets.el b/dashboard-widgets.el index dd0d6db8..1801bc18 100644 --- a/dashboard-widgets.el +++ b/dashboard-widgets.el @@ -281,7 +281,8 @@ If MESSAGEBUF is not nil then MSG is also written in message buffer." ((string-equal heading "Bookmarks:") (all-the-icons-octicon (cdr (assoc 'bookmarks dashboard-heading-icons)) :height 1.2 :v-adjust 0.0 :face 'dashboard-heading)) - ((string-equal heading "Agenda for today:") + ((or (string-equal heading "Agenda for today:") + (string-equal heading "Agenda for the coming week:")) (all-the-icons-octicon (cdr (assoc 'agenda dashboard-heading-icons)) :height 1.2 :v-adjust 0.0 :face 'dashboard-heading)) ((string-equal heading "Registers:") From 16681715d71abdeee68321585804bb8995cea15d Mon Sep 17 00:00:00 2001 From: Corey Ducharme Date: Tue, 2 Jul 2019 15:06:33 -0400 Subject: [PATCH 2/3] Add final case to return no icons instead of throwing an error Will help people who want to run a custom dashboard section --- dashboard-widgets.el | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/dashboard-widgets.el b/dashboard-widgets.el index 1801bc18..330c1389 100644 --- a/dashboard-widgets.el +++ b/dashboard-widgets.el @@ -290,7 +290,8 @@ If MESSAGEBUF is not nil then MSG is also written in message buffer." :height 1.2 :v-adjust 0.0 :face 'dashboard-heading)) ((string-equal heading "Projects:") (all-the-icons-octicon (cdr (assoc 'projects dashboard-heading-icons)) - :height 1.2 :v-adjust 0.0 :face 'dashboard-heading)))) + :height 1.2 :v-adjust 0.0 :face 'dashboard-heading)) + (t " "))) (insert " ")) (insert (propertize heading 'face 'dashboard-heading)) From 64646445bf2ee0904d9c4c91909b5bd4c66b03eb Mon Sep 17 00:00:00 2001 From: Corey Ducharme Date: Tue, 2 Jul 2019 15:26:46 -0400 Subject: [PATCH 3/3] Lint --- dashboard-widgets.el | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dashboard-widgets.el b/dashboard-widgets.el index 330c1389..db88276a 100644 --- a/dashboard-widgets.el +++ b/dashboard-widgets.el @@ -282,7 +282,7 @@ If MESSAGEBUF is not nil then MSG is also written in message buffer." (all-the-icons-octicon (cdr (assoc 'bookmarks dashboard-heading-icons)) :height 1.2 :v-adjust 0.0 :face 'dashboard-heading)) ((or (string-equal heading "Agenda for today:") - (string-equal heading "Agenda for the coming week:")) + (string-equal heading "Agenda for the coming week:")) (all-the-icons-octicon (cdr (assoc 'agenda dashboard-heading-icons)) :height 1.2 :v-adjust 0.0 :face 'dashboard-heading)) ((string-equal heading "Registers:") @@ -291,7 +291,7 @@ If MESSAGEBUF is not nil then MSG is also written in message buffer." ((string-equal heading "Projects:") (all-the-icons-octicon (cdr (assoc 'projects dashboard-heading-icons)) :height 1.2 :v-adjust 0.0 :face 'dashboard-heading)) - (t " "))) + (t " "))) (insert " ")) (insert (propertize heading 'face 'dashboard-heading))