wpf用户控件阻止样式

发布于 2024-10-07 07:27:15 字数 138 浏览 0 评论 0原文

我正在制作一个 wpf 类库,其中包含一些用户控件。我的一些控件没有样式,因此托管我的控件的应用程序中定义的任何样式都会应用于我的控件。这会产生糟糕的外观组合。

我需要我的用户控件指定所有控件都需要使用默认的 wpf 外观,无论父窗体正在做什么。

I am making a wpf class library with some user controls in it. Some of my controls are not styled and so whatever style is defined in the app that hosts my control is applied to my controls. This creates a bad mix of looks.

I need my user control to specify that all controls need to use just the default wpf look and feel regardless of what the parent form is doing.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

过期情话 2024-10-14 07:27:15

尝试样式=“{x:null}”

try style="{x:null}"

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文