Legend

Class
Struct
Enum
Interface
Delegate
Constructor
Method
Property
Event
Field

Sealed class: RT.Util.Consoles.ColoredConsoleOut

Summary

Implements a TextWriter which outputs text to the console in a predetermined ConsoleColor.

Remarks

Every time a string is output to the console, the current console foreground colour is remembered and returned to its previous value after the output.

Constructors

ColoredConsoleOut(ConsoleColor color)
Constructor.

Instance methods

void
Write(char value)
  • Overrides: TextWriter.Write(char)
Writes the specified character to the console.
void
Write(string value)
  • Overrides: TextWriter.Write(string)
Writes the specified string to the console.
void
  • Overrides: TextWriter.WriteLine()
Outputs a newline to the console.
void
WriteLine(string str)
  • Overrides: TextWriter.WriteLine(string)
Outputs the specified text plus a newline to the console.

Instance properties

Encoding
  • Overrides: TextWriter.Encoding
TextWriter requires this to be overridden. This returns Encoding.UTF8.