如何锁定 vim 中的 CTRL_X CTRL_T 选项以仅查找同义词

发布于 2025-01-20 01:57:29 字数 348 浏览 2 评论 0原文

我已将同义词库文件设置为

first, second, third
one, two, three
fibonacci, gauss, euler
firstly, lastly

现在,如果我输入单词“first”并使用 ctrl-x ctrl-t,vim 会使用第一行和第四行中的单词(即

第一、第二、第三、首先、最后)

扩展自动完成菜单,因为它还自动完成第一个到第一个,并包括包含它的整行。这不是我想要的,因为第四行与第一行无关,并且要自动完成单词,我会使用不同的自动完成选项,例如 ctrl-x ctrl-k。

如何让 vim 自动补全仅包含我输入的单词所在行中的单词?

I have set my thesaurus file to

first, second, third
one, two, three
fibonacci, gauss, euler
firstly, lastly

Now if I type a word "first" and use ctrl-x ctrl-t, vim expands autocomplete menu with words both from the first and fourth line, namely

first, second, third, firstly, lastly

because it also autocompletes first to firstly, and includes the whole line containing it. Which is not what I wanted, because the fourth line has nothing to do with the first line, and to autocomplete to a word I would use a different autocomplete option, like ctrl-x ctrl-k.

How do i make vim autocomplete with just the words in the line with the word I typed?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文