From: martin rudalics via "Bug reports for GNU Emacs, the Swiss army knife of text editors" <bug-gnu-emacs@gnu.org>
To: Reuben Thomas <rrt@sc3d.org>
Cc: Po Lu <luangruo@yahoo.com>, Eli Zaretskii <eliz@gnu.org>,
72986@debbugs.gnu.org
Subject: bug#72986: Disabling menu-bar-mode changes size of new frames
Date: Fri, 4 Oct 2024 17:01:25 +0200 [thread overview]
Message-ID: <3d0a1e9a-5efc-4491-ab85-e3e58cb0f068@gmx.at> (raw)
In-Reply-To: <CAOnWdoh4kG-TW2nHH4T91ZM=ztw+jx_8_N_iB8emkxuJYdg9Sg@mail.gmail.com>
> First frame with menu bar:
>
> Frame size history of #<frame *Minibuf-1* - GNU Emacs at dwks
> 0x59e577a85750>
> x_create_frame_1 (5), TS=80x25~>1280x875, NS=80x25~>1296x875,
> IS=80x25~>1296x875, MS=32x70 IH IV
> gui_figure_window_size (5), TS=1280x875~>1280x1260, TC=80x25~>80x36,
> NS=1296x875~>1296x1260, IS=1296x875~>1296x1260, MS=32x70 IH IV
> scroll-bar-width (3), NS=1296x1260~>1328x1260, IS=1296x1260~>1328x1260,
> MS=160x175
> scroll-bar-height (3), MS=160x175
> menu-bar-lines (2), MS=160x175
> x_create_frame_2 (0), MS=160x175
> xg_frame_set_char_size, invisible, PS=1328x1260, XS=1328x1260, DS=1328x1260
This is our first explicit call to set the frame size albeit for an
invisible frame.
> xg_frame_set_char_size (5), MS=32x70 IH IV
> x_make_frame_visible
> MapNotify, not hidden & not iconified, PS=1328x1260, DS=1328x1260
> ConfigureNotify, PS=1328x1260, XS=1328x1260, DS=1328x1260
So far I failed to notice that first ConfigureNotify following the
MapNotify. It comes with the expected values XS=1328x1260. Where on
earth does it come from ...
> xg_frame_resized, unchanged, PS=1328x1260, XS=1328x1260
> ConfigureNotify, PS=1328x1260, XS=1328x1258, DS=1328x1260
... and where does this with XS=1328x1258 come from? On my system, I
get just one ConfigureNotify for each xg_frame_set_char_size.
> xg_frame_resized, changed, PS=1328x1260, XS=1328x1258
> change_frame_size_1, delayed, PS=1328x1260, XS=1328x1258, DS=1328x1260
Here we steadfastly reject the 1258 pixels conceded to us ...
> tool-bar-lines (2), MS=160x175
> xg_frame_set_char_size, visible, PS=1328x1260, XS=1328x1260, DS=1328x1258
> +values, PS=664x654, XS=664x696
... ask again with 696 (/ (+ 1260 50 82) 2) ...
> ConfigureNotify, PS=1328x1260, XS=1328x1258, DS=1328x1258
> xg_frame_resized, changed, PS=1328x1260, XS=1328x1258, DS=1328x1258
> change_frame_size_1, delayed, PS=1328x1260, XS=1328x1258, DS=1328x1258
... and finally succumb because ConfigureNotify offers us those lousy
1258 pixels once more and we don't delay the change any more.
> change_frame_size (5), TS=1280x1260~>1280x1258, TC=80x36~>80x35,
> NS=1328x1260~>1328x1258, IS=1328x1260~>1328x1258, MS=32x70 IH IV
> set_window_configuration (4), MS=160x175 IH IV
We end up with 35 lines as before.
> First frame without menu bar:
>
> Frame size history of #<frame *Minibuf-1* - GNU Emacs at dwks
> 0x63f23d459690>
> x_create_frame_1 (5), TS=80x25~>1280x875, NS=80x25~>1296x875,
> IS=80x25~>1296x875, MS=32x70 IH IV
> gui_figure_window_size (5), TS=1280x875~>1280x1260, TC=80x25~>80x36,
> NS=1296x875~>1296x1260, IS=1296x875~>1296x1260, MS=32x70 IH IV
> scroll-bar-width (3), NS=1296x1260~>1328x1260, IS=1296x1260~>1328x1260,
> MS=160x175
> scroll-bar-height (3), MS=160x175
> menu-bar-lines (2), MS=160x175
> x_create_frame_2 (0), MS=160x175
> xg_frame_set_char_size, invisible, PS=1328x1260, XS=1328x1260, DS=1328x1260
> xg_frame_set_char_size (5), MS=32x70 IH IV
> x_make_frame_visible
> MapNotify, not hidden & not iconified, PS=1328x1260, DS=1328x1260
> ConfigureNotify, PS=1328x1260, XS=1328x1260, DS=1328x1260
> xg_frame_resized, unchanged, PS=1328x1260, XS=1328x1260
> menu-bar-lines (2), MS=160x175
> xg_frame_set_char_size, visible, PS=1328x1260, XS=1328x1260, DS=1328x1260
> +values, PS=664x655, XS=664x630
The 630 here are the next strange thing (they existed in all previous
runs you reported but I didn't notice them either). For some reason the
height of the tool bar is not added when we do not add the one of the
menu bar. This must be a bug on our side.
> ConfigureNotify, PS=1328x1260, XS=1328x1308, DS=1328x1260
This one is truly remarkable: 1308 is 1258 + 50 and 50 pixels are the
height of your menu bar. Why would anyone add the menu bar height here
when we just asked to not add neither the height of the menu nor that of
the tool bar?
> xg_frame_resized, changed, PS=1328x1260, XS=1328x1308
> change_frame_size_1, delayed, PS=1328x1260, XS=1328x1308, DS=1328x1260
> change_frame_size (5), TS=1280x1260~>1280x1308, TC=80x36~>80x37,
So this gets us 37 lines, one too many ...
> NS=1328x1260~>1328x1308, IS=1328x1260~>1328x1308, MS=32x70 IH IV
> tool-bar-lines (2), MS=160x175
> xg_frame_set_char_size, visible, PS=1328x1308, XS=1328x1308
> +values, PS=664x654, XS=664x695
> ConfigureNotify, PS=1328x1308, XS=1328x1176
> xg_frame_resized, changed, PS=1328x1308, XS=1328x1176
> change_frame_size_1, delayed, PS=1328x1308, XS=1328x1176
> change_frame_size (5), TS=1280x1308~>1280x1176, TC=80x37~>80x33,
... here we shrink back to 33 lines ...
> NS=1328x1308~>1328x1176, IS=1328x1308~>1328x1176, MS=32x70 IH IV
> ConfigureNotify, PS=1328x1176, XS=1328x1292
> xg_frame_resized, changed, PS=1328x1176, XS=1328x1292
> change_frame_size_1, delayed, PS=1328x1176, XS=1328x1292
> change_frame_size (5), TS=1280x1176~>1280x1292, TC=80x33~>80x36,
> NS=1328x1176~>1328x1292, IS=1328x1176~>1328x1292, MS=32x70 IH IV
... and here we get the correct number of lines albeit with a surplus of
12 pixels. How does that first frame without menu bar look to you?
> Second frame with menu bar:
>
> Frame size history of #<frame *Minibuf-1* 0x55cd2d33c8f0>
> x_create_frame_1 (5), TS=80x25~>1280x875, NS=80x25~>1296x875,
> IS=80x25~>1296x875, MS=32x70 IH IV
> gui_figure_window_size (5), TS=1280x875~>1280x1260, TC=80x25~>80x36,
> NS=1296x875~>1296x1260, IS=1296x875~>1296x1260, MS=32x70 IH IV
> scroll-bar-width (3), NS=1296x1260~>1328x1260, IS=1296x1260~>1328x1260,
> MS=160x175
> scroll-bar-height (3), MS=160x175
> menu-bar-lines (2), MS=160x175
> x_create_frame_2 (0), MS=160x175
> xg_frame_set_char_size, invisible, PS=1328x1260, XS=1328x1260, DS=1328x1260
> xg_frame_set_char_size (5), MS=32x70 IH IV
> x_make_frame_visible
> MapNotify, not hidden & not iconified, PS=1328x1260, DS=1328x1260
> ConfigureNotify, PS=1328x1260, XS=400x340, DS=1328x1260
This is the usual minimization attempt ...
> xg_frame_resized, changed, PS=1328x1260, XS=400x340
> change_frame_size_1, delayed, PS=1328x1260, XS=400x340, DS=1328x1260
> change_frame_size (5), TS=1280x1260~>352x340, TC=80x36~>22x9,
... which succeeds here. There's no good first ConfigureNotify event
and no second ConfigureNotify as with the initial frame. The remainder
can be ignored.
This time I'll have to look into our code first - something is fishy.
If there are any volunteers on GNOME who can apply a patch and check
whether they get the same either buggy or correct behavior, preferably
with a scaled screen, I'd be very, very grateful.
martin
next prev parent reply other threads:[~2024-10-04 15:01 UTC|newest]
Thread overview: 76+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-09-02 18:48 bug#72986: Disabling menu-bar-mode changes size of new frames Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-03 12:07 ` Eli Zaretskii
2024-09-03 12:09 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-03 15:52 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-03 15:59 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-03 17:03 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-03 17:29 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-03 17:42 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-04 8:01 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-04 11:23 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-04 12:12 ` Po Lu via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-04 13:05 ` Robert Pluim
2024-09-04 17:11 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-04 22:45 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-05 7:49 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-05 19:31 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-06 7:54 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-06 8:11 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-06 9:50 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-06 12:20 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-06 14:16 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-06 15:14 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-07 8:37 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-07 12:07 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-08 8:42 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-08 11:38 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-08 14:21 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-08 15:20 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-08 16:54 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-08 17:32 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-09 8:58 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-09 9:49 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-09 12:33 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-09 13:59 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-09 16:52 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-09 17:52 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-10 9:31 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-10 17:00 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-10 17:16 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-12 16:24 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-14 14:43 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-15 12:40 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-16 8:46 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-25 19:12 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-10-01 8:55 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-10-01 18:11 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-10-02 8:53 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-10-02 12:06 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-10-03 13:54 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-10-03 19:43 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-10-04 15:01 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors [this message]
2024-10-04 15:23 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-10-04 17:21 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-10-05 20:02 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-10-06 15:01 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-10-26 12:39 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-10-26 17:40 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-10-31 11:09 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-10-31 14:14 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-11-05 23:06 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-11-06 8:48 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-11-06 22:03 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-11-07 9:49 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-11-07 10:36 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-11-14 23:25 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-11-15 17:20 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-11-15 20:06 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-11-16 8:59 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-11-16 14:45 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-11-16 16:40 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-11-17 13:09 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-11-17 16:37 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-11-17 17:01 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-03 17:44 ` Eli Zaretskii
2024-09-03 18:34 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-09-04 8:05 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=3d0a1e9a-5efc-4491-ab85-e3e58cb0f068@gmx.at \
--to=bug-gnu-emacs@gnu.org \
--cc=72986@debbugs.gnu.org \
--cc=eliz@gnu.org \
--cc=luangruo@yahoo.com \
--cc=rrt@sc3d.org \
--cc=rudalics@gmx.at \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.