List of usage examples for javafx.scene.layout AnchorPane getChildren
@Override
public ObservableList<Node> getChildren()
From source file:ijfx.ui.canvas.FxCanvasTester.java
@Override public void start(Stage primaryStage) { final SCIFIO scifio = new SCIFIO(); MenuBar menuBar = new MenuBar(); InputControl parameterInput = null;/*from w w w. j ava2 s . c o m*/ try { System.setProperty("imagej.legacy.sync", "true"); //reader.getContext().inject(this); ImageJ imagej = new ImageJ(); context = imagej.getContext(); CommandInfo command = imagej.command().getCommand(GaussianBlur.class); CommandModuleItem input = command.getInput("sigma"); Class<?> type = input.getType(); if (type == double.class) { type = Double.class; } context.inject(this); GaussianBlur module = new GaussianBlur(); imagej.ui().showUI(); //reader = scifio.initializer().initializeReader("./stack.tif"); commandService.run(OpenFile.class, true, new HashMap<String, Object>()); menuBar = new MenuBar(); menuService.createMenus(new FxMenuCreator(), menuBar); ObjectMapper mapper = new ObjectMapper(); SimpleModule simpleModule = new SimpleModule("ModuleSerializer"); // simpleModule.addSerializer(ModuleItem<?>.class,new ModuleItemSerializer()); simpleModule.addSerializer(ModuleInfo.class, new ModuleSerializer()); simpleModule.addSerializer(ModuleItem.class, new ModuleItemSerializer()); mapper.configure(DeserializationFeature.UNWRAP_ROOT_VALUE, true); mapper.enable(SerializationFeature.INDENT_OUTPUT); mapper.registerModule(simpleModule); mapper.writeValue(new File("modules.json"), moduleService.getModules()); } catch (Exception ex) { ImageJFX.getLogger(); } //imageView.fitImageToScreen(); Button reset = new Button("Reset"); reset.setOnAction(event -> update()); BorderPane pane = new BorderPane(); Button test = new Button("Test"); AnchorPane root = new AnchorPane(); root.getChildren().add(pane); root.getStylesheets().add(ArcMenu.class.getResource("arc-default.css").toExternalForm()); root.getStylesheets().add(ImageJFX.class.getResource(("flatterfx.css")).toExternalForm()); AnchorPane.setTopAnchor(pane, 0.0); AnchorPane.setBottomAnchor(pane, 0.0); AnchorPane.setLeftAnchor(pane, 0.0); AnchorPane.setRightAnchor(pane, 0.0); pane.setTop(menuBar); HBox vbox = new HBox(); vbox.getChildren().addAll(reset, test, parameterInput); vbox.setSpacing(10); vbox.setPadding(new Insets(10, 10, 10, 10)); // update(); pane.setCenter(ImageWindowContainer.getInstance()); // pane.setPrefSize(Region.USE_PREF_SIZE, Region.USE_PREF_SIZE); pane.setBottom(vbox); Scene scene = new Scene(root, 600, 600); test.setOnAction(event -> { test(); }); primaryStage.setTitle("ImageCanvasTest"); primaryStage.setScene(scene); primaryStage.show(); }
From source file:com.toyota.carservice.config.config2.java
public Object loadAnchorPane(AnchorPane ap, String a) { try {/* w w w .ja va 2 s . c o m*/ FXMLLoader p = new FXMLLoader(getClass().getResource("/com/toyota/carservice/view/" + a)); ap.getChildren().setAll((AnchorPane) p.load()); return p.getController(); } catch (IOException e) { e.printStackTrace(); } return null; }
From source file:Main.java
@Override public void start(final Stage stage) throws Exception { fonts = Font.getFamilies().toArray(fonts); pagination = new Pagination(fonts.length / itemsPerPage(), 0); pagination.setPageFactory((Integer pageIndex) -> createPage(pageIndex)); AnchorPane anchor = new AnchorPane(); AnchorPane.setTopAnchor(pagination, 10.0); AnchorPane.setRightAnchor(pagination, 10.0); AnchorPane.setBottomAnchor(pagination, 10.0); AnchorPane.setLeftAnchor(pagination, 10.0); anchor.getChildren().addAll(pagination); Scene scene = new Scene(anchor, 400, 450); stage.setScene(scene);//from w ww. j a v a 2s . c o m stage.show(); }
From source file:Main.java
@Override public void start(final Stage stage) throws Exception { pagination = new Pagination(28, 0); pagination.setPageFactory((Integer pageIndex) -> { if (pageIndex >= textPages.length) { return null; } else {//from ww w . ja v a 2s.c om return createPage(pageIndex); } }); AnchorPane anchor = new AnchorPane(); AnchorPane.setTopAnchor(pagination, 10.0); AnchorPane.setRightAnchor(pagination, 10.0); AnchorPane.setBottomAnchor(pagination, 10.0); AnchorPane.setLeftAnchor(pagination, 10.0); anchor.getChildren().addAll(pagination); Scene scene = new Scene(anchor, 400, 250); stage.setScene(scene); stage.setTitle("PaginationSample"); stage.show(); }
From source file:Main.java
private AnchorPane addAnchorPane(GridPane grid) { AnchorPane anchorpane = new AnchorPane(); Button buttonSave = new Button("Save"); Button buttonCancel = new Button("Cancel"); HBox hb = new HBox(); hb.setPadding(new Insets(0, 10, 10, 10)); hb.setSpacing(10);/*from ww w .j av a2 s . co m*/ hb.getChildren().addAll(buttonSave, buttonCancel); anchorpane.getChildren().addAll(grid, hb); // Anchor buttons to bottom right, anchor grid to top AnchorPane.setBottomAnchor(hb, 8.0); AnchorPane.setRightAnchor(hb, 5.0); AnchorPane.setTopAnchor(grid, 10.0); return anchorpane; }
From source file:de.micromata.mgc.javafx.launcher.gui.AbstractConfigDialog.java
private Tab createTab(LocalSettingsConfigModel configModel, Pair<Pane, ? extends AbstractConfigTabController<?>> wc) { AbstractConfigTabController<?> contrl = wc.getSecond(); contrl.setConfigDialog(this); Pane tabPane = wc.getFirst();/*w w w . j a v a2s. c o m*/ contrl.setTabPane(tabPane); Tab tabB = new Tab(); AnchorPane tabContentPane = new AnchorPane(); tabContentPane.setMaxHeight(Integer.MAX_VALUE); // tabContentPane.setPrefHeight(500); FeedbackPanel feedback = new FeedbackPanel(); feedback.setPrefHeight(100); feedback.setMinHeight(100); FXEvents.get().addEventHandler(this, feedback, FeedbackPanelEvents.CLEAR, event -> { feedback.clearMessages(); }); contrl.setFeedback(feedback); tabContentPane.getChildren().add(tabPane); tabContentPane.getChildren().add(feedback); AnchorPane.setTopAnchor(tabPane, 2.0); AnchorPane.setRightAnchor(tabPane, 0.0); AnchorPane.setLeftAnchor(tabPane, 0.0); AnchorPane.setBottomAnchor(tabPane, 70.0); AnchorPane.setBottomAnchor(feedback, 0.0); tabB.setContent(tabContentPane); AnchorPane.setTopAnchor(tabContentPane, 0.0); AnchorPane.setRightAnchor(tabContentPane, 0.0); AnchorPane.setLeftAnchor(tabContentPane, 0.0); AnchorPane.setBottomAnchor(tabContentPane, 0.0); Node scrollPane = tabPane.getChildren().get(0); AnchorPane.setTopAnchor(scrollPane, 0.0); AnchorPane.setRightAnchor(scrollPane, 0.0); AnchorPane.setLeftAnchor(scrollPane, 0.0); AnchorPane.setBottomAnchor(scrollPane, 0.0); configurationTabs.getTabs().add(tabB); tabController.add(contrl); contrl.setTab(tabB); ((ModelController) contrl).setModel(configModel); contrl.initializeWithModel(); contrl.addToolTips(); tabB.setText(contrl.getTabTitle()); contrl.registerValMessageReceivers(); return tabB; }
From source file:main.Content.java
public void showTreeView() { try {//from w w w . j ava 2 s. c o m FXMLLoader loader = new FXMLLoader(); loader.setLocation(Main.class.getResource("view/TreePane.fxml")); AnchorPane activityPaneOverview = (AnchorPane) loader.load(); TreeViewController controller = loader.getController(); ScrollPane scrollPane = new ScrollPane(); controller.setMainApp(this); controller.setTableData(data); controller.startTreeView(); TreeView<String> treeView = controller.getTree(); scrollPane.setContent(treeView); treeView.autosize(); activityPaneOverview.getStylesheets() .add(Main.class.getResource("view/DarkTheme.css").toExternalForm()); activityPaneOverview.getChildren().add(scrollPane); activityPaneOverview.setTopAnchor(scrollPane, 10.0); activityPaneOverview.setLeftAnchor(scrollPane, 10.0); activityPaneOverview.setRightAnchor(scrollPane, 10.0); activityPaneOverview.setBottomAnchor(scrollPane, 10.0); scrollPane.setFitToHeight(true); scrollPane.setFitToWidth(true); rootLayout.setLeft(activityPaneOverview); System.out.println("showTreeOveerview u therrit" + index); } catch (IOException e) { e.printStackTrace(); } }
From source file:io.uploader.drive.auth.webbrowser.SimpleBrowserImpl.java
public SimpleBrowserImpl(Stage stage, String url) throws IOException { super();/*ww w.j a va 2 s . c om*/ Preconditions.checkNotNull(stage); this.stage = stage; stage.setTitle("Drive Uploader - Authentication"); UiUtils.setStageAppSize(stage); Scene scene = new Scene(new Group()); AnchorPane root = new AnchorPane(); final WebView browser = new WebView(); webEngine = browser.getEngine(); /* Menu settingsMenu = new Menu ("Settings") ; MenuItem proxy = new MenuItem ("Proxy") ; settingsMenu.getItems().add(proxy) ; MenuBar menuBar = new MenuBar () ; menuBar.getMenus().add(settingsMenu) ; proxy.setOnAction(new EventHandler<ActionEvent> () { @Override public void handle(ActionEvent event) { try { ProxySettingDialog dlg = new ProxySettingDialog (stage, Configuration.INSTANCE) ; dlg.showDialog(); } catch (IOException e) { logger.error("Error occurred while opening the proxy setting dialog", e); } }});*/ FXMLLoader mainMenuLoader = new FXMLLoader(getClass().getResource("/fxml/MainMenu.fxml")); VBox mainMenuBar = (VBox) mainMenuLoader.load(); AnchorPane.setTopAnchor(mainMenuBar, 0.0); AnchorPane.setLeftAnchor(mainMenuBar, 0.0); AnchorPane.setRightAnchor(mainMenuBar, 0.0); MainMenuController mainMenuController = mainMenuLoader.<MainMenuController>getController(); mainMenuController.setOwner(stage); mainMenuController.setConfiguration(Configuration.INSTANCE); mainMenuController.hideAccountMenu(true); ScrollPane scrollPane = new ScrollPane(); scrollPane.setContent(browser); scrollPane.setFitToWidth(true); scrollPane.setFitToHeight(true); if (StringUtils.isNotEmpty(url)) { goTo(url); } if (DriveUploader.isMacOsX()) { AnchorPane.setTopAnchor(scrollPane, 5.0); } else { AnchorPane.setTopAnchor(scrollPane, 35.0); } AnchorPane.setLeftAnchor(scrollPane, 5.0); AnchorPane.setRightAnchor(scrollPane, 5.0); AnchorPane.setBottomAnchor(scrollPane, 5.0); root.getChildren().add(mainMenuBar); root.getChildren().addAll(scrollPane); scene.setRoot(root); stage.setScene(scene); }
From source file:editeurpanovisu.EditeurPanovisu.java
private AnchorPane afficherListePanosVignettes(int numHS) { AnchorPane aplistePano = new AnchorPane(); aplistePano.setOpacity(1);// w w w.j ava2s.co m Pane fond = new Pane(); fond.setStyle("-fx-background-color : #bbb;"); fond.setPrefWidth(540); fond.setPrefHeight(((nombrePanoramiques - 2) / 4 + 1) * 65 + 10); fond.setMinWidth(540); fond.setMinHeight(70); aplistePano.getChildren().add(fond); aplistePano.setStyle("-fx-backgroung-color : #bbb;"); int j = 0; ImageView[] IVPano; IVPano = new ImageView[nombrePanoramiques]; double xPos; double yPos; int row = 0; for (int i = 0; i < nombrePanoramiques; i++) { int numeroPano = i; IVPano[j] = new ImageView(panoramiquesProjet[i].getVignettePanoramique()); IVPano[j].setFitWidth(120); IVPano[j].setFitHeight(60); IVPano[j].setSmooth(true); String nomPano = panoramiquesProjet[i].getNomFichier(); int col = j % 4; row = j / 4; xPos = col * 130 + 25; yPos = row * 65 + 5; IVPano[j].setLayoutX(xPos); IVPano[j].setLayoutY(yPos); IVPano[j].setCursor(Cursor.HAND); IVPano[j].setStyle("-fx-background-color : #ccc;"); Tooltip t = new Tooltip( nomPano.substring(nomPano.lastIndexOf(File.separator) + 1, nomPano.lastIndexOf("."))); t.setStyle(tooltipStyle); Tooltip.install(IVPano[j], t); IVPano[j].setOnMouseClicked((MouseEvent me) -> { pano.setCursor(Cursor.CROSSHAIR); pano.setOnMouseClicked((MouseEvent me1) -> { gereSourisPanoramique(me1); }); panoListeVignette = nomPano; if (panoramiquesProjet[numeroPano].getTitrePanoramique() != null) { String texteHS = panoramiquesProjet[numeroPano].getTitrePanoramique(); TextArea txtHS = (TextArea) outils.lookup("#txtHS" + numHS); txtHS.setText(texteHS); } panoramiquesProjet[panoActuel].getHotspot(numHS).setNumeroPano(numeroPano); ComboBox cbx = (ComboBox) outils.lookup("#cbpano" + numHS); cbx.setValue(nomPano.substring(nomPano.lastIndexOf(File.separator) + 1, nomPano.lastIndexOf("."))); aplistePano.setVisible(false); me.consume(); }); aplistePano.getChildren().add(IVPano[j]); j++; } int taille = (row + 1) * 65 + 5; aplistePano.setPrefWidth(540); aplistePano.setPrefHeight(taille); aplistePano.setMinWidth(540); aplistePano.setMinHeight(taille); ImageView IVClose = new ImageView( new Image("file:" + repertAppli + File.separator + "images/ferme.png", 20, 20, true, true)); IVClose.setLayoutX(2); IVClose.setLayoutY(5); IVClose.setCursor(Cursor.HAND); aplistePano.getChildren().add(IVClose); IVClose.setOnMouseClicked((MouseEvent me) -> { pano.setCursor(Cursor.CROSSHAIR); pano.setOnMouseClicked((MouseEvent me1) -> { gereSourisPanoramique(me1); }); panoListeVignette = ""; aplistePano.setVisible(false); me.consume(); }); aplistePano.setTranslateZ(2); return aplistePano; }
From source file:editeurpanovisu.EditeurPanovisu.java
/** * * @param primaryStage/*from w w w. jav a 2 s . co m*/ * @param width * @param height * @throws Exception */ private void creeEnvironnement(Stage primaryStage, int width, int height) throws Exception { popUp = new PopUpDialogController(); primaryStage.setMaximized(true); double largeurOutils = 380; hauteurInterface = height; largeurInterface = width; /** * Cration des lments constitutifs de l'cran */ VBox root = new VBox(); creeMenu(root, width); tabPaneEnvironnement = new TabPane(); // tabPaneEnvironnement.setTranslateZ(5); tabPaneEnvironnement.setMinHeight(height - 60); tabPaneEnvironnement.setMaxHeight(height - 60); Pane barreStatus = new Pane(); barreStatus.setPrefSize(width + 20, 30); barreStatus.setTranslateY(25); barreStatus.setStyle("-fx-background-color:#c00;-fx-border-color:#aaa"); tabVisite = new Tab(); Pane visualiseur; Pane panneauPlan; tabInterface = new Tab(); tabPlan = new Tab(); gestionnaireInterface.creeInterface(width, height - 60); visualiseur = gestionnaireInterface.tabInterface; gestionnairePlan.creeInterface(width, height - 60); panneauPlan = gestionnairePlan.tabInterface; tabInterface.setContent(visualiseur); tabPlan.setContent(panneauPlan); HBox hbEnvironnement = new HBox(); TextArea txtTitrePano; TextArea tfTitreVisite; RadioButton radSphere; RadioButton radCube; CheckBox chkAfficheTitre; CheckBox chkAfficheInfo; tabPaneEnvironnement.getTabs().addAll(tabVisite, tabInterface, tabPlan); //tabPaneEnvironnement.setTranslateY(80); tabPaneEnvironnement.setSide(Side.TOP); tabPaneEnvironnement.getSelectionModel().selectedItemProperty() .addListener((ObservableValue<? extends Tab> ov, Tab t, Tab t1) -> { gestionnaireInterface.rafraichit(); }); tabVisite.setText(rb.getString("main.creationVisite")); tabVisite.setClosable(false); tabInterface.setText(rb.getString("main.creationInterface")); tabInterface.setClosable(false); tabPlan.setText(rb.getString("main.tabPlan")); tabPlan.setClosable(false); tabPlan.setDisable(true); tabVisite.setContent(hbEnvironnement); double largeur; String labelStyle = "-fx-color : white;-fx-background-color : #fff;-fx-padding : 5px; -fx-border : 1px solid #777;-fx-width : 100px;-fx-margin : 5px; "; scene = new Scene(root, width, height, Color.rgb(221, 221, 221)); // if (systemeExploitation.indexOf("inux") != -1) { // root.setStyle("-fx-font-size : 7pt;-fx-font-family: sans-serif;"); // } else { root.setStyle("-fx-font-size : 9pt;-fx-font-family: Arial;"); // } panneauOutils = new ScrollPane(); panneauOutils.setId("panOutils"); // panneauOutils.setStyle("-fx-background-color : #ccc;"); outils = new VBox(); paneChoixPanoramique = new VBox(); paneChoixPanoramique.setTranslateX(10); paneChoixPanoramique.setId("choixPanoramique"); Label lblTitreVisite = new Label(rb.getString("main.titreVisite")); lblTitreVisite.setStyle("-fx-font-size : 10pt;-fx-font-weight : bold;"); lblTitreVisite.setPadding(new Insets(15, 5, 5, 0)); lblTitreVisite.setMinWidth(largeurOutils - 20); lblTitreVisite.setAlignment(Pos.CENTER); tfTitreVisite = new TextArea(); tfTitreVisite.setId("titreVisite"); tfTitreVisite.setPrefSize(200, 25); tfTitreVisite.setMaxSize(340, 25); Separator sepTitre = new Separator(Orientation.HORIZONTAL); sepTitre.setMinHeight(10); Label lblChoixPanoramiqueEntree = new Label(rb.getString("main.panoEntree")); lblChoixPanoramiqueEntree.setStyle("-fx-font-size : 10pt;-fx-font-weight : bold;"); lblChoixPanoramiqueEntree.setPadding(new Insets(15, 5, 5, 0)); lblChoixPanoramiqueEntree.setMinWidth(largeurOutils - 20); lblChoixPanoramiqueEntree.setAlignment(Pos.CENTER); lblChoixPanoramique = new Label(rb.getString("main.panoAffiche")); lblChoixPanoramique.setStyle("-fx-font-size : 10pt;-fx-font-weight : bold;"); lblChoixPanoramique.setPadding(new Insets(10, 5, 5, 0)); lblChoixPanoramique.setMinWidth(largeurOutils - 20); lblChoixPanoramique.setAlignment(Pos.CENTER); Separator sepPano = new Separator(Orientation.HORIZONTAL); sepPano.setMinHeight(10); listeChoixPanoramique.setVisibleRowCount(10); listeChoixPanoramique.setTranslateX(60); Pane fond = new Pane(); fond.setCursor(Cursor.HAND); ImageView ivSupprPanoramique = new ImageView( new Image("file:" + repertAppli + File.separator + "images/suppr.png", 30, 30, true, true)); fond.setTranslateX(260); fond.setTranslateY(-40); Tooltip t = new Tooltip(rb.getString("main.supprimePano")); t.setStyle(tooltipStyle); Tooltip.install(fond, t); fond.getChildren().add(ivSupprPanoramique); fond.setOnMouseClicked((MouseEvent me) -> { retirePanoCourant(); }); listeChoixPanoramiqueEntree.setTranslateX(60); Separator sepInfo = new Separator(Orientation.HORIZONTAL); Label lblTitrePano = new Label(rb.getString("main.titrePano")); lblTitrePano.setStyle("-fx-font-size : 10pt;-fx-font-weight : bold;"); lblTitrePano.setPadding(new Insets(5, 5, 5, 0)); lblTitrePano.setMinWidth(largeurOutils - 20); lblTitrePano.setAlignment(Pos.CENTER); txtTitrePano = new TextArea(); txtTitrePano.setId("txttitrepano"); txtTitrePano.setPrefSize(200, 25); txtTitrePano.setMaxSize(340, 25); txtTitrePano.textProperty().addListener((final ObservableValue<? extends String> observable, final String oldValue, final String newValue) -> { clickBtnValidePano(); }); paneChoixPanoramique.getChildren().addAll(lblTitreVisite, tfTitreVisite, lblChoixPanoramiqueEntree, listeChoixPanoramiqueEntree, sepPano, lblChoixPanoramique, listeChoixPanoramique, fond, lblTitrePano, txtTitrePano, sepInfo); paneChoixPanoramique.setSpacing(10); /* modifier pour afficher le panneau des derniers fichiers; */ //outils.getChildren().addAll(lastFiles, paneChoixPanoramique); outils.getChildren().addAll(paneChoixPanoramique); paneChoixPanoramique.setVisible(false); /* Cration du panneau d'info du panoramique */ vuePanoramique = new ScrollPane(); coordonnees = new HBox(); pano = new Pane(); panneau2 = new AnchorPane(); lblLong = new Label(""); lblLat = new Label(""); imagePanoramique = new ImageView(); primaryStage.setScene(scene); //scene.getStylesheets().add("file:css/test.css"); /** * */ vuePanoramique.setPrefSize(width - largeurOutils - 20, height - 130); vuePanoramique.setMaxSize(width - largeurOutils - 20, height - 130); vuePanoramique.setVbarPolicy(ScrollPane.ScrollBarPolicy.NEVER); vuePanoramique.setHbarPolicy(ScrollPane.ScrollBarPolicy.NEVER); vuePanoramique.setTranslateY(5); //vuePanoramique.setStyle("-fx-background-color : #c00;"); /** * */ panneauOutils.setContent(outils); panneauOutils.setVbarPolicy(ScrollPane.ScrollBarPolicy.AS_NEEDED); panneauOutils.setHbarPolicy(ScrollPane.ScrollBarPolicy.NEVER); panneauOutils.setPrefSize(largeurOutils, height - 240); panneauOutils.setMaxWidth(largeurOutils); panneauOutils.setMaxHeight(height - 240); panneauOutils.setTranslateY(15); panneauOutils.setTranslateX(20); // panneauOutils.setStyle("-fx-background-color : #ccc;"); /** * */ pano.setCursor(Cursor.CROSSHAIR); outils.setPrefWidth(largeurOutils - 20); // outils.setStyle("-fx-background-color : #ccc;"); outils.minHeight(height - 130); outils.setLayoutX(10); // lblLong.setStyle(labelStyle); // lblLat.setStyle(labelStyle); lblLong.setPrefSize(100, 15); lblLat.setPrefSize(100, 15); lblLat.setTranslateX(50); // panneau2.setStyle("-fx-background-color : #ddd;"); panneau2.setPrefSize(width - largeurOutils - 20, height - 140); imagePanoramique.setCache(true); largeur = largeurMax - 60; imagePanoramique.setFitWidth(largeur); imagePanoramique.setFitHeight(largeur / 2.0d); imagePanoramique.setLayoutX((largeurMax - largeur) / 2.d); pano.getChildren().add(imagePanoramique); pano.setPrefSize(imagePanoramique.getFitWidth(), imagePanoramique.getFitHeight()); pano.setMaxSize(imagePanoramique.getFitWidth(), imagePanoramique.getFitHeight()); pano.setLayoutY(20); lblLong.setTranslateX(50); lblLat.setTranslateX(80); coordonnees.getChildren().setAll(lblLong, lblLat); vuePanoramique.setContent(panneau2); hbEnvironnement.getChildren().setAll(vuePanoramique, panneauOutils); AnchorPane paneEnv = new AnchorPane(); paneAttends = new AnchorPane(); paneAttends.setPrefHeight(250); paneAttends.setPrefWidth(400); paneAttends.setStyle("-fx-background-color : #ccc;" + "-fx-border-color: #666;" + "-fx-border-radius: 5px;" + "-fx-border-width: 1px;"); paneAttends.setLayoutX((width - 400) / 2.d); paneAttends.setLayoutY((height - 250) / 2.d - 55); ProgressIndicator p1 = new ProgressIndicator(); p1.setPrefSize(100, 100); p1.setLayoutX(150); p1.setLayoutY(50); Label lblAttends = new Label(rb.getString("main.attendsChargement")); lblAttends.setMinWidth(400); lblAttends.setAlignment(Pos.CENTER); lblAttends.setLayoutY(20); lblCharge = new Label(); lblCharge.setMinWidth(400); lblCharge.setLayoutY(200); paneAttends.getChildren().addAll(lblAttends, p1, lblCharge); paneAttends.setVisible(false); paneEnv.getChildren().addAll(tabPaneEnvironnement, paneAttends); // paneEnv.getChildren().addAll(tabPaneEnvironnement); root.getChildren().addAll(paneEnv); panneau2.getChildren().setAll(coordonnees, pano); primaryStage.show(); popUp.affichePopup(); lblDragDrop = new Label(rb.getString("main.dragDrop")); lblDragDrop.setMinHeight(vuePanoramique.getPrefHeight()); lblDragDrop.setMaxHeight(vuePanoramique.getPrefHeight()); lblDragDrop.setMinWidth(vuePanoramique.getPrefWidth()); lblDragDrop.setMaxWidth(vuePanoramique.getPrefWidth()); lblDragDrop.setAlignment(Pos.CENTER); lblDragDrop.setTextFill(Color.web("#c9c7c7")); lblDragDrop.setTextAlignment(TextAlignment.CENTER); lblDragDrop.setWrapText(true); lblDragDrop.setStyle("-fx-font-size:72px"); lblDragDrop.setTranslateY(-100); panneau2.getChildren().addAll(lblDragDrop, afficheLegende()); }