From: Lars Ingebrigtsen <larsi@gnus.org>
To: Tassilo Horn <tsdh@gnu.org>
Cc: 19267@debbugs.gnu.org
Subject: bug#19267: 25.0.50; Enhance cycle-spacing with a state where only whitespace after point is deleted
Date: Thu, 12 May 2022 13:45:20 +0200 [thread overview]
Message-ID: <874k1v0yb3.fsf@gnus.org> (raw)
In-Reply-To: <87wners5ue.fsf@gnu.org> (Tassilo Horn's message of "Thu, 12 May 2022 06:53:58 +0200")
Tassilo Horn <tsdh@gnu.org> writes:
>> I think that sounds like a good feature -- we don't have any other
>> commands for "delete all whitespace after point", do we?
>
> No, just the opposite: delete-horizontal-space with prefix arg.
Huh, I'd forgotten about that one. It's pretty odd to have both `C-\'
and `M-SPC' bound when both commands are so similar.
I guess people have different usage patterns -- for instance, I only use
`M-- M-SPC' (`just-one-space' that also deletes newlines), because
that's what's usually useful in Lisp code.
>> We could implement this as a new third state for `cycle-spacing', and
>> move the "restore" to the fourth state. Does anybody think that will
>> be annoying for people?
>
> It makes the sequence longer in case you want to restore. Not a big
> thing IMHO. But maybe there could also be a new defcustom
> cycle-spacing-actions which lists the actions being cycled, e.g.,
>
> (just-one-space delete-all-space delete-space-after restore-original)
Hm, yes, that might be good. If the list of cycled actions gets to
long, it's no longer convenient. So for myself, I'd probably have
(just-one-space-including-newlines delete-after-space restore-original)
and then `M-SPC' would do what I wanted in 99% of the time (with my
usage patterns). (We could also add target actions like `no-space' and
`no-space-before-point' (i.e., the `M-\' actions).)
So perhaps we could change the `M-SPC' binding to a new
`cycle-spacing-command' that, by default, does exactly what
`just-one-space' does now (so that there will be no user visible
changes; i.e., it doesn't cycle because cycle-spacing-actions will be
just (just-one-space)). But then users can customize it and add the
actions they want in a convenient way.
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no
next prev parent reply other threads:[~2022-05-12 11:45 UTC|newest]
Thread overview: 40+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-12-04 8:06 bug#19267: 25.0.50; Enhance cycle-spacing with a state where only whitespace after point is deleted Tassilo Horn
2022-05-12 2:16 ` Lars Ingebrigtsen
2022-05-12 4:53 ` Tassilo Horn
2022-05-12 11:45 ` Lars Ingebrigtsen [this message]
2022-05-12 11:56 ` Tassilo Horn
2022-05-12 12:09 ` Lars Ingebrigtsen
2022-05-12 12:16 ` Robert Pluim
2022-05-12 12:21 ` Lars Ingebrigtsen
2022-05-12 14:45 ` Tassilo Horn
2022-05-13 8:50 ` Tassilo Horn
2022-05-13 13:33 ` Robert Pluim
2022-05-13 18:48 ` Tassilo Horn
2022-05-13 12:19 ` Lars Ingebrigtsen
2022-05-13 13:36 ` Robert Pluim
2022-05-13 13:39 ` Lars Ingebrigtsen
2022-05-13 19:01 ` Tassilo Horn
2022-05-13 19:26 ` Lars Ingebrigtsen
2022-05-13 21:11 ` Tassilo Horn
2022-05-14 2:24 ` Lars Ingebrigtsen
2022-05-14 6:54 ` Tassilo Horn
2022-05-14 15:51 ` Lars Ingebrigtsen
2022-05-15 9:02 ` Tassilo Horn
2022-05-15 12:27 ` Lars Ingebrigtsen
2022-05-15 19:04 ` Tassilo Horn
2022-05-16 1:05 ` Lars Ingebrigtsen
2022-05-16 8:05 ` Tassilo Horn
2022-05-16 12:19 ` Lars Ingebrigtsen
2022-05-16 12:28 ` Tassilo Horn
2022-05-16 12:32 ` Lars Ingebrigtsen
2022-05-16 13:04 ` Tassilo Horn
2022-05-17 15:42 ` Robert Pluim
2022-05-17 15:55 ` Robert Pluim
2022-05-17 15:57 ` Tassilo Horn
2022-05-17 16:12 ` Robert Pluim
2022-05-16 7:33 ` Robert Pluim
2022-05-12 12:20 ` Tassilo Horn
2022-05-12 5:40 ` Eli Zaretskii
2022-05-12 5:46 ` Tassilo Horn
2022-05-12 8:25 ` Robert Pluim
2022-05-12 8:29 ` Eli Zaretskii
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=874k1v0yb3.fsf@gnus.org \
--to=larsi@gnus.org \
--cc=19267@debbugs.gnu.org \
--cc=tsdh@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.
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.