tview icon indicating copy to clipboard operation
tview copied to clipboard

ANSI Escape Sequences

Open mgale opened this issue 5 months ago • 1 comments

Hello,

After reading the below issues with looks like the handling of ansi escape control sequences is not currently supported, can you confirm if that is the case still?

https://github.com/rivo/tview/issues/24 https://github.com/rivo/tview/issues/568 https://github.com/rivo/tview/issues/746

Do you think the following approach could work?

I have an incoming bytes stream that I was writing directly to a textview but instead I can try:

  1. Reading the bytes stream into a parser first
  2. If I detect an escape control sequence, for example clearing the screen I can execute the appropriate tview change.
  3. If I do not detect an escape control sequence write the bytes to the textview.

Thanks

mgale avatar Sep 06 '24 21:09 mgale