Notepad plugin: Resize correctly after edit mode

Thanks to Patrik Bachan for investigating (#529)