]> git.lyx.org Git - lyx.git/commitdiff
compilation fix; audit and fix calls to cutSelection
authorJean-Marc Lasgouttes <lasgouttes@lyx.org>
Mon, 16 Jun 2003 14:21:52 +0000 (14:21 +0000)
committerJean-Marc Lasgouttes <lasgouttes@lyx.org>
Mon, 16 Jun 2003 14:21:52 +0000 (14:21 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@7174 a592a061-630c-0410-9148-cb99ea01b6c8

po/POTFILES.in
src/ChangeLog
src/insets/ChangeLog
src/insets/insettext.C
src/iterators.C
src/mathed/ChangeLog
src/mathed/formulabase.C
src/text3.C

index 0a6686e7f24ccfd849919cd8f4e5784e542cadb0..fcc49c6744bfd0f48cc43a41aa1390e426a1eca7 100644 (file)
@@ -56,6 +56,7 @@ src/frontends/qt2/QGraphics.C
 src/frontends/qt2/QInclude.C
 src/frontends/qt2/QLPrintDialog.C
 src/frontends/qt2/QLog.C
+src/frontends/qt2/QMath.C
 src/frontends/qt2/QMathDialog.C
 src/frontends/qt2/QMathMatrixDialog.C
 src/frontends/qt2/QMinipage.C
index fb04b213caa56a388bdb9b7dc66f47c5e511b355..7dc0eb2d0dfefff2552cd7beabcdc026ed9401e7 100644 (file)
@@ -1,3 +1,14 @@
+2003-06-16  Jean-Marc Lasgouttes  <lasgouttes@lyx.org>
+
+       * iterators.C (operator++, ParPosition): reintroduce some
+       const_cast for the benefit of older compilers.
+
+2003-06-13  Jean-Marc Lasgouttes  <lasgouttes@lyx.org>
+
+       * text3.C (dispatch): do not modify clipboard when doing
+       LFUN_BACKSPACE, LFUN_BACKSPACE_SKIP, LFUN_DELETE or
+       LFUN_DELETE_SKIP on a selection selection
+
 2003-06-16  André Pönitz  <poenitz@gmx.net>
 
        * BufferView.C:
        * lyxtext.h:
        * text.C: implement accept/rejectChange()
 
-       * lyxtext.h:
-       * text.C: paint changebars. Paint new/deleted text in the chosen colours.
-         Strike through deleted text.
+       * lyxtext.h: 
+       * text.C: paint changebars. Paint new/deleted text in the chosen
+       colours. Strike through deleted text.
 
        * paragraph.h:
        * paragraph.C:
        * paragraph_pimpl.h:
-       * paragraph_pimpl.C: output change markers in .lyx and .tex. Pass in the current change
-         to the insert functions. Rework erase to mark text as deleted, adding
-         an eraseIntern() and a range-based erase(). Implement
-         per-paragraph change lookup and accept/reject.
+       * paragraph_pimpl.C: output change markers in .lyx and .tex. Pass
+         in the current change to the insert functions. Rework erase to
+         mark text as deleted, adding an eraseIntern() and a range-based
+         erase(). Implement per-paragraph change lookup and
+         accept/reject.
 
        * paragraph_funcs.C: Fixup paste for change tracking.
 
        * tabular.C: mark added row/columns as new.
 
-       * text.C: fix rowLast() to never return -1. Don't allow spellchecking of deleted
-         text. Track transpose changes. Don't allow paragraph break or merge where appropriate.
+       * text.C: fix rowLast() to never return -1. Don't allow
+         spellchecking of deleted text. Track transpose changes. Don't
+         allow paragraph break or merge where appropriate.
 
        * text2.C: leave cursor at end of selection after a cut.
 
index 9cc27c1b7b794c89ab44d43ebe704fe04c8ab91d..bc7d3b7bbf15e052203189a2ccbc12969564a8f9 100644 (file)
@@ -1,3 +1,6 @@
+2003-06-13  Jean-Marc Lasgouttes  <lasgouttes@lyx.org>
+
+       * insettext.C (localDispatch): fix call to cutSelection for LFUN_CUT
 
 2003-06-16  André Pönitz  <poenitz@gmx.net>
 
index 897fe7ec615bc957d5e3a5ba0c34d5d94d96cad0..027049eac0d7bcb55d52adc9e4b77441501ca7fb 100644 (file)
@@ -1208,7 +1208,7 @@ Inset::RESULT InsetText::localDispatch(FuncRequest const & cmd)
        }
 
        case LFUN_CUT: {
-               lt->cutSelection(bv);
+               lt->cutSelection(true, true);
                updwhat = CURSOR_PAR;
                updflag = true;
                break;
index 5865272ff1c020977787b2558d28ed7d1639bce8..d7b0d74ed28d941dd48c342431820d6839ec276c 100644 (file)
@@ -47,7 +47,7 @@ public:
 ParPosition::ParPosition(ParagraphList::iterator p, ParagraphList const & pl)
        : pit(p), plist(&pl)
 {
-       if (p != pl.end()) {
+       if (p != const_cast<ParagraphList&>(pl).end()) {
                it.reset(p->insetlist.begin());
        }
 }
@@ -129,7 +129,7 @@ ParIterator & ParIterator::operator++()
                }
 
                // Try to go to the next paragarph
-               if (next(p.pit) != p.plist->end()
+               if (next(p.pit) != const_cast<ParagraphList*>(p.plist)->end()
                    || pimpl_->positions.size() == 1) {
                        ++p.pit;
                        p.index.reset();
@@ -253,7 +253,7 @@ ParConstIterator & ParConstIterator::operator++()
                }
 
                // Try to go to the next paragarph
-               if (next(p.pit) != p.plist->end()
+               if (next(p.pit) != const_cast<ParagraphList*>(p.plist)->end()
                    || pimpl_->positions.size() == 1) {
                        ++p.pit;
                        p.index.reset();
index be5e2bfd17fc8632bc05cbeea9df52dba9dfbdee..48b93ec128b6bbec19c4d82735f4bdb49bd64a95 100644 (file)
@@ -1,3 +1,6 @@
+2003-06-13  Jean-Marc Lasgouttes  <lasgouttes@lyx.org>
+
+       * formulabase.C (mathDispatchCreation): fix call to cutSelection
 
 2003-06-16  André Pönitz  <poenitz@gmx.net>
 
index 3f7f7f0af0014645c0399604fbe1521da81e9c25..ae0d51d0f432e9aa050dcc2838410c3a38c188d9 100644 (file)
@@ -920,7 +920,7 @@ void mathDispatchCreation(FuncRequest const & cmd, bool display)
                        f = new InsetFormula(sel);
                else
                        f = new InsetFormulaMacro(sel);
-               bv->getLyXText()->cutSelection(bv);
+               bv->getLyXText()->cutSelection(true, false);
                openNewInset(bv, f);
        }
        cmd.message(N_("Math editor mode"));
index 50f3498dc49e5a73592b536660366df5c47d4b26..2b3496b90c620cc190628386295b620be03e6c5c 100644 (file)
@@ -736,7 +736,7 @@ Inset::RESULT LyXText::dispatch(FuncRequest const & cmd)
                        // just comment out the line below...
                } else {
                        update();
-                       cutSelection(bv, true);
+                       cutSelection(true, false);
                        update();
                }
                moveCursorUpdate(bv, false);
@@ -777,7 +777,7 @@ Inset::RESULT LyXText::dispatch(FuncRequest const & cmd)
                        }
                } else {
                        update();
-                       cutSelection(bv, true);
+                       cutSelection(true, false);
                }
                update();
                break;
@@ -794,7 +794,7 @@ Inset::RESULT LyXText::dispatch(FuncRequest const & cmd)
                        }
                } else {
                        update();
-                       cutSelection(bv, true);
+                       cutSelection(true, false);
                        update();
                }
                bv->owner()->view_state_changed();
@@ -823,7 +823,7 @@ Inset::RESULT LyXText::dispatch(FuncRequest const & cmd)
                        }
                } else {
                        update();
-                       cutSelection(bv, true);
+                       cutSelection(true, false);
                }
                update();
                break;
@@ -1034,7 +1034,7 @@ Inset::RESULT LyXText::dispatch(FuncRequest const & cmd)
 
        case LFUN_CUT:
                update();
-               cutSelection(bv, true);
+               cutSelection(true, true);
                update();
                cmd.message(_("Cut"));
                break;