package test.scenegraph.app; import javafx.application.Application; import javafx.stage.Stage; import javafx.scene.Group; import javafx.scene.Scene; import javafx.scene.paint.Color; import javafx.scene.shape.Rectangle; /** * * @author shubov */ public class ShortAppWithoutDependencies31 extends Application { protected final static int width = 650; protected final static int height = 650; Group gr = new Group(); Rectangle rec; public void start(Stage stage) { stage.setWidth(width); stage.setHeight(height); stage.setScene(new Scene(gr)); stage.setVisible(true); //gr.setTranslateX(200); //gr.setTranslateY(200); javafx.application.Platform.runLater(new Runnable() { public void run() { setup(); } }); } public void setup() { Rectangle rec0 = new Rectangle(100, 100, 50, 50); //rec0.setArcHeight(15); //rec0.setArcWidth(15); rec0.setFill(Color.TRANSPARENT); rec0.setStroke(Color.RED); gr.getChildren().add(rec0); rec0.setStrokeWidth(5); rec0.setArcWidth(32.2); rec0.setArcHeight(5.08);//(5.37); } public static void main(String[] args) { javafx.application.Launcher.launch(ShortAppWithoutDependencies31.class, args); } }