My fault. Essentially:

Index: cursor.C
===================================================================
RCS file: /usr/local/lyx/cvsroot/lyx-devel/src/cursor.C,v
retrieving revision 1.45
diff -u -p -r1.45 cursor.C
--- cursor.C    3 Feb 2004 11:49:05 -0000       1.45
+++ cursor.C    3 Feb 2004 14:24:08 -0000
@@ -1533,26 +1534,30 @@ bool LCursor::script(bool up)
        string safe = grabAndEraseSelection();
        if (inNucleus()) {
                // we are in a nucleus of a script inset, move to _our_ script
                inset()->asMathInset()->asScriptInset()->ensure(up);
                idx() = up;
                pos() = 0;
        } else if (pos() != 0 && prevAtom()->asScriptInset()) {
-               prevAtom().nucleus()->asScriptInset()->ensure(up);
-               posLeft();
-               push(inset());
+               --pos();
+               nextAtom().nucleus()->asScriptInset()->ensure(up);
+               push(nextInset());
                idx() = up;
                pos() = lastpos();
        } else if (pos() != 0) {
                --pos();
                cell()[pos()] = MathAtom(new MathScriptInset(nextAtom(), up));
-               push(inset());
+               push(nextInset());
                idx() = up;
                pos() = 0;
        } else {
                plainInsert(MathAtom(new MathScriptInset(up)));
-               posLeft();
+               --pos();
                nextAtom().nucleus()->asScriptInset()->ensure(up);
-               push(inset());
+               push(nextInset());
                idx() = up;
                pos() = 0;
        }

Reply via email to