A brief introduction to the problem of C#winForm form flickering

黄舟
Release: 2017-03-25 13:23:32
Original
1464 people have browsed it

The editor below will bring you a brief discussion on the problem of winForm form flickeringC#. The editor thinks it is quite good, so I will share it with you now and give it as a reference for everyone. Let’s follow the editor and take a look.

Add the following code to ConstructionFunction:

this.DoubleBuffered = true;//设置本窗体

SetStyle(ControlStyles.UserPaint, true);

SetStyle(ControlStyles.AllPaintingInWmPaint, true); // 禁止擦除背景.

SetStyle(ControlStyles.DoubleBuffer, true); // 双缓冲

//SetStyle(ControlStyles.DoubleBuffer | ControlStyles.OptimizedDoubleBuffer | ControlStyles.AllPaintingInWmPaint, true);

//UpdateStyles();
Copy after login

The above is the detailed content of A brief introduction to the problem of C#winForm form flickering. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!