LionyxML / auto-dark-emacs

Auto-Dark-Emacs is an auto changer between 2 themes, dark/light, following MacOS, Linux or Windows Dark Mode settings
GNU General Public License v2.0
140 stars 34 forks source link

Is it possible to load 2 themes for each mode? #54

Closed max6166 closed 2 months ago

max6166 commented 2 months ago

Is there a way to load 2 themes at the same time for dark mode, for example?

LionyxML commented 2 months ago

Sure, you could make it with something like:

(use-package auto-dark
  :ensure t
  :config
  (setq auto-dark-dark-theme 'nil)
  (setq auto-dark-light-theme 'nil)

  (add-hook 'auto-dark-light-mode-hook
            (lambda ()
              (disable-theme 'wombat)
              (disable-theme 'tango-dark)
              (load-theme 'adwaita)
              (load-theme 'leuven)))

  (add-hook 'auto-dark-dark-mode-hook
            (lambda ()
              (disable-theme 'adwaita)
              (disable-theme 'leuven)
              (load-theme 'wombat)
              (load-theme 'tango-dark)))

  (auto-dark-mode t))
max6166 commented 2 months ago

Thank you very much. That works perfectly!