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

[Pagination] "-fx-tooltip-visible: false;" is causing the buttons to be invisible

    XMLWordPrintable

    Details

      Description

      When adding
          pagination.setStyle("-fx-tooltip-visible: false; ");

      then the buttons between the arrows are not shown. They pop up when moving the mouse over some other controls or the window close button. If not including the style, doesn't happen.

      Appears even when adding
          pagination.setStyle("-fx-page-information-visible: false; -fx-tooltip-visible: false; ");
      but not when only
          pagination.setStyle("-fx-page-information-visible: false; ");

      Here a short example:

      public void start(Stage primaryStage) throws Exception {

      final Pagination pagination = new Pagination(5);
      pagination.setStyle(" -fx-tooltip-visible: false; ");

      final BorderPane borderPane = new BorderPane();
      borderPane.setPadding(new Insets(20));

      final Button buttonShow = new Button("hit spacebar!");
      buttonShow.setOnAction(new EventHandler<ActionEvent>() {
      public void handle(ActionEvent event) {
      if (borderPane.getCenter() == null) {
      borderPane.setCenter(pagination);
      }else {
      borderPane.setCenter(null);
      }
      }
      });

      borderPane.setPrefSize(500, 200);
      borderPane.setBottom(buttonShow);

      primaryStage.setScene(new Scene(borderPane));
      primaryStage.show();
      }

      How to test:
      don't click the button but press spacebar. The buttons of pagination will not be shown. When commenting out "-fx-tooltip-visible: false;" does work normal.

        Attachments

          Activity

            People

            Assignee:
            dgrieve David Grieve
            Reporter:
            duke J. Duke (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:
              Imported: