0

我使用 Jedi-vim 进行 vim python 自动补全,效果很好。它具有按需显示功能预览/文档的快捷方式。

我现在正在从事 C++ 项目,我正在尝试使用原始的omnicomplete+ctag 来完成同样的事情。但是我在 Jedi-vim 中找不到类似的功能。

我不想通过“:set completeopt+=preview”一直显示预览窗口,也不想使用像“YouCompleteMe”这样巨大的自动补全插件,我只想打开/跳转预览一经请求。有没有办法实现它?提前致谢!

4

1 回答 1

0

我想你会觉得:help preview-window很有趣。

" shows the definition of foo in the preview window
:ptag foo

" shows the definition of the symbol under the cursor in the preview window
<C-w>}

不过,您需要使用 ctags 或一些兼容的程序为您的项目编制索引才能使该功能正常工作。

" doesn't need ctags
:psearch foo
于 2014-11-03T08:58:38.730 回答