]> git.lyx.org Git - lyx.git/blobdiff - src/mathed/math_braceinset.C
Andreas' patch to prevent crash on click on previewd inset
[lyx.git] / src / mathed / math_braceinset.C
index fe63f1b8b90989af49ed2b57a3451a7384b992b5..7e8a70234969bf181baddd470e7044a3dcdf87e5 100644 (file)
@@ -16,6 +16,7 @@
 #include "math_support.h"
 #include "LColor.h"
 #include "support/std_ostream.h"
+#include "frontends/Painter.h"
 
 using std::max;
 using std::auto_ptr;
@@ -58,9 +59,9 @@ void MathBraceInset::draw(PainterInfo & pi, int x, int y) const
        font.setColor(LColor::latex);
        Dimension t;
        mathed_char_dim(font, '{', t);
-       drawChar(pi, font, x, y, '{');
+       pi.pain.text(x, y, '{', font);
        cell(0).draw(pi, x + t.wid, y);
-       drawChar(pi, font, x + t.wid + cell(0).width(), y, '}');
+       pi.pain.text(x + t.wid + cell(0).width(), y, '}', font);
        drawMarkers(pi, x, y);
 }