~ghost08/tcell-term

tcell-term: csi: use osc 1 and 2 instead of L and l for title v1 PROPOSED

Tim Culverhouse: 1
 csi: use osc 1 and 2 instead of L and l for title

 1 files changed, 2 insertions(+), 2 deletions(-)
Export patchset (mbox)
How do I use this?

Copy & paste the following snippet into your terminal to import this patchset into git:

curl -s https://lists.sr.ht/~ghost08/tcell-term/patches/35203/mbox | git am -3
Learn more about email & git

[PATCH tcell-term] csi: use osc 1 and 2 instead of L and l for title Export this patch

Functions the same, and some terminals don't support L and l for osc
control sequences

Signed-off-by: Tim Culverhouse <tim@timculverhouse.com>
---
 termutil/csi.go | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/termutil/csi.go b/termutil/csi.go
index 8f4888367b2d..81513e2401a1 100644
--- a/termutil/csi.go
+++ b/termutil/csi.go
@@ -284,9 +284,9 @@ func (t *Terminal) csiWindowManipulation(params []string) (renderRequired bool)
			w, h := t.windowManipulator.ScreenSizeInChars()
			t.WriteToPty([]byte(fmt.Sprintf("\x1b[9;%d;%dt", h, w)))
		case "20":
			t.WriteToPty([]byte(fmt.Sprintf("\x1b]L%s\x1b\\", t.windowManipulator.GetTitle())))
			t.WriteToPty([]byte(fmt.Sprintf("\x1b]1%s\x1b\\", t.windowManipulator.GetTitle())))
		case "21":
			t.WriteToPty([]byte(fmt.Sprintf("\x1b]l%s\x1b\\", t.windowManipulator.GetTitle())))
			t.WriteToPty([]byte(fmt.Sprintf("\x1b]2%s\x1b\\", t.windowManipulator.GetTitle())))
		case "22":
			if i < len(params)-1 {
				i++
-- 
2.37.3