Pane : text node not render in Pane

XMLWordPrintable

    • Type: Bug
    • Resolution: Not an Issue
    • Priority: P3
    • 8
    • Affects Version/s: 7u6
    • Component/s: javafx

      Run this code to reproduce the issue:

          @Override
          public void start(Stage primaryStage) {
              BorderPane root = new BorderPane();
              
              Pane pane = new Pane();
              
              pane.getChildren().add(new Text("Text"));
              
              root.setCenter(pane);
              
              Scene scene = new Scene(root, 500, 500);
              primaryStage.setTitle(VersionInfo.getRuntimeVersion());
              primaryStage.setScene(scene);
              primaryStage.show();
          }

      The code creates an empty scene. If the line "Pane pane = new Pane();" is changed to "Pane pane = new StackPane();" the text will be shown on the screen.

            Assignee:
            Eva Krejčířová (Inactive)
            Reporter:
            Sergey Lugovoy (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported: