feat(defaults): set hidden

This commit is contained in:
Gregory Anders 2021-08-17 12:12:09 -06:00
parent 15b736d6e8
commit f6c72b745c
4 changed files with 4 additions and 2 deletions

View File

@ -3078,7 +3078,7 @@ A jump table for the options with a short description can be found at |Q_op|.
See |help-translated|.
*'hidden'* *'hid'* *'nohidden'* *'nohid'*
'hidden' 'hid' boolean (default off)
'hidden' 'hid' boolean (default on)
global
When off a buffer is unloaded when it is |abandon|ed. When on a
buffer becomes hidden when it is |abandon|ed. If the buffer is still

View File

@ -41,6 +41,7 @@ the differences.
- 'fillchars' defaults (in effect) to "vert:│,fold:·,sep:│"
- 'formatoptions' defaults to "tcqj"
- 'fsync' is disabled
- 'hidden' is enabled
- 'history' defaults to 10000 (the maximum)
- 'hlsearch' is enabled
- 'incsearch' is enabled

View File

@ -1081,7 +1081,7 @@ return {
short_desc=N_("don't unload buffer when it is |abandon|ed"),
type='bool', scope={'global'},
varname='p_hid',
defaults={if_true=false}
defaults={if_true=true}
},
{
full_name='highlight', abbreviation='hl',

View File

@ -55,6 +55,7 @@ describe(":drop", function()
end)
it("splits off a new window when a buffer can't be abandoned", function()
command("set nohidden")
feed_command("edit tmp1")
feed_command("vsplit")
feed_command("edit tmp2")