开发者

flickering of image in SWT

I am building an SWT application, I have used a ScrolledComposite and a Composite inside that. This has a few more buttons and checkboxes . All this is inside a Composite.

Now I tried to put this main composite in the tab. It worked fine but the image flickers a lot even if I don't scroll or resize. If I put this main composite inside a shell, its working perfect without any flicker.

Why is this开发者_高级运维 happening?


Did you set the SWT.DOUBLE_BUFFERED style bit on your Composite? That might fix it.


Write SWT.DOUBLE_BUFFERED in declaration

Example:

scrolledComposite = new ScrolledComposite(parent, SWT.V_SCROLL | SWT.DOUBLE_BUFFERED);
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