macvim icon indicating copy to clipboard operation
macvim copied to clipboard

cmd + é does not work

Open R0GG opened this issue 9 years ago • 12 comments

Hi,

I have this settings in my .vimrc but who knows why, with the lastest release cmd + é (D-é) does not work to switch tab.

map <D-&> 1gt<CR> map <D-é> 2gt<CR> map <D-"> 3gt<CR> map <D-'> 4gt<CR>

Also, imap <D-é> 2gt<CR>does not work. Instead, it writes <D-é>

Everything works with the snapshot 100.

edit: also, cmd + è does not work

edit: everything works fine for snapshot under 104 for 105 and 106, map <D-"> 3gt<CR> does not work and for 107+ map <D-é> 2gt<CR> and map <D-è> 7gt<CR> do not work

R0GG avatar Oct 16 '16 14:10 R0GG

It sounds the root cause of this issue is #300 right?

splhack avatar Oct 16 '16 22:10 splhack

with debug: screen shot 2016-10-17 at 10 29 07

R0GG avatar Oct 17 '16 08:10 R0GG

That's not the same issue as #300. I copy pasted the same part of code from 104 to 112 and it does not work.

R0GG avatar Oct 19 '16 13:10 R0GG

I'm pretty sure that it's more a Vim issue than a MacVim issue.

R0GG avatar Oct 21 '16 22:10 R0GG

I know I can input é character with this key sequence, option + e, and e. It sounds you have a keyboard which allows to input é character directly, right? I can't investigate this issue.

splhack avatar Oct 22 '16 05:10 splhack

Still not working. (8.0.1203 (139)) To reproduce the issue, you have to switch your keyboard layout: go to system preference->keyboard->Input Sources, add french-> ABC azerty.

Then add map <D-é> 2gt<CR> to your .vimrc. Now open 2 tabs in gui macvim. Check that your keyboard layout is the french one and then try to switch to the 2nd tab using cmd + é which should be cmd + 2 on a qwerty layout. It is as simple as that.

R0GG avatar Oct 20 '17 21:10 R0GG

@R0GG Does your issue is still actual? Which macOs do you use? Which keyboard layout do you use?

eirnym avatar May 18 '19 09:05 eirnym

Yup masOS Mojave 10.14.4 keyboard is french -> french

R0GG avatar May 23 '19 09:05 R0GG

This key seems to be bonded in any app on my macOS. Could you try to use Karabiner or similar software to check where does it go?

eirnym avatar May 24 '19 09:05 eirnym

Not sure what you want me to check. Btw you need to test this using macvim's GUI because shortcuts using cmd+key do not work using vim inside a terminal. And if you do like in insert mode: ctrl+v then cmd+é (which map to cmd+2 for qwerty keyboards) it prints <D-é>

R0GG avatar May 24 '19 13:05 R0GG

I bet there's some "odd" default mapping for this key specifically or key processing inside macOS/MacVim/Vim

My observations:

  • mvim -u NONE -U NONE has the same issue
  • Command-2 is not in a game, I've tried to bind to it separately and it works fine
  • Only Normal mode is affected, Insert mode allows remapping this key, Visual mode hasn't been tested
  • Normally, if key is unbounded, I hear no sound in MacVim, with this key I hear an "error" sound.
  • This is is happening even I disable macmenu bindings and most keybindings I found
  • Finder throws similar sound effect

@R0GG I asked you to test by Karabiner to find out if this is not macOS-specific thing for NSTextView/NSTextField @ychin may be you have any ideas on this?

eirnym avatar May 24 '19 17:05 eirnym

It seems to be a "dead key" problem.

I had difficulty with mapping the "˜" symbol (n key) and solved it with custom layout with dead keys removed as described here: https://stackoverflow.com/a/455854/4177749

xaiamov avatar May 01 '20 10:05 xaiamov