effad / ValidatorFX

A form validation library for JavaFX
BSD 3-Clause "New" or "Revised" License
221 stars 19 forks source link

Allow buttons to be disabled and show a tooltip containing the validation problems #21

Closed effad closed 2 years ago

effad commented 2 years ago

At the moment one can easily disable a button if validation fails, e.g.: signUp.disableProperty().bind(validator.containsErrorsProperty()); But due to JDK-8090379 one cannot easily display a tooltip that will hint the user as to why the button is not enabled.

effad commented 2 years ago

FIX: Created a generic TooltipWrapper class that can wrap around any node. The TooltipWrapper can be used indepdently from the rest of ValidatorFX thus providing a generic workaround. To still be easily usable convenience methods to create a nice tooltip text have been added to Validator. ValidatorFX adapted to give an example of how to use the TooltipWrapper. README.MD extended.

effad commented 2 years ago

Fix contained in version 0.2.1