5 #include "math_funcinset.h"
8 #include "mathed/support.h"
9 #include "support/LOstream.h"
14 extern LyXFont WhichFont(short type, int size);
17 MathFuncInset::MathFuncInset(string const & nm)
22 MathInset * MathFuncInset::clone() const
24 return new MathFuncInset(*this);
28 void MathFuncInset::write(std::ostream & os, bool /* fragile */) const
30 os << "\\" << name_ << ' ';
34 void MathFuncInset::writeNormal(std::ostream & os) const
36 os << "[" << name_ << "] ";
40 void MathFuncInset::metrics(MathStyles st)
44 mathed_char_dim(LM_TC_TEXTRM, size_, 'I', ascent_, descent_, width_);
46 mathed_string_dim(LM_TC_TEXTRM, size_, name_, ascent_, descent_, width_);
50 void MathFuncInset::draw(Painter & pain, int x, int y)
55 drawChar(pain, LM_TC_TEXTRM, size_, x, y, ' ');
57 drawStr(pain, LM_TC_TEXTRM, size_, x, y, name_);