mirror of
https://github.com/ArthurSonzogni/FTXUI.git
synced 2025-09-28 16:29:34 +08:00
Add UTF8 support and a better xterm parsing.
This fixes: https://github.com/ArthurSonzogni/FTXUI/issues/2
This commit is contained in:
@@ -73,10 +73,8 @@ bool Input::OnEvent(Event event) {
|
||||
}
|
||||
|
||||
// Content
|
||||
constexpr char ESC = char(27);
|
||||
if (event.values[0] != ESC) {
|
||||
wchar_t v = (char)event.values[0];
|
||||
content.insert(cursor_position, 1, v);
|
||||
if (event.is_character()) {
|
||||
content.insert(cursor_position, 1, event.character());
|
||||
cursor_position++;
|
||||
return true;
|
||||
}
|
||||
|
Reference in New Issue
Block a user