changeset 61656:23324e660890

(handle_stop): Set saved_face_id to current face if selective_display_ellipsis_p so ellipsis will be shown in same face as preceding text. (setup_for_ellipsis): Don't set saved_face_id here. (next_element_from_display_vector): Default to saved_face_id.
author Kim F. Storm <storm@cua.dk>
date Tue, 19 Apr 2005 10:11:41 +0000
parents 81c033739b60
children 8af99087c1e5
files src/xdisp.c
diffstat 1 files changed, 9 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/src/xdisp.c	Tue Apr 19 10:11:26 2005 +0000
+++ b/src/xdisp.c	Tue Apr 19 10:11:41 2005 +0000
@@ -2706,6 +2706,10 @@
   it->dpvec = NULL;
   it->current.dpvec_index = -1;
 
+  /* Use face of preceding text for ellipsis (if invisible) */
+  if (it->selective_display_ellipsis_p)
+    it->saved_face_id = it->face_id;
+
   do
     {
       handled = HANDLED_NORMALLY;
@@ -3382,9 +3386,12 @@
   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->method = GET_FROM_DISPLAY_VECTOR;
   it->ellipsis_p = 1;
 }
@@ -5423,6 +5430,8 @@
   /* Precondition.  */
   xassert (it->dpvec && it->current.dpvec_index >= 0);
 
+  it->face_id = it->saved_face_id;
+
   if (INTEGERP (*it->dpvec)
       && GLYPH_CHAR_VALID_P (XFASTINT (*it->dpvec)))
     {