]> git.lyx.org Git - features.git/blobdiff - src/mathed/InsetMathFrac.cpp
Introduce a return value for mathmlize(). We will need this to be able
[features.git] / src / mathed / InsetMathFrac.cpp
index 11d337d72912e83407226d556bf2e49e34ac77ec..3fbd56d8fdfc1bf552538258d4a4455d2a4af2be 100644 (file)
@@ -17,6 +17,7 @@
 #include "Cursor.h"
 #include "LaTeXFeatures.h"
 #include "MathData.h"
+#include "MathExtern.h"
 #include "MathStream.h"
 #include "MathSupport.h"
 #include "MetricsInfo.h"
@@ -384,12 +385,14 @@ void InsetMathFrac::octave(OctaveStream & os) const
 }
 
 
-void InsetMathFrac::mathmlize(MathStream & os) const
+docstring InsetMathFrac::mathmlize(MathStream & os) const
 {
-       os << MTag("mfrac") 
-          << MTag("mrow") << cell(0) << ETag("mrow")
-                << MTag("mrow") << cell(1) << ETag("mrow")
-                << ETag("mfrac");
+       os << MTag("mfrac") << MTag("mrow");
+       docstring rv = lyx::mathmlize(cell(0), os);
+       os << ETag("mrow") << MTag("mrow");
+       rv += lyx::mathmlize(cell(1), os);
+       os << ETag("mrow") << ETag("mfrac");
+       return rv;
 }
 
 
@@ -533,8 +536,9 @@ void InsetMathBinom::normalize(NormalStream & os) const
 }
 
 
-void InsetMathBinom::mathmlize(MathStream & os) const
+docstring InsetMathBinom::mathmlize(MathStream & os) const
 {
+       // FIXME This all needs fixing
        switch (kind_) {
        case BINOM:
                os << MTag("mbinom") << cell(0) << cell(1) << ETag("mbinom");
@@ -547,6 +551,7 @@ void InsetMathBinom::mathmlize(MathStream & os) const
                os << MTag("mdbinom") << cell(0) << cell(1) << ETag("mdbinom");
                break;
        }
+       return docstring();
 }