]> git.lyx.org Git - lyx.git/blobdiff - src/mathed/math_gridinset.h
float2string #4 (Spacing)
[lyx.git] / src / mathed / math_gridinset.h
index 37ff4a289b8eec34ed140a5cd9d4af5a46ff2fca..7b0b329552cf40efaeb3b22545c92c69f01e50be 100644 (file)
@@ -20,7 +20,6 @@
  *  This is the base to all grid-like editable math objects
  */
 class MathGridInset : public MathNestInset {
-
 public:
 
        /// additional per-cell information
@@ -94,8 +93,6 @@ public:
        /// Ensures that the dialog is closed.
        ~MathGridInset();
        ///
-       virtual std::auto_ptr<InsetBase> clone() const;
-       ///
        void metrics(MetricsInfo & mi) const;
        ///
        void metrics(MetricsInfo & mi, Dimension &) const;
@@ -145,19 +142,15 @@ public:
        row_type row(idx_type idx) const;
 
        ///
-       bool idxUpDown(BufferView &, bool up, int targetx) const;
-       ///
-       bool idxLeft(BufferView &) const;
+       bool idxUpDown(LCursor &, bool up) const;
        ///
-       bool idxRight(BufferView &) const;
+       bool idxLeft(LCursor &) const;
        ///
-       bool idxFirst(BufferView &) const;
+       bool idxRight(LCursor &) const;
        ///
-       bool idxLast(BufferView &) const;
+       bool idxFirst(LCursor &) const;
        ///
-       bool idxHome(BufferView &) const;
-       ///
-       bool idxEnd(BufferView &) const;
+       bool idxLast(LCursor &) const;
        ///
        bool idxDelete(idx_type & idx);
        /// pulls cell after pressing erase
@@ -215,11 +208,10 @@ public:
        //void octave(OctaveStream &) const;
 
 protected:
+       virtual void doDispatch(LCursor & cur, FuncRequest & cmd);
        ///
-       virtual
-       DispatchResult
-       priv_dispatch(BufferView & bv, FuncRequest const & cmd);
-
+       bool getStatus(LCursor & cur, FuncRequest const & cmd,
+               FuncStatus & flag) const;
        /// returns x offset of cell compared to inset
        int cellXOffset(idx_type idx) const;
        /// returns y offset of cell compared to inset
@@ -231,7 +223,7 @@ protected:
        /// extract number of columns from alignment string
        col_type guessColumns(std::string const & halign) const;
        /// splits cells and shifts right part to the next cell
-       void splitCell(BufferView & pos);
+       void splitCell(LCursor & cur);
 
 public:
        /// row info
@@ -242,6 +234,8 @@ public:
        std::vector<CellInfo> cellinfo_;
        ///
        char v_align_; // add approp. type
+private:
+       virtual std::auto_ptr<InsetBase> doClone() const;
 };
 
 #endif