7 #include "math_dotsinset.h"
8 #include "math_mathmlstream.h"
9 #include "math_streamstr.h"
10 #include "math_support.h"
11 #include "math_parser.h"
14 MathDotsInset::MathDotsInset(latexkeys const * key)
19 MathInset * MathDotsInset::clone() const
21 return new MathDotsInset(*this);
25 void MathDotsInset::metrics(MathMetricsInfo & mi) const
27 mathed_char_dim(mi.base.font, 'M', dim_);
28 if (key_->name == "ldots" || key_->name == "dotsm")
30 else if (key_->name == "cdots" || key_->name == "dotsb"
31 || key_->name == "dotsm" || key_->name == "dotsi")
33 else if (key_->name == "dotsc")
35 else if (key_->name == "vdots")
37 else if (key_->name == "ddots")
42 void MathDotsInset::draw(MathPainterInfo & pain, int x, int y) const
44 mathed_draw_deco(pain, x + 2, y - dh_, width() - 2, ascent(), key_->name);
45 if (key_->name == "vdots" || key_->name == "ddots")
47 if (key_->name != "vdots")
49 mathed_draw_deco(pain, x + 2, y - dh_, width() - 2, ascent(), key_->name);
53 string MathDotsInset::name() const