]> git.lyx.org Git - lyx.git/commitdiff
change tracking:
authorMichael Schmitt <michael.schmitt@teststep.org>
Fri, 20 Oct 2006 13:16:15 +0000 (13:16 +0000)
committerMichael Schmitt <michael.schmitt@teststep.org>
Fri, 20 Oct 2006 13:16:15 +0000 (13:16 +0000)
src/lyxfind.C: some source code reformatting;
pass trackChange parameter to Paragraph::erase(..)

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15405 a592a061-630c-0410-9148-cb99ea01b6c8

src/lyxfind.C

index a48b5db8f86d838a802f0d6119503b1eb0a4bd05..f6bad4a97c9594aa9747bec2bffd4c5a1a0d6582 100644 (file)
@@ -127,8 +127,8 @@ bool findBackwards(DocIterator & cur, MatchString const & match)
 bool findChange(DocIterator & cur)
 {
        for (; cur; cur.forwardPos())
-               if (cur.inTexted() && cur.paragraph().lookupChange(cur.pos()).type
-                   != Change::UNCHANGED)
+               if (cur.inTexted() &&
+                   cur.paragraph().lookupChange(cur.pos()).type != Change::UNCHANGED)
                        return true;
        return false;
 }
@@ -185,7 +185,8 @@ int replaceAll(BufferView * bv,
                lyx::pos_type pos = cur.pos();
                LyXFont const font
                        = cur.paragraph().getFontSettings(buf.params(), pos);
-               int striked = ssize - cur.paragraph().erase(pos, pos + ssize);
+               int striked = ssize - cur.paragraph().erase(pos, pos + ssize,
+                                                           buf.params().trackChanges);
                cur.paragraph().insert(pos, replacestr, font,
                                       Change(buf.params().trackChanges ?
                                              Change::INSERTED : Change::UNCHANGED));