Advanced Console IO in .NET

There are a couple of libraries that can be helpful when writing TUI based applications in C#:

  • Gui.cs is a Terminal UI toolkit for .NET by Miguel de Icaza. This is a simple UI toolkit for .NET, .NET Core and Mono and works on both Windows and Linux/Unix.
  • MonoCurses is an MIT-X11 licensed binding of curses, and it includes the minimalistic gui.cs GUI toolkit for creating console-based applications.
  • ConsoleGUI is a simple layout-driven library for creating console-based GUI applications. It provides most essential layout management utilities as well as a set of basic controls.
  • CursesSharp is a C# wrapper for curses library.

Console.SetCursorPosition, Console.BackgroundColor, Console.ForegroundColor, and Console.ResetColor.

Note these were added to the .NET Framework in version 2.0. Prior to that you would have needed PInvoke.

Tags:

.Net

Console