diff options
author | Bram Moolenaar <Bram@vim.org> | 2015-04-21 18:33:48 +0200 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2015-04-21 18:33:48 +0200 |
commit | 79278367337be1e9a12222698642dcce0af1e059 (patch) | |
tree | e7ed1960e4cb4fdf3940d7f2212b2c6bf65ca820 /src/testdir/test_listchars.in | |
parent | 40ce3a4e1f50badb75ca812e26557a9bc5fde8c6 (diff) | |
download | vim-79278367337be1e9a12222698642dcce0af1e059.zip |
patch 7.4.710
Problem: It is not possible to make spaces visibible in list mode.
Solution: Add the "space" item to 'listchars'. (David Bürgin, issue 350)
Diffstat (limited to 'src/testdir/test_listchars.in')
-rw-r--r-- | src/testdir/test_listchars.in | 53 |
1 files changed, 53 insertions, 0 deletions
diff --git a/src/testdir/test_listchars.in b/src/testdir/test_listchars.in new file mode 100644 index 000000000..1f19afa1a --- /dev/null +++ b/src/testdir/test_listchars.in @@ -0,0 +1,53 @@ +Tests for 'listchars' display with 'list' and :list + +STARTTEST +:so small.vim +:let g:lines = [] +:function GetScreenCharsForLine(lnum) +: return join(map(range(1, virtcol('$')), 'nr2char(screenchar(a:lnum, v:val))'), '') +:endfunction +:nnoremap <expr> GG ":call add(g:lines, GetScreenCharsForLine(".screenrow()."))\<CR>" +:set listchars+=tab:>-,space:.,trail:< +:set list +: +/^start:/ +:normal! jzt +GG +GG +GG +GG +GGH: +:set listchars-=trail:< +GG +GG +GG +GG +GG: +:put =g:lines +:'[,']w! test.out +ENDTEST + +start: + aa + bb + cccc +dd ee + + + +STARTTEST +:set listchars+=trail:< +:set nolist +: +/^start:/ +:redir! >> test.out +:+1,$list +:redir END +:q! +ENDTEST + +start: + fff + gg + h +iii |