changeset 78085:a861d80cf88c

* log-view.el (log-view-font-lock-keywords): Use `eval' to consult the buffer-local value of log-view-*-re if applicable.
author Dan Nicolaescu <dann@ics.uci.edu>
date Sun, 08 Jul 2007 08:18:12 +0000
parents 3440edc548e3
children 9a13508185dc
files lisp/ChangeLog lisp/vc.el
diffstat 2 files changed, 16 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/ChangeLog	Sun Jul 08 06:54:40 2007 +0000
+++ b/lisp/ChangeLog	Sun Jul 08 08:18:12 2007 +0000
@@ -1,3 +1,8 @@
+2007-06-20  Stefan Monnier  <monnier@iro.umontreal.ca>
+
+	* vc.el (vc-default-log-view-mode): New function.
+	(vc-print-log): Add new `log-view-mode' VC operation.
+
 2007-07-08  Nick Roberts  <nickrob@snap.net.nz>
 
 	* pcvs-util.el (cvs-strings->string, cvs-string->strings):
--- a/lisp/vc.el	Sun Jul 08 06:54:40 2007 +0000
+++ b/lisp/vc.el	Sun Jul 08 08:18:12 2007 +0000
@@ -105,7 +105,9 @@
 ;;
 ;; * registered (file)
 ;;
-;;   Return non-nil if FILE is registered in this backend.
+;;   Return non-nil if FILE is registered in this backend.  Both this
+;;   function as well as `state' should be careful to fail gracefully in the
+;;   event that the backend executable is absent.
 ;;
 ;; * state (file)
 ;;
@@ -270,6 +272,12 @@
 ;;   Insert the revision log of FILE into BUFFER, or the *vc* buffer
 ;;   if BUFFER is nil.
 ;;
+;; - log-view-mode ()
+;;
+;;   Mode to use for the output of print-log.  This defaults to
+;;   `log-view-mode' and is expected to be changed (if at all) to a derived
+;;   mode of `log-view-mode'.
+;;
 ;; - show-log-entry (version)
 ;;
 ;;   If provided, search the log entry for VERSION in the current buffer,
@@ -2449,7 +2457,7 @@
     (pop-to-buffer (current-buffer))
     (vc-exec-after
      `(let ((inhibit-read-only t))
-    	(log-view-mode)
+    	(vc-call-backend ',(vc-backend file) 'log-view-mode)
 	(goto-char (point-max)) (forward-line -1)
 	(while (looking-at "=*\n")
 	  (delete-char (- (match-end 0) (match-beginning 0)))
@@ -2464,6 +2472,7 @@
 			 ',focus-rev)
         (set-buffer-modified-p nil)))))
 
+(defun vc-default-log-view-mode (backend) (log-view-mode))
 (defun vc-default-show-log-entry (backend rev)
   (with-no-warnings
    (log-view-goto-rev rev)))