0
0
mirror of https://github.com/vim/vim.git synced 2025-11-15 23:14:06 -05:00

updated for version 7.4a.041

Problem:    When using ":new ++ff=unix" and "dos" is first in 'fileformats'
            then 'ff' is set to "dos" instead of "unix". (Ingo Karkat)
Solution:   Create set_file_options() and invoke it from do_ecmd().
This commit is contained in:
Bram Moolenaar
2013-07-24 15:02:03 +02:00
parent e24a9c0b59
commit ad875fb7ff
6 changed files with 77 additions and 30 deletions

View File

@@ -3,6 +3,7 @@ vim: set ft=vim :
STARTTEST
:so small.vim
:so mbyte.vim
:"
:" Test for getbufvar()
:" Use strings to test for memory leaks.
@@ -22,6 +23,17 @@ STARTTEST
:$put =string(getbufvar(1, '&autoindent'))
:$put =string(getbufvar(1, '&autoindent', 1))
:"
:" Open new window with forced option values
:set fileformats=unix,dos
:new ++ff=dos ++bin ++enc=iso-8859-2
:let otherff = getbufvar(bufnr('%'), '&fileformat')
:let otherbin = getbufvar(bufnr('%'), '&bin')
:let otherfenc = getbufvar(bufnr('%'), '&fenc')
:close
:$put =otherff
:$put =string(otherbin)
:$put =otherfenc
:unlet otherff otherbin otherfenc
:" test for getwinvar()
:let w:var_str = "Dance"
:let def_str = "Chance"

View File

@@ -10,6 +10,9 @@ start:
'5678'
0
0
dos
1
iso-8859-2
'Dance'
'Dance'
{'var_str': 'Dance'}