passthrough unmatched keys

This commit is contained in:
2026-05-28 23:38:23 +09:00
parent 795353609b
commit 7e69827c13
3 changed files with 6 additions and 9 deletions

View File

@@ -185,10 +185,8 @@ transmap(Im *im, Rune c)
e.s = im->pre;
sclear(&key);
sputr(&key, c);
if(!maplookup(t, &key, &e.dict)){
sputr(&e.s, c);
if(!maplookup(t, &key, &e.dict))
return e;
}
e.eat = 1;
sputr(&e.next, c);
return e;
@@ -273,14 +271,16 @@ keystroke(u32int ks, u32int mod, Str *com)
return 1;
}
if(ks > 0x7f || ks == ' '){
if(im.pre.n == 0)
return 0;
commit(com);
sputr(com, ks);
reset();
return 1;
}
dotrans(ks, com);
n = dotrans(ks, com);
show();
return 1;
return n;
}
static void