Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

XkbSwitchIMappings does not work with Meta-mappings #25

Open
yunake opened this issue Jan 8, 2016 · 2 comments
Open

XkbSwitchIMappings does not work with Meta-mappings #25

yunake opened this issue Jan 8, 2016 · 2 comments

Comments

@yunake
Copy link

yunake commented Jan 8, 2016

The XkbSwitchIMappings appears to ignore existing insert-mode mappings with Meta (Alt). I'm not sure there's a way to fix this though: I have not been able to get cyrillic meta mappings to work at all, neither in normal nor in insert.

Oh this of course only applies to console vim with terminal configured to send for alt-combos as per ECMA-35, which is needed if you want to use Unicode. I have no idea how the plugin works with regular, 8th-bit meta (do you want me to test?)

@lyokha
Copy link
Owner

lyokha commented Jan 8, 2016

I tried to map a command to <M-...> key:

imap <silent> <M-b>       <Plug>RightAlign

(No matter what RightAlign is), then checking with :imap I got i â <Plug>RightAlign - of course this is not translatable in standard Insert mappings translation tables, actually in my terminal <M-...> is translated into a composed character for all types of mappings. I do not know how to fix it and if it is fixable at all.

Extending of standard Insert mappings translation table could help if <M-и> (as expected translation of <M-b>) and other cyrillic compositions would translate into a composed character, but it does not.

@lyokha
Copy link
Owner

lyokha commented Jan 8, 2016

Looks like I managed to do correct translation of Meta mappings in my terminal (mate-terminal with older vte2, xterm-256color). Just using ^[ notation instead <M-. For example let's shift a string in Insert mode to the right by one shiftwidth (which is normally <C-T>) by <Alt-b>

imap <silent> ^[b <C-T>

Character ^[ is really one character (Escape character) that can be inserted by entering <C-V><C-[> in Insert mode. Now both <Alt-b> and <Alt-и> work. But it does not work in gvim.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants