delta-client icon indicating copy to clipboard operation
delta-client copied to clipboard

Add ANSI styling to chat and disconnect messages when logged to terminal

Open stackotter opened this issue 3 years ago • 3 comments

It's pretty self explanatory, currently chat and disconnect messages are just printed out plain (and disconnect messages don't even have the legacy formatting codes removed).

stackotter avatar May 30 '22 00:05 stackotter

Would we just need to modify ChatComponentColor to provide ANSI escape sequences for each enumeration, and then use tokens.map(\.color.rawValue + \.string).joined() in LegacyFormattedText#toString?

nekename avatar Dec 21 '22 16:12 nekename

Yeah essentially, although don’t make the rawValue ansi, just give the colour enum an ansiValue property (cause we might need more ‘raw’ values in future too)

stackotter avatar Dec 23 '22 22:12 stackotter

Alright, I'll do this one.

nekename avatar Dec 24 '22 04:12 nekename