[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [WIP PATCH] Adding more keybindings to rectangle-mark-mode-map
From: |
Jim Porter |
Subject: |
Re: [WIP PATCH] Adding more keybindings to rectangle-mark-mode-map |
Date: |
Sun, 2 May 2021 21:06:18 -0700 |
On Sun, May 2, 2021 at 11:07 AM Stefan Monnier <monnier@iro.umontreal.ca> wrote:
>
> Jim Porter [2021-05-02 09:36:14] wrote:
> > On Sun, May 2, 2021 at 9:09 AM Eli Zaretskii <eliz@gnu.org> wrote:
> >> > From: Jim Porter <jporterbugs@gmail.com>
> >> > I interpreted that to mean that, if Edit -> Clear is only enabled
> >> > when there's an active region/rect, `backward-delete-char-untabify'
> >> > is equivalent to a hypothetical `delete-rect-or-region'.
> >>
> >> But Edit->Clear is enabled even when the region is not active, like if
> >> you turn off transient-mark-mode.
> >
> > Ah. In that case, a new function might be safer.
>
> Indeed, we need a new function here.
> It should be a small matter of moving the code from
> `backward-delete-char-untabify' into a separate function.
For what it's worth, I think the attached patch fixes this by changing
the binding for Edit -> Clear to `delete-active-region'. I've tested
it out with and without `transient-mark-mode' using regular and
rectangular regions and it seems to work correctly. I never turn off
`transient-mark-mode' in my normal usage though, so I may have missed
some corner cases.
- Jim
0001-Ensure-menu-bar-edit-clear-handles-rectangular-regio.patch
Description: Binary data
- [WIP PATCH] Adding more keybindings to rectangle-mark-mode-map, Jim Porter, 2021/05/01
- Re: [WIP PATCH] Adding more keybindings to rectangle-mark-mode-map, Stefan Monnier, 2021/05/01
- Re: [WIP PATCH] Adding more keybindings to rectangle-mark-mode-map, Jim Porter, 2021/05/01
- Re: [WIP PATCH] Adding more keybindings to rectangle-mark-mode-map, Stefan Monnier, 2021/05/01
- Re: [WIP PATCH] Adding more keybindings to rectangle-mark-mode-map, Jim Porter, 2021/05/01
- Re: [WIP PATCH] Adding more keybindings to rectangle-mark-mode-map, Eli Zaretskii, 2021/05/02
- Re: [WIP PATCH] Adding more keybindings to rectangle-mark-mode-map, Jim Porter, 2021/05/02
- Re: [WIP PATCH] Adding more keybindings to rectangle-mark-mode-map, Eli Zaretskii, 2021/05/02
- Re: [WIP PATCH] Adding more keybindings to rectangle-mark-mode-map, Jim Porter, 2021/05/02
- Re: [WIP PATCH] Adding more keybindings to rectangle-mark-mode-map, Stefan Monnier, 2021/05/02
- Re: [WIP PATCH] Adding more keybindings to rectangle-mark-mode-map,
Jim Porter <=
- Re: [WIP PATCH] Adding more keybindings to rectangle-mark-mode-map, Andreas Schwab, 2021/05/03
- Re: [WIP PATCH] Adding more keybindings to rectangle-mark-mode-map, Jim Porter, 2021/05/03
- Re: [WIP PATCH] Adding more keybindings to rectangle-mark-mode-map, Stefan Monnier, 2021/05/07
- Re: [WIP PATCH] Adding more keybindings to rectangle-mark-mode-map, Eli Zaretskii, 2021/05/08
- Re: [WIP PATCH] Adding more keybindings to rectangle-mark-mode-map, Andreas Schwab, 2021/05/08
- [PATCH] Improve docstring for delete-active-region (was Re: [WIP PATCH] Adding more keybindings to rectangle-mark-mode-map), Jim Porter, 2021/05/08
- Re: [WIP PATCH] Adding more keybindings to rectangle-mark-mode-map, Ergus, 2021/05/01