InsetMathXYArrow::InsetMathXYArrow()
- : InsetMathNest(2)
+ : InsetMathNest(2), up_(false), target_(0)
{}
bool InsetMathXYArrow::metrics(MetricsInfo & mi) const
{
InsetMathNest::metrics(mi);
- mi_ = mi;
- FontSetChanger dummy(mi.base, "textrm");
+ mi_ = mi;
+ Changer dummy = mi.base.changeFontSet(mi.base, "textrm");
#if 0
target_ = mi.inset ? mi.inset->asXYMatrixInset() : 0;
void InsetMathXYArrow::draw(PainterInfo & pi, int x, int y) const
{
metrics(mi_);
- FontSetChanger dummy(pi.base, "textrm");
+ Changer dummy = pi.base.changeFontSet(pi.base, "textrm");
if (editing()) {
{
MathEnsurer ensurer(os);
os << "\\ar";
- if (cell(0).size())
+ if (!cell(0).empty())
os << '[' << cell(0) << ']';
- if (cell(1).size())
+ if (!cell(1).empty())
os << (up_ ? '^' : '_') << '{' << cell(1) << '}';
os << " ";
}