diff options
author | Stefan Monnier <monnier@iro.umontreal.ca> | 2007-06-20 18:18:31 +0000 |
---|---|---|
committer | Stefan Monnier <monnier@iro.umontreal.ca> | 2007-06-20 18:18:31 +0000 |
commit | d6fc1ed963d4897017a2b9516a27adfeac7814b4 (patch) | |
tree | 0d19b5a70336f520310b879a6b0edc86811fe75e /lisp/log-view.el | |
parent | f0ebdd936884e61b685ba13ac33c59241120298a (diff) | |
download | emacs-d6fc1ed963d4897017a2b9516a27adfeac7814b4.tar.gz |
(log-view-font-lock-keywords): Use `eval' to consult the
buffer-local value of log-view-*-re if applicable.
Diffstat (limited to 'lisp/log-view.el')
-rw-r--r-- | lisp/log-view.el | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/lisp/log-view.el b/lisp/log-view.el index bf029045a8c..5962c216624 100644 --- a/lisp/log-view.el +++ b/lisp/log-view.el @@ -128,13 +128,13 @@ (put 'log-view-message-face 'face-alias 'log-view-message) (defvar log-view-message-face 'log-view-message) -(defconst log-view-file-re +(defvar log-view-file-re (concat "^\\(?:Working file: \\(?1:.+\\)" ;RCS and CVS. ;; Subversion has no such thing?? "\\|\\(?:SCCS/s\\.\\|Changes to \\)\\(?1:.+\\):" ;SCCS and Darcs. "\\)\n")) ;Include the \n for font-lock reasons. -(defconst log-view-message-re +(defvar log-view-message-re (concat "^\\(?:revision \\(?1:[.0-9]+\\)\\(?:\t.*\\)?" ; RCS and CVS. "\\|r\\(?1:[0-9]+\\) | .* | .*" ; Subversion. "\\|D \\(?1:[.0-9]+\\) .*" ; SCCS. @@ -149,11 +149,13 @@ " .*@.*\n\\(?: \\* \\(?1:.*\\)\\)?") "\\)$")) -(defconst log-view-font-lock-keywords - `((,log-view-file-re - (1 (if (boundp 'cvs-filename-face) cvs-filename-face)) - (0 log-view-file-face append)) - (,log-view-message-re . log-view-message-face))) +(defvar log-view-font-lock-keywords + ;; We use `eval' so as to use the buffer-local value of log-view-file-re + ;; and log-view-message-re, if applicable. + '((eval . `(,log-view-file-re + (1 (if (boundp 'cvs-filename-face) cvs-filename-face)) + (0 log-view-file-face append))) + (eval . `(,log-view-message-re . log-view-message-face)))) (defconst log-view-font-lock-defaults '(log-view-font-lock-keywords t nil nil nil)) |