防止vim自动展开折叠

发布于 2024-08-05 10:18:29 字数 180 浏览 3 评论 0原文

我在 Python 代码中使用 foldmethod=marker#{{{ #}}} 标记。

输入 #{{{ 后,vim 会自动展开光标下方的所有折叠。

是否可以将其关闭?

I'm using foldmethod=marker and #{{{ #}}} markers in Python code.

After typing #{{{ vim automatically expands all folds below the cursor.

Is it possible to turn this off?

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

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

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

挽清梦 2024-08-12 10:18:29

尝试从“foldopen”选项中删除块。

:set foldopen-=block

或者也许 Foldclose=all 选项...

:set foldclose=all

Try removing block from the "foldopen" option.

:set foldopen-=block

Or maybe the foldclose=all option...

:set foldclose=all
柒夜笙歌凉 2024-08-12 10:18:29

尝试添加 # {{{ 的匹配项,例如 # {{{1>,然后添加 # }}}1

Try adding a match for the # {{{ like # {{{1 and then a # }}}1

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文