简体   繁体   English

如何使用MetroFramework为NumericUpDown设置主题

[英]How to theme NumericUpDown with MetroFramework

I'm making a WindowsForm project, and I've ran into a pretty major issue (for my application at least) with MetroFramework. 我正在制作WindowsForm项目,但是MetroFramework遇到了一个相当大的问题(至少对于我的应用程序而言)。

When I use NumericUpDown it appears the same as the normal WindowsForm theme. 当我使用NumericUpDown时,它看起来与普通的WindowsForm主题相同。 I tried installing Mahapps.metro, but it didn't show any new tools, and it didn't change how it looked when applied to the form. 我尝试安装Mahapps.metro,但没有显示任何新工具,也没有更改应用于表单时的外观。

How do I make it so that the tool follows the Metro theme, and doesn't just look like the default WindowsForm tool? 如何使该工具遵循Metro主题,而不仅仅是看起来像默认的WindowsForm工具?

Clarification: I'm using WindowsForms and need the theme of Mahapps NumericUpDown in my project 澄清:我正在使用WindowsForms,并且在我的项目中需要Mahapps NumericUpDown的主题

How do I make it so that the tool follows the Metro theme? 如何使它遵循Metro主题?
Clarification: I'm using WindowsForms and need the theme of Mahapps NumericUpDown in my project 澄清:我正在使用WindowsForms,并且在我的项目中需要Mahapps NumericUpDown的主题

You can't. 你不能

MahApps Metro is for WPF not WinForms. MahApps Metro是WPF 而不是 WinForms。 The NumericUpDown control is a WinForms control and like other WinForms controls, doesn't support skinning . NumericUpDown控件是一个WinForms控件,与其他WinForms控件一样, 它不支持skinning

You will need to create a WPF app not WinForms. 您将需要创建一个WPF应用程序而不是WinForms。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM