X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=src%2Flyxtext.h;h=897808cca860789ac90c57995140309b4efb7b67;hb=80328d2053869dc089c23c25adbed4167d7bf0b1;hp=55448a1a5db8b21f7678f39af4ab4956b49b729e;hpb=f4cc84d5a611fb99063540a57ac6f8c9353651a2;p=lyx.git diff --git a/src/lyxtext.h b/src/lyxtext.h index 55448a1a5d..897808cca8 100644 --- a/src/lyxtext.h +++ b/src/lyxtext.h @@ -159,7 +159,11 @@ public: REJECT }; /// accept or reject the selected change - void acceptOrRejectChange(LCursor & cur, ChangeOp op); + void acceptOrRejectChanges(LCursor & cur, ChangeOp op); + /// accept the changes within the complete LyXText + void acceptChanges(BufferParams const & bparams); + /// reject the changes within the complete LyXText + void rejectChanges(BufferParams const & bparams); /// returns true if par was empty and was removed bool setCursor(LCursor & cur, pit_type par, pos_type pos, @@ -345,7 +349,7 @@ public: /// \retval true if a change has happened and we need a redraw. /// FIXME: replace LCursor with DocIterator. This is not possible right /// now because recordUndo() is called which needs a LCursor. - bool deleteEmptyParagraphMechanism(LCursor & cur, + static bool deleteEmptyParagraphMechanism(LCursor & cur, LCursor & old, bool & need_anchor_change); /// delete double spaces, leading spaces, and empty paragraphs @@ -378,7 +382,7 @@ private: // fix the cursor `cur' after a characters has been deleted at `where' // position. Called by deleteEmptyParagraphMechanism - void fixCursorAfterDelete(CursorSlice & cur, CursorSlice const & where); + static void fixCursorAfterDelete(CursorSlice & cur, CursorSlice const & where); // At cursor position 0, try to merge the paragraph with the one before it. // Ignore change tracking, i.e., physically remove the end-of-par character