swt 中是否提供 MultiColumn- 资源管理器小部件?

Is MultiColumn- explorer widget available in swt?

因为 windows 提供查看我在图像中附加的列中的多个文件。 是否有类似于 windows 的多列方式可用于 display/arrange 对象的任何 SWT 小部件?

我已经使用过 "Row layout(SWT.Vertical)" 但是如果它有超过 2000 个对象,我在绘画时会遇到一些性能问题。

而 windows 资源管理器如果超过 6000 条数据则不会出现这种性能问题。

我不能使用 table 查看器,因为它把每一行作为一个对象,但根据我的要求,我需要在每个单元格中都有对象

如果 JFace/SWT 中有任何内置小部件可供多列视图资源管理器排列对象,请告诉我。

谢谢

我找不到满足此要求的直接 JFace/SWT 小部件。或许其他高人可以指点一下。

根据您的要求Nebula Gallery Widget NOTE: THIS WIDGET AND ITS API ARE STILL UNDER DEVELOPMENT, as written in its Javadoc

代码如下:

public class Test {
    public static void main(String[] args) {
        Display display = new Display();
        Image itemImage = new Image(display, Program.findProgram("jpg").getImageData()); //$NON-NLS-1$
        Shell shell = new Shell(display);
        shell.setLayout(new FillLayout());

        Gallery gallery = new Gallery(shell, SWT.H_SCROLL | SWT.MULTI | SWT.VIRTUAL);

        // Renderers
        NoGroupRenderer gr = new NoGroupRenderer();
        gr.setMinMargin(2);
        gr.setItemHeight(20);
        gr.setItemWidth(100);
        gr.setAutoMargin(true);
        gallery.setGroupRenderer(gr);

        ListItemRenderer ir = new ListItemRenderer();
        gallery.setItemRenderer(ir);

        GalleryItem group = new GalleryItem(gallery, SWT.NONE);

        for (int i = 0; i < 20000; i++) {
            GalleryItem item = new GalleryItem(group, SWT.NONE);
            if (itemImage != null) {
                item.setImage(itemImage);
            }
            item.setText("Item " + i); //$NON-NLS-1$
        }

        shell.pack();
        shell.open();

        while (!shell.isDisposed()) {
            if (!display.readAndDispatch())
                display.sleep();
        }
        display.dispose();
    }
}

输出: