Clave de reasignación para etiqueta emergente

I am trying to remap Ctrl + [ a :pop. I have rebound my Ctrl + t a :tabe y Ctrl + cambio + T to new shell tab. I came up with:

nnoremap <C-[> :pop

but when I do this I get :pop on almost every keystroke, and even mouse clicks.

The idea being that this keymapping tacks me back up the chain of the tags list. Opposite of Ctrl + ]

preguntado el 03 de mayo de 12 a las 20:05

La <esc>clave y <c-[> not distinguishable. See :h escape. You will want to come up w/ a different mapping. -

@PeterRincker If you move this to an answer I'll accept it. This was what was causing the issue. -

1 Respuestas

en una terminal, <Esc> es el mismo que <C-[>; both are represented by the same keycode.

Due to the way that the keyboard input is handled internally, differentiating this as well as many other key combinations (like Ctrl+Letter vs. Ctrl+Shift+Letter) unfortunately isn't possible today, even in GVIM. This is a known pain point, and the subject of various discussions on vim_dev and the #vim IRC channel.

Algunas personas (sobre todo Paul LeoNerd Evans) quieren arreglar eso (incluso para la consola Vim en terminales que lo admitan), y han presentado varias propuestas, cp. http://groups.google.com/group/vim_dev/browse_thread/thread/626e83fa4588b32a/bfbcb22f37a8a1f8

Pero a partir de hoy, aún no se han presentado parches ni voluntarios, aunque muchos han expresado el deseo de tener esto en un futuro lanzamiento principal de Vim 8.

contestado el 04 de mayo de 12 a las 07:05

Thank you for the thread. This would be a great addition to Vim. - Pedro Rincker

No es la respuesta que estás buscando? Examinar otras preguntas etiquetadas or haz tu propia pregunta.