From: Stefan Monnier via "Bug reports for GNU Emacs, the Swiss army knife of text editors" <bug-gnu-emacs@gnu.org>
To: martin rudalics <rudalics@gmx.at>
Cc: Alan Mackenzie <acm@muc.de>, Eli Zaretskii <eliz@gnu.org>,
56305@debbugs.gnu.org
Subject: bug#56305: 29.0.50; 'yes-or-no-p' deselects minibuffer frame
Date: Mon, 18 Jul 2022 10:58:09 -0400 [thread overview]
Message-ID: <jwv8roqiimq.fsf-monnier+emacs@gnu.org> (raw)
In-Reply-To: <11e7e566-f626-fcf4-adfc-d03efa0d861c@gmx.at> (martin rudalics's message of "Mon, 18 Jul 2022 09:37:35 +0200")
>> In case you intend to fix this apparent blunder of mine: the point of
>> that commit was to set the selected window and frame so that ELisp code
>> run from the `mode-line-format` would see meaningful and consistent
>> values of selected-frame/window (and companions like the
>> frame-selected-window of the selected-frame, ...).
> How are display_mode_line or display_mode_lines affected by that commit?
I'm sorry, I don't understand the question.
> Worse even: People who want to know, for example, whether the mode line
> belongs to the selected window have to use 'old-selected-window' for
> getting that.
Not sure "worse" than what.
Clearly when computing the mode-line, there are 2 windows of interest:
the one to which this mode-line belongs and the one that's currently
considered (from the outside) as "the selected window". Only one of the
two can be "the selected window" while computing the mode-line, and in
my experience most code wants/needs this to be the mode-line's window
rather than "the one that's currently considered (from the outside) as
the selected window".
> And by no means I'd ask for changing this. But a better explanation in
> the doc-strings and the manual should be in order. End of the aside.
I didn't know that `old-selected-window` could be used for that (when
I installed the patch, there was simply no such option and my
recommendation when people needed such a thing was to use
a `pre-redisplay-hook` to set some global var to remember the window
that was selected when entering redisplay).
>> If calling `Fselect_window` with a non-nil `norecord` argument messes
>> things up somehow then maybe we should fix `Fselect_window` accordingly,
>> or otherwise provide a "more bare bones" function that DTRT.
>>
>> It seems clear to me, for example, that when called with a non-nil
>> `norecord` (like in the mode-line code), `Fselect_window` should never
>> cause any change to the focus redirection (or the focus itself).
>
> NORECORD is not about focus.
Then we need something like it but to say "I just want to change
selected-window temporarily, so don't mess with focus or any such thing".
Or maybe, an alternative would be to wait until the next redisplay to
reflect the effect of select-frame/window on focus.
>> I can't see the connection between these bugs at the above commit, sorry.
> They are a direct result of x/gui_consider_frame_title calling
> Fselect_window calling resize_mini_window and were fixed by binding
> 'inhibit-redisplay' appropriately in x/gui_consider_frame_title.
Hmm... following the idea above, maybe select-frame/window should never
call resize_mini_window, and instead that should only take place at the
next redisplay.
Stefan
next prev parent reply other threads:[~2022-07-18 14:58 UTC|newest]
Thread overview: 83+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-06-29 17:54 bug#56305: 29.0.50; 'yes-or-no-p' deselects minibuffer frame martin rudalics
2022-06-29 19:10 ` Eli Zaretskii
2022-06-30 10:35 ` Alan Mackenzie
2022-06-30 20:32 ` Alan Mackenzie
2022-07-02 11:38 ` Alan Mackenzie
2022-07-03 8:16 ` martin rudalics
2022-07-03 16:09 ` Alan Mackenzie
2022-07-03 16:17 ` Eli Zaretskii
2022-07-04 19:10 ` Alan Mackenzie
2022-07-04 19:21 ` Eli Zaretskii
2022-07-04 19:43 ` Alan Mackenzie
2022-07-05 2:29 ` Eli Zaretskii
2022-07-05 15:59 ` Alan Mackenzie
2022-07-05 16:24 ` Eli Zaretskii
2022-07-05 17:09 ` Alan Mackenzie
2022-07-06 17:04 ` Alan Mackenzie
2022-07-06 17:29 ` Eli Zaretskii
2022-07-06 18:16 ` Alan Mackenzie
2022-07-06 18:34 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-07-06 18:58 ` Andreas Schwab
2022-07-06 19:05 ` Alan Mackenzie
2022-07-06 19:09 ` Andreas Schwab
2022-07-06 19:22 ` Alan Mackenzie
2022-07-07 17:25 ` Alan Mackenzie
2022-07-07 18:57 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-07-08 21:03 ` Alan Mackenzie
2022-07-09 2:15 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-07-07 7:55 ` martin rudalics
2022-07-07 9:12 ` Alan Mackenzie
2022-07-08 7:01 ` martin rudalics
2022-07-08 10:55 ` Alan Mackenzie
2022-07-08 11:55 ` Eli Zaretskii
2022-07-08 18:31 ` Alan Mackenzie
2022-07-09 8:36 ` martin rudalics
2022-07-08 21:45 ` Gregory Heytings
2022-07-09 8:35 ` martin rudalics
2022-07-09 10:57 ` Alan Mackenzie
2022-07-10 8:07 ` martin rudalics
2022-07-10 11:34 ` Alan Mackenzie
2022-07-10 11:47 ` Eli Zaretskii
2022-07-10 12:41 ` Alan Mackenzie
2022-07-10 13:01 ` Eli Zaretskii
2022-07-10 16:13 ` Drew Adams
2022-07-10 16:55 ` Alan Mackenzie
2022-07-11 7:45 ` martin rudalics
2022-07-11 11:12 ` Eli Zaretskii
2022-07-12 7:33 ` martin rudalics
2022-07-12 16:02 ` Eli Zaretskii
2022-07-11 16:22 ` Alan Mackenzie
2022-07-11 16:43 ` Eli Zaretskii
2022-07-11 17:15 ` Alan Mackenzie
2022-07-11 17:33 ` Eli Zaretskii
2022-07-11 17:34 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-07-11 20:09 ` Alan Mackenzie
2022-07-11 17:06 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-07-11 20:01 ` Alan Mackenzie
2022-07-12 7:35 ` martin rudalics
2022-07-12 14:56 ` Drew Adams
2022-07-16 7:06 ` martin rudalics
2022-07-16 20:34 ` Alan Mackenzie
2022-07-18 7:36 ` martin rudalics
2022-07-18 14:44 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-07-19 8:09 ` martin rudalics
2022-07-19 16:04 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-07-16 23:39 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-07-17 11:29 ` Alan Mackenzie
2022-07-17 14:03 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-07-17 15:06 ` Alan Mackenzie
2022-07-18 7:37 ` martin rudalics
2022-07-18 14:58 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors [this message]
2022-07-18 15:58 ` Eli Zaretskii
2022-07-18 16:12 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-07-18 16:50 ` Eli Zaretskii
2022-07-19 20:48 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-07-20 12:17 ` Eli Zaretskii
2022-07-20 14:54 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-07-20 16:02 ` Eli Zaretskii
2022-07-21 15:07 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-07-21 15:58 ` Eli Zaretskii
2022-07-19 8:09 ` martin rudalics
2022-07-07 15:54 ` Alan Mackenzie
2022-07-04 19:46 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-07-04 19:59 ` Alan Mackenzie
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=jwv8roqiimq.fsf-monnier+emacs@gnu.org \
--to=bug-gnu-emacs@gnu.org \
--cc=56305@debbugs.gnu.org \
--cc=acm@muc.de \
--cc=eliz@gnu.org \
--cc=monnier@iro.umontreal.ca \
--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.