render: ime: don’t render pre-edit string in grid while searching

While doing a scrollback search, the pre-edit string should be
rendered in the search box, not in the grid.

Note that we don’t yet support IME in scrollback search mode. This
patch simply prevents the pre-edit text being rendered in the grid,
in the “background”, while searching.
This commit is contained in:
Daniel Eklöf 2020-12-05 11:42:21 +01:00
parent fe6cf547f1
commit 9ce0edc8bb
No known key found for this signature in database
GPG key ID: 5BBD4992C116573F

View file

@ -1029,6 +1029,9 @@ render_ime_preedit(struct terminal *term, struct buffer *buf)
if (likely(term->ime.preedit.cells == NULL))
return;
if (unlikely(term->is_searching))
return;
/* Adjust cursor position to viewport */
struct coord cursor;
cursor = term->grid->cursor.point;