GNU bug report logs -
#24642
26.0.50; Missing mode-line on initial frame
Previous Next
Reported by: martin rudalics <rudalics <at> gmx.at>
Date: Sat, 8 Oct 2016 16:18:01 UTC
Severity: normal
Found in version 26.0.50
Done: Eli Zaretskii <eliz <at> gnu.org>
Bug is archived. No further changes may be made.
To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 24642 in the body.
You can then email your comments to 24642 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#24642
; Package
emacs
.
(Sat, 08 Oct 2016 16:18:01 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
martin rudalics <rudalics <at> gmx.at>
:
New bug report received and forwarded. Copy sent to
bug-gnu-emacs <at> gnu.org
.
(Sat, 08 Oct 2016 16:18:01 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
With the following file missing-mode-line.el
(defvar old (selected-frame))
(defvar new (make-frame '((minibuffer . nil))))
(set-frame-width new 1640 nil t)
(set-frame-width old 400 nil t)
(set-frame-position new 0 0)
(set-frame-position old -1 -40)
and
emacs -Q -load "~/missing-mode-line.el"
I get on Windows XP two frames where the root window of the smaller one
has a missing mode-line. The mode-line reappears when that frame gets
focus. It's a minor issue but cannot be reproduced here with Emacs 25.
It's easily possible that I introduced the bug myself but I don't recall
changing anything in this area. So if this rings a bell ...
In GNU Emacs 26.0.50.1 (i686-pc-mingw32)
of 2016-10-08 built on MACHNO
Repository revision: 9adfb021df482c6aa94a043f07acf1e8eb695bf2
Windowing system distributor 'Microsoft Corp.', version 5.1.2600
Configured using:
'configure --prefix=/c/emacs-git/quick --with-gnutls=no --with-wide-int
--enable-checking=yes --enable-check-lisp-object-type=yes 'CFLAGS=-O0
-g3''
Configured features:
SOUND NOTIFY ACL TOOLKIT_SCROLL_BARS
martin
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#24642
; Package
emacs
.
(Sun, 20 Nov 2016 16:24:02 GMT)
Full text and
rfc822 format available.
Message #8 received at 24642 <at> debbugs.gnu.org (full text, mbox):
> Date: Sat, 08 Oct 2016 18:17:29 +0200
> From: martin rudalics <rudalics <at> gmx.at>
>
> With the following file missing-mode-line.el
>
>
> (defvar old (selected-frame))
> (defvar new (make-frame '((minibuffer . nil))))
>
> (set-frame-width new 1640 nil t)
> (set-frame-width old 400 nil t)
> (set-frame-position new 0 0)
> (set-frame-position old -1 -40)
>
>
> and
>
> emacs -Q -load "~/missing-mode-line.el"
>
> I get on Windows XP two frames where the root window of the smaller one
> has a missing mode-line. The mode-line reappears when that frame gets
> focus. It's a minor issue but cannot be reproduced here with Emacs 25.
>
> It's easily possible that I introduced the bug myself but I don't recall
> changing anything in this area. So if this rings a bell ...
Sorry for a late response.
In fact, not just the mode line was missing, but the entire frame
contents was not displayed, just an empty frame.
No bells rang here, but the patch below solves this for me. Does it
make sense? (Don't ask me how it works on emacs-25, it looks like
some lucky coincidence with timing of the WM_PAINT message and the way
we set windows_or_buffers_changed.)
diff --git a/src/w32term.c b/src/w32term.c
index e8d66c9..ae0f741 100644
--- a/src/w32term.c
+++ b/src/w32term.c
@@ -4628,11 +4628,18 @@ w32_read_socket (struct terminal *terminal,
}
else
{
- HDC hdc = get_frame_dc (f);
+ /* Erase background again for safety. But don't do
+ that if the frame's 'garbaged' flag is set, since
+ in that case expose_frame will do nothing, and if
+ the various redisplay flags happen to be unset,
+ we are left with a blank frame. */
+ if (!FRAME_GARBAGED_P (f))
+ {
+ HDC hdc = get_frame_dc (f);
- /* Erase background again for safety. */
- w32_clear_rect (f, hdc, &msg.rect);
- release_frame_dc (f, hdc);
+ w32_clear_rect (f, hdc, &msg.rect);
+ release_frame_dc (f, hdc);
+ }
expose_frame (f,
msg.rect.left,
msg.rect.top,
diff --git a/src/xdisp.c b/src/xdisp.c
index c045ced..1420a4a 100644
--- a/src/xdisp.c
+++ b/src/xdisp.c
@@ -14116,6 +14116,7 @@ redisplay_internal (void)
if (f->updated_p)
{
f->redisplay = false;
+ f->garbaged = false;
mark_window_display_accurate (f->root_window, true);
if (FRAME_TERMINAL (f)->frame_up_to_date_hook)
FRAME_TERMINAL (f)->frame_up_to_date_hook (f);
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#24642
; Package
emacs
.
(Sun, 20 Nov 2016 17:11:01 GMT)
Full text and
rfc822 format available.
Message #11 received at 24642 <at> debbugs.gnu.org (full text, mbox):
> In fact, not just the mode line was missing, but the entire frame
> contents was not displayed, just an empty frame.
Indeed. I didn't notice since the upper part was obscured by the other
frame.
> No bells rang here, but the patch below solves this for me. Does it
> make sense? (Don't ask me how it works on emacs-25, it looks like
> some lucky coincidence with timing of the WM_PAINT message and the way
> we set windows_or_buffers_changed.)
It solves the problem so please apply it. If it causes other problems,
they will show up soon enough.
Thanks for the fix, martin
Reply sent
to
Eli Zaretskii <eliz <at> gnu.org>
:
You have taken responsibility.
(Sun, 20 Nov 2016 17:30:02 GMT)
Full text and
rfc822 format available.
Notification sent
to
martin rudalics <rudalics <at> gmx.at>
:
bug acknowledged by developer.
(Sun, 20 Nov 2016 17:30:02 GMT)
Full text and
rfc822 format available.
Message #16 received at 24642-done <at> debbugs.gnu.org (full text, mbox):
> Date: Sun, 20 Nov 2016 18:10:18 +0100
> From: martin rudalics <rudalics <at> gmx.at>
> CC: 24642 <at> debbugs.gnu.org
>
> > No bells rang here, but the patch below solves this for me. Does it
> > make sense? (Don't ask me how it works on emacs-25, it looks like
> > some lucky coincidence with timing of the WM_PAINT message and the way
> > we set windows_or_buffers_changed.)
>
> It solves the problem so please apply it.
Done.
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Mon, 19 Dec 2016 12:24:03 GMT)
Full text and
rfc822 format available.
This bug report was last modified 8 years and 238 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.