I’ve seen the following code to enable double buffering on a winform:
// Activates double buffering this.SetStyle(ControlStyles.DoubleBuffer | ControlStyles.OptimizedDoubleBuffer | ControlStyles.UserPaint | ControlStyles.AllPaintingInWmPaint, true); this.UpdateStyles();
Is this different in any way from simply setting Form.DoubleBuffering = true?
Control.DoubleBufferingperformsso your code sets
ControlStyles.UserPaintas well (which probably has no effect at this point).