Bug 431003 - Running status of digikam not reflected in MacOS task bar
Summary: Running status of digikam not reflected in MacOS task bar
Status: RESOLVED FIXED
Alias: None
Product: digikam
Classification: Applications
Component: Bundle-MacOS (show other bugs)
Version: 7.2.0
Platform: macOS (DMG) macOS
: NOR normal
Target Milestone: ---
Assignee: Digikam Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-12-31 12:36 UTC by stef
Modified: 2021-01-06 17:02 UTC (History)
2 users (show)

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


Attachments
digiKam 7.2.0-todays-build in macOS dock, not launched (53.67 KB, image/png)
2021-01-03 10:04 UTC, Hackintosh HD
Details
digiKam 7.2.0-todays-build launched in macOS dock (51.33 KB, image/png)
2021-01-03 10:05 UTC, Hackintosh HD
Details
digikam.svg (525.43 KB, image/svg+xml)
2021-01-03 22:47 UTC, Hackintosh HD
Details
archive with resized SVG app icons (34.34 KB, application/zip)
2021-01-04 12:21 UTC, Hackintosh HD
Details
20200105_digiKam_macOS_dock_icon_after_launch_with_artefacts_in_top_left_corner.png (39.40 KB, image/png)
2021-01-05 08:21 UTC, Hackintosh HD
Details

Note You need to log in before you can comment on or make changes to this bug.
Description stef 2020-12-31 12:36:24 UTC
STEPS TO REPRODUCE
1. Install digiKam-7.2.0-beta2-MacOS-x86-64.pkg
2. Add the digikam app icon to the MacOS task bar
3. Start digikam and observe the dot indicator ("app running") besides the app icon on the MacOS task bar

OBSERVED RESULT
The dot is breifly shown but disappears right away despite digikam being normally running.

EXPECTED RESULT
The dot besides the digikam icon should be present as long as the app is running.

SOFTWARE/OS VERSIONS
digikam: 7.2.0-beta2
macOS: 10.14.6 (Mojave)
KDE Frameworks Version: 5.77.0 
Qt Version: 5.15.2

ADDITIONAL INFORMATION
-
Comment 1 caulier.gilles 2021-01-01 17:14:36 UTC
Happy new year...

What do you mean exactly ? here the process indicator on macOS task bar work as expected. Can you record a desktop video of the problem ?

Do you seen the same problem when digiKam icon is not attached to the task bar ?

Gilles Caulier
Comment 2 caulier.gilles 2021-01-02 14:20:37 UTC
Git commit 5f9af4c9c9ebe1fa237c81871546718a34f76770 by Gilles Caulier.
Committed on 02/01/2021 at 14:19.
Pushed by cgilles into branch 'master'.

Factoring macOS bundle prefix to access to internal Unix hierarchy

M  +20   -3    core/app/utils/digikam_globals.cpp
M  +41   -25   core/app/utils/digikam_globals.h
M  +3    -6    core/dplugins/generic/tools/expoblending/wizard/expoblendingintropage.cpp
M  +1    -1    core/dplugins/generic/tools/expoblending/wizard/expoblendingintropage.h
M  +3    -6    core/dplugins/generic/tools/panorama/wizard/panointropage.cpp
M  +1    -1    core/dplugins/generic/tools/panorama/wizard/panointropage.h
M  +4    -3    core/dplugins/generic/tools/sendbymail/wizard/mailintropage.cpp
M  +1    -1    core/dplugins/generic/tools/sendbymail/wizard/mailintropage.h
M  +1    -1    core/libs/album/engine/albumthumbnailloader.cpp
M  +2    -2    core/libs/database/server/databaseserver.cpp
M  +2    -2    core/libs/database/utils/widgets/dbsettingswidget.cpp
M  +1    -1    core/libs/database/utils/widgets/dbsettingswidget.h
M  +4    -3    core/libs/database/utils/widgets/dbsettingswidget_p.h
M  +4    -3    core/libs/dimg/filters/icc/iccprofile.cpp
M  +59   -57   core/utilities/setup/setupicc.cpp
M  +1    -1    core/utilities/setup/setupicc.h

https://invent.kde.org/graphics/digikam/commit/5f9af4c9c9ebe1fa237c81871546718a34f76770
Comment 3 caulier.gilles 2021-01-02 14:28:36 UTC
Now i can reproduce the problem.

