changeset 6721:26e4c96d8b63

(display_text_line): minibuffer_prompt_width is a distance, not an absolute position.
author Karl Heuer <kwzh@gnu.org>
date Thu, 07 Apr 1994 04:22:54 +0000
parents 9ecffdca3b7a
children dd74576b79f6
files src/xdisp.c
diffstat 1 files changed, 9 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/src/xdisp.c	Thu Apr 07 04:13:55 1994 +0000
+++ b/src/xdisp.c	Thu Apr 07 04:22:54 1994 +0000
@@ -2076,10 +2076,16 @@
       && vpos == XFASTINT (w->top))
     {
       if (minibuf_prompt)
-	hpos = display_string (w, vpos, minibuf_prompt, -1, hpos,
+	{
+	  minibuf_prompt_width
+	    = (display_string (w, vpos, minibuf_prompt, -1, hpos,
 			       (!truncate ? continuer : truncator),
-			       1, -1, -1);
-      minibuf_prompt_width = hpos;
+			       1, -1, -1)
+	       - hpos);
+	  hpos += minibuf_prompt_width;
+	}
+      else
+	minibuf_prompt_width = 0;
     }
 
   desired_glyphs->bufp[vpos] = pos;