]> git.eshelyaron.com Git - emacs.git/commitdiff
(display_text_line): Use the face properties of the overlay arrow, if any.
authorRichard M. Stallman <rms@gnu.org>
Sun, 7 Aug 1994 04:50:05 +0000 (04:50 +0000)
committerRichard M. Stallman <rms@gnu.org>
Sun, 7 Aug 1994 04:50:05 +0000 (04:50 +0000)
src/xdisp.c

index 1e1ae928f8fc6cf04e055de086146908b9a85df7..571db0fc91dbc1374b548d5791c7bdb516b1ae51 100644 (file)
@@ -42,6 +42,8 @@ extern void set_frame_menubar ();
 extern int interrupt_input;
 extern int command_loop_level;
 
+extern Lisp_Object Qface;
+
 /* Nonzero means print newline before next minibuffer message.  */
 
 int noninteractive_need_newline;
@@ -2488,8 +2490,26 @@ display_text_line (w, start, vpos, hpos, taboffset)
 
       if (len > width)
        len = width;
-      for (i = 0; i < len; i++)
-       leftmargin[i] = p[i];
+      if (!NULL_INTERVAL_P (XSTRING (Voverlay_arrow_string)->intervals))
+       {
+         /* If the arrow string has text props, obey them when displaying.  */
+         for (i = 0; i < len; i++)
+           {
+             int c = p[i];
+             Lisp_Object face, ilisp;
+             int newface;
+
+             XFASTINT (ilisp) = i;
+             face = Fget_text_property (ilisp, Qface, Voverlay_arrow_string);
+             newface = compute_glyph_face_1 (f, face, 0);
+             leftmargin[i] = FAST_MAKE_GLYPH (c, newface);
+           }
+       }
+      else
+       {
+         for (i = 0; i < len; i++)
+           leftmargin[i] = p[i];
+       }
 
       /* Bug in SunOS 4.1.1 compiler requires this intermediate variable.  */
       arrow_end = (leftmargin - desired_glyphs->glyphs[vpos]) + len;