From: Philipp Stephani <p.stephani2@gmail.com>
To: Stefan Monnier <monnier@iro.umontreal.ca>
Cc: "martin rudalics" <rudalics@gmx.at>,
"Juri Linkov" <juri@linkov.net>,
"Daniel Martín" <mardani29@yahoo.es>,
"Stefan Kangas" <stefankangas@gmail.com>,
"Daniel Martín via Emacs development discussions."
<emacs-devel@gnu.org>
Subject: Re: Pushing the mark from a primitive like goto-char
Date: Tue, 5 Jan 2021 20:52:44 +0100 [thread overview]
Message-ID: <CAArVCkT2UVF+PkXXe1Ta8h8wfvS6AvvDdFHGDV8uNpFLO6bosQ@mail.gmail.com> (raw)
In-Reply-To: <jwvv9cbw5t4.fsf-monnier+emacs@gnu.org>
Am Di., 5. Jan. 2021 um 20:19 Uhr schrieb Stefan Monnier
<monnier@iro.umontreal.ca>:
>
> >>>> I'd then try to make it behave like 'M-g g' in this regard.
> >>>
> >>> Some interactive versions of low-level primitives have the suffix
> >>> `...-command' in their names, so a command like 'M-g g' and bound to
> >>> 'M-g c' could be named 'goto-char-command'.
> >>
> >> I was more concerned about not pushing the mark when the region is
> >> already active so one can use M-g c to extend the region. BTW, is there
> >> a reason why 'goto-map' is so terribly unpopulated?
> >>
> >
> > This sounds like a good idea:
> >
> > - Create a 'goto-char-command' command in ELisp.
> >
> > - Move the interactive spec that is in 'goto-char' to this new command
> > and make it push the mark smartly (e.g. be careful when a region is
> > active). Then call 'goto-char'.
> >
> > - Rebind 'M-g c' to 'goto-char-command'.
> >
> > - Announce the new command.
> >
> > What do you think? Could it break something? Thanks.
>
> Actually, now that I think about it: do we really need a new command, or
> can we instead arrange to do all the mark-handling from within the
> interactive spec?
>
I think that would be too confusing. The interactive specification
should only gather input, but not perform state changes.
next prev parent reply other threads:[~2021-01-05 19:52 UTC|newest]
Thread overview: 32+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <m1im8mgmb7.fsf.ref@yahoo.es>
2020-12-28 12:14 ` Pushing the mark from a primitive like goto-char Daniel Martín
2020-12-28 14:17 ` Philipp Stephani
2020-12-28 14:45 ` Daniel Martín
2020-12-28 14:49 ` Eli Zaretskii
2020-12-28 14:56 ` Stefan Kangas
2020-12-28 15:32 ` Philipp Stephani
2020-12-28 16:49 ` martin rudalics
2020-12-28 17:15 ` Juri Linkov
2020-12-29 8:54 ` martin rudalics
2020-12-29 14:41 ` Stefan Kangas
2020-12-29 16:59 ` martin rudalics
2020-12-29 17:56 ` Drew Adams
2020-12-29 19:25 ` Juri Linkov
2020-12-29 19:47 ` Eli Zaretskii
2020-12-30 9:36 ` Juri Linkov
2020-12-29 19:54 ` Drew Adams
2020-12-30 9:41 ` Juri Linkov
2020-12-30 17:32 ` Drew Adams
2020-12-30 5:26 ` Richard Stallman
2020-12-31 2:43 ` Howard Melman
2021-01-05 19:06 ` Daniel Martín via "Emacs development discussions.
2021-01-05 19:17 ` Stefan Monnier
2021-01-05 19:19 ` Stefan Monnier
2021-01-05 19:52 ` Philipp Stephani [this message]
2021-01-05 20:01 ` Stefan Monnier
2021-01-05 20:29 ` Drew Adams
2021-01-06 5:12 ` Richard Stallman
2021-01-05 19:29 ` Eli Zaretskii
2021-01-05 19:53 ` Philipp Stephani
2021-01-08 19:30 ` Daniel Martín via "Emacs development discussions.
2021-01-05 19:56 ` Philipp Stephani
2021-01-06 19:26 ` Gabriel do Nascimento Ribeiro
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=CAArVCkT2UVF+PkXXe1Ta8h8wfvS6AvvDdFHGDV8uNpFLO6bosQ@mail.gmail.com \
--to=p.stephani2@gmail.com \
--cc=emacs-devel@gnu.org \
--cc=juri@linkov.net \
--cc=mardani29@yahoo.es \
--cc=monnier@iro.umontreal.ca \
--cc=rudalics@gmx.at \
--cc=stefankangas@gmail.com \
/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.