Clearing Scala Output Worksheet

Each time you save a Scala worksheet to the Scala IDE, the output of each expression is printed as comments on the right side of the editor. Is there a way to clear this output from a Scala worksheet so you can cut and paste code?

My current solution is to save my desktop with an error so that the output disappears. There must be a better way ... keyboard shortcut or something like that.

+7
source share
5 answers

There is no such opportunity yet. There is a linked ticket: The format action should block comments.

+4
source

Expecting that the ticket will be allowed, this regular expression can be used in Find / Replace (Ctrl / Cmd + F) to remove comments.

*//[>|].*$ 

Update: This has been fixed: # 132

+4
source

He refuels, but does his job.

  • Make a little editing (for example, remove the space where it doesn't matter) to trigger a save.
  • Save.
  • Press Esc immediately to complete the workflow.

Now you have a blank sheet!

+2
source

Ctrl + Shift + C does the job in Scala IDE 4.7.0

+2
source

Alt + Shift + A allows block selection mode . You can only select the left side of the screen (columns with code). Lock mode also allows only output columns to be selected.

More about block selection mode

+1
source

All Articles