Mercurial > emacs
comparison lisp/textmodes/ispell.el @ 65834:153b746cc2d0
(ispell-word, ispell-region): Call ispell-maybe-find-aspell-dictionaries.
(ispell-accept-buffer-local-defs):
Don't call ispell-maybe-find-aspell-dictionaries
author | Richard M. Stallman <rms@gnu.org> |
---|---|
date | Tue, 04 Oct 2005 20:28:27 +0000 |
parents | e30aec38a95e |
children | 252e6b444949 aa89c814f853 |
comparison
equal
deleted
inserted
replaced
65833:fca34be2db31 | 65834:153b746cc2d0 |
---|---|
1555 quit spell session exited." | 1555 quit spell session exited." |
1556 | 1556 |
1557 (interactive (list ispell-following-word ispell-quietly current-prefix-arg)) | 1557 (interactive (list ispell-following-word ispell-quietly current-prefix-arg)) |
1558 (if continue | 1558 (if continue |
1559 (ispell-continue) | 1559 (ispell-continue) |
1560 (ispell-maybe-find-aspell-dictionaries) | |
1560 (ispell-accept-buffer-local-defs) ; use the correct dictionary | 1561 (ispell-accept-buffer-local-defs) ; use the correct dictionary |
1561 (let ((cursor-location (point)) ; retain cursor location | 1562 (let ((cursor-location (point)) ; retain cursor location |
1562 (word (ispell-get-word following)) | 1563 (word (ispell-get-word following)) |
1563 start end poss new-word replace) | 1564 start end poss new-word replace) |
1564 ;; De-structure return word info list. | 1565 ;; De-structure return word info list. |
2613 (defun ispell-region (reg-start reg-end &optional recheckp shift) | 2614 (defun ispell-region (reg-start reg-end &optional recheckp shift) |
2614 "Interactively check a region for spelling errors. | 2615 "Interactively check a region for spelling errors. |
2615 Return nil if spell session is quit, | 2616 Return nil if spell session is quit, |
2616 otherwise returns shift offset amount for last line processed." | 2617 otherwise returns shift offset amount for last line processed." |
2617 (interactive "r") ; Don't flag errors on read-only bufs. | 2618 (interactive "r") ; Don't flag errors on read-only bufs. |
2619 (ispell-maybe-find-aspell-dictionaries) | |
2618 (if (not recheckp) | 2620 (if (not recheckp) |
2619 (ispell-accept-buffer-local-defs)) ; set up dictionary, local words, etc. | 2621 (ispell-accept-buffer-local-defs)) ; set up dictionary, local words, etc. |
2620 (let ((skip-region-start (make-marker)) | 2622 (let ((skip-region-start (make-marker)) |
2621 (rstart (make-marker))) | 2623 (rstart (make-marker))) |
2622 (unwind-protect | 2624 (unwind-protect |
3574 ;;; ********************************************************************** | 3576 ;;; ********************************************************************** |
3575 | 3577 |
3576 | 3578 |
3577 (defun ispell-accept-buffer-local-defs () | 3579 (defun ispell-accept-buffer-local-defs () |
3578 "Load all buffer-local information, restarting Ispell when necessary." | 3580 "Load all buffer-local information, restarting Ispell when necessary." |
3579 (ispell-maybe-find-aspell-dictionaries) | |
3580 (ispell-buffer-local-dict) ; May kill ispell-process. | 3581 (ispell-buffer-local-dict) ; May kill ispell-process. |
3581 (ispell-buffer-local-words) ; Will initialize ispell-process. | 3582 (ispell-buffer-local-words) ; Will initialize ispell-process. |
3582 (ispell-buffer-local-parsing)) | 3583 (ispell-buffer-local-parsing)) |
3583 | 3584 |
3584 | 3585 |