Skip to content

Store view regions in undo history#132

Open
darshan-Jahagirdar wants to merge 2 commits into
limetext:masterfrom
darshan-Jahagirdar:codex/undo-stack-regions
Open

Store view regions in undo history#132
darshan-Jahagirdar wants to merge 2 commits into
limetext:masterfrom
darshan-Jahagirdar:codex/undo-stack-regions

Conversation

@darshan-Jahagirdar
Copy link
Copy Markdown

@darshan-Jahagirdar darshan-Jahagirdar commented May 12, 2026

Fixes #101.

This stores a deep snapshot of the view region map at edit start and edit end, then restores the correct snapshot during undo/redo. Selection restoration now uses the same snapshot path, and glued undo entries preserve the first saved region state plus the final current state.

Validation:

  • Added TestUndoStackRestoresViewRegions covering named regions across edit, undo, and redo.
  • git diff --check passes.
  • go test ./render ./clipboard ./keys ./log passes locally.

Could not run the backend package tests on this Windows environment because the existing TextMate/rubex dependency fails to build with CGO disabled (undefined: rubex.Regexp, rubex.CompileWithOption). Existing watcher/package tests also fail on Windows file watcher setup with The parameter is incorrect.

Bounty: targets the $15 Bountysource bounty linked from #101.

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.

The undo stack needs to store regions [$15]

1 participant