Thursday, July 30, 2009

Color of command line in Linux.?

How can I chane the color of the output of my C program on monitor in linux? such as using printf() function.

Color of command line in Linux.?
printf("%c[1;31mHello\n",27); /* Prints "Hello\n" in RED (ANSI) */





try this...I got it...even command line in Linux will change in to red color

gardenia

No comments:

Post a Comment