aboutsummaryrefslogtreecommitdiffstats
path: root/lisp/textmodes
diff options
context:
space:
mode:
Diffstat (limited to 'lisp/textmodes')
-rw-r--r--lisp/textmodes/ispell.el17
1 files changed, 14 insertions, 3 deletions
diff --git a/lisp/textmodes/ispell.el b/lisp/textmodes/ispell.el
index c88b32f64cc..94eb721e4cf 100644
--- a/lisp/textmodes/ispell.el
+++ b/lisp/textmodes/ispell.el
@@ -2630,11 +2630,22 @@ Keeps argument list for future ispell invocations for no async support."
2630 (or ispell-local-dictionary ispell-dictionary "default")) 2630 (or ispell-local-dictionary ispell-dictionary "default"))
2631 (sit-for 0) 2631 (sit-for 0)
2632 (setq ispell-library-directory (ispell-check-version) 2632 (setq ispell-library-directory (ispell-check-version)
2633 ispell-process-directory default-directory
2634 ispell-process (ispell-start-process) 2633 ispell-process (ispell-start-process)
2635 ispell-filter nil 2634 ispell-filter nil
2636 ispell-filter-continue nil 2635 ispell-filter-continue nil)
2637 ispell-process-buffer-name (buffer-name)) 2636 ;; When spellchecking minibuffer contents, make sure ispell process
2637 ;; is not restarted every time the minibuffer is killed.
2638 (if (window-minibuffer-p)
2639 (if (fboundp 'minibuffer-selected-window)
2640 ;; Assign ispell process to parent buffer
2641 (setq ispell-process-directory default-directory
2642 ispell-process-buffer-name (window-buffer (minibuffer-selected-window)))
2643 ;; Force `ispell-process-directory' to $HOME and use a dummy name
2644 (setq ispell-process-directory (expand-file-name "~/")
2645 ispell-process-buffer-name " * Minibuffer-has-spellcheck-enabled"))
2646 ;; Not in a minibuffer
2647 (setq ispell-process-directory default-directory
2648 ispell-process-buffer-name (buffer-name)))
2638 (if ispell-async-processp 2649 (if ispell-async-processp
2639 (set-process-filter ispell-process 'ispell-filter)) 2650 (set-process-filter ispell-process 'ispell-filter))
2640 ;; protect against bogus binding of `enable-multibyte-characters' in XEmacs 2651 ;; protect against bogus binding of `enable-multibyte-characters' in XEmacs