mirror of
https://git.lyx.org/repos/lyx.git
synced 2025-01-03 08:28:25 +00:00
Fix cursor movement in RTL embedded math insets by Elazar Leibovich.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18241 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
f5cfb824aa
commit
31c9218c7e
@ -492,6 +492,10 @@ void InsetMathNest::doDispatch(Cursor & cur, FuncRequest & cmd)
|
|||||||
cur.autocorrect() = false;
|
cur.autocorrect() = false;
|
||||||
cur.clearTargetX();
|
cur.clearTargetX();
|
||||||
cur.macroModeClose();
|
cur.macroModeClose();
|
||||||
|
if (cur.isRTL() )
|
||||||
|
goto goto_char_backwards;
|
||||||
|
|
||||||
|
goto_char_forwards:
|
||||||
if (cur.pos() != cur.lastpos() && cur.openable(cur.nextAtom())) {
|
if (cur.pos() != cur.lastpos() && cur.openable(cur.nextAtom())) {
|
||||||
cur.pushLeft(*cur.nextAtom().nucleus());
|
cur.pushLeft(*cur.nextAtom().nucleus());
|
||||||
cur.inset().idxFirst(cur);
|
cur.inset().idxFirst(cur);
|
||||||
@ -511,6 +515,10 @@ void InsetMathNest::doDispatch(Cursor & cur, FuncRequest & cmd)
|
|||||||
cur.autocorrect() = false;
|
cur.autocorrect() = false;
|
||||||
cur.clearTargetX();
|
cur.clearTargetX();
|
||||||
cur.macroModeClose();
|
cur.macroModeClose();
|
||||||
|
if (cur.isRTL())
|
||||||
|
goto goto_char_forwards;
|
||||||
|
|
||||||
|
goto_char_backwards:
|
||||||
if (cur.pos() != 0 && cur.openable(cur.prevAtom())) {
|
if (cur.pos() != 0 && cur.openable(cur.prevAtom())) {
|
||||||
cur.posLeft();
|
cur.posLeft();
|
||||||
cur.push(*cur.nextAtom().nucleus());
|
cur.push(*cur.nextAtom().nucleus());
|
||||||
|
Loading…
Reference in New Issue
Block a user