feat: switch text to UTF-8; add Unicode key events, dead keys & Czech layout; fix numpad navigation; add NumLock support
This commit is contained in:
1 parent
32660ddd1a
commit
2aa6360b3d
101 files changed
+3733
-1639
No files matched your search
@@ -324,6 +324,8 @@ namespace Sched {
|
||||
processTable[i].inTail = 0;
|
||||
processTable[i].keyHead = 0;
|
||||
processTable[i].keyTail = 0;
|
||||
processTable[i].getcharUtf8Len = 0;
|
||||
processTable[i].getcharUtf8Pos = 0;
|
||||
processTable[i].termCols = 0;
|
||||
processTable[i].termRows = 0;
|
||||
processTable[i].ioOutHandle = -1;
|
||||
@@ -654,6 +656,8 @@ namespace Sched {
|
||||
proc.inTail = 0;
|
||||
proc.keyHead = 0;
|
||||
proc.keyTail = 0;
|
||||
proc.getcharUtf8Len = 0;
|
||||
proc.getcharUtf8Pos = 0;
|
||||
proc.termCols = 0;
|
||||
proc.termRows = 0;
|
||||
proc.ioOutHandle = -1;
|
||||
@@ -835,6 +839,7 @@ namespace Sched {
|
||||
thr.outBuf = nullptr; thr.outHead = 0; thr.outTail = 0;
|
||||
thr.inBuf = nullptr; thr.inHead = 0; thr.inTail = 0;
|
||||
thr.keyHead = 0; thr.keyTail = 0;
|
||||
thr.getcharUtf8Len = 0; thr.getcharUtf8Pos = 0;
|
||||
thr.termCols = 0; thr.termRows = 0;
|
||||
thr.ioOutHandle = -1; thr.ioInHandle = -1;
|
||||
thr.ioKeyHandle = -1; thr.ioWaitsetHandle = -1;
|
||||
@@ -1700,6 +1705,8 @@ namespace Sched {
|
||||
proc.inTail = 0;
|
||||
proc.keyHead = 0;
|
||||
proc.keyTail = 0;
|
||||
proc.getcharUtf8Len = 0;
|
||||
proc.getcharUtf8Pos = 0;
|
||||
proc.termCols = 0;
|
||||
proc.termRows = 0;
|
||||
proc.ioOutHandle = -1;
|
||||
|
||||
@@ -135,9 +135,13 @@ namespace Sched {
|
||||
uint8_t* inBuf = nullptr; // 4KB ring: parent writes, child reads (getchar)
|
||||
volatile uint32_t inHead = 0;
|
||||
volatile uint32_t inTail = 0;
|
||||
montauk::abi::KeyEvent keyBuf[64]; // parent injects, child reads (getkey/iskeyavailable)
|
||||
volatile uint32_t keyHead = 0;
|
||||
volatile uint32_t keyTail = 0;
|
||||
// SYS_GETCHAR returns a key's UTF-8 encoding one byte per call; the
|
||||
// bytes not handed out yet wait here.
|
||||
uint8_t getcharUtf8[4] = {};
|
||||
uint8_t getcharUtf8Len = 0;
|
||||
uint8_t getcharUtf8Pos = 0;
|
||||
static constexpr uint32_t IoBufSize = 4096;
|
||||
|
||||
// GUI terminal dimensions (set by desktop, read by SYS_TERMSIZE)
|
||||
|
||||
Reference in new issue
Block a user