Borrar filtros
Borrar filtros

Hitting mouse 4 +5 at the same time deletes all code in live editor

2 visualizaciones (últimos 30 días)
Ari Dettman
Ari Dettman el 14 de Feb. de 2022
Respondida: Nihal el 2 de En. de 2024
I ran into an issue, I believe. I was moving around the live editor and I accidentally hit mouse 4+5 at the same time. This cleared the entire live editor of any code, and in my initial panic I closed the project, losing all of my progress. After rewriting the code, I tried it again (this time with a backup save) and it happened again. I wasn't able to replicate it a third time. Is there a reason for this?
  5 comentarios
Ari Dettman
Ari Dettman el 14 de Feb. de 2022
Yes, most likley its something to do with the configuration. Ill look into how they are configured. Thanks!
John D'Errico
John D'Errico el 14 de Feb. de 2022
One possibility is one of the buttons was configured as select all. Then the other is cut. So when you click on them both, it selects everything in the window, and then cuts it to the clipboard, so your window is now empty. So you might try it, then check the clipboard contents. But just look at the configuration. Or at least, be careful where you hold your thumb when using the MATLAB editor. :)

Iniciar sesión para comentar.

Respuestas (1)

Nihal
Nihal el 2 de En. de 2024
Hi Ari,
It appears that you've encountered a rather unusual behavior in MATLAB's live editor. The mouse buttons 4 and 5 are typically associated with 'Back' and 'Forward' navigation actions in many applications, but they should not be causing the live editor to clear your code.
This is not standard behavior for MATLAB, and there doesn't seem to be a documented feature or shortcut that would cause the live editor to clear its contents when pressing mouse buttons 4 and 5 simultaneously. There is possiblity of an unintended interaction with another application or utility on your system, or a custom key binding that was somehow set up.
Here are a few ways you could take to troubleshoot this issue:
  • Custom Shortcuts: Check if there are any custom shortcuts set up in MATLAB that might be linked to mouse buttons 4 and 5. You can do this by going to the MATLAB preferences and reviewing the Keyboard Shortcuts settings.
  • External Software: Consider whether you have any mouse or keyboard management software that could be mapping those mouse buttons to a shortcut or macro that affects MATLAB.
Unfortunately, without being able to replicate the issue consistently, it's difficult to pinpoint the exact cause. However, the steps above should help you start investigating the problem. I hope this information helps you.

Categorías

Más información sobre Environment and Settings en Help Center y File Exchange.

Productos


Versión

R2021b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by