Skip to content

Add smoothdrag for smooth mouse-drag panning capture#82

Merged
tig merged 1 commit into
mainfrom
claude/smoothdrag
Jun 6, 2026
Merged

Add smoothdrag for smooth mouse-drag panning capture#82
tig merged 1 commit into
mainfrom
claude/smoothdrag

Conversation

@tig

@tig tig commented Jun 6, 2026

Copy link
Copy Markdown
Member

Fixes #81.

drag: emits its press, all interpolated motion events, and release at one instant, so apps that re-render on motion (e.g. a sixel preview that pans by re-cropping) coalesce the burst and a recording captures a 2-3 frame jump instead of the smooth pan seen interactively.

smoothdrag:c1:r1:c2:r2[:stepMs] expands into a press, one motion event per cell spaced stepMs apart (default 40ms ~= 25fps), and a release, so the app redraws each intermediate position. The player now honors a per-action Delay on Write actions (used for the stepped motions) instead of always applying the global keystroke delay.

Covered by unit tests; full keystroke suite + vet green.

drag: writes its press, all interpolated motion events, and release at one
instant, so apps that re-render on motion coalesce the burst and a recording
captures a 2-3 frame jump instead of the smooth pan seen interactively.

smoothdrag:c1:r1:c2:r2[:stepMs] expands into a press, one motion event per
cell spaced stepMs apart (default 40ms ~= 25fps), and a release, so the app
redraws each intermediate position. The player now honors a per-action Delay
on Write actions (used for the stepped motions) instead of always applying the
global keystroke delay.

Fixes #81.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@tig tig merged commit 16ce965 into main Jun 6, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add smoothdrag for capturing smooth mouse-drag panning

1 participant