Bug 253673 Snippet207 doesn't rotate 45
The snippet says it is rotating 45 but this is not the case because Math.cos() and Math.sin() use radians and not degrees. The snippet has to look like this to really rotate 45 one needs to pass "45 * Math.PI / 180" to the 2 functions.
examples/org.eclipse.swt.snippets/src/org/eclipse/swt/snippets/Snippet207.java
Transform transform = new Transform(display);
				
				
				
				
				
				transform.setElements(-1, 0, 0, 1, 0 ,0);
				gc.setTransform(transform);
				gc.drawImage(image, -1*x-rect.width, y);
				
				x = 30; y += rect.height + 30;
				
				 
				transform.setElements(1, 0, 0, -1, 0, 0);
				gc.setTransform(transform);
				gc.drawImage(image, x, -1*y-rect.height);
				
				x += rect.width + 30;
				
					
				transform.setElements(-1, 0, 0, -1, 0, 0);
				gc.setTransform(transform);
				gc.drawImage(image, -1*x-rect.width, -1*y-rect.height);
				
				x = 30; y += rect.height + 30;
				
				
				transform.setElements(1, 0, -1, 1, 0, 0);
				gc.setTransform(transform);