WPF应用程序边界更改为航空 [英] WPF application border change to aero

查看:87
本文介绍了WPF应用程序边界更改为航空的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,

我正在WPF和c#上创建应用程序,这将安装在一些具有经典主题的Windows服务器上.我希望应用的外观与使用Aero主题的Windows 7(所有控件,Aero玻璃和边框)相同.

Hi everyone,

I am creating app on WPF and c#, this is going to be installed on some windows server with classic theme. I want the look n feel of app to be same as the windows 7 using aero theme (all controls, the aero glass and the border). How can i do this, thinking that the aero theme has to be added in app?

推荐答案

您必须在项目中添加对"PresentationFramework.Aero"的引用,我该怎么做呢? ,然后将其添加到您的App.Xaml文件中:

You have to add a reference to "PresentationFramework.Aero" in your project, and then add this to your App.Xaml file:

<Application.Resources>
    <ResourceDictionary>         
        <ResourceDictionary.MergedDictionaries>
            <ResourceDictionary Source="/PresentationFramework.Aero;component/themes/aero.normalcolor.xaml"/>
        </ResourceDictionary.MergedDictionaries>
    <ResourceDictionary>
</Application.Resources>



您可以在Google上轻松找到它.



You could have easily found this on google.


以上代码仅适用于控件,即使添加了表示框架作为参考也是如此.如何获得经典主题的航空玻璃和边框?
the above code only works with controls even if the presentation framework is added as reference. How can i get aero glass and border in classic theme?


这篇关于WPF应用程序边界更改为航空的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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