unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Sean McAfee <eefacm@gmail.com>
To: Eli Zaretskii <eliz@gnu.org>
Cc: 72862@debbugs.gnu.org
Subject: bug#72862: 29.1; Strange interaction between append-next-kill and kill-whole-line
Date: Mon, 9 Sep 2024 22:13:06 -0500	[thread overview]
Message-ID: <CANan03YsYez+ghrJzoU+icLBdSH58_VOmsPkyp6-NmDVsw3nkA@mail.gmail.com> (raw)
In-Reply-To: <86mskiws3w.fsf@gnu.org>

[-- Attachment #1: Type: text/plain, Size: 1403 bytes --]

On Sun, Sep 8, 2024 at 1:56 AM Eli Zaretskii <eliz@gnu.org> wrote:

> Since kill-whole-line kills both backward and forward from point, it
> seems we should expect that the first part is prepended to previous
> kill, whereas the second part is appended.  Which is what the command
> already does.
>
> WDYT?
>

Since the current behavior is explicitly documented in the code, I suppose
that settles it.  I really can't imagine a good use case for it, though.
But then again, until I filed this ticket, I didn't know that
append-next-kill could sometimes prepend instead of append.  It seems a
small miracle that I've never stumbled across the prepending function by
accident.

Perhaps kill-whole-line does technically kill both forwards and backwards,
but to me it's always been just a welcome shortcut for the classic Emacs
idiom C-a C-k C-k.  And the name kill-whole-line certainly implies to me
that the line is killed as a single unit, not killed in two steps in
opposite directions.  If the current behavior is to stay, then I think it
could stand to be called out explicitly in the documentation for
kill-whole-line.

Anyway!  Although I'd prefer to see what I'd consider to be the more
sensible behavior built into Emacs, I can achieve it on my own by just
rebinding C-S-backspace to a command that moves to the beginning of the
line before calling kill-whole-line.

[-- Attachment #2: Type: text/html, Size: 1771 bytes --]

  reply	other threads:[~2024-09-10  3:13 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-08-28 21:12 bug#72862: 29.1; Strange interaction between append-next-kill and kill-whole-line Sean McAfee
2024-08-29  4:53 ` Eli Zaretskii
2024-09-08  6:56   ` Eli Zaretskii
2024-09-10  3:13     ` Sean McAfee [this message]
2024-09-10 11:54       ` Eli Zaretskii
2024-09-21  9:16         ` 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

  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=CANan03YsYez+ghrJzoU+icLBdSH58_VOmsPkyp6-NmDVsw3nkA@mail.gmail.com \
    --to=eefacm@gmail.com \
    --cc=72862@debbugs.gnu.org \
    --cc=eliz@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 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).