Mercurial > emacs
comparison lisp/international/quail.el @ 23172:a47eab4fc085
(quail-choose-completion-string): Store
completion `choice' in `quail-current-str'; don't insert it.
author | Kenichi Handa <handa@m17n.org> |
---|---|
date | Thu, 03 Sep 1998 11:10:40 +0000 |
parents | ddc2fa7883d6 |
children | 3852eb64cf0e |
comparison
equal
deleted
inserted
replaced
23171:79e077f57e7c | 23172:a47eab4fc085 |
---|---|
1767 (if (and (string-match "\\` \\*Minibuf-[0-9]+\\*\\'" (buffer-name buffer)) | 1767 (if (and (string-match "\\` \\*Minibuf-[0-9]+\\*\\'" (buffer-name buffer)) |
1768 (or (not (active-minibuffer-window)) | 1768 (or (not (active-minibuffer-window)) |
1769 (not (equal buffer | 1769 (not (equal buffer |
1770 (window-buffer (active-minibuffer-window)))))) | 1770 (window-buffer (active-minibuffer-window)))))) |
1771 (quail-error "Minibuffer is not active for completion") | 1771 (quail-error "Minibuffer is not active for completion") |
1772 ;; Insert the completion into the buffer where completion was requested. | 1772 ;; Store the completion in `quail-current-str', which will later |
1773 ;; be converted to a character event list, then inserted into | |
1774 ;; the buffer where completion was requested. | |
1773 (set-buffer buffer) | 1775 (set-buffer buffer) |
1774 ; (if base-size | 1776 ; (if base-size |
1775 ; (delete-region (+ base-size (point-min)) (point)) | 1777 ; (delete-region (+ base-size (point-min)) (point)) |
1776 ; (choose-completion-delete-max-match choice)) | 1778 ; (choose-completion-delete-max-match choice)) |
1777 (insert choice) | 1779 (setq quail-current-str choice) |
1778 (remove-text-properties (- (point) (length choice)) (point) | |
1779 '(mouse-face nil)) | |
1780 ;; Update point in the window that BUFFER is showing in. | 1780 ;; Update point in the window that BUFFER is showing in. |
1781 (let ((window (get-buffer-window buffer t))) | 1781 (let ((window (get-buffer-window buffer t))) |
1782 (set-window-point window (point))) | 1782 (set-window-point window (point))) |
1783 ;; If completing for the minibuffer, exit it with this choice. | 1783 ;; If completing for the minibuffer, exit it with this choice. |
1784 (and (not completion-no-auto-exit) | 1784 (and (not completion-no-auto-exit) |