/* * Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. */ import javafx.application.Application; import javafx.scene.Group; import javafx.scene.Scene; import javafx.scene.paint.Color; import javafx.scene.shape.Rectangle; import javafx.stage.Stage; /** * * @author Alexander Kouznetsov */ public class Bug extends Application { public static void main(String[] args) { launch(args); } @Override public void start(Stage stage) throws Exception { Rectangle r = new Rectangle(); // r.setFill(Color.GREEN); // r.setStroke(Color.RED); r.setStyle("-fx-fill: green; -fx-stroke: red;"); r.setWidth(100); r.setHeight(100); Scene scene = new Scene(new Group(r)); stage.setScene(scene); stage.setVisible(true); } }