使用 ElementHost 时加载 wpf 控件之前的黑色背景 [英] Black background before loading a wpf controll when using ElementHost

查看:23
本文介绍了使用 ElementHost 时加载 wpf 控件之前的黑色背景的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在带有 ElementHost 的 WinForms 中使用 WPF.当表单加载时,ElementHost 即将加载的地方会出现黑色背景的闪光.这看起来有点糟糕.关于如何摆脱这种情况的任何建议?

I'm using WPF in WinForms with ElementHost. When the form loads, there is a flash of black background where the ElementHost is about to load. This looks kind of bad. Any suggestions on how to get rid of this?

推荐答案

隐藏元素 (Visibility = Hidden) 直到 WinForms 控件完全加载...

Hide the element (Visibility = Hidden) until the WinForms control is fully loaded...

这篇关于使用 ElementHost 时加载 wpf 控件之前的黑色背景的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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