#include "math_mathmlstream.h"
+using std::max;
+
+
MathBraceInset::MathBraceInset()
: MathNestInset(1)
{}
MathInset * MathBraceInset::clone() const
-{
+{
return new MathBraceInset(*this);
}
{
xcell(0).metrics(mi);
int a, d;
- mathed_char_dim(LM_TC_TEX, mi, '{', a, d, wid_);
- ascent_ = std::max(xcell(0).ascent(), a);
- descent_ = std::max(xcell(0).descent(), a);
+ whichFont(font_, LM_TC_TEX, mi);
+ mathed_char_dim(font_, '{', a, d, wid_);
+ ascent_ = max(xcell(0).ascent(), a);
+ descent_ = max(xcell(0).descent(), a);
width_ = xcell(0).width() + 2 * wid_;
}
void MathBraceInset::draw(Painter & pain, int x, int y) const
-{
- drawChar(pain, LM_TC_TEX, mi_, x, y, '{');
+{
+ drawChar(pain, font_, x, y, '{');
xcell(0).draw(pain, x + wid_, y);
- drawChar(pain, LM_TC_TEX, mi_, x + width_ - wid_, y, '}');
+ drawChar(pain, font_, x + width_ - wid_, y, '}');
}
{
os << "[block " << cell(0) << ']';
}
-
-