unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* flyspell.el [1.90->1.91] flyspell-large-region-beg should be moved after good match
@ 2005-12-16 12:42 Agustin Martin
  2005-12-17  1:03 ` Richard M. Stallman
  0 siblings, 1 reply; 5+ messages in thread
From: Agustin Martin @ 2005-12-16 12:42 UTC (permalink / raw)


[-- Attachment #1: Type: text/plain, Size: 392 bytes --]

Hi,

Just noticed commit of flyspell.el 1.91 and a problem in it. In function
flyspell-external-point-words flyspell-large-region-beg is not moved
after successful match. That makes that for buffers like 

ispella
ispella
ispella

only first match is found and tagged as misspelled since all further
searches start from the same point.

I am attaching a possible patch for that,

-- 
Agustin

[-- Attachment #2: flyspell.el.fly-ext-poi-words.diff --]
[-- Type: text/plain, Size: 816 bytes --]

--- flyspell.el.orig	2005-12-16 12:10:52.000000000 +0100
+++ flyspell.el	2005-12-16 13:18:59.000000000 +0100
@@ -1334,7 +1334,8 @@
 				    flyspell-large-region-end t)
 		    (save-excursion
 		      (goto-char (- (point) 1))
-		      (let* ((flyword-prev-l (flyspell-get-word nil))
+		      (let* ((match-point (+ (point) 1))
+			     (flyword-prev-l (flyspell-get-word nil))
 			     (flyword-prev (car flyword-prev-l))
 			     (size-match (= (length flyword-prev) (length word))))
 			(when (or
@@ -1361,7 +1362,7 @@
 			  (setq keep nil)
 			  (flyspell-word)
 			  ;; Next search will begin from end of last match
-			  )))
+			  (setq flyspell-large-region-beg match-point))))
 		  ;; Record if misspelling is not found and try new one
 		  (add-to-list 'words-not-found
 			       (concat " -> " word " - "

[-- Attachment #3: Type: text/plain, Size: 142 bytes --]

_______________________________________________
Emacs-devel mailing list
Emacs-devel@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-devel

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2005-12-22 13:02 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-12-16 12:42 flyspell.el [1.90->1.91] flyspell-large-region-beg should be moved after good match Agustin Martin
2005-12-17  1:03 ` Richard M. Stallman
2005-12-19  0:41   ` Agustin Martin
2005-12-19  1:28     ` Agustin Martin
2005-12-22 13:02       ` Agustin Martin

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).