Mercurial > emacs
comparison lisp/emulation/viper-mous.el @ 85972:51aa47312c4b
* 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.
author | Dan Nicolaescu <dann@ics.uci.edu> |
---|---|
date | Fri, 09 Nov 2007 05:20:57 +0000 |
parents | ac0efac52065 |
children | a5a206b3f518 880960b70474 |
comparison
equal
deleted
inserted
replaced
85971:2e692f327278 | 85972:51aa47312c4b |
---|---|
77 :group 'viper-mouse) | 77 :group 'viper-mouse) |
78 | 78 |
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) |
86 "*Time interval in millisecond within which successive mouse clicks are | 86 "*Time interval in millisecond within which successive mouse clicks are |
87 considered related." | 87 considered related." |
225 | 225 |
226 (setq result (buffer-substring word-beg (point)))) | 226 (setq result (buffer-substring word-beg (point)))) |
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 )) |
234 | 234 |
235 | 235 |
271 (if (save-excursion | 271 (if (save-excursion |
272 (or (not (eq (key-binding viper-mouse-down-insert-key-parsed) | 272 (or (not (eq (key-binding viper-mouse-down-insert-key-parsed) |
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) |
280 ;; prefix arg is a list when one hits C-u then command | 280 ;; prefix arg is a list when one hits C-u then command |
281 ((and (listp arg) (integerp (car arg))) | 281 ((and (listp arg) (integerp (car arg))) |
362 (if (save-excursion | 362 (if (save-excursion |
363 (or (not (eq (key-binding viper-mouse-down-search-key-parsed) | 363 (or (not (eq (key-binding viper-mouse-down-search-key-parsed) |
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) |
371 | 371 |
372 (if (and | 372 (if (and |
505 (if (null key) | 505 (if (null key) |
506 ;; just return nil | 506 ;; just return nil |
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) |
526 'button3up 'button3))) | 526 'button3up 'button3))) |
527 (t (error | 527 (t (error |
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 |
546 control-spec meta-spec shift-spec button-spec))) | 546 control-spec meta-spec shift-spec button-spec))) |
547 (vector | 547 (vector |