Dreamine.UI.Wpf 1.0.1

dotnet add package Dreamine.UI.Wpf --version 1.0.1
                    
NuGet\Install-Package Dreamine.UI.Wpf -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="Dreamine.UI.Wpf" Version="1.0.1" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Dreamine.UI.Wpf" Version="1.0.1" />
                    
Directory.Packages.props
<PackageReference Include="Dreamine.UI.Wpf" />
                    
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 Dreamine.UI.Wpf --version 1.0.1
                    
#r "nuget: Dreamine.UI.Wpf, 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 Dreamine.UI.Wpf@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=Dreamine.UI.Wpf&version=1.0.1
                    
Install as a Cake Addin
#tool nuget:?package=Dreamine.UI.Wpf&version=1.0.1
                    
Install as a Cake Tool

Dreamine.UI.Wpf

Dreamine.UI.Wpf is the WPF foundation layer of the Dreamine UI stack.

It provides shared utilities consumed by all higher-level Dreamine UI packages:

  • Value converters
  • WPF behaviors
  • Localization infrastructure
  • Base LED control primitives

➡️ 한국어 문서 보기


What this library solves

WPF UI packages need a shared foundation for:

  • Binding converters reused across many XAML files
  • XAML-attachable behaviors (drag, numeric range, etc.)
  • Centralized multi-language text management
  • Shared enumerations and primitives for LED controls

Without this layer, each UI package would duplicate converters and utilities, causing divergence and maintenance burden.


Key Features

  • Converters: null-to-visibility, bool-to-int, LED geometry, value/unit combination, format-to-example, language-to-XML
  • Behaviors: WindowDragBehavior, NumericRangeBehavior
  • Localization: DreamineLocalizationManager — multi-language text lookup with hot-reload support
  • LED primitives: LedCorner enum shared across LED-related controls
  • Targets net8.0-windows

Requirements

  • Target Framework: net8.0-windows
  • Dependencies:
    • Dreamine.MVVM.ViewModels
    • Microsoft.Xaml.Behaviors.Wpf
    • System.Drawing.Common

Installation

NuGet

dotnet add package Dreamine.UI.Wpf

PackageReference

<PackageReference Include="Dreamine.UI.Wpf" />

Project Structure

Dreamine.UI.Wpf
├── Behaviors/
│   ├── NumericRangeBehavior.cs        — clamp numeric input to min/max
│   └── WindowDragBehavior.cs          — drag window by mouse-down on element
├── Controls/
│   └── LedCorner.cs                   — corner radius enum for LED controls
├── Converters/
│   ├── BoolToIntDynamicConverter.cs   — bool → configurable int value
│   ├── FormatToExampleConverter.cs    — input format → example string
│   ├── LedInnerDiameterConverter.cs   — LED inner circle size (MultiBinding)
│   ├── LedPositionConverter.cs        — LED dot offset within bounding box
│   ├── NullToVisibilityConverter.cs   — null → Collapsed, non-null → Visible
│   └── ValueUnitCombinationConverter.cs — combine value + unit label
└── Localization/
    ├── DreamineLocalization.cs        — XAML attached property entry point
    └── DreamineLocalizationManager.cs — runtime text lookup and language switch

Architecture Role

Dreamine.MVVM.ViewModels
        │
Dreamine.UI.Wpf              ← this package
        │
Dreamine.UI.Wpf.Controls
Dreamine.UI.Wpf.Equipment
Dreamine.UI.Wpf.Themes

All higher-level UI packages reference this package.
It must not reference them.


Quick Start

Converters in XAML

xmlns:conv="clr-namespace:Dreamine.UI.Wpf.Converters;assembly=Dreamine.UI.Wpf"

<conv:NullToVisibilityConverter x:Key="NullToVis" />

<TextBlock Visibility="{Binding Icon, Converter={StaticResource NullToVis}}" />

WindowDragBehavior

xmlns:b="clr-namespace:Dreamine.UI.Wpf.Behaviors;assembly=Dreamine.UI.Wpf"
xmlns:i="http://schemas.microsoft.com/xaml/behaviors"

<Border Background="#FF2D2D2D">
    <i:Interaction.Behaviors>
        <b:WindowDragBehavior />
    </i:Interaction.Behaviors>
</Border>

Localization

// Set language at startup
DreamineLocalizationManager.SetLanguage(Language.ko_KR);
xmlns:vsl="clr-namespace:Dreamine.UI.Wpf.Localization;assembly=Dreamine.UI.Wpf"

<TextBlock vsl:DreamineLocalization.Key="MainMenu.Title" />

Converter Reference

Converter Input Output
NullToVisibilityConverter object? Visibility
BoolToIntDynamicConverter bool int (configurable)
LedInnerDiameterConverter double, double (MultiBinding) double
LedPositionConverter double, LedCorner (MultiBinding) double
ValueUnitCombinationConverter string string
FormatToExampleConverter InputFormat string

Design Notes

  • This package never references higher-level UI packages
  • Converters are stateless and safe to use as static resources
  • DreamineLocalizationManager loads text from XML files at runtime — the file path is configurable
  • WindowDragBehavior uses Window.GetWindow(AssociatedObject).DragMove() internally

License

MIT License

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

NuGet packages (4)

Showing the top 4 NuGet packages that depend on Dreamine.UI.Wpf:

Package Downloads
Dreamine.UI.FullKit

All-in-one meta package for Dreamine UI libraries (WPF stack). Includes Abstractions, Wpf host, Controls, Equipment, and Themes. Blazor / MAUI / WinForms hosts must be installed separately due to framework differences.

Dreamine.UI.Wpf.Controls

Custom WPF controls for the Dreamine UI library: DreamineButton, DreamineTextBox, MessageBox, Navigation, and more.

Dreamine.UI.Wpf.Equipment

Equipment-grade WPF components: Virtual Keyboard, Blink Popup, Alarm Config.

Dreamine.UI.Wpf.Themes

WPF style/theme ResourceDictionary files for Dreamine UI controls.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
1.0.1 120 7/8/2026
1.0.0 110 7/8/2026