]> git.lyx.org Git - lyx.git/blobdiff - src/mathed/InsetMathFrac.cpp
A little cleanup of the layout files.
[lyx.git] / src / mathed / InsetMathFrac.cpp
index cffc1d76deacabf7f87704d26f4d4ded25a0684c..2c2d6975436349626d510ad0cda9ef46ae2881b7 100644 (file)
@@ -223,7 +223,7 @@ void InsetMathFrac::draw(PainterInfo & pi, int x, int y) const
                        ShapeChanger dummy2(pi.base.font, UP_SHAPE);
                        cell(0).draw(pi, x + 2, y - dim0.des - 5);
                        cell(1).draw(pi, x + dim0.width() + 5, y + dim1.asc / 2);
-               } else if (kind_ == FRAC) {
+               } else if (kind_ == FRAC || kind_ == ATOP || kind_ == OVER) {
                        cell(0).draw(pi, m - dim0.wid / 2, y - dim0.des - 2 - 5);
                        cell(1).draw(pi, m - dim1.wid / 2, y + dim1.asc + 2 - 5);
                } else if (kind_ == TFRAC) {
@@ -385,15 +385,16 @@ void InsetMathFrac::octave(OctaveStream & os) const
 void InsetMathFrac::mathmlize(MathStream & os) const
 {
        switch (kind_) {
-       case FRAC:
-               os << MTag("mfrac") << cell(0) << cell(1) << ETag("mfrac");
-               break;
        case DFRAC:
                os << MTag("mdfrac") << cell(0) << cell(1) << ETag("mdfrac");
                break;
        case TFRAC:
                os << MTag("mtfrac") << cell(0) << cell(1) << ETag("mtfrac");
                break;
+       case FRAC:
+       default:
+               os << MTag("mfrac") << cell(0) << cell(1) << ETag("mfrac");
+               break;
        }
 }
 
@@ -544,12 +545,13 @@ void InsetMathBinom::mathmlize(MathStream & os) const
        case BINOM:
                os << MTag("mbinom") << cell(0) << cell(1) << ETag("mbinom");
                break;
-       case DBINOM:
-               os << MTag("mdbinom") << cell(0) << cell(1) << ETag("mdbinom");
-               break;
        case TBINOM:
                os << MTag("mtbinom") << cell(0) << cell(1) << ETag("mtbinom");
                break;
+       case DBINOM:
+       default:
+               os << MTag("mdbinom") << cell(0) << cell(1) << ETag("mdbinom");
+               break;
        }
 }