annotate src/testdir/color_ramp.vim @ 18660:4d2a88cc5821 v8.1.2322

patch 8.1.2322: quickfix test fails in very big terminal Commit: https://github.com/vim/vim/commit/ffc4fb8fee4521a86670ae791411e319b6a2e1fd Author: Bram Moolenaar <Bram@vim.org> Date: Tue Nov 19 22:38:48 2019 +0100 patch 8.1.2322: quickfix test fails in very big terminal Problem: Quickfix test fails in very big terminal. Solution: Adjust the expected result for the width. (Masato Nishihata, closes #5244)
author Bram Moolenaar <Bram@vim.org>
date Tue, 19 Nov 2019 22:45:04 +0100
parents 2d54f1e7ba0f
children 89364104be93
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
12944
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
1 " Script to generate a file that shows al 256 xterm colors
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
2
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
3 new
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
4 call setline(1, 'ANSI')
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
5
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
6 " ANSI colors
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
7 let s = ''
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
8 for nr in range(0, 7)
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
9 let s .= "\033[4" . nr . "m "
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
10 endfor
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
11 for nr in range(8, 15)
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
12 let s .= "\033[10" . (nr - 8) . "m "
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
13 endfor
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
14 " Add | in original color pair to see white background.
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
15 let s .= "\033[m|"
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
16 call setline(2, s)
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
17
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
18 " 6 x 6 x 6 color cube
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
19 call setline(3, 'color cube')
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
20 for high in range(0, 5)
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
21 let s = ''
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
22 for low in range(0, 35)
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
23 let nr = low + high * 36
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
24 let s .= "\033[48;5;" . (nr + 16) . "m "
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
25 endfor
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
26 let s .= "\033[m|"
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
27 call setline(high + 4, s)
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
28 endfor
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
29
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
30 " 24 shades of grey
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
31 call setline(10, 'grey ramp')
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
32 let s = ''
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
33 for nr in range(0, 23)
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
34 let s .= "\033[48;5;" . (nr + 232) . "m "
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
35 endfor
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
36 let s .= "\033[m|"
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
37 call setline(11, s)
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
38
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
39 set binary
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
40 write! <sfile>:h/color_ramp.txt
2d54f1e7ba0f patch 8.0.1348: make testclean deletes script file on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
41 quit