Feature:
A cursor jump point undo/redo stack is maintained separately from the main undo/redo stacks. Cursor jump points take you to a cell position in a particular order (index) in a particular subsong (index). Cursor jump points are stored onto the undo stack when "major cursor movement occurs".
Currently cursor jump points are stored in the following conditions (you can just search for makeCursorUndo()):
cursor coarse up/down
cursor channel left/right
cursor top/bottom
any click outside the current row or channel
paste (if settings.cursorPastePos)
play (if followPattern is on)
go-to-result in find menu
switch/add/duplicate SubSong (i don't know much about this so this is the least tested)
I also added a handy cursor undo/redo stack visualizer to the Debug menu
Status:
I'm finding this super useful (i have it mapped to ctrl-o and ctrl-i like vim/vscode), but also assume it'll need some tweaking over time, to identify the most useful/consistent makeCursorUndo() conditions, and in terms of edge cases when orders or subsongs are destroyed/reordered (i don't think we'll see crashes, but could have some weird scenarios?)
Feature: A cursor jump point undo/redo stack is maintained separately from the main undo/redo stacks. Cursor jump points take you to a cell position in a particular order (index) in a particular subsong (index). Cursor jump points are stored onto the undo stack when "major cursor movement occurs".
Currently cursor jump points are stored in the following conditions (you can just search for
makeCursorUndo()
):settings.cursorPastePos
)demo
https://github.com/user-attachments/assets/229f26f2-d166-42c1-a621-128520ad4946
I also added a handy cursor undo/redo stack visualizer to the Debug menu
Status: I'm finding this super useful (i have it mapped to ctrl-o and ctrl-i like vim/vscode), but also assume it'll need some tweaking over time, to identify the most useful/consistent
makeCursorUndo()
conditions, and in terms of edge cases when orders or subsongs are destroyed/reordered (i don't think we'll see crashes, but could have some weird scenarios?)