annotate src/testdir/test_listlbr.in @ 8378:52777ec8a394 v7.4.1481

commit https://github.com/vim/vim/commit/9f7820f83bc994bbbecdca9483b355953f07179b Author: Bram Moolenaar <Bram@vim.org> Date: Thu Mar 3 17:22:49 2016 +0100 patch 7.4.1481 Problem: Can't build with small features. Solution: Add #ifdef.
author Christian Brabandt <cb@256bit.org>
date Thu, 03 Mar 2016 17:30:13 +0100
parents 68f2cac6b0db
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
6062
50575818a97f updated for version 7.4.370
Bram Moolenaar <bram@vim.org>
parents: 6026
diff changeset
1 Test for linebreak and list option (non-utf8)
6026
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
2
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
3 STARTTEST
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
4 :so small.vim
6266
0a4efa3d2019 updated for version 7.4.467
Bram Moolenaar <bram@vim.org>
parents: 6189
diff changeset
5 :if !exists("+linebreak") || !has("conceal") | e! test.ok | w! test.out | qa! | endif
6026
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
6 :10new|:vsp|:vert resize 20
6062
50575818a97f updated for version 7.4.370
Bram Moolenaar <bram@vim.org>
parents: 6026
diff changeset
7 :put =\"\tabcdef hijklmn\tpqrstuvwxyz_1060ABCDEFGHIJKLMNOP \"
6026
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
8 :norm! zt
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
9 :set ts=4 sw=4 sts=4 linebreak sbr=+ wrap
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
10 :fu! ScreenChar(width)
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
11 : let c=''
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
12 : for j in range(1,4)
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
13 : for i in range(1,a:width)
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
14 : let c.=nr2char(screenchar(j, i))
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
15 : endfor
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
16 : let c.="\n"
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
17 : endfor
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
18 : return c
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
19 :endfu
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
20 :fu! DoRecordScreen()
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
21 : wincmd l
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
22 : $put =printf(\"\n%s\", g:test)
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
23 : $put =g:line
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
24 : wincmd p
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
25 :endfu
7344
68f2cac6b0db commit https://github.com/vim/vim/commit/9bc01ebb957d2b30d57bd30d7aee6f1df2a336b0
Christian Brabandt <cb@256bit.org>
parents: 7143
diff changeset
26 :"
6026
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
27 :let g:test="Test 1: set linebreak"
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
28 :redraw!
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
29 :let line=ScreenChar(winwidth(0))
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
30 :call DoRecordScreen()
7344
68f2cac6b0db commit https://github.com/vim/vim/commit/9bc01ebb957d2b30d57bd30d7aee6f1df2a336b0
Christian Brabandt <cb@256bit.org>
parents: 7143
diff changeset
31 :"
6026
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
32 :let g:test="Test 2: set linebreak + set list"
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
33 :set linebreak list listchars=
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
34 :redraw!
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
35 :let line=ScreenChar(winwidth(0))
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
36 :call DoRecordScreen()
7344
68f2cac6b0db commit https://github.com/vim/vim/commit/9bc01ebb957d2b30d57bd30d7aee6f1df2a336b0
Christian Brabandt <cb@256bit.org>
parents: 7143
diff changeset
37 :"
6062
50575818a97f updated for version 7.4.370
Bram Moolenaar <bram@vim.org>
parents: 6026
diff changeset
38 :let g:test ="Test 3: set linebreak nolist"
6026
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
39 :set nolist linebreak
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
40 :redraw!
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
41 :let line=ScreenChar(winwidth(0))
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
42 :call DoRecordScreen()
7344
68f2cac6b0db commit https://github.com/vim/vim/commit/9bc01ebb957d2b30d57bd30d7aee6f1df2a336b0
Christian Brabandt <cb@256bit.org>
parents: 7143
diff changeset
43 :"
6062
50575818a97f updated for version 7.4.370
Bram Moolenaar <bram@vim.org>
parents: 6026
diff changeset
44 :let g:test ="Test 4: set linebreak with tab and 1 line as long as screen: should break!"
6026
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
45 :set nolist linebreak ts=8
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
46 :let line="1\t".repeat('a', winwidth(0)-2)
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
47 :$put =line
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
48 :$
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
49 :norm! zt
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
50 :redraw!
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
51 :let line=ScreenChar(winwidth(0))
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
52 :call DoRecordScreen()
6172
69da1498ce89 updated for version 7.4.422
Bram Moolenaar <bram@vim.org>
parents: 6062
diff changeset
53 :let line="_S_\t bla"
69da1498ce89 updated for version 7.4.422
Bram Moolenaar <bram@vim.org>
parents: 6062
diff changeset
54 :$put =line
69da1498ce89 updated for version 7.4.422
Bram Moolenaar <bram@vim.org>
parents: 6062
diff changeset
55 :$
69da1498ce89 updated for version 7.4.422
Bram Moolenaar <bram@vim.org>
parents: 6062
diff changeset
56 :norm! zt
7344
68f2cac6b0db commit https://github.com/vim/vim/commit/9bc01ebb957d2b30d57bd30d7aee6f1df2a336b0
Christian Brabandt <cb@256bit.org>
parents: 7143
diff changeset
57 :"
6172
69da1498ce89 updated for version 7.4.422
Bram Moolenaar <bram@vim.org>
parents: 6062
diff changeset
58 :let g:test ="Test 5: set linebreak with conceal and set list and tab displayed by different char (line may not be truncated)"
69da1498ce89 updated for version 7.4.422
Bram Moolenaar <bram@vim.org>
parents: 6062
diff changeset
59 :set cpo&vim list linebreak conceallevel=2 concealcursor=nv listchars=tab:ab
69da1498ce89 updated for version 7.4.422
Bram Moolenaar <bram@vim.org>
parents: 6062
diff changeset
60 :syn match ConcealVar contained /_/ conceal
69da1498ce89 updated for version 7.4.422
Bram Moolenaar <bram@vim.org>
parents: 6062
diff changeset
61 :syn match All /.*/ contains=ConcealVar
69da1498ce89 updated for version 7.4.422
Bram Moolenaar <bram@vim.org>
parents: 6062
diff changeset
62 :let line=ScreenChar(winwidth(0))
69da1498ce89 updated for version 7.4.422
Bram Moolenaar <bram@vim.org>
parents: 6062
diff changeset
63 :call DoRecordScreen()
6266
0a4efa3d2019 updated for version 7.4.467
Bram Moolenaar <bram@vim.org>
parents: 6189
diff changeset
64 :set cpo&vim linebreak
7344
68f2cac6b0db commit https://github.com/vim/vim/commit/9bc01ebb957d2b30d57bd30d7aee6f1df2a336b0
Christian Brabandt <cb@256bit.org>
parents: 7143
diff changeset
65 :"
6266
0a4efa3d2019 updated for version 7.4.467
Bram Moolenaar <bram@vim.org>
parents: 6189
diff changeset
66 :let g:test ="Test 6: set linebreak with visual block mode"
0a4efa3d2019 updated for version 7.4.467
Bram Moolenaar <bram@vim.org>
parents: 6189
diff changeset
67 :let line="REMOVE: this not"
6866
8ebcd7f1ff5b patch 7.4.753
Bram Moolenaar <bram@vim.org>
parents: 6266
diff changeset
68 :$put =g:test
6266
0a4efa3d2019 updated for version 7.4.467
Bram Moolenaar <bram@vim.org>
parents: 6189
diff changeset
69 :$put =line
0a4efa3d2019 updated for version 7.4.467
Bram Moolenaar <bram@vim.org>
parents: 6189
diff changeset
70 :let line="REMOVE: aaaaaaaaaaaaa"
0a4efa3d2019 updated for version 7.4.467
Bram Moolenaar <bram@vim.org>
parents: 6189
diff changeset
71 :$put =line
0a4efa3d2019 updated for version 7.4.467
Bram Moolenaar <bram@vim.org>
parents: 6189
diff changeset
72 :1/^REMOVE:
0a4efa3d2019 updated for version 7.4.467
Bram Moolenaar <bram@vim.org>
parents: 6189
diff changeset
73 0jf x:$put
6866
8ebcd7f1ff5b patch 7.4.753
Bram Moolenaar <bram@vim.org>
parents: 6266
diff changeset
74 :set cpo&vim linebreak
7344
68f2cac6b0db commit https://github.com/vim/vim/commit/9bc01ebb957d2b30d57bd30d7aee6f1df2a336b0
Christian Brabandt <cb@256bit.org>
parents: 7143
diff changeset
75 :"
6866
8ebcd7f1ff5b patch 7.4.753
Bram Moolenaar <bram@vim.org>
parents: 6266
diff changeset
76 :let g:test ="Test 7: set linebreak with visual block mode and v_b_A"
8ebcd7f1ff5b patch 7.4.753
Bram Moolenaar <bram@vim.org>
parents: 6266
diff changeset
77 :$put =g:test
8ebcd7f1ff5b patch 7.4.753
Bram Moolenaar <bram@vim.org>
parents: 6266
diff changeset
78 Golong line: 40afoobar aTARGET at end
8ebcd7f1ff5b patch 7.4.753
Bram Moolenaar <bram@vim.org>
parents: 6266
diff changeset
79 :exe "norm! $3B\<C-v>eAx\<Esc>"
8ebcd7f1ff5b patch 7.4.753
Bram Moolenaar <bram@vim.org>
parents: 6266
diff changeset
80 :set cpo&vim linebreak sbr=
7344
68f2cac6b0db commit https://github.com/vim/vim/commit/9bc01ebb957d2b30d57bd30d7aee6f1df2a336b0
Christian Brabandt <cb@256bit.org>
parents: 7143
diff changeset
81 :"
6866
8ebcd7f1ff5b patch 7.4.753
Bram Moolenaar <bram@vim.org>
parents: 6266
diff changeset
82 :let g:test ="Test 8: set linebreak with visual char mode and changing block"
8ebcd7f1ff5b patch 7.4.753
Bram Moolenaar <bram@vim.org>
parents: 6266
diff changeset
83 :$put =g:test
8ebcd7f1ff5b patch 7.4.753
Bram Moolenaar <bram@vim.org>
parents: 6266
diff changeset
84 Go1111-1111-1111-11-1111-1111-11110f-lv3lc2222bgj.
7344
68f2cac6b0db commit https://github.com/vim/vim/commit/9bc01ebb957d2b30d57bd30d7aee6f1df2a336b0
Christian Brabandt <cb@256bit.org>
parents: 7143
diff changeset
85 :"
6961
c2b132add309 patch 7.4.798
Bram Moolenaar <bram@vim.org>
parents: 6866
diff changeset
86 :let g:test ="Test 9: using redo after block visual mode"
c2b132add309 patch 7.4.798
Bram Moolenaar <bram@vim.org>
parents: 6866
diff changeset
87 :$put =g:test
c2b132add309 patch 7.4.798
Bram Moolenaar <bram@vim.org>
parents: 6866
diff changeset
88 Go
c2b132add309 patch 7.4.798
Bram Moolenaar <bram@vim.org>
parents: 6866
diff changeset
89 aaa
c2b132add309 patch 7.4.798
Bram Moolenaar <bram@vim.org>
parents: 6866
diff changeset
90 aaa
c2b132add309 patch 7.4.798
Bram Moolenaar <bram@vim.org>
parents: 6866
diff changeset
91 a2k2j~e.
7344
68f2cac6b0db commit https://github.com/vim/vim/commit/9bc01ebb957d2b30d57bd30d7aee6f1df2a336b0
Christian Brabandt <cb@256bit.org>
parents: 7143
diff changeset
92 :"
7001
27f8247d2619 patch 7.4.818
Bram Moolenaar <bram@vim.org>
parents: 6961
diff changeset
93 :let g:test ="Test 10: using normal commands after block-visual"
27f8247d2619 patch 7.4.818
Bram Moolenaar <bram@vim.org>
parents: 6961
diff changeset
94 :$put =g:test
27f8247d2619 patch 7.4.818
Bram Moolenaar <bram@vim.org>
parents: 6961
diff changeset
95 :set linebreak
27f8247d2619 patch 7.4.818
Bram Moolenaar <bram@vim.org>
parents: 6961
diff changeset
96 Go
27f8247d2619 patch 7.4.818
Bram Moolenaar <bram@vim.org>
parents: 6961
diff changeset
97 abcd{ef
27f8247d2619 patch 7.4.818
Bram Moolenaar <bram@vim.org>
parents: 6961
diff changeset
98 ghijklm
27f8247d2619 patch 7.4.818
Bram Moolenaar <bram@vim.org>
parents: 6961
diff changeset
99 no}pqrs2k0f{c%
7344
68f2cac6b0db commit https://github.com/vim/vim/commit/9bc01ebb957d2b30d57bd30d7aee6f1df2a336b0
Christian Brabandt <cb@256bit.org>
parents: 7143
diff changeset
100 :"
7143
fe6d525d12f4 commit https://github.com/vim/vim/commit/10ad1d90da8c464e1bf08bf23d92d4888378a8a1
Christian Brabandt <cb@256bit.org>
parents: 7001
diff changeset
101 :let g:test ="Test 11: using block replace mode after wrapping"
fe6d525d12f4 commit https://github.com/vim/vim/commit/10ad1d90da8c464e1bf08bf23d92d4888378a8a1
Christian Brabandt <cb@256bit.org>
parents: 7001
diff changeset
102 :$put =g:test
fe6d525d12f4 commit https://github.com/vim/vim/commit/10ad1d90da8c464e1bf08bf23d92d4888378a8a1
Christian Brabandt <cb@256bit.org>
parents: 7001
diff changeset
103 :set linebreak wrap
fe6d525d12f4 commit https://github.com/vim/vim/commit/10ad1d90da8c464e1bf08bf23d92d4888378a8a1
Christian Brabandt <cb@256bit.org>
parents: 7001
diff changeset
104 Go150aayypk147|jr0
7344
68f2cac6b0db commit https://github.com/vim/vim/commit/9bc01ebb957d2b30d57bd30d7aee6f1df2a336b0
Christian Brabandt <cb@256bit.org>
parents: 7143
diff changeset
105 :"
68f2cac6b0db commit https://github.com/vim/vim/commit/9bc01ebb957d2b30d57bd30d7aee6f1df2a336b0
Christian Brabandt <cb@256bit.org>
parents: 7143
diff changeset
106 :let g:test ="Test 12: set linebreak list listchars=space:_,tab:>-,tail:-,eol:$"
68f2cac6b0db commit https://github.com/vim/vim/commit/9bc01ebb957d2b30d57bd30d7aee6f1df2a336b0
Christian Brabandt <cb@256bit.org>
parents: 7143
diff changeset
107 :set list listchars=space:_,trail:-,tab:>-,eol:$
68f2cac6b0db commit https://github.com/vim/vim/commit/9bc01ebb957d2b30d57bd30d7aee6f1df2a336b0
Christian Brabandt <cb@256bit.org>
parents: 7143
diff changeset
108 :$put =g:test
68f2cac6b0db commit https://github.com/vim/vim/commit/9bc01ebb957d2b30d57bd30d7aee6f1df2a336b0
Christian Brabandt <cb@256bit.org>
parents: 7143
diff changeset
109 :let line="a aaaaaaaaaaaaaaaaaaaaaa\ta "
68f2cac6b0db commit https://github.com/vim/vim/commit/9bc01ebb957d2b30d57bd30d7aee6f1df2a336b0
Christian Brabandt <cb@256bit.org>
parents: 7143
diff changeset
110 :$put =line
68f2cac6b0db commit https://github.com/vim/vim/commit/9bc01ebb957d2b30d57bd30d7aee6f1df2a336b0
Christian Brabandt <cb@256bit.org>
parents: 7143
diff changeset
111 :$
68f2cac6b0db commit https://github.com/vim/vim/commit/9bc01ebb957d2b30d57bd30d7aee6f1df2a336b0
Christian Brabandt <cb@256bit.org>
parents: 7143
diff changeset
112 :norm! zt
68f2cac6b0db commit https://github.com/vim/vim/commit/9bc01ebb957d2b30d57bd30d7aee6f1df2a336b0
Christian Brabandt <cb@256bit.org>
parents: 7143
diff changeset
113 :redraw!
68f2cac6b0db commit https://github.com/vim/vim/commit/9bc01ebb957d2b30d57bd30d7aee6f1df2a336b0
Christian Brabandt <cb@256bit.org>
parents: 7143
diff changeset
114 :let line=ScreenChar(winwidth(0))
68f2cac6b0db commit https://github.com/vim/vim/commit/9bc01ebb957d2b30d57bd30d7aee6f1df2a336b0
Christian Brabandt <cb@256bit.org>
parents: 7143
diff changeset
115 :call DoRecordScreen()
6026
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
116 :%w! test.out
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
117 :qa!
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
118 ENDTEST
d42a1d3b74d4 updated for version 7.4.353
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
119 dummy text