#59 Action-based undo/redo

Closed
opened 1 year ago by nuclearkev · 1 comments

There are many benefits to doing this:

  • less confusing code as actions are easy to distinguish
  • less chance of memory bugs as it only saves the data that needs to be changed opposed to the entire buffer
  • better stability as I've had a heck of a time with the current undo
  • easier debugging, actions are easier to trace
  • fixes duplicated data bug (very common with the current method)
  • similar to other editors (both OpenBSD's mg and Adam Saponara's mle editors use this method
  • faster, it's a lot quicker to copy <100 chars than thousands of chars
  • action packed because it use actions
There are many benefits to doing this: - less confusing code as actions are easy to distinguish - less chance of memory bugs as it only saves the data that needs to be changed opposed to the entire buffer - better stability as I've had a heck of a time with the current undo - easier debugging, actions are easier to trace - fixes duplicated data bug (very common with the current method) - similar to other editors (both OpenBSD's `mg` and Adam Saponara's `mle` editors use this method - faster, it's a lot quicker to copy <100 chars than thousands of chars - action packed because it use actions

Closed with the action-based-undo branch. Merged in to master.

Closed with the action-based-undo branch. Merged in to master.
Sign in to join this conversation.
Loading...
Cancel
Save
There is no content yet.