diff options
| author | Dan Nicolaescu | 2007-11-09 05:20:57 +0000 |
|---|---|---|
| committer | Dan Nicolaescu | 2007-11-09 05:20:57 +0000 |
| commit | e83d1fe87564d06d2fcbb4006dfd9133bc340aa8 (patch) | |
| tree | 2c21707997e91082db05963f343c5bf257c423b2 | |
| parent | 1da7a8c539f30cae62d116903e8fd0ecb0fefbff (diff) | |
| download | emacs-e83d1fe87564d06d2fcbb4006dfd9133bc340aa8.tar.gz emacs-e83d1fe87564d06d2fcbb4006dfd9133bc340aa8.zip | |
* ediff-init.el (ediff-xemacs-p, ediff-emacs-p): Remove.
(ediff-has-face-support-p, ediff-BAD-INFO, ediff-check-version)
(ediff-current-diff-A, ediff-current-diff-B)
(ediff-current-diff-C, ediff-fine-diff-C, ediff-fine-diff-A)
(ediff-fine-diff-B, ediff-fine-diff-Ancestor, ediff-even-diff-A)
(ediff-even-diff-B, ediff-even-diff-C, ediff-even-diff-Ancestor)
(ediff-odd-diff-A, ediff-odd-diff-B, ediff-odd-diff-C)
(ediff-odd-diff-Ancestor, ediff-reset-mouse):
* ediff-wind.el (ediff-narrow-control-frame-leftward-shift)
(ediff-setup-windows-plain-merge)
(ediff-setup-windows-plain-compare, ediff-setup-control-frame)
(ediff-refresh-control-frame, ediff-get-visible-buffer-window):
* ediff-util.el (ediff-setup-keymap, )
(ediff-toggle-wide-display, ediff-toggle-multiframe)
(ediff-toggle-use-toolbar, ediff-really-quit)
(ediff-good-frame-under-mouse)
(ediff-highlight-diff-in-one-buffer)
(ediff-remove-flags-from-buffer, ediff-place-flags-in-buffer1)
(ediff-make-bullet-proof-overlay):
* ediff-mult.el (ediff-setup-meta-map, ediff-emacs-p)
(ediff-set-meta-overlay):
* ediff-help.el (ediff-help-region-map, ediff-set-help-overlays):
* ediff.el (ediff-documentation): Replace ediff-xemacs-p and
ediff-emacs-p with their former definitions.
* emulation/viper-init.el (viper-xemacs-p, viper-emacs-p): Remove.
(viper-has-face-support-p, viper-inactivate-input-method)
(viper-activate-input-method)
(viper-use-replace-region-delimiters, viper-restore-cursor-type):
* emulation/viper-mous.el (viper-multiclick-timeout)
(viper-surrounding-word, viper-mouse-click-insert-word)
(viper-mouse-click-search-word, viper-parse-mouse-key):
* emulation/viper-macs.el (viper-char-array-to-macro):
* emulation/viper.el (viper-go-away, viper-set-hooks)
(viper-non-hook-settings):
* emulation/viper-util.el (viper-get-saved-cursor-color-in-replace-mode)
(viper-get-saved-cursor-color-in-insert-mode)
(viper-get-saved-cursor-color-in-emacs-mode)
(viper-check-version, viper-get-visible-buffer-window)
(viper-file-checked-in-p, viper-set-replace-overlay)
(viper-set-replace-overlay-glyphs, viper-set-minibuffer-overlay)
(viper-check-minibuffer-overlay, viper-read-key-sequence)
(viper-key-to-emacs-key): Replace viper-xemacs-p and viper-emacs-p
with their former definitions.
(viper-eventify-list-xemacs): Only do work for XEmacs.
(viper-set-unread-command-events): Only do work for Emacs.
(viper-overlay-p, viper-make-overlay, viper-overlay-live-p)
(viper-move-overlay, viper-overlay-start, viper-overlay-end)
(viper-overlay-get, viper-overlay-put, viper-read-event)
(viper-characterp, viper-int-to-char, viper-get-face)
(viper-color-defined-p, viper-iconify): New defaliases replacing
the old fsets.
* progmodes/fortran.el (comment-region-function)
(uncomment-region-function): Pacify byte compiler.
* vc.el (vc-diff-internal): Remove code for an old version of
gnus.
| -rw-r--r-- | lisp/ChangeLog | 61 | ||||
| -rw-r--r-- | lisp/ediff-help.el | 4 | ||||
| -rw-r--r-- | lisp/ediff-init.el | 57 | ||||
| -rw-r--r-- | lisp/ediff-mult.el | 6 | ||||
| -rw-r--r-- | lisp/ediff-util.el | 37 | ||||
| -rw-r--r-- | lisp/ediff-wind.el | 17 | ||||
| -rw-r--r-- | lisp/ediff.el | 2 | ||||
| -rw-r--r-- | lisp/emulation/viper-cmd.el | 22 | ||||
| -rw-r--r-- | lisp/emulation/viper-ex.el | 8 | ||||
| -rw-r--r-- | lisp/emulation/viper-init.el | 20 | ||||
| -rw-r--r-- | lisp/emulation/viper-macs.el | 2 | ||||
| -rw-r--r-- | lisp/emulation/viper-mous.el | 28 | ||||
| -rw-r--r-- | lisp/emulation/viper-util.el | 126 | ||||
| -rw-r--r-- | lisp/emulation/viper.el | 26 | ||||
| -rw-r--r-- | lisp/progmodes/fortran.el | 3 | ||||
| -rw-r--r-- | lisp/vc.el | 4 |
16 files changed, 230 insertions, 193 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index d61d09008fb..bac3ee7a691 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,3 +1,64 @@ | |||
| 1 | 2007-11-09 Dan Nicolaescu <dann@ics.uci.edu> | ||
| 2 | |||
| 3 | * ediff-init.el (ediff-xemacs-p, ediff-emacs-p): Remove. | ||
| 4 | (ediff-has-face-support-p, ediff-BAD-INFO, ediff-check-version) | ||
| 5 | (ediff-current-diff-A, ediff-current-diff-B) | ||
| 6 | (ediff-current-diff-C, ediff-fine-diff-C, ediff-fine-diff-A) | ||
| 7 | (ediff-fine-diff-B, ediff-fine-diff-Ancestor, ediff-even-diff-A) | ||
| 8 | (ediff-even-diff-B, ediff-even-diff-C, ediff-even-diff-Ancestor) | ||
| 9 | (ediff-odd-diff-A, ediff-odd-diff-B, ediff-odd-diff-C) | ||
| 10 | (ediff-odd-diff-Ancestor, ediff-reset-mouse): | ||
| 11 | * ediff-wind.el (ediff-narrow-control-frame-leftward-shift) | ||
| 12 | (ediff-setup-windows-plain-merge) | ||
| 13 | (ediff-setup-windows-plain-compare, ediff-setup-control-frame) | ||
| 14 | (ediff-refresh-control-frame, ediff-get-visible-buffer-window): | ||
| 15 | * ediff-util.el (ediff-setup-keymap, ) | ||
| 16 | (ediff-toggle-wide-display, ediff-toggle-multiframe) | ||
| 17 | (ediff-toggle-use-toolbar, ediff-really-quit) | ||
| 18 | (ediff-good-frame-under-mouse) | ||
| 19 | (ediff-highlight-diff-in-one-buffer) | ||
| 20 | (ediff-remove-flags-from-buffer, ediff-place-flags-in-buffer1) | ||
| 21 | (ediff-make-bullet-proof-overlay): | ||
| 22 | * ediff-mult.el (ediff-setup-meta-map, ediff-emacs-p) | ||
| 23 | (ediff-set-meta-overlay): | ||
| 24 | * ediff-help.el (ediff-help-region-map, ediff-set-help-overlays): | ||
| 25 | * ediff.el (ediff-documentation): Replace ediff-xemacs-p and | ||
| 26 | ediff-emacs-p with their former definitions. | ||
| 27 | |||
| 28 | * emulation/viper-init.el (viper-xemacs-p, viper-emacs-p): Remove. | ||
| 29 | (viper-has-face-support-p, viper-inactivate-input-method) | ||
| 30 | (viper-activate-input-method) | ||
| 31 | (viper-use-replace-region-delimiters, viper-restore-cursor-type): | ||
| 32 | * emulation/viper-mous.el (viper-multiclick-timeout) | ||
| 33 | (viper-surrounding-word, viper-mouse-click-insert-word) | ||
| 34 | (viper-mouse-click-search-word, viper-parse-mouse-key): | ||
| 35 | * emulation/viper-macs.el (viper-char-array-to-macro): | ||
| 36 | * emulation/viper.el (viper-go-away, viper-set-hooks) | ||
| 37 | (viper-non-hook-settings): | ||
| 38 | * emulation/viper-util.el (viper-get-saved-cursor-color-in-replace-mode) | ||
| 39 | (viper-get-saved-cursor-color-in-insert-mode) | ||
| 40 | (viper-get-saved-cursor-color-in-emacs-mode) | ||
| 41 | (viper-check-version, viper-get-visible-buffer-window) | ||
| 42 | (viper-file-checked-in-p, viper-set-replace-overlay) | ||
| 43 | (viper-set-replace-overlay-glyphs, viper-set-minibuffer-overlay) | ||
| 44 | (viper-check-minibuffer-overlay, viper-read-key-sequence) | ||
| 45 | (viper-key-to-emacs-key): Replace viper-xemacs-p and viper-emacs-p | ||
| 46 | with their former definitions. | ||
| 47 | (viper-eventify-list-xemacs): Only do work for XEmacs. | ||
| 48 | (viper-set-unread-command-events): Only do work for Emacs. | ||
| 49 | (viper-overlay-p, viper-make-overlay, viper-overlay-live-p) | ||
| 50 | (viper-move-overlay, viper-overlay-start, viper-overlay-end) | ||
| 51 | (viper-overlay-get, viper-overlay-put, viper-read-event) | ||
| 52 | (viper-characterp, viper-int-to-char, viper-get-face) | ||
| 53 | (viper-color-defined-p, viper-iconify): New defaliases replacing | ||
| 54 | the old fsets. | ||
| 55 | |||
| 56 | * progmodes/fortran.el (comment-region-function) | ||
| 57 | (uncomment-region-function): Pacify byte compiler. | ||
| 58 | |||
| 59 | * vc.el (vc-diff-internal): Remove code for an old version of | ||
| 60 | gnus. | ||
| 61 | |||
| 1 | 2007-11-08 Michael Albinus <michael.albinus@gmx.de> | 62 | 2007-11-08 Michael Albinus <michael.albinus@gmx.de> |
| 2 | 63 | ||
| 3 | * net/tramp.el (tramp-maybe-open-connection): Use a local copy of | 64 | * net/tramp.el (tramp-maybe-open-connection): Use a local copy of |
diff --git a/lisp/ediff-help.el b/lisp/ediff-help.el index 1c7a72870fe..0c37be31372 100644 --- a/lisp/ediff-help.el +++ b/lisp/ediff-help.el | |||
| @@ -165,7 +165,7 @@ the value of this variable and the variables `ediff-help-message-*' in | |||
| 165 | 165 | ||
| 166 | (define-key | 166 | (define-key |
| 167 | ediff-help-region-map | 167 | ediff-help-region-map |
| 168 | (if ediff-emacs-p [mouse-2] [button2]) | 168 | (if (featurep 'emacs) [mouse-2] [button2]) |
| 169 | 'ediff-help-for-quick-help) | 169 | 'ediff-help-for-quick-help) |
| 170 | 170 | ||
| 171 | ;; runs in the control buffer | 171 | ;; runs in the control buffer |
| @@ -177,7 +177,7 @@ the value of this variable and the variables `ediff-help-message-*' in | |||
| 177 | end (match-end 0) | 177 | end (match-end 0) |
| 178 | cmd (buffer-substring (match-beginning 1) (match-end 1))) | 178 | cmd (buffer-substring (match-beginning 1) (match-end 1))) |
| 179 | (setq overl (ediff-make-overlay beg end)) | 179 | (setq overl (ediff-make-overlay beg end)) |
| 180 | (if ediff-emacs-p | 180 | (if (featurep 'emacs) |
| 181 | (ediff-overlay-put overl 'mouse-face 'highlight) | 181 | (ediff-overlay-put overl 'mouse-face 'highlight) |
| 182 | (ediff-overlay-put overl 'highlight t)) | 182 | (ediff-overlay-put overl 'highlight t)) |
| 183 | (ediff-overlay-put overl 'ediff-help-info cmd)))) | 183 | (ediff-overlay-put overl 'ediff-help-info cmd)))) |
diff --git a/lisp/ediff-init.el b/lisp/ediff-init.el index 21e6bf660ee..dd69b52b022 100644 --- a/lisp/ediff-init.el +++ b/lisp/ediff-init.el | |||
| @@ -43,11 +43,6 @@ | |||
| 43 | (load "ange-ftp" 'noerror))) | 43 | (load "ange-ftp" 'noerror))) |
| 44 | ;; end pacifier | 44 | ;; end pacifier |
| 45 | 45 | ||
| 46 | ;; Is it XEmacs? | ||
| 47 | (defconst ediff-xemacs-p (featurep 'xemacs)) | ||
| 48 | ;; Is it Emacs? | ||
| 49 | (defconst ediff-emacs-p (not ediff-xemacs-p)) | ||
| 50 | |||
| 51 | ;; This is used to avoid compilation warnings. When emacs/xemacs forms can | 46 | ;; This is used to avoid compilation warnings. When emacs/xemacs forms can |
| 52 | ;; generate compile time warnings, we use this macro. | 47 | ;; generate compile time warnings, we use this macro. |
| 53 | ;; In this case, the macro will expand into the form that is appropriate to the | 48 | ;; In this case, the macro will expand into the form that is appropriate to the |
| @@ -78,8 +73,8 @@ that Ediff doesn't know about.") | |||
| 78 | (cond ((ediff-window-display-p)) | 73 | (cond ((ediff-window-display-p)) |
| 79 | (ediff-force-faces) | 74 | (ediff-force-faces) |
| 80 | ((ediff-color-display-p)) | 75 | ((ediff-color-display-p)) |
| 81 | (ediff-emacs-p (memq (ediff-device-type) '(pc))) | 76 | ((featurep 'emacs) (memq (ediff-device-type) '(pc))) |
| 82 | (ediff-xemacs-p (memq (ediff-device-type) '(tty pc))) | 77 | ((featurep 'xemacs) (memq (ediff-device-type) '(tty pc))) |
| 83 | )) | 78 | )) |
| 84 | 79 | ||
| 85 | ;; toolbar support for emacs hasn't been implemented in ediff | 80 | ;; toolbar support for emacs hasn't been implemented in ediff |
| @@ -506,7 +501,7 @@ set local variables that determine how the display looks like." | |||
| 506 | *** of %sEmacs, does not seem to be properly installed. | 501 | *** of %sEmacs, does not seem to be properly installed. |
| 507 | *** | 502 | *** |
| 508 | *** Please contact your system administrator. " | 503 | *** Please contact your system administrator. " |
| 509 | (if ediff-xemacs-p "X" ""))) | 504 | (if (featurep 'xemacs) "X" ""))) |
| 510 | 505 | ||
| 511 | ;; Selective browsing | 506 | ;; Selective browsing |
| 512 | 507 | ||
| @@ -785,8 +780,8 @@ to temp files when Ediff needs to find fine differences." | |||
| 785 | ;; testing for sufficiently high Emacs versions. | 780 | ;; testing for sufficiently high Emacs versions. |
| 786 | (defun ediff-check-version (op major minor &optional type-of-emacs) | 781 | (defun ediff-check-version (op major minor &optional type-of-emacs) |
| 787 | (if (and (boundp 'emacs-major-version) (boundp 'emacs-minor-version)) | 782 | (if (and (boundp 'emacs-major-version) (boundp 'emacs-minor-version)) |
| 788 | (and (cond ((eq type-of-emacs 'xemacs) ediff-xemacs-p) | 783 | (and (cond ((eq type-of-emacs 'xemacs) (featurep 'xemacs)) |
| 789 | ((eq type-of-emacs 'emacs) ediff-emacs-p) | 784 | ((eq type-of-emacs 'emacs) (featurep 'emacs)) |
| 790 | (t t)) | 785 | (t t)) |
| 791 | (cond ((eq op '=) (and (= emacs-minor-version minor) | 786 | (cond ((eq op '=) (and (= emacs-minor-version minor) |
| 792 | (= emacs-major-version major))) | 787 | (= emacs-major-version major))) |
| @@ -908,7 +903,7 @@ to temp files when Ediff needs to find fine differences." | |||
| 908 | 903 | ||
| 909 | 904 | ||
| 910 | (defface ediff-current-diff-A | 905 | (defface ediff-current-diff-A |
| 911 | (if ediff-emacs-p | 906 | (if (featurep 'emacs) |
| 912 | '((((class color) (min-colors 16)) | 907 | '((((class color) (min-colors 16)) |
| 913 | (:foreground "firebrick" :background "pale green")) | 908 | (:foreground "firebrick" :background "pale green")) |
| 914 | (((class color)) | 909 | (((class color)) |
| @@ -929,7 +924,7 @@ this variable represents.") | |||
| 929 | (ediff-hide-face ediff-current-diff-face-A) | 924 | (ediff-hide-face ediff-current-diff-face-A) |
| 930 | ;; Until custom.el for XEmacs starts supporting :inverse-video we do this. | 925 | ;; Until custom.el for XEmacs starts supporting :inverse-video we do this. |
| 931 | ;; This means that some user customization may be trashed. | 926 | ;; This means that some user customization may be trashed. |
| 932 | (if (and ediff-xemacs-p | 927 | (if (and (featurep 'xemacs) |
| 933 | (ediff-has-face-support-p) | 928 | (ediff-has-face-support-p) |
| 934 | (not (ediff-color-display-p))) | 929 | (not (ediff-color-display-p))) |
| 935 | (copy-face 'modeline ediff-current-diff-face-A)) | 930 | (copy-face 'modeline ediff-current-diff-face-A)) |
| @@ -937,7 +932,7 @@ this variable represents.") | |||
| 937 | 932 | ||
| 938 | 933 | ||
| 939 | (defface ediff-current-diff-B | 934 | (defface ediff-current-diff-B |
| 940 | (if ediff-emacs-p | 935 | (if (featurep 'emacs) |
| 941 | '((((class color) (min-colors 16)) | 936 | '((((class color) (min-colors 16)) |
| 942 | (:foreground "DarkOrchid" :background "Yellow")) | 937 | (:foreground "DarkOrchid" :background "Yellow")) |
| 943 | (((class color)) | 938 | (((class color)) |
| @@ -960,14 +955,14 @@ this variable represents.") | |||
| 960 | (ediff-hide-face ediff-current-diff-face-B) | 955 | (ediff-hide-face ediff-current-diff-face-B) |
| 961 | ;; Until custom.el for XEmacs starts supporting :inverse-video we do this. | 956 | ;; Until custom.el for XEmacs starts supporting :inverse-video we do this. |
| 962 | ;; This means that some user customization may be trashed. | 957 | ;; This means that some user customization may be trashed. |
| 963 | (if (and ediff-xemacs-p | 958 | (if (and (featurep 'xemacs) |
| 964 | (ediff-has-face-support-p) | 959 | (ediff-has-face-support-p) |
| 965 | (not (ediff-color-display-p))) | 960 | (not (ediff-color-display-p))) |
| 966 | (copy-face 'modeline ediff-current-diff-face-B)) | 961 | (copy-face 'modeline ediff-current-diff-face-B)) |
| 967 | 962 | ||
| 968 | 963 | ||
| 969 | (defface ediff-current-diff-C | 964 | (defface ediff-current-diff-C |
| 970 | (if ediff-emacs-p | 965 | (if (featurep 'emacs) |
| 971 | '((((class color) (min-colors 16)) | 966 | '((((class color) (min-colors 16)) |
| 972 | (:foreground "Navy" :background "Pink")) | 967 | (:foreground "Navy" :background "Pink")) |
| 973 | (((class color)) | 968 | (((class color)) |
| @@ -988,14 +983,14 @@ this variable represents.") | |||
| 988 | (ediff-hide-face ediff-current-diff-face-C) | 983 | (ediff-hide-face ediff-current-diff-face-C) |
| 989 | ;; Until custom.el for XEmacs starts supporting :inverse-video we do this. | 984 | ;; Until custom.el for XEmacs starts supporting :inverse-video we do this. |
| 990 | ;; This means that some user customization may be trashed. | 985 | ;; This means that some user customization may be trashed. |
| 991 | (if (and ediff-xemacs-p | 986 | (if (and (featurep 'xemacs) |
| 992 | (ediff-has-face-support-p) | 987 | (ediff-has-face-support-p) |
| 993 | (not (ediff-color-display-p))) | 988 | (not (ediff-color-display-p))) |
| 994 | (copy-face 'modeline ediff-current-diff-face-C)) | 989 | (copy-face 'modeline ediff-current-diff-face-C)) |
| 995 | 990 | ||
| 996 | 991 | ||
| 997 | (defface ediff-current-diff-Ancestor | 992 | (defface ediff-current-diff-Ancestor |
| 998 | (if ediff-emacs-p | 993 | (if (featurep 'emacs) |
| 999 | '((((class color) (min-colors 16)) | 994 | '((((class color) (min-colors 16)) |
| 1000 | (:foreground "Black" :background "VioletRed")) | 995 | (:foreground "Black" :background "VioletRed")) |
| 1001 | (((class color)) | 996 | (((class color)) |
| @@ -1016,14 +1011,14 @@ this variable represents.") | |||
| 1016 | (ediff-hide-face ediff-current-diff-face-Ancestor) | 1011 | (ediff-hide-face ediff-current-diff-face-Ancestor) |
| 1017 | ;; Until custom.el for XEmacs starts supporting :inverse-video we do this. | 1012 | ;; Until custom.el for XEmacs starts supporting :inverse-video we do this. |
| 1018 | ;; This means that some user customization may be trashed. | 1013 | ;; This means that some user customization may be trashed. |
| 1019 | (if (and ediff-xemacs-p | 1014 | (if (and (featurep 'xemacs) |
| 1020 | (ediff-has-face-support-p) | 1015 | (ediff-has-face-support-p) |
| 1021 | (not (ediff-color-display-p))) | 1016 | (not (ediff-color-display-p))) |
| 1022 | (copy-face 'modeline ediff-current-diff-face-Ancestor)) | 1017 | (copy-face 'modeline ediff-current-diff-face-Ancestor)) |
| 1023 | 1018 | ||
| 1024 | 1019 | ||
| 1025 | (defface ediff-fine-diff-A | 1020 | (defface ediff-fine-diff-A |
| 1026 | (if ediff-emacs-p | 1021 | (if (featurep 'emacs) |
| 1027 | '((((class color) (min-colors 16)) | 1022 | '((((class color) (min-colors 16)) |
| 1028 | (:foreground "Navy" :background "sky blue")) | 1023 | (:foreground "Navy" :background "sky blue")) |
| 1029 | (((class color)) | 1024 | (((class color)) |
| @@ -1044,7 +1039,7 @@ this variable represents.") | |||
| 1044 | (ediff-hide-face ediff-fine-diff-face-A) | 1039 | (ediff-hide-face ediff-fine-diff-face-A) |
| 1045 | 1040 | ||
| 1046 | (defface ediff-fine-diff-B | 1041 | (defface ediff-fine-diff-B |
| 1047 | (if ediff-emacs-p | 1042 | (if (featurep 'emacs) |
| 1048 | '((((class color) (min-colors 16)) | 1043 | '((((class color) (min-colors 16)) |
| 1049 | (:foreground "Black" :background "cyan")) | 1044 | (:foreground "Black" :background "cyan")) |
| 1050 | (((class color)) | 1045 | (((class color)) |
| @@ -1065,7 +1060,7 @@ this variable represents.") | |||
| 1065 | (ediff-hide-face ediff-fine-diff-face-B) | 1060 | (ediff-hide-face ediff-fine-diff-face-B) |
| 1066 | 1061 | ||
| 1067 | (defface ediff-fine-diff-C | 1062 | (defface ediff-fine-diff-C |
| 1068 | (if ediff-emacs-p | 1063 | (if (featurep 'emacs) |
| 1069 | '((((type pc)) | 1064 | '((((type pc)) |
| 1070 | (:foreground "white" :background "Turquoise")) | 1065 | (:foreground "white" :background "Turquoise")) |
| 1071 | (((class color) (min-colors 16)) | 1066 | (((class color) (min-colors 16)) |
| @@ -1091,7 +1086,7 @@ this variable represents.") | |||
| 1091 | (ediff-hide-face ediff-fine-diff-face-C) | 1086 | (ediff-hide-face ediff-fine-diff-face-C) |
| 1092 | 1087 | ||
| 1093 | (defface ediff-fine-diff-Ancestor | 1088 | (defface ediff-fine-diff-Ancestor |
| 1094 | (if ediff-emacs-p | 1089 | (if (featurep 'emacs) |
| 1095 | '((((class color) (min-colors 16)) | 1090 | '((((class color) (min-colors 16)) |
| 1096 | (:foreground "Black" :background "Green")) | 1091 | (:foreground "Black" :background "Green")) |
| 1097 | (((class color)) | 1092 | (((class color)) |
| @@ -1123,7 +1118,7 @@ this variable represents.") | |||
| 1123 | (t "Stipple"))) | 1118 | (t "Stipple"))) |
| 1124 | 1119 | ||
| 1125 | (defface ediff-even-diff-A | 1120 | (defface ediff-even-diff-A |
| 1126 | (if ediff-emacs-p | 1121 | (if (featurep 'emacs) |
| 1127 | `((((type pc)) | 1122 | `((((type pc)) |
| 1128 | (:foreground "green3" :background "light grey")) | 1123 | (:foreground "green3" :background "light grey")) |
| 1129 | (((class color) (min-colors 16)) | 1124 | (((class color) (min-colors 16)) |
| @@ -1149,7 +1144,7 @@ this variable represents.") | |||
| 1149 | (ediff-hide-face ediff-even-diff-face-A) | 1144 | (ediff-hide-face ediff-even-diff-face-A) |
| 1150 | 1145 | ||
| 1151 | (defface ediff-even-diff-B | 1146 | (defface ediff-even-diff-B |
| 1152 | (if ediff-emacs-p | 1147 | (if (featurep 'emacs) |
| 1153 | `((((class color) (min-colors 16)) | 1148 | `((((class color) (min-colors 16)) |
| 1154 | (:foreground "White" :background "Grey")) | 1149 | (:foreground "White" :background "Grey")) |
| 1155 | (((class color)) | 1150 | (((class color)) |
| @@ -1170,7 +1165,7 @@ this variable represents.") | |||
| 1170 | (ediff-hide-face ediff-even-diff-face-B) | 1165 | (ediff-hide-face ediff-even-diff-face-B) |
| 1171 | 1166 | ||
| 1172 | (defface ediff-even-diff-C | 1167 | (defface ediff-even-diff-C |
| 1173 | (if ediff-emacs-p | 1168 | (if (featurep 'emacs) |
| 1174 | `((((type pc)) | 1169 | `((((type pc)) |
| 1175 | (:foreground "yellow3" :background "light grey")) | 1170 | (:foreground "yellow3" :background "light grey")) |
| 1176 | (((class color) (min-colors 16)) | 1171 | (((class color) (min-colors 16)) |
| @@ -1196,7 +1191,7 @@ this variable represents.") | |||
| 1196 | (ediff-hide-face ediff-even-diff-face-C) | 1191 | (ediff-hide-face ediff-even-diff-face-C) |
| 1197 | 1192 | ||
| 1198 | (defface ediff-even-diff-Ancestor | 1193 | (defface ediff-even-diff-Ancestor |
| 1199 | (if ediff-emacs-p | 1194 | (if (featurep 'emacs) |
| 1200 | `((((type pc)) | 1195 | `((((type pc)) |
| 1201 | (:foreground "cyan3" :background "light grey")) | 1196 | (:foreground "cyan3" :background "light grey")) |
| 1202 | (((class color) (min-colors 16)) | 1197 | (((class color) (min-colors 16)) |
| @@ -1229,7 +1224,7 @@ this variable represents.") | |||
| 1229 | (Ancestor . ediff-even-diff-Ancestor))) | 1224 | (Ancestor . ediff-even-diff-Ancestor))) |
| 1230 | 1225 | ||
| 1231 | (defface ediff-odd-diff-A | 1226 | (defface ediff-odd-diff-A |
| 1232 | (if ediff-emacs-p | 1227 | (if (featurep 'emacs) |
| 1233 | '((((type pc)) | 1228 | '((((type pc)) |
| 1234 | (:foreground "green3" :background "gray40")) | 1229 | (:foreground "green3" :background "gray40")) |
| 1235 | (((class color) (min-colors 16)) | 1230 | (((class color) (min-colors 16)) |
| @@ -1254,7 +1249,7 @@ this variable represents.") | |||
| 1254 | 1249 | ||
| 1255 | 1250 | ||
| 1256 | (defface ediff-odd-diff-B | 1251 | (defface ediff-odd-diff-B |
| 1257 | (if ediff-emacs-p | 1252 | (if (featurep 'emacs) |
| 1258 | '((((type pc)) | 1253 | '((((type pc)) |
| 1259 | (:foreground "White" :background "gray40")) | 1254 | (:foreground "White" :background "gray40")) |
| 1260 | (((class color) (min-colors 16)) | 1255 | (((class color) (min-colors 16)) |
| @@ -1278,7 +1273,7 @@ this variable represents.") | |||
| 1278 | (ediff-hide-face ediff-odd-diff-face-B) | 1273 | (ediff-hide-face ediff-odd-diff-face-B) |
| 1279 | 1274 | ||
| 1280 | (defface ediff-odd-diff-C | 1275 | (defface ediff-odd-diff-C |
| 1281 | (if ediff-emacs-p | 1276 | (if (featurep 'emacs) |
| 1282 | '((((type pc)) | 1277 | '((((type pc)) |
| 1283 | (:foreground "yellow3" :background "gray40")) | 1278 | (:foreground "yellow3" :background "gray40")) |
| 1284 | (((class color) (min-colors 16)) | 1279 | (((class color) (min-colors 16)) |
| @@ -1302,7 +1297,7 @@ this variable represents.") | |||
| 1302 | (ediff-hide-face ediff-odd-diff-face-C) | 1297 | (ediff-hide-face ediff-odd-diff-face-C) |
| 1303 | 1298 | ||
| 1304 | (defface ediff-odd-diff-Ancestor | 1299 | (defface ediff-odd-diff-Ancestor |
| 1305 | (if ediff-emacs-p | 1300 | (if (featurep 'emacs) |
| 1306 | '((((class color) (min-colors 16)) | 1301 | '((((class color) (min-colors 16)) |
| 1307 | (:foreground "cyan3" :background "gray40")) | 1302 | (:foreground "cyan3" :background "gray40")) |
| 1308 | (((class color)) | 1303 | (((class color)) |
| @@ -1630,7 +1625,7 @@ This default should work without changes." | |||
| 1630 | (or frame (setq frame (selected-frame))) | 1625 | (or frame (setq frame (selected-frame))) |
| 1631 | (if (ediff-window-display-p) | 1626 | (if (ediff-window-display-p) |
| 1632 | (let ((frame-or-wind frame)) | 1627 | (let ((frame-or-wind frame)) |
| 1633 | (if ediff-xemacs-p | 1628 | (if (featurep 'xemacs) |
| 1634 | (setq frame-or-wind (frame-selected-window frame))) | 1629 | (setq frame-or-wind (frame-selected-window frame))) |
| 1635 | (or do-not-grab-mouse | 1630 | (or do-not-grab-mouse |
| 1636 | ;; don't set mouse if the user said to never do this | 1631 | ;; don't set mouse if the user said to never do this |
diff --git a/lisp/ediff-mult.el b/lisp/ediff-mult.el index 3696d8ae776..51502615cf7 100644 --- a/lisp/ediff-mult.el +++ b/lisp/ediff-mult.el | |||
| @@ -404,7 +404,7 @@ Toggled by ediff-toggle-verbose-help-meta-buffer" ) | |||
| 404 | (define-key ediff-meta-buffer-map "=h" 'ediff-meta-mark-equal-files))) | 404 | (define-key ediff-meta-buffer-map "=h" 'ediff-meta-mark-equal-files))) |
| 405 | (if ediff-no-emacs-help-in-control-buffer | 405 | (if ediff-no-emacs-help-in-control-buffer |
| 406 | (define-key ediff-meta-buffer-map "\C-h" 'ediff-previous-meta-item)) | 406 | (define-key ediff-meta-buffer-map "\C-h" 'ediff-previous-meta-item)) |
| 407 | (if ediff-emacs-p | 407 | (if (featurep 'emacs) |
| 408 | (define-key ediff-meta-buffer-map [mouse-2] ediff-meta-action-function) | 408 | (define-key ediff-meta-buffer-map [mouse-2] ediff-meta-action-function) |
| 409 | (define-key ediff-meta-buffer-map [button2] ediff-meta-action-function)) | 409 | (define-key ediff-meta-buffer-map [button2] ediff-meta-action-function)) |
| 410 | 410 | ||
| @@ -448,7 +448,7 @@ Commands: | |||
| 448 | (define-key ediff-dir-diffs-buffer-map "\C-?" 'previous-line) | 448 | (define-key ediff-dir-diffs-buffer-map "\C-?" 'previous-line) |
| 449 | (define-key ediff-dir-diffs-buffer-map "p" 'previous-line) | 449 | (define-key ediff-dir-diffs-buffer-map "p" 'previous-line) |
| 450 | (define-key ediff-dir-diffs-buffer-map "C" 'ediff-dir-diff-copy-file) | 450 | (define-key ediff-dir-diffs-buffer-map "C" 'ediff-dir-diff-copy-file) |
| 451 | (if ediff-emacs-p | 451 | (if (featurep 'emacs) |
| 452 | (define-key ediff-dir-diffs-buffer-map [mouse-2] 'ediff-dir-diff-copy-file) | 452 | (define-key ediff-dir-diffs-buffer-map [mouse-2] 'ediff-dir-diff-copy-file) |
| 453 | (define-key ediff-dir-diffs-buffer-map [button2] 'ediff-dir-diff-copy-file)) | 453 | (define-key ediff-dir-diffs-buffer-map [button2] 'ediff-dir-diff-copy-file)) |
| 454 | (define-key ediff-dir-diffs-buffer-map [delete] 'previous-line) | 454 | (define-key ediff-dir-diffs-buffer-map [delete] 'previous-line) |
| @@ -1493,7 +1493,7 @@ Useful commands: | |||
| 1493 | (defun ediff-set-meta-overlay (b e prop &optional session-number hidden) | 1493 | (defun ediff-set-meta-overlay (b e prop &optional session-number hidden) |
| 1494 | (let (overl) | 1494 | (let (overl) |
| 1495 | (setq overl (ediff-make-overlay b e)) | 1495 | (setq overl (ediff-make-overlay b e)) |
| 1496 | (if ediff-emacs-p | 1496 | (if (featurep 'emacs) |
| 1497 | (ediff-overlay-put overl 'mouse-face 'highlight) | 1497 | (ediff-overlay-put overl 'mouse-face 'highlight) |
| 1498 | (ediff-overlay-put overl 'highlight t)) | 1498 | (ediff-overlay-put overl 'highlight t)) |
| 1499 | (ediff-overlay-put overl 'ediff-meta-info prop) | 1499 | (ediff-overlay-put overl 'ediff-meta-info prop) |
diff --git a/lisp/ediff-util.el b/lisp/ediff-util.el index f3cffe0847f..2ed8f73a282 100644 --- a/lisp/ediff-util.el +++ b/lisp/ediff-util.el | |||
| @@ -38,7 +38,6 @@ | |||
| 38 | (defvar bottom-toolbar-visible-p) | 38 | (defvar bottom-toolbar-visible-p) |
| 39 | (defvar bottom-toolbar-height) | 39 | (defvar bottom-toolbar-height) |
| 40 | (defvar mark-active) | 40 | (defvar mark-active) |
| 41 | (defvar ediff-emacs-p) | ||
| 42 | 41 | ||
| 43 | (defvar ediff-after-quit-hook-internal nil) | 42 | (defvar ediff-after-quit-hook-internal nil) |
| 44 | 43 | ||
| @@ -64,7 +63,7 @@ | |||
| 64 | (or (featurep 'ediff) | 63 | (or (featurep 'ediff) |
| 65 | (load "ediff.el" nil nil 'nosuffix)) | 64 | (load "ediff.el" nil nil 'nosuffix)) |
| 66 | (or (featurep 'ediff-tbar) | 65 | (or (featurep 'ediff-tbar) |
| 67 | ediff-emacs-p | 66 | (featurep 'emacs) |
| 68 | (load "ediff-tbar.el" 'noerror nil 'nosuffix)) | 67 | (load "ediff-tbar.el" 'noerror nil 'nosuffix)) |
| 69 | )) | 68 | )) |
| 70 | ;; end pacifier | 69 | ;; end pacifier |
| @@ -77,7 +76,7 @@ | |||
| 77 | (require 'ediff-diff) | 76 | (require 'ediff-diff) |
| 78 | (require 'ediff-merg) | 77 | (require 'ediff-merg) |
| 79 | 78 | ||
| 80 | (if ediff-xemacs-p | 79 | (if (featurep 'xemacs) |
| 81 | (require 'ediff-tbar)) | 80 | (require 'ediff-tbar)) |
| 82 | 81 | ||
| 83 | 82 | ||
| @@ -154,7 +153,7 @@ to invocation.") | |||
| 154 | (suppress-keymap ediff-mode-map) | 153 | (suppress-keymap ediff-mode-map) |
| 155 | 154 | ||
| 156 | (define-key ediff-mode-map | 155 | (define-key ediff-mode-map |
| 157 | (if ediff-emacs-p [mouse-2] [button2]) 'ediff-help-for-quick-help) | 156 | (if (featurep 'emacs) [mouse-2] [button2]) 'ediff-help-for-quick-help) |
| 158 | (define-key ediff-mode-map "\C-m" 'ediff-help-for-quick-help) | 157 | (define-key ediff-mode-map "\C-m" 'ediff-help-for-quick-help) |
| 159 | 158 | ||
| 160 | (define-key ediff-mode-map "p" 'ediff-previous-difference) | 159 | (define-key ediff-mode-map "p" 'ediff-previous-difference) |
| @@ -1275,7 +1274,7 @@ This is especially useful when comparing buffers side-by-side." | |||
| 1275 | (ediff-barf-if-not-control-buffer) | 1274 | (ediff-barf-if-not-control-buffer) |
| 1276 | (or (ediff-window-display-p) | 1275 | (or (ediff-window-display-p) |
| 1277 | (error "%sEmacs is not running as a window application" | 1276 | (error "%sEmacs is not running as a window application" |
| 1278 | (if ediff-emacs-p "" "X"))) | 1277 | (if (featurep 'emacs) "" "X"))) |
| 1279 | (ediff-recenter 'no-rehighlight) ; make sure buffs are displayed in windows | 1278 | (ediff-recenter 'no-rehighlight) ; make sure buffs are displayed in windows |
| 1280 | (let ((ctl-buf ediff-control-buffer)) | 1279 | (let ((ctl-buf ediff-control-buffer)) |
| 1281 | (setq ediff-wide-display-p (not ediff-wide-display-p)) | 1280 | (setq ediff-wide-display-p (not ediff-wide-display-p)) |
| @@ -1283,7 +1282,7 @@ This is especially useful when comparing buffers side-by-side." | |||
| 1283 | (ediff-with-current-buffer ctl-buf | 1282 | (ediff-with-current-buffer ctl-buf |
| 1284 | (modify-frame-parameters | 1283 | (modify-frame-parameters |
| 1285 | ediff-wide-display-frame ediff-wide-display-orig-parameters) | 1284 | ediff-wide-display-frame ediff-wide-display-orig-parameters) |
| 1286 | ;;(sit-for (if ediff-xemacs-p 0.4 0)) | 1285 | ;;(sit-for (if (featurep 'xemacs) 0.4 0)) |
| 1287 | ;; restore control buf, since ctl window may have been deleted | 1286 | ;; restore control buf, since ctl window may have been deleted |
| 1288 | ;; during resizing | 1287 | ;; during resizing |
| 1289 | (set-buffer ctl-buf) | 1288 | (set-buffer ctl-buf) |
| @@ -1291,7 +1290,7 @@ This is especially useful when comparing buffers side-by-side." | |||
| 1291 | ediff-window-B nil) ; force update of window config | 1290 | ediff-window-B nil) ; force update of window config |
| 1292 | (ediff-recenter 'no-rehighlight)) | 1291 | (ediff-recenter 'no-rehighlight)) |
| 1293 | (funcall ediff-make-wide-display-function) | 1292 | (funcall ediff-make-wide-display-function) |
| 1294 | ;;(sit-for (if ediff-xemacs-p 0.4 0)) | 1293 | ;;(sit-for (if (featurep 'xemacs) 0.4 0)) |
| 1295 | (ediff-with-current-buffer ctl-buf | 1294 | (ediff-with-current-buffer ctl-buf |
| 1296 | (setq ediff-window-B nil) ; force update of window config | 1295 | (setq ediff-window-B nil) ; force update of window config |
| 1297 | (ediff-recenter 'no-rehighlight))))) | 1296 | (ediff-recenter 'no-rehighlight))))) |
| @@ -1305,7 +1304,7 @@ which see." | |||
| 1305 | (let (window-setup-func) | 1304 | (let (window-setup-func) |
| 1306 | (or (ediff-window-display-p) | 1305 | (or (ediff-window-display-p) |
| 1307 | (error "%sEmacs is not running as a window application" | 1306 | (error "%sEmacs is not running as a window application" |
| 1308 | (if ediff-emacs-p "" "X"))) | 1307 | (if (featurep 'emacs) "" "X"))) |
| 1309 | 1308 | ||
| 1310 | (cond ((eq ediff-window-setup-function 'ediff-setup-windows-multiframe) | 1309 | (cond ((eq ediff-window-setup-function 'ediff-setup-windows-multiframe) |
| 1311 | (setq window-setup-func 'ediff-setup-windows-plain)) | 1310 | (setq window-setup-func 'ediff-setup-windows-plain)) |
| @@ -1335,7 +1334,7 @@ To change the default, set the variable `ediff-use-toolbar-p', which see." | |||
| 1335 | (progn | 1334 | (progn |
| 1336 | (or (ediff-window-display-p) | 1335 | (or (ediff-window-display-p) |
| 1337 | (error "%sEmacs is not running as a window application" | 1336 | (error "%sEmacs is not running as a window application" |
| 1338 | (if ediff-emacs-p "" "X"))) | 1337 | (if (featurep 'emacs) "" "X"))) |
| 1339 | (if (ediff-use-toolbar-p) | 1338 | (if (ediff-use-toolbar-p) |
| 1340 | (ediff-kill-bottom-toolbar)) | 1339 | (ediff-kill-bottom-toolbar)) |
| 1341 | ;; do this only after killing the toolbar | 1340 | ;; do this only after killing the toolbar |
| @@ -2529,7 +2528,7 @@ temporarily reverses the meaning of this variable." | |||
| 2529 | (cond ((ediff-good-frame-under-mouse)) | 2528 | (cond ((ediff-good-frame-under-mouse)) |
| 2530 | (t warp-frame))) | 2529 | (t warp-frame))) |
| 2531 | (if (and (ediff-window-display-p) (frame-live-p warp-frame) ediff-grab-mouse) | 2530 | (if (and (ediff-window-display-p) (frame-live-p warp-frame) ediff-grab-mouse) |
| 2532 | (set-mouse-position (if ediff-emacs-p | 2531 | (set-mouse-position (if (featurep 'emacs) |
| 2533 | warp-frame | 2532 | warp-frame |
| 2534 | (frame-selected-window warp-frame)) | 2533 | (frame-selected-window warp-frame)) |
| 2535 | 2 1)) | 2534 | 2 1)) |
| @@ -2544,11 +2543,11 @@ temporarily reverses the meaning of this variable." | |||
| 2544 | (buf-name "") | 2543 | (buf-name "") |
| 2545 | frame obj-ok) | 2544 | frame obj-ok) |
| 2546 | (setq obj-ok | 2545 | (setq obj-ok |
| 2547 | (if ediff-emacs-p | 2546 | (if (featurep 'emacs) |
| 2548 | (frame-live-p frame-or-win) | 2547 | (frame-live-p frame-or-win) |
| 2549 | (window-live-p frame-or-win))) | 2548 | (window-live-p frame-or-win))) |
| 2550 | (if obj-ok | 2549 | (if obj-ok |
| 2551 | (setq frame (if ediff-emacs-p frame-or-win (window-frame frame-or-win)) | 2550 | (setq frame (if (featurep 'emacs) frame-or-win (window-frame frame-or-win)) |
| 2552 | buf-name | 2551 | buf-name |
| 2553 | (buffer-name (window-buffer (frame-selected-window frame))))) | 2552 | (buffer-name (window-buffer (frame-selected-window frame))))) |
| 2554 | (if (string-match "Minibuf" buf-name) | 2553 | (if (string-match "Minibuf" buf-name) |
| @@ -3031,7 +3030,7 @@ Hit \\[ediff-recenter] to reset the windows afterward." | |||
| 3031 | (ediff-get-symbol-from-alist | 3030 | (ediff-get-symbol-from-alist |
| 3032 | buf-type ediff-current-diff-overlay-alist)))) | 3031 | buf-type ediff-current-diff-overlay-alist)))) |
| 3033 | 3032 | ||
| 3034 | (if ediff-xemacs-p | 3033 | (if (featurep 'xemacs) |
| 3035 | (ediff-move-overlay current-diff-overlay begin end-hilit) | 3034 | (ediff-move-overlay current-diff-overlay begin end-hilit) |
| 3036 | (ediff-move-overlay current-diff-overlay begin end-hilit buff)) | 3035 | (ediff-move-overlay current-diff-overlay begin end-hilit buff)) |
| 3037 | (ediff-overlay-put current-diff-overlay 'priority | 3036 | (ediff-overlay-put current-diff-overlay 'priority |
| @@ -3611,11 +3610,11 @@ Ediff Control Panel to restore highlighting." | |||
| 3611 | (defun ediff-remove-flags-from-buffer (buffer overlay) | 3610 | (defun ediff-remove-flags-from-buffer (buffer overlay) |
| 3612 | (ediff-with-current-buffer buffer | 3611 | (ediff-with-current-buffer buffer |
| 3613 | (let ((inhibit-read-only t)) | 3612 | (let ((inhibit-read-only t)) |
| 3614 | (if ediff-xemacs-p | 3613 | (if (featurep 'xemacs) |
| 3615 | (ediff-overlay-put overlay 'begin-glyph nil) | 3614 | (ediff-overlay-put overlay 'begin-glyph nil) |
| 3616 | (ediff-overlay-put overlay 'before-string nil)) | 3615 | (ediff-overlay-put overlay 'before-string nil)) |
| 3617 | 3616 | ||
| 3618 | (if ediff-xemacs-p | 3617 | (if (featurep 'xemacs) |
| 3619 | (ediff-overlay-put overlay 'end-glyph nil) | 3618 | (ediff-overlay-put overlay 'end-glyph nil) |
| 3620 | (ediff-overlay-put overlay 'after-string nil)) | 3619 | (ediff-overlay-put overlay 'after-string nil)) |
| 3621 | ))) | 3620 | ))) |
| @@ -3643,7 +3642,7 @@ Ediff Control Panel to restore highlighting." | |||
| 3643 | ediff-before-flag-bol ediff-before-flag-mol)))) | 3642 | ediff-before-flag-bol ediff-before-flag-mol)))) |
| 3644 | 3643 | ||
| 3645 | ;; insert the flag itself | 3644 | ;; insert the flag itself |
| 3646 | (if ediff-xemacs-p | 3645 | (if (featurep 'xemacs) |
| 3647 | (ediff-overlay-put curr-overl 'begin-glyph flag) | 3646 | (ediff-overlay-put curr-overl 'begin-glyph flag) |
| 3648 | (ediff-overlay-put curr-overl 'before-string flag)) | 3647 | (ediff-overlay-put curr-overl 'before-string flag)) |
| 3649 | 3648 | ||
| @@ -3659,7 +3658,7 @@ Ediff Control Panel to restore highlighting." | |||
| 3659 | ediff-after-flag-eol ediff-after-flag-mol)))) | 3658 | ediff-after-flag-eol ediff-after-flag-mol)))) |
| 3660 | 3659 | ||
| 3661 | ;; insert the flag itself | 3660 | ;; insert the flag itself |
| 3662 | (if ediff-xemacs-p | 3661 | (if (featurep 'xemacs) |
| 3663 | (ediff-overlay-put curr-overl 'end-glyph flag) | 3662 | (ediff-overlay-put curr-overl 'end-glyph flag) |
| 3664 | (ediff-overlay-put curr-overl 'after-string flag)) | 3663 | (ediff-overlay-put curr-overl 'after-string flag)) |
| 3665 | )) | 3664 | )) |
| @@ -3786,10 +3785,10 @@ Ediff Control Panel to restore highlighting." | |||
| 3786 | 3785 | ||
| 3787 | ;; never detach | 3786 | ;; never detach |
| 3788 | (ediff-overlay-put | 3787 | (ediff-overlay-put |
| 3789 | overl (if ediff-emacs-p 'evaporate 'detachable) nil) | 3788 | overl (if (featurep 'emacs) 'evaporate 'detachable) nil) |
| 3790 | ;; make overlay open-ended | 3789 | ;; make overlay open-ended |
| 3791 | ;; In emacs, it is made open ended at creation time | 3790 | ;; In emacs, it is made open ended at creation time |
| 3792 | (if ediff-xemacs-p | 3791 | (if (featurep 'xemacs) |
| 3793 | (progn | 3792 | (progn |
| 3794 | (ediff-overlay-put overl 'start-open nil) | 3793 | (ediff-overlay-put overl 'start-open nil) |
| 3795 | (ediff-overlay-put overl 'end-open nil))) | 3794 | (ediff-overlay-put overl 'end-open nil))) |
diff --git a/lisp/ediff-wind.el b/lisp/ediff-wind.el index c2c130ac6bb..8b72a673d17 100644 --- a/lisp/ediff-wind.el +++ b/lisp/ediff-wind.el | |||
| @@ -39,7 +39,6 @@ | |||
| 39 | (defvar top-gutter) | 39 | (defvar top-gutter) |
| 40 | (defvar frame-icon-title-format) | 40 | (defvar frame-icon-title-format) |
| 41 | (defvar ediff-diff-status) | 41 | (defvar ediff-diff-status) |
| 42 | (defvar ediff-emacs-p) | ||
| 43 | 42 | ||
| 44 | (eval-when-compile | 43 | (eval-when-compile |
| 45 | (let ((load-path (cons (expand-file-name ".") load-path))) | 44 | (let ((load-path (cons (expand-file-name ".") load-path))) |
| @@ -50,7 +49,7 @@ | |||
| 50 | (or (featurep 'ediff-help) | 49 | (or (featurep 'ediff-help) |
| 51 | (load "ediff-help.el" nil nil 'nosuffix)) | 50 | (load "ediff-help.el" nil nil 'nosuffix)) |
| 52 | (or (featurep 'ediff-tbar) | 51 | (or (featurep 'ediff-tbar) |
| 53 | ediff-emacs-p | 52 | (featurep 'emacs) |
| 54 | (load "ediff-tbar.el" 'noerror nil 'nosuffix)) | 53 | (load "ediff-tbar.el" 'noerror nil 'nosuffix)) |
| 55 | )) | 54 | )) |
| 56 | ;; end pacifier | 55 | ;; end pacifier |
| @@ -58,7 +57,7 @@ | |||
| 58 | (require 'ediff-init) | 57 | (require 'ediff-init) |
| 59 | 58 | ||
| 60 | ;; be careful with ediff-tbar | 59 | ;; be careful with ediff-tbar |
| 61 | (if ediff-xemacs-p | 60 | (if (featurep 'xemacs) |
| 62 | (condition-case nil | 61 | (condition-case nil |
| 63 | (require 'ediff-tbar) | 62 | (require 'ediff-tbar) |
| 64 | (error | 63 | (error |
| @@ -213,7 +212,7 @@ customization of the default control frame positioning." | |||
| 213 | :type 'integer | 212 | :type 'integer |
| 214 | :group 'ediff-window) | 213 | :group 'ediff-window) |
| 215 | 214 | ||
| 216 | (defcustom ediff-narrow-control-frame-leftward-shift (if ediff-xemacs-p 7 3) | 215 | (defcustom ediff-narrow-control-frame-leftward-shift (if (featurep 'xemacs) 7 3) |
| 217 | "*The leftward shift of control frame from the right edge of buf A's frame. | 216 | "*The leftward shift of control frame from the right edge of buf A's frame. |
| 218 | Measured in characters. | 217 | Measured in characters. |
| 219 | This is used by the default control frame positioning function, | 218 | This is used by the default control frame positioning function, |
| @@ -380,7 +379,7 @@ into icons, regardless of the window manager." | |||
| 380 | ;; XEmacs used to have a lot of trouble with display | 379 | ;; XEmacs used to have a lot of trouble with display |
| 381 | ;; It did't set things right unless we tell it to sit still | 380 | ;; It did't set things right unless we tell it to sit still |
| 382 | ;; 19.12 seems ok. | 381 | ;; 19.12 seems ok. |
| 383 | ;;(if ediff-xemacs-p (sit-for 0)) | 382 | ;;(if (featurep 'xemacs) (sit-for 0)) |
| 384 | 383 | ||
| 385 | (split-window-vertically (max 2 (- (window-height) merge-window-lines))) | 384 | (split-window-vertically (max 2 (- (window-height) merge-window-lines))) |
| 386 | (if (eq (selected-window) wind-A) | 385 | (if (eq (selected-window) wind-A) |
| @@ -443,7 +442,7 @@ into icons, regardless of the window manager." | |||
| 443 | ;; XEmacs used to have a lot of trouble with display | 442 | ;; XEmacs used to have a lot of trouble with display |
| 444 | ;; It did't set things right unless we told it to sit still | 443 | ;; It did't set things right unless we told it to sit still |
| 445 | ;; 19.12 seems ok. | 444 | ;; 19.12 seems ok. |
| 446 | ;;(if ediff-xemacs-p (sit-for 0)) | 445 | ;;(if (featurep 'xemacs) (sit-for 0)) |
| 447 | 446 | ||
| 448 | (funcall split-window-function wind-width-or-height) | 447 | (funcall split-window-function wind-width-or-height) |
| 449 | 448 | ||
| @@ -1043,7 +1042,7 @@ into icons, regardless of the window manager." | |||
| 1043 | (or (eq this-command 'ediff-quit) | 1042 | (or (eq this-command 'ediff-quit) |
| 1044 | (not (eq ediff-grab-mouse t))))) | 1043 | (not (eq ediff-grab-mouse t))))) |
| 1045 | 1044 | ||
| 1046 | (if ediff-xemacs-p | 1045 | (if (featurep 'xemacs) |
| 1047 | (ediff-with-current-buffer ctl-buffer | 1046 | (ediff-with-current-buffer ctl-buffer |
| 1048 | (ediff-cond-compile-for-xemacs-or-emacs | 1047 | (ediff-cond-compile-for-xemacs-or-emacs |
| 1049 | (make-local-hook 'select-frame-hook) ; xemacs | 1048 | (make-local-hook 'select-frame-hook) ; xemacs |
| @@ -1238,7 +1237,7 @@ It assumes that it is called from within the control buffer." | |||
| 1238 | 1237 | ||
| 1239 | 1238 | ||
| 1240 | (defun ediff-refresh-control-frame () | 1239 | (defun ediff-refresh-control-frame () |
| 1241 | (if ediff-emacs-p | 1240 | (if (featurep 'emacs) |
| 1242 | ;; set frame/icon titles for Emacs | 1241 | ;; set frame/icon titles for Emacs |
| 1243 | (modify-frame-parameters | 1242 | (modify-frame-parameters |
| 1244 | ediff-control-frame | 1243 | ediff-control-frame |
| @@ -1288,7 +1287,7 @@ It assumes that it is called from within the control buffer." | |||
| 1288 | ;; If buff is not live, return nil | 1287 | ;; If buff is not live, return nil |
| 1289 | (defun ediff-get-visible-buffer-window (buff) | 1288 | (defun ediff-get-visible-buffer-window (buff) |
| 1290 | (if (ediff-buffer-live-p buff) | 1289 | (if (ediff-buffer-live-p buff) |
| 1291 | (if ediff-xemacs-p | 1290 | (if (featurep 'xemacs) |
| 1292 | (get-buffer-window buff t) | 1291 | (get-buffer-window buff t) |
| 1293 | (get-buffer-window buff 'visible)))) | 1292 | (get-buffer-window buff 'visible)))) |
| 1294 | 1293 | ||
diff --git a/lisp/ediff.el b/lisp/ediff.el index 8911dc599f1..a2aafc90292 100644 --- a/lisp/ediff.el +++ b/lisp/ediff.el | |||
| @@ -1440,7 +1440,7 @@ With optional NODE, goes to that node." | |||
| 1440 | (condition-case nil | 1440 | (condition-case nil |
| 1441 | (progn | 1441 | (progn |
| 1442 | (pop-to-buffer (get-buffer-create "*info*")) | 1442 | (pop-to-buffer (get-buffer-create "*info*")) |
| 1443 | (info (if ediff-xemacs-p "ediff.info" "ediff")) | 1443 | (info (if (featurep 'xemacs) "ediff.info" "ediff")) |
| 1444 | (if node | 1444 | (if node |
| 1445 | (Info-goto-node node) | 1445 | (Info-goto-node node) |
| 1446 | (message "Type `i' to search for a specific topic")) | 1446 | (message "Type `i' to search for a specific topic")) |
diff --git a/lisp/emulation/viper-cmd.el b/lisp/emulation/viper-cmd.el index 88af961e488..5e13edb9495 100644 --- a/lisp/emulation/viper-cmd.el +++ b/lisp/emulation/viper-cmd.el | |||
| @@ -834,7 +834,7 @@ Vi's prefix argument will be used. Otherwise, the prefix argument passed to | |||
| 834 | viper-emacs-kbd-minor-mode | 834 | viper-emacs-kbd-minor-mode |
| 835 | ch) | 835 | ch) |
| 836 | (cond ((and viper-special-input-method | 836 | (cond ((and viper-special-input-method |
| 837 | viper-emacs-p | 837 | (featurep 'emacs) |
| 838 | (fboundp 'quail-input-method)) | 838 | (fboundp 'quail-input-method)) |
| 839 | ;; (let ...) is used to restore unread-command-events to the | 839 | ;; (let ...) is used to restore unread-command-events to the |
| 840 | ;; original state. We don't want anything left in there after | 840 | ;; original state. We don't want anything left in there after |
| @@ -861,7 +861,7 @@ Vi's prefix argument will be used. Otherwise, the prefix argument passed to | |||
| 861 | (1- (length quail-current-str))))) | 861 | (1- (length quail-current-str))))) |
| 862 | )) | 862 | )) |
| 863 | ((and viper-special-input-method | 863 | ((and viper-special-input-method |
| 864 | viper-xemacs-p | 864 | (featurep 'xemacs) |
| 865 | (fboundp 'quail-start-translation)) | 865 | (fboundp 'quail-start-translation)) |
| 866 | ;; same as above but for XEmacs, which doesn't have | 866 | ;; same as above but for XEmacs, which doesn't have |
| 867 | ;; quail-input-method | 867 | ;; quail-input-method |
| @@ -893,7 +893,7 @@ Vi's prefix argument will be used. Otherwise, the prefix argument passed to | |||
| 893 | (t | 893 | (t |
| 894 | ;;(setq ch (read-char-exclusive)) | 894 | ;;(setq ch (read-char-exclusive)) |
| 895 | (setq ch (aref (read-key-sequence nil) 0)) | 895 | (setq ch (aref (read-key-sequence nil) 0)) |
| 896 | (if viper-xemacs-p | 896 | (if (featurep 'xemacs) |
| 897 | (setq ch (event-to-character ch))) | 897 | (setq ch (event-to-character ch))) |
| 898 | ;; replace ^M with the newline | 898 | ;; replace ^M with the newline |
| 899 | (if (eq ch ?\C-m) (setq ch ?\n)) | 899 | (if (eq ch ?\C-m) (setq ch ?\n)) |
| @@ -902,13 +902,13 @@ Vi's prefix argument will be used. Otherwise, the prefix argument passed to | |||
| 902 | (progn | 902 | (progn |
| 903 | ;;(setq ch (read-char-exclusive)) | 903 | ;;(setq ch (read-char-exclusive)) |
| 904 | (setq ch (aref (read-key-sequence nil) 0)) | 904 | (setq ch (aref (read-key-sequence nil) 0)) |
| 905 | (if viper-xemacs-p | 905 | (if (featurep 'xemacs) |
| 906 | (setq ch (event-to-character ch)))) | 906 | (setq ch (event-to-character ch)))) |
| 907 | ) | 907 | ) |
| 908 | (insert ch)) | 908 | (insert ch)) |
| 909 | ) | 909 | ) |
| 910 | (setq last-command-event | 910 | (setq last-command-event |
| 911 | (viper-copy-event (if viper-xemacs-p | 911 | (viper-copy-event (if (featurep 'xemacs) |
| 912 | (character-to-event ch) ch))) | 912 | (character-to-event ch) ch))) |
| 913 | ) ; let | 913 | ) ; let |
| 914 | (error nil) | 914 | (error nil) |
| @@ -1080,10 +1080,10 @@ as a Meta key and any number of multiple escapes is allowed." | |||
| 1080 | ;; and return ESC as the key-sequence | 1080 | ;; and return ESC as the key-sequence |
| 1081 | (viper-set-unread-command-events (viper-subseq keyseq 1)) | 1081 | (viper-set-unread-command-events (viper-subseq keyseq 1)) |
| 1082 | (setq last-input-event event | 1082 | (setq last-input-event event |
| 1083 | keyseq (if viper-emacs-p | 1083 | keyseq (if (featurep 'emacs) |
| 1084 | "\e" | 1084 | "\e" |
| 1085 | (vector (character-to-event ?\e))))) | 1085 | (vector (character-to-event ?\e))))) |
| 1086 | ((and viper-xemacs-p | 1086 | ((and (featurep 'xemacs) |
| 1087 | (key-press-event-p first-key) | 1087 | (key-press-event-p first-key) |
| 1088 | (equal '(meta) key-mod)) | 1088 | (equal '(meta) key-mod)) |
| 1089 | (viper-set-unread-command-events | 1089 | (viper-set-unread-command-events |
| @@ -1320,7 +1320,7 @@ as a Meta key and any number of multiple escapes is allowed." | |||
| 1320 | (setq last-command-char char) | 1320 | (setq last-command-char char) |
| 1321 | (setq last-command-event | 1321 | (setq last-command-event |
| 1322 | (viper-copy-event | 1322 | (viper-copy-event |
| 1323 | (if viper-xemacs-p (character-to-event char) char))) | 1323 | (if (featurep 'xemacs) (character-to-event char) char))) |
| 1324 | (condition-case err | 1324 | (condition-case err |
| 1325 | (funcall cmd-to-exec-at-end cmd-info) | 1325 | (funcall cmd-to-exec-at-end cmd-info) |
| 1326 | (error | 1326 | (error |
| @@ -2791,7 +2791,7 @@ On reaching beginning of line, stop and signal error." | |||
| 2791 | (defun viper-next-line-carefully (arg) | 2791 | (defun viper-next-line-carefully (arg) |
| 2792 | (condition-case nil | 2792 | (condition-case nil |
| 2793 | ;; do not use forward-line! need to keep column | 2793 | ;; do not use forward-line! need to keep column |
| 2794 | (next-line arg) | 2794 | (with-no-warnings (next-line arg)) |
| 2795 | (error nil))) | 2795 | (error nil))) |
| 2796 | 2796 | ||
| 2797 | 2797 | ||
| @@ -3091,7 +3091,7 @@ On reaching beginning of line, stop and signal error." | |||
| 3091 | (com (viper-getCom arg))) | 3091 | (com (viper-getCom arg))) |
| 3092 | (if com (viper-move-marker-locally 'viper-com-point (point))) | 3092 | (if com (viper-move-marker-locally 'viper-com-point (point))) |
| 3093 | ;; do not use forward-line! need to keep column | 3093 | ;; do not use forward-line! need to keep column |
| 3094 | (next-line val) | 3094 | (with-no-warnings (next-line val)) |
| 3095 | (if viper-ex-style-motion | 3095 | (if viper-ex-style-motion |
| 3096 | (if (and (eolp) (not (bolp))) (backward-char 1))) | 3096 | (if (and (eolp) (not (bolp))) (backward-char 1))) |
| 3097 | (setq this-command 'next-line) | 3097 | (setq this-command 'next-line) |
| @@ -3135,7 +3135,7 @@ If point is on a widget or a button, simulate clicking on that widget/button." | |||
| 3135 | (com (viper-getCom arg))) | 3135 | (com (viper-getCom arg))) |
| 3136 | (if com (viper-move-marker-locally 'viper-com-point (point))) | 3136 | (if com (viper-move-marker-locally 'viper-com-point (point))) |
| 3137 | ;; do not use forward-line! need to keep column | 3137 | ;; do not use forward-line! need to keep column |
| 3138 | (previous-line val) | 3138 | (with-no-warnings (previous-line val)) |
| 3139 | (if viper-ex-style-motion | 3139 | (if viper-ex-style-motion |
| 3140 | (if (and (eolp) (not (bolp))) (backward-char 1))) | 3140 | (if (and (eolp) (not (bolp))) (backward-char 1))) |
| 3141 | (setq this-command 'previous-line) | 3141 | (setq this-command 'previous-line) |
diff --git a/lisp/emulation/viper-ex.el b/lisp/emulation/viper-ex.el index d9cc97719ca..caeecd12c8a 100644 --- a/lisp/emulation/viper-ex.el +++ b/lisp/emulation/viper-ex.el | |||
| @@ -1103,7 +1103,7 @@ reversed." | |||
| 1103 | beg end cont val) | 1103 | beg end cont val) |
| 1104 | 1104 | ||
| 1105 | (viper-add-keymap ex-read-filename-map | 1105 | (viper-add-keymap ex-read-filename-map |
| 1106 | (if viper-emacs-p | 1106 | (if (featurep 'emacs) |
| 1107 | minibuffer-local-completion-map | 1107 | minibuffer-local-completion-map |
| 1108 | read-file-name-map)) | 1108 | read-file-name-map)) |
| 1109 | 1109 | ||
| @@ -1558,7 +1558,7 @@ reversed." | |||
| 1558 | ;; setup buffer | 1558 | ;; setup buffer |
| 1559 | (if (setq wind (viper-get-visible-buffer-window buf)) | 1559 | (if (setq wind (viper-get-visible-buffer-window buf)) |
| 1560 | () | 1560 | () |
| 1561 | (setq wind (get-lru-window (if viper-xemacs-p nil 'visible))) | 1561 | (setq wind (get-lru-window (if (featurep 'xemacs) nil 'visible))) |
| 1562 | (set-window-buffer wind buf)) | 1562 | (set-window-buffer wind buf)) |
| 1563 | 1563 | ||
| 1564 | (if (viper-window-display-p) | 1564 | (if (viper-window-display-p) |
| @@ -1878,7 +1878,7 @@ reversed." | |||
| 1878 | (condition-case nil | 1878 | (condition-case nil |
| 1879 | (progn | 1879 | (progn |
| 1880 | (pop-to-buffer (get-buffer-create "*info*")) | 1880 | (pop-to-buffer (get-buffer-create "*info*")) |
| 1881 | (info (if viper-xemacs-p "viper.info" "viper")) | 1881 | (info (if (featurep 'xemacs) "viper.info" "viper")) |
| 1882 | (message "Type `i' to search for a specific topic")) | 1882 | (message "Type `i' to search for a specific topic")) |
| 1883 | (error (beep 1) | 1883 | (error (beep 1) |
| 1884 | (with-output-to-temp-buffer " *viper-info*" | 1884 | (with-output-to-temp-buffer " *viper-info*" |
| @@ -1887,7 +1887,7 @@ The Info file for Viper does not seem to be installed. | |||
| 1887 | 1887 | ||
| 1888 | This file is part of the standard distribution of %sEmacs. | 1888 | This file is part of the standard distribution of %sEmacs. |
| 1889 | Please contact your system administrator. " | 1889 | Please contact your system administrator. " |
| 1890 | (if viper-xemacs-p "X" "") | 1890 | (if (featurep 'xemacs) "X" "") |
| 1891 | )))))) | 1891 | )))))) |
| 1892 | 1892 | ||
| 1893 | ;; Ex source command. Loads the file specified as argument or `~/.viper' | 1893 | ;; Ex source command. Loads the file specified as argument or `~/.viper' |
diff --git a/lisp/emulation/viper-init.el b/lisp/emulation/viper-init.el index 1b05ef7189d..1b1e07a0a0c 100644 --- a/lisp/emulation/viper-init.el +++ b/lisp/emulation/viper-init.el | |||
| @@ -49,10 +49,6 @@ | |||
| 49 | (interactive) | 49 | (interactive) |
| 50 | (message "Viper version is %s" viper-version)) | 50 | (message "Viper version is %s" viper-version)) |
| 51 | 51 | ||
| 52 | ;; Is it XEmacs? | ||
| 53 | (defconst viper-xemacs-p (featurep 'xemacs)) | ||
| 54 | ;; Is it Emacs? | ||
| 55 | (defconst viper-emacs-p (not viper-xemacs-p)) | ||
| 56 | ;; Tell whether we are running as a window application or on a TTY | 52 | ;; Tell whether we are running as a window application or on a TTY |
| 57 | 53 | ||
| 58 | ;; This is used to avoid compilation warnings. When emacs/xemacs forms can | 54 | ;; This is used to avoid compilation warnings. When emacs/xemacs forms can |
| @@ -116,8 +112,8 @@ In all likelihood, you don't need to bother with this setting." | |||
| 116 | (cond ((viper-window-display-p)) | 112 | (cond ((viper-window-display-p)) |
| 117 | (viper-force-faces) | 113 | (viper-force-faces) |
| 118 | ((viper-color-display-p)) | 114 | ((viper-color-display-p)) |
| 119 | (viper-emacs-p (memq (viper-device-type) '(pc))) | 115 | ((featurep 'emacs) (memq (viper-device-type) '(pc))) |
| 120 | (viper-xemacs-p (memq (viper-device-type) '(tty pc))))) | 116 | ((featurep 'xemacs) (memq (viper-device-type) '(tty pc))))) |
| 121 | 117 | ||
| 122 | 118 | ||
| 123 | ;;; Macros | 119 | ;;; Macros |
| @@ -356,9 +352,9 @@ Use `M-x viper-set-expert-level' to change this.") | |||
| 356 | ""))))) | 352 | ""))))) |
| 357 | 353 | ||
| 358 | (defun viper-inactivate-input-method () | 354 | (defun viper-inactivate-input-method () |
| 359 | (cond ((and viper-emacs-p (fboundp 'inactivate-input-method)) | 355 | (cond ((and (featurep 'emacs) (fboundp 'inactivate-input-method)) |
| 360 | (inactivate-input-method)) | 356 | (inactivate-input-method)) |
| 361 | ((and viper-xemacs-p (boundp 'current-input-method)) | 357 | ((and (featurep 'xemacs) (boundp 'current-input-method)) |
| 362 | ;; XEmacs had broken quil-mode for some time, so we are working around | 358 | ;; XEmacs had broken quil-mode for some time, so we are working around |
| 363 | ;; it here | 359 | ;; it here |
| 364 | (setq quail-mode nil) | 360 | (setq quail-mode nil) |
| @@ -370,7 +366,7 @@ Use `M-x viper-set-expert-level' to change this.") | |||
| 370 | (force-mode-line-update)) | 366 | (force-mode-line-update)) |
| 371 | )) | 367 | )) |
| 372 | (defun viper-activate-input-method () | 368 | (defun viper-activate-input-method () |
| 373 | (cond ((and viper-emacs-p (fboundp 'activate-input-method)) | 369 | (cond ((and (featurep 'emacs) (fboundp 'activate-input-method)) |
| 374 | (activate-input-method default-input-method)) | 370 | (activate-input-method default-input-method)) |
| 375 | ((featurep 'xemacs) | 371 | ((featurep 'xemacs) |
| 376 | (if (fboundp 'quail-mode) (quail-mode 1))))) | 372 | (if (fboundp 'quail-mode) (quail-mode 1))))) |
| @@ -475,7 +471,7 @@ is non-nil." | |||
| 475 | :group 'viper) | 471 | :group 'viper) |
| 476 | (defcustom viper-use-replace-region-delimiters | 472 | (defcustom viper-use-replace-region-delimiters |
| 477 | (or (not (viper-has-face-support-p)) | 473 | (or (not (viper-has-face-support-p)) |
| 478 | (and viper-xemacs-p (eq (viper-device-type) 'tty))) | 474 | (and (featurep 'xemacs) (eq (viper-device-type) 'tty))) |
| 479 | "*If non-nil, Viper will always use `viper-replace-region-end-delimiter' and | 475 | "*If non-nil, Viper will always use `viper-replace-region-end-delimiter' and |
| 480 | `viper-replace-region-start-delimiter' to delimit replacement regions, even on | 476 | `viper-replace-region-start-delimiter' to delimit replacement regions, even on |
| 481 | color displays. By default, the delimiters are used only on TTYs." | 477 | color displays. By default, the delimiters are used only on TTYs." |
| @@ -1018,13 +1014,13 @@ Should be set in `~/.viper' file." | |||
| 1018 | 1014 | ||
| 1019 | (defun viper-restore-cursor-type () | 1015 | (defun viper-restore-cursor-type () |
| 1020 | (condition-case nil | 1016 | (condition-case nil |
| 1021 | (if viper-xemacs-p | 1017 | (if (featurep 'xemacs) |
| 1022 | (set (make-local-variable 'bar-cursor) nil) | 1018 | (set (make-local-variable 'bar-cursor) nil) |
| 1023 | (setq cursor-type default-cursor-type)) | 1019 | (setq cursor-type default-cursor-type)) |
| 1024 | (error nil))) | 1020 | (error nil))) |
| 1025 | 1021 | ||
| 1026 | (defun viper-set-insert-cursor-type () | 1022 | (defun viper-set-insert-cursor-type () |
| 1027 | (if viper-xemacs-p | 1023 | (if (featurep 'xemacs) |
| 1028 | (set (make-local-variable 'bar-cursor) 2) | 1024 | (set (make-local-variable 'bar-cursor) 2) |
| 1029 | (setq cursor-type '(bar . 2)))) | 1025 | (setq cursor-type '(bar . 2)))) |
| 1030 | 1026 | ||
diff --git a/lisp/emulation/viper-macs.el b/lisp/emulation/viper-macs.el index bf3f0eefb39..788feaf86e6 100644 --- a/lisp/emulation/viper-macs.el +++ b/lisp/emulation/viper-macs.el | |||
| @@ -826,7 +826,7 @@ name from there." | |||
| 826 | (defun viper-char-array-to-macro (array) | 826 | (defun viper-char-array-to-macro (array) |
| 827 | (let ((vec (vconcat array)) | 827 | (let ((vec (vconcat array)) |
| 828 | macro) | 828 | macro) |
| 829 | (if viper-xemacs-p | 829 | (if (featurep 'xemacs) |
| 830 | (setq macro (mapcar 'character-to-event vec)) | 830 | (setq macro (mapcar 'character-to-event vec)) |
| 831 | (setq macro vec)) | 831 | (setq macro vec)) |
| 832 | (vconcat (mapcar 'viper-event-key macro)))) | 832 | (vconcat (mapcar 'viper-event-key macro)))) |
diff --git a/lisp/emulation/viper-mous.el b/lisp/emulation/viper-mous.el index e95e80aa4e0..7a47d321890 100644 --- a/lisp/emulation/viper-mous.el +++ b/lisp/emulation/viper-mous.el | |||
| @@ -79,7 +79,7 @@ or a tripple-click." | |||
| 79 | ;; time interval in millisecond within which successive clicks are | 79 | ;; time interval in millisecond within which successive clicks are |
| 80 | ;; considered related | 80 | ;; considered related |
| 81 | (defcustom viper-multiclick-timeout (if (viper-window-display-p) | 81 | (defcustom viper-multiclick-timeout (if (viper-window-display-p) |
| 82 | (if viper-xemacs-p | 82 | (if (featurep 'xemacs) |
| 83 | mouse-track-multi-click-time | 83 | mouse-track-multi-click-time |
| 84 | double-click-time) | 84 | double-click-time) |
| 85 | 500) | 85 | 500) |
| @@ -227,7 +227,7 @@ is ignored." | |||
| 227 | ) ; if | 227 | ) ; if |
| 228 | ;; XEmacs doesn't have set-text-properties, but there buffer-substring | 228 | ;; XEmacs doesn't have set-text-properties, but there buffer-substring |
| 229 | ;; doesn't return properties together with the string, so it's not needed. | 229 | ;; doesn't return properties together with the string, so it's not needed. |
| 230 | (if viper-emacs-p | 230 | (if (featurep 'emacs) |
| 231 | (set-text-properties 0 (length result) nil result)) | 231 | (set-text-properties 0 (length result) nil result)) |
| 232 | result | 232 | result |
| 233 | )) | 233 | )) |
| @@ -273,7 +273,7 @@ See `viper-surrounding-word' for the definition of a word in this case." | |||
| 273 | 'viper-mouse-catch-frame-switch)) | 273 | 'viper-mouse-catch-frame-switch)) |
| 274 | (not (eq (key-binding viper-mouse-up-insert-key-parsed) | 274 | (not (eq (key-binding viper-mouse-up-insert-key-parsed) |
| 275 | 'viper-mouse-click-insert-word)) | 275 | 'viper-mouse-click-insert-word)) |
| 276 | (and viper-xemacs-p (not (event-over-text-area-p click))))) | 276 | (and (featurep 'xemacs) (not (event-over-text-area-p click))))) |
| 277 | () ; do nothing, if binding isn't right or not over text | 277 | () ; do nothing, if binding isn't right or not over text |
| 278 | ;; turn arg into a number | 278 | ;; turn arg into a number |
| 279 | (cond ((integerp arg) nil) | 279 | (cond ((integerp arg) nil) |
| @@ -364,7 +364,7 @@ this command." | |||
| 364 | 'viper-mouse-catch-frame-switch)) | 364 | 'viper-mouse-catch-frame-switch)) |
| 365 | (not (eq (key-binding viper-mouse-up-search-key-parsed) | 365 | (not (eq (key-binding viper-mouse-up-search-key-parsed) |
| 366 | 'viper-mouse-click-search-word)) | 366 | 'viper-mouse-click-search-word)) |
| 367 | (and viper-xemacs-p (not (event-over-text-area-p click))))) | 367 | (and (featurep 'xemacs) (not (event-over-text-area-p click))))) |
| 368 | () ; do nothing, if binding isn't right or not over text | 368 | () ; do nothing, if binding isn't right or not over text |
| 369 | (let ((previous-search-string viper-s-string) | 369 | (let ((previous-search-string viper-s-string) |
| 370 | click-word click-count) | 370 | click-word click-count) |
| @@ -507,19 +507,19 @@ bindings in the Viper manual." | |||
| 507 | () | 507 | () |
| 508 | (setq button-spec | 508 | (setq button-spec |
| 509 | (cond ((memq 1 key) | 509 | (cond ((memq 1 key) |
| 510 | (if viper-emacs-p | 510 | (if (featurep 'emacs) |
| 511 | (if (eq 'up event-type) | 511 | (if (eq 'up event-type) |
| 512 | "mouse-1" "down-mouse-1") | 512 | "mouse-1" "down-mouse-1") |
| 513 | (if (eq 'up event-type) | 513 | (if (eq 'up event-type) |
| 514 | 'button1up 'button1))) | 514 | 'button1up 'button1))) |
| 515 | ((memq 2 key) | 515 | ((memq 2 key) |
| 516 | (if viper-emacs-p | 516 | (if (featurep 'emacs) |
| 517 | (if (eq 'up event-type) | 517 | (if (eq 'up event-type) |
| 518 | "mouse-2" "down-mouse-2") | 518 | "mouse-2" "down-mouse-2") |
| 519 | (if (eq 'up event-type) | 519 | (if (eq 'up event-type) |
| 520 | 'button2up 'button2))) | 520 | 'button2up 'button2))) |
| 521 | ((memq 3 key) | 521 | ((memq 3 key) |
| 522 | (if viper-emacs-p | 522 | (if (featurep 'emacs) |
| 523 | (if (eq 'up event-type) | 523 | (if (eq 'up event-type) |
| 524 | "mouse-3" "down-mouse-3") | 524 | "mouse-3" "down-mouse-3") |
| 525 | (if (eq 'up event-type) | 525 | (if (eq 'up event-type) |
| @@ -528,18 +528,18 @@ bindings in the Viper manual." | |||
| 528 | "%S: invalid button number, %S" key-var key))) | 528 | "%S: invalid button number, %S" key-var key))) |
| 529 | meta-spec | 529 | meta-spec |
| 530 | (if (memq 'meta key) | 530 | (if (memq 'meta key) |
| 531 | (if viper-emacs-p "M-" 'meta) | 531 | (if (featurep 'emacs) "M-" 'meta) |
| 532 | (if viper-emacs-p "" nil)) | 532 | (if (featurep 'emacs) "" nil)) |
| 533 | shift-spec | 533 | shift-spec |
| 534 | (if (memq 'shift key) | 534 | (if (memq 'shift key) |
| 535 | (if viper-emacs-p "S-" 'shift) | 535 | (if (featurep 'emacs) "S-" 'shift) |
| 536 | (if viper-emacs-p "" nil)) | 536 | (if (featurep 'emacs) "" nil)) |
| 537 | control-spec | 537 | control-spec |
| 538 | (if (memq 'control key) | 538 | (if (memq 'control key) |
| 539 | (if viper-emacs-p "C-" 'control) | 539 | (if (featurep 'emacs) "C-" 'control) |
| 540 | (if viper-emacs-p "" nil))) | 540 | (if (featurep 'emacs) "" nil))) |
| 541 | 541 | ||
| 542 | (setq key-spec (if viper-emacs-p | 542 | (setq key-spec (if (featurep 'emacs) |
| 543 | (vector | 543 | (vector |
| 544 | (intern | 544 | (intern |
| 545 | (concat | 545 | (concat |
diff --git a/lisp/emulation/viper-util.el b/lisp/emulation/viper-util.el index 7073cd019dd..c757eb63aef 100644 --- a/lisp/emulation/viper-util.el +++ b/lisp/emulation/viper-util.el | |||
| @@ -64,48 +64,34 @@ | |||
| 64 | (fset 'x-color-defined-p (symbol-function 'ns-color-defined-p))) | 64 | (fset 'x-color-defined-p (symbol-function 'ns-color-defined-p))) |
| 65 | 65 | ||
| 66 | 66 | ||
| 67 | ;;; XEmacs support | 67 | (defalias 'viper-overlay-p |
| 68 | 68 | (if (featurep 'xemacs) 'extentp 'overlayp)) | |
| 69 | 69 | (defalias 'viper-make-overlay | |
| 70 | (viper-cond-compile-for-xemacs-or-emacs | 70 | (if (featurep 'xemacs) 'make-extent 'make-overlay)) |
| 71 | (progn ; xemacs | 71 | (defalias 'viper-overlay-live-p |
| 72 | (fset 'viper-overlay-p (symbol-function 'extentp)) | 72 | (if (featurep 'xemacs) 'extent-live-p 'overlayp)) |
| 73 | (fset 'viper-make-overlay (symbol-function 'make-extent)) | 73 | (defalias 'viper-move-overlay |
| 74 | (fset 'viper-overlay-live-p (symbol-function 'extent-live-p)) | 74 | (if (featurep 'xemacs) 'set-extent-endpoints 'move-overlay)) |
| 75 | (fset 'viper-move-overlay (symbol-function 'set-extent-endpoints)) | 75 | (defalias 'viper-overlay-start |
| 76 | (fset 'viper-overlay-start (symbol-function 'extent-start-position)) | 76 | (if (featurep 'xemacs) 'extent-start-position 'overlay-start)) |
| 77 | (fset 'viper-overlay-end (symbol-function 'extent-end-position)) | 77 | (defalias 'viper-overlay-end |
| 78 | (fset 'viper-overlay-get (symbol-function 'extent-property)) | 78 | (if (featurep 'xemacs) 'extent-end-position 'overlay-end)) |
| 79 | (fset 'viper-overlay-put (symbol-function 'set-extent-property)) | 79 | (defalias 'viper-overlay-get |
| 80 | (fset 'viper-read-event (symbol-function 'next-command-event)) | 80 | (if (featurep 'xemacs) 'extent-property 'overlay-get)) |
| 81 | (fset 'viper-characterp (symbol-function 'characterp)) | 81 | (defalias 'viper-overlay-put |
| 82 | (fset 'viper-int-to-char (symbol-function 'int-to-char)) | 82 | (if (featurep 'xemacs) 'set-extent-property 'overlay-put)) |
| 83 | (if (viper-window-display-p) | 83 | (defalias 'viper-read-event |
| 84 | (fset 'viper-iconify (symbol-function 'iconify-frame))) | 84 | (if (featurep 'xemacs) 'next-command-event 'read-event)) |
| 85 | (cond ((viper-has-face-support-p) | 85 | (defalias 'viper-characterp |
| 86 | (fset 'viper-get-face (symbol-function 'get-face)) | 86 | (if (featurep 'xemacs) 'characterp 'integerp)) |
| 87 | (fset 'viper-color-defined-p (symbol-function 'valid-color-name-p)) | 87 | (defalias 'viper-int-to-char |
| 88 | ))) | 88 | (if (featurep 'xemacs) 'int-to-char 'identity)) |
| 89 | (progn ; emacs | 89 | (defalias 'viper-get-face |
| 90 | (fset 'viper-overlay-p (symbol-function 'overlayp)) | 90 | (if (featurep 'xemacs) 'get-face 'internal-get-face)) |
| 91 | (fset 'viper-make-overlay (symbol-function 'make-overlay)) | 91 | (defalias 'viper-color-defined-p |
| 92 | (fset 'viper-overlay-live-p (symbol-function 'overlayp)) | 92 | (if (featurep 'xemacs) 'valid-color-name-p 'x-color-defined-p)) |
| 93 | (fset 'viper-move-overlay (symbol-function 'move-overlay)) | 93 | (defalias 'viper-iconify |
| 94 | (fset 'viper-overlay-start (symbol-function 'overlay-start)) | 94 | (if (featurep 'xemacs) 'iconify-frame 'iconify-or-deiconify-frame)) |
| 95 | (fset 'viper-overlay-end (symbol-function 'overlay-end)) | ||
| 96 | (fset 'viper-overlay-get (symbol-function 'overlay-get)) | ||
| 97 | (fset 'viper-overlay-put (symbol-function 'overlay-put)) | ||
| 98 | (fset 'viper-read-event (symbol-function 'read-event)) | ||
| 99 | (fset 'viper-characterp (symbol-function 'integerp)) | ||
| 100 | (fset 'viper-int-to-char (symbol-function 'identity)) | ||
| 101 | (if (viper-window-display-p) | ||
| 102 | (fset 'viper-iconify (symbol-function 'iconify-or-deiconify-frame))) | ||
| 103 | (cond ((viper-has-face-support-p) | ||
| 104 | (fset 'viper-get-face (symbol-function 'internal-get-face)) | ||
| 105 | (fset 'viper-color-defined-p (symbol-function 'x-color-defined-p)) | ||
| 106 | ))) | ||
| 107 | ) | ||
| 108 | |||
| 109 | 95 | ||
| 110 | 96 | ||
| 111 | ;; CHAR is supposed to be a char or an integer (positive or negative) | 97 | ;; CHAR is supposed to be a char or an integer (positive or negative) |
| @@ -201,7 +187,7 @@ | |||
| 201 | (defsubst viper-get-saved-cursor-color-in-replace-mode () | 187 | (defsubst viper-get-saved-cursor-color-in-replace-mode () |
| 202 | (or | 188 | (or |
| 203 | (funcall | 189 | (funcall |
| 204 | (if viper-emacs-p 'frame-parameter 'frame-property) | 190 | (if (featurep 'emacs) 'frame-parameter 'frame-property) |
| 205 | (selected-frame) | 191 | (selected-frame) |
| 206 | 'viper-saved-cursor-color-in-replace-mode) | 192 | 'viper-saved-cursor-color-in-replace-mode) |
| 207 | (if (and (eq viper-current-state 'emacs-mode) viper-emacs-state-cursor-color) | 193 | (if (and (eq viper-current-state 'emacs-mode) viper-emacs-state-cursor-color) |
| @@ -211,7 +197,7 @@ | |||
| 211 | (defsubst viper-get-saved-cursor-color-in-insert-mode () | 197 | (defsubst viper-get-saved-cursor-color-in-insert-mode () |
| 212 | (or | 198 | (or |
| 213 | (funcall | 199 | (funcall |
| 214 | (if viper-emacs-p 'frame-parameter 'frame-property) | 200 | (if (featurep 'emacs) 'frame-parameter 'frame-property) |
| 215 | (selected-frame) | 201 | (selected-frame) |
| 216 | 'viper-saved-cursor-color-in-insert-mode) | 202 | 'viper-saved-cursor-color-in-insert-mode) |
| 217 | (if (and (eq viper-current-state 'emacs-mode) viper-emacs-state-cursor-color) | 203 | (if (and (eq viper-current-state 'emacs-mode) viper-emacs-state-cursor-color) |
| @@ -221,7 +207,7 @@ | |||
| 221 | (defsubst viper-get-saved-cursor-color-in-emacs-mode () | 207 | (defsubst viper-get-saved-cursor-color-in-emacs-mode () |
| 222 | (or | 208 | (or |
| 223 | (funcall | 209 | (funcall |
| 224 | (if viper-emacs-p 'frame-parameter 'frame-property) | 210 | (if (featurep 'emacs) 'frame-parameter 'frame-property) |
| 225 | (selected-frame) | 211 | (selected-frame) |
| 226 | 'viper-saved-cursor-color-in-emacs-mode) | 212 | 'viper-saved-cursor-color-in-emacs-mode) |
| 227 | viper-vi-state-cursor-color)) | 213 | viper-vi-state-cursor-color)) |
| @@ -249,8 +235,8 @@ | |||
| 249 | ;; testing for sufficiently high Emacs versions. | 235 | ;; testing for sufficiently high Emacs versions. |
| 250 | (defun viper-check-version (op major minor &optional type-of-emacs) | 236 | (defun viper-check-version (op major minor &optional type-of-emacs) |
| 251 | (if (and (boundp 'emacs-major-version) (boundp 'emacs-minor-version)) | 237 | (if (and (boundp 'emacs-major-version) (boundp 'emacs-minor-version)) |
| 252 | (and (cond ((eq type-of-emacs 'xemacs) viper-xemacs-p) | 238 | (and (cond ((eq type-of-emacs 'xemacs) (featurep 'xemacs)) |
| 253 | ((eq type-of-emacs 'emacs) viper-emacs-p) | 239 | ((eq type-of-emacs 'emacs) (featurep 'emacs)) |
| 254 | (t t)) | 240 | (t t)) |
| 255 | (cond ((eq op '=) (and (= emacs-minor-version minor) | 241 | (cond ((eq op '=) (and (= emacs-minor-version minor) |
| 256 | (= emacs-major-version major))) | 242 | (= emacs-major-version major))) |
| @@ -267,7 +253,7 @@ | |||
| 267 | 253 | ||
| 268 | 254 | ||
| 269 | (defun viper-get-visible-buffer-window (wind) | 255 | (defun viper-get-visible-buffer-window (wind) |
| 270 | (if viper-xemacs-p | 256 | (if (featurep 'xemacs) |
| 271 | (get-buffer-window wind t) | 257 | (get-buffer-window wind t) |
| 272 | (get-buffer-window wind 'visible))) | 258 | (get-buffer-window wind 'visible))) |
| 273 | 259 | ||
| @@ -724,13 +710,14 @@ | |||
| 724 | (defsubst viper-file-checked-in-p (file) | 710 | (defsubst viper-file-checked-in-p (file) |
| 725 | (and (featurep 'vc-hooks) | 711 | (and (featurep 'vc-hooks) |
| 726 | ;; CVS files are considered not checked in | 712 | ;; CVS files are considered not checked in |
| 713 | ;; FIXME: Should this deal with more than CVS? | ||
| 727 | (not (memq (vc-backend file) '(nil CVS))) | 714 | (not (memq (vc-backend file) '(nil CVS))) |
| 728 | (if (fboundp 'vc-state) | 715 | (if (fboundp 'vc-state) |
| 729 | (and | 716 | (and |
| 730 | (not (memq (vc-state file) '(edited needs-merge))) | 717 | (not (memq (vc-state file) '(edited needs-merge))) |
| 731 | (not (stringp (vc-state file)))) | 718 | (not (stringp (vc-state file)))) |
| 732 | ;; XEmacs has no vc-state | 719 | ;; XEmacs has no vc-state |
| 733 | (not (vc-locking-user file))) | 720 | (if (featurep 'xemacs)(not (vc-locking-user file)))) |
| 734 | )) | 721 | )) |
| 735 | 722 | ||
| 736 | ;; checkout if visited file is checked in | 723 | ;; checkout if visited file is checked in |
| @@ -787,7 +774,7 @@ | |||
| 787 | (setq viper-replace-overlay (viper-make-overlay beg end (current-buffer))) | 774 | (setq viper-replace-overlay (viper-make-overlay beg end (current-buffer))) |
| 788 | ;; never detach | 775 | ;; never detach |
| 789 | (viper-overlay-put | 776 | (viper-overlay-put |
| 790 | viper-replace-overlay (if viper-emacs-p 'evaporate 'detachable) nil) | 777 | viper-replace-overlay (if (featurep 'emacs) 'evaporate 'detachable) nil) |
| 791 | (viper-overlay-put | 778 | (viper-overlay-put |
| 792 | viper-replace-overlay 'priority viper-replace-overlay-priority) | 779 | viper-replace-overlay 'priority viper-replace-overlay-priority) |
| 793 | ;; If Emacs will start supporting overlay maps, as it currently supports | 780 | ;; If Emacs will start supporting overlay maps, as it currently supports |
| @@ -795,7 +782,7 @@ | |||
| 795 | ;; just have keymap attached to replace overlay. | 782 | ;; just have keymap attached to replace overlay. |
| 796 | ;;(viper-overlay-put | 783 | ;;(viper-overlay-put |
| 797 | ;; viper-replace-overlay | 784 | ;; viper-replace-overlay |
| 798 | ;; (if viper-xemacs-p 'keymap 'local-map) | 785 | ;; (if (featurep 'xemacs) 'keymap 'local-map) |
| 799 | ;; viper-replace-map) | 786 | ;; viper-replace-map) |
| 800 | ) | 787 | ) |
| 801 | (if (viper-has-face-support-p) | 788 | (if (viper-has-face-support-p) |
| @@ -811,8 +798,8 @@ | |||
| 811 | (viper-set-replace-overlay (point-min) (point-min))) | 798 | (viper-set-replace-overlay (point-min) (point-min))) |
| 812 | (if (or (not (viper-has-face-support-p)) | 799 | (if (or (not (viper-has-face-support-p)) |
| 813 | viper-use-replace-region-delimiters) | 800 | viper-use-replace-region-delimiters) |
| 814 | (let ((before-name (if viper-xemacs-p 'begin-glyph 'before-string)) | 801 | (let ((before-name (if (featurep 'xemacs) 'begin-glyph 'before-string)) |
| 815 | (after-name (if viper-xemacs-p 'end-glyph 'after-string))) | 802 | (after-name (if (featurep 'xemacs) 'end-glyph 'after-string))) |
| 816 | (viper-overlay-put viper-replace-overlay before-name before-glyph) | 803 | (viper-overlay-put viper-replace-overlay before-name before-glyph) |
| 817 | (viper-overlay-put viper-replace-overlay after-name after-glyph)))) | 804 | (viper-overlay-put viper-replace-overlay after-name after-glyph)))) |
| 818 | 805 | ||
| @@ -843,11 +830,11 @@ | |||
| 843 | ;; never detach | 830 | ;; never detach |
| 844 | (viper-overlay-put | 831 | (viper-overlay-put |
| 845 | viper-minibuffer-overlay | 832 | viper-minibuffer-overlay |
| 846 | (if viper-emacs-p 'evaporate 'detachable) | 833 | (if (featurep 'emacs) 'evaporate 'detachable) |
| 847 | nil) | 834 | nil) |
| 848 | ;; make viper-minibuffer-overlay open-ended | 835 | ;; make viper-minibuffer-overlay open-ended |
| 849 | ;; In emacs, it is made open ended at creation time | 836 | ;; In emacs, it is made open ended at creation time |
| 850 | (if viper-xemacs-p | 837 | (if (featurep 'xemacs) |
| 851 | (progn | 838 | (progn |
| 852 | (viper-overlay-put viper-minibuffer-overlay 'start-open nil) | 839 | (viper-overlay-put viper-minibuffer-overlay 'start-open nil) |
| 853 | (viper-overlay-put viper-minibuffer-overlay 'end-open nil))) | 840 | (viper-overlay-put viper-minibuffer-overlay 'end-open nil))) |
| @@ -860,7 +847,7 @@ | |||
| 860 | (if (fboundp 'minibuffer-prompt-end) (minibuffer-prompt-end) 1) | 847 | (if (fboundp 'minibuffer-prompt-end) (minibuffer-prompt-end) 1) |
| 861 | (1+ (buffer-size))) | 848 | (1+ (buffer-size))) |
| 862 | (setq viper-minibuffer-overlay | 849 | (setq viper-minibuffer-overlay |
| 863 | (if viper-xemacs-p | 850 | (if (featurep 'xemacs) |
| 864 | (viper-make-overlay 1 (1+ (buffer-size)) (current-buffer)) | 851 | (viper-make-overlay 1 (1+ (buffer-size)) (current-buffer)) |
| 865 | ;; make overlay open-ended | 852 | ;; make overlay open-ended |
| 866 | (viper-make-overlay | 853 | (viper-make-overlay |
| @@ -983,7 +970,7 @@ | |||
| 983 | (defun viper-read-key-sequence (prompt &optional continue-echo) | 970 | (defun viper-read-key-sequence (prompt &optional continue-echo) |
| 984 | (let (inhibit-quit event keyseq) | 971 | (let (inhibit-quit event keyseq) |
| 985 | (setq keyseq (read-key-sequence prompt continue-echo)) | 972 | (setq keyseq (read-key-sequence prompt continue-echo)) |
| 986 | (setq event (if viper-xemacs-p | 973 | (setq event (if (featurep 'xemacs) |
| 987 | (elt keyseq 0) ; XEmacs returns vector of events | 974 | (elt keyseq 0) ; XEmacs returns vector of events |
| 988 | (elt (listify-key-sequence keyseq) 0))) | 975 | (elt (listify-key-sequence keyseq) 0))) |
| 989 | (if (viper-ESC-event-p event) | 976 | (if (viper-ESC-event-p event) |
| @@ -1078,7 +1065,7 @@ | |||
| 1078 | 1065 | ||
| 1079 | (defun viper-key-to-emacs-key (key) | 1066 | (defun viper-key-to-emacs-key (key) |
| 1080 | (let (key-name char-p modifiers mod-char-list base-key base-key-name) | 1067 | (let (key-name char-p modifiers mod-char-list base-key base-key-name) |
| 1081 | (cond (viper-xemacs-p key) | 1068 | (cond ((featurep 'xemacs) key) |
| 1082 | 1069 | ||
| 1083 | ((symbolp key) | 1070 | ((symbolp key) |
| 1084 | (setq key-name (symbol-name key)) | 1071 | (setq key-name (symbol-name key)) |
| @@ -1086,10 +1073,10 @@ | |||
| 1086 | (string-to-char key-name)) | 1073 | (string-to-char key-name)) |
| 1087 | ;; Emacs doesn't recognize `return' and `escape' as events on | 1074 | ;; Emacs doesn't recognize `return' and `escape' as events on |
| 1088 | ;; dumb terminals, so we translate them into characters | 1075 | ;; dumb terminals, so we translate them into characters |
| 1089 | ((and viper-emacs-p (not (viper-window-display-p)) | 1076 | ((and (featurep 'emacs) (not (viper-window-display-p)) |
| 1090 | (string= key-name "return")) | 1077 | (string= key-name "return")) |
| 1091 | ?\C-m) | 1078 | ?\C-m) |
| 1092 | ((and viper-emacs-p (not (viper-window-display-p)) | 1079 | ((and (featurep 'emacs) (not (viper-window-display-p)) |
| 1093 | (string= key-name "escape")) | 1080 | (string= key-name "escape")) |
| 1094 | ?\e) | 1081 | ?\e) |
| 1095 | ;; pass symbol-event as is | 1082 | ;; pass symbol-event as is |
| @@ -1123,14 +1110,15 @@ | |||
| 1123 | 1110 | ||
| 1124 | ;; LIS is assumed to be a list of events of characters | 1111 | ;; LIS is assumed to be a list of events of characters |
| 1125 | (defun viper-eventify-list-xemacs (lis) | 1112 | (defun viper-eventify-list-xemacs (lis) |
| 1126 | (mapcar | 1113 | (if (featurep 'xemacs) |
| 1127 | (lambda (elt) | 1114 | (mapcar |
| 1128 | (cond ((viper-characterp elt) (character-to-event elt)) | 1115 | (lambda (elt) |
| 1129 | ((eventp elt) elt) | 1116 | (cond ((viper-characterp elt) (character-to-event elt)) |
| 1130 | (t (error | 1117 | ((eventp elt) elt) |
| 1131 | "viper-eventify-list-xemacs: can't convert to event, %S" | 1118 | (t (error |
| 1132 | elt)))) | 1119 | "viper-eventify-list-xemacs: can't convert to event, %S" |
| 1133 | lis)) | 1120 | elt)))) |
| 1121 | lis))) | ||
| 1134 | 1122 | ||
| 1135 | 1123 | ||
| 1136 | ;; Smoothes out the difference between Emacs' unread-command-events | 1124 | ;; Smoothes out the difference between Emacs' unread-command-events |
| @@ -1142,7 +1130,7 @@ | |||
| 1142 | ;; into an event. Below, we delete nil from event lists, since nil is the most | 1130 | ;; into an event. Below, we delete nil from event lists, since nil is the most |
| 1143 | ;; common symbol that might appear in this wrong context. | 1131 | ;; common symbol that might appear in this wrong context. |
| 1144 | (defun viper-set-unread-command-events (arg) | 1132 | (defun viper-set-unread-command-events (arg) |
| 1145 | (if viper-emacs-p | 1133 | (if (featurep 'emacs) |
| 1146 | (setq | 1134 | (setq |
| 1147 | unread-command-events | 1135 | unread-command-events |
| 1148 | (let ((new-events | 1136 | (let ((new-events |
diff --git a/lisp/emulation/viper.el b/lisp/emulation/viper.el index c0118250167..65d40e8bad7 100644 --- a/lisp/emulation/viper.el +++ b/lisp/emulation/viper.el | |||
| @@ -690,7 +690,7 @@ It also can't undo some Viper settings." | |||
| 690 | (setq default-major-mode | 690 | (setq default-major-mode |
| 691 | (viper-standard-value 'default-major-mode viper-saved-non-viper-variables)) | 691 | (viper-standard-value 'default-major-mode viper-saved-non-viper-variables)) |
| 692 | 692 | ||
| 693 | (if viper-emacs-p | 693 | (if (featurep 'emacs) |
| 694 | (setq-default | 694 | (setq-default |
| 695 | mark-even-if-inactive | 695 | mark-even-if-inactive |
| 696 | (viper-standard-value | 696 | (viper-standard-value |
| @@ -701,7 +701,7 @@ It also can't undo some Viper settings." | |||
| 701 | (and (fboundp 'add-to-ordered-list) (boundp 'emulation-mode-map-alists)) | 701 | (and (fboundp 'add-to-ordered-list) (boundp 'emulation-mode-map-alists)) |
| 702 | (viper-delocalize-var 'minor-mode-map-alist)) | 702 | (viper-delocalize-var 'minor-mode-map-alist)) |
| 703 | (viper-delocalize-var 'require-final-newline) | 703 | (viper-delocalize-var 'require-final-newline) |
| 704 | (if viper-xemacs-p (viper-delocalize-var 'bar-cursor)) | 704 | (if (featurep 'xemacs) (viper-delocalize-var 'bar-cursor)) |
| 705 | 705 | ||
| 706 | 706 | ||
| 707 | ;; deactivate all advices done by Viper. | 707 | ;; deactivate all advices done by Viper. |
| @@ -788,7 +788,7 @@ It also can't undo some Viper settings." | |||
| 788 | ;; In emacs, we have to advice handle-switch-frame | 788 | ;; In emacs, we have to advice handle-switch-frame |
| 789 | ;; This advice is undone earlier, when all advices matchine "viper-" are | 789 | ;; This advice is undone earlier, when all advices matchine "viper-" are |
| 790 | ;; deactivated. | 790 | ;; deactivated. |
| 791 | (if viper-xemacs-p | 791 | (if (featurep 'xemacs) |
| 792 | (remove-hook 'mouse-leave-frame-hook 'viper-remember-current-frame)) | 792 | (remove-hook 'mouse-leave-frame-hook 'viper-remember-current-frame)) |
| 793 | ) ; end viper-go-away | 793 | ) ; end viper-go-away |
| 794 | 794 | ||
| @@ -981,7 +981,7 @@ It also can't undo some Viper settings." | |||
| 981 | ))) | 981 | ))) |
| 982 | 982 | ||
| 983 | ;; International input methods | 983 | ;; International input methods |
| 984 | (if viper-emacs-p | 984 | (if (featurep 'emacs) |
| 985 | (eval-after-load "mule-cmds" | 985 | (eval-after-load "mule-cmds" |
| 986 | '(progn | 986 | '(progn |
| 987 | (defadvice inactivate-input-method (after viper-mule-advice activate) | 987 | (defadvice inactivate-input-method (after viper-mule-advice activate) |
| @@ -1022,7 +1022,7 @@ It also can't undo some Viper settings." | |||
| 1022 | require-final-newline t) | 1022 | require-final-newline t) |
| 1023 | 1023 | ||
| 1024 | ;; don't bark when mark is inactive | 1024 | ;; don't bark when mark is inactive |
| 1025 | (if viper-emacs-p | 1025 | (if (featurep 'emacs) |
| 1026 | (setq mark-even-if-inactive t)) | 1026 | (setq mark-even-if-inactive t)) |
| 1027 | 1027 | ||
| 1028 | (setq scroll-step 1) | 1028 | (setq scroll-step 1) |
| @@ -1094,12 +1094,12 @@ It also can't undo some Viper settings." | |||
| 1094 | "Use `read-file-name' for reading arguments." | 1094 | "Use `read-file-name' for reading arguments." |
| 1095 | (interactive (cons (read-file-name "Find file: " nil default-directory) | 1095 | (interactive (cons (read-file-name "Find file: " nil default-directory) |
| 1096 | ;; XEmacs: if Mule & prefix arg, ask for coding system | 1096 | ;; XEmacs: if Mule & prefix arg, ask for coding system |
| 1097 | (cond ((and viper-xemacs-p (featurep 'mule)) | 1097 | (cond ((and (featurep 'xemacs) (featurep 'mule)) |
| 1098 | (list | 1098 | (list |
| 1099 | (and current-prefix-arg | 1099 | (and current-prefix-arg |
| 1100 | (read-coding-system "Coding-system: ")))) | 1100 | (read-coding-system "Coding-system: ")))) |
| 1101 | ;; Emacs: do wildcards | 1101 | ;; Emacs: do wildcards |
| 1102 | ((and viper-emacs-p (boundp 'find-file-wildcards)) | 1102 | ((and (featurep 'emacs) (boundp 'find-file-wildcards)) |
| 1103 | (list find-file-wildcards)))) | 1103 | (list find-file-wildcards)))) |
| 1104 | )) | 1104 | )) |
| 1105 | 1105 | ||
| @@ -1108,12 +1108,12 @@ It also can't undo some Viper settings." | |||
| 1108 | (interactive (cons (read-file-name "Find file in other window: " | 1108 | (interactive (cons (read-file-name "Find file in other window: " |
| 1109 | nil default-directory) | 1109 | nil default-directory) |
| 1110 | ;; XEmacs: if Mule & prefix arg, ask for coding system | 1110 | ;; XEmacs: if Mule & prefix arg, ask for coding system |
| 1111 | (cond ((and viper-xemacs-p (featurep 'mule)) | 1111 | (cond ((and (featurep 'xemacs) (featurep 'mule)) |
| 1112 | (list | 1112 | (list |
| 1113 | (and current-prefix-arg | 1113 | (and current-prefix-arg |
| 1114 | (read-coding-system "Coding-system: ")))) | 1114 | (read-coding-system "Coding-system: ")))) |
| 1115 | ;; Emacs: do wildcards | 1115 | ;; Emacs: do wildcards |
| 1116 | ((and viper-emacs-p (boundp 'find-file-wildcards)) | 1116 | ((and (featurep 'emacs) (boundp 'find-file-wildcards)) |
| 1117 | (list find-file-wildcards)))) | 1117 | (list find-file-wildcards)))) |
| 1118 | )) | 1118 | )) |
| 1119 | 1119 | ||
| @@ -1123,12 +1123,12 @@ It also can't undo some Viper settings." | |||
| 1123 | (interactive (cons (read-file-name "Find file in other frame: " | 1123 | (interactive (cons (read-file-name "Find file in other frame: " |
| 1124 | nil default-directory) | 1124 | nil default-directory) |
| 1125 | ;; XEmacs: if Mule & prefix arg, ask for coding system | 1125 | ;; XEmacs: if Mule & prefix arg, ask for coding system |
| 1126 | (cond ((and viper-xemacs-p (featurep 'mule)) | 1126 | (cond ((and (featurep 'xemacs) (featurep 'mule)) |
| 1127 | (list | 1127 | (list |
| 1128 | (and current-prefix-arg | 1128 | (and current-prefix-arg |
| 1129 | (read-coding-system "Coding-system: ")))) | 1129 | (read-coding-system "Coding-system: ")))) |
| 1130 | ;; Emacs: do wildcards | 1130 | ;; Emacs: do wildcards |
| 1131 | ((and viper-emacs-p (boundp 'find-file-wildcards)) | 1131 | ((and (featurep 'emacs) (boundp 'find-file-wildcards)) |
| 1132 | (list find-file-wildcards)))) | 1132 | (list find-file-wildcards)))) |
| 1133 | )) | 1133 | )) |
| 1134 | 1134 | ||
| @@ -1159,7 +1159,7 @@ It also can't undo some Viper settings." | |||
| 1159 | 1159 | ||
| 1160 | ;; catch frame switching event | 1160 | ;; catch frame switching event |
| 1161 | (if (viper-window-display-p) | 1161 | (if (viper-window-display-p) |
| 1162 | (if viper-xemacs-p | 1162 | (if (featurep 'xemacs) |
| 1163 | (add-hook 'mouse-leave-frame-hook | 1163 | (add-hook 'mouse-leave-frame-hook |
| 1164 | 'viper-remember-current-frame) | 1164 | 'viper-remember-current-frame) |
| 1165 | (defadvice handle-switch-frame (before viper-frame-advice activate) | 1165 | (defadvice handle-switch-frame (before viper-frame-advice activate) |
| @@ -1227,7 +1227,7 @@ These two lines must come in the order given. | |||
| 1227 | (cons 'mode-line-buffer-identification | 1227 | (cons 'mode-line-buffer-identification |
| 1228 | (list (default-value 'mode-line-buffer-identification))) | 1228 | (list (default-value 'mode-line-buffer-identification))) |
| 1229 | (cons 'global-mode-string (list global-mode-string)) | 1229 | (cons 'global-mode-string (list global-mode-string)) |
| 1230 | (if viper-emacs-p | 1230 | (if (featurep 'emacs) |
| 1231 | (cons 'mark-even-if-inactive (list mark-even-if-inactive))) | 1231 | (cons 'mark-even-if-inactive (list mark-even-if-inactive))) |
| 1232 | ))) | 1232 | ))) |
| 1233 | 1233 | ||
diff --git a/lisp/progmodes/fortran.el b/lisp/progmodes/fortran.el index 01c4c09c954..43cb61cba6b 100644 --- a/lisp/progmodes/fortran.el +++ b/lisp/progmodes/fortran.el | |||
| @@ -59,7 +59,8 @@ | |||
| 59 | (defvar gud-find-expr-function) | 59 | (defvar gud-find-expr-function) |
| 60 | (defvar imenu-case-fold-search) | 60 | (defvar imenu-case-fold-search) |
| 61 | (defvar imenu-syntax-alist) | 61 | (defvar imenu-syntax-alist) |
| 62 | 62 | (defvar comment-region-function) | |
| 63 | (defvar uncomment-region-function) | ||
| 63 | 64 | ||
| 64 | (defgroup fortran nil | 65 | (defgroup fortran nil |
| 65 | "Major mode for editing fixed format Fortran code." | 66 | "Major mode for editing fixed format Fortran code." |
diff --git a/lisp/vc.el b/lisp/vc.el index 1bc6aac856d..474c41c30ae 100644 --- a/lisp/vc.el +++ b/lisp/vc.el | |||
| @@ -1930,9 +1930,7 @@ returns t if the buffer had changes, nil otherwise." | |||
| 1930 | (message "No changes between %s and %s" rev1-name rev2-name) | 1930 | (message "No changes between %s and %s" rev1-name rev2-name) |
| 1931 | nil) | 1931 | nil) |
| 1932 | (pop-to-buffer (current-buffer)) | 1932 | (pop-to-buffer (current-buffer)) |
| 1933 | ;; Gnus-5.8.5 sets up an autoload for diff-mode, even if it's | 1933 | (diff-mode) |
| 1934 | ;; not available. Work around that. | ||
| 1935 | (if (require 'diff-mode nil t) (diff-mode)) | ||
| 1936 | (vc-exec-after `(vc-diff-sentinel ,verbose ,rev1-name ,rev2-name)) | 1934 | (vc-exec-after `(vc-diff-sentinel ,verbose ,rev1-name ,rev2-name)) |
| 1937 | ;; In the async case, we return t even if there are no differences | 1935 | ;; In the async case, we return t even if there are no differences |
| 1938 | ;; because we don't know that yet. | 1936 | ;; because we don't know that yet. |