0

Functional keys (F1-F12) for vim in console don't work. But the worst thing is when I hit such key, vim stays in some "mode" not allowing me to type anything for 2s... Very annoying

Another thing is after pressing Esc key vim pause for about 0.5s before go to normal mode.. But this is only happening in screen, even I set

export TERM=xterm

Anybody has some clean and short solution?

BenMorel
  • 34,448
  • 50
  • 182
  • 322
Tomek Wyderka
  • 1,425
  • 1
  • 15
  • 21
  • I couldn't post here smile ":)" after word "annoying". Reason: does not meet our quality standards... :) – Tomek Wyderka Dec 05 '12 at 14:46
  • 1
    Vim has nothing to do with console not working, my Vim instance works great with functional keys. What you are looking for is your console setting and the mode you use. By default these keys are not mapped, how can you tell they are not working? What is your mapping? For me Vim works in both urxvt and xterm pretty well. – lzap Dec 05 '12 at 14:55
  • I don't know what is my mapping. I've probably never change it. How I can check it? – Tomek Wyderka Dec 05 '12 at 17:01
  • Is your TERM correct *outside* of `screen`? This is the important one. – Itay Perl Dec 05 '12 at 17:13
  • 1
    Regarding the escape delay: you probably want something like `maptimeout 0` in your `.screenrc`. – Itay Perl Dec 05 '12 at 17:16
  • Thanks Itay Perl. That works great! – Tomek Wyderka Dec 05 '12 at 18:30
  • I had alias v="vim -T builtin_ansi". sorry for not necessary question. – Tomek Wyderka Dec 05 '12 at 18:32

1 Answers1

0

Sounds like some disagreement between the byte sequences vim thinks the terminal is going to send, and the sequences it actually does.

Also the half-second delay is a consequence of having some mappings that start with Escape.

LeoNerd
  • 8,344
  • 1
  • 29
  • 36
  • It was my wrong defined terminal type. But that half-second delay it was really screen fault. Adding `maptimeout 0` is a solution. I'm wonder why screen have such delay... – Tomek Wyderka Dec 06 '12 at 03:35