]> git.lyx.org Git - lyx.git/blob - src/mathed/math_liminset.C
architectural changes to tex2lyx
[lyx.git] / src / mathed / math_liminset.C
1 #include <config.h>
2
3 #include "math_liminset.h"
4 #include "math_support.h"
5 #include "math_mathmlstream.h"
6 #include "math_symbolinset.h"
7 #include "debug.h"
8
9 using std::auto_ptr;
10 using std::endl;
11
12
13 MathLimInset::MathLimInset
14         (MathArray const & f, MathArray const & x, MathArray const & x0)
15         : MathNestInset(3)
16 {
17         cell(0) = f;
18         cell(1) = x;
19         cell(2) = x0;
20 }
21
22
23 auto_ptr<InsetBase> MathLimInset::clone() const
24 {
25         return auto_ptr<InsetBase>(new MathLimInset(*this));
26 }
27
28
29 void MathLimInset::normalize(NormalStream & os) const
30 {
31         os << "[lim " << cell(0) << ' ' << cell(1) << ' ' << cell(2) << ']';
32 }
33
34
35 void MathLimInset::metrics(MetricsInfo &, Dimension &) const
36 {
37         lyxerr << "should not happen" << endl;
38 }
39
40
41 void MathLimInset::draw(PainterInfo &, int, int) const
42 {
43         lyxerr << "should not happen" << endl;
44 }
45
46
47 void MathLimInset::maple(MapleStream & os) const
48 {
49         os << "limit(" << cell(0) << ',' << cell(1) << '=' << cell(2) << ')';
50 }
51
52
53 void MathLimInset::mathematica(MathematicaStream & os) const
54 {
55         os << "Lim[" << cell(0) << ',' << cell(1) << ',' << cell(2) << ']';
56 }
57
58
59 void MathLimInset::mathmlize(MathMLStream & os) const
60 {
61         os << "lim(" << cell(0) << ',' << cell(1) << ',' << cell(2) << ')';
62 }
63
64
65 void MathLimInset::write(WriteStream &) const
66 {
67         lyxerr << "should not happen" << endl;
68 }