Skip to content
Snippets Groups Projects
Commit b830d597 authored by Alexandru Croitor's avatar Alexandru Croitor
Browse files

Initial translation API review notes

Still need to cover leftovers
parent fe8027d2
No related branches found
No related tags found
No related merge requests found
......@@ -32,15 +32,33 @@ There is an exmaple snippet in doc page of `qt_add_translations`, but there's no
Has "since qt version" blurb.
**Notes:**
**Action points:**
Rename `I18N_NATIVE_LANGUAGE` to `I18N_DEVELOPMENT_LANGUAGE` or `I18N_SOURCE_LANGUAGE`?
Currently it is called plurals-only option in lupdate. Where is NATIVE coming from?
Final proposed synopsis:
```
set(QT_I18N_NO_GENERATE_DEVELOPMENT_LANGUAGE_PLURALS_ONLY_FILE TRUE)
qt_standard_project_setup(
I18N_SOURCE_LANGUAGE en
I18N_TRANSLATED_LANGUAGES fr de
)
````
**Action points:**
AP: Rename `I18N_NATIVE_LANGUAGE` to `I18N_SOURCE_LANGUAGE`
AP: Rename `I18N_LANGUAGES` to `I18N_TRANSLATED_LANGUAGES`
AP: Always generates plurals file source language unless opted out
AP: Add opt out QT_I18N_NO_GENERATE_DEVELOPMENT_LANGUAGE_PLURALS_ONLY_FILE
AP: Default to english if `I18N_SOURCE_LANGUAGE` is not set, no warning, no error,
because Info.plist created by xcode new project wizard implicitly has english
AP: Don't add example snippet, instead add see also link to `qt_add_translations`
paragraph that also calls `qt_standard_project_setup`
AP: If source language is specified also to `I18N_TRANSLATED_LANGUAGES`,
generate full strings for it, and not plurals file
AP: Consider not generating plurals if no plurals in code,
need care that cmake file dependencies still work
## qttools
......@@ -60,7 +78,10 @@ No "since qt version" blurb.
**Notes:**
**Action points:**
AP: Mention the old deprecated signature in the synopsis, so there will be 2 signatures.
AP: Introduce since qt verison blurb.
AP: Update example snippet with something richer
AP: Update `NATIVE_TS_FILE` to `PLURALS_TS_FILE`
### `qt_add_lrelease` - New API options and changed option
......@@ -251,8 +272,14 @@ Partial "since qt version" blurb for new / changed options.
**Notes:**
**Action points:**
AP: There is a use case to pass in extra qm files (e.g qt sdk translations) to
`qt_add_translations` to merge them, currently not released, open gerrit change,
possibly in Qt 6.8.
AP: Look into what happens when id-based translations are mixed with regular translations
https://doc.qt.io/qt-6/linguist-id-based-i18n.html
AP: Mention idbased option on qt_add_translations doc page, and link to page above
just mention `LRELEASE_OPTIONS -idbased`
AP: Kai: Talk to qt design team why they use idbased translations
### `qt_add_translations` - New API options and behavior change
......@@ -314,8 +341,6 @@ No "since qt version" blurb for new options.
**Action points:**
### `qt_add_lupdate` - New API options and behavior change
Add a way to specify the native language for i18n
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment