aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorJim Blandy1993-02-14 14:39:45 +0000
committerJim Blandy1993-02-14 14:39:45 +0000
commit1f40cad246221a6d2d1976dabf8d8a93f1914c87 (patch)
tree69d0fda7db112a55ae3a1808c058c4465113f375 /src
parent832a07261f026605a57c146fb023f8d3cce4fbb7 (diff)
downloademacs-1f40cad246221a6d2d1976dabf8d8a93f1914c87.tar.gz
emacs-1f40cad246221a6d2d1976dabf8d8a93f1914c87.zip
* xdisp.c (message): Set echo_frame to the frame whose message buf
we want to use, not to the message buf itself. * xdisp.c (message): Use the message buffer of the frame we're going to display the message on to format the message, not that of the selected frame.
Diffstat (limited to 'src')
-rw-r--r--src/xdisp.c60
1 files changed, 37 insertions, 23 deletions
diff --git a/src/xdisp.c b/src/xdisp.c
index 8ad0b6be119..7acd1bfa9e1 100644
--- a/src/xdisp.c
+++ b/src/xdisp.c
@@ -233,36 +233,50 @@ message (m, a1, a2, a3)
233 fflush (stderr); 233 fflush (stderr);
234 } 234 }
235 } 235 }
236 /* A null message buffer means that the frame hasn't really been 236 else if (INTERACTIVE)
237 initialized yet. Error messages get reported properly by
238 cmd_error, so this must be just an informative message; toss it. */
239 else if (INTERACTIVE && FRAME_MESSAGE_BUF (selected_frame))
240 { 237 {
241 if (m) 238 /* The frame whose minibuffer we're going to display the message on.
239 It may be larger than the selected frame, so we need
240 to use its buffer, not the selected frame's buffer. */
241 FRAME_PTR echo_frame;
242#ifdef MULTI_FRAME
243 choose_minibuf_frame ();
244 echo_frame = XFRAME (WINDOW_FRAME (XWINDOW (minibuf_window)));
245#else
246 echo_frame = selected_frame;
247#endif
248
249 /* A null message buffer means that the frame hasn't really been
250 initialized yet. Error messages get reported properly by
251 cmd_error, so this must be just an informative message; toss it. */
252 if (FRAME_MESSAGE_BUF (echo_frame))
242 { 253 {
243 { 254 if (m)
255 {
256 {
244#ifdef NO_ARG_ARRAY 257#ifdef NO_ARG_ARRAY
245 int a[3]; 258 int a[3];
246 a[0] = a1; 259 a[0] = a1;
247 a[1] = a2; 260 a[1] = a2;
248 a[2] = a3; 261 a[2] = a3;
249 262
250 doprnt (FRAME_MESSAGE_BUF (selected_frame), 263 doprnt (FRAME_MESSAGE_BUF (echo_frame),
251 FRAME_WIDTH (selected_frame), m, 0, 3, a); 264 FRAME_WIDTH (echo_frame), m, 0, 3, a);
252#else 265#else
253 doprnt (FRAME_MESSAGE_BUF (selected_frame), 266 doprnt (FRAME_MESSAGE_BUF (echo_frame),
254 FRAME_WIDTH (selected_frame), m, 0, 3, &a1); 267 FRAME_WIDTH (echo_frame), m, 0, 3, &a1);
255#endif /* NO_ARG_ARRAY */ 268#endif /* NO_ARG_ARRAY */
256 } 269 }
257 270
258 message1 (FRAME_MESSAGE_BUF (selected_frame)); 271 message1 (FRAME_MESSAGE_BUF (echo_frame));
259 } 272 }
260 else 273 else
261 message1 (0); 274 message1 (0);
262 275
263 /* Print should start at the beginning of the message 276 /* Print should start at the beginning of the message
264 buffer next time. */ 277 buffer next time. */
265 message_buf_print = 0; 278 message_buf_print = 0;
279 }
266 } 280 }
267} 281}
268 282