]> git.lyx.org Git - lyx.git/commitdiff
spell fix from Alfredo
authorJohn Levon <levon@movementarian.org>
Thu, 10 Apr 2003 03:04:22 +0000 (03:04 +0000)
committerJohn Levon <levon@movementarian.org>
Thu, 10 Apr 2003 03:04:22 +0000 (03:04 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@6759 a592a061-630c-0410-9148-cb99ea01b6c8

src/ChangeLog
src/text.C

index 2c89b23b39c209ad88063f36807a3231e23707d1..d73285477c3bfc6cff8c5ee4e4e7e49cc23b3d71 100644 (file)
@@ -1,3 +1,8 @@
+2003-04-09  Alfredo Braunstein  <abraunst@libero.it>
+
+       * text.C (selectNextWordToSpellcheck): don't accidentally
+       skip insets
+
 2003-04-10  John Levon  <levon@movementarian.org>
 
        * ToolbarBackend.C (getIcon): special handling for
index 98b74ffb01c43d16a02af37910e40cc9b0bea1ac..24e3c11d026335781d4f11d534345221b7a9dc12 100644 (file)
@@ -2159,13 +2159,13 @@ LyXText::selectNextWordToSpellcheck(float & value)
                        break;
                }
 
-               bool const is_bad_inset(cpit->isInset(cpos)
-                       && !cpit->getInset(cpos)->allowSpellcheck());
-
-               if (cpit->isLetter(cpos) && !isDeletedText(*cpit, cpos)
-                       && !is_bad_inset)
-                       break;
-
+               bool const is_good_inset = cpit->isInset(cpos)
+                       && cpit->getInset(cpos)->allowSpellcheck();
+  
+               if (!isDeletedText(*cpit, cpos) 
+                   && (is_good_inset || cpit->isLetter(cpos)))
+                       break;
+  
                cursor.pos(cpos + 1);
        }