ietf-tools / editor

A fully featured editor to write, review, refine and submit Internet-Drafts.
https://draftforge.ietf.org
Other
11 stars 2 forks source link

The ability to undo/redo edits should span Save actions #33

Open ajeanmahoney opened 9 months ago

ajeanmahoney commented 9 months ago

A user should be able to type, save, and then undo (or redo) the edits that they made before the save action. Currently, neither undo nor redo work if the document was just saved. The edit buffer can be flushed when the document is closed, though.

ajeanmahoney commented 9 months ago

I can undo/redo basic edits before saving, but I can't undo a Reindent action even if it's the only edit I've made and I haven't saved.

NGPixel commented 9 months ago

Are you saving / under / redo via the toolbar or within the editor using keyboard shortcuts (Cmd+S, Cmd+Z, Cmd+Y) ?

ajeanmahoney commented 9 months ago

Keyboard shortcuts

NGPixel commented 1 month ago

I'm not able to replicate this bug? I tried both scenarios:

Test 1:

Test 2:

Can you try again using the latest build?

ajeanmahoney commented 1 month ago

Test 1 passes - I can undo edits that were made before a save point and edits made before 4 save points.

Test 2 fails - I cannot undo a "Reformat" even if I haven't saved. I used both Cmd + Z and selected Edit > Undo.

Note that Cmd + Y doesn't work on my system, but Cmd + Shift + Z does, which is the short cut shown for Edit > Redo.