Re: Missing parts of translatable string in ‘Welcome’ app
Luigi Toscano
luigi.toscano at tiscali.it
Sat Jan 21 14:23:09 GMT 2023
Karl Ove Hufthammer ha scritto:
> In the new ‘Welcome’ app, there’s a long, multi-line string that begins with
> the text ‘KDE Connect lets you integrate your phone with your computer in
> various ways:’
> https://invent.kde.org/plasma/plasma-welcome/-/blob/master/src/contents/ui/pages/PowerfulWhenNeeded.qml#L173-181
>
>
> However, in the corresponding POT file (plasma-welcome.pot), only the first
> line of the string is present. And if we translate it, the translation is not
> being used (as it doesn’t match the original string).
>
> The string in the .qml file was added in 2022, and the POT file last updated
> 2023-01-19, so it doesn’t seem to be a case of an outdated POT file.
>
> The .qml file uses a normal xi18nc() call, which looks correct. Any ideas
> what’s causing the problem?
(assing plasma-devel in CC):
I suspect, but please others correct me, this may be related to the handling
of strings in Javascript/QML, as previously discussed here:
https://phabricator.kde.org/D24073 and https://phabricator.kde.org/T11721
If that's the case, the strings should be reformatted accordingly, either as a
long string on a single line, or using the format:
i18n("foo \
bar \
baz")
Ciao
--
Luigi
More information about the Plasma-devel
mailing list