]> git.lyx.org Git - features.git/commitdiff
fix bug 461
authorJean-Marc Lasgouttes <lasgouttes@lyx.org>
Mon, 1 Jul 2002 21:50:54 +0000 (21:50 +0000)
committerJean-Marc Lasgouttes <lasgouttes@lyx.org>
Mon, 1 Jul 2002 21:50:54 +0000 (21:50 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@4513 a592a061-630c-0410-9148-cb99ea01b6c8

development/ChangeLog
src/ChangeLog
src/text.C

index 789fbe0ce1e522ab795a444de536620b6703be42..b82dec864d72789e1f4087f91ab6af5b24f3604f 100644 (file)
@@ -1,7 +1,7 @@
-
 2002-06-26  André Pönitz <poenitz@gmx.de>
 
-       * development/Win32/lyxwin32.c: Win32 specific patch from Claus Hentschel
+       * development/Win32/lyxwin32.c: Win32 specific patch from Claus
+       Hentschel
 
 2002-06-05  Jean-Marc Lasgouttes  <lasgouttes@freesurf.fr>
 
index 7f253e82b43df997d0a59264931ef7d6fc732cd3..bd1e2c821a533e80fa85190f3746bb47b84b3e9d 100644 (file)
@@ -1,3 +1,8 @@
+2002-06-20  Jean-Marc Lasgouttes  <lasgouttes@freesurf.fr>
+
+       * text.C (changeRegionCase): do not change case of all the
+       document when region ends at paragraph end (bug #461)
+
 2002-07-01  Jean-Marc Lasgouttes  <lasgouttes@freesurf.fr>
 
        * paragraph.C (startTeXParParams):
index 248919e886e86feb2180c058e42961e23738e5e6..f2582dc463eb112a7a688002ec25fdaf2791ac9b 100644 (file)
@@ -2604,6 +2604,11 @@ void LyXText::changeRegionCase(BufferView * bview,
        Paragraph * par = from.par();
 
        while (par && (pos != to.pos() || par != to.par())) {
+               if (pos == par->size()) {
+                       par = par->next();
+                       pos = 0;
+                       continue;
+               }
                unsigned char c = par->getChar(pos);
                if (!IsInsetChar(c) && !IsHfillChar(c)) {
                        switch (action) {
@@ -2623,10 +2628,6 @@ void LyXText::changeRegionCase(BufferView * bview,
                checkParagraph(bview, par, pos);
 
                ++pos;
-               if (pos == par->size()) {
-                       par = par->next();
-                       pos = 0;
-               }
        }
        if (to.row() != from.row()) {
                refresh_y = from.y() - from.row()->baseline();