summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAmin Bandali <mab@gnu.org>2020-01-26 23:52:52 -0500
committerAmin Bandali <mab@gnu.org>2020-01-26 23:52:52 -0500
commit22fff83b4157b81ad6d739eadb16774b6eb505e3 (patch)
tree7b0f8e2531371d831fe30d7837b03dc84e803624
parent36cc7643a6f3f66a3e5aa83fe72eb645f1701466 (diff)
downloadconfigs-22fff83b4157b81ad6d739eadb16774b6eb505e3.tar.gz
configs-22fff83b4157b81ad6d739eadb16774b6eb505e3.tar.xz
configs-22fff83b4157b81ad6d739eadb16774b6eb505e3.zip
emacs: make my theme change functions more robust
only call sml/apply-theme if smart-mode-line is available
-rw-r--r--.emacs.d/init.el6
1 files changed, 4 insertions, 2 deletions
diff --git a/.emacs.d/init.el b/.emacs.d/init.el
index e709f70..0d2c850 100644
--- a/.emacs.d/init.el
+++ b/.emacs.d/init.el
@@ -1609,7 +1609,8 @@ This function is intended for use with `ivy-ignore-buffers'."
(interactive)
(mapc #'disable-theme custom-enabled-themes)
(load-theme 'tangomod t)
- (sml/apply-theme 'tangomod)
+ (when (featurep 'smart-mode-line)
+ (sml/apply-theme 'tangomod))
(font-lock-remove-keywords
'org-mode b/org-mode-font-lock-keywords)
(when (featurep 'erc-hl-nicks)
@@ -1622,7 +1623,8 @@ This function is intended for use with `ivy-ignore-buffers'."
(interactive)
(mapc #'disable-theme custom-enabled-themes)
(load-theme 'doom-one t)
- (sml/apply-theme 'automatic)
+ (when (featurep 'smart-mode-line)
+ (sml/apply-theme 'automatic))
(font-lock-add-keywords
'org-mode b/org-mode-font-lock-keywords t)
(when (featurep 'erc-hl-nicks)