From: Eli Zaretskii <eliz@gnu.org>
To: martin rudalics <rudalics@gmx.at>
Cc: emacs-devel@gnu.org
Subject: Re: About the 'minibuffer' frame parameter
Date: Tue, 09 Aug 2016 19:21:05 +0300 [thread overview]
Message-ID: <83pophhq1a.fsf@gnu.org> (raw)
In-Reply-To: <57A9FFDE.10106@gmx.at> (message from martin rudalics on Tue, 09 Aug 2016 18:07:58 +0200)
> Date: Tue, 09 Aug 2016 18:07:58 +0200
> From: martin rudalics <rudalics@gmx.at>
> CC: emacs-devel@gnu.org
>
> >> (1) Make sure that store_frame_param doesn't store invalid parameter
> >> values.
> >>
> >> (2) Never store a minibuffer window as frame parameter.
> >>
> >> (3) Have ‘frame-parameter’ return the 'minibuffer' parameter as stored
> >> internally. If no stored value is available, return t.
> >>
> >> (4) Wait for regression reports.
> >>
> >> (5) Fix the documentation.
> >>
> >> (6) Fix/remove related comments.
> >
> > I'm okay with that, but I'm surprised by (2): won't storing the
> > minibuffer window there allow us to report the correct value in (3)?
> > What am I missing?
>
> If we did that we would invert the values returned by ‘frame-parameter’
> for the "normal" frame and minibuffer-less frame cases. Currently, we
> return the minibuffer window for a normal frame and nil for a
> minibuffer-less frame. You would return the minibuffer window for a
> minibuffer-less frame and t for a normal frame. Correct?
Maybe. Another alternative would be to return a window in both cases.
> This would have the benefit that after
>
> (set-frame-parameter minibuffer-less-frame 'minibuffer some-minibuffer-window)
>
> the value returned by ‘frame-parameter’ would be consistent with the
> requested value. However, most minibuffer-less frames are created via
>
> (make-frame '((minibuffer . nil)))
>
> and whatever we do here we would introduce another inconsistency: Either
> the stored value is the minibuffer window chosen by Emacs and the value
> returned by ‘frame-parameter’ would not be the value from the PARAMETERS
> argument of ‘make-frame’. Or we would sometimes return nil and
> sometimes a window as value of the 'minibuffer' frame parameter of a
> minibuffer-less frame.
We have already a few cases where frame-parameter returns a value
different from the one specified when make-frame was called. There's
nothing wrong about that, if it's Emacs that chooses the actual value.
> Given the fact that changing the frame parameter of a minibuffer-less
> frame is a pretty rare operation, I would prefer the solution sketched
> in (2). WDYT?
Do you still prefer (2)? I prefer storing a window because then we
could naturally return it, like we do with frame colors.
next prev parent reply other threads:[~2016-08-09 16:21 UTC|newest]
Thread overview: 43+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-07-31 18:12 About the 'minibuffer' frame parameter martin rudalics
2016-08-05 13:33 ` Eli Zaretskii
2016-08-05 16:37 ` martin rudalics
2016-08-05 17:18 ` Drew Adams
2016-08-05 17:35 ` martin rudalics
2016-08-05 17:52 ` Drew Adams
2016-08-05 18:19 ` martin rudalics
2016-08-05 18:37 ` Drew Adams
2016-08-06 9:32 ` martin rudalics
2016-08-06 16:46 ` Drew Adams
2016-08-07 8:46 ` martin rudalics
2017-01-14 0:59 ` Juanma Barranquero
2017-01-14 7:47 ` Eli Zaretskii
2017-01-14 9:18 ` Juanma Barranquero
2017-01-14 10:42 ` Eli Zaretskii
2017-01-14 11:05 ` martin rudalics
2017-01-14 14:01 ` Juanma Barranquero
2017-01-19 3:54 ` John Wiegley
2017-01-14 15:56 ` Drew Adams
2017-01-15 3:01 ` Richard Stallman
2016-08-05 19:25 ` Eli Zaretskii
2016-08-06 9:33 ` martin rudalics
2016-08-07 13:54 ` Eli Zaretskii
2016-08-08 8:27 ` martin rudalics
2016-08-08 15:34 ` Eli Zaretskii
2016-08-09 8:27 ` martin rudalics
2016-08-09 14:51 ` Eli Zaretskii
2016-08-09 16:07 ` martin rudalics
2016-08-09 16:21 ` Eli Zaretskii [this message]
2016-08-09 17:34 ` martin rudalics
2016-08-09 17:51 ` Eli Zaretskii
2016-08-10 12:15 ` martin rudalics
2016-08-10 14:23 ` Stefan Monnier
2016-08-10 14:54 ` Eli Zaretskii
2016-08-10 14:49 ` Eli Zaretskii
2016-08-21 9:41 ` martin rudalics
2016-08-21 20:51 ` Kaushal Modi
2016-08-22 12:49 ` Kaushal Modi
2016-08-22 13:03 ` Kaushal Modi
2016-08-22 15:51 ` Kaushal Modi
2016-08-22 16:01 ` martin rudalics
2016-08-22 16:27 ` Kaushal Modi
2016-08-23 8:19 ` martin rudalics
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
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=83pophhq1a.fsf@gnu.org \
--to=eliz@gnu.org \
--cc=emacs-devel@gnu.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 public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).