Subject: Re: Various Program Settings not Saving and Icons not Recognized

From: Liliana Marie Prikler <[email-masked]>
Date: Fri, 26 Nov 2021 17:45:17 +0100

Hi Jaft,

> I'm not sure if it's stemming from a bug or I've just missed a package
> or service I should've included but I find there're several programs I
> have installed which aren't saving their settings.
> Catfish and thunar are two easy examples while gnome-calendar, arandr,
> and viewnior do save their preferences, when modified, just fine. In a
> sort of weird middle-ground, lxappearance will save, say, an icon
> change (I can check .config/gtk-3.0/settings.ini and see that the icons
> have been updated) but, upon opening it, again, I find that it says the
> previous icon set is what's been chosen (this doesn't affect the
> settings.ini file, though; I would need to actually reselect the old
> icon set and hit Apply for that to get updated, once more).
Many GNOME-adjacent/GTK-based applications use GSettings to store their
configuration and are backed by a dconf store.  You can use dconf-editor
to inspect/change their values manually.
Communication between your application and the dconf store is provided
by the dconf-service, which itself uses DBus.  My guess is that either
dbus is not started at all or the dconf-service is not running.

> In a sort of similar vein, icons can't seem to be recognized for
> particular programs; thunar and gnome-screenshot are easy examples and
> I've attached an image indicating what I mean. Catfish is fine but I
> think it's falling back to the HighContrast iconset (interestingly, the
> only iconset that seems to work when I set it in lxappearance). rofi,
> even, isn't able to provide any application icons when using drun mode.
> lxappearance and nitrogren are two I've noticed using the icons I set
> (Papirus-Light, mostly).
Most GTK-based applications again use the GTK icon theme set by your
window manager (usually) using GSettings/dconf.  Most applications also
typically fall back to hicolor-icon-theme, but that appears to be
lacking from your system definition.  Note that it's *not* included in
gnome-themes-standard.

You appear to be using quite anemic versions of the GNOME/XFCE desktop
environments overall.  While yes, it is a bug that those applications
typically fail to deliver icons outside of their respective
environments, it is a fact we have to deal with.  An alternative
"solution" to this problem would require us to propagate stuff like
hicolor-icon-theme from each and every one of them, resulting in
conflicts if you want to bump just a single package.

I tested around a little and with the following I can at least see
the icons of nautilus and gnome-settings-daemon, even when using
e.g. ratpoison as my window manager
--8<---------------cut here---------------start------------->8---
(define anemic-gnome
  (package
   (inherit gnome)
   (propagated-inputs
    `(;; GNOME-Core-Shell
      ("adwaita-icon-theme" ,adwaita-icon-theme)
      ("gnome-keyring" ,gnome-keyring)
      ("gnome-session" ,gnome-session)
      ("gnome-control-center" ,gnome-control-center)
      ("gnome-settings-daemon" ,gnome-settings-daemon)
      ("gnome-system-monitor" ,gnome-system-monitor)
      ("gnome-shell" ,gnome-shell)
      ("gvfs" ,gvfs)
      ("mutter" ,mutter)
      ("gnome-calculator" ,gnome-calculator)
      ("gnome-font-viewer" ,gnome-font-viewer)
      ("gnome-screenshot" ,gnome-screenshot)
      ("gnome-terminal" ,gnome-terminal)
      ("nautilus" ,nautilus)
      ;; Others
      ("hicolor-icon-theme" ,hicolor-icon-theme)
      ("font-abattis-cantarell" ,font-abattis-cantarell)
      ("gnome-themes-standard" ,gnome-themes-standard)))))
--8<---------------cut here---------------end--------------->8---
using the following values of services while either leaving packages
as %base-packages or simply consing some other window manager to it.
--8<---------------cut here---------------start------------->8---
 (services
   (cons*
    (service gnome-desktop-service-type
             (gnome-desktop-configuration (gnome anemic-gnome)))
    (service slim-service-type
             (slim-configuration (display ":0") (vt "vt7")
                                 (xorg-configuration
                                  (xorg-configuration
                                   (keyboard-layout keyboard-layout)))))
    (modify-services %desktop-services
                     (delete gdm-service-type))))
--8<---------------cut here---------------end--------------->8---

The same can surely be done for xfce-desktop-service as well.  You are
free to cut even more inputs, but be warned that at some point
gnome-desktop-service starts raising errors when you try to build your
system.  It shouldn't do that when merely missing icons, though.

Cheers