aboutsummaryrefslogtreecommitdiffstats
path: root/man
diff options
context:
space:
mode:
authorStefan Monnier <[email protected]>2000-03-27 04:20:08 +0000
committerStefan Monnier <[email protected]>2000-03-27 04:20:08 +0000
commit8c085080baf318ec0fc376414c5d9202c314a398 (patch)
tree94cf9156c29cac2baa0026d6800acb2b868a7d4b /man
parent0683b6fa90db2a43ca13bb2774255e22d40c4758 (diff)
Update sample code for adding font-lock-keywords
Diffstat (limited to 'man')
-rw-r--r--man/mh-e.texi16
1 files changed, 4 insertions, 12 deletions
diff --git a/man/mh-e.texi b/man/mh-e.texi
index 0492694bbb..8f13b7d073 100644
--- a/man/mh-e.texi
+++ b/man/mh-e.texi
@@ -1,5 +1,5 @@
\input texinfo @c -*-texinfo-*-
-@c $Id: mh-e.texi,v 1.1 1999/09/29 15:17:04 fx Exp $
+@c $Id: mh-e.texi,v 1.2 1999/11/18 15:59:59 eliz Exp $
@c %**start of header
@setfilename ../info/mh-e
@settitle mh-e
@@ -2375,17 +2375,9 @@ very nice feature indeed.
(defun my-mh-show-mode-hook ()
"Hook to turn on and customize fonts."
- (require 'font-lock) ; @r{for font-lock-keywords below}
- (make-local-variable 'font-lock-mode-hook) ; @r{don't affect other buffers}
- (add-hook 'font-lock-mode-hook ; @r{set a hook with inline function}
- (function ; @r{modifies font-lock-keywords when}
- (lambda () ; @r{font-lock-mode run}
- (setq font-lock-keywords
- (append my-mh-keywords font-lock-keywords)))))
- (font-lock-mode 1)) ; @r{change the typefaces}
-
-(if window-system ; @r{can't do this on @sc{ascii} terminal}
- (add-hook 'mh-show-mode-hook 'my-mh-show-mode-hook))
+ (font-lock-add-keywords nil my-mh-keywords))
+
+(add-hook 'mh-show-mode-hook 'my-mh-show-mode-hook))
@end group
@end lisp