From ed3bdb12c390fb1ef97a532f4bab88c7ff31a06d Mon Sep 17 00:00:00 2001 From: fpi Date: Fri, 14 Feb 2020 17:09:09 +0100 Subject: Update pdf-view-midnight-colors after theme change --- emacs-init.org | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/emacs-init.org b/emacs-init.org index 5afb11f..df14609 100644 --- a/emacs-init.org +++ b/emacs-init.org @@ -807,6 +807,12 @@ The above macro can be used like this. (:background nil :inherit nil)))) #+end_src +Advice =load-theme= to also update the colors for +=pdf-view-midnight-mode=. +#+begin_src emacs-lisp +(defadvice load-theme (after update-pdf-view-midnight-color activate) + (setq pdf-view-midnight-colors `(,(face-attribute 'default :foreground) . ,(face-attribute 'default :background)))) +#+end_src Finally load the theme. #+begin_src emacs-lisp -- cgit v1.2.3