private void initStyle(StackPane pane) { pane.setOpacity(1); pane.setPrefSize(30, 4); pane.setBackground(new Background(new BackgroundFill(Color.BLACK, new CornerRadii(5), Insets.EMPTY))); }
private void resetPseudoClass() { if (activePseudoClass != null) { content.pseudoClassStateChanged(activePseudoClass, false); activePseudoClass = null; } }
@Override public void requestLayout() { if (performingLayout) { return; } super.requestLayout(); }
public void updateDisabled() { final boolean disabled = control.isDisable(); line.setBorder(!disabled ? Border.EMPTY : new Border(new BorderStroke(control.getUnFocusColor(), BorderStrokeStyle.DASHED, CornerRadii.EMPTY, new BorderWidths(1)))); line.setBackground(new Background( new BackgroundFill(disabled ? Color.TRANSPARENT : control.getUnFocusColor(), CornerRadii.EMPTY, Insets.EMPTY))); } }
/*************************************************************************** * * * Setters / Getters * * * **************************************************************************/ public ObservableList<Node> getHeading() { return heading.getChildren(); }
public static void updateBackground(Background newBackground, Region nodeToUpdate, Paint fill) { if (newBackground != null && !newBackground.getFills().isEmpty()) { final BackgroundFill[] fills = new BackgroundFill[newBackground.getFills().size()]; for (int i = 0; i < newBackground.getFills().size(); i++) { BackgroundFill bf = newBackground.getFills().get(i); fills[i] = new BackgroundFill(fill, bf.getRadii(), bf.getInsets()); } nodeToUpdate.setBackground(new Background(fills)); } }
/** * set the content of the dialog * * @param content */ public void setContent(Region content) { if (content != null) { this.content = content; this.content.setPickOnBounds(false); contentHolder.getChildren().setAll(content); } }
/** * creates empty dialog layout */ public JFXDialogLayout() { initialize(); heading.getStyleClass().addAll("jfx-layout-heading", "title"); body.getStyleClass().add("jfx-layout-body"); VBox.setVgrow(body, Priority.ALWAYS); actions.getStyleClass().add("jfx-layout-actions"); getChildren().setAll(heading, body, actions); }
public void updateFocusColor() { Paint paint = control.getFocusColor(); focusedLine.setBackground(paint == null ? Background.EMPTY : new Background(new BackgroundFill(paint, CornerRadii.EMPTY, Insets.EMPTY))); }
private void init() { setClip(clip); clip.setBackground(new Background(new BackgroundFill(Color.BLACK, new CornerRadii(2), Insets.EMPTY))); backgroundProperty().addListener(observable -> JFXNodeUtils.updateBackground(getBackground(), clip)); }
FlowPaneStackPaneJFXNodesAnimation(final FlowPane main, final StackPane nextPage, final StackPane wizard, final StackPane colorPane1) { super(main, nextPage); this.main = main; this.nextPage = nextPage; this.wizard = wizard; this.colorPane1 = colorPane1; tempPage = new Pane(); newX = 0; newY = 0; }
protected double getBLockWidth(Region region) { if (region.getMinWidth() != -1) { return region.getMinWidth(); } if (region.getPrefWidth() != USE_COMPUTED_SIZE) { return region.getPrefWidth(); } else { return region.prefWidth(-1); } }
@Override protected void layoutChildren() { super.layoutChildren(); clip.resizeRelocate(0,0,getWidth(), getHeight()); } }
/** * {@inheritDoc} */ @Override public void requestLayout() { if (performingLayout) { return; } super.requestLayout(); }
@Override protected double computePrefHeight(double width, double topInset, double rightInset, double bottomInset, double leftInset) { return arcPane.prefHeight(-1); }
@Override public void requestLayout() { if (performingLayout) { return; } super.requestLayout(); }
@Override protected double computePrefWidth(double height, double topInset, double rightInset, double bottomInset, double leftInset) { return arcPane.prefWidth(-1); }
/*************************************************************************** * * * Setters / Getters * * * **************************************************************************/ public ObservableList<Node> getSidePane() { return sidePane.getChildren(); }
public void updateUnfocusColor() { Paint paint = control.getUnFocusColor(); line.setBackground(paint == null ? Background.EMPTY : new Background(new BackgroundFill(paint, CornerRadii.EMPTY, Insets.EMPTY))); }
@Override protected double computePrefHeight(double width, double topInset, double rightInset, double bottomInset, double leftInset) { return topInset + bar.prefHeight(width) + bottomInset; }