5 #include "math_macroarg.h"
6 #include "math_macro.h"
8 #include "mathed/support.h"
13 MathMacroArgument::MathMacroArgument(int n)
17 lyxerr << "MathMacroArgument::MathMacroArgument: wrong Argument id: "
23 MathInset * MathMacroArgument::clone() const
25 return new MathMacroArgument(*this);
29 void MathMacroArgument::draw(Painter & pain, int x, int y)
33 drawStr(pain, LM_TC_TEX, size(), x, y, str);
37 void MathMacroArgument::metrics(MathStyles st)
42 mathed_string_dim(LM_TC_TEX, size(), str, ascent_, descent_, width_);
46 void MathMacroArgument::write(std::ostream & os, bool /*fragile*/) const
48 os << '#' << number_ << ' ';
52 void MathMacroArgument::writeNormal(std::ostream & os) const
54 os << "[macroarg " << number_ << "] ";
58 void MathMacroArgument::substitute(MathArray & array, MathMacro const & m) const
60 array.push_back(m.cell(number_ - 1));