Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Initial work on adding internationalization. #417

Closed
wants to merge 5 commits into from
Closed

Initial work on adding internationalization. #417

wants to merge 5 commits into from

Conversation

MFAshby
Copy link
Contributor

@MFAshby MFAshby commented Jun 6, 2021

From #363

This commit adds lv_i18n tooling for translating user-facing strings. It also adds a new settings page to allow selecting between up to 4 languages.

Done:
[X] Language selector for the settings screen (caveat, this can only support up to 4 languages at the moment)
[X] Replace hard-coded english text with lookups (done most text I can find)
[X] Update main README for contributing translations

Known issue:
Some characters aren't rendering properly, for example Batería is rendering as Batera in the settings menu.

Known limitation:
The settings screen will only support up to 4 languages.

TODO:
[ ] Fix rendering issues for characters outside the usual ASCII
[ ] Calculate firmware size increase due to translations
[ ] If unacceptably large, either:

  1. build multiple firmwares, one for each language, and remove the user selection at runtime.
  2. wait until external flash memory can be used, and store strings files in it External flash usage #321

MFAshby added 5 commits June 24, 2021 21:33
This commit adds lv_i18n to the build, and starts to use keys to lookup
text on the Settings screen.

WIP, TODO:
- Language selector for the settings screen
- Consider building locale-specific DFU to cut down on size
Add default en-GB locale to settings.
Make the checkboxes on language settings page function as radio
selector.
Extended translations.md and added extract and compile scripts rather
than copying commands from a readme to perform these operations.

Added some basic spanish translations for the settings menu to test.
@MFAshby
Copy link
Contributor Author

MFAshby commented Jun 24, 2021

DFU from this branch
pinetime-mcuboot-app-dfu-1.2.0.zip

@MFAshby MFAshby marked this pull request as ready for review June 24, 2021 21:38
@MFAshby
Copy link
Contributor Author

MFAshby commented Jun 24, 2021

Grainy photos of settings screen and (probably badly) translated menu.
IMG_20210624_223227466
IMG_20210624_223252025

@Avamander
Copy link
Collaborator

Needs rebasing, it's probably easier to do incrementally than in big batches. Definitely something that'll be part of InfiniTime at some point and this PR is a great start.

@dyamon dyamon mentioned this pull request Sep 9, 2021
@MFAshby
Copy link
Contributor Author

MFAshby commented Sep 14, 2021

Practically it's probably better to just start again with these code changes, they were quite simple.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants