Raxol.Terminal.ControlCodes (Raxol v2.0.1)

View Source

Handles C0 control codes and simple ESC sequences.

Extracted from Terminal.Emulator for better organization. Relies on Emulator state and ScreenBuffer for actions.

Summary

Functions

Handles bell control code.

Handle Backspace (BS)

Handles a C0 control code (0-31) or DEL (127). Delegates to specific handlers based on the codepoint.

Handle Carriage Return (CR)

Handles simple escape sequences (ESC followed by a single byte).

Handles the Horizontal Tab (HT) action.

Handle Line Feed (LF), New Line (NL), Vertical Tab (VT)

Handle Locking Shift 1 Right (LS1R) - ESC ~ Invokes G1 character set into GR

Handle Locking Shift 2 (LS2) - ESC n Invokes G2 character set into GL

Handle Locking Shift 2 Right (LS2R) - ESC } Invokes G2 character set into GR

Handle Locking Shift 3 (LS3) - ESC o Invokes G3 character set into GL

Handle Locking Shift 3 Right (LS3R) - ESC | Invokes G3 character set into GR

Handle Reverse Index (RI) - ESC M

Handles substitute character control code.

Functions

handle_bel(emulator)

Handles bell control code.

handle_bs(emulator)

Handle Backspace (BS)

handle_c0(emulator, char_codepoint)

Handles a C0 control code (0-31) or DEL (127). Delegates to specific handlers based on the codepoint.

handle_can(emulator)

handle_cr(emulator)

Handle Carriage Return (CR)

handle_decrc(emulator)

handle_decsc(emulator)

handle_escape(emulator, byte)

Handles simple escape sequences (ESC followed by a single byte).

handle_ht(emulator)

Handles the Horizontal Tab (HT) action.

handle_hts(emulator)

handle_ind(emulator)

handle_lf(emulator)

Handle Line Feed (LF), New Line (NL), Vertical Tab (VT)

handle_ls1r(emulator)

Handle Locking Shift 1 Right (LS1R) - ESC ~ Invokes G1 character set into GR

handle_ls2(emulator)

Handle Locking Shift 2 (LS2) - ESC n Invokes G2 character set into GL

handle_ls2r(emulator)

Handle Locking Shift 2 Right (LS2R) - ESC } Invokes G2 character set into GR

handle_ls3(emulator)

Handle Locking Shift 3 (LS3) - ESC o Invokes G3 character set into GL

handle_ls3r(emulator)

Handle Locking Shift 3 Right (LS3R) - ESC | Invokes G3 character set into GR

handle_nel(emulator)

handle_ri(emulator)

Handle Reverse Index (RI) - ESC M

handle_ris(emulator)

handle_si(emulator)

handle_so(emulator)

handle_sub(emulator)

Handles substitute character control code.