{
Dimension dim0;
cell(0).metrics(mi, dim0);
- Dimension t = theFontMetrics(mi.base.font).dimension('{');
+ FontInfo font = mi.base.font;
+ augmentFont(font, from_ascii("mathnormal"));
+ Dimension t = theFontMetrics(font).dimension('{');
dim.asc = max(dim0.asc, t.asc);
dim.des = max(dim0.des, t.des);
dim.wid = dim0.width() + 2 * t.wid;
void InsetMathBrace::draw(PainterInfo & pi, int x, int y) const
{
FontInfo font = pi.base.font;
+ augmentFont(font, from_ascii("mathnormal"));
font.setShape(UP_SHAPE);
font.setColor(Color_latex);
Dimension t = theFontMetrics(font).dimension('{');
if (completion.length() == 0)
continue;
- dim.wid += mathed_string_width(mi.base.font, completion);
+ FontInfo font = mi.base.font;
+ augmentFont(font, from_ascii("mathnormal"));
+ dim.wid += mathed_string_width(font, completion);
}
// Cache the dimension.
mi.base.bv->coordCache().arrays().add(this, dim);
if (completion.length() == 0)
continue;
FontInfo f = pi.base.font;
+ augmentFont(f, from_ascii("mathnormal"));
// draw the unique and the non-unique completion part
// Note: this is not time-critical as it is
void metricsStrRedBlack(MetricsInfo & mi, Dimension & dim, docstring const & str)
{
- mathed_string_dim(mi.base.font, str, dim);
+ FontInfo font = mi.base.font;
+ augmentFont(font, from_ascii("mathnormal"));
+ mathed_string_dim(font, str, dim);
}
void drawStrRed(PainterInfo & pi, int x, int y, docstring const & str)
{
FontInfo f = pi.base.font;
+ augmentFont(f, from_ascii("mathnormal"));
f.setColor(Color_latex);
pi.pain.text(x, y, str, f);
}
void drawStrBlack(PainterInfo & pi, int x, int y, docstring const & str)
{
FontInfo f = pi.base.font;
+ augmentFont(f, from_ascii("mathnormal"));
f.setColor(Color_foreground);
pi.pain.text(x, y, str, f);
}