merge whitespace-style with global value, not local
And ensure it runs as late as possible in after-change-major-mode-hook. Hopefully to increase the probability of doom-highlight-non-default-indentation-h detecting a user-enabled whitespace-mode and bowing out in time.
This commit is contained in:
parent
9311744f7f
commit
88096a81a9
1 changed files with 2 additions and 2 deletions
|
@ -141,7 +141,7 @@ read-only or not file-visiting."
|
|||
(set (make-local-variable 'whitespace-style)
|
||||
(let ((style (if indent-tabs-mode '(indentation) '(tabs tab-mark))))
|
||||
(if whitespace-mode
|
||||
(cl-union style whitespace-style)
|
||||
(cl-union style (default-value 'whitespace-style))
|
||||
`(face ,@style))))
|
||||
(add-to-list 'whitespace-style 'face)
|
||||
(whitespace-mode +1)))
|
||||
|
@ -649,7 +649,7 @@ startup (or theme switch) time, so long as `doom--prefer-theme-elc' is non-nil."
|
|||
(run-hook-wrapped 'doom-init-ui-hook #'doom-try-run-hook)
|
||||
|
||||
(add-to-list 'kill-buffer-query-functions #'doom-protect-fallback-buffer-h nil 'eq)
|
||||
(add-hook 'after-change-major-mode-hook #'doom-highlight-non-default-indentation-h)
|
||||
(add-hook 'after-change-major-mode-hook #'doom-highlight-non-default-indentation-h 'append)
|
||||
|
||||
;; Initialize custom switch-{buffer,window,frame} hooks:
|
||||
;; + `doom-switch-buffer-hook'
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue