Example: On the initial main screen, there are two instances of "Opacity: 100%" (or some other opacity value). These percentage values look like they are hard-coded to %1%. But however, there are some languages that prepend the percentage sign to the number or use spaces and else. In order to able to fix it, these values should be open for translation.
Hm, the code is following the recommended way of setting labels, value and suffix on the sliders: slOpacity->setPrefix(QString("%1 ").arg(i18n("Opacity:"))); slOpacity->setSuffix(i18n("%")); slider->setValue(100); Are there any sliders in Krita where you think this is done correctly?
Created attachment 154435 [details] screenshot of translatable strings Sure, please see the screenshot. These are the strings that are allowed to be translated. I am not fully versed on how KF sliders work, but I think replacing the QString with an i18n wrapper (and omitting the second line) would expose the string for translation.
Thanks for your comment! Automatically switching the status of this bug to REPORTED so that the KDE team knows that the bug is ready to get confirmed. In the future you may also do this yourself when providing needed information.
This is related to a patch I have: https://invent.kde.org/graphics/krita/-/merge_requests/1159 I'm not sure if I will get back to it soon.
Okay, setting to confirmed then.
So, thanks to Alvin and Dmitry's work, and some contribution from my side, most of these are tackled. The remaining ones are here: plugins/tools/tool_transform2/wdg_tool_transform.ui:971 plugins/tools/tool_transform2/wdg_tool_transform.ui:987 libs/ui/forms/wdgdisplaysettings.ui:434 libs/ui/layerstyles/wdgInnerGlow.ui:220 libs/ui/layerstyles/wdgInnerGlow.ui:322 libs/ui/layerstyles/wdgInnerGlow.ui:351 plugins/generators/pattern/wdgpatternoptions.ui:90 plugins/generators/pattern/wdgpatternoptions.ui:116 plugins/impex/jxl/kis_wdg_options_jpegxl.ui:638 plugins/impex/jxl/kis_wdg_options_jpegxl.ui:690 plugins/impex/jxl/kis_wdg_options_jpegxl.ui:837 plugins/impex/tiff/kis_wdg_options_tiff.ui:277 plugins/impex/webp/kis_wdg_options_webp.ui:82 plugins/impex/webp/kis_wdg_options_webp.ui:305 plugins/impex/webp/kis_wdg_options_webp.ui:328 plugins/impex/webp/kis_wdg_options_webp.ui:466 plugins/impex/webp/kis_wdg_options_webp.ui:596 plugins/impex/webp/kis_wdg_options_webp.ui:684 plugins/impex/webp/kis_wdg_options_webp.ui:750 plugins/impex/webp/kis_wdg_options_webp.ui:773 plugins/paintops/curvebrush/kis_curve_paintop_settings.cpp:137 plugins/paintops/experiment/kis_experiment_paintop_settings.cpp:78 plugins/paintops/experiment/kis_experiment_paintop_settings.cpp:147 plugins/paintops/libpaintop/KisCurveOptionWidget.cpp:61 plugins/paintops/libpaintop/KisCurveOptionWidget.cpp:78 plugins/paintops/libpaintop/KisDynamicSensorFactoryRegistry.cpp:20 plugins/paintops/libpaintop/KisDynamicSensorFactoryRegistry.cpp:22 plugins/paintops/libpaintop/KisDynamicSensorFactoryRegistry.cpp:23 plugins/paintops/libpaintop/KisDynamicSensorFactoryRegistry.cpp:24 plugins/paintops/libpaintop/KisDynamicSensorFactoryRegistry.cpp:25 plugins/paintops/libpaintop/KisDynamicSensorFactoryRegistry.cpp:26 plugins/paintops/libpaintop/KisDynamicSensorFactoryRegistry.cpp:27 plugins/paintops/mypaint/MyPaintSensorPack.cpp:48 plugins/paintops/mypaint/MyPaintSensorPack.cpp:49 plugins/paintops/mypaint/MyPaintSensorPack.cpp:50 plugins/paintops/spray/KisSprayShapeOptionModel.cpp:88 I want to have a look at these before Krita 5.3, but if someone is bored and wants to have a look, please go ahead. :)
Updated list of remaining changes need to be made: libs/ui/layerstyles/wdgInnerGlow.ui:220 libs/ui/layerstyles/wdgInnerGlow.ui:322 libs/ui/layerstyles/wdgInnerGlow.ui:351 plugins/generators/pattern/wdgpatternoptions.ui:90 plugins/generators/pattern/wdgpatternoptions.ui:116 plugins/impex/tiff/kis_wdg_options_tiff.ui:277 plugins/paintops/curvebrush/kis_curve_paintop_settings.cpp:137 plugins/paintops/experiment/kis_experiment_paintop_settings.cpp:78 plugins/paintops/experiment/kis_experiment_paintop_settings.cpp:147 plugins/paintops/libpaintop/KisCurveOptionWidget.cpp:61 plugins/paintops/libpaintop/KisCurveOptionWidget.cpp:78 plugins/paintops/libpaintop/KisDynamicSensorFactoryRegistry.cpp:20 plugins/paintops/libpaintop/KisDynamicSensorFactoryRegistry.cpp:22 plugins/paintops/libpaintop/KisDynamicSensorFactoryRegistry.cpp:23 plugins/paintops/libpaintop/KisDynamicSensorFactoryRegistry.cpp:24 plugins/paintops/libpaintop/KisDynamicSensorFactoryRegistry.cpp:25 plugins/paintops/libpaintop/KisDynamicSensorFactoryRegistry.cpp:26 plugins/paintops/libpaintop/KisDynamicSensorFactoryRegistry.cpp:27 plugins/paintops/mypaint/MyPaintSensorPack.cpp:48 plugins/paintops/mypaint/MyPaintSensorPack.cpp:49 plugins/paintops/mypaint/MyPaintSensorPack.cpp:50 plugins/paintops/spray/KisSprayShapeOptionModel.cpp:88
There is now also support for this out of the box for QSpinBox in ki18n. API: setupSpinBoxFormatString(): https://api.kde.org/frameworks/ki18n/html/namespaceKLocalization.html Blog entry: https://www.volkerkrause.eu/2024/08/16/kf6-localized-spin-box-prefix-suffix.html