aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard M. Stallman1993-07-31 05:31:58 +0000
committerRichard M. Stallman1993-07-31 05:31:58 +0000
commit49e61c42679385a7dca711a56b67c426e95417cf (patch)
treea97eb9bdb447643e7a6737858f80e2e5aca6a9f2
parent8686888e2c3ac0bb432e4d126d1e01967ac5f74b (diff)
downloademacs-49e61c42679385a7dca711a56b67c426e95417cf.tar.gz
emacs-49e61c42679385a7dca711a56b67c426e95417cf.zip
(mouse-choose-completion): Actually choose that alternative,
don't just insert its name.
-rw-r--r--lisp/mouse.el4
1 files changed, 3 insertions, 1 deletions
diff --git a/lisp/mouse.el b/lisp/mouse.el
index b3ce6da6688..904227727e9 100644
--- a/lisp/mouse.el
+++ b/lisp/mouse.el
@@ -843,6 +843,7 @@ and selects that window."
843;; Choose a completion with the mouse. 843;; Choose a completion with the mouse.
844 844
845(defun mouse-choose-completion (event) 845(defun mouse-choose-completion (event)
846 "Click on an alternative in the `*Completions*' buffer to choose it."
846 (interactive "e") 847 (interactive "e")
847 (let (choice) 848 (let (choice)
848 (save-excursion 849 (save-excursion
@@ -861,7 +862,8 @@ and selects that window."
861 (not (string= tail (substring choice 0 (length tail)))))) 862 (not (string= tail (substring choice 0 (length tail))))))
862 (forward-char 1)) 863 (forward-char 1))
863 (insert choice) 864 (insert choice)
864 (delete-region (point) (point-max))))) 865 (delete-region (point) (point-max))
866 (minibuffer-complete-and-exit))))
865 867
866;; Font selection. 868;; Font selection.
867 869