public void setWindowOpaque(Window window, boolean isOpaque) {
		// prevent setting if not supported
		if(!isTranslucencyCapable(window.getGraphicsConfiguration()) ||
				!isTranslucencySupported(Translucency.PERPIXEL_TRANSLUCENT, window.getGraphicsConfiguration().getDevice())) {
			return;
		}
		final Color background = window.getBackground();
		final int alpha = isOpaque ? OPAQUE : NOT_OPAQUE;
		window.setBackground(new Color(background.getRed(), background.getGreen(), background.getBlue(), alpha));
	}