There are various keyboard commands for editing text, and the Expression Editor has buttons for clearing and restoring the entire text of an expression.
Undoing back to an expression’s previous contents
The Edit button compiles an expression. If you’ve made an editing change and haven’t yet clicked the Edit button, you can click the Reload button to retrieve the previous expression. This restores the expression to the contents last present when you clicked the Create or Edit button.