private void initListeners() { initTranslateBinding = Bindings.createDoubleBinding(() -> -1 * directionProperty.get().doubleValue() * defaultSizeProperty.getValue() - initOffset * directionProperty.get().doubleValue(), defaultSizeProperty, directionProperty);
@Override public Double getValue() { return delegate.getValue(); }
public final double getStartMargin() { return startMargin.getValue(); }
public final double getEndMargin() { return endMargin.getValue(); }
DoubleProperty x = new SimpleDoubleProperty(0); x.set(1); x.getValue(); imageView.xProperty().bind(x); anchorPane.heightProperty().add(x);
/** * Creates a new {@link DoubleField} with the given property. * * @param binding * The property from the model to be bound with. * * @return Returns a new {@link DoubleField}. */ public static DoubleField ofDoubleType(DoubleProperty binding) { return new DoubleField(new SimpleDoubleProperty(binding.getValue()), new SimpleDoubleProperty(binding.getValue())).bind(binding); }
@Override public final OptionalDouble getAsDouble(String key) { final DoubleProperty prop = (DoubleProperty) properties.get(key); if (prop == null) { return OptionalDouble.empty(); } else { return OptionalUtil.ofNullable(prop.getValue()); } }
/** * The constructor of {@code DoubleField}. * * @param valueProperty * The property that is used to store the current valid value * of the field. * @param persistentValueProperty * The property that is used to store the latest persisted * value of the field. */ protected DoubleField(SimpleDoubleProperty valueProperty, SimpleDoubleProperty persistentValueProperty) { super(valueProperty, persistentValueProperty); stringConverter = new AbstractStringConverter<Double>() { @Override public Double fromString(String string) { return Double.parseDouble(string); } }; renderer = new SimpleDoubleControl(); userInput.set(stringConverter.toString(value.getValue())); }
int nbSegments = (int)Math.ceil(textLength.getValue()/middleSectionWidth); for (int i=0; i<nbSegments; i++) { waxButon.getChildren().add(new ImageView(waxBtnMiddle));
Color.hsb(hue.getValue(), 1.0, 1.0), CornerRadii.EMPTY, Insets.EMPTY));
private void initListeners() { initTranslateBinding = Bindings.createDoubleBinding(() -> -1 * directionProperty.get().doubleValue() * defaultSizeProperty.getValue() - initOffset * directionProperty.get().doubleValue(), defaultSizeProperty, directionProperty);