2d266b54a8
Replaced hardcoded US scancode→escape-sequence table in fbcond's text.rs with a configurable Keymap struct supporting TOML-based keyboard layouts. Five layouts embedded at compile time: - us.toml — US English (QWERTY), default - ru.toml — Russian JCUKEN, #1 non-English locale throughout Red Bear OS - uk.toml — UK English (QWERTY) - de.toml — German (QWERTZ) - fr.toml — French (AZERTY) Implementation: - src/keymap.rs: Keymap struct with TOML deserialization, scancode→byte sequence lookup, embedded defaults via include_str!(). 6 unit tests. - src/text.rs: TextScreen gains field. Hardcoded 12-arm scancode match replaced with call. Same Ctrl+letter translation fallback preserved. - keymaps/*.toml: Five embedded layout files. - Cargo.toml: added toml.workspace dependency. - main.rs: registered mod keymap. Keymap priority policy: English (US) default, Russian #1 non-English, then UK/DE/FR. Unknown names fall back to US.
30 lines
638 B
TOML
30 lines
638 B
TOML
[package]
|
|
name = "fbcond"
|
|
description = "Terminal daemon"
|
|
version = "0.1.0"
|
|
edition = "2021"
|
|
|
|
[dependencies]
|
|
drm.workspace = true
|
|
log.workspace = true
|
|
orbclient.workspace = true
|
|
ransid.workspace = true
|
|
redox_event.workspace = true
|
|
redox_syscall.workspace = true
|
|
redox-scheme.workspace = true
|
|
scheme-utils = { path = "../../../scheme-utils" }
|
|
toml.workspace = true
|
|
|
|
common = { path = "../../common" }
|
|
console-draw = { path = "../console-draw" }
|
|
daemon = { path = "../../../daemon" }
|
|
graphics-ipc = { path = "../graphics-ipc" }
|
|
inputd = { path = "../../inputd" }
|
|
libredox.workspace = true
|
|
|
|
[features]
|
|
default = []
|
|
|
|
[lints]
|
|
workspace = true
|