]> git.lyx.org Git - lyx.git/blobdiff - src/mathed/InsetMathExFunc.cpp
Assure correct spacing of colored items in mathed
[lyx.git] / src / mathed / InsetMathExFunc.cpp
index e4479275d01093e7aec6a6699e263b5f72da9c00..9782e25cf3ff2aefdbe56b06d53aa1ca5fdf9cc1 100644 (file)
@@ -44,7 +44,7 @@ Inset * InsetMathExFunc::clone() const
 
 void InsetMathExFunc::metrics(MetricsInfo & mi, Dimension & dim) const
 {
-       mathed_string_dim(mi.base.font, name_, dim);
+       metricsStrRedBlack(mi, dim, name_);
 }
 
 
@@ -122,10 +122,21 @@ void InsetMathExFunc::mathematica(MathematicaStream & os) const
 }
 
 
-void InsetMathExFunc::mathmlize(MathStream & os) const
+void InsetMathExFunc::mathmlize(MathStream & ms) const
 {
-       os.os() << "<mi>" << name_ << "</mi>" << "&af;";
-       os << cell(0);
+       ms << "<" << from_ascii(ms.namespacedTag("mi")) << ">"
+          << name_
+       << "</" << from_ascii(ms.namespacedTag("mi")) << ">"
+          << "<" << from_ascii(ms.namespacedTag("mo")) << ">"
+          << "&af;"
+          << "</" << from_ascii(ms.namespacedTag("mo")) << ">"
+          << cell(0);
+}
+
+
+void InsetMathExFunc::htmlize(HtmlStream & os) const
+{
+       os << name_ << cell(0);
 }