There is no key labeled "numlock" on my apple keyboard, the "clear" key in the same place seems to function the same way.
I'm not really following about the escape sequences. Are you saying terminfo with rxvt-256color, vim has a hardcoded understanding of the keys, but with screen-256color, it does not? i.e. vim knows rxvt doesn't define these keys, but someone patched vim to understand it rather than fixing the terminfo file? I was able to put this in vim to remap the keys, but it feels more like a hack than a fix. " fix keypad keys in tmux/urxvt :inoremap <C-K> = :inoremap <Esc>Oo / :inoremap <Esc>Oj * :inoremap <Esc>Om - :inoremap <Esc>Ok + :inoremap <Esc>OM <Enter> :inoremap <Esc>On . --John -----Original Message----- From: Nicholas Marriott <[email protected]> Sent: Monday, September 9, 2019 9:51 AM To: [email protected] Cc: [email protected] Subject: Re: numeric keys in vim are wrong in urxvt This seems correct, this sounds like a problem with vim to me, the numeric key escape sequences are not listed in terminfo so my guess would be it is sending smkx and has hardcoded the escape sequences it expects for TERM rxvt* but not for screen* and tmux*. Don't you have a numlock? rxvt should send the symbols directly even with smkx when it is on. On Mon, Sep 09, 2019 at 09:32:51AM -0400, [email protected] wrote: > This is pressing, on the numeric keypad, on an Apple keyboard, =, /, *, -, +, and ENTER. > > $ cat > ^K/*-+ > > /*-+ > ^C > $ tput smkx > $ cat > ^K^[Oo^[Oj^[Om^[Ok^[OM > > ojmkM > > I get the same results inside vim before and after the tput command. > > --John > > -----Original Message----- > From: [email protected] <[email protected]> On > Behalf Of Nicholas Marriott > Sent: Sunday, September 8, 2019 4:46 PM > To: [email protected] > Cc: [email protected] > Subject: Re: numeric keys in vim are wrong in urxvt > > If you run "cat" inside tmux and press the problem keys, what do you see? > > What if you do "tput smkx" then "cat"? > > > > On Sat, Sep 07, 2019 at 05:52:28PM -0400, [email protected] wrote: > > I'm having problems with certain keys on my numpad in vim when using tmux. > > They work outside of vim. It's all the keys other than the numbers. The > > numbers work. (/ * - + . ENTER do not). > > > > > > > > I am using rxvt-unicode-256color. When stating the terminal emulator, I > > have my TERM set to rxvt-unicode-256color. In tmux, the TERM is set to > > screen-256color. > > > > > > > > The tmux version is 2.7 on the jump host I am using, but I installed a > > local copy of tmux 2.9a, and it made no difference. > > > > > > > > If I set the TERM (in tmux) to rxvt-256color, the numpad keys work, but > > HOME and END stop working. I can fix that by setting the TERM to linux and > > then immediately back to rxvt-256color. > > > > > > > > So the only way I have found to get all the keys working is to do this in > > my bashrc. > > > > > > > > export TERM=linux > > > > export TERM=rxvt-256color > > > > > > > > Am I doing something wrong? > > > > > > > > Thanks. > > > > > > > > -- > > You received this message because you are subscribed to the Google Groups > > "tmux-users" group. > > To unsubscribe from this group and stop receiving emails from it, send an > > email to [email protected]. > > To view this discussion on the web, visit > > https://groups.google.com/d/msgid/tmux-users/002b01d565c6%248b73f4e0%24a25bd ea0%24%40technoplaza.net. > > -- > You received this message because you are subscribed to the Google Groups "tmux-users" group. > To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. > To view this discussion on the web, visit https://groups.google.com/d/msgid/tmux-users/20190908204627.ubfws6tkogndyu3e %40yelena. > -- You received this message because you are subscribed to the Google Groups "tmux-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web, visit https://groups.google.com/d/msgid/tmux-users/017e01d567e2%244b2eb640%24e18c22c0%24%40technoplaza.net.
