Is there a way to output text to a file in different colors on Linux?

I am outputting data to a txt file on Linux using C++. Is there a way to output a portion of a line of text in a different color?

For example, I'd like to be able to write 0.000 Watts in red.

Total Power Usage of this model: 0.000 Watts


Plain text files (*.txt) don't support color in any way. You will have to use a different format, such as RTF or HTML.

Need Your Help

test a function that returns triangle type

c++ c testing integration-testing

I got the following question as part of a screening interview:

Handling new lines in php

php arrays textarea line-breaks explode

I have form in html where user can put the text in text area.

About UNIX Resources Network

Original, collect and organize Developers related documents, information and materials, contains jQuery, Html, CSS, MySQL, .NET, ASP.NET, SQL, objective-c, iPhone, Ruby on Rails, C, SQL Server, Ruby, Arrays, Regex, ASP.NET MVC, WPF, XML, Ajax, DataBase, and so on.