Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[platform-swt-dev] How to print two composites into a picture?

Hello,
 
I have an editor and its property view. I want to snapshot the two windows into one picture.
I know how to print one composite, for example,
       Display display = Display.getCurrent();
        Image image = new Image(display, composite.getBounds());
        gc = new GC(image);
        composite.print(gc);
        gc.dispose();
        ImageLoader loader = new ImageLoader();
        loader.data = "" ImageData[] {image.getImageData()};
        loader.save(fileName, format);
 
However, I have no idea about how to print two composites into one picture file.
Could anyone help me?
 
Best regards,
Hua



Back to the top