Bug 397423 - Add build option to change default ICC profiles path
Summary: Add build option to change default ICC profiles path
Status: RESOLVED DOWNSTREAM
Alias: None
Product: krita
Classification: Applications
Component: General (show other bugs)
Version: 4.1.1
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: Krita Bugs
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-08-13 15:49 UTC by Peter Eszlari
Modified: 2018-08-23 14:02 UTC (History)
2 users (show)

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Peter Eszlari 2018-08-13 15:49:41 UTC
When running Krita under flatpak, the standard ICC profiles path "/usr/share/color/icc" is not visible, but is actually accessible as "/run/host/usr/share/color/icc".

Gimp solved this by adding a compile time option for specifying this path:
https://gitlab.gnome.org/GNOME/gimp/commit/6c9ba16e114d996f75f564c2c4aceca0d105f304

original bug report: https://github.com/flathub/org.kde.krita/issues/5
Comment 1 Halla Rempt 2018-08-13 17:49:14 UTC
I guess we can just add that to our list of places where we look. It feels a bit like a kludge, though.
Comment 2 Halla Rempt 2018-08-13 17:54:30 UTC
Ah, that's what I thought. But all of this is dynamic in Krita, and depends on the the values of the XDG variables. If XDG_DATA_DIRS includes /run/host/usr then the profiles will be found, so we actually only need a way to set that before starting Krita. Does flatpak support that?
Comment 3 Peter Eszlari 2018-08-13 19:06:24 UTC
Actually, I'm not certain what the original reporter's problem is. When I go to

"Settings > Configure Krita > Color Management > Display > Add new color profile"

in a freshly installed Krita (no configs) running under flatpak, the file dialog opens in "/usr/share/color/icc" (host), as one would expect.

(The flatpak of Krita has the option --filesystem=host set, so it gets the same read/write access to the host, like a regular user.)

But if you opened another file (e.g. regular picture) before, the last location is remembered and maybe the problem is, that user might have trouble finding the location of the color profiles. So the solution might be to always open that path in there color management settings, instead of the last location.
Comment 4 alexb3d 2018-08-18 22:02:10 UTC
There is a confusion, several actually. I do not understand why there are github and bugs.kde. I did not open this article, this confuses me...

The original problem was that Krita (Flatpak) does not have access to the ICC profiles `/usr/share/color/icc`. To calibrate my Hardware and my Software I need to have access to the profiles. This is understood, I suppose.

Krita has no problem. Flatpak has no problem.

The problem is "communicational". It took me a long time to learn that Flatpak accesses the profiles in this directory  `/run/host/usr/share/color/icc/`.
Comment 5 Halla Rempt 2018-08-19 07:27:46 UTC
"I do not understand why there are github and bugs.kde.org"

The repository on github is a mirror. It exists because other people thought it would be a good idea for there to be a mirror on github of all KDE projects. I don't know why, it only causes confusion.

I do think it's a flatpak problem if system resources cannot be loaded; flatpak ought to be able to read from usr/share. Though, if colord is running, Krita will get your system profiles automatically (unless flatpak also makes it impossible to communicate with dbus to system demons -- I don't know about that.)

In any case, this clearly isn't a bug in Krita. If the XDG variables are set correctly, Krita will find its own default profiles, and there's much more that we can code.
Comment 6 Peter Eszlari 2018-08-20 22:06:51 UTC
> Though, if colord is running, Krita will get your system profiles automatically (unless flatpak also makes it impossible to communicate with dbus to system demons -- I don't know about that.)

How can I test this? Flatpak apps can talk to dbus, I just need to set the right permissions.
Comment 7 Halla Rempt 2018-08-21 06:29:50 UTC
Depends on your desktop: on Gnome it's built-in, on Plasma you need to install the colord kcm. Then you can just select a display profile in the setttings application and Krita should see it automatically.
Comment 8 alexb3d 2018-08-23 13:52:32 UTC
(In reply to Boudewijn Rempt from comment #7)
> Depends on your desktop: on Gnome it's built-in, on Plasma you need to
> install the colord kcm. Then you can just select a display profile in the
> setttings application and Krita should see it automatically.

To calibrate it is also necessary to select the CMYK profile.
Comment 9 alexb3d 2018-08-23 14:02:45 UTC
(In reply to Boudewijn Rempt from comment #5)
> "I do not understand why there are github and bugs.kde.org"

Every time there is more confusion due to lack of information... Github is "only for errors related to flatpak". 


> In any case, this clearly isn't a bug in Krita. If the XDG variables are set
> correctly, Krita will find its own default profiles, and there's much more
> that we can code.

I already said it, it's not a mistake by Krita, nor is it a Flatpak error.

The error is that nobody reports that the access address to the ICC profiles has changed.

It seems that very few people who use FOSS have the need to calibrate the monitor.