From: Heime via "Bug reports for GNU Emacs, the Swiss army knife of text editors" <bug-gnu-emacs@gnu.org>
To: Stefan Monnier <monnier@iro.umontreal.ca>
Cc: Gregory Heytings <gregory@heytings.org>,
65459@debbugs.gnu.org, Eli Zaretskii <eliz@gnu.org>
Subject: bug#65459: completing-read INITIAL-VALUE unaware of COLLECTION and REQUIRE-MATCH
Date: Sun, 27 Aug 2023 21:11:27 +0000 [thread overview]
Message-ID: <PGHFCqIlqCiLxdJPsfkhTdXMBxqeltIA4-jsbNTrcBkDHaEVr3JelBwoN2l-vFCfCfvp1a84HPt_R7JIBMK2xAcITbgUm0FGEn9Las9hii0=@protonmail.com> (raw)
In-Reply-To: <jwvbkes74n1.fsf-monnier+emacs@gnu.org>
Sent with Proton Mail secure email.
------- Original Message -------
On Monday, August 28th, 2023 at 6:01 AM, Stefan Monnier <monnier@iro.umontreal.ca> wrote:
> > > Whether the default only shows up when instructed is a UI issue, which
> > > can/should be under control of a UI customization. - Stefan
> > > I would need an example. Suppose one changes the UI customization, would that
> > > apply to all calls of that function ? I would want prefilling occasionally.
> > > Would that be possible ?
> There are some cases, such as `read-file-name` where we do want some
> prefilling, so of course it's possible, but it has to be linked to some
> specific property of the thing we're requesting from the user and how it
> relates to the string with which we want to prefill the buffer.
I am proposing a broader use. I meant an example of how a programmer can
include minibuffer prefilling. It seems that the functionality exists
but not well known or understood. If minibuffer prefilling has been possible
for us in `read-file-name`, then the possibility should also be provided to
programmers and users devising their own functionality.
> So it goes back to the question of why you want this specific call to
> `completing-read` to be prefilled. The answer shouldn't be "because
> I prefer it this way" (that answer should be satisfied instead by
> a customization setting since it may not apply to other users of that
> code).
>
> E.g. in the case of `read-file-name` it's because in 99% of the cases
> the end result wants to include all or most of that prefilled string.
>
> > All these UI accept any entries by the user.
Customarily all minibuffer input from the user is allowed to be entered.
I claim automatic prefilling can be considered a form of user input, if
they code their own function with prefilling in mind.
> I don't know what you mean by that.
>
> > I am of the school of thought that doing so automatically is also
> > a valid operation.
> And I didn't understand this part either. > Stefan
There are two audiences in all this. Programmers who write libraries
and users who write functions for their own use. The thought is that
if `read-file-name` has capability of minibuffer prefilling, then minibuffer
prefilling capability should be available for them to use without having
them convince anybody why they want it to happen.
I consider the statement "I prefer it this way" legitimate, because in emacs
users have the capability to add functionality for their personal use, and their
decisions would not affect other users of that code.
Did some more thinking about all this and can see the possibility of INITIAL
to become much broader. For maintainers of libraries for public use, the code
could need some elaboration, but not much for personal use cases.
be
next prev parent reply other threads:[~2023-08-27 21:11 UTC|newest]
Thread overview: 54+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-08-22 22:04 bug#65459: completing-read INITIAL-VALUE unaware of COLLECTION and REQUIRE-MATCH Heime via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-23 11:29 ` Eli Zaretskii
2023-08-23 11:57 ` Heime via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-23 13:07 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-23 15:29 ` Heime via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-23 16:05 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-23 16:39 ` Heime via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-23 16:58 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-23 18:12 ` Heime via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-23 21:27 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-23 22:44 ` Drew Adams
2023-08-23 23:06 ` Gregory Heytings
2023-08-24 2:30 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-24 12:30 ` Gregory Heytings
2023-08-24 13:19 ` Heime via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-25 6:59 ` Juri Linkov
2023-08-24 13:46 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-26 8:06 ` Gregory Heytings
2023-08-31 9:42 ` Eli Zaretskii
2023-09-04 21:35 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-09-04 22:16 ` Stefan Kangas
2023-09-05 11:05 ` Eli Zaretskii
2023-09-05 12:59 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-09-05 13:14 ` Eli Zaretskii
2023-08-24 9:02 ` Heime via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-24 13:36 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-24 14:51 ` Heime via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-24 16:45 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-24 18:50 ` Heime via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-24 19:35 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-24 20:22 ` Heime via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-24 21:02 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-24 21:45 ` Heime via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-26 8:10 ` Gregory Heytings
2023-08-26 14:27 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-27 6:45 ` Heime via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-27 14:40 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-27 16:21 ` Heime via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-27 16:26 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-27 16:35 ` Heime via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-27 18:01 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-27 21:11 ` Heime via Bug reports for GNU Emacs, the Swiss army knife of text editors [this message]
2023-08-27 21:48 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-27 22:59 ` Heime via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-28 3:12 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-28 9:14 ` Heime via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-28 12:44 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-28 12:50 ` Heime via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-28 13:04 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-28 13:13 ` Heime via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-27 16:42 ` Heime via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-27 18:02 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-27 20:54 ` Heime via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-27 21:26 ` Heime 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='PGHFCqIlqCiLxdJPsfkhTdXMBxqeltIA4-jsbNTrcBkDHaEVr3JelBwoN2l-vFCfCfvp1a84HPt_R7JIBMK2xAcITbgUm0FGEn9Las9hii0=@protonmail.com' \
--to=bug-gnu-emacs@gnu.org \
--cc=65459@debbugs.gnu.org \
--cc=eliz@gnu.org \
--cc=gregory@heytings.org \
--cc=heimeborgia@protonmail.com \
--cc=monnier@iro.umontreal.ca \
/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.