From 28b9df06737e5e50a0f6730a70db3551c99747d6 Mon Sep 17 00:00:00 2001 From: toctan Date: Sat, 11 Oct 2014 11:56:40 +0800 Subject: [PATCH] Custom theme via prelude-theme variable --- README.md | 4 ++-- core/prelude-custom.el | 5 +++++ core/prelude-ui.el | 2 +- init.el | 2 +- 4 files changed, 9 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 38adddc..322c2a7 100644 --- a/README.md +++ b/README.md @@ -475,10 +475,10 @@ line: (disable-theme 'zenburn) ``` -Or you can use another theme altogether by adding something like: +Or you can use another theme altogether by adding something in `personal/preload` like: ```lisp -(load-theme 'solarized-dark t) +(setq prelude-theme 'solarized-dark) ``` **P.S.** Solarized is not available by default - you'll have to diff --git a/core/prelude-custom.el b/core/prelude-custom.el index 6a76867..193ef9e 100644 --- a/core/prelude-custom.el +++ b/core/prelude-custom.el @@ -93,6 +93,11 @@ Only modes that don't derive from `prog-mode' should be listed here." :type 'number :group 'prelude) +(defcustom prelude-theme 'zenburn + "The default color theme, change this in your /personal/preload config." + :type 'symbol + :group 'prelude) + (provide 'prelude-custom) ;;; prelude-custom.el ends here diff --git a/core/prelude-ui.el b/core/prelude-ui.el index 15906cb..b5d64d0 100644 --- a/core/prelude-ui.el +++ b/core/prelude-ui.el @@ -73,7 +73,7 @@ "%b")))) ;; use zenburn as the default theme -(load-theme 'zenburn t) +(load-theme prelude-theme t) (provide 'prelude-ui) ;;; prelude-ui.el ends here diff --git a/init.el b/init.el index beea1cd..e42619a 100644 --- a/init.el +++ b/init.el @@ -99,8 +99,8 @@ by Prelude.") ;; the core stuff (require 'prelude-packages) +(require 'prelude-custom) ;; Needs to be loaded before core, editor and ui (require 'prelude-ui) -(require 'prelude-custom) ;; Needs to be loaded before core and editor (require 'prelude-core) (require 'prelude-mode) (require 'prelude-editor)