]> git.rmz.io Git - dotfiles.git/blobdiff - vim/ftplugin/cpp.vim
awesome: add function to check if host has battery
[dotfiles.git] / vim / ftplugin / cpp.vim
index 7dd40e60d9239aa5f98ec1e98a78c22e39cda2df..af391a13f56976ff8d3e2b7c0b40abd6c348bf5b 100644 (file)
@@ -16,11 +16,14 @@ let b:load_doxygen_syntax = 1
 
 augroup fswitch
     au BufEnter *.h   let b:fswitchdst  = 'cpp,c'
 
 augroup fswitch
     au BufEnter *.h   let b:fswitchdst  = 'cpp,c'
-    au BufEnter *.h   let b:fswitchlocs = 'reg:/include/source/'
+    au BufEnter *.h   let b:fswitchlocs = 'reg:|include.*|source|'
     au BufEnter *.cpp let b:fswitchdst  = 'h'
     au BufEnter *.cpp let b:fswitchdst  = 'h'
-    au BufEnter *.cpp let b:fswitchlocs = 'reg:/\Csource/include/'
+    au BufEnter *.cpp let b:fswitchlocs = 'reg:|source|include/**|'
 augroup END
 
 augroup END
 
+nnoremap <buffer> gd :YcmCompleter GoTo<CR>
+nnoremap <buffer> <C-W>d :vs<CR>:YcmCompleter GoTo<CR>
+
 setlocal foldmethod=syntax
 " set foldlevel according to number of matches of 'namespace' and 'class' not
 " containing ';'
 setlocal foldmethod=syntax
 " set foldlevel according to number of matches of 'namespace' and 'class' not
 " containing ';'