Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我正在开发一个在 Aero Glass 上显示文本的应用程序。为了使其可读,我使用了 OuterGlowBitmapEffect,但是,正如这里所描述的,这在 .NET 4 中不再可能,并且 DropShadowEffect 也不适用于 Glass。
在寻找解决方案时,我在 DWMApi 中遇到了原生 DrawThemeTextEx,但我发现的所有示例都是针对 WinForms 而不是 WPF。
那么如何在 WPF 中使用它呢?
谢谢
我也在尝试使用 DrawThemeTextEx 但是我找不到任何使用它以及正确的系统字体的示例。
.NET 4 中的以下效果接近 Aero 玻璃文本并替换了 BitmapEffects。
<Decorator> <Decorator.Effect> <DropShadowEffect BlurRadius="10" Color="White" ShadowDepth="0" /> </Decorator.Effect> </Decorator>