Bug 436299 - German Translation of Buttons
Summary: German Translation of Buttons
Status: RESOLVED FIXED
Alias: None
Product: digikam
Classification: Applications
Component: Usability-i18n (show other bugs)
Version: 7.2.0
Platform: Microsoft Windows Microsoft Windows
: NOR normal
Target Milestone: ---
Assignee: Digikam Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-04-28 08:54 UTC by herb
Modified: 2021-05-20 12:02 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In: 7.3.0
Sentry Crash Report:


Attachments
debug output of deigiKam start after language change (67.86 KB, text/plain)
2021-05-16 08:47 UTC, herb
Details

Note You need to log in before you can comment on or make changes to this bug.
Description herb 2021-04-28 08:54:13 UTC
SUMMARY
Hallo,

Working with German GUI of digiKam 7.2.0 (official release), but also with 7.3.0 snapshots I have seen that many buttons still have English captions.

Some examples:
- Album --> Neu
        --> Eigenschaften           has Buttons: OK - Cancel - Help
- Album --> Umbenennen                           OK - Cancel
- Album --> Löschen                              Cancel - Löschen
- Stichwort --> Neu
            --> Eigenschaften                    OK - Cancel - Help
- Stichwort --> Löschen                          Yes - Cancel
- Eintrag --> Umbenennen                         OK - Cancel - Help
- Eintrag --> In den Papierkorb verschieben      Cancel - Verschieben
- Eintrag --> Metadaten bearbeiten               Zurück - OK - Weiter
                                                  Close - Apply - Über
- Eintrag --> Geolokalisierung bearbeiten        Close - Apply - Über
- Hilfe --> unterstützte RAW Kameras             OK - ...kopieren - Help
- Einstellungen --> digiKam einrichten           OK - Cancel - Help
- Einstellungen --> Sprache einrichten           OK - Abbrechen
- Exportieren --> Hochladen                      OK - Close
- Importieren --> Dateien hinzufügen             Choose - Cancel
- Foto Druck                                     Back - Next - Cancel
                                                  Über

I asked on the mailing-list of German translators what must be done in order to get proper German strings.
The answer was:
- maybe it is a Windows specific problem or
- a problem with installation medium

Thanks for your help in advance
herb


STEPS TO REPRODUCE
1. 
2. 
3. 

OBSERVED RESULT


EXPECTED RESULT


SOFTWARE/OS VERSIONS
Windows: 
macOS: 
Linux/KDE Plasma: 
(available in About System)
KDE Plasma Version: 
KDE Frameworks Version: 
Qt Version: 

ADDITIONAL INFORMATION
Comment 1 Maik Qualmann 2021-04-28 11:04:16 UTC
In general, the German translation is currently up to date with digiKam-7.3.0. So before we added context information and existing translations became invalid. As before, there are also some current strings that have not yet been translated. So far everything is good again for the most part.

This problem affects the buttons of the dialogs. These are not fully translated in either the AppImage or the Windows version. In my native Linux version there are no problems, the dialog buttons are German.

So I suspect a missing translation file from either KF5 or Qt in the bundle we created. 

Maik
Comment 2 Maik Qualmann 2021-04-28 11:20:39 UTC
Under Windows we have 2 directories with translation files:

C:\Program Files\digiKam\translations

C:\Program Files\digiKam\data\locale\de\LC_MESSAGES

Unfortunately, it doesn't help to copy the corresponding German Qt files from "translations" into the German directory ...\de\LC_MESSAGES

Maik
Comment 3 Maik Qualmann 2021-05-03 18:48:45 UTC
Git commit ecfb7664e7f328a491224b438b86d38e42effb31 by Maik Qualmann.
Committed on 03/05/2021 at 18:47.
Pushed by mqualmann into branch 'master'.

try to add Qt translation with QTranslator

M  +30   -0    core/app/main/main.cpp

https://invent.kde.org/graphics/digikam/commit/ecfb7664e7f328a491224b438b86d38e42effb31
Comment 4 Maik Qualmann 2021-05-04 11:35:52 UTC
The patch works, Qt texts are now translated. The patch still needs adjustments, at the moment a few languages are not supported and we do not have to read the system language setting, but the currently set application language.

