summaryrefslogtreecommitdiffstats
path: root/patches/source/vim/patches/7.4.370
blob: 5da13f467148d53a8402b8832155e1ecdc950d8d (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
To: vim_dev@googlegroups.com
Subject: Patch 7.4.370
Fcc: outbox
From: Bram Moolenaar <Bram@moolenaar.net>
Mime-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
------------

Patch 7.4.370
Problem:    Linebreak test fails when encoding is not utf-8. (Danek Duvall)
Solution:   Split the test in a single byte one and a utf-8 one. (Christian
	    Brabandt)
Files:	    src/testdir/Make_amiga.mak, src/testdir/Make_dos.mak,
	    src/testdir/Make_ming.mak, src/testdir/Make_os2.mak,
	    src/testdir/Make_vms.mms, src/testdir/Makefile,
	    src/testdir/test_listlbr.in, src/testdir/test_listlbr.ok,
	    src/testdir/test_listlbr_utf8.in, src/testdir/test_listlbr_utf8.ok


*** ../vim-7.4.369/src/testdir/Make_amiga.mak	2014-07-02 19:59:35.454375136 +0200
--- src/testdir/Make_amiga.mak	2014-07-16 16:55:15.311578352 +0200
***************
*** 39,44 ****
--- 39,45 ----
  		test_autoformat_join.out \
  		test_breakindent.out \
  		test_listlbr.out \
+ 		test_listlbr_utf8.out \
  		test_eval.out \
  		test_options.out
  
***************
*** 167,171 ****
--- 168,173 ----
  test_autoformat_join.out: test_autoformat_join.in
  test_breakindent.out: test_breakindent.in
  test_listlbr.out: test_listlbr.in
+ test_listlbr_utf8.out: test_listlbr_utf8.in
  test_eval.out: test_eval.in
  test_options.out: test_options.in
*** ../vim-7.4.369/src/testdir/Make_dos.mak	2014-07-16 14:20:38.255766903 +0200
--- src/testdir/Make_dos.mak	2014-07-16 16:56:02.423577394 +0200
***************
*** 38,43 ****
--- 38,44 ----
  		test_autoformat_join.out \
  		test_breakindent.out \
  		test_listlbr.out \
+ 		test_listlbr_utf8.out \
  		test_eval.out \
  		test_options.out
  
*** ../vim-7.4.369/src/testdir/Make_ming.mak	2014-07-02 19:59:35.454375136 +0200
--- src/testdir/Make_ming.mak	2014-07-16 16:55:15.311578352 +0200
***************
*** 58,63 ****
--- 58,64 ----
  		test_autoformat_join.out \
  		test_breakindent.out \
  		test_listlbr.out \
+ 		test_listlbr_utf8.out \
  		test_eval.out \
  		test_options.out
  
*** ../vim-7.4.369/src/testdir/Make_os2.mak	2014-07-02 19:59:35.454375136 +0200
--- src/testdir/Make_os2.mak	2014-07-16 16:55:15.311578352 +0200
***************
*** 40,45 ****
--- 40,46 ----
  		test_autoformat_join.out \
  		test_eval.out \
  		test_breakindent.out \
+ 		test_listlbr_utf8.out \
  		test_listlbr.out \
  		test_options.out
  
*** ../vim-7.4.369/src/testdir/Make_vms.mms	2014-07-02 19:59:35.454375136 +0200
--- src/testdir/Make_vms.mms	2014-07-16 16:55:15.311578352 +0200
***************
*** 99,104 ****
--- 99,105 ----
  	 test_autoformat_join.out \
  	 test_breakindent.out \
  	 test_listlbr.out \
+ 	 test_listlbr_utf8.out \
  	 test_eval.out \
  	 test_options.out
  
*** ../vim-7.4.369/src/testdir/Makefile	2014-07-02 19:59:35.454375136 +0200
--- src/testdir/Makefile	2014-07-16 16:55:15.311578352 +0200
***************
*** 36,41 ****
--- 36,42 ----
  		test_autoformat_join.out \
  		test_breakindent.out \
  		test_listlbr.out \
+ 		test_listlbr_utf8.out \
  		test_eval.out \
  		test_options.out
  
*** ../vim-7.4.369/src/testdir/test_listlbr.in	2014-07-02 19:59:35.454375136 +0200
--- src/testdir/test_listlbr.in	2014-07-16 16:55:15.311578352 +0200
***************
*** 1,10 ****
! Test for linebreak and list option
  
  STARTTEST
  :so small.vim
  :if !exists("+linebreak") | e! test.ok | w! test.out | qa! | endif
  :10new|:vsp|:vert resize 20
! :put =\"\tabcdef hijklmn\tpqrstuvwxyz\u00a01060ABCDEFGHIJKLMNOP \"
  :norm! zt
  :set ts=4 sw=4 sts=4 linebreak sbr=+ wrap
  :fu! ScreenChar(width)
--- 1,10 ----
! Test for linebreak and list option (non-utf8)
  
  STARTTEST
  :so small.vim
  :if !exists("+linebreak") | e! test.ok | w! test.out | qa! | endif
  :10new|:vsp|:vert resize 20
! :put =\"\tabcdef hijklmn\tpqrstuvwxyz_1060ABCDEFGHIJKLMNOP \"
  :norm! zt
  :set ts=4 sw=4 sts=4 linebreak sbr=+ wrap
  :fu! ScreenChar(width)
***************
*** 32,53 ****
  :redraw!
  :let line=ScreenChar(winwidth(0))
  :call DoRecordScreen()
! :let g:test ="Test 3: set linebreak + set list + fancy listchars"
! :exe "set linebreak list listchars=nbsp:\u2423,tab:\u2595\u2014,trail:\u02d1,eol:\ub6"
! :redraw!
! :let line=ScreenChar(winwidth(0))
! :call DoRecordScreen()
! :let g:test ="Test 4: set linebreak nolist"
  :set nolist linebreak
  :redraw!
  :let line=ScreenChar(winwidth(0))
  :call DoRecordScreen()
! :let g:test ="Test 5: set nolinebreak list"
! :set list nolinebreak
! :redraw!
! :let line=ScreenChar(winwidth(0))
! :call DoRecordScreen()
! :let g:test ="Test 6: set linebreak with tab and 1 line as long as screen: should break!"
  :set nolist linebreak ts=8
  :let line="1\t".repeat('a', winwidth(0)-2)
  :$put =line
--- 32,43 ----
  :redraw!
  :let line=ScreenChar(winwidth(0))
  :call DoRecordScreen()
! :let g:test ="Test 3: set linebreak nolist"
  :set nolist linebreak
  :redraw!
  :let line=ScreenChar(winwidth(0))
  :call DoRecordScreen()
! :let g:test ="Test 4: set linebreak with tab and 1 line as long as screen: should break!"
  :set nolist linebreak ts=8
  :let line="1\t".repeat('a', winwidth(0)-2)
  :$put =line
*** ../vim-7.4.369/src/testdir/test_listlbr.ok	2014-07-02 19:59:35.454375136 +0200
--- src/testdir/test_listlbr.ok	2014-07-16 16:55:15.315578352 +0200
***************
*** 1,38 ****
  
! 	abcdef hijklmn	pqrstuvwxyz 1060ABCDEFGHIJKLMNOP 
  
  Test 1: set linebreak
      abcdef          
  +hijklmn            
! +pqrstuvwxyz 1060ABC
  +DEFGHIJKLMNOP      
  
  Test 2: set linebreak + set list
  ^Iabcdef hijklmn^I  
! +pqrstuvwxyz 1060ABC
  +DEFGHIJKLMNOP      
                      
  
! Test 3: set linebreak + set list + fancy listchars
! ▕———abcdef          
! +hijklmn▕———        
! +pqrstuvwxyz␣1060ABC
! +DEFGHIJKLMNOPˑ¶    
! 
! Test 4: set linebreak nolist
      abcdef          
  +hijklmn            
! +pqrstuvwxyz 1060ABC
  +DEFGHIJKLMNOP      
- 
- Test 5: set nolinebreak list
- ▕———abcdef hijklmn▕—
- +pqrstuvwxyz␣1060ABC
- +DEFGHIJKLMNOPˑ¶    
- ¶                   
  1	aaaaaaaaaaaaaaaaaa
  
! Test 6: set linebreak with tab and 1 line as long as screen: should break!
  1                   
  +aaaaaaaaaaaaaaaaaa 
  ~                   
--- 1,26 ----
  
! 	abcdef hijklmn	pqrstuvwxyz_1060ABCDEFGHIJKLMNOP 
  
  Test 1: set linebreak
      abcdef          
  +hijklmn            
! +pqrstuvwxyz_1060ABC
  +DEFGHIJKLMNOP      
  
  Test 2: set linebreak + set list
  ^Iabcdef hijklmn^I  
! +pqrstuvwxyz_1060ABC
  +DEFGHIJKLMNOP      
                      
  
! Test 3: set linebreak nolist
      abcdef          
  +hijklmn            
! +pqrstuvwxyz_1060ABC
  +DEFGHIJKLMNOP      
  1	aaaaaaaaaaaaaaaaaa
  
! Test 4: set linebreak with tab and 1 line as long as screen: should break!
  1                   
  +aaaaaaaaaaaaaaaaaa 
  ~                   
*** ../vim-7.4.369/src/testdir/test_listlbr_utf8.in	2014-07-16 17:01:25.415570829 +0200
--- src/testdir/test_listlbr_utf8.in	2014-07-16 16:55:15.315578352 +0200
***************
*** 0 ****
--- 1,41 ----
+ Test for linebreak and list option in utf-8 mode
+ 
+ STARTTEST
+ :so small.vim
+ :if !exists("+linebreak") | e! test.ok | w! test.out | qa! | endif
+ :so mbyte.vim
+ :if &enc !=? 'utf-8'|:e! test.ok|:w! test.out|qa!|endif
+ :10new|:vsp|:vert resize 20
+ :put =\"\tabcdef hijklmn\tpqrstuvwxyz\u00a01060ABCDEFGHIJKLMNOP \"
+ :norm! zt
+ :set ts=4 sw=4 sts=4 linebreak sbr=+ wrap
+ :fu! ScreenChar(width)
+ :	let c=''
+ :	for j in range(1,4)
+ :	    for i in range(1,a:width)
+ :	    	let c.=nr2char(screenchar(j, i))
+ :	    endfor
+ :           let c.="\n"
+ :	endfor
+ :	return c
+ :endfu
+ :fu! DoRecordScreen()
+ :	wincmd l
+ :	$put =printf(\"\n%s\", g:test)
+ :	$put =g:line
+ :	wincmd p
+ :endfu
+ :let g:test ="Test 1: set linebreak + set list + fancy listchars"
+ :exe "set linebreak list listchars=nbsp:\u2423,tab:\u2595\u2014,trail:\u02d1,eol:\ub6"
+ :redraw!
+ :let line=ScreenChar(winwidth(0))
+ :call DoRecordScreen()
+ :let g:test ="Test 2: set nolinebreak list"
+ :set list nolinebreak
+ :redraw!
+ :let line=ScreenChar(winwidth(0))
+ :call DoRecordScreen()
+ :%w! test.out
+ :qa!
+ ENDTEST
+ dummy text
*** ../vim-7.4.369/src/testdir/test_listlbr_utf8.ok	2014-07-16 17:01:25.419570829 +0200
--- src/testdir/test_listlbr_utf8.ok	2014-07-16 16:55:15.315578352 +0200
***************
*** 0 ****
--- 1,14 ----
+ 
+ 	abcdef hijklmn	pqrstuvwxyz 1060ABCDEFGHIJKLMNOP 
+ 
+ Test 1: set linebreak + set list + fancy listchars
+ ▕———abcdef          
+ +hijklmn▕———        
+ +pqrstuvwxyz␣1060ABC
+ +DEFGHIJKLMNOPˑ¶    
+ 
+ Test 2: set nolinebreak list
+ ▕———abcdef hijklmn▕—
+ +pqrstuvwxyz␣1060ABC
+ +DEFGHIJKLMNOPˑ¶    
+ ¶                   
*** ../vim-7.4.369/src/version.c	2014-07-16 16:30:21.647608710 +0200
--- src/version.c	2014-07-16 16:56:38.755576656 +0200
***************
*** 736,737 ****
--- 736,739 ----
  {   /* Add new patch number below this line */
+ /**/
+     370,
  /**/

-- 
   Another bucket of what can only be described as human ordure hits ARTHUR.
ARTHUR: ... Right!  (to the KNIGHTS) That settles it!
                 "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD

 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\  an exciting new programming language -- http://www.Zimbu.org        ///
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///