all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* set-frame-size for frame without minibuffer loses mode line
@ 2007-08-07 16:46 Drew Adams
  2007-08-08  9:31 ` martin rudalics
  2007-10-09 11:33 ` Jason Rumney
  0 siblings, 2 replies; 8+ messages in thread
From: Drew Adams @ 2007-08-07 16:46 UTC (permalink / raw)
  To: Bug-Gnu-Emacs

emacs -Q

M-: (setq pop-up-frames t)
M-: (setq minibuffer-frame-alist (cons (quote (minibuffer . only))
                                       minibuffer-frame-alist))
M-: (setq default-frame-alist (cons (quote (minibuffer))
                                    default-frame-alist))
M-: (make-frame minibuffer-frame-alist)
C-x 4 d some directory

With the dired frame selected:
M-: (set-frame-size (selected-frame) 30 40)

The dired frame is correctly resized, but an empty extra line appears
below the mode line (there is no minibuffer on this frame).

With the dired frame selected, repeat the last command (that is,
repeat (set-frame-size (selected-frame) 30 40)):

C-x ESC ESC

Now, both the extra empty "minibuffer" line and the mode line have
disappeared.

The more serious bug is the disappearance of the mode line. No matter
how many times the `set-frame-size' is repeated, the mode line does
not reappear.

IOW, the first `set-frame-size' is OK (except for the extra blank
line), but repeating it removes the mode line.

This is not related to C-x ESC ESC or M-:. The same thing happens
from Lisp code that calls `set-frame-size'. If there is a standalone
minibuffer, then the problem arises.


In GNU Emacs 22.1.1 (i386-mingw-nt5.1.2600)
 of 2007-06-02 on RELEASE
Windowing system distributor `Microsoft Corp.', version 5.1.2600
configured using `configure --with-gcc (3.4) --cflags -Ic:/gnuwin32/include'

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: set-frame-size for frame without minibuffer loses mode line
  2007-08-07 16:46 set-frame-size for frame without minibuffer loses mode line Drew Adams
@ 2007-08-08  9:31 ` martin rudalics
  2007-08-08 14:13   ` Drew Adams
  2007-10-09 11:33 ` Jason Rumney
  1 sibling, 1 reply; 8+ messages in thread
From: martin rudalics @ 2007-08-08  9:31 UTC (permalink / raw)
  To: Bug-Gnu-Emacs

 > With the dired frame selected:
 > M-: (set-frame-size (selected-frame) 30 40)
 >
 > The dired frame is correctly resized, but an empty extra line appears
 > below the mode line (there is no minibuffer on this frame).

Does this wrap the menu-bar of the selected frame?  That is, do you get
two menu-bar lines instead of one?  Does the extra line appear when the
menu-bar does not wrap?

 > With the dired frame selected, repeat the last command (that is,
 > repeat (set-frame-size (selected-frame) 30 40)):
 >
 > C-x ESC ESC
 >
 > Now, both the extra empty "minibuffer" line and the mode line have
 > disappeared.
 >
 > The more serious bug is the disappearance of the mode line. No matter
 > how many times the `set-frame-size' is repeated, the mode line does
 > not reappear.

What do you use to make it reappear?

^ permalink raw reply	[flat|nested] 8+ messages in thread

* RE: set-frame-size for frame without minibuffer loses mode line
  2007-08-08  9:31 ` martin rudalics
@ 2007-08-08 14:13   ` Drew Adams
  2007-08-08 15:28     ` martin rudalics
  0 siblings, 1 reply; 8+ messages in thread
From: Drew Adams @ 2007-08-08 14:13 UTC (permalink / raw)
  To: martin rudalics, Bug-Gnu-Emacs

>  > With the dired frame selected:
>  > M-: (set-frame-size (selected-frame) 30 40)
>  >
>  > The dired frame is correctly resized, but an empty extra line appears
>  > below the mode line (there is no minibuffer on this frame).
>
> Does this wrap the menu-bar of the selected frame?
> That is, do you get two menu-bar lines instead of one?

Yes.

> Does the extra line appear when the menu-bar does not wrap?

No. That is, there seems to be no problem when the new size does not cause
the menu-bar to wrap.

>  > With the dired frame selected, repeat the last command (that is,
>  > repeat (set-frame-size (selected-frame) 30 40)):
>  >
>  > C-x ESC ESC
>  >
>  > Now, both the extra empty "minibuffer" line and the mode line have
>  > disappeared.

