Just before all this started to happen, I rebuilt the IDE because I had just downloaded RichMemo.
Could this have been the cause?
"Downloading" a package by itself has no effect, but when it is a designtime packages and you "install" it you modify the IDE and can make it unstable. Therefore, installing third-party components always poses some (small) risk of issues. Whenever possible try to use third-party packages from the Online-Package-Manager - this repository is rather well-maintained (in contrast to many repos on the author's or cloned sites - of course, it depends...)
I don't know of instabilities due to RichMemo, though. But you can always uninstall the component and see if the issue goes away: Go to "Packages" > "Install/uninstall packages". If RichMemo is installed its package its package ("richmemopackage 1.0") should appear in the LEFT lists. Select it, click "Uninstall selection", then "Save and rebuild IDE".