diff options
author | Tom Willemse | 2013-06-02 14:29:47 +0200 |
---|---|---|
committer | Tom Willemse | 2013-06-02 14:29:47 +0200 |
commit | 2aef75d7816c4768b7b561b851bcef051c80ca37 (patch) | |
tree | 06c24f775ac22c32152989b609e8558c0590dc8e | |
parent | 42522017831ece7a35ad72130036d172a0fe2343 (diff) | |
download | mode-icons-2aef75d7816c4768b7b561b851bcef051c80ca37.tar.gz mode-icons-2aef75d7816c4768b7b561b851bcef051c80ca37.zip |
Run set-current-mode-icon when starting
Otherwise the currently visited buffer will not have the correct mode
icon set.
-rw-r--r-- | mode-icons.el | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/mode-icons.el b/mode-icons.el index da85875..8807d52 100644 --- a/mode-icons.el +++ b/mode-icons.el @@ -91,7 +91,9 @@ ICON-SPEC should be a specification from `mode-icons'." "Replace the name of the current major mode with an icon." :global t (if mode-icons-mode - (add-hook 'after-change-major-mode-hook 'set-current-mode-icon) + (progn + (add-hook 'after-change-major-mode-hook 'set-current-mode-icon) + (set-current-mode-icon)) (remove-hook 'after-change-major-mode-hook 'set-current-mode-icon))) (provide 'mode-icons) |