From 128c263fa97b804b80972867ae173cc1170408eb Mon Sep 17 00:00:00 2001 From: Mitchell Hashimoto Date: Wed, 17 Jan 2024 08:00:11 -0800 Subject: [PATCH] readme: remove outdated sequences docs, more up to date are in web --- README.md | 18 +++++++++--------- docs/sequences.md | 44 ------------------------------------------- docs/sequences/bel.md | 24 ----------------------- docs/sequences/bs.md | 19 ------------------- docs/sequences/can.md | 10 ---------- docs/sequences/cr.md | 13 ------------- docs/sequences/enq.md | 29 ---------------------------- docs/sequences/ff.md | 8 -------- docs/sequences/hts.md | 8 -------- docs/sequences/ind.md | 19 ------------------- docs/sequences/lf.md | 12 ------------ docs/sequences/nel.md | 8 -------- docs/sequences/ri.md | 21 --------------------- docs/sequences/tab.md | 21 --------------------- docs/sequences/vt.md | 8 -------- 15 files changed, 9 insertions(+), 253 deletions(-) delete mode 100644 docs/sequences.md delete mode 100644 docs/sequences/bel.md delete mode 100644 docs/sequences/bs.md delete mode 100644 docs/sequences/can.md delete mode 100644 docs/sequences/cr.md delete mode 100644 docs/sequences/enq.md delete mode 100644 docs/sequences/ff.md delete mode 100644 docs/sequences/hts.md delete mode 100644 docs/sequences/ind.md delete mode 100644 docs/sequences/lf.md delete mode 100644 docs/sequences/nel.md delete mode 100644 docs/sequences/ri.md delete mode 100644 docs/sequences/tab.md delete mode 100644 docs/sequences/vt.md diff --git a/README.md b/README.md index 4aa78d10b..3cb7cd523 100644 --- a/README.md +++ b/README.md @@ -313,15 +313,15 @@ support](https://www.openssh.com/txt/release-8.7) for setting `TERM` via The high-level ambitious plan for the project, in order: -| # | Step | Status | -| :-: | ----------------------------------------------------------- | :----: | -| 1 | [Standards-compliant terminal emulation](docs/sequences.md) | ⚠️ | -| 2 | Competitive performance | ✅ | -| 3 | Basic customizability -- fonts, bg colors, etc. | ✅ | -| 4 | Richer windowing features -- multi-window, tabbing, panes | ✅ | -| 5 | Native Platform Experiences (i.e. Mac Preference Panel) | ⚠️ | -| 6 | Windows Terminals (including PowerShell, Cmd, WSL) | ❌ | -| N | Fancy features (to be expanded upon later) | ❌ | +| # | Step | Status | +| :-: | --------------------------------------------------------- | :----: | +| 1 | Standards-compliant terminal emulation | ✅ | +| 2 | Competitive performance | ✅ | +| 3 | Basic customizability -- fonts, bg colors, etc. | ✅ | +| 4 | Richer windowing features -- multi-window, tabbing, panes | ✅ | +| 5 | Native Platform Experiences (i.e. Mac Preference Panel) | ⚠️ | +| 6 | Windows Terminals (including PowerShell, Cmd, WSL) | ❌ | +| N | Fancy features (to be expanded upon later) | ❌ | Additional details for each step in the big roadmap below: diff --git a/docs/sequences.md b/docs/sequences.md deleted file mode 100644 index 8cdf91ac5..000000000 --- a/docs/sequences.md +++ /dev/null @@ -1,44 +0,0 @@ -# Control and Escape Sequences - -⚠️ **This is super out of date. Ghostty's support is much better -than this document seems. TODO to update this.** ⚠️ - -This is the list of control and escape sequences known in the ecosystem -of terminal emulators and their implementation status in ghostty. Note that -some control sequences may never be implemented in ghostty. In these scenarios, -it is noted why. - -Status meanings: - -- ✅ - Implementation is complete and considered 100% accurate. -- ⚠️ - Implementation works, but may be missing some functionality. The - details of how well it works or doesn't are in the linked page. In many - cases, the missing functionality is very specific or esoteric. Regardless, - we don't consider a sequence a green checkmark until all known feature - interactions are complete. -- ❌ - Implementation is effectively non-functional, but ghostty continues - in the face of it (probably in some broken state). -- 💥 - Ghostty crashes if this control sequence is sent. - -| ID | ASCII | Name | Status | -| :---: | :-----: | :----------------------------------------- | :----: | -| `ENQ` | `0x05` | [Enquiry](sequences/enq.md) | ✅ | -| `BEL` | `0x07` | [Bell](sequences/bel.md) | ❌ | -| `BS` | `0x08` | [Backspace](sequences/bs.md) | ⚠️ | -| `TAB` | `0x09` | [Tab](sequences/tab.md) | ⚠️ | -| `LF` | `0x0A` | [Linefeed](sequences/lf.md) | ⚠️ | -| `VT` | `0x0B` | [Vertical Tab](sequences/vt.md) | ✅ | -| `FF` | `0x0C` | [Form Feed](sequences/ff.md) | ✅ | -| `CR` | `0x0D` | [Carriage Return](sequences/cr.md) | ⚠️ | -| `SO` | `0x0E` | [Shift Out](#) | ❌ | -| `SI` | `0x0F` | [Shift In](#) | ❌ | -| `CAN` | `0x18` | [Cancel Parsing](sequences/can.md) | ✅ | -| `SUB` | `0x1A` | [Cancel Parsing (Alias)](sequences/can.md) | ✅ | -| `IND` | `ESC D` | [Index](sequences/ind.md) | ✅ | -| `NEL` | `ESC E` | [Next Line](sequences/nel.md) | ✅ | -| `HTS` | `ESC H` | [Horizontal Tab Set](sequences/hts.md) | ✅ | -| `RI` | `ESC M` | [Reverse Index](sequences/ri.md) | ⚠️ | -| `SS2` | `ESC N` | [Single Shift 2](#) | ❌ | -| `SS3` | `ESC O` | [Single Shift 3](#) | ❌ | -| `SPA` | `ESC V` | [Start Protected Area](#) | ❌ | -| `EPA` | `ESC W` | [End Protected Area](#) | ❌ | diff --git a/docs/sequences/bel.md b/docs/sequences/bel.md deleted file mode 100644 index 3ee7a4445..000000000 --- a/docs/sequences/bel.md +++ /dev/null @@ -1,24 +0,0 @@ -# Bell - -| | | -| ---- | ------ | -| Text | | -| Hex | `0x07` | - -Rings a "bell" to alert the operator to some condition. - -## Implementation Details - -- ghostty logs "BELL" - -## TODO - -- Add a configurable visual bell -- common in most terminal emulators -- - to flash the border. -- Mark the window as requesting attention, most operating systems support - this. For example, Windows windows will flash in the toolbar. -- Support an audible bell. - -## References - -- https://vt100.net/docs/vt100-ug/chapter3.html diff --git a/docs/sequences/bs.md b/docs/sequences/bs.md deleted file mode 100644 index 80835947e..000000000 --- a/docs/sequences/bs.md +++ /dev/null @@ -1,19 +0,0 @@ -# Backspace - -| | | -| ---- | ------ | -| Text | | -| Hex | `0x08` | - -Move the cursor left one cell. - -TODO: Details about how this interacts with soft wrapping. - -## Implementation Details - -- ghostty implements this naively as `cursor.x -|= 1` (`-|=` being a - saturating subtraction). - -## TODO - -- Soft wrap integration diff --git a/docs/sequences/can.md b/docs/sequences/can.md deleted file mode 100644 index d2f5236ba..000000000 --- a/docs/sequences/can.md +++ /dev/null @@ -1,10 +0,0 @@ -# Cancel Parsing - -| | | -| ---- | ---------------- | -| Text | | -| Hex | `0x18` or `0x1A` | - -Cancels sequence parsing. Any partially completed sequence such as `ESC` -can send `0x18` and revert back to an unparsed state. The sequence characters -up to that point are discarded. diff --git a/docs/sequences/cr.md b/docs/sequences/cr.md deleted file mode 100644 index e5ba913b7..000000000 --- a/docs/sequences/cr.md +++ /dev/null @@ -1,13 +0,0 @@ -# Carriage Return - -| | | -| ---- | ------ | -| Text | | -| Hex | `0x0D` | - -Moves the cursor to the left-most column and resets any pending wrap flags. - -## TODO - -- Integration with left/right scrolling margins -- Integration with origin mode diff --git a/docs/sequences/enq.md b/docs/sequences/enq.md deleted file mode 100644 index 3c5969f58..000000000 --- a/docs/sequences/enq.md +++ /dev/null @@ -1,29 +0,0 @@ -# Enquiry (Answerback) - -| | | -| ---- | ------ | -| Text | | -| Hex | `0x05` | - -Sends an answerback string. In the VT100, this was configurable by the -operator. - -## Implementation Details - -The answerback can be configured in the config file using the `enquiry-response` -configuration setting or on the command line using the `--enquiry-response` -parameter. The default is to send an empty string (`""`). - -## TODO - -- Implement method for changing the answerback on-the-fly. This could be part of - a larger configuration editor or as a stand-alone method. - -## References - -- https://vt100.net/docs/vt100-ug/chapter3.html -- https://documentation.help/PuTTY/config-answerback.html -- https://invisible-island.net/xterm/ctlseqs/ctlseqs.html#h4-Single-character-functions:ENQ.C29 -- https://invisible-island.net/xterm/manpage/xterm.html#VT100-Widget-Resources:answerbackString -- https://iterm2.com/documentation-preferences-profiles-terminal.html -- https://iterm2.com/documentation-scripting.html diff --git a/docs/sequences/ff.md b/docs/sequences/ff.md deleted file mode 100644 index b8a25048d..000000000 --- a/docs/sequences/ff.md +++ /dev/null @@ -1,8 +0,0 @@ -# Form Feed - -| | | -| ---- | ------ | -| Text | | -| Hex | `0x0C` | - -Equivalent to [linefeed](lf.md). diff --git a/docs/sequences/hts.md b/docs/sequences/hts.md deleted file mode 100644 index 451957a9d..000000000 --- a/docs/sequences/hts.md +++ /dev/null @@ -1,8 +0,0 @@ -# Horizontal Tab Set - -| | | -| ---- | ----------- | -| Text | `ESC H` | -| Hex | `0x18 0x48` | - -Mark the current cursor column as a tab stop. diff --git a/docs/sequences/ind.md b/docs/sequences/ind.md deleted file mode 100644 index dc1b9c077..000000000 --- a/docs/sequences/ind.md +++ /dev/null @@ -1,19 +0,0 @@ -# Index - -| | | -| ---- | ----------- | -| Text | `ESC D` | -| Hex | `0x18 0x44` | - -Move the cursor to the next line in the scrolling region, scrolling -if necessary. This always unsets the pending wrap state. - -If the cursor is currently outside the scrolling region: - -- move the cursor down one line if it is not on bottom line of the screen. - -If the cursor is inside the scrolling region: - -- If the cursor is on the bottom-most line of the screen: invoke - [scroll up](su.md) with the value `1`. -- Else: move the cursor one line down. diff --git a/docs/sequences/lf.md b/docs/sequences/lf.md deleted file mode 100644 index a36472415..000000000 --- a/docs/sequences/lf.md +++ /dev/null @@ -1,12 +0,0 @@ -# Linefeed - -| | | -| ---- | ------ | -| Text | | -| Hex | `0x0A` | - -Invoke [Index](ind.md). - -## TODO - -- Linefeed mode (mode 20) diff --git a/docs/sequences/nel.md b/docs/sequences/nel.md deleted file mode 100644 index 39691789f..000000000 --- a/docs/sequences/nel.md +++ /dev/null @@ -1,8 +0,0 @@ -# Index - -| | | -| ---- | ----------- | -| Text | `ESC E` | -| Hex | `0x18 0x45` | - -Invoke [carriage return](cr.md) and then [index](ind.md). diff --git a/docs/sequences/ri.md b/docs/sequences/ri.md deleted file mode 100644 index 88ba96fe1..000000000 --- a/docs/sequences/ri.md +++ /dev/null @@ -1,21 +0,0 @@ -# Reverse Index - -| | | -| ---- | ----------- | -| Text | `ESC M` | -| Hex | `0x18 0x4D` | - -Reverse [index](ind.md). This unsets the pending wrap state. - -If the cursor is outside of the scrolling region: - -- move the cursor one line up unless it is the top-most line of the screen. - -If the cursor is inside the scrolling region: - -- If the cursor is on the top-most line: invoke [scroll down](#) with value `1` -- Else: move the cursor one line up. - -## TODO - -- Scroll region edge cases diff --git a/docs/sequences/tab.md b/docs/sequences/tab.md deleted file mode 100644 index c186289ee..000000000 --- a/docs/sequences/tab.md +++ /dev/null @@ -1,21 +0,0 @@ -# Tab - -| | | -| ---- | ------ | -| Text | | -| Hex | `0x09` | - -Move the cursor right to the next tab stop. - -A tab stop is a specifically marked column that a cursor stops when a tab -is invoked. Tab stops are typically thought of as uniform spacing (i.e. -four spaces) but in terminals this is not the case: tab stops can be set -at any column number using the [tab set](#) and [tab clear](#) -sequences. - -Initially, tab stops are set on every 8th column. - -## TODO - -- Integration with left/right margins of the scrolling region. -- How does horizontal tab interact with the pending wrap state? diff --git a/docs/sequences/vt.md b/docs/sequences/vt.md deleted file mode 100644 index f721741b3..000000000 --- a/docs/sequences/vt.md +++ /dev/null @@ -1,8 +0,0 @@ -# Vertical Tab - -| | | -| ---- | ------ | -| Text | | -| Hex | `0x0B` | - -Equivalent to [linefeed](lf.md).