Origami

Docs › Workspaces

Editor

Where a file opened in the Explorer is read and changed, with VS Code's keys.

Where Titlebar › Explorer 1 min read

How it works

  1. ⌘D adds the next occurrence of the selection, or of the word at the cursor, as another cursor. ⇧⌘L takes every occurrence, ⌥⌘↑ and ⌥⌘↓ add a cursor above or below, and ⌥-click adds one where you click. Esc goes back to one cursor.
  2. ⌥↑ and ⌥↓ move a line, ⇧⌥↑ and ⇧⌥↓ copy it, ⇧⌘K deletes it and ⌘/ comments it out.
  3. ⌘F finds in the file and ⌥⌘F finds and replaces, with Match Case, Whole Word and Regex. ⌃G goes to a line, or to line:column.
  4. ⌥⌘[ and ⌥⌘] fold and unfold, ⌥Z turns word wrap on or off, and ⌃Space completes a word.
  5. The status line at the bottom right shows the cursor's line and column, the language, the indentation and the line endings. Press the position to go to a line, or one of the others to change it for this file while it is open.

Good to know

  • Settings › Editor sets what saving does, indentation, word wrap, whitespace, font size, closing brackets, word completion, and the files hidden from the Explorer and search.
  • A repository's .editorconfig goes over those settings for indentation, line endings, the final newline and trailing whitespace.
  • While a file has the keyboard, ⌘D and ⌘⏎ are the editor's, not Sidetrack's or the tab's. The shortcuts dialog lists every key under Editor.

Related