comparison src/libvterm/t/12state_scroll.test @ 11621:b8299e742f41 v8.0.0693

patch 8.0.0693: no terminal emulator support commit https://github.com/vim/vim/commit/e4f25e4a8db2c8a8a71a4ba2a68540b3ab341e42 Author: Bram Moolenaar <Bram@vim.org> Date: Fri Jul 7 11:54:15 2017 +0200 patch 8.0.0693: no terminal emulator support Problem: No terminal emulator support. Cannot properly run commands in the GUI. Cannot run a job interactively with an ssh connection. Solution: Very early implementation of the :terminal command. Includes libvterm converted to ANSI C. Many parts still missing.
author Christian Brabandt <cb@256bit.org>
date Fri, 07 Jul 2017 12:00:04 +0200
parents
children 747a270eb1db
comparison
equal deleted inserted replaced
11620:fb788b3997c1 11621:b8299e742f41
1 INIT
2 UTF8 1
3 WANTSTATE s
4
5 !Linefeed
6 PUSH "\n"x24
7 ?cursor = 24,0
8 PUSH "\n"
9 scrollrect 0..25,0..80 => +1,+0
10 ?cursor = 24,0
11
12 RESET
13
14 !Index
15 PUSH "\e[25H"
16 PUSH "\eD"
17 scrollrect 0..25,0..80 => +1,+0
18
19 RESET
20
21 !Reverse Index
22 PUSH "\eM"
23 scrollrect 0..25,0..80 => -1,+0
24
25 RESET
26
27 !Linefeed in DECSTBM
28 PUSH "\e[1;10r"
29 ?cursor = 0,0
30 PUSH "\n"x9
31 ?cursor = 9,0
32 PUSH "\n"
33 scrollrect 0..10,0..80 => +1,+0
34 ?cursor = 9,0
35
36 !Linefeed outside DECSTBM
37 PUSH "\e[20H"
38 ?cursor = 19,0
39 PUSH "\n"
40 ?cursor = 20,0
41
42 !Index in DECSTBM
43 PUSH "\e[10H"
44 PUSH "\e[9;10r"
45 PUSH "\eM"
46 ?cursor = 8,0
47 PUSH "\eM"
48 scrollrect 8..10,0..80 => -1,+0
49
50 !Reverse Index in DECSTBM
51 PUSH "\e[25H"
52 ?cursor = 24,0
53 PUSH "\n"
54 # no scrollrect
55 ?cursor = 24,0
56
57 !Linefeed in DECSTBM+DECSLRM
58 PUSH "\e[?69h"
59 PUSH "\e[3;10r\e[10;40s"
60 PUSH "\e[10;10H\n"
61 scrollrect 2..10,9..40 => +1,+0
62
63 !IND/RI in DECSTBM+DECSLRM
64 PUSH "\eD"
65 scrollrect 2..10,9..40 => +1,+0
66 PUSH "\e[3;10H\eM"
67 scrollrect 2..10,9..40 => -1,+0
68
69 !DECRQSS on DECSTBM
70 PUSH "\eP\$qr\e\\"
71 output "\eP1\$r3;10r\e\\"
72
73 !DECRQSS on DECSLRM
74 PUSH "\eP\$qs\e\\"
75 output "\eP1\$r10;40s\e\\"
76
77 !Setting invalid DECSLRM with !DECVSSM is still rejected
78 PUSH "\e[?69l\e[;0s\e[?69h"
79
80 RESET
81
82 !Scroll Down
83 PUSH "\e[S"
84 scrollrect 0..25,0..80 => +1,+0
85 ?cursor = 0,0
86 PUSH "\e[2S"
87 scrollrect 0..25,0..80 => +2,+0
88 ?cursor = 0,0
89 PUSH "\e[100S"
90 scrollrect 0..25,0..80 => +25,+0
91
92 !Scroll Up
93 PUSH "\e[T"
94 scrollrect 0..25,0..80 => -1,+0
95 ?cursor = 0,0
96 PUSH "\e[2T"
97 scrollrect 0..25,0..80 => -2,+0
98 ?cursor = 0,0
99 PUSH "\e[100T"
100 scrollrect 0..25,0..80 => -25,+0
101
102 !SD/SU in DECSTBM
103 PUSH "\e[5;20r"
104 PUSH "\e[S"
105 scrollrect 4..20,0..80 => +1,+0
106 PUSH "\e[T"
107 scrollrect 4..20,0..80 => -1,+0
108
109 RESET
110
111 !SD/SU in DECSTBM+DECSLRM
112 PUSH "\e[?69h"
113 PUSH "\e[3;10r\e[10;40s"
114 ?cursor = 0,0
115 PUSH "\e[3;10H"
116 ?cursor = 2,9
117 PUSH "\e[S"
118 scrollrect 2..10,9..40 => +1,+0
119 PUSH "\e[?69l"
120 PUSH "\e[S"
121 scrollrect 2..10,0..80 => +1,+0
122
123 !Invalid boundaries
124 RESET
125
126 PUSH "\e[100;105r\eD"
127 PUSH "\e[5;2r\eD"
128
129 RESET
130 WANTSTATE -s+me
131
132 !Scroll Down move+erase emulation
133 PUSH "\e[S"
134 moverect 1..25,0..80 -> 0..24,0..80
135 erase 24..25,0..80
136 ?cursor = 0,0
137 PUSH "\e[2S"
138 moverect 2..25,0..80 -> 0..23,0..80
139 erase 23..25,0..80
140 ?cursor = 0,0
141
142 !Scroll Up move+erase emulation
143 PUSH "\e[T"
144 moverect 0..24,0..80 -> 1..25,0..80
145 erase 0..1,0..80
146 ?cursor = 0,0
147 PUSH "\e[2T"
148 moverect 0..23,0..80 -> 2..25,0..80
149 erase 0..2,0..80
150 ?cursor = 0,0