Commit bbe6126c authored by Michael Kifer's avatar Michael Kifer
Browse files

*** empty log message ***

parent fce30d79
;;; ediff-diff.el --- diff-related utilities
;; Copyright (C) 1994, 1995 Free Software Foundation, Inc.
;; Copyright (C) 1994, 1995, 1996 Free Software Foundation, Inc.
;; Author: Michael Kifer <kifer@cs.sunysb.edu>
......@@ -28,7 +28,8 @@
(defvar ediff-shell
(cond ((eq system-type 'emx) "cmd") ; OS/2
((eq system-type 'ms-dos) shell-file-name) ; no standard name on MS-DOS
((memq system-type '(ms-dos windows-nt windows-95))
shell-file-name) ; no standard name on MS-DOS
((memq system-type '(vax-vms axp-vms)) "*dcl*") ; VMS
(t "sh")) ; UNIX
"*The shell used to run diff and patch. If user's .profile or
......@@ -63,7 +64,7 @@ Must produce output compatible with Unix's diff3 program.")
(defvar ediff-diff3-options ""
"*Options to pass to `ediff-diff3-program'.")
(defvar ediff-diff3-ok-lines-regexp
"^\\([1-3]:\\|====\\| \\|.*Warning *:\\|.*No newline\\|.*missing newline\\)"
"^\\([1-3]:\\|====\\| \\|.*Warning *:\\|.*No newline\\|.*missing newline\\|^\C-m$\\)"
"*Regexp that matches normal output lines from `ediff-diff3-program'.
Lines that do not match are assumed to be error messages.")
......@@ -71,18 +72,6 @@ Lines that do not match are assumed to be error messages.")
;; the status can be =diff(A), =diff(B), or =diff(A+B)
(ediff-defvar-local ediff-diff-status "" "")
;; Support for patch
(defvar ediff-patch-program "patch"
"*Name of the program that applies patches.")
(defvar ediff-patch-options ""
"*Options to pass to ediff-patch-program.")
;; The buffer of the patch file.
(defvar ediff-patch-buf nil)
;; The buffer where patch would display its diagnostics.
(defvar ediff-patch-diagnostics nil)
;;; Fine differences
......@@ -99,13 +88,13 @@ Use `setq-default' if setting it in .emacs")
This variable can be set either in .emacs or toggled interactively.
Use `setq-default' if setting it in .emacs")
(ediff-defvar-local ediff-auto-refine-limit 700
"Auto-refine only those regions that are smaller than this number of bytes.")
(ediff-defvar-local ediff-auto-refine-limit 1400
"*Auto-refine only the regions of this size \(in bytes\) or less.")
;;; General
(defvar ediff-diff-ok-lines-regexp
"^\\([0-9,]+[acd][0-9,]+$\\|[<>] \\|---\\|.*Warning *:\\|.*No newline\\|.*missing newline\\)"
"^\\([0-9,]+[acd][0-9,]+$\\|[<>] \\|---\\|.*Warning *:\\|.*No +newline\\|.*missing +newline\\|^\C-m$\\)"
"Regexp that matches normal output lines from `ediff-diff-program'.
This is mostly lifted from Emerge, except that Ediff also considers
warnings and `Missing newline'-type messages to be normal output.
......@@ -138,19 +127,47 @@ one optional arguments, diff-number to refine.")
;;; ;; When xemacs implements minibufferless frames, this won't be necessary
;;; (if ediff-xemacs-p (setq synchronize-minibuffers t))
;; create, if it doesn't exist
(or (ediff-buffer-live-p ediff-diff-buffer)
(setq ediff-diff-buffer
(get-buffer-create (ediff-unique-buffer-name "*ediff-diff" "*"))))
(message "Computing differences ...")
(ediff-exec-process ediff-diff-program ediff-diff-buffer 'synchronize
ediff-diff-options file-A file-B)
(ediff-make-diff2-buffer ediff-diff-buffer file-A file-B)
(ediff-prepare-error-list ediff-diff-ok-lines-regexp ediff-diff-buffer)
;;(message "Computing differences ... done")
(ediff-convert-diffs-to-overlays
(ediff-extract-diffs
ediff-diff-buffer ediff-word-mode ediff-narrow-bounds)))
;; fill in DIFF-BUFFER with the output from the diff program run on FILE1 and
;; FILE2
;; Return the length of that buffer.
(defun ediff-make-diff2-buffer (diff-buffer file1 file2)
(cond ((< (ediff-file-size file1) 0)
(message "Can't diff remote files: %s"
(ediff-abbreviate-file-name file1))
(sit-for 2)
;; 1 is an error exit code
1)
((< (ediff-file-size file2) 0)
(message "Can't diff remote file: %s"
(ediff-abbreviate-file-name file2))
(sit-for 2)
(message "")
;; 1 is an error exit code
1)
(t (message "Computing differences between %s and %s ..."
(file-name-nondirectory file1)
(file-name-nondirectory file2))
;; this erases the diff buffer automatically
(ediff-exec-process ediff-diff-program
diff-buffer
'synchronize
ediff-diff-options file1 file2)
;;(message "Computing differences ... done")
(message "")
(ediff-eval-in-buffer diff-buffer
(buffer-size)))))
;; If file-A/B/C is nil, do 2-way comparison with the non-nil buffers
;; This function works for diff3 and diff2 jobs
......@@ -500,7 +517,7 @@ one optional arguments, diff-number to refine.")
(or n (setq n ediff-current-difference))
(if (< ediff-number-of-differences 1)
(error "Sorry, it is not my job to munch identical variants..."))
(error ediff-NO-DIFFERENCES))
(if ediff-word-mode
(setq flag 'skip
......@@ -524,7 +541,8 @@ one optional arguments, diff-number to refine.")
(cond ((and (eq flag 'noforce) (ediff-get-fine-diff-vector n 'A))
;; don't compute fine diffs if diff vector exists
(if (ediff-no-fine-diffs-p n)
(ediff-message-if-verbose
;;(ediff-message-if-verbose
(message
"Only white-space differences in region %d" (1+ n))))
;; If one of the regions is empty (or 2 in 3way comparison)
;; then don't refine.
......@@ -548,16 +566,19 @@ one optional arguments, diff-number to refine.")
(empty-B 'B)
(empty-C 'C)))
)
;; if all regions happen to be whitespace, indicate this
;; if all regions happen to be whitespace
(if (and whitespace-A whitespace-B whitespace-C)
;; mark as space only
(ediff-mark-diff-as-space-only n t)
;; if some regions are white and others don't, then mark as
;; non-white-space-only
(ediff-mark-diff-as-space-only n nil)))
;; don't compute fine diffs for this region
((eq flag 'skip)
(or (ediff-get-fine-diff-vector n 'A)
(memq ediff-auto-refine '(off nix))
(ediff-message-if-verbose
"Region %d exceeds auto-refine limit. `%s' force-refines"
"Region %d exceeds auto-refine limit. Type `%s' to refine"
(1+ n)
(substitute-command-keys
"\\[ediff-make-or-kill-fine-diffs]")
......@@ -605,20 +626,20 @@ one optional arguments, diff-number to refine.")
((and ediff-3way-job whitespace-B)
(ediff-setup-fine-diff-regions file-A nil file-C n))
((and ediff-3way-job
(or whitespace-C
(and ediff-merge-job
(ediff-looks-like-combined-merge n))))
;; In merge-jobs, whitespace-C is t, since
;; ediff-empty-diff-region-p returns t in this case
whitespace-C)
(ediff-setup-fine-diff-regions file-A file-B nil n))
(t
(ediff-setup-fine-diff-regions file-A file-B file-C n)))
(setq cumulative-fine-diff-length
(+ (length (ediff-get-fine-diff-vector n 'A))
(length (ediff-get-fine-diff-vector n 'B))
(if file-C
(length
(ediff-get-fine-diff-vector n 'C))
0)))
(length (ediff-get-fine-diff-vector n 'B))
;; in merge jobs, the merge buffer is never refined
(if (and file-C (not ediff-merge-job))
(length (ediff-get-fine-diff-vector n 'C))
0)))
(cond ((or
;; all regions are white space
......@@ -632,7 +653,7 @@ one optional arguments, diff-number to refine.")
(ediff-message-if-verbose
"Only white-space differences in region %d" (1+ n)))
((eq cumulative-fine-diff-length 0)
(ediff-mark-diff-as-space-only n nil)
(ediff-mark-diff-as-space-only n t)
(ediff-message-if-verbose
"Only white-space differences in region %d %s"
(1+ n)
......@@ -847,7 +868,7 @@ one optional arguments, diff-number to refine.")
;; leave point after matched line
(beginning-of-line 2)
(let ((agreement (buffer-substring (match-beginning 1) (match-end 1))))
;; if the A and B files are the same and not 3way-comparison,
;; if the files A and B are the same and not 3way-comparison,
;; ignore the difference
(if (or three-way-comp (not (string-equal agreement "3")))
(let* ((a-begin (car (ediff-get-diff3-group "1")))
......@@ -1164,6 +1185,11 @@ argument to `skip-chars-forward'."
(point))))
;;; Local Variables:
;;; eval: (put 'ediff-defvar-local 'lisp-indent-hook 'defun)
;;; eval: (put 'ediff-eval-in-buffer 'lisp-indent-hook 1)
;;; End:
(provide 'ediff-diff)
......
;;; ediff-hook.el --- setup for Ediff's menus and autoloads
;; Copyright (C) 1995 Free Software Foundation, Inc.
;; Copyright (C) 1995, 1996 Free Software Foundation, Inc.
;; Author: Michael Kifer <kifer@cs.sunysb.edu>
......@@ -25,10 +25,6 @@
;;; These must be placed in menu-bar.el in Emacs
;;
;; (define-key menu-bar-tools-menu [ediff-doc]
;; '("Ediff Manual..." . ediff-documentation))
;; (define-key menu-bar-tools-menu [eregistry]
;; '("List Ediff Sessions..." . ediff-show-registry))
;; (define-key menu-bar-tools-menu [epatch]
;; '("Apply Patch" . menu-bar-epatch-menu))
;; (define-key menu-bar-tools-menu [ediff-merge]
......@@ -36,6 +32,11 @@
;; (define-key menu-bar-tools-menu [ediff]
;; '("Compare" . menu-bar-ediff-menu))
;; Compiler pacifier
(defvar ediff-menu)
(defvar ediff-merge-menu)
(defvar epatch-menu)
;; end pacifier
(defun ediff-xemacs-init-menus ()
(if (featurep 'menubar)
......@@ -46,12 +47,6 @@
'("Tools") ediff-merge-menu "OO-Browser...")
(add-submenu
'("Tools") epatch-menu "OO-Browser...")
(add-menu-button
'("Tools")
["List Ediff Sessions..." ediff-show-registry t] "OO-Browser...")
(add-menu-button
'("Tools")
["Ediff Manual..." ediff-documentation t] "OO-Browser...")
(add-menu-button
'("Tools")
["-------" nil nil] "OO-Browser...")
......@@ -78,6 +73,9 @@
"---"
["Regions Word-by-word..." ediff-regions-wordwise t]
["Regions Line-by-line..." ediff-regions-linewise t]
"---"
["List Ediff Sessions..." ediff-show-registry t]
["Ediff Manual..." ediff-documentation t]
))
(defvar ediff-merge-menu
'("Merge"
......@@ -97,11 +95,17 @@
["Directory Revisions..." ediff-merge-directory-revisions t]
["Directory Revisions with Ancestor..."
ediff-merge-directory-revisions-with-ancestor t]
"---"
["List Ediff Sessions..." ediff-show-registry t]
["Ediff Manual..." ediff-documentation t]
))
(defvar epatch-menu
'("Apply Patch"
["To a file..." ediff-patch-file t]
["To a buffer..." ediff-patch-buffer t]
"---"
["List Ediff Sessions..." ediff-show-registry t]
["Ediff Manual..." ediff-documentation t]
))
;; put these menus before Object-Oriented-Browser in Tools menu
......@@ -122,6 +126,11 @@
(fset 'menu-bar-ediff-menu (symbol-value 'menu-bar-ediff-menu))
;; define ediff-menu
(define-key menu-bar-ediff-menu [ediff-doc]
'("Ediff Manual..." . ediff-documentation))
(define-key menu-bar-ediff-menu [eregistry]
'("List Ediff Sessions..." . ediff-show-registry))
(define-key menu-bar-ediff-menu [separator-ediff-manual] '("--"))
(define-key menu-bar-ediff-menu [window]
'("This Window and Next Window" . compare-windows))
(define-key menu-bar-ediff-menu [ediff-windows-linewise]
......@@ -154,6 +163,12 @@
'("Two Files..." . ediff-files))
;; define merge menu
(define-key menu-bar-ediff-merge-menu [ediff-doc2]
'("Ediff Manual..." . ediff-documentation))
(define-key menu-bar-ediff-merge-menu [eregistry2]
'("List Ediff Sessions..." . ediff-show-registry))
(define-key
menu-bar-ediff-merge-menu [separator-ediff-merge-manual] '("--"))
(define-key
menu-bar-ediff-merge-menu [ediff-merge-dir-revisions-with-ancestor]
'("Directory Revisions with Ancestor..."
......@@ -187,6 +202,11 @@
'("Files..." . ediff-merge-files))
;; define epatch menu
(define-key menu-bar-epatch-menu [ediff-doc3]
'("Ediff Manual..." . ediff-documentation))
(define-key menu-bar-epatch-menu [eregistry3]
'("List Ediff Sessions..." . ediff-show-registry))
(define-key menu-bar-epatch-menu [separator-epatch] '("--"))
(define-key menu-bar-epatch-menu [ediff-patch-buffer]
'("To a Buffer..." . ediff-patch-buffer))
(define-key menu-bar-epatch-menu [ediff-patch-file]
......@@ -202,84 +222,93 @@
(autoload 'ediff "ediff" "Compare two files" t)
(autoload 'ediff-files "ediff" "Compare two files" t)
(autoload 'ediff-buffers "ediff" "Compare two bufers" t)
(autoload 'ebuffers "ediff" "Compare two bufers" t)
(autoload 'ediff3 "ediff" "Compare three files" t)
(autoload 'ediff-files3 "ediff" "Compare three files" t)
(autoload 'ediff-buffers3 "ediff" "Compare three bufers" t)
(autoload 'ebuffers3 "ediff" "Compare three bufers" t)
(autoload 'ediff-revision "ediff" "Compare versions of a file" t)
;; compare regions and windows
(autoload 'ediff-windows-wordwise
"ediff" "Compare two windows word-by-word" t)
"ediff" "Compare two windows word-by-word." t)
(autoload 'ediff-regions-wordwise
"ediff" "Compare two regions word-by-word" t)
"ediff" "Compare two regions word-by-word." t)
(autoload 'ediff-windows-linewise
"ediff" "Compare two windows line-by-line" t)
"ediff" "Compare two windows line-by-line." t)
(autoload 'ediff-regions-linewise
"ediff" "Compare two regions line-by-line" t)
"ediff" "Compare two regions line-by-line." t)
;; patch
(autoload 'ediff-patch-file "ediff" "Patch a file" t)
(autoload 'epatch "ediff" "Patch a file" t)
(autoload 'ediff-patch-buffer "ediff" "Patch a buffer")
(autoload 'epatch-buffer "ediff" "Patch a buffer" t)
(autoload 'ediff-patch-file "ediff" "Patch a file." t)
(autoload 'epatch "ediff" "Patch a file." t)
(autoload 'ediff-patch-buffer "ediff" "Patch a buffer.")
(autoload 'epatch-buffer "ediff" "Patch a buffer." t)
;; merge
(autoload 'ediff-merge "ediff" "Merge two files" t)
(autoload 'ediff-merge-files "ediff" "Merge two files" t)
(autoload 'ediff-merge "ediff" "Merge two files." t)
(autoload 'ediff-merge-files "ediff" "Merge two files." t)
(autoload 'ediff-merge-files-with-ancestor
"ediff" "Merge two files using a third file as an ancestor" t)
(autoload 'ediff-merge-buffers "ediff" "Merge two buffers" t)
"ediff" "Merge two files using a third file as an ancestor." t)
(autoload 'ediff-merge-buffers "ediff" "Merge two buffers." t)
(autoload 'ediff-merge-buffers-with-ancestor
"ediff" "Merge two buffers using a third buffer as an ancestor" t)
"ediff" "Merge two buffers using a third buffer as an ancestor." t)
(autoload 'ediff-merge-revisions "ediff" "Merge two versions of a file" t)
(autoload 'ediff-merge-revisions "ediff" "Merge two versions of a file." t)
(autoload 'ediff-merge-revisions-with-ancestor
"ediff" "Merge two versions of a file" t)
"ediff" "Merge two versions of a file." t)
;; compare directories
(autoload 'edirs "ediff" "Compare files in two directories" t)
(autoload 'ediff-directories "ediff" "Compare files in two directories" t)
(autoload 'edirs3 "ediff" "Compare files in three directories" t)
(autoload 'ediff-directories3 "ediff" "Compare files in three directories" t)
(autoload 'edirs "ediff" "Compare files in two directories." t)
(autoload 'ediff-directories "ediff" "Compare files in two directories." t)
(autoload 'edirs3 "ediff" "Compare files in three directories." t)
(autoload
'ediff-directories3 "ediff" "Compare files in three directories." t)
(autoload 'edir-revisions
"ediff" "Compare two versions of a file" t)
"ediff" "Compare two versions of a file." t)
(autoload 'ediff-directory-revisions
"ediff" "Compare two versions of a file" t)
"ediff" "Compare two versions of a file." t)
;; merge directories
(autoload 'edirs-merge "ediff" "Merge files in two directories" t)
(autoload 'edirs-merge "ediff" "Merge files in two directories." t)
(autoload 'ediff-merge-directories
"ediff" "Merge files in two directories" t)
"ediff" "Merge files in two directories." t)
(autoload 'edirs-merge-with-ancestor
"ediff"
"Merge files in two directories using files in a third dir as ancestors" t)
"Merge files in two directories using files in a third dir as ancestors."
t)
(autoload 'ediff-merge-directories-with-ancestor
"ediff"
"Merge files in two directories using files in a third dir as ancestors" t)
"Merge files in two directories using files in a third dir as ancestors."
t)
(autoload 'edir-merge-revisions
"ediff" "Merge versions of files in a directory" t)
"ediff" "Merge versions of files in a directory." t)
(autoload 'ediff-merge-directory-revisions
"ediff" "Merge versions of files in a directory" t)
"ediff" "Merge versions of files in a directory." t)
(autoload 'ediff-merge-directory-revisions-with-ancestor
"ediff"
"Merge versions of files in a directory using other versions as ancestors"
"Merge versions of files in a directory using other versions as ancestors."
t)
(autoload 'edir-merge-revisions-with-ancestor
"ediff"
"Merge versions of files in a directory using other versions as ancestors"
"Merge versions of files in a directory using other versions as ancestors."
t)
;; misc
(autoload 'ediff-show-registry
"ediff-meta"
"Display the registry of active Ediff sessions"
"Display the registry of active Ediff sessions."
t)
(autoload 'ediff-documentation
"ediff"
"Display Ediff's manual."
t)
(autoload 'ediff-version
"ediff"
"Show Ediff's version and last modification date"
"Show Ediff's version and last modification date."
t)
) ; if purify-flag
......
;;; ediff-init.el --- Macros, variables, and defsubsts used by Ediff
;; Copyright (C) 1994, 1995 Free Software Foundation, Inc.
;; Copyright (C) 1994, 1995, 1996 Free Software Foundation, Inc.
;; Author: Michael Kifer <kifer@cs.sunysb.edu>
......@@ -23,15 +23,33 @@
;;; Code:
;; Start compiler pacifier
(defvar ediff-metajob-name)
(defvar ediff-meta-buffer)
(defvar pm-color-alist)
(defvar ediff-grab-mouse)
(defvar ediff-mouse-pixel-position)
(defvar ediff-mouse-pixel-threshold)
(defvar ediff-whitespace)
(defvar ediff-multiframe)
;; end pacifier
;; Is it XEmacs?
(defconst ediff-xemacs-p (string-match "XEmacs" emacs-version))
;; Is it Emacs?
(defconst ediff-emacs-p (not ediff-xemacs-p))
(defvar ediff-force-faces nil
"If t, Ediff will think that it is running on a display that supports faces.
This is provided as a temporary relief for users of face-capable displays
that Ediff doesn't know about.")
;; Are we running as a window application or on a TTY?
(defsubst ediff-device-type ()
(if ediff-emacs-p
window-system
(device-type (selected-device))))
;; in XEmacs: device-type is tty on tty and stream in batch.
(defun ediff-window-display-p ()
(and (ediff-device-type) (not (memq (ediff-device-type) '(tty pc stream)))))
......@@ -45,6 +63,35 @@
(ediff-emacs-p (memq (ediff-device-type) '(pc)))
(ediff-xemacs-p (memq (ediff-device-type) '(tty pc)))))
;; Defines SYMBOL as an advertised local variable.
;; Performs a defvar, then executes `make-variable-buffer-local' on
;; the variable. Also sets the `permanent-local' property,
;; so that `kill-all-local-variables' (called by major-mode setting
;; commands) won't destroy Ediff control variables.
;;
;; Plagiarised from `emerge-defvar-local' for XEmacs.
(defmacro ediff-defvar-local (var value doc)
(` (progn
(defvar (, var) (, value) (, doc))
(make-variable-buffer-local '(, var))
(put '(, var) 'permanent-local t))))
;; Variables that control each Ediff session---local to the control buffer.
;; Mode variables
;; The buffer in which the A variant is stored.
(ediff-defvar-local ediff-buffer-A nil "")
;; The buffer in which the B variant is stored.
(ediff-defvar-local ediff-buffer-B nil "")
;; The buffer in which the C variant is stored.
(ediff-defvar-local ediff-buffer-C nil "")
;; Ancestor buffer
(ediff-defvar-local ediff-ancestor-buffer nil "")
;; The control buffer of ediff.
(ediff-defvar-local ediff-control-buffer nil "")
;;; Macros
(defmacro ediff-odd-p (arg)
......@@ -130,20 +177,6 @@
(` (ediff-get-fine-diff-vector-from-diff-record
(ediff-get-difference (, n) (, buf-type)))))
;; Defines SYMBOL as an advertised local variable.
;; Performs a defvar, then executes `make-variable-buffer-local' on
;; the variable. Also sets the `permanent-local' property,
;; so that `kill-all-local-variables' (called by major-mode setting
;; commands) won't destroy Ediff control variables.
;;
;; Plagiarised from `emerge-defvar-local' for XEmacs.
(defmacro ediff-defvar-local (var value doc)
(` (progn
(defvar (, var) (, value) (, doc))
(make-variable-buffer-local '(, var))
(put '(, var) 'permanent-local t))))
;; Macro to switch to BUFFER, evaluate FORMS, returns to original buffer.
;; Differs from `save-excursion' in that it doesn't save the point and mark.
;; This is essentially `emerge-eval-in-buffer' with the test for live buffers."
......@@ -229,9 +262,14 @@
'(ediff-directory-revisions
ediff-merge-directory-revisions
ediff-merge-directory-revisions-with-ancestor)))
;; metajob involving only one directory
(defsubst ediff-dir1-metajob (&optional metajob)
(defsubst ediff-patch-metajob (&optional metajob)
(memq (or metajob ediff-metajob-name)
'(ediff-multifile-patch)))
;; metajob involving only one group of files, such as multipatch or directory
;; revision
(defsubst ediff-one-filegroup-metajob (&optional metajob)
(or (ediff-revision-metajob metajob)
(ediff-patch-metajob metajob)
;; add more here
))
(defsubst ediff-collect-diffs-metajob (&optional metajob)
......@@ -431,7 +469,10 @@ the value of this variable and the variables `ediff-help-message-*' in
(defconst ediff-KILLED-VITAL-BUFFER
"You have killed a vital Ediff buffer---you must leave Ediff now!")
(defconst ediff-NO-DIFFERENCES
"Sorry, it is not my job to munch identical variants...")
"Sorry, comparison of identical variants is not what I am made for...")
(defconst ediff-BAD-DIFF-NUMBER
;; %S stands for this-command, %d - diff number, %d - max diff
"%S: Bad diff region number, %d. Valid numbers are 1 to %d")
;; Selective browsing
......@@ -511,12 +552,6 @@ highlighted using ASCII flags.
This variable can be set either in .emacs or toggled interactively.
Use `setq-default' if setting it in .emacs")
(defvar ediff-force-faces nil
"If t, Ediff will think that it is running on a display that supports faces.
This is provided as a temporary relief for users of face-capable displays
that Ediff doesn't know about.")
;; this indicates that diff regions are word-size, so fine diffs are
;; permanently nixed; used in ediff-windows-wordwise and ediff-regions-wordwise
(ediff-defvar-local ediff-word-mode nil "")
......@@ -560,22 +595,6 @@ ediff-toggle-hilit. Use `setq-default' to set it.")
;; unhighlighted, `off' -- turned off \(on a dumb terminal only\).
(ediff-defvar-local ediff-highlighting-style nil "")
;; Variables that control each Ediff session. They are local to the
;; control buffer.
;; Mode variables
;; The buffer in which the A variant is stored.
(ediff-defvar-local ediff-buffer-A nil "")
;; The buffer in which the B variant is stored.
(ediff-defvar-local ediff-buffer-B nil "")
;; The buffer in which the C variant is stored.
(ediff-defvar-local ediff-buffer-C nil "")
;; Ancestor buffer
(ediff-defvar-local ediff-ancestor-buffer nil "")
;; The control buffer of ediff.
(ediff-defvar-local ediff-control-buffer nil "")
;; The suffix of the control buffer name.
(ediff-defvar-local ediff-control-buffer-suffix nil "")
......@@ -797,18 +816,18 @@ appropriate symbol: `rcs', `pcl-cvs', or `generic-sc' if you so desire.")
(let ((is-current (ediff-overlay-get extent 'ediff))
(face (ediff-overlay-get extent 'face))
(diff-num (ediff-overlay-get extent 'ediff-diff-num))
face-help help-msg)
face-help)
;; This happens only for refinement overlays
(setq face-help (and face (get face 'ediff-help-echo)))
(setq help-msg
(cond ((and is-current diff-num) ; current diff region
(format "Difference region %S -- current" (1+ diff-num)))
(face-help) ; refinement of current diff region
(diff-num ; non-current
(format "Difference region %S -- non-current" (1+ diff-num)))
(t ""))))) ; none
(cond ((and is-current diff-num) ; current diff region
(format "Difference region %S -- current" (1+ diff-num)))
(face-help) ; refinement of current diff region
(diff-num ; non-current
(format "Difference region %S -- non-current" (1+ diff-num)))
(t "")) ; none
))
(defun ediff-set-face (ground face color)
"Set face foreground/background."
......@@ -1353,7 +1372,7 @@ More precisely, a regexp to match any one such character.")
(defun ediff-overlay-buffer (overl)
(if ediff-emacs-p
(overlay-buffer overl)
(and (extent-live-p overl) (extent-buffer overl))))