在Windows上运行GTK#应用程序 [英] Running GTK# Application on Windows

查看:607
本文介绍了在Windows上运行GTK#应用程序的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我刚刚在Linux Mint 16上使用MonoDevelop编程并构建了GTK#应用程序.我想看看它是否跨平台启用,因此我尝试在Windows 8计算机(具有.NET Framework 4.0的计算机)上运行它),并安装了Mono运行时(包括适用于Windows的GTK#),以便可以在那运行.

I've just programmed and built a GTK# application using MonoDevelop on Linux Mint 16. I wanted to see if it's cross-platform enabled, so I tried to run it on a Windows 8 machine (which has .NET Framework 4.0), and installed Mono runtime (which includes GTK# for Windows) so that it could run over there.

这是问题所在:当我从Windows资源管理器运行可执行文件时,我假定.NET Framework会接管一切,因为什么也没发生.如果从Windows中输入"Mono命令提示符",导航到.exe并键入"mono filename.exe",则可执行文件将运行.

Here's the issue: when I run the executable from Windows Explorer, I assume .NET Framework takes over, because nothing happens. The executable will run if, from within Windows, I enter "Mono command prompt", navigate to the .exe and type "mono filename.exe".

我该怎么做才能使应用程序直接在Windows的文件资源管理器中运行?

What can I do to enable the application to run from within the File explorer directly on Windows?

推荐答案

您无法通过Windows版Mono通过File Explorer启动.exe文件.

You can't make an .exe file be launched from the File Explorer with Mono for Windows.

但是,您可以使用.NET框架启动.NET应用程序. Gtk#库可在MS.NET中工作,它们不依赖于Mono.

What you can do, though, is use the .NET framework to launch your .NET application. Gtk# libraries work in MS.NET, they don't have a dependency on Mono.

这篇关于在Windows上运行GTK#应用程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