Mercurial > emacs
comparison lisp/international/quail.el @ 99198:96652546aa33
(quail-show-guidance): Don't create a guidance-frame if current buffer is
not a minibuffer, since even if selected-window is mini-p, the buffer will
never be displayed in it, so it wil be usable for guidance.
author | Stefan Monnier <monnier@iro.umontreal.ca> |
---|---|
date | Wed, 29 Oct 2008 01:44:45 +0000 |
parents | bb607b812d23 |
children | 042c1d530bbd |
comparison
equal
deleted
inserted
replaced
99197:7548cef42245 | 99198:96652546aa33 |
---|---|
229 name)) | 229 name)) |
230 | 230 |
231 ;;;###autoload | 231 ;;;###autoload |
232 (defun quail-use-package (package-name &rest libraries) | 232 (defun quail-use-package (package-name &rest libraries) |
233 "Start using Quail package PACKAGE-NAME. | 233 "Start using Quail package PACKAGE-NAME. |
234 The remaining arguments are libraries to be loaded before using the package. | 234 The remaining arguments are LIBRARIES to be loaded before using the package. |
235 | 235 |
236 This activates input method defined by PACKAGE-NAME by running | 236 This activates input method defined by PACKAGE-NAME by running |
237 `quail-activate', which see." | 237 `quail-activate', which see." |
238 (let ((package (quail-package package-name))) | 238 (let ((package (quail-package package-name))) |
239 (if (null package) | 239 (if (null package) |
543 (interactive) | 543 (interactive) |
544 (quail-activate -1)) | 544 (quail-activate -1)) |
545 | 545 |
546 (defun quail-activate (&optional arg) | 546 (defun quail-activate (&optional arg) |
547 "Activate Quail input method. | 547 "Activate Quail input method. |
548 With arg, activate Quail input method if and only if arg is positive. | 548 With ARG, activate Quail input method if and only if arg is positive. |
549 | 549 |
550 This function runs `quail-activate-hook' if it activates the input | 550 This function runs `quail-activate-hook' if it activates the input |
551 method, `quail-inactivate-hook' if it deactivates it. | 551 method, `quail-inactivate-hook' if it deactivates it. |
552 | 552 |
553 While this input method is active, the variable | 553 While this input method is active, the variable |
1972 ;; Then, show the guidance. | 1972 ;; Then, show the guidance. |
1973 (when (and (quail-require-guidance-buf) | 1973 (when (and (quail-require-guidance-buf) |
1974 (not input-method-use-echo-area) | 1974 (not input-method-use-echo-area) |
1975 (null unread-command-events) | 1975 (null unread-command-events) |
1976 (null unread-post-input-method-events)) | 1976 (null unread-post-input-method-events)) |
1977 (if (eq (selected-window) (minibuffer-window)) | 1977 (if (minibufferp) |
1978 (if (eq (minibuffer-window) (frame-root-window)) | 1978 (if (eq (minibuffer-window) (frame-root-window)) |
1979 ;; Use another frame. It is sure that we are using some | 1979 ;; Use another frame. It is sure that we are using some |
1980 ;; window system. | 1980 ;; window system. |
1981 (let ((guidance quail-guidance-str)) | 1981 (let ((guidance quail-guidance-str)) |
1982 (or (frame-live-p quail-guidance-frame) | 1982 (or (frame-live-p quail-guidance-frame) |