From 998184e2880c64624c9f2df2d6d276cd6c7677fc Mon Sep 17 00:00:00 2001 From: Bananymous Date: Wed, 7 Dec 2022 04:35:02 +0200 Subject: [PATCH] Kernel: TTY now handles '\b' --- kernel/arch/i386/tty.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/kernel/arch/i386/tty.cpp b/kernel/arch/i386/tty.cpp index 2b02d748b1..87c7addd94 100644 --- a/kernel/arch/i386/tty.cpp +++ b/kernel/arch/i386/tty.cpp @@ -101,6 +101,12 @@ void terminal_putchar(char c) terminal_col = 0; terminal_row++; } + else if (c == '\b') + { + if (terminal_col > 0) + terminal_col--; + terminal_putentryat(' ', terminal_color, terminal_col, terminal_row); + } else { terminal_putentryat(c, terminal_color, terminal_col, terminal_row);