How to scroll a scrolled composite using mouse wheels in SWT
问题 I would like to know if it is possible to scroll a ScrolledComposite using mouse wheels. By default it is not working. 回答1: Apparently, it is necessary to create mouse wheel listener for your composite. You can use something like this as the basis: scrolledComposite = new ScrolledComposite(parent, SWT.H_SCROLL | SWT.V_SCROLL); GridData scrollGridData = new GridData(SWT.FILL, SWT.FILL, true, true); scrolledComposite.setLayoutData(scrollGridData); layout = new GridLayout(); scrolledComposite