summaryrefslogtreecommitdiff
path: root/test/snapshots/hscroll.snap
blob: 3f371147c9134a11ca8a2e599d144d4bc5719282 (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
# horizontal scroll, file panes only (terminals wrap at pty width): the
# horizontal wheel shifts the content window (gutter stays put, no scrollbar),
# and keyboard movement keeps the scrolloff margin sideways — $ on a long
# line pulls the view right, 0 snaps it back. Overscroll right is allowed;
# a cursor move reels it in.
file wide.txt short1 END_A_MARKER_WAY_OUT_RIGHT_padpadpadpadpadpadpadpadpadpadpadpadpadpad_TAIL
start 30 90 -n 3
wait 8000 wide.txt
stable 700 20000
# open wide.txt: click a body spot, type the name, look it
press left 5 8
release left 5 8
stable 400 5000
key i
text wide.txt
key esc
settle 100
stable 400 5000
press right 7 8
release right 7 8
stable 700 15000
snap opened
# wheel right over the file pane: content shifts, line numbers stay
send \x1b[<66;10;3M
send \x1b[<66;10;3M
stable 400 5000
snap wheeled
# wheel back left past the start clamps at column 0
send \x1b[<67;10;3M
send \x1b[<67;10;3M
send \x1b[<67;10;3M
stable 400 5000
snap clamped
# $ walks the cursor to the line end: the view follows with the margin
key g g
stable 400 5000
key $
stable 400 5000
snap dollar
# 0 back to column zero: the view snaps home
key 0
stable 400 5000
snap zero