kitty: report-alternate: apply base-layout key to composed characters

This commit is contained in:
Daniel Eklöf 2021-12-07 21:48:42 +01:00
parent 9b57ef07f1
commit c0cfec89e0
No known key found for this signature in database
GPG key ID: 5BBD4992C116573F

View file

@ -1437,11 +1437,14 @@ emit_escapes:
if (key == 0) if (key == 0)
key = sym_to_use; key = sym_to_use;
if (report_alternate)
alternate = xkb_keysym_to_utf32(sym);
}
if (report_alternate) { if (report_alternate) {
/* The *shifted* key. May be the same as the unshifted /* The *shifted* key. May be the same as the unshifted
* key - if so, this is filtered out below, when * key - if so, this is filtered out below, when
* emitting the CSI */ * emitting the CSI */
alternate = xkb_keysym_to_utf32(sym);
/* Base layout key. I.e the symbol the pressed key /* Base layout key. I.e the symbol the pressed key
* produces in the base/default layout (layout idx * produces in the base/default layout (layout idx
@ -1453,7 +1456,6 @@ emit_escapes:
if (base_sym_count > 0) if (base_sym_count > 0)
base = xkb_keysym_to_utf32(base_syms[0]); base = xkb_keysym_to_utf32(base_syms[0]);
} }
}
final = 'u'; final = 'u';
break; break;