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

Facilitate translation of "device status" screen. #928

Draft
wants to merge 1 commit into
base: beta
Choose a base branch
from

Conversation

johnjohndoe
Copy link

@johnjohndoe johnjohndoe commented Nov 11, 2021

Description

  • Extract English texts into constants.
  • Add German translations.

Draft / To be discussed

Here are a few topics where I need your expertise before I can mark this PR as ready for review.

  • Do new constants have to be added to all translation files?
  • Clarify where to use FPSTR() or F().
  • Clarify what Last OTA means.
  • Clarify what Data Send Return means.

Testing

  • ⚠️ The changes have not been tested on a device.

+ Extract English texts into constants.
+ Add German translations.
@ricki-z
Copy link
Member

ricki-z commented Nov 14, 2021

Draft / To be discussed

Here are a few topics where I need your expertise before I can mark this PR as ready for review.

* [ ]  Do **new** constants have to be added to all translation files?

Yes, they have to be added to all files. Translators may otherwise forget to translate some of the strings.

* [ ]  Clarify where to use `FPSTR()` or `F()`.

I have found the following:

The purpose of the PSTR() macro is to configure the string to be used directly from flash memory. The string is then not loaded to dynamic memory at runtime as it would be without PROGMEM specifier set by the macro.
The purpose of the FPSTR() macro is to cast a string to 'dummy' FlashStringHelper type to help compiler choose the right overloaded function if dynamic memory and flash memory version of a function is available. An example would be the print function.
The F() macro combines this two macros. It makes the string a PROGMEM string and casts it to FlashStringHelper.

* [ ]  Clarify what `Last OTA` means.

"Last OTA" is the time of the last lookup for an new firmware version. It's not the time the last OTA was done.

* [ ]  Clarify what `Data Send Return` means.

'Data Send Return' is the result code of the last data transmission.

@johnjohndoe
Copy link
Author

johnjohndoe commented Nov 15, 2021

Thank you for your response. I have a few follow-up questions:

  • Do new constants have to be added to all translation files?

Yes, they have to be added to all files. Translators may otherwise forget to translate some of the strings.

Do you want me to put the English text in the language files where I am not able to provide the translation myself?

  • Clarify where to use FPSTR() or F().

[...] The F() macro combines this two macros. It makes the string a PROGMEM string and casts it to FlashStringHelper.

That sounds very much like that you want me to use the F() macro everywhere. Okay?

  • Clarify what Data Send Return means.

'Data Send Return' is the result code of the last data transmission.

Is this the status code of the HTTP response?

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