C#Panel.BackgroundImage +透明控件=闪烁? [英] C# Panel.BackgroundImage + transparent Controls = flickering?
本文介绍了C#Panel.BackgroundImage +透明控件=闪烁?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我有一个Panel
和一个jpg BackgroundImage
(带有BackgroundImageLayout = Stretch
).
在面板上是Controls
,我添加了带有PictureBoxes
,该PNG具有透明的边框.显示此内容不会带来任何问题,但是移动PictureBoxes
确实可以.(移动框是可拖动的).
I've got a Panel
with a jpg BackgroundImage
(with BackgroundImageLayout = Stretch
).
On the panel it's Controls
I add some PictureBoxes
with a PNG which has transparent borders. Displaying this doesn't give any problems, but moving (the boxes are draggable) the PictureBoxes
does.
结果是移动的PictureBox
干扰" BackgroundImage
并降低了性能.我拖动框的速度越快,对BackgroundImage
的干扰就越大,反之亦然.
The result is that the moving PictureBox
"disturbs" the BackgroundImage
and slows down performance. The faster I drag the box, the more it disturbs the BackgroundImage
, and vice versa.
如何解决这个问题?