aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorEli Zaretskii2015-08-08 16:55:26 +0300
committerEli Zaretskii2015-08-08 16:55:26 +0300
commit1bb08a8cb10f0b8aa862d93a57edf70591fd135e (patch)
tree35bf796ed208205d57033f08c929a5c9bcf4321d /src
parent7afa4f300b9dc38bf3f33b18fa83bfe35e21a479 (diff)
downloademacs-1bb08a8cb10f0b8aa862d93a57edf70591fd135e.tar.gz
emacs-1bb08a8cb10f0b8aa862d93a57edf70591fd135e.zip
Fix overlay string display regressions introduced in Emacs 24.5
* src/xdisp.c (pop_it): Reset the flag to ignore overlays at this buffer position, if we move the iterator to a new position as result of jumping over text covered by a "replacing" display property. * test/redisplay-testsuite.el (test-redisplay-4): Add 2 new tests.
Diffstat (limited to 'src')
-rw-r--r--src/xdisp.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/xdisp.c b/src/xdisp.c
index e7626d1ce25..711fe080b03 100644
--- a/src/xdisp.c
+++ b/src/xdisp.c
@@ -5972,6 +5972,7 @@ pop_it (struct it *it)
5972{ 5972{
5973 struct iterator_stack_entry *p; 5973 struct iterator_stack_entry *p;
5974 bool from_display_prop = it->from_disp_prop_p; 5974 bool from_display_prop = it->from_disp_prop_p;
5975 ptrdiff_t prev_pos = IT_CHARPOS (*it);
5975 5976
5976 eassert (it->sp > 0); 5977 eassert (it->sp > 0);
5977 --it->sp; 5978 --it->sp;
@@ -6060,6 +6061,11 @@ pop_it (struct it *it)
6060 && IT_STRING_BYTEPOS (*it) == it->bidi_it.bytepos) 6061 && IT_STRING_BYTEPOS (*it) == it->bidi_it.bytepos)
6061 || (CONSP (it->object) && it->method == GET_FROM_STRETCH)); 6062 || (CONSP (it->object) && it->method == GET_FROM_STRETCH));
6062 } 6063 }
6064 /* If we move the iterator over text covered by a display property
6065 to a new buffer position, any info about previously seen overlays
6066 is no longer valid. */
6067 if (from_display_prop && it->sp == 0 && CHARPOS (it->position) != prev_pos)
6068 it->ignore_overlay_strings_at_pos_p = false;
6063} 6069}
6064 6070
6065 6071