3 ms·
If you represent Unicode codepoints as unsigned 32-bit integers, you have the eleven high bits free for representing modifier keys. You can even represent chang
by cjs_ac 3y ago
If you represent Unicode codepoints as unsigned 32-bit integers, you have the eleven high bits free for representing modifier keys. You can even represent changes of state for the modifier keys without a normal key press by sending the modifier bits with a NUL character.