# HG changeset patch # User Kenichi Handa # Date 1263532440 -32400 # Node ID fd03fa91837d5e10fbd036e3ff1a264b42cf2156 # Parent 49daa9e9669fda0f782bf36807efd28518d141ad# Parent a6629254b6ba070cf9c4748f4d7b4161e650734d xdisp.c (CHAR_COMPOSED_P): New arg END_CHARPOS. Callers changed. diff -r 49daa9e9669f -r fd03fa91837d src/ChangeLog --- a/src/ChangeLog Thu Jan 14 19:59:04 2010 -0800 +++ b/src/ChangeLog Fri Jan 15 14:14:00 2010 +0900 @@ -1,3 +1,7 @@ +2010-01-15 Kenichi Handa + + * xdisp.c (CHAR_COMPOSED_P): New arg END_CHARPOS. Callers changed. + 2010-01-15 Chong Yidong * nsterm.m (Qnone): Define. diff -r 49daa9e9669f -r fd03fa91837d src/xdisp.c --- a/src/xdisp.c Thu Jan 14 19:59:04 2010 -0800 +++ b/src/xdisp.c Fri Jan 15 14:14:00 2010 +0900 @@ -5638,11 +5638,11 @@ /* Return 1 iff a character at CHARPOS (and BYTEPOS) is composed (possibly with the following characters). */ -#define CHAR_COMPOSED_P(IT,CHARPOS,BYTEPOS) \ +#define CHAR_COMPOSED_P(IT,CHARPOS,BYTEPOS,END_CHARPOS) \ ((IT)->cmp_it.id >= 0 \ || ((IT)->cmp_it.stop_pos == (CHARPOS) \ && composition_reseat_it (&(IT)->cmp_it, CHARPOS, BYTEPOS, \ - (IT)->end_charpos, (IT)->w, \ + END_CHARPOS, (IT)->w, \ FACE_FROM_ID ((IT)->f, (IT)->face_id), \ (IT)->string))) @@ -6300,7 +6300,7 @@ return 0; } else if (CHAR_COMPOSED_P (it, IT_STRING_CHARPOS (*it), - IT_STRING_BYTEPOS (*it)) + IT_STRING_BYTEPOS (*it), SCHARS (it->string)) && next_element_from_composition (it)) { return 1; @@ -6336,7 +6336,7 @@ CHARPOS (position) = BYTEPOS (position) = -1; } else if (CHAR_COMPOSED_P (it, IT_STRING_CHARPOS (*it), - IT_STRING_BYTEPOS (*it)) + IT_STRING_BYTEPOS (*it), it->string_nchars) && next_element_from_composition (it)) { return 1; @@ -6523,7 +6523,8 @@ && IT_CHARPOS (*it) >= it->redisplay_end_trigger_charpos) run_redisplay_end_trigger_hook (it); - if (CHAR_COMPOSED_P (it, IT_CHARPOS (*it), IT_BYTEPOS (*it)) + if (CHAR_COMPOSED_P (it, IT_CHARPOS (*it), IT_BYTEPOS (*it), + it->end_charpos) && next_element_from_composition (it)) { return 1;