diff options
author | Chong Yidong <[email protected]> | 2011-07-07 12:18:25 -0400 |
---|---|---|
committer | Chong Yidong <[email protected]> | 2011-07-07 12:18:25 -0400 |
commit | 412f24b9ddf1e07022f8c5fe05f0717f130c4c02 (patch) | |
tree | cf8450140b0907d14ac4dbdcf025f033a992bc98 /src | |
parent | af0905c84a232b034b4f792847aa05531f8cdefc (diff) | |
parent | 15fa4783a39e7a8d99cc6b5e783307c08b25a823 (diff) |
Merge from emacs-23 branch
Diffstat (limited to 'src')
-rw-r--r-- | src/ChangeLog | 7 | ||||
-rw-r--r-- | src/composite.c | 1 | ||||
-rw-r--r-- | src/xdisp.c | 5 |
3 files changed, 13 insertions, 0 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index 6485ed0802..9186061530 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,10 @@ +2011-07-07 Kenichi Handa <[email protected]> + + * composite.c (composition_compute_stop_pos): Ignore a static + composition starting before CHARPOS (Bug#8915). + + * xdisp.c (handle_composition_prop): Likewise. + 2011-07-07 Eli Zaretskii <[email protected]> * term.c (produce_glyphs) <xassert>: Allow IT_GLYPHLESS in it->what. diff --git a/src/composite.c b/src/composite.c index 577640f6fb..cf1e053f02 100644 --- a/src/composite.c +++ b/src/composite.c @@ -1026,6 +1026,7 @@ composition_compute_stop_pos (struct composition_it *cmp_it, EMACS_INT charpos, /* FIXME: Bidi is not yet handled well in static composition. */ if (charpos < endpos && find_composition (charpos, endpos, &start, &end, &prop, string) + && start >= charpos && COMPOSITION_VALID_P (start, end, prop)) { cmp_it->stop_pos = endpos = start; diff --git a/src/xdisp.c b/src/xdisp.c index a99f06a4e4..774bc22699 100644 --- a/src/xdisp.c +++ b/src/xdisp.c @@ -4583,6 +4583,11 @@ handle_composition_prop (struct it *it) && COMPOSITION_VALID_P (start, end, prop) && (STRINGP (it->string) || (PT <= start || PT >= end))) { + if (start < pos) + /* As we can't handle this situation (perhaps font-lock added + a new composition), we just return here hoping that next + redisplay will detect this composition much earlier. */ + return HANDLED_NORMALLY; if (start != pos) { if (STRINGP (it->string)) |