changeset 61663:59371ed3045c

(setup_for_ellipsis): Reset saved_face_id to use default face unless last visible char and first invisible char have the same face. Also use default face if saved_face_id is undefined.
author Kim F. Storm <storm@cua.dk>
date Tue, 19 Apr 2005 12:52:02 +0000
parents 732773b25b5d
children 79b58e05730b
files src/xdisp.c
diffstat 1 files changed, 4 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/src/xdisp.c	Tue Apr 19 12:51:37 2005 +0000
+++ b/src/xdisp.c	Tue Apr 19 12:52:02 2005 +0000
@@ -3386,11 +3386,11 @@
   it->current.dpvec_index = 0;
   it->dpvec_face_id = -1;
 
-#if 0  /* Already saved in handle_stop */
   /* Remember the current face id in case glyphs specify faces.
-     IT's face is restored in set_iterator_to_next.  */
-  it->saved_face_id = it->face_id;
-#endif
+     IT's face is restored in set_iterator_to_next.
+     saved_face_id was set to preceding char's face in handle_stop.  */
+  if (it->saved_face_id < 0 || it->saved_face_id != it->face_id)
+    it->saved_face_id = it->face_id = DEFAULT_FACE_ID;
 
   it->method = GET_FROM_DISPLAY_VECTOR;
   it->ellipsis_p = 1;