Match tab cells when searching, from Alexander Arch in GitHub issue

4201.
This commit is contained in:
nicm 2024-10-28 08:16:51 +00:00
parent 62e15e905b
commit c8bd42de16

View File

@ -3082,6 +3082,9 @@ window_copy_search_compare(struct grid *gd, u_int px, u_int py,
grid_get_cell(sgd, spx, 0, &sgc); grid_get_cell(sgd, spx, 0, &sgc);
sud = &sgc.data; sud = &sgc.data;
if (*sud->data == '\t' && sud->size == 1 && gc.flags & GRID_FLAG_TAB)
return (1);
if (ud->size != sud->size || ud->width != sud->width) if (ud->size != sud->size || ud->width != sud->width)
return (0); return (0);