GTKSystem.Windows.Forms
1.0.0.1
See the version list below for details.
dotnet tool install --global GTKSystem.Windows.Forms --version 1.0.0.1
dotnet new tool-manifest
dotnet tool install --local GTKSystem.Windows.Forms --version 1.0.0.1
#tool dotnet:?package=GTKSystem.Windows.Forms&version=1.0.0.1
nuke :add-package GTKSystem.Windows.Forms --version 1.0.0.1
GTKSystem.Windows.Forms
介绍
Visual Studio原生开发,无需学习,一次编译,跨平台运行. 这是基于GTK框架组件开发的跨平台(windows、linux、macos)C#桌面应用程序表单界面组件,该组件的核心优势是使用C#的原生表单控件和属性方法,C#原生开发即可,无需学习。 便于开发跨平台winform软件,便于将C#升级为跨平台软件。
作者博客请看 https://www.cnblogs.com/easywebfactory/p/17803567.html
目前功能持续更新中,将优先完善常用功能。
软件架构
使用GTK3.24.24.95作为表单UI重写C#的System.Windows.Forms组件,在应用时,兼容原生C#程序组件。
安装教程
- 把项目工程改为“控制台应用程序”或者配置UseWindowsForms为false,框架.net6或以上版本
- NulGet安装GtkSharp(3.24.24.95)
- 引用Libs目录下的GTKSystem.Windows.Forms.dll和System.Resources.Extensions.dll
- 编译发布测试运行
- linux和macos上执行命令:dotnet doemo_app.dll
VisualStudio插件安装
关闭visual studio,直接双击GTKWinformVSIXProject.vsix文件安装
插件会安装两个功能,都是在右键菜单和工具菜单上添加:
1、新建项的Form窗体模板
2、菜单增加设置/修复窗体设计器
使用说明
以下配置在你的项目工程里操作:
1、新建System.Resources.ResourceManager类<br/> 在项目下新建System.Resources.ResourceManager类,继承GTKSystem.Resources.ResourceManager,用于覆盖原生System.Resources.ResourceManager类。 GTKSystem.Resources.ResourceManager实现了项目资源文件和图像文件读取。 如果项目里没有使用资源图像文件,可以不用新建此文件。
2、新建System.ComponentModel.ComponentResourceManager类<br/> 在项目下新建System.ComponentModel.ComponentResourceManager类,继承GTKSystem.ComponentModel.ComponentResourceManager,用于覆盖原生System.ComponentModel.ComponentResourceManager类。<br/> GTKSystem.ComponentModel.ComponentResourceManager实现了项目资源文件和图像文件读取(调用GTKSystem.Resources.ResourceManager)。 如果项目里没有使用资源图像文件,可以不用新建此文件。
3、GTKWinFormsApp.csproj<br/> 配置UseWindowsForms为false,或者使用控制台应用程序
<UseWindowsForms>false</UseWindowsForms>
4、引用GTKSystem.Windows.Forms、System.Resources.Extensions <br/> System.Resources.Extensions是空程序dll,VS加载Form界面时验证需要此dll.
5、GTKWinFormsApp\obj\Debug\net6.0\GTKWinFormsApp.designer.runtimeconfig.json GTKWinFormsApp\obj\Release\net6.0\GTKWinFormsApp.designer.runtimeconfig.json 将name设置为Microsoft.WindowsDesktop.App, 用于VS支持可视化窗体设计器,重新加载工程或重启VS
"runtimeOptions": {
"framework": {
"name": "Microsoft.WindowsDesktop.App"
},
demo效果
mac运行效果
颜色主题
窗口背景
工具栏菜单
交流
QQ群:236066073
参与贡献
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net6.0 is compatible. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 was computed. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 was computed. 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. |
This package has no dependencies.
| Version | Downloads | Last Updated |
|---|---|---|
| 1.3.24.84 | 33 | 1/8/2026 |
| 1.3.24.83 | 123 | 12/13/2025 |
| 1.3.24.82 | 189 | 12/5/2025 |
| 1.3.24.81 | 181 | 10/31/2025 |
| 1.3.24.80 | 205 | 10/26/2025 |
| 1.3.24.79 | 193 | 10/22/2025 |
| 1.3.24.78 | 183 | 10/21/2025 |
| 1.3.24.77 | 186 | 10/16/2025 |
| 1.3.24.76 | 224 | 9/13/2025 |
| 1.3.24.75 | 312 | 8/29/2025 |
| 1.3.24.74 | 207 | 8/15/2025 |
| 1.3.24.73 | 200 | 8/14/2025 |
| 1.3.24.72 | 445 | 7/25/2025 |
| 1.3.24.71 | 511 | 7/24/2025 |
| 1.3.24.70 | 472 | 7/21/2025 |
| 1.3.24.69 | 260 | 6/29/2025 |
| 1.3.24.68 | 237 | 6/14/2025 |
| 1.3.24.67 | 247 | 5/26/2025 |
| 1.3.24.66 | 401 | 5/5/2025 |
| 1.3.24.65 | 193 | 4/19/2025 |
| 1.3.24.64 | 377 | 3/10/2025 |
| 1.3.24.63 | 235 | 3/9/2025 |
| 1.3.24.62 | 415 | 2/27/2025 |
| 1.3.24.61 | 163 | 2/26/2025 |
| 1.3.24.60 | 226 | 2/10/2025 |
| 1.3.24.59 | 179 | 2/5/2025 |
| 1.3.24.58 | 414 | 1/2/2025 |
| 1.3.24.57 | 216 | 12/28/2024 |
| 1.3.24.56 | 236 | 12/13/2024 |
| 1.3.24.55 | 190 | 11/26/2024 |
| 1.3.24.54 | 356 | 11/14/2024 |
| 1.3.24.53 | 218 | 11/6/2024 |
| 1.3.24.52 | 212 | 10/24/2024 |
| 1.3.24.51 | 155 | 10/23/2024 |
| 1.3.24.50 | 210 | 10/19/2024 |
| 1.3.24.49 | 188 | 9/27/2024 |
| 1.3.24.48 | 199 | 9/22/2024 |
| 1.3.24.47 | 277 | 8/27/2024 |
| 1.3.24.46 | 394 | 8/26/2024 |
| 1.3.24.45 | 354 | 7/16/2024 |
| 1.3.24.44 | 184 | 7/15/2024 |
| 1.3.24.43 | 185 | 7/12/2024 |
| 1.3.24.42 | 214 | 7/8/2024 |
| 1.3.24.41 | 268 | 7/7/2024 |
| 1.3.24.40 | 190 | 7/2/2024 |
| 1.3.24.39 | 217 | 6/27/2024 |
| 1.3.24.38 | 258 | 6/22/2024 |
| 1.3.24.37 | 182 | 6/22/2024 |
| 1.3.24.36 | 190 | 6/20/2024 |
| 1.3.24.35 | 182 | 6/20/2024 |
| 1.3.24.34 | 175 | 6/18/2024 |
| 1.3.24.33 | 184 | 6/11/2024 |
| 1.3.24.32 | 183 | 6/9/2024 |
| 1.3.24.31 | 204 | 5/30/2024 |
| 1.3.24.30 | 173 | 5/27/2024 |
| 1.3.24.29 | 189 | 5/22/2024 |
| 1.3.24.28 | 181 | 5/21/2024 |
| 1.3.24.27 | 171 | 5/20/2024 |
| 1.3.24.26 | 190 | 5/16/2024 |
| 1.3.24.25 | 159 | 5/16/2024 |
| 1.3.24.24 | 196 | 5/15/2024 |
| 1.3.24.23 | 200 | 5/10/2024 |
| 1.3.24.22 | 210 | 5/6/2024 |
| 1.3.24.21 | 180 | 5/6/2024 |
| 1.3.24.20 | 170 | 5/5/2024 |
| 1.3.24.14 | 207 | 4/20/2024 |
| 1.3.24.13 | 179 | 4/19/2024 |
| 1.3.24.12 | 205 | 3/28/2024 |
| 1.3.24.11 | 524 | 3/19/2024 |
| 1.3.24.10 | 188 | 3/6/2024 |
| 1.3.24.9 | 236 | 3/2/2024 |
| 1.3.24.8 | 172 | 2/29/2024 |
| 1.3.24.7 | 191 | 2/22/2024 |
| 1.3.24.6 | 211 | 2/20/2024 |
| 1.3.24.5 | 170 | 2/18/2024 |
| 1.3.24.4 | 183 | 2/8/2024 |
| 1.3.24.3 | 185 | 2/5/2024 |
| 1.3.24.2 | 181 | 2/5/2024 |
| 1.3.24.1 | 195 | 2/5/2024 |
| 1.0.0.3 | 174 | 2/8/2024 |
| 1.0.0.2 | 192 | 2/8/2024 |
| 1.0.0.1 | 244 | 2/5/2024 |
C#界面跨平台开发组件gtksystem-windows-forms