如何在打开文件时设置默认展开? [英] How to set the default to unfolded when you open a file?

查看:217
本文介绍了如何在打开文件时设置默认展开?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在我的 .vimrc 中,我已经把 set foldmethod = syntax 我不喜欢默认情况下,每次打开文件,整个事情就是折叠。有没有一种方法来启用 foldmethod ,但打开文件时展开的文件? 解决方案 div>

  set foldlevel = 99 

应该全部打开折叠,无论用于折叠的方法。有 foldlevel = 0 全部折叠, foldlevel = 1 只有一些,...更高的数字将关闭更少的折叠。 / p>

In my .vimrc I've put set foldmethod=syntax to enable folding of methods etc. However, I don't like the default that everytime I open a file, the whole thing is folded. Is there a way to enable foldmethod, yet have files unfolded when I open them?

解决方案

set foldlevel=99

should open all folds, regardless of method used for folding. With foldlevel=0 all folded, foldlevel=1 only somes, ... higher numbers will close fewer folds.

这篇关于如何在打开文件时设置默认展开?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