新WPF功能区的深色背景变成渐变?

发布于 2024-09-30 14:43:50 字数 309 浏览 6 评论 0原文

我正在 Windows 7 中使用新版本的 MS WPF 功能区(版本 MS WPF 功能区 3.5.40729.1),并且我正在尝试更改功能区的背景。如果我使用浅色背景颜色,一切看起来都很好。

但例如,如果我选择“黑色”,则会显示白色渐变和黑色。似乎不可能去除白色并简单地使用黑色背景。而且它看起来很丑,尤其是当每个 Textcolor 通常都是白色时。 (选项卡标题变为白色背景并且不再可读)

在示例中,(我将所有内容保留原样)如果我直接在功能区的属性中设置Background = Black,效果是相同的。

我必须设置或做什么才能消除白色渐变颜色?

I am using the new Version of MS WPF Ribbon (Version MS WPF Ribbon 3.5.40729.1) with Windows 7 and I am trying to change the Background of the Ribbon. Everything looks fine if I use light background colors.

But e.g. if I choose "Black" a white gradient is shown with the black. It does not seem to be possible to remove the white and simply have a black background. And it looks ugly, especially when every Textcolor normally is white. (Tabheaders get white background and are not readable anymore)

In the samples, (I leave everything as is) if I set Background=Black directly in the ribbon's property, the effect is the same.

What do I have to set or do to get rid of the white gradient color?

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

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

发布评论

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

评论(1

鼻尖触碰 2024-10-07 14:43:50

RibbonGroup 模板中有硬编码的光泽效果。它很蹩脚,但摆脱它的唯一方法是覆盖 RibbonGroup 的模板。如果您有 Blend,只需提取模板并撕掉有问题的 LinearGradientBrush

There's a hard-coded gloss effect in the RibbonGroup template. It's lame, but the only way to get rid of it is to override the temlate for RibbonGroup. If you have Blend, just extract the template and rip out the offending LinearGradientBrush.

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