If digiKam icon from lauchpad installed by PKG bundle is plug to taskbar, 2 digiKam icons are show at startup. Both use different icons in fact : first from digiKam core, second one from breeze theme.

The first icon corresponding to macOS applet is used to start a script which run  kbuildsycoca5 cli tool to update kservice cache, before to run real digiKam binary.

The applet do not live a lot and no taskbar activity can be show.

The second icon corresponding to real digiKam binary program has a long startup activity visible on taskbar.

In fact, the applet starting kbuildsycoca5 is never used under macOS, as we don't use KService/KIO/DBUS/etc... It's the same under Windows. It's only used under Linux.

I will remove the applet, which overload the macOS bundle for nothing...

Gilles Caulier
Comment 4 caulier.gilles 2021-01-02 21:57:42 UTC
Git commit 56e443e0e41b688f0faf1ca6e8d78ddd24668229 by Gilles Caulier.
Committed on 02/01/2021 at 21:47.
Pushed by cgilles into branch 'master'.

Remove macOS applets to start digiKam and Showfoto.
Simplify macOS bundle architecture.

M  +1    -1    core/app/utils/digikam_globals.cpp
M  +1    -1    project/bundles/macports/01-build-macports.sh
M  +1    -1    project/bundles/macports/02-build-extralibs.sh
M  +34   -76   project/bundles/macports/04-build-installer.sh
M  +1    -1    project/bundles/macports/common.sh
M  +2    -2    project/bundles/macports/config.sh
M  +1    -1    project/bundles/macports/fixbundledatapath.sh
M  +1    -1    project/bundles/macports/makeall.sh
M  +1    -1    project/bundles/macports/rll.py
M  +1    -1    project/bundles/macports/update.sh

https://invent.kde.org/graphics/digikam/commit/56e443e0e41b688f0faf1ca6e8d78ddd24668229
Comment 5 caulier.gilles 2021-01-03 06:02:42 UTC
Git commit 7b15b8b5b2fe95b5774e2598553370d57fe6d86c by Gilles Caulier.
Committed on 03/01/2021 at 06:01.
Pushed by cgilles into branch 'master'.

Fix description of internal macOS bundle

M  +56   -65   project/bundles/macports/README

https://invent.kde.org/graphics/digikam/commit/7b15b8b5b2fe95b5774e2598553370d57fe6d86c
Comment 6 caulier.gilles 2021-01-03 06:04:27 UTC
New macOS pre-release 7.2.0 PKG installer is available for testing at usual place:

https://files.kde.org/digikam/

Gilles Caulier
Comment 7 caulier.gilles 2021-01-03 06:42:03 UTC
Git commit 971cdc636ec5f2a2a6e67acdc72333bf3e89ff7f by Gilles Caulier.
Committed on 03/01/2021 at 06:39.
Pushed by cgilles into branch 'master'.

Overwrite breeze and breeze-dark digikam and showfoto svg icons to prevent 2 defferent versions used at startup in macOS taskbar.

M  +4    -0    project/bundles/macports/03-build-digikam.sh
M  +2    -2    project/bundles/macports/TODO
A  +696  -0    project/bundles/macports/data/digikam.svg
A  +682  -0    project/bundles/macports/data/showfoto.svg

https://invent.kde.org/graphics/digikam/commit/971cdc636ec5f2a2a6e67acdc72333bf3e89ff7f
Comment 8 Hackintosh HD 2021-01-03 10:03:24 UTC
Tested this morning's macOS build https://files.kde.org/digikam/digiKam-7.2.0-rc-20210103T072125-MacOS-x86-64.pkg with the following result:

1. digiKam now launches as one icon instance, there are in other words no longer two icons bouncing in the macOS dock.
2. While bouncing, the first hi-res icon, the object lens with engraved text, gets replaced by a (apparently lower-res) highly pixelated icon, the object lens without engraved text. All that within one icon instance (see 1. above).

Screenshots to follow.
Comment 9 Hackintosh HD 2021-01-03 10:04:23 UTC
Created attachment 134500 [details]
digiKam 7.2.0-todays-build in macOS dock, not launched

