Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: [vi-mode] widgets for case manipulation: `gU` and `U` in visual mode
- X-seq: zsh-users 21691
- From: Filipe Silva <filipe.silva@xxxxxxxxx>
- To: Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx>
- Subject: Re: [vi-mode] widgets for case manipulation: `gU` and `U` in visual mode
- Date: Wed, 22 Jun 2016 10:19:03 -0300
- Cc: zsh-users@xxxxxxx
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=kLHa67mM0x05pPd52TcLOTJ37XiCdBdP2nkqLdeJ+bI=; b=cPUYSeWDnSkU6X4GVNhHe97W61czVAKCGSzf8TsewJOHPFozrVf/gzFfAb9TdEZxlk KMrFtC+TmegPCNbJrWDBgEXIp+XiY7q/6OCyeZQn4qx2D/At1vVdlfFfjsat+zGxDDLU qjIX6WkQhFomjU6Fyt9H7iCYkeTA8/Pkb7F8NNo+heZqHIymU3cQ+eorRQfheCFsnlqL 83ti/04WAd+jP/n15EbRCb5cHpuWSoibgMlQVYVKEQGfwHNYZLhrpgabw+dxZ3APcqM7 3TKR+5oDqA9LrHdGty2CnbDY6htntcrAum3wy23o9YQNOnHftZb9izAt1rOcVFhQ2lXT Amtw==
- In-reply-to: <160621234233.ZM10369@torch.brasslantern.com>
- List-help: <mailto:zsh-users-help@zsh.org>
- List-id: Zsh Users List <zsh-users.zsh.org>
- List-post: <mailto:zsh-users@zsh.org>
- Mailing-list: contact zsh-users-help@xxxxxxx; run by ezmlm
- References: <CAEwkUWMnBO7_6EOo5y5b1eMAZB6uXkgXsh51OqtuEbbUQQPRyQ@mail.gmail.com> <21997.1466550647@thecus.kiddle.eu> <160621234233.ZM10369@torch.brasslantern.com>
Hi Oliver, thanks for sharing the widgets. You should know that there's a
bug in both widgets in an edge case:
suppose you have the word `abc` and `a` is the first char of the line. also
suppose you've select just the `ab` of the `abc` word and then hit `U`:
```
# [ab] is the visually selected text
$ [ab]c
```
after you hit `U` the result is
```
$ cAB
```
I've fixed the bug including the following condition:
if [[ $save_cur = '1' ]]; then
zle .vi-put-before -n 1
else
zle .vi-put-after -n 1
fi
On Wed, Jun 22, 2016 at 3:42 AM, Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx>
wrote:
> On Jun 22, 1:10am, Oliver Kiddle wrote:
> }
> } Some of the text objects were done via shell widgets - select-quoted and
> } select-bracketed which select text between delimiters.
>
> Incidentally, I think select-bracketed might break given ksharrays --
> select-quoted explictly turns ksharrays off.
>
Messages sorted by:
Reverse Date,
Date,
Thread,
Author