diff options
| author | Gabriel Schneider <[email protected]> | 2026-07-31 23:21:17 -0300 |
|---|---|---|
| committer | Gabriel Schneider <[email protected]> | 2026-08-01 15:02:08 -0300 |
| commit | bc6abf1716a4824513c325204302f2fd229c2974 (patch) | |
| tree | 12d55d882ce32c86f67163894203913fe69e19c5 /test | |
| parent | f4ac5ee26851ced516b826953fa340008fa7069c (diff) | |
| download | pardes-bc6abf1716a4824513c325204302f2fd229c2974.tar.gz pardes-bc6abf1716a4824513c325204302f2fd229c2974.zip | |
a corner grab drags the column edge and the pane edge at once
Diffstat (limited to 'test')
| -rw-r--r-- | test/snapshots/cornerdrag.golden | 248 | ||||
| -rw-r--r-- | test/snapshots/cornerdrag.snap | 51 |
2 files changed, 299 insertions, 0 deletions
diff --git a/test/snapshots/cornerdrag.golden b/test/snapshots/cornerdrag.golden new file mode 100644 index 00000000..30ebaee1 --- /dev/null +++ b/test/snapshots/cornerdrag.golden @@ -0,0 +1,248 @@ +== snap hover-corner grid=100x30 cursor=4,4 +|Kill Newcol Tutor Debug NextColor Dump Find Grep Help +|• /tmp/pardes-snap/cornerdrag/cwd Del ╎• /tmp/pardes-snap/cornerdrag/cwd Del +| ╎ +| w.txt ╎ w.txt +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +|╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌ +|• /tmp/pardes-snap/cornerdrag/cwd Del ╎ +| ╎ +| w.txt ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +== snap edge-drag grid=100x30 cursor=4,4 +|Kill Newcol Tutor Debug NextColor Dump Find Grep Help +|• /tmp/pardes-snap/cornerdrag╎cwd Del • /tmp/pardes-snap/cornerdrag/cwd Del +| ╎ +| w.txt ╎ w.txt +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +|• /tmp/pardes-snap/cornerdrag╎cwd Del +| ╎ +| w.txt ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +== snap edge-done grid=100x30 cursor=4,4 +|Kill Newcol Tutor Debug NextColor Dump Find Grep Help +|• /tmp/pardes-snap/cornerdrag/• /tmp/pardes-snap/cornerdrag/cwd Del +| +| w.txt w.txt +| +| +| +| +| +| +| +| +| +| +| +| +|• /tmp/pardes-snap/cornerdrag/ +| +| w.txt +| +| +| +| +| +| +| +| +| +| +| +== snap corner-drag grid=100x30 cursor=4,4 +|Kill Newcol Tutor Debug NextColor Dump Find Grep Help +|• /tmp/pardes-snap/cornerdrag/• /tmp/pardes-snap/cornerdrag╎cwd Del +| ╎ +| w.txt w.txt ╎ +| ╎ +| ╎ +| ╎ +|╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +|• /tmp/pardes-snap/cornerdrag/ ╎ +| ╎ +| w.txt ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +== snap corner-done grid=100x30 cursor=4,4 +|Kill Newcol Tutor Debug NextColor Dump Find Grep Help +|• /tmp/pardes-snap/cornerdrag/cwd Del • /tmp/pardes-snap/cornerdrag/cwd Del +| +| w.txt w.txt +| +| +| +| +|• /tmp/pardes-snap/cornerdrag/cwd Del +| +| w.txt +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +== snap clamp-x grid=100x30 cursor=4,4 +|Kill Newcol Tutor Debug NextColor Dump Find Grep Help +|• /tmp/pardes-snap/cornerdrag/cwd Del • /tmp/pardes-snap/cornerdrag/╎wd Del +| ╎ +| w.txt w.txt ╎ +| ╎ +| ╎ +| ╎ +| ╎ +|• /tmp/pardes-snap/cornerdrag/cwd Del ╎ +| ╎ +| w.txt ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +|╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +== snap clamp-y grid=100x30 cursor=4,4 +|Kill Newcol Tutor Debug NextColor Dump Find Grep Help +|• /tmp/pardes-snap/cornerdrag/cwd Del ╎• /tmp/pardes-snap/cornerdrag/cwd Del +| ╎ +| w.txt ╎ w.txt +| ╎ +| ╎ +| ╎ +| ╎ +|• /tmp/pardes-snap/cornerdrag/cwd Del ╎ +| ╎ +| w.txt ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +| ╎ +|╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌ +| ╎ +== snap clamp-done grid=100x30 cursor=4,4 +|Kill Newcol Tutor Debug NextColor Dump Find Grep Help +|• /tmp/pardes-snap/cornerdrag/cwd Del • /tmp/pardes-snap/cornerdrag/cwd Del +| +| w.txt w.txt +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +|• /tmp/pardes-snap/cornerdrag/cwd Del diff --git a/test/snapshots/cornerdrag.snap b/test/snapshots/cornerdrag.snap new file mode 100644 index 00000000..1ad5d5ae --- /dev/null +++ b/test/snapshots/cornerdrag.snap @@ -0,0 +1,51 @@ +# corner grabs: where a column edge crosses a pane edge, ONE drag moves both. +# Only the left column's h-splits make a corner — the v handle IS that column's +# last cell, so that is the only pane pair whose horizontal hint runs through +# it, and a corner therefore sits exactly where the two lines visibly cross. +# The layout is windowops': col 0 (x 0, w 50) holds panes 0 (rows 1-15) and 1 +# (rows 16-29), col 1 holds one pane. The corner is col 49, row 15. +file w.txt x +start 30 100 -n 3 +wait 8000 w.txt +stable 700 20000 +# hover the corner: BOTH hints light, before anything is grabbed +motion 50 16 +stable 400 5000 +snap hover-corner +# CONTROL: the same vertical edge ten rows off the crossing is a plain edge. +# The identical diagonal drag moves the column and nothing else — pane 0 still +# ends on row 15, and the preview is one dash, not two +press left 50 6 +drag left 30 24 +stable 400 5000 +snap edge-drag +release left 30 24 +motion 45 25 +stable 500 8000 +snap edge-done +# the corner itself, now at col 0's new last col (29) and still row 15: drag it +# up and to the right and both boundaries follow the one mouse +press left 30 16 +drag left 60 8 +stable 400 5000 +snap corner-drag +release left 60 8 +motion 45 25 +stable 500 8000 +snap corner-done +# clamp interaction, half one: shove the corner off the right edge while +# staying mid-height. The column preview parks at its MINW stop; the row +# preview keeps tracking the mouse exactly +press left 60 8 +drag left 99 20 +stable 400 5000 +snap clamp-x +# half two, the mirror: below the bottom at mid-width. Now the ROW preview +# parks (the lower pane keeps its tag row) and the COLUMN keeps tracking +drag left 60 30 +stable 400 5000 +snap clamp-y +release left 60 30 +motion 45 25 +stable 500 8000 +snap clamp-done |
