3 #include "math_exfuncinset.h"
4 #include "math_support.h"
5 #include "math_mathmlstream.h"
6 #include "math_streamstr.h"
11 MathExFuncInset::MathExFuncInset(string const & name)
12 : MathNestInset(1), name_(name)
16 MathInset * MathExFuncInset::clone() const
18 return new MathExFuncInset(*this);
22 void MathExFuncInset::metrics(MathMetricsInfo const & mi) const
25 mathed_string_dim(LM_TC_TEXTRM, mi_, name_, ascent_, descent_, width_);
29 void MathExFuncInset::draw(Painter & pain, int x, int y) const
31 drawStr(pain, LM_TC_TEXTRM, mi_, x, y, name_);
35 void MathExFuncInset::normalize(NormalStream & os) const
37 os << '[' << name_ << ' ' << cell(0) << ']';
41 void MathExFuncInset::maplize(MapleStream & os) const
43 os << name_ << '(' << cell(0) << ')';
47 void MathExFuncInset::mathmlize(MathMLStream & os) const
49 os << MTag(name_.c_str()) << cell(0) << ETag(name_.c_str());
53 void MathExFuncInset::octavize(OctaveStream & os) const
55 os << name_ << '(' << cell(0) << ')';
59 void MathExFuncInset::write(WriteStream & os) const
61 os << '\\' << name_ << '{' << cell(0) << '}';