diff --git a/CHANGELOG.md b/CHANGELOG.md index 38d2a395..92612adb 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -30,6 +30,7 @@ * Update PGO build instructions in `INSTALL.md` (https://codeberg.org/dnkl/foot/issues/418). +* In scrollback search mode, empty cells can now be matched by spaces. ### Deprecated diff --git a/search.c b/search.c index 30a50ae5..02cea9e0 100644 --- a/search.c +++ b/search.c @@ -241,6 +241,9 @@ matches_cell(const struct terminal *term, const struct cell *cell, size_t search base = composed->base; } + if (composed == NULL && base == 0 && term->search.buf[search_ofs] == L' ') + return 1; + if (wcsncasecmp(&base, &term->search.buf[search_ofs], 1) != 0) return -1;