Example usage for javafx.scene.layout AnchorPane setMinHeight

List of usage examples for javafx.scene.layout AnchorPane setMinHeight

Introduction

In this page you can find the example usage for javafx.scene.layout AnchorPane setMinHeight.

Prototype

public final void setMinHeight(double value) 

Source Link

Usage

From source file:editeurpanovisu.EditeurPanovisu.java

private ScrollPane afficheLegende() {
    double positionX = 0;
    double positionY = 0;
    AnchorPane apLegende = new AnchorPane();
    ScrollPane spLegende = new ScrollPane(apLegende);
    spLegende.getStyleClass().add("legendePane");

    apLegende.setMinWidth(1000);//ww  w. java2  s. c o m
    apLegende.setMinHeight(150);
    apLegende.setPrefWidth(1000);
    apLegende.setPrefHeight(150);
    apLegende.setMaxWidth(1000);
    apLegende.setMaxHeight(150);
    positionY = (pano.getLayoutY() + pano.getPrefHeight() + 10);

    Circle point = new Circle(30, 20, 5);
    point.setFill(Color.YELLOW);
    point.setStroke(Color.RED);
    point.setCursor(Cursor.DEFAULT);
    Circle point2 = new Circle(30, 60, 5);
    point2.setFill(Color.BLUE);
    point2.setStroke(Color.YELLOW);
    point2.setCursor(Cursor.DEFAULT);
    Circle point3 = new Circle(30, 100, 5);
    point3.setFill(Color.GREEN);
    point3.setStroke(Color.YELLOW);
    point3.setCursor(Cursor.DEFAULT);
    Polygon polygon = new Polygon();
    polygon.getPoints().addAll(new Double[] { 15.0, 2.0, 2.0, 2.0, 2.0, 15.0, -2.0, 15.0, -2.0, 2.0, -15.0, 2.0,
            -15.0, -2.0, -2.0, -2.0, -2.0, -15.0, 2.0, -15.0, 2.0, -2.0, 15.0, -2.0 });
    polygon.setStrokeLineJoin(StrokeLineJoin.MITER);
    polygon.setFill(Color.BLUEVIOLET);
    polygon.setStroke(Color.YELLOW);
    polygon.setId("PoV");
    polygon.setLayoutX(500);
    polygon.setLayoutY(20);
    Label lblHS = new Label(rb.getString("main.legendeHS"));
    Label lblHSImage = new Label(rb.getString("main.legendeHSImage"));
    //Label lblHSHTML = new Label(rb.getString("main.legendeHSHTML"));
    Label lblPoV = new Label(rb.getString("main.legendePoV"));
    Label lblNord = new Label(rb.getString("main.legendeNord"));
    Line ligneNord = new Line(500, 45, 500, 65);
    ligneNord.setStroke(Color.RED);
    ligneNord.setStrokeWidth(3);
    lblHS.setLayoutX(50);
    lblHS.setLayoutY(10);
    lblHSImage.setLayoutX(50);
    lblHSImage.setLayoutY(50);
    //lblHSHTML.setLayoutX(50);
    //lblHSHTML.setLayoutY(90);
    lblPoV.setLayoutX(520);
    lblPoV.setLayoutY(10);
    lblNord.setLayoutX(520);
    lblNord.setLayoutY(50);
    //        apLegende.getChildren().addAll(lblHS, point, lblHSImage, point2, lblHSHTML, point3, lblPoV, polygon, lblNord, ligneNord);
    apLegende.getChildren().addAll(lblHS, point, lblHSImage, point2, lblPoV, polygon, lblNord, ligneNord);
    apLegende.setId("legende");
    apLegende.setVisible(true);
    if (largeurMax - 50 < 1004) {
        spLegende.setPrefWidth(largeurMax - 50);
        spLegende.setMaxWidth(largeurMax - 50);
        positionX = 25;
    } else {
        spLegende.setPrefWidth(1004);
        spLegende.setMaxWidth(1004);
        positionX = (largeurMax - 1004) / 2.d;
    }
    spLegende.setLayoutX(positionX);
    spLegende.setLayoutY(positionY);
    spLegende.setVbarPolicy(ScrollPane.ScrollBarPolicy.NEVER);
    spLegende.setHbarPolicy(ScrollPane.ScrollBarPolicy.AS_NEEDED);

    return spLegende;
}

