Просмотр исходного кода

fix mouse support for vim

screen mouse still broken though, since scrollwheel still doesn't let us view
the buffer for that window
Weiyi Lou 13 лет назад
Родитель
Сommit
9abf06a748
2 измененных файлов с 6 добавлено и 7 удалено
  1. 3 3
      screen/screenrc
  2. 3 4
      vim/vimrc

+ 3 - 3
screen/screenrc

@@ -58,15 +58,15 @@ term                  linux
 
 # Tweak termcap, terminfo, and termcapinfo  entries for best performance.
 termcap               linux           'AF=\E[3%dm:AB=\E[4%dm'
-termcap               xterm-color     'AF=\E[3%dm:AB=\E[4%dm'
+termcap               xterm*          'AF=\E[3%dm:AB=\E[4%dm'
 terminfo              linux           'AF=\E[3%p1%dm:AB=\E[4%p1%dm'
-terminfo              xterm-color     'AF=\E[3%p1%dm:AB=\E[4%p1%dm'
+terminfo              xterm*          'AF=\E[3%p1%dm:AB=\E[4%p1%dm'
 
 # Allow xterm / Terminal scrollbars to access the scrollback buffer. This
 # enables the behavior you'd expect, instead of losing the content that scrolls
 # out of the window.
 termcapinfo           linux           ti@:te@
-termcapinfo           xterm-color     ti@:te@
+termcapinfo           xterm*          ti@:te@
 
 # Use visual bell instead of audio bell.
 vbell                 on              # default: ???

+ 3 - 4
vim/vimrc

@@ -21,10 +21,9 @@ if has("persistent_undo")
     set undodir=~/.vimundo
 endif
 
-"if version >= 700
-"    set mouse=a "mouse support for 7.x, but don't use this if we use screen
-"    because it has no effect, and then just becomes annoying for copy/paste
-"endif 
+" mouse support. TODO: Are there any checks we should be doing?
+set ttymouse=xterm2
+set mouse=a
 
 if has("autocmd")
     " Enable filetype specific features