Comment 15 for bug 1804954

Revision history for this message
Andrew Hayzen (ahayzen) wrote : Re: Themes work in Xorg but not Wayland sessions - when using Communitheme snap sessions

OK after much discussion with flatpak developers and testing things in VMs, we have found the reason this happens on wayland only !

Quote from TingPing, "dconf supports distros installing override files into the system, then when queried dconf will look at user setting, then fallback to distro setting, then fallback to default setting. In a sandbox we can ask dconf for the user setting but we don't have disk access to the override files".

So what this means is that on wayland the flatpak can't read the default overrides from the session (eg Ubuntu choosing Ambiance and Minimise, Maximise, Close) as it doesn't have permission to read the system files only user ones. (this doesn't affect X11 sessions as gtk reads from xsettings instead).

This will be solved when the settings portal [0] is used in xdg-desktop-portal, as that runs on the host outside of the sandbox it is able to read the necessary files.

For now the workaround is to install gnome-tweaks, change your theme to something else and then back to Ambiance. Also for the window controls change one of them from true to false to true. This will then write user settings to dconf which the flatpak's can then read.

As this will be solved in the next version of xdg-deskop-portal, I will close this bug for the flatpak package and open against xdg-desktop-portal.

0 - https://github.com/flatpak/xdg-desktop-portal/pull/245