Adding support for selecting language dynamically #345
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Motivation
Following the idea of supporting i18n I think it would be good to select the language from the UI directly.
Note: This is work in progress and I am sending the PR to check if this is something you want to support and if you agree on the approach if you confirm this I can continue working in the final solution and make the remaining components bound to the resource factory
Solution based on https://stackoverflow.com/questions/32464974/javafx-change-application-language-on-the-run
Proposal
Adding a combobox with the available language and instead of setting text directly into components make they bound to a resource factory so a change in the resource factory will make them to update.
Initial UI
After changing language
Only "Start" translate to "Empezar" because that is the only translation available.
Changes