zed-industries / zed

Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.
https://zed.dev
Other
47.12k stars 2.71k forks source link

Missing block selection mode with vim keybindings #17348

Closed olivoil closed 1 week ago

olivoil commented 1 week ago

Check for existing issues

Describe the feature

With vim keybindings, it would be great to be able to enter block selection mode to select rectangular blocks of text.

There are some issues mentioning AddSelectionAbove and AddSelectionBelow and their key mapping (https://github.com/zed-industries/zed/issues/16510 and https://github.com/zed-industries/zed/issues/16441 for instance). But it's not quite as convenient as using vim's keybindings.

This is usually triggered by ctrl+v in visual mode by default in vim, and allows vim motions to control the selection.

If applicable, add mockups / screenshots to help present your vision of the feature

No response

ConradIrwin commented 1 week ago

@olivoil visual block mode should be supported already (accessed via ctrl-v) if you have vim_mode: true in your settings.

You can get a similar feature out of vim mode with cmd-ctrl-n/p as you noted.

Please let me know if there's something that isn't working for you.

olivoil commented 1 week ago

It is working now, thank you! I'm not sure why I thought it was not working when I filed the issue... if it happens again, I will try to gather more info.