@Gilles, I only had a quick look at the unzipped AppImage. I think the Qt translation files are currently not included. What is the situation with MacOS? Dialog button translated? 

Maik
Comment 5 caulier.gilles 2021-05-04 11:42:45 UTC
Hi Maik,

The Qt translation must be included in all bundles.

https://invent.kde.org/graphics/digikam/-/blob/master/project/bundles/appimage/04-build-appimage.sh#L167

And this what i see in current AppImage build log:

[root@localhost logs (master)]# cat build-appimage.full.log 
04-build-appimage.sh : build digiKam AppImage bundle.
-----------------------------------------------------
Check run as root passed...
CPU Cores to use : 1
Mageia release 6 (Official) for x86_64
Architecture is x86_64
Register invent.kde.org
# Host invent.kde.org found: line 4
# Host invent.kde.org found: line 5
# Host invent.kde.org found: line 6
/root/.ssh/known_hosts updated.
Original contents retained as /root/.ssh/known_hosts.old
# invent.kde.org:22 SSH-2.0-OpenSSH_7.6p1 Ubuntu-4ubuntu0.3
# invent.kde.org:22 SSH-2.0-OpenSSH_7.6p1 Ubuntu-4ubuntu0.3
# invent.kde.org:22 SSH-2.0-OpenSSH_7.6p1 Ubuntu-4ubuntu0.3
Register deino.kde.org
# Host deino.kde.org found: line 4
# Host deino.kde.org found: line 5
# Host deino.kde.org found: line 6
/root/.ssh/known_hosts updated.
Original contents retained as /root/.ssh/known_hosts.old
# deino.kde.org:22 SSH-2.0-OpenSSH_8.2p1 Ubuntu-4ubuntu0.2
# deino.kde.org:22 SSH-2.0-OpenSSH_8.2p1 Ubuntu-4ubuntu0.2
# deino.kde.org:22 SSH-2.0-OpenSSH_8.2p1 Ubuntu-4ubuntu0.2
---------- Build icons-set ressource

-- Configuring done
-- Generating done
-- Build files have been written to: /home/gilles/Documents/7.x/project/bundles/appimage/icon-rcc
Scanning dependencies of target qrcAlias
[ 50%] Built target qrcAlias
Scanning dependencies of target icons
[ 75%] Generating breeze.rcc
[100%] Generating breeze-dark.rcc
[100%] Built target icons
---------- Prepare directories in bundle

---------- Copy Files in bundle

------------- Copy runtime data files

------------- Copy AppImage stream data file

------------- Copy QWebEngine bin data files

------------- Copy libgphoto2 drivers

------------- Copy sane backends

------------- Copy ImageMagick codecs

------------- Copy I18n

------------- Copy Qt translations files       <=========!!!!!!!!!

------------- Copy KF5 translations files

------------- Copy digiKam translations files

---------- Copy digiKam icons files

/usr/share/icons/hicolor/32x32/actions/albumfolder-importdir.png
/usr/share/icons/hicolor/32x32/actions/albumfolder-importimages.png
/usr/share/icons/hicolor/32x32/actions/albumfolder-new.png
/usr/share/icons/hicolor/32x32/actions/albumfolder-properties.png
/usr/share/icons/hicolor/32x32/actions/overexposure.png
/usr/share/icons/hicolor/32x32/actions/tag-addresbook.png
...
Comment 6 caulier.gilles 2021-05-04 11:44:56 UTC
For MacOS:

https://invent.kde.org/graphics/digikam/-/blob/master/project/bundles/macports/04-build-installer.sh#L324

I'm not sure at all...

Gilles
Comment 7 caulier.gilles 2021-05-04 11:48:10 UTC
In AppImage, only QtWebEngine translations are copied in the bundle :

[root@localhost translations]# ls -R
.:
qtwebengine_locales/

./qtwebengine_locales:
am.pak  bn.pak  da.pak  en-GB.pak   es.pak  fil.pak  gu.pak  hr.pak  it.pak  ko.pak  ml.pak  nb.pak  pt-BR.pak  ru.pak  sr.pak  ta.pak  tr.pak  zh-CN.pak
ar.pak  ca.pak  de.pak  en-US.pak   et.pak  fi.pak   he.pak  hu.pak  ja.pak  lt.pak  mr.pak  nl.pak  pt-PT.pak  sk.pak  sv.pak  te.pak  uk.pak  zh-TW.pak
bg.pak  cs.pak  el.pak  es-419.pak  fa.pak  fr.pak   hi.pak  id.pak  kn.pak  lv.pak  ms.pak  pl.pak  ro.pak     sl.pak  sw.pak  th.pak  vi.pak
[root@localhost translations]# pwd
/digikam.appdir/usr/translations
[root@localhost translations]# 

