aboutsummaryrefslogtreecommitdiffstats
path: root/lisp
diff options
context:
space:
mode:
authorChong Yidong <[email protected]>2010-02-16 09:23:44 -0500
committerChong Yidong <[email protected]>2010-02-16 09:23:44 -0500
commit05bbe066a68442dca234abb2c2f479bb0c2a293f (patch)
tree5e2b415f65a498aa69e2b9bf663437abf9dc8112 /lisp
parentf1e0d763624b7aaecde07611cbe33d189901665b (diff)
* textmodes/flyspell.el (flyspell-word): Obey the offset specified
by ispell-parse-output (Bug#5575).
Diffstat (limited to 'lisp')
-rw-r--r--lisp/ChangeLog5
-rw-r--r--lisp/textmodes/flyspell.el9
2 files changed, 12 insertions, 2 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 0dbc97c0df..92ae206d10 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,8 @@
+2010-02-16 Chong Yidong <[email protected]>
+
+ * textmodes/flyspell.el (flyspell-word): Obey the offset specified
+ by ispell-parse-output (Bug#5575).
+
2010-02-16 Kenichi Handa <[email protected]>
* international/ja-dic-cnv.el (iso-2022-7bit-short): Delete it.
diff --git a/lisp/textmodes/flyspell.el b/lisp/textmodes/flyspell.el
index 612f83123b..ee7a52a109 100644
--- a/lisp/textmodes/flyspell.el
+++ b/lisp/textmodes/flyspell.el
@@ -1155,10 +1155,15 @@ than preceding) word when the cursor is not over a word."
nil)
(t
(setq flyspell-word-cache-result nil)
- ;; incorrect highlight the location
+ ;; Highlight the location as incorrect,
+ ;; including offset specified in POSS.
(if flyspell-highlight-flag
(flyspell-highlight-incorrect-region
- start end poss)
+ (if (and (consp poss)
+ (integerp (nth 1 poss)))
+ (+ start (nth 1 poss) -1)
+ start)
+ end poss)
(flyspell-notify-misspell word poss))
nil))))
;; return to original location