Screenshot: digiKam 7.2.0-todays-build in macOS dock, not launched
Comment 10 Hackintosh HD 2021-01-03 10:05:32 UTC
Created attachment 134501 [details]
digiKam 7.2.0-todays-build launched in macOS dock

Screenshot: digiKam 7.2.0-todays-build launched in macOS dock
Comment 11 Hackintosh HD 2021-01-03 10:07:39 UTC
Just FYI, because attachment handling doesn't seem to work with the two screenshots (at least not in my browser): They are PNG files.
Comment 12 caulier.gilles 2021-01-03 10:10:10 UTC
I can reproduce the dysfunction with no text icon when application start in taskbar. I check it now...

Gilles
Comment 13 caulier.gilles 2021-01-03 13:29:41 UTC
Git commit bb45db16403cb112a5cebdba6f39781ba38a369a by Gilles Caulier.
Committed on 03/01/2021 at 13:28.
Pushed by cgilles into branch 'master'.

Cleanup rcc cache before to rebuild icons ressources

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

https://invent.kde.org/graphics/digikam/commit/bb45db16403cb112a5cebdba6f39781ba38a369a
Comment 14 caulier.gilles 2021-01-03 13:57:32 UTC
Git commit defae795563b94931e0da70a434dff9f162400a5 by Gilles Caulier.
Committed on 03/01/2021 at 13:55.
Pushed by cgilles into branch 'master'.

reencode SVG icon with last Inkscape codec

M  +27   -5    project/bundles/macports/data/digikam.svg
M  +27   -5    project/bundles/macports/data/showfoto.svg

https://invent.kde.org/graphics/digikam/commit/defae795563b94931e0da70a434dff9f162400a5
Comment 15 caulier.gilles 2021-01-03 13:59:56 UTC
Hackintosh HD,

I think the problem with low resolution digiKam icon is due to the 32x32 default image size encoded in XML of SVG contents.

I check with breeze icons set from KF5 frameworks, and SVG image have an higher resolution defined in XML. I don't know how to fix this with Inkscape. editing XML manually break image rendering.

