Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8115287

OEL. Popup has white area behind it

    XMLWordPrintable

Details

    • Bug
    • Resolution: Not an Issue
    • P3
    • None
    • 8
    • javafx
    • OEL 6.4, jdk1.8.0b98 x64

    Description

      To reproduce open any menu.

      import com.sun.javafx.runtime.VersionInfo;
      import javafx.application.Application;
      import javafx.scene.Scene;
      import javafx.scene.control.*;
      import javafx.scene.layout.VBox;
      import javafx.stage.Stage;

      public class MenuBarApp extends Application {

          public static void main(String[] args) {
              launch(args);
          }

          @Override
          public void start(Stage stage) throws Exception {
              stage.setTitle(VersionInfo.getRuntimeVersion());
              stage.setScene(createScene());
              stage.show();
          }

          private Scene createScene() {

              Menu file = new Menu("File");
              file.getItems().add(new MenuItem("New"));
              file.getItems().add(new MenuItem("Open"));

              Menu edit = new Menu("Edit");
              edit.getItems().add(new MenuItem("Copy"));
              edit.getItems().add(new MenuItem("Paste"));

              MenuBar menuBar = new MenuBar();
              for (int i = 0; i < 3; i++) {
                  Menu menu = new Menu("Menu " + i);
                  menuBar.getMenus().add(menu);
                  for (int j = 0; j < 5; j++) {
                      MenuItem menuItem = new MenuItem("Menu item " + j);
                      menu.getItems().add(menuItem);
                  }
              }

              menuBar.getMenus().add(file);
              menuBar.getMenus().add(edit);

              VBox root = new VBox(5);
              root.getChildren().add(menuBar);

              return new Scene(root, 1200, 800);
          }
      }

      Attachments

        Activity

          People

            art Artem Ananiev (Inactive)
            dzinkevi Dmitry Zinkevich (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:
              Imported: