-
Notifications
You must be signed in to change notification settings - Fork 97
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
[LVGL] Add multilanguage support (i18n) #274
Comments
I think basic multi language support would be quite easy to achieve as the text label The localised strings are handled offline in .yml files and a node script is used to generate the C code. The include of "lv_i18n.h" can be manually added into screens.c settings. Reference to lv_i18n: Reference to squareline studio's usage: |
We also need to add support through expressions. So you can write something like this:
Here syntax will be |
We should support LVGL YML format for lv_i18n.h:
|
I'd still like to propose to do this in two steps in case this project is low on developers: If the tiny little effort for step 1 is done right away it has the big advantage that migrants from squareline studio can use this feature as they did in the past without losing this functionality for their project. Step 1 is needed anyway and may not change much when developing step 2 at a later stage. |
I implemented Step 1 in the master. In "Label", "Textarea", "Dropdown" and "Roller" widgets you can now select for "Text" and "Options" a new option called "Translated literal": Here is the project I used for testing: https://github.com/eez-open/lvgl_test_translate_literal Here is the place where I putted i18n files: https://github.com/eez-open/lvgl_test_translate_literal/tree/master/src/i18n I added following line to And added these lines in |
No description provided.
The text was updated successfully, but these errors were encountered: