]> git.lyx.org Git - lyx.git/blobdiff - src/Text.h
Transfer current_font and real_current_font from Text to Cursor.
[lyx.git] / src / Text.h
index 88295d2ba6ca96c50417288e1dd44bc758feb6e4..b7764d7d8081cf27a65e617d1085c362cbf15938 100644 (file)
@@ -38,7 +38,6 @@ class Inset;
 class Color_color;
 class Cursor;
 class PainterInfo;
-class Row;
 class Spacing;
 
 
@@ -169,8 +168,6 @@ public:
        ///
        void setCursorIntern(Cursor & cur, pit_type par,
                 pos_type pos, bool setfont = true, bool boundary = false);
-       ///
-       void setCurrentFont(Cursor & cur);
 
        ///
        void recUndo(Cursor & cur, pit_type first, pit_type last) const;
@@ -191,17 +188,15 @@ public:
        bool cursorLeftOneWord(Cursor & cur);
        ///
        bool cursorRightOneWord(Cursor & cur);
+       /// Delete from cursor up to the end of the current or next word.
+       void deleteWordForward(Cursor & cur);
+       /// Delete from cursor to start of current or prior word.
+       void deleteWordBackward(Cursor & cur);
        ///
        bool cursorUpParagraph(Cursor & cur);
        ///
        bool cursorDownParagraph(Cursor & cur);
        ///
-       /// FIXME: move to TextMetrics.
-       bool cursorHome(Cursor & cur);
-       ///
-       /// FIXME: move to TextMetrics.
-       bool cursorEnd(Cursor & cur);
-       ///
        bool cursorTop(Cursor & cur);
        ///
        bool cursorBottom(Cursor & cur);
@@ -258,13 +253,6 @@ public:
        /// return true if this is the main text
        bool isMainText(Buffer const &) const;
 
-       /// is this row the last in the text?
-       /// FIXME: move to TextMetrics.
-       bool isLastRow(pit_type pit, Row const & row) const;
-       /// is this row the first in the text?
-       /// FIXME: move to TextMetrics.
-       bool isFirstRow(pit_type pit, Row const & row) const;
-
        ///
        double spacing(Buffer const & buffer, Paragraph const & par) const;
        /// make a suggestion for a label
@@ -301,10 +289,6 @@ public:
        void deleteEmptyParagraphMechanism(pit_type first, pit_type last, bool trackChanges);
 
 public:
-       /// the current font settings
-       Font current_font;
-       /// the current font
-       Font real_current_font;
        ///
        int background_color_;
 
@@ -331,13 +315,6 @@ private:
        bool backspacePos0(Cursor & cur);
        /// handle the case where bibitems were deleted
        bool handleBibitems(Cursor & cur);
-
-       ///
-       void deleteWordForward(Cursor & cur);
-       ///
-       void deleteWordBackward(Cursor & cur);
-       ///
-       void deleteLineForward(Cursor & cur);
        ///
        void charInserted();
        /// set 'number' font property