4 #include "math_biginset.h"
5 #include "math_support.h"
6 #include "math_parser.h"
7 #include "math_mathmlstream.h"
8 #include "math_streamstr.h"
11 MathBigInset::MathBigInset(string const & name, string const & delim)
12 : name_(name), delim_(delim)
16 MathInset * MathBigInset::clone() const
18 return new MathBigInset(*this);
22 MathBigInset::size_type MathBigInset::size() const
24 return name_.size() - 4;
28 double MathBigInset::increase() const
40 void MathBigInset::metrics(MetricsInfo & mi) const
42 double const h = mathed_char_ascent(mi.base.font, 'I');
43 double const f = increase();
45 dim_.a = int(h + f * h);
50 void MathBigInset::draw(PainterInfo & pi, int x, int y) const
52 mathed_draw_deco(pi, x + 1, y - ascent(), 4, height(), delim_);
56 void MathBigInset::write(WriteStream & os) const
58 os << '\\' << name_ << ' ' << delim_;
62 void MathBigInset::normalize(NormalStream & os) const
64 os << '[' << name_ << ' ' << delim_ << ']';