use base16-theme, customize smart-mode-line, at start set dark theme
This commit is contained in:
parent
2ef39750c4
commit
36af0a9f50
23
init.el
23
init.el
@ -483,23 +483,24 @@
|
|||||||
(use-package smart-mode-line
|
(use-package smart-mode-line
|
||||||
:config
|
:config
|
||||||
(setq sml/no-confirm-load-theme t
|
(setq sml/no-confirm-load-theme t
|
||||||
|
sml/shorten-directory t
|
||||||
|
sml/shorten-modes t
|
||||||
|
sml/name-width 50
|
||||||
|
sml/mode-width 'full
|
||||||
sml/theme 'respectful)
|
sml/theme 'respectful)
|
||||||
(sml/setup))
|
(sml/setup))
|
||||||
|
|
||||||
|
|
||||||
;;; ### Switching themes ###
|
;;; ### Switching themes ###
|
||||||
|
|
||||||
(use-package zenburn-theme
|
(use-package base16-theme
|
||||||
:defer)
|
|
||||||
|
|
||||||
(use-package apropospriate-theme
|
|
||||||
:defer)
|
:defer)
|
||||||
|
|
||||||
(use-package faff-theme
|
(use-package faff-theme
|
||||||
:defer)
|
:defer)
|
||||||
|
|
||||||
(setq my-dark-theme 'zenburn
|
(setq my-dark-theme 'base16-espresso
|
||||||
my-light-theme 'apropospriate-light)
|
my-light-theme 'base16-mexico-light)
|
||||||
|
|
||||||
(defun my-select-theme (theme)
|
(defun my-select-theme (theme)
|
||||||
(mapc #'disable-theme custom-enabled-themes)
|
(mapc #'disable-theme custom-enabled-themes)
|
||||||
@ -510,6 +511,16 @@
|
|||||||
t)
|
t)
|
||||||
(sml/setup))
|
(sml/setup))
|
||||||
|
|
||||||
|
(defun my-select-theme-if-none-selected (frame)
|
||||||
|
(if (and (eq 'x (window-system frame))
|
||||||
|
(null (seq-filter (lambda (theme)
|
||||||
|
(not (string-prefix-p "smart-mode-line-" (symbol-name theme))))
|
||||||
|
custom-enabled-themes)))
|
||||||
|
(my-select-theme 'dark)))
|
||||||
|
|
||||||
|
(my-select-theme-if-none-selected nil)
|
||||||
|
(add-to-list 'after-make-frame-functions #'my-select-theme-if-none-selected)
|
||||||
|
|
||||||
(defun my-toggle-theme ()
|
(defun my-toggle-theme ()
|
||||||
"Toggle between dark and light themes."
|
"Toggle between dark and light themes."
|
||||||
(interactive)
|
(interactive)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user