Original reported at https://github.com/rizonesoft/Notepad3/issues/5146, following steps reproduceable on SciTE:
1. open a file with at least 3 lines.
2. click margin to select line 1, press Tab twice.
3. click margin to select line 2, press Tab twice.
4. click "Undo" button 4 times.
5. click margin to select line 3, press Tab.
6. click "Undo" button.
7. click "Redo" button twice.
Diff:
The undo history wasn't truncated at step 5 where the insertion branched from the earlier actions.
Committed fix as [f81029].
Related
Commit: [f81029]