GNU bug report logs - #25
frame parameter menu-bar-lines changes height of frame

Previous Next

Package: emacs;

Reported by: "Drew Adams" <drew.adams <at> oracle.com>

Date: Fri, 29 Feb 2008 09:15:04 UTC

Severity: wishlist

Merged with 14795

Done: martin rudalics <rudalics <at> gmx.at>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: help-debbugs <at> gnu.org (GNU bug Tracking System)
To: Juanma Barranquero <lekktu <at> gmail.com>
Subject: bug#14795: closed (Re: frame parameter menu-bar-lines changes
 height of frame)
Date: Wed, 31 Dec 2014 18:37:04 +0000
[Message part 1 (text/plain, inline)]
Your bug report

#25: height parameter inconsistent in new vs existing frames when tool-bar is enabled

which was filed against the emacs package, has been closed.

The explanation is attached below, along with your original report.
If you require more details, please reply to 14795 <at> debbugs.gnu.org.

-- 
25: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=25
GNU Bug Tracking System
Contact help-debbugs <at> gnu.org with problems
[Message part 2 (message/rfc822, inline)]
From: martin rudalics <rudalics <at> gmx.at>
To: drew.adams <at> oracle.com, 25-done <at> debbugs.gnu.org
Subject: Re: frame parameter menu-bar-lines changes height of frame
Date: Wed, 31 Dec 2014 19:36:36 +0100
> > emacs -Q
> >
> > (make-frame '((width . 70)(height . 50)))
> > (modify-frame-parameters (selected-frame) '((menu-bar-lines . 0)))
> > (frame-parameters)
> > (modify-frame-parameters (selected-frame) '((menu-bar-lines . 1)))
> > (frame-parameters)
> >
> > Adding and removing a menu-bar line changes the visible height of the
> > frame (incorrect), but it does not change the `height' frame
> > parameter. The correct behavior is that observed for `tool-bar-lines':
> > neither the visible frame height nor the `height' parameter is
> > changed.
>
> Use (assq 'height (frame-parameters)) to see that the `height'
> parameter does not change.

This can now be handled on trunk/master by adding 'menu-bar-lines' to
`frame-inhibit-implied-resize'.  Bug closed.

Thanks, martin

[Message part 3 (message/rfc822, inline)]
From: Juanma Barranquero <lekktu <at> gmail.com>
To: Bug-Gnu-Emacs <bug-gnu-emacs <at> gnu.org>
Subject: height parameter inconsistent in new vs existing frames when tool-bar
 is enabled
Date: Fri, 5 Jul 2013 00:52:22 +0200
Package: emacs


This happens since at least 22.1, and I think has been discussed
before on emacs-devel, but I've been unable to find the reference.

  emacs -Q

 (let ((params '((height . 25))))
  (make-frame params)  ;; f1
  (modify-frame-parameters (make-frame) params))  ;; f2

  f1 = 28 lines
  f2 = 25 lines

Adding (tool-bar-lines . 0) to params, both frames are 25 lines.

Obviously, when creating the frame Emacs is allowing three additional
lines as space for the toolbar. tool-bar-mode defaults to 3 in a newly
created frame, at least once it has been displayed:

(let ((f (make-frame)))
  (cons (frame-parameter f 'tool-bar-lines)
        (progn
          (sit-for 0)
          (frame-parameter f 'tool-bar-lines))))

=> (1 . 3)

Does that happen in all platforms? If so, shouldn't we make the
meaning of the height frame parameter consistent in all its uses?



This bug report was last modified 10 years and 143 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.