From 0637757f6cc057218ecf0000c44821946df476da Mon Sep 17 00:00:00 2001 From: Samir Benmendil Date: Mon, 24 Oct 2016 09:01:11 +0100 Subject: [PATCH] vim: skip preview window when moving between windows I'm not entirely sure about this. It does help a lot for not giving focus to the ycm doc window. But it also prevents focusing the fugitive status window. It can still be reached with gs though. Maybe this needs a function that checks what the content of the preview window is and skip conditionally. --- vim/vimrc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/vim/vimrc b/vim/vimrc index c6aee80..ef35da8 100644 --- a/vim/vimrc +++ b/vim/vimrc @@ -435,9 +435,9 @@ nnoremap zx zMzxzt map :ls:b -" move between windows -nnoremap w -nnoremap W +" move between windows (skip previewwindow) +nnoremap w:if &previewwindow \| wincmd w \| endif +nnoremap W:if &previewwindow \| wincmd W \| endif "xterm mouse with middleclick paste nnoremap i -- 2.48.1