3 #include "math_exfuncinset.h"
4 #include "math_support.h"
5 #include "math_mathmlstream.h"
6 #include "math_streamstr.h"
9 MathExFuncInset::MathExFuncInset(string const & name)
10 : MathNestInset(1), name_(name)
14 MathInset * MathExFuncInset::clone() const
16 return new MathExFuncInset(*this);
20 void MathExFuncInset::metrics(MathMetricsInfo const & mi) const
23 mathed_string_dim(LM_TC_TEXTRM, mi_, name_, ascent_, descent_, width_);
27 void MathExFuncInset::draw(Painter & pain, int x, int y) const
29 drawStr(pain, LM_TC_TEXTRM, mi_, x, y, name_);
33 void MathExFuncInset::normalize(NormalStream & os) const
35 os << '[' << name_ << ' ' << cell(0) << ']';
39 void MathExFuncInset::maplize(MapleStream & os) const
41 os << name_ << '(' << cell(0) << ')';
45 void MathExFuncInset::mathmlize(MathMLStream & os) const
47 os << MTag(name_.c_str()) << cell(0) << ETag(name_.c_str());
51 void MathExFuncInset::octavize(OctaveStream & os) const
53 os << name_ << '(' << cell(0) << ')';
57 void MathExFuncInset::write(WriteStream & os) const
59 os << '\\' << name_ << '{' << cell(0) << '}';