From source file:editeurpanovisu.EditeurPanovisu.java

private AnchorPane afficherListePanosVignettes(int numHS) {

    AnchorPane aplistePano = new AnchorPane();
    aplistePano.setOpacity(1);/*  w w w. j  a v a2  s .c  om*/
    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

/**
 *
 * @return/*from  www .  j  av  a2s  .  com*/
 */
private static ScrollPane spAfficheLegende() {
    double positionX;
    double positionY;
    AnchorPane apLegende = new AnchorPane();
    ScrollPane spLegende = new ScrollPane(apLegende);
    spLegende.getStyleClass().add("legendePane");

    apLegende.setMinWidth(1000);
    apLegende.setMinHeight(150);
    apLegende.setPrefWidth(1000);
    apLegende.setPrefHeight(150);
    apLegende.setMaxWidth(1000);
    apLegende.setMaxHeight(150);
    positionY = (spVuePanoramique.getPrefHeight() - apLegende.getPrefHeight() - 15);

    Circle circPoint = new Circle(30, 20, 5);
    circPoint.setFill(Color.YELLOW);
    circPoint.setStroke(Color.RED);
    circPoint.setCursor(Cursor.DEFAULT);
    Circle circPoint2 = new Circle(30, 40, 5);
    circPoint2.setFill(Color.BLUE);
    circPoint2.setStroke(Color.YELLOW);
    circPoint2.setCursor(Cursor.DEFAULT);
    Circle circPoint3 = new Circle(30, 60, 5);
    circPoint3.setFill(Color.GREEN);
    circPoint3.setStroke(Color.YELLOW);
    circPoint3.setCursor(Cursor.DEFAULT);
    Polygon polygonCroix = new Polygon();
    polygonCroix.getPoints().addAll(new Double[] { 15.0, 2.0, 2.0, 2.0, 2.0, 15.0, -2.0, 15.0, -2.0, 2.0, -15.0,
            2.0, -15.0, -2.0, -2.0, -2.0, -2.0, -15.0, 2.0, -15.0, 2.0, -2.0, 15.0, -2.0 });
    polygonCroix.setStrokeLineJoin(StrokeLineJoin.MITER);
    polygonCroix.setFill(Color.BLUEVIOLET);
    polygonCroix.setStroke(Color.YELLOW);
    polygonCroix.setId("PoV");
    polygonCroix.setLayoutX(500);
    polygonCroix.setLayoutY(20);
    Label lblHS = new Label(rbLocalisation.getString("main.legendeHS"));
    Label lblHSImage = new Label(rbLocalisation.getString("main.legendeHSImage"));
    Label lblHSHTML = new Label(rbLocalisation.getString("main.legendeHSHTML"));
    Label lblPoV = new Label(rbLocalisation.getString("main.legendePoV"));
    Label lblNord = new Label(rbLocalisation.getString("main.legendeNord"));
    Line lineNord = new Line(500, 45, 500, 65);
    lineNord.setStroke(Color.RED);
    lineNord.setStrokeWidth(3);
    lblHS.setLayoutX(50);
    lblHS.setLayoutY(15);
    lblHSImage.setLayoutX(50);
    lblHSImage.setLayoutY(35);
    lblHSHTML.setLayoutX(50);
    lblHSHTML.setLayoutY(55);
    lblPoV.setLayoutX(520);
    lblPoV.setLayoutY(15);
    lblNord.setLayoutX(520);
    lblNord.setLayoutY(55);
    apLegende.getChildren().addAll(lblHS, circPoint, lblHSImage, circPoint2, lblHSHTML, circPoint3, lblPoV,
            polygonCroix, lblNord, lineNord);
    apLegende.setId("legende");
    apLegende.setVisible(true);
    if (largeurMax - 50 < 1004) {
        spLegende.setPrefWidth(largeurMax - 50);
        spLegende.setMaxWidth(largeurMax - 50);
        positionX = 25;
    } else {
        spLegende.setPrefWidth(1004);
        spLegende.setMaxWidth(1004);
        positionX = (largeurMax - 1004) / 2.d;
    }
    spLegende.setLayoutX(positionX);
    spLegende.setLayoutY(positionY);
    spLegende.setVbarPolicy(ScrollPane.ScrollBarPolicy.NEVER);
    spLegende.setHbarPolicy(ScrollPane.ScrollBarPolicy.AS_NEEDED);

    return spLegende;
}

From source file:editeurpanovisu.EditeurPanovisu.java

/**
 *
 * @param strNomFichierBarre//w ww  .  java 2s  .  com
 */
public static void creerEditerBarre(String strNomFichierBarre) {
    apCreationBarre.getChildren().clear();
    apCreationBarre.setStyle("-fx-background-color : -fx-base;" + "-fx-border-color: derive(-fx-base,10%);"
            + "-fx-effect: dropshadow( three-pass-box , rgba(0,0,0,0.5) , 8, 0.0 , 0 , 8 );"
            + "-fx-border-width: 1px;");

    AnchorPane apOutilsBarre = new AnchorPane();
    Button btnAnnulerBarre = new Button(rbLocalisation.getString("main.quitter"),
            new ImageView(new Image("file:" + getStrRepertAppli() + "/images/annule.png")));
    final Button btnSauverBarre = new Button(rbLocalisation.getString("main.sauver"), new ImageView(
            new Image("file:" + getStrRepertAppli() + "/images/sauveProjet.png", 24, 24, true, true, true)));
    Rectangle2D tailleEcran = Screen.getPrimary().getBounds();
    btnAjouteZone = new Button(rbLocalisation.getString("main.ajouteZone"), new ImageView(
            new Image("file:" + getStrRepertAppli() + "/images/btn+.png", 24, 24, true, true, true)));
    apImgBarrePersonnalisee = new AnchorPane();
    apImgBarrePersonnalisee.getChildren().clear();
    apZoneBarrePersonnalisee = new AnchorPane();
    apZoneBarrePersonnalisee.getChildren().clear();
    apZoneBarrePersonnalisee.setLayoutX(0);
    apZoneBarrePersonnalisee.setLayoutY(150);
    apZoneBarrePersonnalisee.setPrefWidth(300);
    apZoneBarrePersonnalisee.setPrefHeight(200);

    int iLargeurEcran = (int) tailleEcran.getWidth();
    int iHauteurEcran = (int) tailleEcran.getHeight() - 100;
    final int iLargeur = 1200;
    final int iHauteur = 600;
    mbarPrincipal.setDisable(true);
    bbarPrincipal.setDisable(true);
    hbBarreBouton.setDisable(true);
    tpEnvironnement.setDisable(true);
    apCreationBarre.setPrefWidth(iLargeur);
    apCreationBarre.setMinWidth(iLargeur);
    apCreationBarre.setMaxWidth(iLargeur);
    apCreationBarre.setPrefHeight(iHauteur);
    apCreationBarre.setMinHeight(iHauteur);
    apCreationBarre.setMaxHeight(iHauteur);
    apCreationBarre.setLayoutX((iLargeurEcran - iLargeur) / 2);
    apCreationBarre.setLayoutY((iHauteurEcran - iHauteur) / 2);
    apCreationBarre.setVisible(true);
    Label lblBarrePersonnalisee = new Label(rbLocalisation.getString("main.creeBarrePersonnalisee"));
    lblBarrePersonnalisee.setMinWidth(iLargeur - 10);
    lblBarrePersonnalisee.setAlignment(Pos.CENTER);
    lblBarrePersonnalisee.setStyle("-fx-background-color : #777;");
    lblBarrePersonnalisee.setTextFill(Color.WHITE);
    lblBarrePersonnalisee.setLayoutX(5);
    lblBarrePersonnalisee.setLayoutY(10);
    lblBarrePersonnalisee.setFont(Font.font(14));
    apCreationBarre.getChildren().add(lblBarrePersonnalisee);
    apOutilsBarre.setPrefWidth(300);
    apOutilsBarre.setMinWidth(300);
    apOutilsBarre.setMaxWidth(300);
    apOutilsBarre.setPrefHeight(iHauteur - 50);
    apOutilsBarre.setMinHeight(iHauteur - 50);
    apOutilsBarre.setMaxHeight(iHauteur - 50);
    apOutilsBarre.setLayoutX(iLargeur - 302);
    apOutilsBarre.setLayoutY(50);

    apOutilsBarre.setStyle(
            "-fx-background-color : -fx-background;-fx-border-width : 1px;-fx-border-color : transparent transparent transparent -fx-outer-border;");
    btnAnnulerBarre.setPrefWidth(120);
    btnAnnulerBarre.setLayoutX(30);
    btnAnnulerBarre.setLayoutY(iHauteur - 90);
    btnSauverBarre.setPrefWidth(120);
    btnSauverBarre.setLayoutX(160);
    btnSauverBarre.setLayoutY(iHauteur - 90);
    btnSauverBarre.setDisable(true);
    Label lblChargeImage = new Label(rbLocalisation.getString("main.chargeImage"));
    lblChargeImage.setLayoutX(20);
    lblChargeImage.setLayoutY(10);
    TextField tfChargeImage = new TextField("");
    tfChargeImage.setDisable(true);
    tfChargeImage.setPrefWidth(200);
    tfChargeImage.setLayoutX(50);
    tfChargeImage.setLayoutY(40);
    Button btnChargeImage = new Button("...");
    btnChargeImage.setLayoutX(260);
    btnChargeImage.setLayoutY(40);
    final CheckBox cbMasqueZones = new CheckBox(rbLocalisation.getString("main.masqueZones"));
    cbMasqueZones.setDisable(true);
    cbMasqueZones.setLayoutX(20);
    cbMasqueZones.setLayoutY(70);
    btnAjouteZone.setLayoutX(130);
    btnAjouteZone.setLayoutY(110);
    btnAjouteZone.setDisable(true);
    apOutilsBarre.getChildren().addAll(lblChargeImage, tfChargeImage, btnChargeImage, cbMasqueZones,
            btnAjouteZone, apZoneBarrePersonnalisee, btnAnnulerBarre, btnSauverBarre);

    apCreationBarre.getChildren().addAll(apImgBarrePersonnalisee, apOutilsBarre);
    if (!strNomFichierBarre.equals("")) {
        lblChargeImage.setVisible(false);
        tfChargeImage.setVisible(false);
        btnChargeImage.setVisible(false);
        String strNomFichier = strNomFichierBarre;
        strNomFichier = strNomFichier.substring(0, strNomFichier.length() - 4);
        strNomFichierShp = strNomFichier + ".shp";
        String strNomFichierPng = strNomFichier + ".png";
        File fichPng = new File(strNomFichierPng);
        if (fichPng.exists()) {
            try {
                btnAjouteZone.setDisable(false);
                imgBarrePersonnalisee = new Image("file:" + fichPng);
                iNombreZones = getGestionnaireInterface().lisFichierShp(strNomFichierShp, zones);
                btnSauverBarre.setDisable(false);
                if (iNombreZones > 0) {
                    cbMasqueZones.setDisable(false);
                }
                afficheBarrePersonnalisee(iLargeur, iHauteur, false);

            } catch (IOException ex) {
                Logger.getLogger(EditeurPanovisu.class.getName()).log(Level.SEVERE, null, ex);
            }

        }
    }

    btnAnnulerBarre.setOnMouseClicked((t) -> {
        mbarPrincipal.setDisable(false);
        bbarPrincipal.setDisable(false);
        hbBarreBouton.setDisable(false);
        tpEnvironnement.setDisable(false);
        apCreationBarre.setVisible(false);
    });

    btnAjouteZone.setOnMouseClicked((t) -> {
        btnAjouteZone.setDisable(true);
        ajouterZone(iLargeur, iHauteur, false);
    });
    btnChargeImage.setOnMouseClicked((t) -> {
        strRepertBarrePersonnalisee = getStrRepertAppli() + "/theme/telecommandes";
        File fileRepert;
        fileRepert = new File(strRepertBarrePersonnalisee);
        FileChooser fileChooser = new FileChooser();
        FileChooser.ExtensionFilter efShpFilter = new FileChooser.ExtensionFilter(
                "Fichiers barre personnalise (SHP)", "*.shp", "*.png");

        fileChooser.setInitialDirectory(fileRepert);
        fileChooser.getExtensionFilters().addAll(efShpFilter);

        File fileFichierImage = fileChooser.showOpenDialog(null);
        if (fileFichierImage != null) {
            String strNomFichier = fileFichierImage.getAbsolutePath();
            strNomFichier = strNomFichier.substring(0, strNomFichier.length() - 4);
            strNomFichierShp = strNomFichier + ".shp";
            String strNomFichierPng = strNomFichier + ".png";
            File fileFichierPng = new File(strNomFichierPng);
            if (fileFichierPng.exists()) {
                try {
                    btnAjouteZone.setDisable(false);
                    imgBarrePersonnalisee = new Image("file:" + fileFichierPng);
                    iNombreZones = getGestionnaireInterface().lisFichierShp(strNomFichierShp, zones);
                    btnSauverBarre.setDisable(false);
                    if (iNombreZones > 0) {
                        cbMasqueZones.setDisable(false);
                    }
                    afficheBarrePersonnalisee(iLargeur, iHauteur, false);

                } catch (IOException ex) {
                    Logger.getLogger(EditeurPanovisu.class.getName()).log(Level.SEVERE, null, ex);
                }
            }
        }
    });

    btnSauverBarre.setOnMouseClicked((t) -> {
        try {
            sauverBarre(strNomFichierShp);
            getGestionnaireInterface().chargeBarrePersonnalisee(strNomFichierBarre);

        } catch (IOException ex) {
            Logger.getLogger(EditeurPanovisu.class.getName()).log(Level.SEVERE, null, ex);
        }
    });
    cbMasqueZones.selectedProperty()
            .addListener((ObservableValue<? extends Boolean> ov, Boolean old_val, Boolean new_val) -> {
                afficheBarrePersonnalisee(iLargeur, iHauteur, new_val);
            });

}

From source file:editeurpanovisu.EditeurPanovisu.java

/**
 *
 * @param iNumHS/*from ww  w . ja v a 2s .co  m*/
 * @return
 */
private static AnchorPane apAfficherListePanosVignettes(int iNumHS) {
    NavigateurPanoramique navigateurPano2;
    AnchorPane apVisuPanoHS;
    iNumeroPanoChoisitHS = -1;
    if (!getPanoramiquesProjet()[getiPanoActuel()].getHotspot(iNumHS).getStrFichierXML().equals("")) {
        for (int ii1 = 0; ii1 < getiNombrePanoramiques(); ii1++) {
            String strFichPano = getPanoramiquesProjet()[ii1].getStrNomFichier();
            String strNomXMLFile = strFichPano
                    .substring(strFichPano.lastIndexOf(File.separator) + 1, strFichPano.length())
                    .split("\\.")[0] + ".xml";
            if (strNomXMLFile
                    .equals(getPanoramiquesProjet()[getiPanoActuel()].getHotspot(iNumHS).getStrFichierXML())) {
                iNumeroPanoChoisitHS = ii1;
                strNomPanoChoisitHS = getPanoramiquesProjet()[ii1].getStrNomFichier();
            }
        }
        navigateurPano2 = new NavigateurPanoramique(
                getPanoramiquesProjet()[iNumeroPanoChoisitHS].getImgVisuPanoramique(), 0, 0, 400, 200, true);
        if (getPanoramiquesProjet()[getiPanoActuel()].getHotspot(iNumHS).getRegardX() != -1000) {
            navigateurPano2.setChoixLongitude(
                    getPanoramiquesProjet()[getiPanoActuel()].getHotspot(iNumHS).getRegardX());
        } else {
            navigateurPano2.setChoixLongitude(0);
        }
        navigateurPano2.setLongitude(navigateurPano2.getChoixLongitude());
        if (getPanoramiquesProjet()[getiPanoActuel()].getHotspot(iNumHS).getRegardY() != -1000) {
            navigateurPano2.setChoixLatitude(
                    getPanoramiquesProjet()[getiPanoActuel()].getHotspot(iNumHS).getRegardY());
        } else {
            navigateurPano2.setChoixLatitude(0);
        }
        navigateurPano2.setLatitude(navigateurPano2.getChoixLatitude());
        if (getPanoramiquesProjet()[getiPanoActuel()].getHotspot(iNumHS).getChampVisuel() != 0) {
            navigateurPano2
                    .setChoixFov(getPanoramiquesProjet()[getiPanoActuel()].getHotspot(iNumHS).getChampVisuel());
        } else {
            navigateurPano2.setChoixFov(50);
        }
        navigateurPano2.setFov(navigateurPano2.getChoixFov());
        apVisuPanoHS = navigateurPano2.affichePano();
        apVisuPanoHS.setDisable(false);

    } else {
        navigateurPano2 = new NavigateurPanoramique(
                getPanoramiquesProjet()[getiPanoActuel()].getImgVisuPanoramique(), 0, 0, 400, 200, true);
        apVisuPanoHS = navigateurPano2.affichePano();
        apVisuPanoHS.setDisable(true);
    }
    AnchorPane aplistePano = new AnchorPane();
    aplistePano.setOpacity(1);
    Pane paneFond = new Pane();
    paneFond.setOnMouseClicked((mouseEvent) -> {
        mouseEvent.consume();
    });
    paneFond.setStyle("-fx-background-color : #bbb;");
    paneFond.setPrefWidth(540);
    paneFond.setPrefHeight(((getiNombrePanoramiques() - 2) / 4 + 1) * 65 + 10 + 320);
    paneFond.setMinWidth(540);
    paneFond.setMinHeight(70);
    aplistePano.getChildren().add(paneFond);
    aplistePano.setStyle("-fx-backgroung-color : #bbb;");
    int ij = 0;
    ImageView[] ivPano;
    ivPano = new ImageView[getiNombrePanoramiques()];
    double xPos;
    double yPos;
    int iRow = 0;
    Button btnValide = new Button("Ok");
    btnValide.setPrefWidth(80);
    btnValide.setLayoutX(paneFond.getPrefWidth() - 100);
    btnValide.setLayoutY(paneFond.getPrefHeight() - 30);
    paneFond.getChildren().add(btnValide);
    btnValide.setOnMouseClicked((mouseEvent) -> {
        if (iNumeroPanoChoisitHS != -1) {
            panePanoramique.setCursor(Cursor.CROSSHAIR);
            panePanoramique.setOnMouseClicked((me1) -> {
                gereSourisPanoramique(me1);
            });
            setStrPanoListeVignette(strNomPanoChoisitHS);
            if (getPanoramiquesProjet()[iNumeroPanoChoisitHS].getStrTitrePanoramique() != null) {
                String strTexteHS = getPanoramiquesProjet()[iNumeroPanoChoisitHS].getStrTitrePanoramique();
                TextField tfTxtHS = (TextField) vbOutils.lookup("#txtHS" + iNumHS);
                tfTxtHS.setText(strTexteHS);
            }
            double latitude = Math.round(navigateurPano2.getChoixLatitude() * 10) / 10.d;
            double longitude = Math.round(navigateurPano2.getChoixLongitude() * 10) / 10.d - 180;
            double fov = Math.round(navigateurPano2.getChoixFov() * 10) / 10.d;
            longitude = longitude % 360;
            longitude = longitude < 0 ? longitude + 360 : longitude;
            longitude = longitude > 180 ? longitude - 360 : longitude;
            getPanoramiquesProjet()[getiPanoActuel()].getHotspot(iNumHS).setNumeroPano(iNumeroPanoChoisitHS);
            getPanoramiquesProjet()[getiPanoActuel()].getHotspot(iNumHS).setRegardX(longitude - 180);
            getPanoramiquesProjet()[getiPanoActuel()].getHotspot(iNumHS).setRegardY(latitude);
            getPanoramiquesProjet()[getiPanoActuel()].getHotspot(iNumHS).setChampVisuel(fov);
            getPanoramiquesProjet()[getiPanoActuel()].getHotspot(iNumHS)
                    .setImgVueHs(navigateurPano2.getImgVignetteHS());
            ComboBox cbPanos = (ComboBox) vbOutils.lookup("#cbpano" + iNumHS);
            cbPanos.getSelectionModel().select(iNumeroPanoChoisitHS);
            aplistePano.setVisible(false);
        }
        mouseEvent.consume();

    });
    for (int i = 0; i < getiNombrePanoramiques(); i++) {
        int iNumeroPano1 = i;
        String strNomPano = getPanoramiquesProjet()[i].getStrNomFichier();
        ivPano[ij] = new ImageView(getPanoramiquesProjet()[i].getImgVignettePanoramique());
        ivPano[ij].setFitWidth(120);
        ivPano[ij].setFitHeight(60);
        ivPano[ij].setSmooth(true);
        int iCol = ij % 4;
        iRow = ij / 4;
        xPos = iCol * 130 + 25;
        yPos = iRow * 65 + 15;
        ivPano[ij].setLayoutX(xPos);
        ivPano[ij].setLayoutY(yPos);
        ivPano[ij].setCursor(Cursor.HAND);
        ivPano[ij].setStyle("-fx-background-color : #ccc;");
        Tooltip tltpPano = new Tooltip(
                strNomPano.substring(strNomPano.lastIndexOf(File.separator) + 1, strNomPano.lastIndexOf(".")));
        tltpPano.setStyle(getStrTooltipStyle());
        Tooltip.install(ivPano[ij], tltpPano);
        ivPano[ij].setOnMouseClicked((mouseEvent) -> {
            iNumeroPanoChoisitHS = iNumeroPano1;
            strNomPanoChoisitHS = getPanoramiquesProjet()[iNumeroPanoChoisitHS].getStrNomFichier();
            navigateurPano2.setImagePanoramique(
                    getPanoramiquesProjet()[iNumeroPanoChoisitHS].getStrNomFichier(),
                    getPanoramiquesProjet()[iNumeroPanoChoisitHS].getImgVisuPanoramique());
            navigateurPano2.setLongitude(getPanoramiquesProjet()[iNumeroPanoChoisitHS].getRegardX() - 180);
            navigateurPano2.setLatitude(getPanoramiquesProjet()[iNumeroPanoChoisitHS].getRegardY());
            navigateurPano2.setFov(getPanoramiquesProjet()[iNumeroPanoChoisitHS].getChampVisuel());
            navigateurPano2.affiche();
            apVisuPanoHS.setDisable(false);
        });
        aplistePano.getChildren().add(ivPano[ij]);
        ij++;

    }
    int iTaille = (iRow + 1) * 65 + 5;
    apVisuPanoHS.setLayoutY(iTaille + 10);
    iTaille += 320;
    apVisuPanoHS.setLayoutX((540 - apVisuPanoHS.getPrefWidth()) / 2.d);
    aplistePano.setPrefWidth(540);
    aplistePano.setPrefHeight(iTaille);
    aplistePano.setMinWidth(540);
    aplistePano.setMinHeight(iTaille);
    aplistePano.getChildren().add(apVisuPanoHS);
    ImageView ivClose = new ImageView(
            new Image("file:" + getStrRepertAppli() + 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) -> {
        panePanoramique.setCursor(Cursor.CROSSHAIR);
        panePanoramique.setOnMouseClicked((mouseEvent1) -> {
            gereSourisPanoramique(mouseEvent1);
        });

        setStrPanoListeVignette("");
        aplistePano.setVisible(false);
        mouseEvent.consume();
    });
    return aplistePano;
}