[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#13521: `sort-lines' on the empty region
From: |
Eli Zaretskii |
Subject: |
bug#13521: `sort-lines' on the empty region |
Date: |
Sat, 05 Sep 2020 18:37:00 +0300 |
> Date: Sat, 5 Sep 2020 08:22:58 -0700 (PDT)
> From: Drew Adams <drew.adams@oracle.com>
> Cc: stefan@marxist.se, xfq.free@gmail.com, rgm@gnu.org,
> monnier@iro.umontreal.ca, 13521@debbugs.gnu.org
>
> > > I doubt that someone who has `transient-mark-mode' off
> > > would ever want commands such as `flush-lines' and
> > > `sort-lines' to act on the region. And if they did, I
> > > expect they'd just narrow to it.
> >
> > Please don't doubt, and please don't impose unnecessary commands on
> > users who have transient-mark-mode off.
>
> Please don't claim that I imposed any commands on anyone.
You expected them to narrow the buffer. That takes additional
commands.
> The region is nearly always present and usually nonempty.
> A user with `transient-mark-mode' off would typically
> (IMHO) be bothered if `flush-lines' started always acting
> on the region (it would be almost always: whenever there's
> a mark in the buffer and the region is nonempty).
So maybe flush-lines needs a separate solution, or none at all. This
bug is about sort-lines, so flush-lines is a tangent.
> And I think "the important point here" is that a command
> that behaves differently when the region is active should
> NOT act on the region when `transient-mark-mode' is off.
That's not really relevant here. We are talking about commands which
by virtue of their 'interactive' spec work on the region. Such
commands shouldn't depend on the region being active.
> This was not the case for `sort-lines', as you point out.
> It did NOT, and does not, behave differently when the
> region is active from when it is inactive.
The proposed change would have made it behave differently, which is
why I've pointed that out.