User: michaelk
Date: 06/02/19 04:35:26
Modified: packages/xemacs-packages/ediff ediff.texi ediff.el
ediff-wind.el ediff-vers.el ediff-util.el
ediff-tbar.el ediff-ptch.el ediff-mult.el
ediff-merg.el ediff-init.el ediff-hook.el
ediff-help.el ediff-diff.el ChangeLog
Log:
* ediff-diff.el (ediff-ignore-case, ediff-ignore-case-option,
ediff-ignore-case-option3, ediff-actual-diff-options,
ediff-actual-diff3-options): new variables to control case sensitivity.
(ediff-make-diff2-buffer, ediff-setup-fine-diff-regions,
ediff-setup-diff-regions3): made aware of case-sensitivity.
(ediff-toggle-ignore-case): new function.
(ediff-extract-diffs, ediff-extract-diffs3): preserve point in buffers.
* ediff-help.el (ediff-long-help-message-narrow2,
ediff-long-help-message-compare2, ediff-long-help-message-compare3,
ediff-long-help-message-word-mode): add ignore-case command.
(ediff-help-for-quick-help): add ignore-case command.
* ediff-merg.el: move provide to the end.
* ediff-ptch.el: move provide to the end.
* ediff-wind.el: move provide to the end.
* ediff-mult.el: move provide to the end.
(ediff-set-meta-overlay): enable follow-link.
* ediff.el: move provide to the end.
Break recursive load cycle in eval-when-compile.
(ediff-patch-buffer): better heuristics.
* ediff-util.el: move provide to the end.
Break recursive load cycle in eval-when-compile.
(ediff-setup-keymap): add binding for #c. Replaced some defsubsts with
defuns.
(ediff-submit-report): pass the values of ediff-diff3-program,
ediff-diff3-options.
Revision Changes Path
1.34 +34 -1 XEmacs/packages/xemacs-packages/ediff/ediff.texi
Index: ediff.texi
===================================================================
RCS file: /pack/xemacscvs/XEmacs/packages/xemacs-packages/ediff/ediff.texi,v
retrieving revision 1.33
retrieving revision 1.34
diff -u -p -r1.33 -r1.34
--- ediff.texi 2005/10/06 00:17:44 1.33
+++ ediff.texi 2006/02/19 03:35:17 1.34
@@ -26,7 +26,7 @@ This file documents Ediff, a comprehensi
and patch utilities.
Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
- 2003, 2004, 2005 Free Software Foundation, Inc.
+ 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
@quotation
Permission is granted to copy, distribute and/or modify this document
@@ -686,6 +686,16 @@ Even though such regions will be skipped
one of them by typing the region number and then `j'. Typing @kbd{##}
again puts Ediff back in the original state.
+@item #c
+@kindex #c
+@vindex ediff-ignore-case-option
+@vindex ediff-ignore-case-option3
+@vindex ediff-ignore-case
+Toggle case sensitivity in the diff program. All diffs are recomputed.
+Case sensitivity is controlled by the variables
+@code{ediff-ignore-case-option}, @code{ediff-ignore-case-option3},
+and @code{ediff-ignore-case}, which are explained elsewhere.
+
@item #h
@itemx #f
@kindex #f
@@ -1584,6 +1594,28 @@ Ediff may take a long time to skip over
differences of all intermediate regions. This delay does not indicate any
problem.
+@vindex ediff-ignore-case-option
+@vindex ediff-ignore-case-option3
+@vindex ediff-ignore-case
+Finally, Ediff can be told to ignore the case of the letters. This behavior
+can be toggled with @kbd{#c} and it is controlled with three variables:
+Toggle case sensitivity in the diff program. All diffs are recomputed.
+Case sensitivity is controlled by the variables
+@code{ediff-ignore-case-option}, @code{ediff-ignore-case-option3}, and
+@code{ediff-ignore-case}.
+
+The variable @code{ediff-ignore-case-option} specifies the option to pass
+to the diff program for comparing two files or buffers. For GNU
+@code{diff}, this option is @code{"-i"}. The variable
+@code{ediff-ignore-case-option3} specifies the option to pass to the
+@code{diff3} program in order to make it case-insensitive. GNU @code{diff3}
+does not have such an option, so when merging or comparing three files with
+this program, ignoring the letter case is not supported.
+
+The variable @code{ediff-ignore-case} controls whether Ediff starts out by
+ignoring letter case or not. It can be set in @file{.emacs} using
+@code{setq-default}.
+
@node Highlighting Difference Regions, Narrowing, Selective Browsing, Customization
@section Highlighting Difference Regions
@@ -2388,6 +2420,7 @@ Here is a hopefully full list of contrib
@example
Adrian Aichner (aichner@(a)ecf.teradyne.com),
+Drew Adams (drew.adams@(a)oracle.com),
Steve Baur (steve@(a)xemacs.org),
Neal Becker (neal@(a)ctd.comsat.com),
E.@: Jay Berkenbilt (ejb@(a)ql.org),
1.33 +8 -5 XEmacs/packages/xemacs-packages/ediff/ediff.el
Index: ediff.el
===================================================================
RCS file: /pack/xemacscvs/XEmacs/packages/xemacs-packages/ediff/ediff.el,v
retrieving revision 1.32
retrieving revision 1.33
diff -u -p -r1.32 -r1.33
--- ediff.el 2005/11/25 07:31:38 1.32
+++ ediff.el 2006/02/19 03:35:17 1.33
@@ -1,14 +1,14 @@
;;; ediff.el --- a comprehensive visual interface to diff & patch
;; Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
-;; 2003, 2004, 2005 Free Software Foundation, Inc.
+;; 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
;; Author: Michael Kifer <kifer(a)cs.stonybrook.edu>
;; Created: February 2, 1994
;; Keywords: comparing, merging, patching, tools, unix
-(defconst ediff-version "2.80.1" "The current version of Ediff")
-(defconst ediff-date "November 25, 2005" "Date of last update")
+(defconst ediff-version "2.81" "The current version of Ediff")
+(defconst ediff-date "February 18, 2006" "Date of last update")
;; This file is part of GNU Emacs.
@@ -107,7 +107,6 @@
;;; Code:
-(provide 'ediff)
;; Compiler pacifier
(defvar cvs-cookie-handle)
@@ -121,6 +120,7 @@
(load "pcl-cvs" 'noerror)))
(eval-when-compile
(let ((load-path (cons (expand-file-name ".") load-path)))
+ (provide 'ediff) ; to break recursive load cycle
(or (featurep 'ediff-init)
(load "ediff-init.el" nil nil 'nosuffix))
(or (featurep 'ediff-mult)
@@ -1374,7 +1374,7 @@ patch. If not given, the user is prompte
patch-buf
(read-buffer
"Which buffer to patch? "
- (current-buffer))))
+ (ediff-other-buffer patch-buf))))
;;;###autoload
@@ -1532,6 +1532,9 @@ With optional NODE, goes to that node."
(require 'ediff-util)
(run-hooks 'ediff-load-hook)
+
+(provide 'ediff)
+
;;; Local Variables:
;;; eval: (put 'ediff-defvar-local 'lisp-indent-hook 'defun)
1.23 +4 -2 XEmacs/packages/xemacs-packages/ediff/ediff-wind.el
Index: ediff-wind.el
===================================================================
RCS file: /pack/xemacscvs/XEmacs/packages/xemacs-packages/ediff/ediff-wind.el,v
retrieving revision 1.22
retrieving revision 1.23
diff -u -p -r1.22 -r1.23
--- ediff-wind.el 2005/11/29 06:16:20 1.22
+++ ediff-wind.el 2006/02/19 03:35:17 1.23
@@ -1,7 +1,7 @@
;;; ediff-wind.el --- window manipulation utilities
;; Copyright (C) 1994, 1995, 1996, 1997, 2000, 2001, 2002, 2003,
-;; 2004, 2005 Free Software Foundation, Inc.
+;; 2004, 2005, 2006 Free Software Foundation, Inc.
;; Author: Michael Kifer <kifer(a)cs.stonybrook.edu>
@@ -26,7 +26,6 @@
;;; Code:
-(provide 'ediff-wind)
;; Compiler pacifier
(defvar icon-title-format)
@@ -1312,6 +1311,9 @@ It assumes that it is called from within
ediff-split-window-function
(ediff-multiframe-setup-p)
ediff-wide-display-p)))))))
+
+
+(provide 'ediff-wind)
;;; Local Variables:
1.15 +2 -1 XEmacs/packages/xemacs-packages/ediff/ediff-vers.el
Index: ediff-vers.el
===================================================================
RCS file: /pack/xemacscvs/XEmacs/packages/xemacs-packages/ediff/ediff-vers.el,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -p -r1.14 -r1.15
--- ediff-vers.el 2005/09/20 17:54:29 1.14
+++ ediff-vers.el 2006/02/19 03:35:18 1.15
@@ -1,7 +1,7 @@
;;; ediff-vers.el --- version control interface to Ediff
;; Copyright (C) 1995, 1996, 1997, 2002, 2003, 2004,
-;; 2005 Free Software Foundation, Inc.
+;; 2005, 2006 Free Software Foundation, Inc.
;; Author: Michael Kifer <kifer(a)cs.stonybrook.edu>
@@ -310,6 +310,7 @@
(provide 'ediff-vers)
+
;;; Local Variables:
;;; eval: (put 'ediff-defvar-local 'lisp-indent-hook 'defun)
1.32 +12 -8 XEmacs/packages/xemacs-packages/ediff/ediff-util.el
Index: ediff-util.el
===================================================================
RCS file: /pack/xemacscvs/XEmacs/packages/xemacs-packages/ediff/ediff-util.el,v
retrieving revision 1.31
retrieving revision 1.32
diff -u -p -r1.31 -r1.32
--- ediff-util.el 2005/11/15 18:51:35 1.31
+++ ediff-util.el 2006/02/19 03:35:18 1.32
@@ -1,7 +1,7 @@
;;; ediff-util.el --- the core commands and utilities of ediff
;; Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
-;; 2003, 2004, 2005 Free Software Foundation, Inc.
+;; 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
;; Author: Michael Kifer <kifer(a)cs.stonybrook.edu>
@@ -26,7 +26,6 @@
;;; Code:
-(provide 'ediff-util)
;; Compiler pacifier
(defvar ediff-patch-diagnostics)
@@ -49,6 +48,7 @@
(eval-when-compile
(let ((load-path (cons (expand-file-name ".") load-path)))
+ (provide 'ediff-util) ; to break recursive load cycle
(or (featurep 'ediff-init)
(load "ediff-init.el" nil nil 'nosuffix))
(or (featurep 'ediff-help)
@@ -234,6 +234,7 @@ to invocation.")
(define-key ediff-mode-map "#" nil)
(define-key ediff-mode-map "#h" 'ediff-toggle-regexp-match)
(define-key ediff-mode-map "#f" 'ediff-toggle-regexp-match)
+ (define-key ediff-mode-map "#c" 'ediff-toggle-ignore-case)
(or ediff-word-mode
(define-key ediff-mode-map "##" 'ediff-toggle-skip-similar))
(define-key ediff-mode-map "o" nil)
@@ -1133,7 +1134,7 @@ of the current buffer."
;; ))
-(defsubst ediff-file-checked-out-p (file)
+(defun ediff-file-checked-out-p (file)
(or (not (featurep 'vc-hooks))
(and (vc-backend file)
(if (fboundp 'vc-state)
@@ -1143,7 +1144,7 @@ of the current buffer."
(vc-locking-user file))
)))
-(defsubst ediff-file-checked-in-p (file)
+(defun ediff-file-checked-in-p (file)
(and (featurep 'vc-hooks)
;; CVS files are considered not checked in
(not (memq (vc-backend file) '(nil CVS)))
@@ -3079,7 +3080,7 @@ Hit \\[ediff-recenter] to reset the wind
)))
-(defsubst ediff-highlight-diff (n)
+(defun ediff-highlight-diff (n)
"Put face on diff N. Invoked for X displays only."
(ediff-highlight-diff-in-one-buffer n 'A)
(ediff-highlight-diff-in-one-buffer n 'B)
@@ -3088,7 +3089,7 @@ Hit \\[ediff-recenter] to reset the wind
)
-(defsubst ediff-unhighlight-diff ()
+(defun ediff-unhighlight-diff ()
"Remove overlays from buffers A, B, and C."
(ediff-unhighlight-diff-in-one-buffer 'A)
(ediff-unhighlight-diff-in-one-buffer 'B)
@@ -3097,7 +3098,7 @@ Hit \\[ediff-recenter] to reset the wind
)
;; delete highlighting overlays, restore faces to their original form
-(defsubst ediff-unhighlight-diffs-totally ()
+(defun ediff-unhighlight-diffs-totally ()
(ediff-unhighlight-diffs-totally-in-one-buffer 'A)
(ediff-unhighlight-diffs-totally-in-one-buffer 'B)
(ediff-unhighlight-diffs-totally-in-one-buffer 'C)
@@ -3686,7 +3687,7 @@ Ediff Control Panel to restore highlight
(>= (point) end))))))
-(defsubst ediff-get-region-contents (n buf-type ctrl-buf &optional start end)
+(defun ediff-get-region-contents (n buf-type ctrl-buf &optional start end)
(ediff-with-current-buffer
(ediff-with-current-buffer ctrl-buf (ediff-get-buffer buf-type))
(buffer-substring
@@ -3945,6 +3946,7 @@ Ediff Control Panel to restore highlight
(ediff-device-type (ediff-device-type))
varlist salutation buffer-name)
(setq varlist '(ediff-diff-program ediff-diff-options
+ ediff-diff3-program ediff-diff3-options
ediff-patch-program ediff-patch-options
ediff-shell
ediff-use-faces
@@ -4299,6 +4301,8 @@ Mail anyway? (y or n) ")
;;(ediff-load-version-control 'silent)
(run-hooks 'ediff-load-hook)
+
+(provide 'ediff-util)
;;; Local Variables:
1.9 +4 -2 XEmacs/packages/xemacs-packages/ediff/ediff-tbar.el
Index: ediff-tbar.el
===================================================================
RCS file: /pack/xemacscvs/XEmacs/packages/xemacs-packages/ediff/ediff-tbar.el,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -p -r1.8 -r1.9
--- ediff-tbar.el 2002/01/08 04:27:57 1.8
+++ ediff-tbar.el 2006/02/19 03:35:18 1.9
@@ -1,6 +1,7 @@
;;; ediff-tbar.el --- A toolbar for Ediff control buffer
-;; Copyright (C) 1996, 97, 2002 Free Software Foundation, Inc.
+;; Copyright (C) 1996, 97, 2002, 2003, 2004, 2005,
+;; 2006 Free Software Foundation, Inc.
;; Author: Marc Paquette <marcpa(a)cam.org>
@@ -23,7 +24,6 @@
;;; Code:
-(provide 'ediff-tbar)
;; compiler pacifier
(eval-when-compile
@@ -364,6 +364,8 @@ Here's an example:
"Quit this ediff session."]
)))
+
+(provide 'ediff-tbar)
;;; Local Variables:
1.17 +3 -2 XEmacs/packages/xemacs-packages/ediff/ediff-ptch.el
Index: ediff-ptch.el
===================================================================
RCS file: /pack/xemacscvs/XEmacs/packages/xemacs-packages/ediff/ediff-ptch.el,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -p -r1.16 -r1.17
--- ediff-ptch.el 2005/10/06 00:17:44 1.16
+++ ediff-ptch.el 2006/02/19 03:35:18 1.17
@@ -1,7 +1,7 @@
;;; ediff-ptch.el --- Ediff's patch support
;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002,
-;; 2003, 2004, 2005 Free Software Foundation, Inc.
+;; 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
;; Author: Michael Kifer <kifer(a)cs.stonybrook.edu>
@@ -26,7 +26,6 @@
;;; Code:
-(provide 'ediff-ptch)
(defgroup ediff-ptch nil
"Ediff patch support."
@@ -843,6 +842,8 @@ you can still examine the changes via M-
))
+
+(provide 'ediff-ptch)
;;; Local Variables:
1.25 +11 -10 XEmacs/packages/xemacs-packages/ediff/ediff-mult.el
Index: ediff-mult.el
===================================================================
RCS file: /pack/xemacscvs/XEmacs/packages/xemacs-packages/ediff/ediff-mult.el,v
retrieving revision 1.24
retrieving revision 1.25
diff -u -p -r1.24 -r1.25
--- ediff-mult.el 2005/10/06 00:17:44 1.24
+++ ediff-mult.el 2006/02/19 03:35:18 1.25
@@ -1,7 +1,7 @@
;;; ediff-mult.el --- support for multi-file/multi-buffer processing in Ediff
;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
-;; 2003, 2004, 2005 Free Software Foundation, Inc.
+;; 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
;; Author: Michael Kifer <kifer(a)cs.stonybrook.edu>
@@ -104,7 +104,6 @@
;;; Code:
-(provide 'ediff-mult)
(defgroup ediff-mult nil
"Multi-file and multi-buffer processing in Ediff."
@@ -123,7 +122,6 @@
;; end pacifier
(require 'ediff-init)
-(require 'ediff-util)
;; meta-buffer
(ediff-defvar-local ediff-meta-buffer nil "")
@@ -176,7 +174,7 @@ directories.")
(defcustom ediff-default-filtering-regexp nil
"The default regular expression used as a filename filter in multifile comparisons.
-Should be a sexp. For instance (car ediff-filtering-regexp-history) or nil."
+Should be a sexp. For instance (car ediff-filtering-regexp-history) or nil."
:type 'sexp
:group 'ediff-mult)
@@ -219,9 +217,9 @@ This can be toggled with `ediff-toggle-f
(defcustom ediff-before-session-group-setup-hooks nil
"*Hooks to run before Ediff arranges the window for group-level operations.
-It is used by commands such as ediff-directories.
+It is used by commands such as `ediff-directories'.
This hook can be used to save the previous window config, which can be restored
-on ediff-quit, ediff-suspend, or ediff-quit-session-group-hook."
+on `ediff-quit', `ediff-suspend', or `ediff-quit-session-group-hook'."
:type 'hook
:group 'ediff-hook)
(defcustom ediff-after-session-group-setup-hook nil
@@ -242,7 +240,7 @@ ediff-directories, is run."
:type 'hook
:group 'ediff-mult)
(defcustom ediff-meta-buffer-keymap-setup-hook nil
- "*Hooks run just after setting up the ediff-meta-buffer-map.
+ "*Hooks run just after setting up the `ediff-meta-buffer-map'.
This keymap controls key bindings in the meta buffer and is a local variable.
This means that you can set different bindings for different kinds of meta
buffers."
@@ -363,7 +361,7 @@ buffers."
(file-directory-p (ediff-get-session-objC-name session-info)) t)))
;; set up the keymap in the meta buffer
-(defun ediff-setup-meta-map()
+(defun ediff-setup-meta-map ()
(setq ediff-meta-buffer-map (make-sparse-keymap))
(suppress-keymap ediff-meta-buffer-map)
(define-key ediff-meta-buffer-map "q" 'ediff-quit-meta-buffer)
@@ -1473,6 +1471,7 @@ Useful commands:
(ediff-overlay-put overl 'highlight t))
(ediff-overlay-put overl 'ediff-meta-info prop)
(ediff-overlay-put overl 'invisible hidden)
+ (ediff-overlay-put overl 'follow-link t)
(if (numberp session-number)
(ediff-overlay-put overl 'ediff-meta-session-number session-number))))
@@ -2332,8 +2331,8 @@ If this is a session registry buffer the
"Run through the session list and mark identical files.
This is used only for sessions that involve 2 or 3 files at the same time.
ACTION is an optional argument that can be ?h, ?m, ?=, to mark for hiding, mark
-for operation, or simply indicate which are equal files. If it is nil, then
-last-command-char is used to decide which action to take."
+for operation, or simply indicate which are equal files. If it is nil, then
+`last-command-char' is used to decide which action to take."
(interactive)
(if (null action)
(setq action last-command-char))
@@ -2383,6 +2382,8 @@ last-command-char is used to decide whic
))
))
+
+(provide 'ediff-mult)
;;; Local Variables:
1.14 +4 -2 XEmacs/packages/xemacs-packages/ediff/ediff-merg.el
Index: ediff-merg.el
===================================================================
RCS file: /pack/xemacscvs/XEmacs/packages/xemacs-packages/ediff/ediff-merg.el,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -p -r1.13 -r1.14
--- ediff-merg.el 2005/11/04 05:43:37 1.13
+++ ediff-merg.el 2006/02/19 03:35:18 1.14
@@ -1,7 +1,7 @@
;;; ediff-merg.el --- merging utilities
;; Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
-;; 2003, 2004, 2005 Free Software Foundation, Inc.
+;; 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
;; Author: Michael Kifer <kifer(a)cs.stonybrook.edu>
@@ -26,7 +26,6 @@
;;; Code:
-(provide 'ediff-merg)
;; compiler pacifier
(defvar ediff-window-A)
@@ -388,6 +387,9 @@ Combining is done according to the speci
(string= state-of-merge "prefer-B")
(not (string= reg-B reg-C)))
)))
+
+
+(provide 'ediff-merg)
;;; Local Variables:
1.35 +2 -1 XEmacs/packages/xemacs-packages/ediff/ediff-init.el
Index: ediff-init.el
===================================================================
RCS file: /pack/xemacscvs/XEmacs/packages/xemacs-packages/ediff/ediff-init.el,v
retrieving revision 1.34
retrieving revision 1.35
diff -u -p -r1.34 -r1.35
--- ediff-init.el 2005/09/20 17:54:29 1.34
+++ ediff-init.el 2006/02/19 03:35:19 1.35
@@ -1,7 +1,7 @@
;;; ediff-init.el --- Macros, variables, and defsubsts used by Ediff
;; Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
-;; 2003, 2004, 2005 Free Software Foundation, Inc.
+;; 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
;; Author: Michael Kifer <kifer(a)cs.stonybrook.edu>
@@ -1866,6 +1866,7 @@ Unless optional argument INPLACE is non-
(save-current-buffer
(set-buffer ,old-buffer)
(set-syntax-table ,old-table)))))))
+
(provide 'ediff-init)
1.15 +2 -1 XEmacs/packages/xemacs-packages/ediff/ediff-hook.el
Index: ediff-hook.el
===================================================================
RCS file: /pack/xemacscvs/XEmacs/packages/xemacs-packages/ediff/ediff-hook.el,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -p -r1.14 -r1.15
--- ediff-hook.el 2005/09/20 17:54:30 1.14
+++ ediff-hook.el 2006/02/19 03:35:19 1.15
@@ -1,7 +1,7 @@
;;; ediff-hook.el --- setup for Ediff's menus and autoloads
;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003,
-;; 2004, 2005 Free Software Foundation, Inc.
+;; 2004, 2005, 2006 Free Software Foundation, Inc.
;; Author: Michael Kifer <kifer(a)cs.stonybrook.edu>
@@ -370,6 +370,7 @@
(provide 'ediff-hook)
+
;;; arch-tag: 512f8656-8a4b-4789-af5d-5c6144498df3
;;; ediff-hook.el ends here
1.12 +13 -10 XEmacs/packages/xemacs-packages/ediff/ediff-help.el
Index: ediff-help.el
===================================================================
RCS file: /pack/xemacscvs/XEmacs/packages/xemacs-packages/ediff/ediff-help.el,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -p -r1.11 -r1.12
--- ediff-help.el 2005/09/20 17:54:30 1.11
+++ ediff-help.el 2006/02/19 03:35:19 1.12
@@ -1,7 +1,7 @@
;;; ediff-help.el --- Code related to the contents of Ediff help buffers
;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003,
-;; 2004, 2005 Free Software Foundation, Inc.
+;; 2004, 2005, 2006 Free Software Foundation, Inc.
;; Author: Michael Kifer <kifer(a)cs.stonybrook.edu>
@@ -26,7 +26,6 @@
;;; Code:
-(provide 'ediff-help)
;; Compiler pacifier start
(defvar ediff-multiframe)
@@ -61,8 +60,8 @@ For help on a specific command: Click B
p,DEL -previous diff | | -vert/horiz split | xy -copy buf X's region to Y
n,SPC -next diff | h -hilighting | rx -restore buf X's old diff
j -jump to diff | @ -auto-refinement | * -refine current region
- gx -goto X's point| | ! -update diff regions
- C-l -recenter | ## -ignore whitespace |
+ gx -goto X's point| ## -ignore whitespace | ! -update diff regions
+ C-l -recenter | #c -ignore case |
v/V -scroll up/dn | #f/#h -focus/hide regions | wx -save buf X
</> -scroll lt/rt | X -read-only in buf X | wd -save diff output
~ -rotate buffers| m -wide display |
@@ -75,8 +74,8 @@ Normally, not a user option. See `ediff
p,DEL -previous diff | | -vert/horiz split |a/b -copy A/B's region to B/A
n,SPC -next diff | h -hilighting | rx -restore buf X's old diff
j -jump to diff | @ -auto-refinement | * -refine current region
- gx -goto X's point| | ! -update diff regions
- C-l -recenter | ## -ignore whitespace |
+ gx -goto X's point| ## -ignore whitespace | ! -update diff regions
+ C-l -recenter | #c -ignore case |
v/V -scroll up/dn | #f/#h -focus/hide regions | wx -save buf X
</> -scroll lt/rt | X -read-only in buf X | wd -save diff output
~ -swap variants | m -wide display |
@@ -89,8 +88,8 @@ Normally, not a user option. See `ediff
p,DEL -previous diff | | -vert/horiz split |a/b -copy A/B's region to B/A
n,SPC -next diff | h -hilighting | rx -restore buf X's old diff
j -jump to diff | @ -auto-refinement | * -refine current region
- gx -goto X's point| % -narrow/widen buffs | ! -update diff regions
- C-l -recenter | ## -ignore whitespace |
+ gx -goto X's point| ## -ignore whitespace | ! -update diff regions
+ C-l -recenter | #c -ignore case | % -narrow/widen buffs
v/V -scroll up/dn | #f/#h -focus/hide regions | wx -save buf X
</> -scroll lt/rt | X -read-only in buf X | wd -save diff output
~ -swap variants | m -wide display |
@@ -103,8 +102,8 @@ Normally, not a user option. See `ediff
p,DEL -previous diff | | -vert/horiz split | xy -copy buf X's region to Y
n,SPC -next diff | h -hilighting | rx -restore buf X's old diff
j -jump to diff | |
- gx -goto X's point| % -narrow/widen buffs | ! -recompute diffs
- C-l -recenter | |
+ gx -goto X's point| % -narrow/widen buffs | ! -recompute diffs
+ C-l -recenter | #c -ignore case |
v/V -scroll up/dn | #f/#h -focus/hide regions | wx -save buf X
</> -scroll lt/rt | X -read-only in buf X | wd -save diff output
~ -swap variants | m -wide display |
@@ -228,6 +227,7 @@ the value of this variable and the varia
((string= cmd "r") (re-search-forward "^`r'"))
((string= cmd "rx") (re-search-forward "^`ra'"))
((string= cmd "##") (re-search-forward "^`##'"))
+ ((string= cmd "#c") (re-search-forward "^`#c'"))
((string= cmd "#f/#h") (re-search-forward "^`#f'"))
((string= cmd "X") (re-search-forward "^`A'"))
((string= cmd "v/V") (re-search-forward "^`v'"))
@@ -323,6 +323,9 @@ the value of this variable and the varia
(defun ediff-customize ()
(interactive)
(customize-group "ediff"))
+
+
+(provide 'ediff-help)
;;; arch-tag: 05659813-7fcf-4274-964f-d2f577431a9d
1.27 +95 -19 XEmacs/packages/xemacs-packages/ediff/ediff-diff.el
Index: ediff-diff.el
===================================================================
RCS file: /pack/xemacscvs/XEmacs/packages/xemacs-packages/ediff/ediff-diff.el,v
retrieving revision 1.26
retrieving revision 1.27
diff -u -p -r1.26 -r1.27
--- ediff-diff.el 2005/09/20 17:54:30 1.26
+++ ediff-diff.el 2006/02/19 03:35:19 1.27
@@ -1,7 +1,7 @@
;;; ediff-diff.el --- diff-related utilities
;; Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001,
-;; 2002, 2003, 2004, 2005 Free Software Foundation, Inc.
+;; 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
;; Author: Michael Kifer <kifer(a)cs.stonybrook.edu>
@@ -26,7 +26,6 @@
;;; Code:
-(provide 'ediff-diff)
;; compiler pacifier
(defvar ediff-default-variant)
@@ -129,13 +128,33 @@ are `-I REGEXP', to ignore changes whose
(defcustom ediff-diff-options ""
"*Options to pass to `ediff-diff-program'.
-If Unix diff is used as `ediff-diff-program', then the most useful options are
+If Unix diff is used as `ediff-diff-program', then a useful option is
`-w', to ignore space, and `-i', to ignore case of letters.
-At present, the option `-c' is not allowed."
+Options `-c' and `-i' are not allowed. Case sensitivity can be toggled
+interactively using [ediff-toggle-ignore-case]"
:set 'ediff-reset-diff-options
:type 'string
:group 'ediff-diff)
+(ediff-defvar-local ediff-ignore-case nil
+ "*If t, skip over difference regions that differ only in letter case.
+This variable can be set either in .emacs or toggled interactively.
+Use `setq-default' if setting it in .emacs")
+
+(defcustom ediff-ignore-case-option "-i"
+ "*Option that causes the diff program to ignore case of letters."
+:type 'string
+:group 'ediff-diff)
+
+(defcustom ediff-ignore-case-option3 ""
+ "*Option that causes the diff3 program to ignore case of letters.
+GNU diff3 doesn't have such an option."
+:type 'string
+:group 'ediff-diff)
+
+;; the actual options used in comparison
+(ediff-defvar-local ediff-actual-diff-options "" "")
+
(defcustom ediff-custom-diff-program ediff-diff-program
"*Program to use for generating custom diff output for saving it in a file.
This output is not used by Ediff internally."
@@ -155,6 +174,10 @@ This output is not used by Ediff interna
:set 'ediff-reset-diff-options
:type 'string
:group 'ediff-diff)
+
+;; the actual options used in comparison
+(ediff-defvar-local ediff-actual-diff3-options "" "")
+
(defcustom ediff-diff3-ok-lines-regexp
"^\\([1-3]:\\|====\\| \\|.*Warning *:\\|.*No newline\\|.*missing newline\\|^\C-m$\\)"
"*Regexp that matches normal output lines from `ediff-diff3-program'.
@@ -182,7 +205,7 @@ Use `setq-default' if setting it in .ema
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 1400
+(ediff-defvar-local ediff-auto-refine-limit 14000
"*Auto-refine only the regions of this size \(in bytes\) or less.")
;;; General
@@ -227,9 +250,9 @@ one optional arguments, diff-number to r
;; ediff-setup-diff-regions-function, which can also have the value
;; ediff-setup-diff-regions3, which takes 4 arguments.
(defun ediff-setup-diff-regions (file-A file-B file-C)
- ;; looking either for '-c' or a 'c' in a set of clustered non-long options
- (if (string-match "^-c\\| -c\\|-[^- ]+c" ediff-diff-options)
- (error "Option `-c' is not allowed in `ediff-diff-options'"))
+ ;; looking for '-c', '-i', or a 'c', 'i' among clustered non-long options
+ (if (string-match "^-[ci]\\| -[ci]\\|-[^- ]+[ci]" ediff-diff-options)
+ (error "Options `-c' and `-i' are not allowed in `ediff-diff-options'"))
;; create, if it doesn't exist
(or (ediff-buffer-live-p ediff-diff-buffer)
@@ -266,7 +289,7 @@ one optional arguments, diff-number to r
(ediff-exec-process ediff-diff-program
diff-buffer
'synchronize
- ediff-diff-options file1 file2)
+ ediff-actual-diff-options file1 file2)
(message "")
(ediff-with-current-buffer diff-buffer
(buffer-size))))))
@@ -284,7 +307,9 @@ one optional arguments, diff-number to r
(let (diff3-job diff-program diff-options ok-regexp diff-list)
(setq diff3-job ediff-3way-job
diff-program (if diff3-job ediff-diff3-program ediff-diff-program)
- diff-options (if diff3-job ediff-diff3-options ediff-diff-options)
+ diff-options (if diff3-job
+ ediff-actual-diff3-options
+ ediff-actual-diff-options)
ok-regexp (if diff3-job
ediff-diff3-ok-lines-regexp
ediff-diff-ok-lines-regexp))
@@ -366,11 +391,14 @@ one optional arguments, diff-number to r
(B-buffer ediff-buffer-B)
(C-buffer ediff-buffer-C)
(a-prev 1) ; this is needed to set the first diff line correctly
+ (a-prev-pt nil)
(b-prev 1)
+ (b-prev-pt nil)
(c-prev 1)
+ (c-prev-pt nil)
diff-list shift-A shift-B
)
-
+
;; diff list contains word numbers, unless changed later
(setq diff-list (cons (if word-mode 'words 'points)
diff-list))
@@ -382,7 +410,7 @@ one optional arguments, diff-number to r
shift-B
(ediff-overlay-start
(ediff-get-value-according-to-buffer-type 'B bounds))))
-
+
;; reset point in buffers A/B/C
(ediff-with-current-buffer A-buffer
(goto-char (if shift-A shift-A (point-min))))
@@ -466,11 +494,13 @@ one optional arguments, diff-number to r
;; we must disable and then restore longlines-mode
(if (eq longlines-mode-val 1)
(longlines-mode 0))
+ (goto-char (or a-prev-pt shift-A (point-min)))
(forward-line (- a-begin a-prev))
(setq a-begin-pt (point))
(forward-line (- a-end a-begin))
(setq a-end-pt (point)
- a-prev a-end)
+ a-prev a-end
+ a-prev-pt a-end-pt)
(if (eq longlines-mode-val 1)
(longlines-mode longlines-mode-val))
))
@@ -479,11 +509,13 @@ one optional arguments, diff-number to r
(if (and (boundp 'longlines-mode) longlines-mode) 1 0)))
(if (eq longlines-mode-val 1)
(longlines-mode 0))
+ (goto-char (or b-prev-pt shift-B (point-min)))
(forward-line (- b-begin b-prev))
(setq b-begin-pt (point))
(forward-line (- b-end b-begin))
(setq b-end-pt (point)
- b-prev b-end)
+ b-prev b-end
+ b-prev-pt b-end-pt)
(if (eq longlines-mode-val 1)
(longlines-mode longlines-mode-val))
))
@@ -493,11 +525,13 @@ one optional arguments, diff-number to r
(if (and (boundp 'longlines-mode) longlines-mode) 1 0)))
(if (eq longlines-mode-val 1)
(longlines-mode 0))
+ (goto-char (or c-prev-pt (point-min)))
(forward-line (- c-begin c-prev))
(setq c-begin-pt (point))
(forward-line (- c-end c-begin))
(setq c-end-pt (point)
- c-prev c-end)
+ c-prev c-end
+ c-prev-pt c-end-pt)
(if (eq longlines-mode-val 1)
(longlines-mode longlines-mode-val))
)))
@@ -987,8 +1021,11 @@ delimiter regions"))
(C-buffer ediff-buffer-C)
(anc-buffer ediff-ancestor-buffer)
(a-prev 1) ; needed to set the first diff line correctly
+ (a-prev-pt nil)
(b-prev 1)
+ (b-prev-pt nil)
(c-prev 1)
+ (c-prev-pt nil)
(anc-prev 1)
diff-list shift-A shift-B shift-C
)
@@ -1089,11 +1126,13 @@ delimiter regions"))
;; we must disable and then restore longlines-mode
(if (eq longlines-mode-val 1)
(longlines-mode 0))
+ (goto-char (or a-prev-pt shift-A (point-min)))
(forward-line (- a-begin a-prev))
(setq a-begin-pt (point))
(forward-line (- a-end a-begin))
(setq a-end-pt (point)
- a-prev a-end)
+ a-prev a-end
+ a-prev-pt a-end-pt)
(if (eq longlines-mode-val 1)
(longlines-mode longlines-mode-val))
))
@@ -1102,11 +1141,13 @@ delimiter regions"))
(if (and (boundp 'longlines-mode) longlines-mode) 1 0)))
(if (eq longlines-mode-val 1)
(longlines-mode 0))
+ (goto-char (or b-prev-pt shift-B (point-min)))
(forward-line (- b-begin b-prev))
(setq b-begin-pt (point))
(forward-line (- b-end b-begin))
(setq b-end-pt (point)
- b-prev b-end)
+ b-prev b-end
+ b-prev-pt b-end-pt)
(if (eq longlines-mode-val 1)
(longlines-mode longlines-mode-val))
))
@@ -1115,11 +1156,13 @@ delimiter regions"))
(if (and (boundp 'longlines-mode) longlines-mode) 1 0)))
(if (eq longlines-mode-val 1)
(longlines-mode 0))
+ (goto-char (or c-prev-pt shift-C (point-min)))
(forward-line (- c-begin c-prev))
(setq c-begin-pt (point))
(forward-line (- c-end c-begin))
(setq c-end-pt (point)
- c-prev c-end)
+ c-prev c-end
+ c-prev-pt c-end-pt)
(if (eq longlines-mode-val 1)
(longlines-mode longlines-mode-val))
))
@@ -1171,13 +1214,17 @@ delimiter regions"))
;; File-C is either the third file to compare (in case of 3-way comparison)
;; or it is the ancestor file.
(defun ediff-setup-diff-regions3 (file-A file-B file-C)
+ ;; looking for '-i' or a 'i' among clustered non-long options
+ (if (string-match "^-i\\| -i\\|-[^- ]+i" ediff-diff-options)
+ (error "Option `-i' is not allowed in `ediff-diff3-options'"))
+
(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-diff3-program ediff-diff-buffer 'synchronize
- ediff-diff3-options file-A file-B file-C)
+ ediff-actual-diff3-options file-A file-B file-C)
(ediff-prepare-error-list ediff-diff3-ok-lines-regexp ediff-diff-buffer)
;;(message "Computing differences ... done")
@@ -1470,6 +1517,35 @@ affects only files whose names match the
(setq result (cons elt result)))
(setq file-list-list (cdr file-list-list)))
(reverse result)))
+
+;; Ignore case handling - some ideas from drew.adams@(a)oracle.com
+(defun ediff-toggle-ignore-case ()
+ (interactive)
+ (ediff-barf-if-not-control-buffer)
+ (setq ediff-ignore-case (not ediff-ignore-case))
+ (cond (ediff-ignore-case
+ (setq ediff-actual-diff-options
+ (concat ediff-diff-options " " ediff-ignore-case-option)
+ ediff-actual-diff3-options
+ (concat ediff-diff3-options " " ediff-ignore-case-option3))
+ (message "Ignoring regions that differ only in case"))
+ (t
+ (setq ediff-actual-diff-options ediff-diff-options
+ ediff-actual-diff3-options ediff-diff3-options)
+ (message "Ignoring case differences turned OFF")))
+ (cond (ediff-merge-job
+ (message "Ignoring letter case is too dangerous in merge jobs"))
+ ((and ediff-diff3-job (string= ediff-ignore-case-option3 ""))
+ (message "Ignoring letter case is not supported by this diff3 program"))
+ ((and (not ediff-3way-job) (string= ediff-ignore-case-option ""))
+ (message "Ignoring letter case is not supported by this diff program"))
+ (t
+ (sit-for 1)
+ (ediff-update-diffs)))
+ )
+
+
+(provide 'ediff-diff)
;;; Local Variables:
1.100 +35 -0 XEmacs/packages/xemacs-packages/ediff/ChangeLog
Index: ChangeLog
===================================================================
RCS file: /pack/xemacscvs/XEmacs/packages/xemacs-packages/ediff/ChangeLog,v
retrieving revision 1.99
retrieving revision 1.100
diff -u -p -r1.99 -r1.100
--- ChangeLog 2005/12/05 06:18:55 1.99
+++ ChangeLog 2006/02/19 03:35:19 1.100
@@ -1,3 +1,38 @@
+2006-02-19 Michael Kifer <kifer(a)cs.stonybrook.edu>
+
+ * ediff-diff.el (ediff-ignore-case, ediff-ignore-case-option,
+ ediff-ignore-case-option3, ediff-actual-diff-options,
+ ediff-actual-diff3-options): new variables to control case sensitivity.
+ (ediff-make-diff2-buffer, ediff-setup-fine-diff-regions,
+ ediff-setup-diff-regions3): made aware of case-sensitivity.
+ (ediff-toggle-ignore-case): new function.
+ (ediff-extract-diffs, ediff-extract-diffs3): preserve point in buffers.
+
+ * ediff-help.el (ediff-long-help-message-narrow2,
+ ediff-long-help-message-compare2, ediff-long-help-message-compare3,
+ ediff-long-help-message-word-mode): add ignore-case command.
+ (ediff-help-for-quick-help): add ignore-case command.
+
+ * ediff-merg.el: move provide to the end.
+
+ * ediff-ptch.el: move provide to the end.
+
+ * ediff-wind.el: move provide to the end.
+
+ * ediff-mult.el: move provide to the end.
+ (ediff-set-meta-overlay): enable follow-link.
+
+ * ediff.el: move provide to the end.
+ Break recursive load cycle in eval-when-compile.
+ (ediff-patch-buffer): better heuristics.
+
+ * ediff-util.el: move provide to the end.
+ Break recursive load cycle in eval-when-compile.
+ (ediff-setup-keymap): add binding for #c. Replaced some defsubsts with
+ defuns.
+ (ediff-submit-report): pass the values of ediff-diff3-program,
+ ediff-diff3-options.
+
2005-12-05 Norbert Koch <viteno(a)xemacs.org>
* Makefile (VERSION): XEmacs package 1.60 released.