How to use a custom key to trigger visual block selection in VIM

I know that VIM can start selecting a visual block with Ctrl + V , and sometimes Ctrl + V will be inserted, we can still go with Ctrl + Q. But I think that this key combination is not so easy to press, is it possible to assign a custom key for this? For example, I would like to use Q in normal mode to start the visual selection (I don't use macro photography so much):

map q ??? <- what should I write here?

+4
source share
1 answer

I believe what you are looking for

 :nnoremap q <cv> 

But note that you cannot record macros unless you reassign this too.

+2
source

Source: https://habr.com/ru/post/1445413/


All Articles