List of usage examples for javafx.scene Group Group
public Group()
From source file:Main.java
@Override public void start(Stage primaryStage) { primaryStage.setTitle("Shapes"); Group root = new Group(); Scene scene = new Scene(root, 300, 300, Color.WHITE); Ellipse bigCircle = new Ellipse(20, 20); bigCircle.setCenterX(20);/*from w w w . j ava 2s .com*/ bigCircle.setCenterY(20); bigCircle.setRadiusX(10); bigCircle.setRadiusY(10); System.out.println(bigCircle.getRadiusY()); root.getChildren().add(bigCircle); primaryStage.setScene(scene); primaryStage.show(); }
From source file:Main.java
@Override public void start(Stage primaryStage) { primaryStage.setTitle("Shapes"); Group root = new Group(); Scene scene = new Scene(root, 300, 300, Color.WHITE); Ellipse bigCircle = new Ellipse(20, 20); bigCircle.setCenterX(20);//ww w.j a va 2s . c o m bigCircle.setCenterY(20); bigCircle.setRadiusX(10); bigCircle.setRadiusY(10); System.out.println(bigCircle.getCenterY()); root.getChildren().add(bigCircle); primaryStage.setScene(scene); primaryStage.show(); }
From source file:Main.java
@Override public void start(Stage primaryStage) { primaryStage.setTitle("Shapes"); Group root = new Group(); Scene scene = new Scene(root, 300, 300, Color.WHITE); Ellipse bigCircle = new Ellipse(20, 20, 30, 30); bigCircle.setCenterX(20);//from w w w. j a va 2s .c o m bigCircle.setCenterY(20); bigCircle.setRadiusX(10); bigCircle.setRadiusY(10); System.out.println(bigCircle.centerXProperty().doubleValue()); root.getChildren().add(bigCircle); primaryStage.setScene(scene); primaryStage.show(); }
From source file:Main.java
@Override public void start(Stage primaryStage) { primaryStage.setTitle("Shapes"); Group root = new Group(); Scene scene = new Scene(root, 300, 300, Color.WHITE); Ellipse bigCircle = new Ellipse(20, 20); bigCircle.setCenterX(20);//from w ww .ja va 2s .c om bigCircle.setCenterY(20); bigCircle.setRadiusX(10); bigCircle.setRadiusY(10); System.out.println(bigCircle.radiusXProperty()); root.getChildren().add(bigCircle); primaryStage.setScene(scene); primaryStage.show(); }
From source file:Main.java
@Override public void start(Stage primaryStage) { primaryStage.setTitle("Shapes"); Group root = new Group(); Scene scene = new Scene(root, 300, 300, Color.WHITE); Ellipse bigCircle = new Ellipse(20, 20); bigCircle.setCenterX(20);/*from ww w.j a v a 2 s . c om*/ bigCircle.setCenterY(20); bigCircle.setRadiusX(10); bigCircle.setRadiusY(10); System.out.println(bigCircle.centerYProperty().doubleValue()); root.getChildren().add(bigCircle); primaryStage.setScene(scene); primaryStage.show(); }
From source file:Main.java
@Override public void start(Stage primaryStage) { primaryStage.setTitle("Shapes"); Group root = new Group(); Scene scene = new Scene(root, 300, 300, Color.WHITE); Ellipse bigCircle = new Ellipse(20, 20); bigCircle.setCenterX(20);// w w w.j a v a 2s . co m bigCircle.setCenterY(20); bigCircle.setRadiusX(10); bigCircle.setRadiusY(10); System.out.println(bigCircle.getRadiusX()); root.getChildren().add(bigCircle); primaryStage.setScene(scene); primaryStage.show(); }
From source file:Main.java
@Override public void start(Stage primaryStage) { primaryStage.setTitle("Shapes"); Group root = new Group(); Scene scene = new Scene(root, 300, 300, Color.WHITE); Ellipse bigCircle = new Ellipse(20, 20); bigCircle.setCenterX(20);//from w ww.java2 s . co m bigCircle.setCenterY(20); bigCircle.setRadiusX(10); bigCircle.setRadiusY(10); System.out.println(bigCircle.getCenterX()); root.getChildren().add(bigCircle); primaryStage.setScene(scene); primaryStage.show(); }
From source file:Main.java
@Override public void start(Stage primaryStage) { primaryStage.setTitle("Shapes"); Group root = new Group(); Scene scene = new Scene(root, 300, 300, Color.WHITE); Ellipse bigCircle = new Ellipse(20, 20); bigCircle.setCenterX(20);//from ww w . j a v a 2 s . c om bigCircle.setCenterY(20); bigCircle.setRadiusX(10); bigCircle.setRadiusY(10); System.out.println(bigCircle.radiusYProperty()); root.getChildren().add(bigCircle); primaryStage.setScene(scene); primaryStage.show(); }
From source file:Main.java
@Override public void start(Stage primaryStage) { Group root = new Group(); Scene scene = new Scene(root, 300, 250); TextField textBox = new TextField(); textBox.setPromptText("Write here"); // Register an event handler for a single node and a specific event type scene.addEventHandler(DragEvent.DRAG_ENTERED, new EventHandler<DragEvent>() { public void handle(DragEvent e) { System.out.println("drag enter"); }//ww w .j a va 2 s .com }); root.getChildren().add(textBox); primaryStage.setScene(scene); primaryStage.show(); }
From source file:Main.java
@Override public void start(Stage primaryStage) { Group root = new Group(); Scene scene = new Scene(root, 300, 250); TextField textBox = new TextField(); textBox.setPromptText("Write here"); // Register an event filter for a single node and a specific event type scene.addEventFilter(MouseEvent.MOUSE_CLICKED, new EventHandler<MouseEvent>() { public void handle(MouseEvent e) { System.out.println("mouse clicked"); };// w w w.j a va2 s. c om }); root.getChildren().add(textBox); primaryStage.setScene(scene); primaryStage.show(); }