Gilles
Comment 8 caulier.gilles 2021-05-04 12:38:04 UTC
Under Windows, Qt5 translations are copied in the bundle :

https://invent.kde.org/graphics/digikam/-/blob/master/project/bundles/mxe/04-build-installer.sh#L126

Gilles
Comment 9 caulier.gilles 2021-05-04 12:46:55 UTC
Git commit 821df8a8836700380e884d5916feb356461b856d by Gilles Caulier.
Committed on 04/05/2021 at 12:46.
Pushed by cgilles into branch 'master'.

host Qt translation files in MacoOS bundle

M  +1    -0    project/bundles/macports/04-build-installer.sh

https://invent.kde.org/graphics/digikam/commit/821df8a8836700380e884d5916feb356461b856d
Comment 10 caulier.gilles 2021-05-04 12:51:21 UTC
Git commit ac3c300aadacfe677c8a820652b272393c974d24 by Gilles Caulier.
Committed on 04/05/2021 at 12:50.
Pushed by cgilles into branch 'master'.

Do not skip Qt translations build for AppImage bundle

M  +0    -1    project/bundles/3rdparty/ext_qt/5.14/CMakeLists.txt
M  +0    -1    project/bundles/3rdparty/ext_qt/5.15/CMakeLists.txt

https://invent.kde.org/graphics/digikam/commit/ac3c300aadacfe677c8a820652b272393c974d24
Comment 11 Maik Qualmann 2021-05-04 15:53:12 UTC
*** Bug 436586 has been marked as a duplicate of this bug. ***
Comment 12 Maik Qualmann 2021-05-04 17:38:09 UTC
Git commit de437ba82dc5829c6a7fb93c3ca3de3f7e9b55fb by Maik Qualmann.
Committed on 04/05/2021 at 17:36.
Pushed by mqualmann into branch 'master'.

load the correct application translation

M  +13   -9    core/app/main/main.cpp

https://invent.kde.org/graphics/digikam/commit/de437ba82dc5829c6a7fb93c3ca3de3f7e9b55fb
Comment 13 Maik Qualmann 2021-05-04 19:09:28 UTC
Git commit 8906cf47de5ed77ae92ba6face3d080a7d666f4f by Maik Qualmann.
Committed on 04/05/2021 at 19:08.
Pushed by mqualmann into branch 'master'.

add Qt translation to Showfoto

M  +7    -7    core/app/main/main.cpp
M  +33   -0    core/showfoto/main/main.cpp

https://invent.kde.org/graphics/digikam/commit/8906cf47de5ed77ae92ba6face3d080a7d666f4f
Comment 14 caulier.gilles 2021-05-06 07:26:42 UTC
Maik,

AppImage bundle 7.3.0 daily build is updated and now it must includes Qt translations.

I still MacOS package to rebuild;, and i see a broken packaging yesterday evening. I will fix it.

Gilles
Comment 15 Maik Qualmann 2021-05-06 08:11:24 UTC
The "translations" folder is not found. This would be found in the AppImage if we moved it to share/digikam. Then the translation of the file dialogs and buttons works without problems.

Maik
Comment 16 caulier.gilles 2021-05-06 11:10:41 UTC
Git commit 7be34db7e9e48ecef1a1d99392f8f17dd2baca95 by Gilles Caulier.
Committed on 06/05/2021 at 10:57.
Pushed by cgilles into branch 'master'.

Fix place to store Qt translations in AppImage

M  +5    -1    project/bundles/appimage/04-build-appimage.sh

https://invent.kde.org/graphics/digikam/commit/7be34db7e9e48ecef1a1d99392f8f17dd2baca95
Comment 17 caulier.gilles 2021-05-06 13:48:06 UTC
Maik,

AppImage have been just rebuilt...

Gilles
Comment 18 Maik Qualmann 2021-05-06 16:15:47 UTC
AppImage works fine now. The bug 415605 is also fixed. 

