ab26a17
Opt into language-aware features when getting buffer chunks
Click to expand commit body
We use chunks a lot to transform points and sync the various display maps,
and always querying tree-sitter or the LSP diagnostics in those cases is
unnecessarily expensive.
Antonio Scandurra
created
bd44172
Cancel innermost snippet insertion when hitting `esc`
Antonio Scandurra
created
426ca94
Allow completions to bleed off the editor's bounds
Antonio Scandurra
created
d246a39
Syntax highlight even when the label doesn't contain a detail
Antonio Scandurra
created
8fc89da
Don't overflow selection index when completions are filtered
Antonio Scandurra
created
439d12c
Start work on syntax highlighting completions
88adddb
Remove theme parameters from buffer/display map's chunks methods
Click to expand commit body
Change Chunks to contain highlight ids instead of actual highlight
styles. Retrieve the actual highlight style from the theme in the
editor element layer.
This is to set us up to perform syntax highlighting in other code
paths where the theme is not available.
497626e
Re-filter existing completions on selection update
Click to expand commit body
We still request new completions, but this ensures results are up-to-date in the meantime.
Also: Cancel any pending completions task when we dismiss the completions dialog or start a new completions request.
Co-Authored-By: Antonio Scandurra <me@as-cii.com>
Nathan Sobo
and
Antonio Scandurra
created
b89a39b
Filter and sort suggestions in autocomplete
Click to expand commit body
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
Antonio Scandurra
and
Nathan Sobo
created
bcbd265
Dismiss autocomplete when moving outside of a word
Antonio Scandurra
created
92f0491
Don't assign completion_state when completions are empty
Nathan Sobo
created
327ddbe
Always issue a new completions request when typing a trigger character
Click to expand commit body
We'll interpolate the anchor range of original request, but it's still a good idea to be up-to-date in case the language server is influenced by the content preceding the location. This doesn't *seem* to be the case with rust-analyzer so far, but it's how VS Code works so let's do it this way.
Nathan Sobo
created
ae0237c
Create anchors with latest snapshot when completions are ready
Click to expand commit body
Using the previous snapshot was panicking.
Nathan Sobo
created
fde03b1
Make the anchor range inclusive on completions
Click to expand commit body
This will help us to correctly interpolate the replacement range when we confirm before receiving new completions after typing with a completion open.
Nathan Sobo
created
1d1f8df
Trigger completion when typing words or trigger characters