comparison lisp/international/mule-cmds.el @ 19748:06cbad2e806a

(read-input-method-name): Specify the input history properly. (select-input-method): Improve prompt.
author Richard M. Stallman <rms@gnu.org>
date Thu, 04 Sep 1997 05:54:38 +0000
parents 2ee3950b5a35
children da913efb39cf
comparison
equal deleted inserted replaced
19747:bed06df9cbc5 19748:06cbad2e806a
446 (if default 446 (if default
447 (setq prompt (format prompt default))) 447 (setq prompt (format prompt default)))
448 (let* ((completion-ignore-case t) 448 (let* ((completion-ignore-case t)
449 ;; This binding is necessary because input-method-history is 449 ;; This binding is necessary because input-method-history is
450 ;; buffer local. 450 ;; buffer local.
451 (minibuffer-history input-method-history)
452 (input-method (completing-read prompt input-method-alist 451 (input-method (completing-read prompt input-method-alist
453 nil t nil nil default))) 452 nil t nil 'input-method-history
453 default)))
454 (if (> (length input-method) 0) 454 (if (> (length input-method) 0)
455 input-method 455 input-method
456 (if inhibit-null 456 (if inhibit-null
457 (error "No valid input method is specified"))))) 457 (error "No valid input method is specified")))))
458 458
496 (interactive 496 (interactive
497 (let* ((default (or (car input-method-history) default-input-method))) 497 (let* ((default (or (car input-method-history) default-input-method)))
498 (if (not enable-multibyte-characters) 498 (if (not enable-multibyte-characters)
499 (error "Can't activate an input method while multibyte characters are disabled")) 499 (error "Can't activate an input method while multibyte characters are disabled"))
500 (list (read-input-method-name 500 (list (read-input-method-name
501 (if default "Input method (default %s): " "Input method: ") 501 (if default "Select input method (default %s): " "Select input method: ")
502 default t)))) 502 default t))))
503 (activate-input-method input-method) 503 (activate-input-method input-method)
504 (setq default-input-method input-method)) 504 (setq default-input-method input-method))
505 505
506 (defun toggle-input-method (&optional arg) 506 (defun toggle-input-method (&optional arg)