Skip to content

Bump org.int4.fx:fx-values from 0.4 to 0.5#794

Open
dependabot[bot] wants to merge 1 commit into
masterfrom
dependabot/gradle/org.int4.fx-fx-values-0.5
Open

Bump org.int4.fx:fx-values from 0.4 to 0.5#794
dependabot[bot] wants to merge 1 commit into
masterfrom
dependabot/gradle/org.int4.fx-fx-values-0.5

Conversation

@dependabot
Copy link
Copy Markdown

@dependabot dependabot Bot commented on behalf of github Feb 23, 2026

Bumps org.int4.fx:fx-values from 0.4 to 0.5.

Release notes

Sourced from org.int4.fx:fx-values's releases.

0.5

Full Changelog: int4-org/FX@0.4...0.5

This release enhances FX with a more flexible, strategy-driven builder model, enabling build-time customizable resolution of text, formatting, and child nodes.

Context‑Aware Build Strategy Infrastructure

A major addition is the build context and strategies framework. This allows builder behavior to be customized and overridden without changing the builders themselves. It introduces:

  • BuildContext, BuildContexts, and BuildStrategy to represent, compose, and resolve strategy implementations.
  • Thread‑local and global root contexts for scoped strategy application.
  • Support for override of strategies such as text formatting (TextStrategy), content resolution (ContentStrategy) and children handling (ChildrenStrategy). This enables advanced use‑cases such as localization and custom node resolution.

Below is an example how text accepting builder methods can be (globally) overridden to do localization:

ChoiceModel<Locale> locales = ChoiceModel.of(Locale.ENGLISH, Locale.GERMAN);
BuildContexts.root(
BuildContext.of(TextStrategy.class, (node, input, setter) -> {
if (locales.get().equals(Locale.GERMAN)) {
setter.accept(Objects.toString(input).toUpperCase());
}
else {
setter.accept(Objects.toString(input));
}
})
);

The example:

  • Creates a new BuildContext with an overridden TextStrategy
  • Sets the newly created BuildContext as the root context for builders to use

Generalized text inputs

The text, promptText, and accessibleText builder methods now accept Object instead of String. Values are passed to the active TextStrategy, with the default behavior calling toString(). This enables richer use cases such as enum-based localization, custom formatting, and late or dynamic text resolution without changing builder APIs.

Simplified ComboBox and Spinner typing

ComboBox and Spinner builders no longer require an explicit type witness. The new raw/typed builder split allows the item type to be inferred naturally from methods that supply a type (eg. items(...), value(...), model(...), or comparator(...)), reducing boilerplate while preserving full type safety once the type is established. For example:

FX.comboBox()                       // type is ComboBoxBuilder.Raw
    .items(List.of("A", "B", "C")   // type is now ComboBoxBuilder.Typed<String>
    .comparator( ... )              // accepts Comparator<String> only now
    .build();
Commits
  • 2656531 Add snapshots
  • f30dba7 Add build context and strategy infrastructure for fluent builders
  • 18ae899 Improve documentation
  • ee17022 Improve README.md for StyleSheets class: add benefits of inline method
  • dbd8de7 ComboBox and Spinner now establish their value type during building
  • 74589c6 Add new terminal builder method "with" for types accepting nodes
  • 0e303a4 Documentation improvements
  • 8d912d0 Make most builder methods non-terminating and add null checks
  • 440febc Clarify javadoc
  • b18b49f Add methods to configure pickOnBounds property in AbstractNodeBuilder
  • Additional commits viewable in compare view

Note
Automatic rebases have been disabled on this pull request as it has been open for over 30 days.

@dependabot dependabot Bot added dependencies Pull requests that update a dependency file java Pull requests that update Java code labels Feb 23, 2026
@crschnick
Copy link
Copy Markdown
Member

@dependabot rebase

Bumps [org.int4.fx:fx-values](https://github.com/int4-org/FX) from 0.4 to 0.5.
- [Release notes](https://github.com/int4-org/FX/releases)
- [Commits](int4-org/FX@0.4...0.5)

---
updated-dependencies:
- dependency-name: org.int4.fx:fx-values
  dependency-version: '0.5'
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
@dependabot dependabot Bot force-pushed the dependabot/gradle/org.int4.fx-fx-values-0.5 branch from 68e3046 to 1567fc3 Compare May 1, 2026 06:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file java Pull requests that update Java code

Development

Successfully merging this pull request may close these issues.

1 participant