Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Can vim commands be mapped to key combinations with >1 modifier (e.g. ctrl-alt-v)

Tags:

vim

macvim

Is it possible to map a vim command to a combination of keys involving more than one modifier? For example: ctrl-alt-v.

As far as I can tell, the only modifier key that can be used in combination with another is shift. e.g. <C-v> and <C-V>. Or am I missing something?

like image 464
nelstrom Avatar asked Sep 21 '09 18:09

nelstrom


People also ask

How do I remap a key in vim?

To map keys that work only in the normal mode, use the ':nmap' or ':nnoremap' command. The 'n' in ':nmap' and ':nnoremap' denotes normal mode. Examples: The following commands map the 'j' key to execute 'gj' and the 'k' key to execute 'gk'.

What is silent key in vim?

<silent> tells vim to show no message when this key sequence is used. <leader> means the key sequence starts with the character assigned to variable mapleader -- a backslash, if no let mapleader = statement has executed yet at the point nmap executes.

What is cr in vim?

The <CR> in vim mappings is the carriage return usually the Enter on your keyboard.


1 Answers

Yeah, you would map <C-A-v> or <C-M-v> (A, Alt, and M, Meta are equivalent concepts). See :help key-notation.

like image 173
chaos Avatar answered Oct 22 '22 02:10

chaos