public static StdImage getImage(JComponent component) {
		StdImage offscreen = null;
		synchronized (component.getTreeLock()) {
			Graphics2D gc = null;
			try {
				Rectangle bounds = component.getVisibleRect();
				offscreen = StdImage.createTransparent(component.getGraphicsConfiguration(), bounds.width, bounds.height);
				gc = offscreen.getGraphics();
				gc.translate(-bounds.x, -bounds.y);
				component.paint(gc);
			} catch (Exception exception) {
				Log.error(exception);
			} finally {
				if (gc != null) {
					gc.dispose();
				}
			}
		}
		return offscreen;
	}