aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorEli Zaretskii2011-10-08 15:03:43 +0200
committerEli Zaretskii2011-10-08 15:03:43 +0200
commit7061c986301ecc3d69c73a9d8b6a51299bd4fb6a (patch)
tree34545f8e7e102c0a2975f6b21892d4fe8583dd2a /src
parent03669ccbad9fcaf6c29003d23f3e8bdecaab21b1 (diff)
downloademacs-7061c986301ecc3d69c73a9d8b6a51299bd4fb6a.tar.gz
emacs-7061c986301ecc3d69c73a9d8b6a51299bd4fb6a.zip
Fix cursor positioning in hscrolled lines with R2L characters.
src/xdisp.c (set_cursor_from_row): Fix cursor positioning in mixed L2R+R2L lines that are hscrolled on the left.
Diffstat (limited to 'src')
-rw-r--r--src/ChangeLog2
-rw-r--r--src/xdisp.c6
2 files changed, 7 insertions, 1 deletions
diff --git a/src/ChangeLog b/src/ChangeLog
index 3f93987c0f1..4409d5e7f60 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -2,6 +2,8 @@
2 2
3 * xdisp.c (hscroll_window_tree): Support hscroll in right-to-left 3 * xdisp.c (hscroll_window_tree): Support hscroll in right-to-left
4 lines. 4 lines.
5 (set_cursor_from_row): Fix cursor positioning in mixed L2R+R2L
6 lines that are hscrolled on the left.
5 7
6 * dispnew.c (buffer_posn_from_coords): Account for a possible 8 * dispnew.c (buffer_posn_from_coords): Account for a possible
7 presence of header-line. (Bug#4426) 9 presence of header-line. (Bug#4426)
diff --git a/src/xdisp.c b/src/xdisp.c
index 2fff6d9518c..e7fc1b4b37e 100644
--- a/src/xdisp.c
+++ b/src/xdisp.c
@@ -13890,7 +13890,11 @@ set_cursor_from_row (struct window *w, struct glyph_row *row,
13890 ? glyph_after > glyphs_end 13890 ? glyph_after > glyphs_end
13891 : glyph_after < glyphs_end))))) 13891 : glyph_after < glyphs_end)))))
13892 { 13892 {
13893 cursor = glyph_after; 13893 if (!match_with_avoid_cursor
13894 && row->truncated_on_left_p && pt_old < bpos_min)
13895 cursor = glyph_before;
13896 else
13897 cursor = glyph_after;
13894 x = -1; 13898 x = -1;
13895 } 13899 }
13896 else if (string_seen) 13900 else if (string_seen)