Hi there,
I love vim and admire all the job done here. I have tried all in stackoverflow and other blogs without success. Ctrl + Right/Left is creating a lot issues on my developments it deletes lines and I have spent a lot of time fixing those changes , so I want to block this shortcut is not helping me. Would anybody please help me with this ?
Thanks in advance.
Regards,
Julio
stop deleting lines
ubuntu 20
8.1
none
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub.
Triage notifications on the go with GitHub Mobile for iOS or Android.
![]()
Which terminal are you using?
What's the output of echo $TERM in the shell?
What's the output of :set <xRight>? in Vim?
In insert mode, if you press CTRL-V then CTRL-Right, what is inserted in the buffer?
Do you use a terminal multiplexer? If so, which one? And what is the output of echo $TERM outside as well as inside this terminal multiplexer?
—
You are receiving this because you commented.
Hi Gary, I have applied those changes in my vimrc but the problem remains, after I ran the verbose command maps are pointing to my vimrc (same lines I added). I'm sorry I did not know this is the dev repo, will move my question to the other repo.
Hi lacygoill, as per your questions:
—
You are receiving this because you commented.
E846: Key code not set:
Try to add this into your vimrc:
if &term =~ '^\%(screen\|tmux\)'
" Enable modified arrow keys, see :help xterm-modifier-keys
execute "silent! set <xUp>=\<Esc>[@;*A"
execute "silent! set <xDown>=\<Esc>[@;*B"
execute "silent! set <xRight>=\<Esc>[@;*C"
execute "silent! set <xLeft>=\<Esc>[@;*D"
endif
Make sure that :echo &term contains either the string screen or tmux when you start Vim from inside tmux.
Ctrl-V then Ctrl-Right, delete lines
I doubt it does that if you are in insert mode. You probably pressed the keys from normal mode. Try again from insert mode (or from command-line mode).
I use tmux
TERM out multiplexer: same as inside VIM - screen-256color
If $TERM is the same inside and outside tmux, then that's wrong. Outside, it should identify the real terminal (e.g. xterm-256color). Inside, it should identify screen or tmux.
—
You are receiving this because you commented.
Thank you all! Yes that condition fixed my problem! what an awesome support!
—
You are receiving this because you commented.