issues with Unicode characters in UI dialogues (at least on Windows)

Cristian Secară liste at secarica.ro
Tue Jan 4 14:55:52 CET 2022


(message resent with links to snapshots instead of attached snapshots; the list rejected my previous message due to "Message body is too big: 97216 bytes with a limit of 60 KB"; hmm: 94 KiB too big in year 2022 ? this reminds me of the BBS era...)

There are two type of Unicode issues related to some UI dialogues - at least on Windows (in my case version 10, 64bit).

1. Pure Unicode characters that are not present in 8-bit Windows codepage

With reference to the snapshot
https://www.secarica.ro/traduceri/misc/01_pinentry-qt_prompt_from_claws-mail_ro.png
the translation for "Cancel" button contains the ț character (U+021B) that is not part of any 8-bit Windows codepage (let alone the current one) and because of that it displays a ? instead, which is common for 8-bit only (i.e. ancient) programs; more than that, as seen in the snapshot
https://www.secarica.ro/traduceri/misc/02_pinentry-qt_prompt_from_claws-mail_ro_retry.png
this happens also with the translated string "Bad Passphrase", which I guess it comes from the combination of these two strings:

#: agent/call-pinentry.c:1566 agent/call-pinentry.c:1830
msgid "SETERROR %s (try %d of %d)"
msgstr "SETERROR %s (încercarea %d din %d)"

#: agent/call-pinentry.c:1622 agent/call-pinentry.c:1885
msgid "Bad Passphrase"
msgstr "Frază-parolă greșită"

To be noted that the rest of the strings in that dialog *are* correct, despite the presence of the same ț character elsewhere ("Introduceți fraza-parolă etc.")

These dialogues are related to Claws Mail, but the next ones are related to Mozilla Firefox and an installed extension called Mailvelope.

2. Mess with UTF-8 characters

With reference to the snapshot
https://www.secarica.ro/traduceri/misc/03_pinentry-qt_prompt_from_ff_ro_utf-u_error.png
the translation of the main text is screwed at every UTF-8 character; at the same time, in the snapshot
https://www.secarica.ro/traduceri/misc/04_pinentry-qt_prompt_from_ff_ro_utf-u_error_retry.png
it can be observed a mix of problem from 1. (i.e. just out-of-8-bit-codepage issue on the red string) combined with this UTF-8 mess.

*To be noted here the translated string that says "Notă: cerere de la browserul web."*

This sting is this one:

#: agent/command.c:823
msgid "Note: Request from the web browser."
msgstr "Notă: cerere de la browserul web."

3. Just about the same dialogues, *except for a single difference*: on the above msgstr string, I eliminated the ă character, thus leaving the "Nota: cerere de la browserul web." string as pure ASCII only; now the UTF-8 mess no longer occur, only the out-of-8-bit-codepage issue remains:
https://www.secarica.ro/traduceri/misc/05_pinentry-qt_prompt_from_ff_ro.png
https://www.secarica.ro/traduceri/misc/06_pinentry-qt_prompt_from_ff_ro_retry.png
That ă character triggers in somehow the UTF-8 mess that follows.

Maybe this issue has something to do with this quite complex sting:

#: g10/passphrase.c:529
msgid ""
"%s\n"
"\"%.*s\"\n"
"%u-bit %s key, ID %s,\n"
"created %s%s.\n"
"%s"
msgstr ""
"%1$s\n"
"„%3$.*2$s”\n"
"cheie %5$s de %4$u de biți, ID %6$s,\n"
"creată în data de %7$s%8$s\n"
"%9$s"

4. Again on Claws Mail, with reference to the snapshot
https://www.secarica.ro/traduceri/misc/07_claws-mail_libgpg-error_utf-8_display_error_1.png
an error string that is passed from libgpg-error is displayed wrong at UTF-8 encoded characters (this particular string is when canceling an attempt to decrypt a message).

The error string comes from here:

#: src/err-codes.h:127
msgid "Operation cancelled"
msgstr "Operațiune anulată"

This one has nothing to do with the out-of-8-bit-codepage, since the ă one *is* part of both CP1250 and ISO-8859-2 (while I am sure that the GTK+, on which Claws Mail is based, is, or should be, always Unicode).

??

Cristi

-- 
Cristian Secară
https://www.secarica.ro



More information about the Gnupg-devel mailing list