X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=src%2Fmathed%2FInsetMathNest.cpp;h=8c835a0f7f06d25f8754b62944888a191e0b1f12;hb=b9765984c0e2d38b251b765cabfc9d23bf957a7a;hp=2941b4c32fbc9692e44af9451ec40af9e1092fa4;hpb=00e1771f945d7c32d67177f70ec56c6ccbe7dbd4;p=lyx.git diff --git a/src/mathed/InsetMathNest.cpp b/src/mathed/InsetMathNest.cpp index 2941b4c32f..8c835a0f7f 100644 --- a/src/mathed/InsetMathNest.cpp +++ b/src/mathed/InsetMathNest.cpp @@ -492,6 +492,10 @@ void InsetMathNest::doDispatch(Cursor & cur, FuncRequest & cmd) cur.autocorrect() = false; cur.clearTargetX(); cur.macroModeClose(); + if (cur.isRTL() ) + goto goto_char_backwards; + +goto_char_forwards: if (cur.pos() != cur.lastpos() && cur.openable(cur.nextAtom())) { cur.pushLeft(*cur.nextAtom().nucleus()); cur.inset().idxFirst(cur); @@ -511,6 +515,10 @@ void InsetMathNest::doDispatch(Cursor & cur, FuncRequest & cmd) cur.autocorrect() = false; cur.clearTargetX(); cur.macroModeClose(); + if (cur.isRTL()) + goto goto_char_forwards; + +goto_char_backwards: if (cur.pos() != 0 && cur.openable(cur.prevAtom())) { cur.posLeft(); cur.push(*cur.nextAtom().nucleus());