Gilles Caulier
Comment 16 Hackintosh HD 2021-01-03 22:46:07 UTC
(In reply to caulier.gilles from comment #15)

Thank you for the explanations, Gilles, I'm not sure if I understand the mechanism how both the digiKam and showfoto SVG resources for the applications' icons are incorporated into the applications yet.

You've listed the location of the SVG files within the repository above, and if I open them in a vector graphics editor like Serif's Affinity Designer, their image properties are indeed displayed as 32 x 32 pixels. As we're dealing with a vector file format here, I could fix that to macOS' maximum icon size of 1024 x 1024 pixels and attach the resulting SVG file here, but again, I assume this may be thought too simple.
Comment 17 Hackintosh HD 2021-01-03 22:47:42 UTC
Created attachment 134523 [details]
digikam.svg

Test with document properties = 1024 x 1024 px
Comment 18 caulier.gilles 2021-01-03 23:11:31 UTC
1024 x 1024 is too much. 256 x 256 must be enough as size properties.

How did you edit the SVG file exactly ? With Inkscape ?

Gilles Caulier
Comment 19 Hackintosh HD 2021-01-04 10:11:42 UTC
(In reply to caulier.gilles from comment #18)

Hi Gilles,

I chose 1024 x 1024 px after checking https://developer.apple.com/design/human-interface-guidelines/macos/icons-and-images/app-icon, which states that macOS applications should contain icons in a size of - quote - "512x512 pt (512x512 px @1x, 1024x1024 px @2x)". So I'd assume 256 x 256 px is not enough for some macOS icon occurrences (Finder object view set to maximum icon size etc. pp.).

I've adjusted the SVG icon px size with Serif's Affinity Designer (I've purchased a license, but a free evaluation license can be obtained here: https://store.serif.com/get/designer/trial/mac/ or /win/).

In Inkscape, you would probably first transform the lens object to 1024 x 1024 px, then enlarge the page size to 1024 x 1024 px and then center the lens object on it, finally save it in SVG format again. I could apply these steps also in Inkscape to both digikam.svg and showfoto.svg and provide resized versions if you want me to.
Comment 20 caulier.gilles 2021-01-04 10:15:30 UTC
yes please, if you can process digikam and showfoto SVG files, it will be nice.

best 

Gilles Caulier
Comment 21 Hackintosh HD 2021-01-04 12:21:04 UTC
Created attachment 134533 [details]
archive with resized SVG app icons

digikam-showfoto-svgs.zip containing:

- digikam_1024_x_1024_px.svg (digiKam app icon with 1024 x 1024 px document properties)
- digikam_512_x_512_px.svg (digiKam app icon with 512 x 512 px document properties)
- digikam.svg (original source file with 32 x 32 px document properties)
- showfoto_1024_x_1024_px.svg (showFoto app icon with 1024 x 1024 px document properties)
- showfoto_512_x_512_px.svg (showFoto app icon with 512 x 512 px document properties)
- showfoto.svg (original source file with 32 x 32 px document properties)
Comment 22 Hackintosh HD 2021-01-04 12:24:35 UTC
(In reply to caulier.gilles from comment #20)

Salut Gilles,

voilà un archive ZIP avec au moins deux versions en 1024 px et en 512 px pour chaque application crées dans Inkscape.
Comment 23 caulier.gilles 2021-01-04 15:13:48 UTC
Git commit 69ca421eec4879cda3ed5d1288474469d0e9b325 by Gilles Caulier.
Committed on 04/01/2021 at 15:12.
Pushed by cgilles into branch 'master'.

Update digikam and Showfoto svg icons with 10.24x1024 property sizes for macOS

M  +102  -74   project/bundles/macports/data/digikam.svg
M  +120  -92   project/bundles/macports/data/showfoto.svg

https://invent.kde.org/graphics/digikam/commit/69ca421eec4879cda3ed5d1288474469d0e9b325
Comment 24 caulier.gilles 2021-01-04 17:21:38 UTC
Done. 

New pre-release 7.2.0 PKG bundles are uploaded at usual place and ready to test.

https://files.kde.org/digikam/

Gilles Caulier
Comment 25 Hackintosh HD 2021-01-04 20:42:30 UTC
I've tested https://files.kde.org/digikam/digiKam-7.2.0-rc-20210104T180304-MacOS-x86-64.pkg and unfortunately there's no change at all in the app icons' dock appearance, i.e. the final icons are still heavily pixelated.
Comment 26 caulier.gilles 2021-01-05 06:54:26 UTC
Git commit 7d2b74ef2d2ec45163d5f81f3887a59dd230091a by Gilles Caulier.
Committed on 05/01/2021 at 06:53.
Pushed by cgilles into branch 'master'.

missing to patch breeze dark icons set

M  +3    -1    project/bundles/macports/03-build-digikam.sh

https://invent.kde.org/graphics/digikam/commit/7d2b74ef2d2ec45163d5f81f3887a59dd230091a
Comment 27 Hackintosh HD 2021-01-05 08:18:19 UTC
I've just tested https://files.kde.org/digikam/digiKam-7.2.0-rc-20210105T085952-MacOS-x86-64.pkg. Unfortunately, there's no improvement for digiKam's macOS dock icon, it's still heavily pixelated after changing from the initial icon version obviously taken from the .icns resource file to the one generated from the SVG file.

This time, however, it is visible that digiKam's icon was regenerated, because the resulting macOS dock icon has now a small rendering artefact in the top left corner. I assume that was created when the icon was rendered from the SVG file). I'll attach a screenshot to better illustrate the current state of things.

I honestly don't know what else we could try to achieve a proper macOS dock icon display for digiKam. I doesn't seem to be the picture resources, so it's maybe the way the different icon sizes are rendered from the SVG file when digiKam is compiled? Is there maybe an application that uses a similar way to include icon resources that we could use for a comparision?
Comment 28 Hackintosh HD 2021-01-05 08:21:31 UTC
Created attachment 134563 [details]
20200105_digiKam_macOS_dock_icon_after_launch_with_artefacts_in_top_left_corner.png

20200105_digiKam_macOS_dock_icon_after_launch_with_artefacts_in_top_left_corner.png
Comment 29 caulier.gilles 2021-01-05 08:27:50 UTC
Comment on attachment 134563 [details]
20200105_digiKam_macOS_dock_icon_after_launch_with_artefacts_in_top_left_corner.png

yes, i see, i'm lost with this technical dysfunction...

Gilles
Comment 30 caulier.gilles 2021-01-05 08:47:09 UTC
What's i'm sure; the way to encode SVG icon has a real influence to the macOS taskbar icon rendering. So, perhaps something going wrong while trying to regerate the SVG icon with 1024x1024 size property.

Look how SVG icon are generated with breeze theme, used with all KDE applications (and digiKam under macOS):

https://invent.kde.org/frameworks/breeze-icons/-/tree/master/icons/apps/64

Here the max icon size is 64x64. In Breeze where we can found a light blue version of digiKam icons, size is 48x48:

https://invent.kde.org/frameworks/breeze-icons/-/tree/master/icons/apps/48

What i don't understand: SVG is a vector graphic image, not a raster as PNG. Why we need to specify a size property ? After all, the client application can generate the right size without to lost image quality...

Gilles Caulier
Comment 31 caulier.gilles 2021-01-06 09:59:13 UTC
Ok, i found the solution : drop digikam/showfoto svg icons in breeze-icons KF5 components.

In fact under macOS, the executable have already a high resolution icons embedded. No need extra application icons from themes when application start to load breeze icons-set.

It work fine here. I will patch git repository and close this file as resolved.

To "Hackintosh HD": thanks for your support.

Gilles Caulier
Comment 32 caulier.gilles 2021-01-06 10:00:44 UTC
Git commit f3460af8478a391aff504de1984b52717f67d55f by Gilles Caulier.
Committed on 06/01/2021 at 09:59.
Pushed by cgilles into branch 'master'.

add patch to drop digikam and showfoto SVG icons from breeze.
FIXED-IN: 7.2.0

M  +2    -1    NEWS
M  +1    -1    project/bundles/3rdparty/ext_kf5_frameworks/CMakeLists.txt
A  +192  -0    project/bundles/3rdparty/ext_kf5_frameworks/breeze-icons-drop-svg.patch
M  +0    -6    project/bundles/macports/03-build-digikam.sh
D  +0    -746  project/bundles/macports/data/digikam.svg
D  +0    -732  project/bundles/macports/data/showfoto.svg

https://invent.kde.org/graphics/digikam/commit/f3460af8478a391aff504de1984b52717f67d55f
Comment 33 caulier.gilles 2021-01-06 12:38:19 UTC
Git commit c7986dc85f086731e534ff3c9458237c1443a488 by Gilles Caulier.
Committed on 06/01/2021 at 12:36.
Pushed by cgilles into branch 'master'.

Embed hicolor icons-setin maOS bundle. Like this all customized icons from digiKam will be available in GUI. This include all icons from plugins.

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

https://invent.kde.org/graphics/digikam/commit/c7986dc85f086731e534ff3c9458237c1443a488
Comment 34 Hackintosh HD 2021-01-06 15:34:19 UTC
Great! I can confirm today's macOS build https://files.kde.org/digikam/digiKam-7.2.0-rc-20210106T133431-MacOS-x86-64.pkg fixes the problem, the hi-res icons from the .icns resources are now permanently used in the macOS dock.

Thank you very much for all the research that you've put into fixing this problem (these "cosmetic" issues may seem minor, but IMHO they have a high impact on how "native" an application feels under a given OS. I'll probably now try to go through https://l10n.kde.org/docs/translation-howto/ on the weekend to perhaps add the partly missing German localisation to the digikam and Help Finder menus).
Comment 35 caulier.gilles 2021-01-06 15:57:12 UTC
Hackintosh HD,

Thanks. Yes, i would to make the macOS bundle perfect, step by step...

The next stage where i'm currently working is a file common to Windows and MacOS : provide a way to update the installer through main menu.

See this file: https://bugs.kde.org/show_bug.cgi?id=426997

The first part is implemented : check for new release available. Next stage is to download installer and run it. Downloading is implemented but not the instal stage.

In fact i want something similar to Clementine or VLC under macOS...

Gilles Caulier
Comment 36 Hackintosh HD 2021-01-06 17:02:51 UTC
That sounds promising, I really like your approach of "polishing" the macOS release continuously bit by bit! :)

An auto-update option is definitely something I would have proposed myself as a feature, so possible further comments on that over in bug #426997.