From: tomas@tuxteam.de
To: Lajos Bodnar <bodnarlajoska@gmail.com>
Cc: help-gnu-emacs@gnu.org
Subject: Re: menu command
Date: Mon, 27 Aug 2018 15:03:00 +0200 [thread overview]
Message-ID: <20180827130300.GD16347@tuxteam.de> (raw)
In-Reply-To: <CAPibjnk8OtQDn6UNHx-a2hDci1cafL=4yKOdkwt3u6cUcZONAQ@mail.gmail.com>
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On Mon, Aug 27, 2018 at 02:19:24PM +0200, Lajos Bodnar wrote:
> Thanks,
> I haven't found command in the "describe-key" result which open a
> filedialog.
Ah, I think I get it now: what confuses you is the opening
of a GUI like file dialog?
If I got you right this time, the best answer is in the
source code:
`find-file' calls `find-file-read-args' to to ask the user which
file name (s)he wants. This one calls `read-file-name', which has
a pretty extensive documentation string. I insert the relevant
part here:
If this command was invoked with the mouse, use a graphical file
dialog if ‘use-dialog-box’ is non-nil, and the window system or X
toolkit in use provides a file dialog box, and DIR is not a
remote file. For graphical file dialogs, any of the special values
of MUSTMATCH ‘confirm’ and ‘confirm-after-completion’ are
treated as equivalent to nil. Some graphical file dialogs respect
a MUSTMATCH value of t, and some do not (or it only has a cosmetic
effect, and does not actually prevent the user from entering a
non-existent file).
So this is the mechanism which adapts to how the user invoked `find-file':
if the user used keys, then the question appears in the minibuffer, but
if the user clicked on a menu, (s)he gets a GUI-like file browser (to
me that makes a lot of sense).
I hope I've understood your question better now.
Cheers
- -- tomás
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.12 (GNU/Linux)
iEYEARECAAYFAluD9oQACgkQBcgs9XrR2kYXNACfYdvSKA/fgTkT/FYC9v4cp6mE
YiwAniDADh9f6yZgxZvI7lnoKG26Um/l
=cJi4
-----END PGP SIGNATURE-----
next prev parent reply other threads:[~2018-08-27 13:03 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-08-27 9:45 menu command Lajos Bodnar
2018-08-27 11:21 ` tomas
2018-08-27 12:19 ` Lajos Bodnar
2018-08-27 13:03 ` tomas [this message]
2018-08-27 13:38 ` Lajos Bodnar
2018-08-28 16:13 ` Lajos Bodnar
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=20180827130300.GD16347@tuxteam.de \
--to=tomas@tuxteam.de \
--cc=bodnarlajoska@gmail.com \
--cc=help-gnu-emacs@gnu.org \
/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.
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).