#include "lyxrc.h"
#include "outputparams.h"
#include "textpainter.h"
-#include "undo.h"
#include "frontends/Alert.h"
case LFUN_MATH_NUMBER:
//lyxerr << "toggling all numbers" << endl;
if (display()) {
- recordUndo(cur);
+ ////recordUndo(cur, Undo::INSERT);
bool old = numberedType();
if (type_ == "multline")
numbered(nrows() - 1, !old);
case LFUN_MATH_NONUMBER:
if (display()) {
row_type r = (type_ == "multline") ? nrows() - 1 : cur.row();
- recordUndo(cur);
+ ////recordUndo(cur, Undo::INSERT);
bool old = numbered(r);
cur.message(old ? _("No number") : _("Number"));
numbered(r, !old);
}
-void MathHullInset::handleFont(LCursor & cur, string const & arg,
- string const & font)
+void MathHullInset::handleFont
+ (LCursor & cur, string const & arg, string const & font)
{
// this whole function is a hack and won't work for incremental font
// changes...
- recordUndo(cur);
- if (cur.inset().asMathInset()->name() == font)
+ //recordUndo(cur, Undo::ATOMIC);
+
+ if (cur.inset()->asMathInset()->name() == font)
cur.handleFont(font);
else {
cur.handleNest(createMathInset(font));
void MathHullInset::handleFont2(LCursor & cur, string const & arg)
{
- recordUndo(cur);
+ //recordUndo(cur, Undo::ATOMIC);
LyXFont font;
bool b;
bv_funcs::string2font(arg, font, b);