Enable project search on type by default (#62506)

Closes https://github.com/zed-industries/zed/issues/9318

Most of the diff is tests.

Notable behavior changes during this mode, compared to current mode:

* unsaved changes in multi buffer won't spawn any "save or not" pop-ups
during typing — submitting the query still does it, as before.
Unsaved files will stay so after being sorted out on typing: we cannot
save them by default as file-less buffers need a save modal; Zed should
already be able to persist and restore such changes on restart.

* gutter may jump during search, if new excerpts with large line numbers
appear during query input — yet it would not shrink back to avoid
excessive flickering and rewraps

Release Notes:

- Enabled project search on type by default (use `{ "search": {
"search_on_type": false } }` to restore the previous behavior)
This commit is contained in:
Kirill Bulatov
2026-08-26 14:33:03 +00:00
committed by GitHub
parent 4ccbcabfee
commit 1475887faf
21 changed files with 4459 additions and 212 deletions
+1 -1
View File
@@ -3131,7 +3131,7 @@ impl MultiBuffer {
}
}
fn build_excerpt_ranges(
pub fn build_excerpt_ranges(
ranges: impl IntoIterator<Item = Range<Point>>,
context_line_count: u32,
buffer_snapshot: &BufferSnapshot,