Retro.TUI.Rendering
0.4.1-alpha.4
Prefix Reserved
dotnet add package Retro.TUI.Rendering --version 0.4.1-alpha.4
NuGet\Install-Package Retro.TUI.Rendering -Version 0.4.1-alpha.4
<PackageReference Include="Retro.TUI.Rendering" Version="0.4.1-alpha.4" />
<PackageVersion Include="Retro.TUI.Rendering" Version="0.4.1-alpha.4" />
<PackageReference Include="Retro.TUI.Rendering" />
paket add Retro.TUI.Rendering --version 0.4.1-alpha.4
#r "nuget: Retro.TUI.Rendering, 0.4.1-alpha.4"
#:package Retro.TUI.Rendering@0.4.1-alpha.4
#addin nuget:?package=Retro.TUI.Rendering&version=0.4.1-alpha.4&prerelease
#tool nuget:?package=Retro.TUI.Rendering&version=0.4.1-alpha.4&prerelease
Retro.TUI.Framework
A modern C-Sharp .NET multiplatform TUI framework powered by SkiaSharp,
inspired by Turbo Vision with a PC Tools 9.x retro aesthetic.
π VersiΓ³n espaΓ±ola

Index
- Overview
- What it is and what it is not
- Inspiration and references
- Design decisions
- Solution structure
- Architecture layers
- Roadmap
- Detailed technical documentation
1. Overview
Retro.TUI.Framework is a .NET framework for building text user interface (TUI) applications with the following core characteristics:
- Truly multiplatform: Windows, Linux and macOS from the same code base.
- Vector rendering: SkiaSharp as the drawing engine, with embedded bitmap fonts and an authentic EGA/CGA color palette.
- Component model: hierarchical view tree, typed event system, focus management and modal stack, inspired by the Turbo Vision architecture.
- Fixed EGA palette: 16-color EGA palette with semantic color roles (
TuiColorRole). Colors are fixed and faithful to the PC Tools 9.x aesthetic by Central Point Software. - Idiomatic C#: naming, patterns and conventions native to modern C# (.NET 10+). It is not a 1:1 translation of Turbo Vision.
2. What it is and what it is not
It is
- A framework for building desktop TUI applications with a retro look.
- A reusable library distributable as independent NuGet packages per layer.
- An extensible foundation for building custom controls and behaviours.
It is not
- A terminal emulator or a framework for console applications (
stdout/stdin). - A direct reimplementation of Turbo Vision. It adopts its philosophy and patterns, but adapts them to the modern .NET ecosystem.
- A specific application. The project includes a sample app (
samples/) that reproduces the PC Tools 9 look, but the framework is independent of it.
3. Inspiration and references
Turbo Vision (Borland, 1990)
Turbo Vision was a TUI framework for C++ and Pascal that introduced advanced concepts for its time: view tree, event system, modal stack, semantic palettes and a component composition model. This framework adopts its architectural philosophy and translates it to the modern C# paradigm.
| Turbo Vision concept | Retro.TUI equivalent |
|---|---|
TView |
TuiView |
TGroup |
TuiGroup |
TApplication |
TuiApplication |
TEvent (struct with union) |
record hierarchy with TuiEvent |
Numeric palette (tpXxx) |
TuiColorRole (semantic enum) |
TDeskTop |
TuiDesktop |
TWindow / TDialog |
TuiWindow / TuiDialog |
TMenuBar / TStatusLine |
TuiMenuBar / TuiStatusBar |
PC Tools 9.x (Central Point Software, ~1991)
The visual aesthetic reference. Characteristics reproduced:
- Standard 16-color EGA palette mapped to semantic roles, with two additional non-EGA grays for inactive title bars and scroll bar tracks.
- IBM VGA monospaced font (PxPlus IBM VGA 9x16), embedded as a resource in
Retro.TUI.Theming. - Application title bar in Norton/PCTools style.
- Window borders with geometric lines (not Unicode box-drawing characters).
- Semi-transparent shadows on windows and dialogs.
- Menu bar and status bar with the characteristic color scheme.
4. Design decisions
4.1 Window host: SDL2 + SkiaSharp
Decision: SDL2 (via .NET binding through Silk.NET) as window and input host. SkiaSharp as the 2D rendering engine.
Rationale:
- SDL2 does exactly one thing: manage windows, keyboard/mouse input and the rendering context. It imposes no UI model of its own.
- SkiaSharp provides high-quality 2D vector rendering with font support, controllable antialiasing and direct access to graphics primitives.
- Truly multiplatform: the same API on Windows, Linux and macOS.
4.2 Class prefix: Tui
Decision: all public framework classes use the Tui prefix.
Rationale: avoids collisions with System.* (View, Window, Application,
Label, Control...), SkiaSharp (SK prefix) and SDL2 (SDL prefix).
Examples: TuiView, TuiDialog, TuiMenuBar, TuiPalette, TuiTheme.
4.3 Event system: .NET records + Channel<T>
Decision: hierarchy of abstract record TuiEvent with subtypes for each event type.
Queue implemented with System.Threading.Channels.Channel<TuiEvent>.
4.4 Color system: fixed EGA palette + semantic roles
Decision: the color scheme is fixed and defined in three static classes β
TuiEgaPalette (16 canonical EGA color constants), TuiColorMap (internal
mapping from TuiColorRole to SKColor) and TuiPalette (public static
Resolve(TuiColorRole) method). TuiTheme is a static class holding only
typography and shadow parameters.
No control has hardcoded colors. All rendering code resolves colors through
TuiPalette.Resolve(TuiColorRole).
4.5 Separate projects per layer
Decision: each layer is an independent .csproj project.
Rationale: enforces layer dependencies at compile time, enables independent NuGet distribution per layer, and facilitates unit testing per layer.
4.6 Naming and conventions
The framework follows official C# conventions throughout:
PascalCase, _camelCase for private fields, I prefix for interfaces,
XML doc comments on all public API, nullable reference types enabled,
record for immutable value types, init-only setters for configuration.
5. Solution structure
Retro.TUI.Framework.sln
β
βββ docs/
β βββ architecture.md Detailed technical design
β
βββ samples/
β βββ Retro.TUI.Sample.Basic/ Basic demo application
β
βββ src/
β βββ Retro.TUI.Core/ Application, message loop
β βββ Retro.TUI.Events/ Event hierarchy and commands
β βββ Retro.TUI.Hosting/ Window and input host (SDL2)
β βββ Retro.TUI.Rendering/ Rendering engine (SkiaSharp)
β βββ Retro.TUI.Theming/ Palettes, themes and color roles
β βββ Retro.TUI.Views/ TuiView, TuiGroup, TuiDesktop
β βββ Retro.TUI.Widgets/ Standard controls
β βββ Retro.TUI.Windows/ TuiWindow, TuiDialog
β
βββ tests/
βββ Retro.TUI.Core.Tests/
βββ Retro.TUI.Events.Tests/
βββ Retro.TUI.Hosting.Tests/
βββ Retro.TUI.Rendering.Tests/
βββ Retro.TUI.Theming.Tests/
βββ Retro.TUI.Views.Tests/
βββ Retro.TUI.Widgets.Tests/
βββ Retro.TUI.Windows.Tests/
Project dependencies
Dependencies strictly follow the layer direction. No lower layer knows about any upper layer.
Retro.TUI.Widgets
βββ Retro.TUI.Windows
βββ Retro.TUI.Views
βββ Retro.TUI.Core
βββ Retro.TUI.Rendering
β βββ Retro.TUI.Theming
β βββ Retro.TUI.Events
βββ Retro.TUI.Hosting
βββ Retro.TUI.Events
6. Architecture layers
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β WIDGETS LAYER β
β TuiMenuBar Β· TuiStatusBar Β· TuiButton Β· TuiLabel β
β TuiInputLine Β· TuiCheckBox Β· TuiRadioButton Β· ... β
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β WINDOWS LAYER β
β TuiWindow Β· TuiDialog β
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β VIEWS LAYER β
β TuiView Β· TuiGroup Β· TuiDesktop β
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β CORE LAYER β
β TuiApplication Β· TuiMessageLoop β
βββββββββββββββββββββββββ¬βββββββββββββββββββββββββββββββ€
β RENDERING LAYER β HOSTING LAYER β
β TuiRenderContext β ITuiHost Β· SdlHost β
β TuiGrid Β· TuiFont β ITuiInputProvider β
βββββββββββββββββββββββββ΄βββββββββββββββββββββββββββββββ€
β THEMING LAYER β
β TuiTheme Β· TuiPalette Β· TuiColorRole β
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β EVENTS LAYER β
β TuiEvent (record hierarchy) Β· TuiCommand β
β TuiEventQueue Β· TuiKey Β· TuiModifiers β
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
For the complete technical detail of each layer, see:
7. Roadmap
| Milestone | Version | Content |
|---|---|---|
| 1 β Foundations | v0.1.0 |
Hosting, Rendering, Theming, Events |
| 2 β View tree | v0.2.0 |
Views, Core, Application loop |
| 3 β Windows | v0.3.0 |
TuiWindow, TuiDialog, modal stack |
| 4 β Base controls (Widgets) | v0.4.0 |
MenuBar, StatusBar, Button, Input |
| 5 β Advanced controls | v0.5.0 |
CheckBox, RadioButton, ListBox, ScrollBar |
| 6 β Sample application | v1.0.0 |
PC Tools 9 desktop sample |
Milestone 1 β Foundations (Hosting + Rendering + Theming + Events)
v0.1.0
- β
Retro.TUI.Events: record hierarchy,TuiCommand,TuiKey - β
Retro.TUI.Theming:TuiColorRole,TuiEgaPalette,TuiColorMap,TuiPalette(static),TuiTheme(static) β IBM VGA font embedded as resource - β
Retro.TUI.Hosting:ITuiHost,SdlHost - β
Retro.TUI.Rendering:TuiRenderContext,TuiGrid,TuiFont
Milestone 2 β View tree (Views + Core)
v0.2.0
- β
Retro.TUI.Views:TuiView,TuiGroup,TuiDesktop - β
Retro.TUI.Core:TuiApplication,TuiMessageLoop,TuiFocusManager - β Keyboard and mouse event dispatch to the tree
- β Custom mouse cursor
Milestone 3 β Windows
v0.3.0 β
- β
TuiWindowwith title, border and shadow - β
TuiDialogwith modal stack (IModalDialog,TuiDesktop.PushModal/PopModal) - β
Window drag with mouse (mouse capture via
_capturedView) - β Z-order (bring to front on click)
- β
TuiApplication.RunModalβ nested event loop, automatic lifecycle - β Modal event routing β keyboard, mouse and commands restricted to active modal
Milestone 4 β Base controls (Widgets)
v0.4.0
-
TuiMenuBarwith hover and menu opening -
TuiStatusBarwith function keys - β
TuiButtonβ focus, keyboard/mouse/accelerator activation, disabled state, factory presets (Ok,Cancel,Yes,No,Abort,Retry,Ignore) - β
TuiLabel -
TuiInputLinewith blinking cursor and basic editing
Milestone 5 β Advanced controls
v0.5.0
-
TuiCheckBox -
TuiRadioButtonwith groups -
TuiListBox -
TuiScrollBar - Drop-down menus (
TuiMenu,TuiMenuItem)
Milestone 6 β Sample application
v1.0.0
-
Retro.TUI.Sample.PcTools: reproduction of the PC Tools 9 desktop - Framework usage documentation
8. Detailed technical documentation
| Document | Content |
|---|---|
| docs/architecture.md | Contracts, event hierarchy, theming, lifecycle, view tree |
Requirements
- .NET 10 SDK (
10.0.300or later) - Visual Studio 2026 or VS Code with C# Dev Kit
- SDL2 native libraries (Windows: bundled via NuGet; Linux/macOS: system package)
- Compatible with Windows 10+, Ubuntu 20.04+, macOS 12+
Contributing
See CONTRIBUTING.md for branch strategy, commit conventions and coding guidelines.
Third-party notices
See THIRD-PARTY-NOTICES.md for the licenses of all third-party components used by this project.
License
This project is licensed under the MIT License.
Β© 2026 Oscar Fernandez Gonzalez a.k.a. Osc@rNET and Contributors
Trademarks and Acknowledgements
This project is not affiliated with, endorsed by, or sponsored by any of the following companies or products:
- Turbo Vision is a trademark of Embarcadero Technologies, Inc.
- PC Tools was a trademark of Central Point Software, Inc., later acquired by Symantec Corporation.
- Norton is a trademark of Gen Digital Inc.
- IBM is a registered trademark of International Business Machines Corporation.
The retro aesthetic and architectural concepts used in this project are inspired by these products for educational and nostalgic purposes only. All trademarks are the property of their respective owners.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net10.0 is compatible. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net10.0
- Retro.TUI.Theming (>= 0.4.1-alpha.4)
- SkiaSharp (>= 3.119.2)
- SkiaSharp.NativeAssets.Linux (>= 3.119.2)
- SkiaSharp.NativeAssets.macOS (>= 3.119.2)
- SkiaSharp.NativeAssets.Win32 (>= 3.119.2)
NuGet packages (2)
Showing the top 2 NuGet packages that depend on Retro.TUI.Rendering:
| Package | Downloads |
|---|---|
|
Retro.TUI.Views
View-tree layer for Retro.TUI.Framework. Provides TuiView, TuiGroup and TuiDesktop β the composable visual hierarchy that all controls and windows build on. Depends on Events, Theming and Rendering; does not reference SkiaSharp directly. |
|
|
Retro.TUI.Core
Application core for Retro.TUI.Framework. Provides TuiApplication (entry point), TuiMessageLoop (poll-update-render cycle) and TuiFocusManager (keyboard focus). This is the only layer that wires together Hosting, Rendering and the view tree. |
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 0.4.1-alpha.4 | 98 | 7/7/2026 |
| 0.3.0-alpha.3 | 83 | 6/27/2026 |