Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is there a way to enable double buffering for SWT components?

In the Eclipse RCP application I'm building, I noticed that when I rebuild parts of the GUI (by adding/removing controls), the GUI gets updated and redrawn immediately upon each modification, which causes a flicker effect.

Is there a way to enable double buffering, so that the GUI refresh will happen only once at the end of the event dispatch cycle?

like image 480
Peter Walser Avatar asked Dec 05 '25 15:12

Peter Walser


1 Answers

Try:

Control#setRedraw(false);
...
modify
...
Control#setRedraw(true);
like image 94
Kire Haglin Avatar answered Dec 08 '25 04:12

Kire Haglin



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!