Hi!While looking through the cursor movement code to fix the problems with the line skipping on Mac I started to clean it up a bit and most importantly to get the target_x logic working again. So do that (especially when moving out from the math insets into the text) a tighter integration of text and math (i.e. Cursor::up/down) cursor movement is needed to keep a valid target_x value. So I basically moved the cursorUp/Down from the Text class into the the Cursor class. Cursor::up/down can now handle either case, math and text. Moreover the left/right methods for text movement are now reasonable again, especially set the boundary correctly.
Attached is the patch and a test file for RTL. StefanP.S.: One minor known problem is that big insets (like labels) might "move" the target_x value. This should be tackled later as well, but not now.
P.P.S.: Isn't it intended to use the boundary flag also between font changes? I didn't find that in the trunk code, but saw some comment somewhere I think. Would make sense to add text on both sides of such a change. Comments?
cursor.patch
Description: Binary data
rtl.lyx
Description: Binary data
PGP.sig
Description: Signierter Teil der Nachricht