From: Kenichi Handa Date: Thu, 26 Aug 2010 00:47:34 +0000 (+0900) Subject: xdisp.c (compute_stop_pos): Pay attention to bidi scan direction on calling compositi... X-Git-Tag: emacs-pretest-24.0.90~104^2~275^2~438^2~48^2~236 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=fe50eb41eac9d38909937f7da3bf394b96fb44af;p=emacs.git xdisp.c (compute_stop_pos): Pay attention to bidi scan direction on calling composition_compute_stop_pos. --- diff --git a/src/ChangeLog b/src/ChangeLog index 39f168dc8a4..8a3714bcf0d 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,8 @@ +2010-08-26 Kenichi Handa + + * xdisp.c (compute_stop_pos): Pay attention to bidi scan direction + on calling composition_compute_stop_pos. + 2010-08-25 Kenichi Handa * fontset.c (reorder_font_vector): Prefer a font-spec specifying diff --git a/src/xdisp.c b/src/xdisp.c index 93fdb68eeac..07078a199a3 100644 --- a/src/xdisp.c +++ b/src/xdisp.c @@ -3177,7 +3177,7 @@ compute_stop_pos (struct it *it) { register INTERVAL iv, next_iv; Lisp_Object object, limit, position; - EMACS_INT charpos, bytepos; + EMACS_INT charpos, bytepos, stoppos; /* If nowhere else, stop at the end. */ it->stop_charpos = it->end_charpos; @@ -3267,8 +3267,12 @@ compute_stop_pos (struct it *it) } } + if (it->bidi_p && it->bidi_it.scan_dir < 0) + stoppos = -1; + else + stoppos = it->stop_charpos; composition_compute_stop_pos (&it->cmp_it, charpos, bytepos, - it->stop_charpos, it->string); + stoppos, it->string); xassert (STRINGP (it->string) || (it->stop_charpos >= BEGV