[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] Changes to emacs/lisp/textmodes/ispell.el,v
From: |
Glenn Morris |
Subject: |
[Emacs-diffs] Changes to emacs/lisp/textmodes/ispell.el,v |
Date: |
Sat, 26 Apr 2008 20:14:13 +0000 |
CVSROOT: /sources/emacs
Module name: emacs
Changes by: Glenn Morris <gm> 08/04/26 20:14:13
Index: ispell.el
===================================================================
RCS file: /sources/emacs/emacs/lisp/textmodes/ispell.el,v
retrieving revision 1.229
retrieving revision 1.230
diff -u -b -r1.229 -r1.230
--- ispell.el 26 Apr 2008 02:41:13 -0000 1.229
+++ ispell.el 26 Apr 2008 20:14:12 -0000 1.230
@@ -1528,6 +1528,16 @@
(delete-region start (point)))
(setq more-lines (= 0 (forward-line))))))))))))))
+
+;; Insert WORD while translating Latin characters to the equivalent
+;; characters that is supported by buffer-file-coding-system.
+
+(defun ispell-insert-word (word)
+ (let ((pos (point)))
+ (insert word)
+ (if (char-table-p translation-table-for-input)
+ (translate-region pos (point) translation-table-for-input))))
+
;;;###autoload
(defun ispell-word (&optional following quietly continue region)
"Check spelling of word under or before the cursor.
@@ -1637,7 +1647,7 @@
;; Insert first and then delete,
;; to avoid collapsing markers before and after
;; into a single place.
- (insert new-word)
+ (ispell-insert-word new-word)
(delete-region (point) end)
;; It is meaningless to preserve the cursor position
;; inside a word that has changed.
@@ -3068,7 +3078,7 @@
(delete-region (point) (+ word-len (point)))
(if (not (listp replace))
(progn
- (insert replace) ; insert dictionary word
+ (ispell-insert-word replace) ; insert dictionary word
(ispell-send-replacement (car poss) replace)
(setq accept-list (cons replace accept-list)))
(let ((replace-word (car replace)))
@@ -3238,7 +3248,7 @@
(setq word (if (atom replacement) replacement (car replacement))
cursor-location (+ (- (length word) (- end start))
cursor-location))
- (insert word)
+ (ispell-insert-word word)
(if (not (atom replacement)) ; recheck spelling of replacement.
(progn
(goto-char cursor-location)
- [Emacs-diffs] Changes to emacs/lisp/textmodes/ispell.el,v, Stefan Monnier, 2008/04/10
- [Emacs-diffs] Changes to emacs/lisp/textmodes/ispell.el,v, Stefan Monnier, 2008/04/23
- [Emacs-diffs] Changes to emacs/lisp/textmodes/ispell.el,v, Stefan Monnier, 2008/04/24
- [Emacs-diffs] Changes to emacs/lisp/textmodes/ispell.el,v, Glenn Morris, 2008/04/25
- [Emacs-diffs] Changes to emacs/lisp/textmodes/ispell.el,v,
Glenn Morris <=