]> git.lyx.org Git - lyx.git/blobdiff - src/mathed/math_braceinset.C
fix #1073
[lyx.git] / src / mathed / math_braceinset.C
index 29edda531de45828e31e1c75b5c55d377e1b605a..b0213e2c387950bc17df0a4d33e0ca79c5dc13ab 100644 (file)
@@ -1,8 +1,5 @@
 #include <config.h>
 
-#ifdef __GNUG__
-#pragma implementation
-#endif
 
 #include "math_braceinset.h"
 #include "math_parser.h"
@@ -31,24 +28,24 @@ MathInset * MathBraceInset::clone() const
 }
 
 
-void MathBraceInset::metrics(MathMetricsInfo & mi) const
+void MathBraceInset::metrics(MetricsInfo & mi) const
 {
-       xcell(0).metrics(mi);
+       cell(0).metrics(mi);
        Dimension t;
        mathed_char_dim(mi.base.font, '{', t);
        wid_ = t.w;
-       dim_.a = max(xcell(0).ascent(), t.a);
-       dim_.d = max(xcell(0).descent(), t.a);
-       dim_.w = xcell(0).width() + 2 * wid_;
+       dim_.a = max(cell(0).ascent(), t.a);
+       dim_.d = max(cell(0).descent(), t.d);
+       dim_.w = cell(0).width() + 2 * wid_;
 }
 
 
-void MathBraceInset::draw(MathPainterInfo & pi, int x, int y) const
+void MathBraceInset::draw(PainterInfo & pi, int x, int y) const
 {
        LyXFont font = pi.base.font;
        font.setColor(LColor::latex);
        drawChar(pi, font, x, y, '{');
-       xcell(0).draw(pi, x + wid_, y);
+       cell(0).draw(pi, x + wid_, y);
        drawChar(pi, font, x + width() - wid_, y, '}');
 }
 
@@ -65,6 +62,30 @@ void MathBraceInset::normalize(NormalStream & os) const
 }
 
 
+void MathBraceInset::maple(MapleStream & os) const
+{
+       os << cell(0);
+}
+
+
+void MathBraceInset::octave(OctaveStream & os) const
+{
+       os << cell(0);
+}
+
+
+void MathBraceInset::mathmlize(MathMLStream & os) const
+{
+       os << MTag("mrow") << cell(0) << ETag("mrow");
+}
+
+
+void MathBraceInset::mathematica(MathematicaStream & os) const
+{
+       os << cell(0);
+}
+
+
 void MathBraceInset::infoize(std::ostream & os) const
 {
        os << "Nested Block: ";