]> git.lyx.org Git - lyx.git/blobdiff - src/mathed/InsetMathUnknown.C
This commit fixes a crash when accessing a math inset. This was due to an invalid...
[lyx.git] / src / mathed / InsetMathUnknown.C
index 14cee3c3e97bfcdd3da5e5ec92b47923223d66ac..fd52b0aed97b6e24077aa2af9a94a78b4acf84e3 100644 (file)
@@ -51,17 +51,19 @@ void InsetMathUnknown::normalize(NormalStream & os) const
 
 void InsetMathUnknown::metrics(MetricsInfo & mi, Dimension & dim) const
 {
-       mathed_string_dim(mi.base.font, name_, dim);
+       // FIXME UNICODE
+       mathed_string_dim(mi.base.font, lyx::from_utf8(name_), dim);
        dim_ = dim;
 }
 
 
 void InsetMathUnknown::draw(PainterInfo & pi, int x, int y) const
 {
+       // FIXME UNICODE
        if (black_)
-               drawStrBlack(pi, x, y, name_);
+               drawStrBlack(pi, x, y, lyx::from_utf8(name_));
        else
-               drawStrRed(pi, x, y, name_);
+               drawStrRed(pi, x, y, lyx::from_utf8(name_));
        setPosCache(pi, x, y);
 }