`let R_assign_map = '<M-->'` does not work to me
Following the documentation, I have added
set <M-->=^[-
let R_assign_map = '<M-->'
to ~/.vimrc in order to use Alt-- to insert <- but it is not working (it just avoids replacing _ by <-). It places the cursor at the beginning of one line up. I looked for
:verbose map ^[-
to see if it was used for another plugin, but I get No mapping found. Which can be the issue?
Thanks!
A can replicate the issue. If I do the trick taught at stackexchange (answer 69), I find - as the final string of <M-->. However, without, any trick, that is, without using the sed -n l command, if I hold the left Alt key and press = in Insert mode, I get ½. So, I put in my init.vim:
let R_assign_map = '½'
and now I can press R_assign_map, but I liked so much the <M-=> that now I switched to it.
Maybe someone else can find a way of mapping <M-->...
Thanks for reporting the issue!
@jalvesaq:
... if I hold the left Alt key and press = in Insert mode, I get ½.
If I do the same, I am taken to normal mode (neovim 0.4.4, us layout).
My keyboard has the Brazilian layout. The keys are mostly in the same position as in the U.S. keyboard, but it seems that we have more variation in the output of Alt keys.
I'm closing the issue because the problem is fixed in Neovim: let R_assign_map = '<M-->' works as expected.
I don't know when it was fixed... I'm using Neovim v0.9.0-dev.
Not working yet with ViM 8.2 on Debian stable (https://packages.debian.org/bullseye/source/vim) :(
It does not work with Vim, only with GVim and Neovim. But it is a limitation of Vim, not Nvim-R.
Do you mean this will not work even with future versions of ViM?
I don't know because I'm not part of Vim's development team, but similar issues have already been reported: https://github.com/vim/vim/issues?q=is%3Aissue+is%3Aopen+map+alt+key+