diff options
author | Eli Zaretskii <eliz@gnu.org> | 2011-08-19 13:18:40 +0300 |
---|---|---|
committer | Eli Zaretskii <eliz@gnu.org> | 2011-08-19 13:18:40 +0300 |
commit | 54a1215bccc20584285799c015a81f668b266bbc (patch) | |
tree | c870777f750687615733292d31f31be2c1fa2a88 /lisp | |
parent | f08670270206439ed672793573159c611a6f1379 (diff) | |
download | emacs-54a1215bccc20584285799c015a81f668b266bbc.tar.gz emacs-54a1215bccc20584285799c015a81f668b266bbc.tar.bz2 emacs-54a1215bccc20584285799c015a81f668b266bbc.zip |
Fix bidi cursor motion when a line begins with a composed character.
src/xdisp.c (RECORD_MAX_MIN_POS): If the display element comes from
a composition, take its buffer position from IT->cmp_it.charpos.
Diffstat (limited to 'lisp')
-rw-r--r-- | lisp/minibuffer.el | 22 |
1 files changed, 18 insertions, 4 deletions
diff --git a/lisp/minibuffer.el b/lisp/minibuffer.el index 313298de97e..b82147b97f1 100644 --- a/lisp/minibuffer.el +++ b/lisp/minibuffer.el @@ -1119,13 +1119,27 @@ It also eliminates runs of equal strings." `(display (space :align-to ,column))) nil)))) (if (not (consp str)) - (put-text-property (point) (progn (insert str) (point)) + (put-text-property (point) + (progn + (insert (bidi-string-mark-left-to-right + str)) + (point)) 'mouse-face 'highlight) - (put-text-property (point) (progn (insert (car str)) (point)) + (put-text-property (point) + (progn + (insert + (bidi-string-mark-left-to-right + (car str))) + (point)) 'mouse-face 'highlight) - (add-text-properties (point) (progn (insert (cadr str)) (point)) + (add-text-properties (point) + (progn + (insert + (bidi-string-mark-left-to-right + (cadr str))) + (point)) '(mouse-face nil - face completions-annotations))) + face completions-annotations))) (cond ((eq completions-format 'vertical) ;; Vertical format |