Getting Around a Document
- Where you are
- Going to a line
- The outline
- Bookmarks
- Going back
- Splitting the editor
- Invisible characters
- Languages
Where you are
Two things at the foot of the editor say where the cursor is.
The path bar shows where the cursor is in the document's structure: the elements it is inside in HTML, the rule in a stylesheet, the function in a script. Click a step of the path to see a menu of the items beside it, and choose one to go there. Click the list at the start of the path to open the outline.
The readout shows the line and column of the cursor, and when text is selected, how many characters and lines are selected. Click it to go to a line.
Going to a line
Choose Edit ⟩ Go To… (command L) and type where you want to go:
42goes to line 4242:8goes to line 42, column 842-60selects lines 42 to 60c:1200goes to the 1200th character of the document
The editor shows the place as you type. Press enter to go there, or escape to stay where you were.
The outline
Choose Edit ⟩ Show Outline (control 6), or click the list at the start of the path bar, to see the whole structure of the document: its elements, rules, functions and classes, as the document's language describes them.
Type to filter the outline. Press enter to go to the first match, or press down to move into the list and choose. Click an item to go to it. escape clears the filter, and pressed again closes the outline.
The outline is made from the same understanding of the document as code folding, so a language that has one has the other.
Bookmarks
A bookmark marks a line you want to come back to. It is shown as a dot beside the line number, and Espresso remembers a file's bookmarks between sessions.
The commands are in Edit ⟩ Bookmarks:
- Toggle Bookmark (control command B) adds a bookmark to the line the cursor is on, or removes the one it has. With several lines selected, it marks all of them.
- Next Bookmark (control command N) and Previous Bookmark (control command P) move between the document's bookmarks, going round at the ends
- Remove All Bookmarks
Going back
Espresso keeps track of where you have been. Edit ⟩ Go Back (control -) returns to where the cursor was before you last jumped somewhere else: to another tab, or to a distant part of the same document. Edit ⟩ Go Forward (control shift -) goes the other way. Both follow you from one tab and window to another.
Splitting the editor
Choose View ⟩ Split Editor (control command </kbd>) to see two parts of a document at once, one above the other. Both panes show the same text, so a change in one is a change in the other. Each pane has its own find bar, path bar and readout, and commands go to the pane you last typed or clicked in. Choose the command again to go back to one pane.
Invisible characters
Choose View ⟩ Show Invisible Characters to see spaces, tabs and line endings drawn in the text.
Languages
Espresso works out a document's language from its name, and where that does not settle it, from its contents. To choose a language yourself, use the View ⟩ Language menu. Detect Automatically hands the choice back to Espresso.
Espresso comes with these languages:
- The web: HTML, CSS, JavaScript, TypeScript, JSX, JSON, XML, XSL, SVG, Markdown
- Stylesheet languages: SCSS, Sass, LESS
- Components and templates: Astro, Svelte, Vue, Blade, EJS, ERB, Haml, Jinja, Liquid, Smarty, Twig and Espresso's own Dynamo
- Programming languages: PHP, Python, Ruby, Perl, Go, Rust, Swift, Zig, Java, C, C++, C#, Objective-C, CoffeeScript, SQL, GraphQL, shell scripts
- Configuration: Apache and Nginx configuration, Dockerfile, environment files, INI, TOML, YAML
More can be added with plug-ins.