GNU bug report logs - #21415
25.0.50; Emacs Trunk -- pixelwise width/height for x-create-frame

Previous Next

Package: emacs;

Reported by: Keith David Bershatsky <esq <at> lawlist.com>

Date: Fri, 4 Sep 2015 17:43:01 UTC

Severity: wishlist

Found in version 25.0.50

Done: Lars Ingebrigtsen <larsi <at> gnus.org>

Bug is archived. No further changes may be made.

Full log


Message #65 received at 21415 <at> debbugs.gnu.org (full text, mbox):

From: Keith David Bershatsky <esq <at> lawlist.com>
To: martin rudalics <rudalics <at> gmx.at>
Cc: 21415 <at> debbugs.gnu.org
Subject: Re: bug#21415: 25.0.50;
 Emacs Trunk -- pixelwise width/height for x-create-frame
Date: Wed, 09 Sep 2015 17:46:51 -0700
The patch of `nsterm.m` has repaired much of the functionality of `frame-inhibit-implied-resize`.  The two tests that previously failed now work as expected:

     1.  From a maximized frame, I can change the `font` to Courier 18 using `set-face-attribute` and there is no need to set `frame-inhibit-implied-resize` in that circumstance.

     2.  From a frame that is smaller than the screen size, I can use `set-face-attribute` to change the font to Courier 18 provided that `frame-inhibit-implied-resize` is set to `t`.

The problem I am having is with a situation where `ns-auto-hide-menu-bar` is set to `t`.  As previously noted in this thread, the `top` frame parameter is ignored when making a new frame that is the size of the screen -- the new frame appears substantially above the top of the display -- i.e., one-half out of sight.  When the new frame is partially above the top of the screen, `set-face-attribute` substantially enlarges the frame even though `frame-inhibit-implied-resize` is set to `t`.  When the frame comes back into full view (e.g., top 0, left 0), it is then possible to apply `set-face-attribute` without altering the dimensions of the frame.  The following are two examples -- one example works, the other example is broken -- both rely upon `ns-auto-hide-menu-bar` being set to `t`.

(setq ns-auto-hide-menu-bar t)

;; WORKS
(let* (
    (frame-inhibit-implied-resize t)
    (frame
      (make-frame '(
         (vertical-scroll-bars)
         (left-fringe . 8)
         (right-fringe . 8)
         (width . 1259.0)
         (height . 771.0)
         (tool-bar-lines . 0)))) )
  (set-frame-position frame 0 0)
  (set-face-attribute 'default frame :font "-*-Courier-normal-normal-normal-*-18-*-*-*-m-0-iso10646-1"))

;; BROKEN
(let* (
    (frame-inhibit-implied-resize t)
    (frame
      (make-frame '(
        (font . "-*-Courier-normal-normal-normal-*-18-*-*-*-m-0-iso10646-1")
        (vertical-scroll-bars)
        (left-fringe . 8)
        (right-fringe . 8)
        (width . 1259.0)
        (height . 771.0)
        (tool-bar-lines . 0)))) )
  (set-frame-position frame 0 0))




This bug report was last modified 4 years and 251 days ago.

Previous Next


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