User guide / Key bindings

Structural syntax

Development reference · View source

KeyAction
Space x e / Space x sExpand / shrink syntax selection
Space x p / Space x cSelect syntax parent / first child
Space x h / Space x lSelect previous / next syntax sibling
Space x oOpen the immediate Tree-sitter document outline
Space x xToggle the syntax fold at the cursor
Space x f / Space x uFold / unfold all syntax regions in this pane
Space x [ f/c/pGo to the previous function / class / parameter
Space x ] f/c/pGo to the next function / class / parameter
  • Bounds. Expansion keeps Tree-sitter’s half-open bounds. Relationship commands and the syntax text objects show them with the block cursor on the last included character, as in Select mode. Yank, delete, change, and indent act on exactly the highlighted span.
  • Folds are per pane. Two panes may collapse different regions of one shared buffer. Any edit clears both panes’ folds.
  • Folded rows show an accent-coloured ▸ between the line number and the gutter rule, and a muted … N lines suffix counting the hidden rows.
  • While parsing. Space x commands and mm are dimmed until the syntax tree is ready; see Syntax highlighting .