This problem (the main one) also only happens when the menu-bar wraps.

>  > The more serious bug is the disappearance of the mode line. No matter
>  > how many times the `set-frame-size' is repeated, the mode line does
>  > not reappear.
>
> What do you use to make it reappear?

Nothing. It does not reappear. But, as you suggested, the problem only
happens when the new width is small enough that the menu-bar must wrap.

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: set-frame-size for frame without minibuffer loses mode line
  2007-08-08 14:13   ` Drew Adams
@ 2007-08-08 15:28     ` martin rudalics
  0 siblings, 0 replies; 8+ messages in thread
From: martin rudalics @ 2007-08-08 15:28 UTC (permalink / raw)
  To: Drew Adams; +Cc: Bug-Gnu-Emacs

 >>Does this wrap the menu-bar of the selected frame?
 >>That is, do you get two menu-bar lines instead of one?
 >
 >
 > Yes.
 >
 >
 >>Does the extra line appear when the menu-bar does not wrap?
 >
 >
 > No. That is, there seems to be no problem when the new size does not cause
 > the menu-bar to wrap.

Here

(set-frame-size (selected-frame) 30 40)

is sufficient to reproduce the bug, provided it makes the menu-bar wrap.

 >> > With the dired frame selected, repeat the last command (that is,
 >> > repeat (set-frame-size (selected-frame) 30 40)):
 >> >
 >> > C-x ESC ESC
 >> >
 >> > Now, both the extra empty "minibuffer" line and the mode line have
 >> > disappeared.
 >
 >
 > This problem (the main one) also only happens when the menu-bar wraps.

This problem looks like a consequence of the first one.

 >> > The more serious bug is the disappearance of the mode line. No matter
 >> > how many times the `set-frame-size' is repeated, the mode line does
 >> > not reappear.
 >>
 >>What do you use to make it reappear?
 >
 >
 > Nothing. It does not reappear. But, as you suggested, the problem only
 > happens when the new width is small enough that the menu-bar must wrap.

Here the only way to make it reappear is to push the maximize button of
the frame.

We have to check first whether this bug is Windows specific or can be
reproduced on GNU/Linux too.  Could someone please try?

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: set-frame-size for frame without minibuffer loses mode line
  2007-08-07 16:46 set-frame-size for frame without minibuffer loses mode line Drew Adams
  2007-08-08  9:31 ` martin rudalics
@ 2007-10-09 11:33 ` Jason Rumney
  2007-10-09 14:19   ` Drew Adams
  1 sibling, 1 reply; 8+ messages in thread
From: Jason Rumney @ 2007-10-09 11:33 UTC (permalink / raw)
  To: Drew Adams; +Cc: Bug-Gnu-Emacs

Drew Adams wrote:
> emacs -Q
>
> M-: (setq pop-up-frames t)
> M-: (setq minibuffer-frame-alist (cons (quote (minibuffer . only))
>                                        minibuffer-frame-alist))
> M-: (setq default-frame-alist (cons (quote (minibuffer))
>                                     default-frame-alist))
> M-: (make-frame minibuffer-frame-alist)
> C-x 4 d some directory
>
> With the dired frame selected:
> M-: (set-frame-size (selected-frame) 30 40)
>
> The dired frame is correctly resized, but an empty extra line appears
> below the mode line (there is no minibuffer on this frame).
>   
There is for me, and the default-frame-alist above seems to suggest that
there should be if I am understanding it correctly.

> With the dired frame selected, repeat the last command (that is,
> repeat (set-frame-size (selected-frame) 30 40)):
>
> C-x ESC ESC
>
> Now, both the extra empty "minibuffer" line and the mode line have
> disappeared. 
>   

I have checked in a change that seems to fix the minibuffer disappearing
completely. There is still some strange behaviour, such as the extra
blank line at the bottom of the frame after the first resize, which
seems to be caused by the menu-bar wrapping automatically when the frame
is resized, but that happens asynchronously, so the Lisp code makes
certain assumptions that later turn out to be invalid.







^ permalink raw reply	[flat|nested] 8+ messages in thread

* RE: set-frame-size for frame without minibuffer loses mode line
  2007-10-09 11:33 ` Jason Rumney
