norcalli / nvim-colorizer.lua

The fastest Neovim colorizer.
Other
2.25k stars 117 forks source link

Remapping <C-a> and <C-x> possible? #45

Open joe23rep opened 3 years ago

joe23rep commented 3 years ago

ive already used these shortcuts in my config so it would be awesome if i could remap them to something else. its a great feature which sets this plugin apart even more from the rest.

went threw all the documentations and searched the plugin file for the mappings but came up empty.

is there a way i could change these shortcuts?

igorgue commented 3 years ago

Hi, that's a vim feature to increment and decrement any number, and you can remap them take a look at this article:

https://vim.fandom.com/wiki/Increasing_or_decreasing_numbers#Alternative_mapping

Looks like this would map it to ALT+A and ALT+X respectively:

nnoremap <A-a> <C-a>
nnoremap <A-x> <C-x>

I honestly, advice against remapping it, and maybe map your old commands to <leader> a and <leader> x