Fix invalid sate icon in org-narrow.

narrow-to-region doesn't work in org-narrow-to-subtree, org-narrow-to-block,
org-narrow-to-element. Don't know the root cause.
This commit is contained in:
Vincent Zhang 2019-04-02 00:23:08 +08:00
parent 78f4ee0b8c
commit 64f1cf5de1

View file

@ -286,6 +286,9 @@ Uses `all-the-icons-material' to fetch the icon."
(advice-add #'widen :after #'doom-modeline-update-buffer-file-state-icon) (advice-add #'widen :after #'doom-modeline-update-buffer-file-state-icon)
(advice-add #'fancy-narrow-to-region :after #'doom-modeline-update-buffer-file-state-icon) (advice-add #'fancy-narrow-to-region :after #'doom-modeline-update-buffer-file-state-icon)
(advice-add #'fancy-widen :after #'doom-modeline-update-buffer-file-state-icon) (advice-add #'fancy-widen :after #'doom-modeline-update-buffer-file-state-icon)
(advice-add #'org-narrow-to-subtree :after #'doom-modeline-update-buffer-file-state-icon)
(advice-add #'org-narrow-to-block :after #'doom-modeline-update-buffer-file-state-icon)
(advice-add #'org-narrow-to-element :after #'doom-modeline-update-buffer-file-state-icon)
(when (>= emacs-major-version 26) (when (>= emacs-major-version 26)
(add-variable-watcher (add-variable-watcher