* Initial plan * Add missing properties to IApplication and move implementation to ApplicationImpl - Added Force16Colors, ForceDriver, Sixel, Screen, and ClearScreenNextIteration to IApplication - Moved implementation of these properties from Application static class to ApplicationImpl - Updated Application.Driver.cs to delegate to ApplicationImpl.Instance - Updated Application.Screen.cs to delegate to ApplicationImpl.Instance - Added ResetScreen() method to ApplicationImpl for proper state cleanup - Removed TODOs marked "Add to IApplication" in Application.Driver.cs - All Application-related unit tests passing (180 passed) Co-authored-by: tig <585482+tig@users.noreply.github.com> * Rename Application.Initialization.cs to Application.Lifecycle.cs - Changed terminology from "Initialization" to "Lifecycle" as requested - Updated file comment to reflect lifecycle encompasses Init through Shutdown - All tests still passing (193 Application-related tests) Co-authored-by: tig <585482+tig@users.noreply.github.com> * Address code review feedback in Application.Lifecycle.cs - Fixed typo: 'cam' -> 'can' in XML documentation - Fixed typo: 'Gets of list' -> 'Gets a list' in XML documentation - Removed large block of commented-out legacy driver detection code - Removed extra blank lines for cleaner code formatting - All tests still passing (180 Application tests) Co-authored-by: tig <585482+tig@users.noreply.github.com> * Fix potential race condition in ApplicationImpl.Shutdown() - Reset Screen before calling Application.ResetState() to avoid circular reference - Application.ResetState() was trying to access ApplicationImpl.Instance while inside Shutdown() - This could cause race conditions and crashes in test scenarios - ResetScreen() is now called both in Shutdown() and ResetState() for safety - All 3116 unit tests passing Co-authored-by: tig <585482+tig@users.noreply.github.com> --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: tig <585482+tig@users.noreply.github.com> Co-authored-by: Tig <tig@users.noreply.github.com>
Application.Keyboard to support fully decoupled state and parallelizable unit tests (#4316)
Terminal.Gui v2
The premier toolkit for building rich console apps for Windows, the Mac, and Linux/Unix.
⚠️ Note:
v1is in maintenance mode and we will only accept PRs for issues impacting existing functionality.
⚠️ Note:
Developers starting new TUI projects are encouraged to targetv2 Alpha. The API is significantly changed, and significantly improved. There will be breaking changes in the API before Beta, but the core API is stable.
Quick Start
Paste these commands into your favorite terminal on Windows, Mac, or Linux. This will install the Terminal.Gui.Templates, create a new "Hello World" TUI app, and run it.
(Press CTRL-Q to exit the app)
dotnet new --install Terminal.Gui.templates
dotnet new tui -n myproj
cd myproj
dotnet run
To run the UICatalog demo app that shows all the controls and features of the toolkit, use the following command:
dotnet run --project Examples/UICatalog/UICatalog.csproj
There is also a visual designer (uses Terminal.Gui itself).
Documentation
The full developer documentation for Terminal.Gui is available at gui-cs.github.io/Terminal.Gui.
Getting Started
- Getting Started - Quick start guide to create your first Terminal.Gui application
- Migrating from v1 to v2 - Complete guide for upgrading existing applications
- What's New in v2 - Overview of new features and improvements
API Reference
For detailed API documentation, see the API Reference.
Installing
Use NuGet to install the Terminal.Gui NuGet package:
v2 Alpha
(Infrequently updated, but stable enough for production use)
dotnet add package Terminal.Gui --version "2.0.0-alpha.*"
v2 Develop
(Frequently updated, but may have breaking changes)
dotnet add package Terminal.Gui --version "2.0.0-develop.*"
Legacy v1
dotnet add package Terminal.Gui --version "1.*
Or, you can use the Terminal.Gui.Templates.
Contributing
See CONTRIBUTING.md.
Debates on architecture and design can be found in Issues tagged with design.
History
See gui-cs for how this project came to be.

