Disable all themes before loading new theme

This commit is contained in:
Jeremy Dormitzer 2019-01-29 19:22:26 -05:00
parent f1ab04d41c
commit 6b4ab640bc

View File

@ -816,14 +816,16 @@ Display the column number in programming modes:
(add-hook 'prog-mode-hook #'column-number-mode)
#+END_SRC
Load up some tasty solarized themes:
Load up some tasty themes:
#+BEGIN_SRC emacs-lisp
(use-package solarized-theme)
#+END_SRC
And also [[https://github.com/kunalb/poet][poet-theme]]:
How to disable all applied custom themes:
#+BEGIN_SRC emacs-lisp
(use-package poet-theme)
(defun disable-all-themes ()
(interactive)
(mapcar #'disable-theme custom-enabled-themes))
#+END_SRC
A function to load a font, including overriding any theme settings for org-mode headers:
@ -868,6 +870,7 @@ A function to load a theme then override font settings:
(list (intern (completing-read "Load custom theme: "
(mapcar 'symbol-name
(custom-available-themes))))))
(disable-all-themes)
(load-theme theme t)
(jdormit/load-persisted-fonts)
(persist-variable 'jdormit/theme theme))