public void paint(GC gc, int width, int height) {
	if (!example.checkAdvancedGraphics()) return;
	Device device = gc.getDevice();

	Pattern pattern = null;
	if (background.getBgColor1() != null) {
		gc.setBackground(background.getBgColor1());
	} else if (background.getBgImage() != null) {
		pattern = new Pattern(device, background.getBgImage());
		gc.setBackgroundPattern(pattern);
	}
	
	gc.setAntialias(SWT.ON);
	gc.setAlpha(alphaSpinner.getSelection());
	
	// rotate on center
	Transform transform = new Transform(device);
	transform.translate(width/2, height/2);
	transform.rotate(-angle);
	transform.translate(-width/2, -height/2);
	gc.setTransform(transform);
	transform.dispose();
	
	// choose the smallest between height and width
	int diameter = (height < width) ? height : width;
	
	Path path = new Path(device);
	path.addArc((width-diameter/5)/2, (height-diameter/5)/2, diameter/5, diameter/5, 0, 360);
	path.addArc(5*(width-diameter/8)/12, 4*(height-diameter/8)/12, diameter/8, diameter/8, 0, 360);
	path.addArc(7*(width-diameter/8)/12, 8*(height-diameter/8)/12, diameter/8, diameter/8, 0, 360);
	path.addArc(6*(width-diameter/12)/12, 3*(height-diameter/12)/12, diameter/12, diameter/12, 0, 360);
	path.addArc(6*(width-diameter/12)/12, 9*(height-diameter/12)/12, diameter/12, diameter/12, 0, 360);
	path.addArc(11.5f*(width-diameter/18)/20, 5*(height-diameter/18)/18, diameter/18, diameter/18, 0, 360);	
	path.addArc(8.5f*(width-diameter/18)/20, 13*(height-diameter/18)/18, diameter/18, diameter/18, 0, 360);
	path.addArc(62f*(width-diameter/25)/100, 32*(height-diameter/25)/100, diameter/25, diameter/25, 0, 360);
	path.addArc(39f*(width-diameter/25)/100, 67*(height-diameter/25)/100, diameter/25, diameter/25, 0, 360);
		
	gc.fillPath(path);
	path.dispose();
			
    if (pattern != null) pattern.dispose();
}