engine: the digits type until the candidate list is engaged

Every complete reading shows its candidates, so 1-9 were candidate picks
in the middle of composing: ka then 5 committed 家, and heya then 2
typed a 2 the application never asked for.  They pick only once Space,
Tab, or an arrow has chosen a candidate, as in Mozc; before that they are
ordinary keys.  A search is unchanged: its digits pick from the start.
This commit is contained in:
2026-08-17 12:36:23 +09:00
parent cf8eca2ff1
commit c2aec44aa9
3 changed files with 18 additions and 3 deletions

View File

@@ -812,7 +812,8 @@ transition(u32int ks, u32int mod, Str *com)
movekouho(n);
return 1;
}
n = numberedkouho(ks, mod);
/* Digits pick a candidate only once the list has been engaged. */
n = im.sel >= 0 ? numberedkouho(ks, mod) : -1;
if(n >= 0){
sappend(com, &im.kouho[n]);
reset();