defaults: enable 'smarttab' by default. #2855

This commit is contained in:
Felipe Morales
2015-06-18 17:23:29 -03:00
committed by Justin M. Keyes
parent 8b200f904f
commit 41c76d9444
4 changed files with 6 additions and 3 deletions

View File

@@ -5862,7 +5862,7 @@ A jump table for the options with a short description can be found at |Q_op|.
NOTE: When 'paste' is set smart indenting is disabled.
*'smarttab'* *'sta'* *'nosmarttab'* *'nosta'*
'smarttab' 'sta' boolean (default off)
'smarttab' 'sta' boolean (default on)
global
When on, a <Tab> in front of a line inserts blanks according to
'shiftwidth'. 'tabstop' or 'softtabstop' is used in other places. A

View File

@@ -33,6 +33,7 @@ these differences.
- 'formatoptions' defaults to "tcqj"
- 'nocompatible' is always set
- 'nrformats' defaults to "hex"
- 'smarttab' is set by default
- 'tags' defaults to "./tags;,tags"
- 'ttyfast' is always set
- 'wildmenu' is set by default

View File

@@ -1407,9 +1407,9 @@ static vimoption_T
{"smartindent", "si", P_BOOL|P_VI_DEF|P_VIM,
(char_u *)&p_si, PV_SI,
{(char_u *)FALSE, (char_u *)0L} SCRIPTID_INIT},
{"smarttab", "sta", P_BOOL|P_VI_DEF|P_VIM,
{"smarttab", "sta", P_BOOL|P_VIM,
(char_u *)&p_sta, PV_NONE,
{(char_u *)FALSE, (char_u *)0L} SCRIPTID_INIT},
{(char_u *)FALSE, (char_u *)TRUE} SCRIPTID_INIT},
{"softtabstop", "sts", P_NUM|P_VI_DEF|P_VIM,
(char_u *)&p_sts, PV_STS,
{(char_u *)0L, (char_u *)0L} SCRIPTID_INIT},

View File

@@ -10,6 +10,8 @@ describe('Virtual replace mode', function()
it('is working', function()
-- Make sure that backspace works, no matter what termcap is used.
execute('set t_kD=x7f t_kb=x08')
-- Use vi default for 'smarttab'
execute('set nosmarttab')
feed('ggdGa<cr>')
feed('abcdefghi<cr>')
feed('jk<tab>lmn<cr>')