]> git.lyx.org Git - lyx.git/blobdiff - src/mathed/MathMacroTemplate.cpp
Another warning.
[lyx.git] / src / mathed / MathMacroTemplate.cpp
index 7db428faf3734d18ee95dea1e898b382dc5122a5..3eadf6d2ef2242e04a6700b7808b7f611fa946b7 100644 (file)
@@ -35,7 +35,6 @@
 #include "FuncStatus.h"
 #include "Lexer.h"
 #include "LyXRC.h" 
-#include "Undo.h"
 
 #include "frontends/Painter.h"
 
@@ -592,6 +591,7 @@ void MathMacroTemplate::metrics(MetricsInfo & mi, Dimension & dim) const
 
 void MathMacroTemplate::draw(PainterInfo & pi, int x, int y) const
 {
+       ColorChanger dummy0(pi.base.font, Color_math);
        FontSetChanger dummy1(pi.base, from_ascii("mathnormal"));
        StyleChanger dummy2(pi.base, LM_ST_TEXT);
 
@@ -616,7 +616,7 @@ void MathMacroTemplate::draw(PainterInfo & pi, int x, int y) const
 void MathMacroTemplate::edit(Cursor & cur, bool front, EntryDirection entry_from)
 {
        updateLook();
-       cur.updateFlags(Update::SinglePar);
+       cur.screenUpdateFlags(Update::SinglePar);
        InsetMathNest::edit(cur, front, entry_from);
 }
 
@@ -625,7 +625,7 @@ bool MathMacroTemplate::notifyCursorLeaves(Cursor const & old, Cursor & cur)
 {
        commitEditChanges(cur, old);
        updateLook();
-       cur.updateFlags(Update::Force);
+       cur.screenUpdateFlags(Update::Force);
        return InsetMathNest::notifyCursorLeaves(old, cur);
 }
 
@@ -802,7 +802,7 @@ void fixMacroInstances(Cursor & cur, DocIterator const & inset_pos,
                                        hull.nextInset()->asInsetMath()->asHullInset();
                                LASSERT(inset_hull, /**/);
                                inset_hull->reloadPreview(hull);
-                               cur.updateFlags(Update::Force);
+                               cur.screenUpdateFlags(Update::Force);
                                preview_reload_needed = false;
                        }
                        hull.clear();