|
C-Menu 0.2.9
A User Interface Toolkit
|
removes ansi escape sequences beginning with "\033["" and ending in "m" or "K" More...
Go to the source code of this file.
Functions | |
| int | main (int argc, char *argv[]) |
removes ansi escape sequences beginning with "\033["" and ending in "m" or "K"
Definition in file stripansi.c.
| int main | ( | int | argc, |
| char * | argv[] ) |
C function - strip_ansi(out_str, in_str)
This function iterates through the input string, copying characters to the output buffer while skipping over any ANSI escape sequences. It looks for sequences that start with "\033[" and end with "m" or "K", and removes them from the output.
| argc | Argument count (should be 2 for the program name and input file) |
| argv | Argument vector (argv[1] should be the input file name) |
ANSI escape sequences start with "\033[" and end with "m" or "K". This function removes those sequences from the input string and writes the cleaned string to stdout
< Buffer to hold the input string read from the file
< Buffer to hold the cleaned output string
Definition at line 24 of file stripansi.c.
References strip_ansi().