summaryrefslogtreecommitdiff
path: root/lisp/diff-mode.el
diff options
context:
space:
mode:
authorStefan Monnier <monnier@iro.umontreal.ca>2001-05-01 13:33:59 +0000
committerStefan Monnier <monnier@iro.umontreal.ca>2001-05-01 13:33:59 +0000
commit469fc0a23fd52eae6a754d2439acae358016bcd7 (patch)
treec3364314156c27b28486cb30b3d831d6372aa8b7 /lisp/diff-mode.el
parented438271883d22cc66abea45b75817b67dcddb41 (diff)
downloademacs-469fc0a23fd52eae6a754d2439acae358016bcd7.tar.gz
(diff-nonexistant-face): New face.
(diff-font-lock-keywords): Use it.
Diffstat (limited to 'lisp/diff-mode.el')
-rw-r--r--lisp/diff-mode.el11
1 files changed, 8 insertions, 3 deletions
diff --git a/lisp/diff-mode.el b/lisp/diff-mode.el
index b53d36bfc79..894a221539d 100644
--- a/lisp/diff-mode.el
+++ b/lisp/diff-mode.el
@@ -4,7 +4,6 @@
;; Author: Stefan Monnier <monnier@cs.yale.edu>
;; Keywords: patch diff
-;; Revision: $Id: diff-mode.el,v 1.35 2000/11/14 18:09:21 fx Exp $
;; This file is part of GNU Emacs.
@@ -250,12 +249,17 @@ when editing big diffs)."
:group 'diff-mode)
(defvar diff-context-face 'diff-context-face)
+(defface diff-nonexistant-face
+ '((t (:inherit diff-file-header-face)))
+ "`diff-mode' face used to highlight nonexistant files in recursive diffs."
+ :group 'diff-mode)
+(defvar diff-nonexistant-face 'diff-nonexistant-face)
+
(defvar diff-font-lock-keywords
'(("^\\(@@ -[0-9,]+ \\+[0-9,]+ @@\\)\\(.*\\)$" ;unified
(1 diff-hunk-header-face)
(2 diff-function-face))
- ("^--- .+ ----$" ;context
- . diff-hunk-header-face)
+ ("^--- .+ ----$" . diff-hunk-header-face) ;context
("\\(\\*\\{15\\}\\)\\(.*\\)$" ;context
(1 diff-hunk-header-face)
(2 diff-function-face))
@@ -267,6 +271,7 @@ when editing big diffs)."
("^[+>].*\n" . diff-added-face)
("^[-<].*\n" . diff-removed-face)
("^Index: \\(.+\\).*\n" (0 diff-header-face) (1 diff-index-face prepend))
+ ("^Only in .*\n" . diff-nonexistant-face)
("^#.*" . font-lock-string-face)
("^[^-=+*!<>].*\n" . diff-context-face)))