import javafx.application.*; import javafx.animation.*; import javafx.util.*; import javafx.stage.*; import javafx.scene.*; import javafx.scene.paint.*; import javafx.scene.shape.*; public class ScaledCircleBug extends Application { public void start(Stage stage) { Circle c = new Circle(250, 250, 50); c.setStrokeWidth(25); c.setStroke(Color.BLUE); c.setFill(Color.GREEN); c.setScaleX(2.0); KeyValue kv1 = new KeyValue(c.rotateProperty(), 360.0); KeyFrame kf = new KeyFrame(new Duration(1000), kv1); Timeline t = new Timeline(kf); t.setCycleCount(Timeline.INDEFINITE); t.play(); Scene scene = new Scene(new Group(c), 500, 500); stage.setScene(scene); stage.setVisible(true); } public static void main(String argv[]) { launch(ScaledCircleBug.class, argv); } }