From 73fec79d5ad80d7c24a61fc5e8bff7f6b9d1a717 Mon Sep 17 00:00:00 2001 From: Scott Shawcroft Date: Wed, 16 Jul 2025 14:01:35 -0700 Subject: [PATCH] Tweak Terminal formatting so lists render correctly. Fixes #10473 --- shared-bindings/terminalio/Terminal.c | 35 +++++++++++++++++++-------- 1 file changed, 25 insertions(+), 10 deletions(-) diff --git a/shared-bindings/terminalio/Terminal.c b/shared-bindings/terminalio/Terminal.c index 60d1fe7fdc061..f8394dcc17d52 100644 --- a/shared-bindings/terminalio/Terminal.c +++ b/shared-bindings/terminalio/Terminal.c @@ -24,15 +24,18 @@ //| """Display a character stream with a TileGrid //| //| ASCII control: +//| //| * ``\\r`` - Move cursor to column 1 //| * ``\\n`` - Move cursor down a row //| * ``\\b`` - Move cursor left one if possible //| //| OSC control sequences: +//| //| * ``ESC ] 0; ESC \\`` - Set title bar to //| * ``ESC ] ####; ESC \\`` - Ignored //| //| VT100 control sequences: +//| //| * ``ESC [ K`` - Clear the remainder of the line //| * ``ESC [ 0 K`` - Clear the remainder of the line //| * ``ESC [ 1 K`` - Clear start of the line to cursor @@ -50,16 +53,28 @@ //| * ``ESC [ ## ; ## ; ## m`` - Set the terminal display attributes. //| //| Supported Display attributes: -//| 0 - Reset all attributes -//| Foreground Colors Background Colors -//| 30 - Black 40 - Black -//| 31 - Red 41 - Red -//| 32 - Green 42 - Green -//| 33 - Yellow 43 - Yellow -//| 34 - Blue 44 - Blue -//| 35 - Magenta 45 - Magenta -//| 36 - Cyan 46 - Cyan -//| 37 - White 47 - White +//| +//| +--------+------------+------------+ +//| | Color | Foreground | Background | +//| +========+============+============+ +//| | Reset | 0 | 0 | +//| +--------+------------+------------+ +//| | Black | 30 | 40 | +//| +--------+------------+------------+ +//| | Red | 31 | 41 | +//| +--------+------------+------------+ +//| | Green | 32 | 42 | +//| +--------+------------+------------+ +//| | Yellow | 33 | 43 | +//| +--------+------------+------------+ +//| | Blue | 34 | 44 | +//| +--------+------------+------------+ +//| | Magenta| 35 | 45 | +//| +--------+------------+------------+ +//| | Cyan | 36 | 46 | +//| +--------+------------+------------+ +//| | White | 37 | 47 | +//| +--------+------------+------------+ //| """ //| //| def __init__( pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy