Darkraise.Win32UI 1.0.1

dotnet add package Darkraise.Win32UI --version 1.0.1
                    
NuGet\Install-Package Darkraise.Win32UI -Version 1.0.1
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Darkraise.Win32UI" Version="1.0.1" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Darkraise.Win32UI" Version="1.0.1" />
                    
Directory.Packages.props
<PackageReference Include="Darkraise.Win32UI" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Darkraise.Win32UI --version 1.0.1
                    
#r "nuget: Darkraise.Win32UI, 1.0.1"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Darkraise.Win32UI@1.0.1
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Darkraise.Win32UI&version=1.0.1
                    
Install as a Cake Addin
#tool nuget:?package=Darkraise.Win32UI&version=1.0.1
                    
Install as a Cake Tool

Darkraise.Win32UI

A desktop UI framework built directly on Win32 and Direct2D. No WPF, no WinForms, no third-party packages — windows are real HWNDs, painting is hardware-accelerated through Direct2D and DirectWrite, and the whole framework is NativeAOT compatible.

dotnet add package Darkraise.Win32UI

Highlights

  • 90+ themed controls — buttons, inputs, selects, data grid, tree view, tabs, menus, dialogs, drawers, popovers, toasts, charts, calendars, color picker, and a full syntax-highlighting code editor with completion, diagnostics, folding, multi-caret and find/replace.
  • Fluent builder API — compose views in C# through the static View factory, or write them in .draml markup and let Darkraise.Win32UI.Generators compile them.
  • Convention-based MVVMFooViewModel resolves to FooView; screens get lifecycle hooks, DI resolution, logging and dialogs from the shared Darkraise.Mvvm layer.
  • Theming — light and dark themes, accent presets, surface elevation tokens, runtime switching, and a CSS-like box model with shadows, corner radii and transitions.
  • Layout — stack, dock, grid and flow managers, plus WPF-style Grid, WrapPanel, UniformGrid, Canvas and Viewbox panels.
  • Data binding — one-way and two-way property binding, collection binding, and data templates.

Quick start

// Program.cs
using Darkraise.Win32UI.Application;

public static class Program
{
    [STAThread]
    public static void Main() => new App().Run();
}

// App.cs
public class App : DarkraiseApplication
{
    protected override void ConfigureServices(IServiceRegistry services)
    {
        // Register your own services; AddWin32UI() runs afterwards and respects overrides.
    }

    protected override void Configure(ApplicationConfiguration config)
    {
        config.ApplicationName = "Hello Win32UI";
        config.Theme = AppTheme.Dark;
        config.Accent = AccentPreset.Blue;
        config.Assemblies = [typeof(App).Assembly];
    }
}

// ViewModels/ShellViewModel.cs
[RootViewModel]
public class ShellViewModel : DarkraiseScreen
{
    private string _status = "Ready";

    public string Status
    {
        get => _status;
        set => Set(ref _status, value);
    }

    public void Greet() => Status = $"Hello from Win32UI at {DateTime.Now:T}";
}

// Views/ShellView.cs — resolved by convention: ShellViewModel → ShellView
public class ShellView : ViewBase<ShellViewModel>
{
    protected override Control BuildView(ShellViewModel vm) =>
        View.Stack(
                Orientation.Vertical,
                16,
                View.Label("Hello, Win32UI").FontSize(FontSize.Xl).Bold(),
                View.Label().Bind(vm, x => x.Status).Muted(),
                View.Button("Greet").OnClick(vm.Greet)
            )
            .Padding(24);
}

Run() builds the DI container, scans the configured assemblies for view models, resolves the [RootViewModel] and its view, then pumps the message loop until shutdown.

Requirements

Targets net10.0-windows and requires Windows. Direct2D rendering needs a D3D-capable device; the framework falls back gracefully on device loss.

Documentation

License

MIT. Embedded icon geometry derives from the Lucide icon set (ISC) — see THIRD-PARTY-NOTICES.md.

Product Compatible and additional computed target framework versions.
.NET net10.0-windows7.0 is compatible. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
1.0.1 99 8/15/2026
1.0.0 89 8/15/2026