A C/C++ library for colored console output using ANSI/VT100 Escape sequences or the Windows API
Run make
on Linux or using MinGW or nmake -f Makefile.win
when using Visual C++
Just copy console.c
, console.h
and optionally console.hpp
to your project and include them into your build system
#include <stdio.h>
#include "console.h"
int main() {
clear(); // clear screen
setcolor(LIME); // set foreground color to light green
printf("Hello world"); // print text using stdio.h
return 0;
}
See demo.c and demo2.cpp for more examples
This project is licensed under the MIT License - see the LICENSE file for details