OK, I had a look at the ios::flags in Visual Studio, and none of them specify how to set the color.
My first guess, (and this assumes you're on a IBM-compatible PC), is to reopen the stdio stream as a byte stream, and send the color attributes along with the text. There isn't any info in the MSDN what the color attributes are (they've removed all the old DOS reference info long ago), so you'll have to find an old DOS programming reference book (sorry, I don't have one any more). But, IIRC, it used the lowest 3 bits as foreground color, next highest 3 bits as background color, next 2 bits as blinking/underline codes.
Or, if this is a Windows program, you can call the Win32 GDI function called TextOut along with the SetTextColor function.
Or, if you're using MFC, call the ::SetTextColor of a CDC object, then call it's :

rawText method.
Chip H.