Bug 440365

Summary: digikam geolocation editor decimal separator broken in some locales
Product: [Applications] digikam Reporter: Lukas Jirkovsky <l.jirkovsky>
Component: Geolocation-WorkflowAssignee: Digikam Developers <digikam-bugs-null>
Status: RESOLVED FIXED    
Severity: normal CC: caulier.gilles
Priority: NOR    
Version First Reported In: 7.3.0   
Target Milestone: ---   
Platform: Arch Linux   
OS: Linux   
Latest Commit: Version Fixed In: 7.4.0
Sentry Crash Report:

Description Lukas Jirkovsky 2021-07-28 17:33:20 UTC
SUMMARY
When entering a location in the geolocation editor, the decimal separator doesn't work as expected when the locale uses decimal separator different from '.'.

STEPS TO REPRODUCE
* Change to a locale that uses a different decimal separator. I'm using Czech locale (uses ',' to separate decimals).
* When I try to input location as "49.68", the editor won't allow me to write '.'.
* When I try to input location as "49,68", the editor will allow to enter the location, but as soon as the changes are applied, the whole input field is reset.

WORKAROUNDS
I found two workarounds.

One is to write only "49" first and then apply. Next select only the part after '.' an overwrite it with the desired value ("68") here and apply.

The other one is to run digikam in eg. "C" locale.

SOFTWARE/OS VERSIONS
Digikam 7.2.0
OS: Arch Linux
KDE Plasma Version: 5.22.3
KDE Frameworks Version: 5.83.0
Qt Version: 5.15.2
Comment 1 Lukas Jirkovsky 2021-07-28 18:05:45 UTC
The problem also occurs in Digikam 7.3.0, KDE Frameworks 5.84.0, Qt 5.15.2
Comment 2 Maik Qualmann 2021-07-28 20:49:08 UTC
Git commit 4b581f26cbb6472504292bc88c80ac6be0bdf679 by Maik Qualmann.
Committed on 28/07/2021 at 20:47.
Pushed by mqualmann into branch 'master'.

use QLocale to use the correct decimal point
FIXED-IN: 7.4.0

M  +2    -1    NEWS
M  +9    -9    core/dplugins/generic/metadata/geolocationedit/dialog/gpsitemdetails.cpp
M  +2    -2    core/utilities/geolocation/geoiface/items/gpsitemcontainer.cpp

https://invent.kde.org/graphics/digikam/commit/4b581f26cbb6472504292bc88c80ac6be0bdf679