Hmm, you should be able to use ansi-colors, ie. escape sequences to get colors.
I haven't tried this in win/dos for years, but in linux you can do this (it should work under win as well) :
printf("%c[34mBlue!!%c[37m\n", 27, 27);
(27 is the ASCII-code for <escape>)
This prints the text "Blue!!" with blue foreground.
The 37 resets the foreground to white afterwards since a change like this is done for ever, until one changes the color back. Try it out =)
Here is a link to a site where you can find out a lot of weird stuff one can do with escape sequences and a color of all color values (note that setting black fg on black bg is _not_ a lot of fun )
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.