Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

undo autopaste should (maybe) reset autopaste "vector" #946

Open
dave-doty opened this issue Oct 2, 2023 · 2 comments
Open

undo autopaste should (maybe) reset autopaste "vector" #946

dave-doty opened this issue Oct 2, 2023 · 2 comments
Assignees
Labels
invalid This doesn't seem right

Comments

@dave-doty
Copy link
Member

Draw a strand:

image

Copy/Paste:

image

Press Ctrl+Shift+V to autopaste three times:

image

Press Ctrl+Z three times to undo:

image

Now press Ctrl+Shift+V to autopaste again:

image

Note that this goes in the place where autopaste would have pasted the next strand after the most recent autopaste. However, this is somewhat unexpected behavior; a user might expect "Undo" to mean "Undo the autopaste meta-information about where the next autopasted strand should go" and expected Autopaste to put the strand adjacent to the existing strands, as it did the first time.

@dave-doty dave-doty added the invalid This doesn't seem right label Oct 2, 2023
@dave-doty dave-doty self-assigned this Oct 2, 2023
@dave-doty dave-doty assigned dave-doty and nehashafi18 and unassigned dave-doty Aug 9, 2024
@dave-doty
Copy link
Member Author

What should happen here is that autopaste should put the third strand immediately to the right of the second strand, as happened the first time that we only had two strands. In other words we need Undo to undo not only the change to which strands are in the design, but also undo the change in internal Autopaste data (stored in AppUIState.copy_info) that happens after each time you press Ctrl+Shift+V.

@dave-doty
Copy link
Member Author

I think the most straightforward fix here is to include a CopyInfo field in the UndoRedoItem object, alongside the Design.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
invalid This doesn't seem right
Projects
None yet
Development

No branches or pull requests

2 participants