@ 2007-10-09 14:19   ` Drew Adams
  2007-10-09 15:07     ` Jason Rumney
  0 siblings, 1 reply; 8+ messages in thread
From: Drew Adams @ 2007-10-09 14:19 UTC (permalink / raw)
  To: Jason Rumney; +Cc: Bug-Gnu-Emacs

> > emacs -Q
> >
> > M-: (setq pop-up-frames t)
> > M-: (setq minibuffer-frame-alist (cons (quote (minibuffer . only))
> >                                        minibuffer-frame-alist))
> > M-: (setq default-frame-alist (cons (quote (minibuffer))
> >                                     default-frame-alist))
> > M-: (make-frame minibuffer-frame-alist)
> > C-x 4 d some directory
> >
> > With the dired frame selected:
> > M-: (set-frame-size (selected-frame) 30 40)
> >
> > The dired frame is correctly resized, but an empty extra line appears
> > below the mode line (there is no minibuffer on this frame).
>
> There is for me, and the default-frame-alist above seems to suggest that
> there should be if I am understanding it correctly.

There is an extra empty line, but there should not be a minibuffer.

An entry of (minibuffer) in `default-frame-alist' means there is no
minibuffer - the `minibuffer' frame parameter value is nil. See node `Buffer
Parameters' of the Elisp manual:

  `minibuffer'
     Whether this frame has its own minibuffer.  The value `t' means
     yes, `nil' means no, `only' means this frame is just a minibuffer.
     If the value is a minibuffer window (in some other frame), the
     new frame uses that minibuffer.

> > With the dired frame selected, repeat the last command (that is,
> > repeat (set-frame-size (selected-frame) 30 40)):
> >
> > C-x ESC ESC
> >
> > Now, both the extra empty "minibuffer" line and the mode line have
> > disappeared.
>
> I have checked in a change that seems to fix the minibuffer disappearing
> completely. There is still some strange behaviour, such as the extra
> blank line at the bottom of the frame after the first resize, which
> seems to be caused by the menu-bar wrapping automatically when the frame
> is resized, but that happens asynchronously, so the Lisp code makes
> certain assumptions that later turn out to be invalid.

Is there a Lisp patch I can used to check the fix, or is it in C sources?






^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: set-frame-size for frame without minibuffer loses mode line
  2007-10-09 14:19   ` Drew Adams
@ 2007-10-09 15:07     ` Jason Rumney
  2007-10-09 15:28       ` Drew Adams
  0 siblings, 1 reply; 8+ messages in thread
From: Jason Rumney @ 2007-10-09 15:07 UTC (permalink / raw)
  To: Drew Adams; +Cc: Bug-Gnu-Emacs

Drew Adams wrote:
> There is an extra empty line, but there should not be a minibuffer.
>   
I missed the 4 in C-x 4 d.

> Is there a Lisp patch I can used to check the fix, or is it in C sources?
>   

The patch is in w32term.c, currently only on the EMACS_22_BASE branch.





^ permalink raw reply	[flat|nested] 8+ messages in thread

* RE: set-frame-size for frame without minibuffer loses mode line
  2007-10-09 15:07     ` Jason Rumney
@ 2007-10-09 15:28       ` Drew Adams
  0 siblings, 0 replies; 8+ messages in thread
From: Drew Adams @ 2007-10-09 15:28 UTC (permalink / raw)
  To: Jason Rumney; +Cc: Bug-Gnu-Emacs

> > There is an extra empty line, but there should not be a minibuffer.
>
> I missed the 4 in C-x 4 d.
>
> > Is there a Lisp patch I can used to check the fix, or is it in
> C sources?
>
> The patch is in w32term.c, currently only on the EMACS_22_BASE branch.

OK, thanks for fixing this, Jason. I will wait until I can get a Windows
binary with the fix to check it out.





^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2007-10-09 15:28 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-08-07 16:46 set-frame-size for frame without minibuffer loses mode line Drew Adams
2007-08-08  9:31 ` martin rudalics
2007-08-08 14:13   ` Drew Adams
2007-08-08 15:28     ` martin rudalics
2007-10-09 11:33 ` Jason Rumney
2007-10-09 14:19   ` Drew Adams
2007-10-09 15:07     ` Jason Rumney
2007-10-09 15:28       ` Drew Adams

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.