diff --git a/core/core-ui.el b/core/core-ui.el index 97cab4a98..a93458807 100644 --- a/core/core-ui.el +++ b/core/core-ui.el @@ -223,11 +223,10 @@ read-only or not file-visiting." ;; prompts the user for confirmation when deleting a non-empty frame (global-set-key [remap delete-frame] #'doom/delete-frame) -;; Use this instead of `whitespace-mode' because it's faster (implemented in C) -(setq-default show-trailing-whitespace t) -;; Except in the minibuffer and read-only/special buffers -(setq-hook! 'minibuffer-setup-hook show-trailing-whitespace nil) -(setq-hook! 'change-major-mode-after-body-hook show-trailing-whitespace (not buffer-read-only)) +;; Use `show-trailing-whitespace' instead of `whitespace-mode' because it's +;; faster (implemented in C). But try to only enable it in editing buffers. +(setq-default show-trailing-whitespace nil) +(setq-hook! '(prog-mode-hook text-mode-hook conf-mode-hook) show-trailing-whitespace t) ;; The native border "consumes" a pixel of the fringe on righter-most splits, ;; `window-divider' does not. Available since Emacs 25.1.