MathInset * MathBigInset::clone() const
-{
+{
return new MathBigInset(*this);
}
}
-void MathBigInset::metrics(MathMetricsInfo const & mi) const
+void MathBigInset::metrics(MathMetricsInfo & mi) const
{
- LyXFont font;
- whichFont(font, LM_TC_VAR, mi);
- double h = mathed_char_height(font, 'I', ascent_, descent_);
- double f = increase();
- width_ = 6;
- ascent_ = int(h + f * h);
- descent_ = int(f * h);
+ double const h = mathed_char_ascent(mi.base.font, 'I');
+ double const f = increase();
+ dim_.w = 6;
+ dim_.a = int(h + f * h);
+ dim_.d = int(f * h);
}
-void MathBigInset::draw(Painter & pain, int x, int y) const
-{
- mathed_draw_deco(pain, x + 1, y - ascent_, 4, height(), delim_);
+void MathBigInset::draw(MathPainterInfo & pi, int x, int y) const
+{
+ mathed_draw_deco(pi, x + 1, y - ascent(), 4, height(), delim_);
}
void MathBigInset::normalize(NormalStream & os) const
{
- os << "[" << name_ << ' ' << delim_ << ']';
+ os << '[' << name_ << ' ' << delim_ << ']';
}