@Override public Button createNode() { final Button btn = new Button(text, icon.view()); btn.setTextAlignment(TextAlignment.CENTER); btn.setAlignment(Pos.CENTER); btn.setMnemonicParsing(false); btn.setLayoutX(10); btn.setLayoutY(10); btn.setPadding(new Insets(8, 12, 8, 12)); btn.setOnAction(handler); btn.setTooltip(new Tooltip(tooltip)); return btn; } }
public NaviSelect() { getStyleClass().add("navi-select"); editButton.getStyleClass().add("edit-button"); editButton.valueProperty().bind(visualBinding); HBox.setHgrow(editButton, Priority.ALWAYS); editButton.setTooltip(new Tooltip("Edit")); Pane gotoButtonGraphic = new Pane(); gotoButtonGraphic.getStyleClass().add("icon"); gotoButton.setGraphic(gotoButtonGraphic); gotoButton.setTooltip(new Tooltip("Goto")); gotoButton.getStyleClass().add("goto-button"); getChildren().addAll(editButton, gotoButton); }
@Override public List<? extends Node> getContributedButtons(MessageProvider messageProvider) { List<Button> contributedButtons = new ArrayList<Button>(); final Button expandButton = new Button("", new ImageView(new Image(getClass().getResourceAsStream("/org/copperengine/gui/icon/expandall.png")))); expandButton.setTooltip(new Tooltip(messageProvider.getText(MessageKey.filterAbleForm_button_expandall))); expandButton.setOnAction(new EventHandler<ActionEvent>() { @Override public void handle(ActionEvent e) { expandAll(workflowView.getRoot()); } }); contributedButtons.add(expandButton); final Button collapseButton = new Button("", new ImageView(new Image(getClass().getResourceAsStream("/org/copperengine/gui/icon/collapseall.png")))); collapseButton.setTooltip(new Tooltip(messageProvider.getText(MessageKey.filterAbleForm_button_collapseall))); collapseButton.setOnAction(new EventHandler<ActionEvent>() { @Override public void handle(ActionEvent e) { for (TreeItem<DisplayWorkflowClassesModel> child : workflowView.getRoot().getChildren()) { collapseAll(child); } } }); contributedButtons.add(collapseButton); return contributedButtons; }
/** * Constructor */ public SimplePaginationBar() { super(); previousButton.getStyleClass().addAll("simple-pagination-button"); previousButton.setTooltip(new Tooltip("Back")); previousButton.disableProperty().bind(Bindings.not(hasPrevious)); IconUtils.setFontIcon("mdi-chevron-left:24", previousButton); nextButton.getStyleClass().addAll("simple-pagination-button"); nextButton.setTooltip(new Tooltip("Next")); nextButton.disableProperty().bind(Bindings.not(hasNext)); IconUtils.setFontIcon("mdi-chevron-right:24", nextButton); firstButton.getStyleClass().addAll("simple-pagination-button"); IconUtils.setFontIcon("mdi-chevron-double-left:24", firstButton); lastButton.getStyleClass().addAll("simple-pagination-button"); IconUtils.setFontIcon("mdi-chevron-double-right:24", lastButton); lastButton.setTooltip(new Tooltip("Last")); lastButton.disableProperty().bind(Bindings.not(hasNext)); firstButton.setTooltip(new Tooltip("First")); firstButton.disableProperty().bind(Bindings.not(hasPrevious)); // @formatter:off layout.setSpacing(10); layout.getChildren().addAll(rowsPerPageLabel, itemsCount, NodeHelper.horizontalSpacer(), rowsPerPageCombo, previousButton, nextButton); // @formatter:on }
refreshButton.setId(REFRESH_BUTTON_ID); HBox.setMargin(refreshButton, new Insets(4, 0, 4, 0)); refreshButton.setTooltip(new Tooltip(messageProvider.getText(MessageKey.filterAbleForm_button_refresh))); refreshButton.setOnAction(new EventHandler<ActionEvent>() { @Override clearButton.setTooltip(new Tooltip(messageProvider.getText(MessageKey.filterAbleForm_button_clear))); clearButton.setOnAction(new EventHandler<ActionEvent>() { @Override
Node icon = xyTabPane.getIcon(FontAwesome.Glyph.POWER_OFF.name(), xyTabPane.getIconSize()); powerButton.setTooltip(new Tooltip(I18n.get(JavaFxI18n.POWER_OFF))); powerButton.setGraphic(icon); powerButton.setDisable(false);
hBox.getChildren().add(deleteButton); showButton.setTooltip(new Tooltip(uniformDesign.getText(editText))); selectButton.setTooltip(new Tooltip(uniformDesign.getText(selectText))); newButton.setTooltip(new Tooltip(uniformDesign.getText(addText))); deleteButton.setTooltip(new Tooltip(uniformDesign.getText(deleteText)));
buttons.getChildren().add(sortButton); showButton.setTooltip(new Tooltip(uniformDesign.getText(editText))); selectButton.setTooltip(new Tooltip(uniformDesign.getText(selectText))); adderButton.setTooltip(new Tooltip(uniformDesign.getText(addText))); deleteButton.setTooltip(new Tooltip(uniformDesign.getText(deleteText))); copyButton.setTooltip(new Tooltip(uniformDesign.getText(copyText)));
close.setTooltip(new Tooltip("Close")); close.setOnAction(t -> switchClose()); FontIcon closeicon = new FontIcon("mdi-close:18"); maximize.setTooltip(new Tooltip("Maximize")); maximize.setOnAction(t -> switchMaximize()); FontIcon maximizeicon = new FontIcon("mdi-window-maximize:16"); restore.setTooltip(new Tooltip("Restore")); restore.setOnAction(t -> switchRestore()); FontIcon maximizeicon = new FontIcon("mdi-window-restore:16"); fullscreen.setTooltip(new Tooltip("FullScreen")); fullscreen.setOnAction(t -> switchFullscreen()); FontIcon fullscreenicon = new FontIcon("mdi-fullscreen:16"); iconify.setTooltip(new Tooltip("Minimize")); iconify.setOnAction(t -> iconify()); FontIcon minimizeicon = new FontIcon("mdi-window-minimize:16");
fullscreen.setTooltip(new Tooltip("Restore")); fullscreen.setTooltip(new Tooltip("FullScreen"));
b1.setText("Default (push to enable Tab 'Progress')"); b1.setDefaultButton(true); b1.setTooltip(new Tooltip("This is a ToolTip")); b1.setOnAction(new EventHandler<ActionEvent>() { @Override public void handle(ActionEvent event) { Button pb1 = new Button(); pb1.setText("Button 1"); pb1.setTooltip(new Tooltip("This is a ToolTip")); AquaFx.createButtonStyler().setType(ButtonType.LEFT_PILL).style(pb1); pillButtonBox.getChildren().add(pb1);