2012-01-26 02:12:56 +04:00
|
|
|
/*
|
|
|
|
* echo-test
|
|
|
|
*
|
2012-07-07 08:08:28 +04:00
|
|
|
* Prints a test string to standard out
|
|
|
|
* that includes various bits of ANSI
|
|
|
|
* escape sequences.
|
2012-01-26 02:12:56 +04:00
|
|
|
*/
|
|
|
|
#include <stdio.h>
|
|
|
|
|
|
|
|
int main(int argc, char ** argv) {
|
|
|
|
|
|
|
|
printf("\n\033[1mBold \033[0m\033[3mItalic \033[1mBold+Italic\033[0m\033[0m \033[4mUnderline\033[0m \033[9mX-Out\033[0m \033[1;3;4;9mEverything\033[0m\n");
|
|
|
|
|
2013-03-28 04:42:47 +04:00
|
|
|
printf("\033[38;2;178;213;238mHello World\033[0m\n");
|
|
|
|
|
|
|
|
for (int i = 0; i < 256; i += 3) {
|
2013-03-29 11:34:12 +04:00
|
|
|
printf("\033[48;6;255;0;0;%dmX\033[0m", i);
|
2013-03-28 04:42:47 +04:00
|
|
|
}
|
|
|
|
printf("\n");
|
|
|
|
|
2013-03-29 11:39:23 +04:00
|
|
|
for (int i = 0; i < 256; i += 3) {
|
|
|
|
printf("\033[48;6;255;0;0;0;m\033[38;6;255;0;0;%dmX\033[0m", i);
|
|
|
|
}
|
|
|
|
printf("\n");
|
|
|
|
|
2012-01-26 02:12:56 +04:00
|
|
|
return 0;
|
|
|
|
}
|
|
|
|
|
|
|
|
/*
|
|
|
|
* vim:tabstop=4
|
|
|
|
* vim:noexpandtab
|
|
|
|
* vim:shiftwidth=4
|
|
|
|
*/
|