]> git.lyx.org Git - lyx.git/blobdiff - src/mathed/InsetMathFrac.h
Restore correct left/right navigation in root inset
[lyx.git] / src / mathed / InsetMathFrac.h
index 36e7ba363b808cb07320a83195f90bba360c1f1d..ba92006a985a976a8bbfe5f5196657a344e1a122 100644 (file)
@@ -25,11 +25,17 @@ public:
        ///
        InsetMathFracBase(Buffer * buf, idx_type ncells = 2);
        ///
+       marker_type marker(BufferView const *) const { return MARKER2; }
+       ///
        bool idxUpDown(Cursor &, bool up) const;
        ///
        bool idxBackward(Cursor &) const { return false; }
        ///
        bool idxForward(Cursor &) const { return false; }
+       ///
+       InsetMathFracBase * asFracBaseInset() { return this; }
+       ///
+       InsetMathFracBase const * asFracBaseInset() const { return this; }
 };
 
 
@@ -58,6 +64,8 @@ public:
        ///
        bool idxBackward(Cursor &) const;
        ///
+       MathClass mathClass() const;
+       ///
        void metrics(MetricsInfo & mi, Dimension & dim) const;
        ///
        void draw(PainterInfo &, int x, int y) const;
@@ -84,8 +92,13 @@ public:
        ///
        void mathmlize(MathStream &) const;
        ///
+       void htmlize(HtmlStream &) const;
+       ///
        void validate(LaTeXFeatures & features) const;
-public:
+private:
+       /// vertical displacement
+       int dy(FontInfo & fi) const;
+       ///
        Inset * clone() const;
        ///
        Kind kind_;
@@ -111,18 +124,19 @@ public:
        void write(WriteStream & os) const;
        ///
        void normalize(NormalStream &) const;
+       /// Generalized fractions are of inner class (see The TeXbook, p.292)
+       MathClass mathClass() const { return MC_INNER; }
        ///
        void metrics(MetricsInfo & mi, Dimension & dim) const;
        ///
        void draw(PainterInfo &, int x, int y) const;
-       /// draw decorations.
-       void drawDecoration(PainterInfo & pi, int x, int y) const
-       { drawMarkers2(pi, x, y); }
        ///
        bool extraBraces() const;
        ///
        void mathmlize(MathStream &) const;
        ///
+       void htmlize(HtmlStream &) const;
+       ///
        void validate(LaTeXFeatures & features) const;
        ///
        InsetCode lyxCode() const { return MATH_FRAC_CODE; }