diff --git a/python/nammu/controller/NammuController.py b/python/nammu/controller/NammuController.py index 52d6db75..1edf4e93 100644 --- a/python/nammu/controller/NammuController.py +++ b/python/nammu/controller/NammuController.py @@ -203,6 +203,7 @@ def openFile(self, event=None): # we dont highlight before the full file is loaded runSwingLater(self.initHighlighting) + # TODO: Else, prompt user to choose again before closing # Update settings with current file's path @@ -212,6 +213,9 @@ def openFile(self, event=None): # Finally, refresh the edit area to propagate custom font settings self.atfAreaController.refreshEditArea() + # Clear stack of edits + self.atfAreaController.view.undo_manager.discardAllEdits() + def initHighlighting(self): ''' A helper function to be called when we need to initialise syntax