@Override protected double computePrefHeight(double width) { return control.prefHeight(width); } };
@Override protected double computePrefHeight(double width) { double height = 0.0F; for (Node child : getChildren()) { if (child instanceof TabHeaderContainer) { height = Math.max(height, child.prefHeight(width)); } } return snapSize(height) + snappedTopInset() + snappedBottomInset(); }
@Override protected double computePrefHeight(double width) { if (!getChildren().isEmpty()) { return getChildren().get(0).prefHeight(width); } return super.computePrefHeight(width); }
double newAnimatedHeight = newNode.prefHeight(-1) * (expandedProperty.get() ? 1 : -1); double newHeight = expandedProperty.get() ? this.getHeight() + newAnimatedHeight : this.prefHeight( -1); ((Region) cellContent).setMaxHeight(cellContent.prefHeight(-1)); setGraphic(cellContent);
@Override protected double computePrefHeight(double width, double topInset, double rightInset, double bottomInset, double leftInset) { return content == null ? 0 : content.prefHeight(width); };
@Override protected double computePrefHeight(double width, double topInset, double rightInset, double bottomInset, double leftInset) { double insets = topInset + bottomInset; return insets + (content == null ? 0 : content.prefHeight(width)); }
@Override protected double computePrefHeight(double width) { return content.prefHeight(width); }
@Override public double prefBreadth(Node node) { return node.prefHeight(-1); }
@Override public double prefLength(Node node, double breadth) { return node.prefHeight(breadth); }
@Override protected double computePrefHeight(double width) { return control.prefHeight(width); } };
private double calculateNodeHeight(Node n, MinPrefMax size) { if (size == MinPrefMax.MIN) { return n.minHeight(-1); } if (size == MinPrefMax.MAX) { return n.maxHeight(-1); } return n.prefHeight(-1); }
protected double computePrefHeight(double width, double topInset, double rightInset, double bottomInset, double leftInset) { double prefHeight; if (getSkinnable().getOrientation() == Orientation.VERTICAL) prefHeight = acc(n -> n.prefHeight(width)) + topInset + bottomInset; else prefHeight = biggest(n -> n.prefHeight(width)) + topInset + bottomInset; return Math.max(prefHeight, getSkinnable().getPrefHeight()); }
private double getPrefRowHeight() { double editorHeight = getSkinnable().getEditor().prefHeight(-1); if (getChildren().isEmpty()) return editorHeight; else return Math.max(editorHeight, getChildren().get(0).prefHeight(-1)); }
@Override protected double computePrefHeight(double width) { double height = 0.0F; for (Node child : getChildren()) { if (child instanceof TabHeaderContainer) { height = Math.max(height, child.prefHeight(width)); } } return snapSize(height) + snappedTopInset() + snappedBottomInset(); }
/** * Add the preferred height of the expanded Node whenever the expanded flag is true. * * @return The preferred height of the TableRow, appended with the preferred height of the expanded node * if this row is currently expanded. */ @Override protected double computePrefHeight(double width, double topInset, double rightInset, double bottomInset, double leftInset) { tableRowPrefHeight = super.computePrefHeight(width, topInset, rightInset, bottomInset, leftInset); return isExpanded() ? tableRowPrefHeight + getContent().prefHeight(width) : tableRowPrefHeight; }
/** * Add the preferred height of the expanded Node whenever the expanded flag is true. * * @return The preferred height of the TableRow, appended with the preferred height of the expanded node * if this row is currently expanded. */ @Override protected double computePrefHeight(double width, double topInset, double rightInset, double bottomInset, double leftInset) { tableRowPrefHeight = super.computePrefHeight(width, topInset, rightInset, bottomInset, leftInset); return isExpanded() ? tableRowPrefHeight + getContent().prefHeight(width) : tableRowPrefHeight; }
@Override protected double computePrefHeight(double width, double topInset, double rightInset, double bottomInset, double leftInset) { if (getSkinnable().getOrientation().equals(Orientation.HORIZONTAL)) { OptionalDouble maxHeight = getChildren().stream().mapToDouble(node -> node.prefHeight(-1)).max(); if (maxHeight.isPresent()) { return maxHeight.getAsDouble(); } } return getSkinnable().getPrefHeight(); }
@Override protected double computePrefHeight(double width) { if (!getChildren().isEmpty()) { return getChildren().get(0).prefHeight(width); } return super.computePrefHeight(width); }
protected double computePrefHeight(double width, double topInset, double rightInset, double bottomInset, double leftInset) { double h = text.prefHeight(width); if (getSkinnable().getGraphic() != null && iconPosition().isHorizontal()) h += Math.max(getSkinnable().getGraphic().prefHeight(-1), graphicFixedSize()); return h + topInset + bottomInset; }
private static Size computeSize(@NonNull Node control, boolean flushCache) { int wHint = FX_DEFAULT, hHint = FX_DEFAULT; RowData data = getConstraint(control); if (data != null) { wHint = data.getWidth(); hHint = data.getHeight(); } return new Size(control.prefWidth(wHint), control.prefHeight(hHint)); }