Maik
Comment 19 Maik Qualmann 2021-05-10 18:10:16 UTC
Git commit 465c25dd9772b4d072b832c523ba4fffca4faf1f by Maik Qualmann.
Committed on 10/05/2021 at 18:08.
Pushed by mqualmann into branch 'master'.

load Qt translations and polish debug
Related: bug 415605
FIXED-IN: 7.3.0

M  +2    -2    NEWS
M  +2    -3    core/app/main/main.cpp
M  +2    -3    core/showfoto/main/main.cpp

https://invent.kde.org/graphics/digikam/commit/465c25dd9772b4d072b832c523ba4fffca4faf1f
Comment 20 herb 2021-05-14 10:49:48 UTC
Hello,

thanks for your investigations.
But please allow an additional question:
- Is the language of the button-texts the language of the PC-system
  (in my case German) or
- is it the language assigned tp digiKam using "Configure language"

I ask this question because with digiKam 7.3.0 snapshot 13.5.2021 all button texts are in German - also in case I want to work with an English digiKam.

Thanks for your help in advance.
herb
Comment 21 Maik Qualmann 2021-05-14 20:28:36 UTC
No, the Qt translation (i.e. dialog buttons, Qt file dialogs) i is definitely in the language specified in digiKam. I've tested this several times under a real Windows 7 computer and a Windows 10 VM.
Otherwise post the DebugView output from the start of digiKam, the recognized language and loaded translation state is displayed.

Maik
Comment 22 herb 2021-05-16 08:47:28 UTC
Created attachment 138476 [details]
debug output of deigiKam start after language change

Hello Maik,

thanks for your answer.

I am working on Windows 10 system in German.
I installed digiKam debug-version built on 15.5.2021.
Then I did the following:
- I started digiKam with German language and changed digiKam language to
  English-US and left digiKam.
- I started debugView
- I started digiKam and checked the button language with "Configure digiKam"
  dialog. It was again German.

Attached please find the output collected by debugView.
Comment 23 Maik Qualmann 2021-05-16 11:12:29 UTC
Git commit 285e38d0bf8efc02f21ca087404c694250de3068 by Maik Qualmann.
Committed on 16/05/2021 at 11:11.
Pushed by mqualmann into branch 'master'.

force current locale from the language config file

M  +17   -0    core/app/main/main.cpp
M  +17   -0    core/showfoto/main/main.cpp

https://invent.kde.org/graphics/digikam/commit/285e38d0bf8efc02f21ca087404c694250de3068
Comment 24 Maik Qualmann 2021-05-17 05:35:43 UTC
Git commit f596ea601da6e7e0e7deb0b17eee4577e1bf48f4 by Maik Qualmann.
Committed on 17/05/2021 at 05:35.
Pushed by mqualmann into branch 'master'.

fix decode the language from config file

M  +1    -1    core/app/main/main.cpp
M  +1    -1    core/showfoto/main/main.cpp

https://invent.kde.org/graphics/digikam/commit/f596ea601da6e7e0e7deb0b17eee4577e1bf48f4
Comment 25 herb 2021-05-20 09:33:37 UTC
Hello Maik,

thanks again for your investigations and corrections.
I am sorry, but still not all buttons behave as expected.

With digiKam snapshot from 19.5.2021 I did a short test and have seen that with digikam-language==English some buttons have German text-strings (on my German Windows):
- settings --> configure toolbar
-          --> configure language
-          --> configure Keyboard shortcut

Please be aware that I did not check all possible dialogs etc.

Thanks in advance
herb
Comment 26 Maik Qualmann 2021-05-20 11:50:38 UTC
At the moment I only have a Windows7 here, but everything is translated (German Windows, digiKam language is US English). But I know that Windows10 behaves differently and the QLocale has the system language when digiKam starts. However, we set this to the language set by digiKam. The problem is that the missing translations come from the KF5 framework. We may not have any influence on where they get the currently set language from.

Maik
Comment 27 Maik Qualmann 2021-05-20 12:02:52 UTC
I just see that the tool button "full screen mode" is not translated in Windows7 either. It also comes from the KF5 framework. I open bug 415605 again, we continue there, as the Qt internal things are now translated correctly.

Maik