aboutsummaryrefslogtreecommitdiff
path: root/misc
diff options
context:
space:
mode:
Diffstat (limited to 'misc')
-rw-r--r--misc/eselect-mode.el7
1 files changed, 4 insertions, 3 deletions
diff --git a/misc/eselect-mode.el b/misc/eselect-mode.el
index e59c90c..06843df 100644
--- a/misc/eselect-mode.el
+++ b/misc/eselect-mode.el
@@ -148,10 +148,11 @@
(setq tab-width 4)
(setq indent-tabs-mode t))
-(add-hook 'eselect-mode-hook
- (lambda () (font-lock-add-keywords
- nil eselect-mode-font-lock-keywords)))
+(defun eselect-mode-add-font-lock ()
+ "Add `eselect-mode' font-lock keywords for the current buffer."
+ (font-lock-add-keywords nil eselect-mode-font-lock-keywords))
+(add-hook 'eselect-mode-hook 'eselect-mode-add-font-lock)
;;;###autoload
(add-to-list 'auto-mode-alist '("\\.eselect\\'" . eselect-mode))