ApeFree.ApeDialogs.WPF
1.1.0-alpha61112
.NET 6.0
This package targets .NET 6.0. The package is compatible with this framework or higher.
.NET Framework 4.5.2
This package targets .NET Framework 4.5.2. The package is compatible with this framework or higher.
This is a prerelease version of ApeFree.ApeDialogs.WPF.
dotnet add package ApeFree.ApeDialogs.WPF --version 1.1.0-alpha61112
NuGet\Install-Package ApeFree.ApeDialogs.WPF -Version 1.1.0-alpha61112
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="ApeFree.ApeDialogs.WPF" Version="1.1.0-alpha61112" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="ApeFree.ApeDialogs.WPF" Version="1.1.0-alpha61112" />
<PackageReference Include="ApeFree.ApeDialogs.WPF" />
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 ApeFree.ApeDialogs.WPF --version 1.1.0-alpha61112
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: ApeFree.ApeDialogs.WPF, 1.1.0-alpha61112"
#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 ApeFree.ApeDialogs.WPF@1.1.0-alpha61112
#: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=ApeFree.ApeDialogs.WPF&version=1.1.0-alpha61112&prerelease
#tool nuget:?package=ApeFree.ApeDialogs.WPF&version=1.1.0-alpha61112&prerelease
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
ApeFree.ApeDialogs.WPF
ApeFree.ApeDialogs.WPF 是 ApeFree.ApeDialogs 规范的 WPF 实现库。遵循 Windows 11 Fluent Design 视觉规范设计,内置暗黑/明亮主题自动跟随与切换、圆角阴影及微动效交互。
- 目标框架:
net452、net461、net472、net6.0-windows、net8.0-windows、net10.0-windows
🌟 核心特性
- 🎨 Win11 Fluent 视觉风格:精致的排版、进出场与校验抖动动画、主色强调与圆角阴影效果。
- 🌓 深色/浅色主题支持:内置
Brushes.Light与Brushes.Dark,默认跟随系统主题并支持通过ThemeManager运行时切换。 - 🖼 跨宿主支持:原生支持纯 WPF 窗口环境,并可通过
ApeFree.ApeDialogs.WPF.WinForms桥接包无缝运行在 WinForms 应用程序中(使用IWin32Owner自动建立层级与模态等待)。 - 🛠 完整弹窗覆盖:支持消息、提示、输入、密码、颜色选取、单选/多选、时间日期、滑动条/区间滑动条、文件/目录选择、进度、轻提示、长文本及动态表单等全部 19 种标准弹窗。
📦 安装
dotnet add package ApeFree.ApeDialogs.WPF
或在项目文件(.csproj)中添加引用:
<PackageReference Include="ApeFree.ApeDialogs.WPF" Version="1.1.0.0-alpha61112" />
🚀 快速上手
1. 基础用法
using System;
using ApeFree.ApeDialogs;
using ApeFree.ApeDialogs.Settings;
using ApeFree.ApeDialogs.WPF;
// 创建 WPF DialogProvider 实例
var provider = new ApeDialogsWpfProvider();
// 弹出标准消息提示框
var result = await provider.ShowMessageDialogAsync(new MessageDialogSettings
{
Title = "系统提示",
Content = "操作成功!",
});
// 弹出颜色拾取对话框
var colorResult = await provider.ShowColorDialogAsync(new ColorDialogSettings
{
Title = "颜色配置",
Content = "请选择背景颜色",
});
if (colorResult.IsConfirmed)
{
var color = colorResult.Value;
Console.WriteLine($"选择了颜色: R={color.R}, G={color.G}, B={color.B}");
}
2. 指定父窗口宿主 (Owner)
using ApeFree.ApeDialogs.WPF.Interop;
// 指定 WPF Window 为父窗口
await provider.ShowInputDialogAsync(
new InputDialogSettings
{
Title = "标题",
Content = "请输入内容",
},
new WindowOwner(this));
📄 开源许可证
本项目基于 Apache-2.0 协议开源。
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net6.0-windows7.0 is compatible. net7.0-windows was computed. net8.0-windows was computed. net8.0-windows7.0 is compatible. net9.0-windows was computed. net10.0-windows was computed. net10.0-windows7.0 is compatible. |
| .NET Framework | net452 is compatible. net46 was computed. net461 is compatible. net462 was computed. net463 was computed. net47 was computed. net471 was computed. net472 is compatible. net48 was computed. net481 was computed. |
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
-
.NETFramework 4.5.2
- ApeFree.ApeDialogs (>= 1.1.0-alpha61112)
- System.ValueTuple (>= 4.5.0)
-
.NETFramework 4.6.1
- ApeFree.ApeDialogs (>= 1.1.0-alpha61112)
- System.ValueTuple (>= 4.5.0)
-
.NETFramework 4.7.2
- ApeFree.ApeDialogs (>= 1.1.0-alpha61112)
-
net10.0-windows7.0
- ApeFree.ApeDialogs (>= 1.1.0-alpha61112)
-
net6.0-windows7.0
- ApeFree.ApeDialogs (>= 1.1.0-alpha61112)
-
net8.0-windows7.0
- ApeFree.ApeDialogs (>= 1.1.0-alpha61112)
NuGet packages (1)
Showing the top 1 NuGet packages that depend on ApeFree.ApeDialogs.WPF:
| Package | Downloads |
|---|---|
|
ApeFree.ApeDialogs.WPF.WinForms
在 WinForms 应用中使用 ApeFree.ApeDialogs.WPF 的桥接包(FormOwner + Form 扩展方法)。 |
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 1.1.0-alpha61112 | 51 | 11/12/2026 |