A bit more re-organization.
[lyx.git] / src / mathed / InsetMathNumber.cpp
blob933505a6bfa28fb0104c4ff9ef273cebaf63a03a
1 /**
2 * \file InsetMathNumber.cpp
3 * This file is part of LyX, the document processor.
4 * Licence details can be found in the file COPYING.
6 * \author André Pönitz
8 * Full author contact details are available in file CREDITS.
9 */
11 #include <config.h>
13 #include "InsetMathNumber.h"
14 #include "MathStream.h"
15 #include "MathStream.h"
16 #include "MathSupport.h"
18 using namespace std;
21 namespace lyx {
23 InsetMathNumber::InsetMathNumber(docstring const & s)
24 : str_(s)
28 Inset * InsetMathNumber::clone() const
30 return new InsetMathNumber(*this);
34 void InsetMathNumber::metrics(MetricsInfo & mi, Dimension & dim) const
36 mathed_string_dim(mi.base.font, str_, dim);
40 void InsetMathNumber::draw(PainterInfo & pi, int x, int y) const
42 pi.draw(x, y, str_);
46 void InsetMathNumber::normalize(NormalStream & os) const
48 os << "[number " << str_ << ']';
52 void InsetMathNumber::maple(MapleStream & os) const
54 os << str_;
58 void InsetMathNumber::mathematica(MathematicaStream & os) const
60 os << str_;
64 void InsetMathNumber::octave(OctaveStream & os) const
66 os << str_;
70 void InsetMathNumber::mathmlize(MathStream & os) const
72 os << "<mi> " << str_ << " </mi>";
76 void InsetMathNumber::write(WriteStream & os) const
78 os << str_;
82 } // namespace lyx