How to handle ansi escape codes in C?
I'm writing terminal program in C with ncurses, and I have no idea how to handle ansi escape codes like "ESC[;4;5m",does ncurses provide some routine to handle this, or is there any lib can help?
And is there any stuff explains ansi escape codes ?
man ascii would be a start
You could define some color escape strings like:
Wait, curses has already colors macro defined, try:
But how to handle it?
For example, I read a string like "\033[;1;31mHello World\033[0m"
Or vim's escape codes:
|All times are GMT -5. The time now is 10:18 AM.|