]> git.lyx.org Git - lyx.git/blobdiff - src/Text.h
Fix bug #10579
[lyx.git] / src / Text.h
index fa4229025848079536dadf75b3df7750e0bc7cc7..2174984b2352fef7f2405786c80dcd3712e6720a 100644 (file)
@@ -130,9 +130,13 @@ public:
                
        /// Appends a possibly abbreviated representation of our text to \param os,
        /// where \param maxlen defines the maximum size of \param os. If \param
-       /// shorten is true, then os is shortened as above
-       void forOutliner(docstring & os, size_t const maxlen,
-                                        bool const shorten = true) const;
+       /// shorten is true, then os is shortened as above.
+       void forOutliner(docstring & os, size_t maxlen, bool shorten = true) const;
+       /// Appends a possibly abbreviated representation of our text, from
+       /// start to end, to \param os, where \param maxlen defines the
+       /// maximum size of \param os. Omits the label of the first paragraph.
+       void forOutliner(docstring & os, size_t maxlen, pit_type start, pit_type end,
+                        bool shorten = true) const;
 
        /// insert a character at cursor position
        /// FIXME: replace Cursor with DocIterator.
@@ -185,8 +189,6 @@ public:
        bool setCursor(Cursor & cur, pit_type pit, pos_type pos,
                       bool setfont = true, bool boundary = false);
        ///
-       void setCursor(CursorSlice &, pit_type pit, pos_type pos);
-       ///
        void setCursorIntern(Cursor & cur, pit_type pit,
                 pos_type pos, bool setfont = true, bool boundary = false);
 
@@ -221,9 +223,10 @@ public:
        ///
        bool cursorVisRightOneWord(Cursor & cur);
        /// Delete from cursor up to the end of the current or next word.
-       void deleteWordForward(Cursor & cur);
+       /// Use force to skip the confirmDeletion check.
+       void deleteWordForward(Cursor & cur, bool force = false);
        /// Delete from cursor to start of current or prior word.
-       void deleteWordBackward(Cursor & cur);
+       void deleteWordBackward(Cursor & cur, bool force = false);
        ///
        bool cursorUpParagraph(Cursor & cur);
        ///
@@ -331,6 +334,9 @@ public:
        pit_type outerHook(pit_type pit) const;
        /// Is it the first par with same depth and layout?
        bool isFirstInSequence(pit_type pit) const;
+       /// Return the last paragraph with same depth and layout, or a strictly
+       /// greater depth
+       pit_type lastInSequence(pit_type pit) const;
        /// Is this paragraph in the table of contents?
        int getTocLevel(pit_type pit) const;
        /// Get the font of the "environment" of paragraph \p par_offset in \p pars.