mirror of
https://github.com/neovim/neovim
synced 2025-07-15 16:51:49 +00:00
fix(incsearch): include compsing characters with Ctrl-L
Cherry-picked from Vim patch 8.1.0579.
(cherry picked from commit f348c0ebba
)
This commit is contained in:
committed by
github-actions[bot]
parent
d1214da08f
commit
282f9fb816
@ -608,6 +608,16 @@ static int may_add_char_to_search(int firstc, int *c, incsearch_state_T *s)
|
||||
stuffcharReadbuff(*c);
|
||||
*c = '\\';
|
||||
}
|
||||
// add any composing characters
|
||||
if (utf_char2len(*c) != utfc_ptr2len(get_cursor_pos_ptr())) {
|
||||
const int save_c = *c;
|
||||
while (utf_char2len(*c) != utfc_ptr2len(get_cursor_pos_ptr())) {
|
||||
curwin->w_cursor.col += utf_char2len(*c);
|
||||
*c = gchar_cursor();
|
||||
stuffcharReadbuff(*c);
|
||||
}
|
||||
*c = save_c;
|
||||
}
|
||||
return FAIL;
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user