diff options
author | Michael Kifer <kifer@cs.stonybrook.edu> | 2001-03-17 18:59:39 +0000 |
---|---|---|
committer | Michael Kifer <kifer@cs.stonybrook.edu> | 2001-03-17 18:59:39 +0000 |
commit | 4986c2c6c8b786409fb44f740b2e358736145313 (patch) | |
tree | a159e994a7ca65985c2e7b03f56ff0e3472071f6 /lisp/ediff-util.el | |
parent | 42b7180c96b3855e62720491ba55e432ca470356 (diff) | |
download | emacs-4986c2c6c8b786409fb44f740b2e358736145313.tar.gz emacs-4986c2c6c8b786409fb44f740b2e358736145313.tar.bz2 emacs-4986c2c6c8b786409fb44f740b2e358736145313.zip |
2001-03-17 Michael Kifer <kifer@cs.sunysb.edu>
* ediff-util.el: Copyright years.
(ediff-choose-syntax-table): New function.
(ediff-setup): Use ediff-choose-syntax-table.
* ediff-init.el (ediff-with-syntax-table): New macro, uses
with-syntax-table.
* ediff.el: Date of last update, copyright years.
* ediff-wind (ediff-setup-control-frame): Nill->nil.
* viper-ex.el (ex-token-list,ex-cmd-execute): Revamped, courtesy
of Scott Bronson.
(ex-cmd-assoc,ex-cmd-one-letr): New functions.
(viper-check-sub,viper-get-ex-command,viper-execute-ex-command):
Deleted functions.
(viper-get-ex-com-subr,viper-ex,ex-mark): Changed to use the new
ex-token-list.
* viper-util.el: Spaces, indentation.
* viper.el: Changed version, modification time.
Diffstat (limited to 'lisp/ediff-util.el')
-rw-r--r-- | lisp/ediff-util.el | 25 |
1 files changed, 23 insertions, 2 deletions
diff --git a/lisp/ediff-util.el b/lisp/ediff-util.el index dff95ce4cb8..c26162715c7 100644 --- a/lisp/ediff-util.el +++ b/lisp/ediff-util.el @@ -1,6 +1,6 @@ ;;; ediff-util.el --- the core commands and utilities of ediff -;; Copyright (C) 1994, 1995, 1996, 1997, 2001 Free Software Foundation, Inc. +;; Copyright (C) 1994, 95, 96, 97, 98, 99, 2000, 01 Free Software Foundation, Inc. ;; Author: Michael Kifer <kifer@cs.sunysb.edu> @@ -354,6 +354,8 @@ to invocation.") ediff-buffer-B buffer-B ediff-buffer-C buffer-C ediff-control-buffer control-buffer) + + (ediff-choose-syntax-table) (setq ediff-control-buffer-suffix (if (string-match "<[0-9]*>" control-buffer-name) @@ -3692,7 +3694,26 @@ Mail anyway? (y or n) ") (ediff-with-current-buffer ctl-buf (ediff-recenter 'no-rehighlight)))) )) - + + +;; Find an appropriate syntax table for everyone to use +;; If buffer B is not fundamental or text mode, use its syntax table +;; Otherwise, use buffer B's. +;; The syntax mode is used in ediff-forward-word-function +;; The important thing is that every buffer should use the same syntax table +;; during the refinement operation +(defun ediff-choose-syntax-table () + (setq ediff-syntax-table + (ediff-with-current-buffer ediff-buffer-A + (if (not (memq major-mode + '(fundamental-mode text-mode indented-text-mode))) + (syntax-table)))) + (if (not ediff-syntax-table) + (setq ediff-syntax-table + (ediff-with-current-buffer ediff-buffer-B + (syntax-table)))) + ) + (defun ediff-deactivate-mark () (if ediff-xemacs-p |