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

From: Jaft <[email-masked]>
Date: Sun, 28 Nov 2021 12:52:01 +0000 (UTC)

Thanks so much, Liliana, for the response; this really helpful and enlightening in terms of understanding Guix better (I think I tend to learn more intuitively from examples than anything).

> On Friday, November 26, 2021, 04:45:19 PM UTC, Liliana Marie Prikler <[email-masked]> wrote: >
 >
 > 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.

That makes sense; I definitely did not have anything dconf-related running. In case anyone else does stumble upon this E-mail thread and is curious, you can also circumvent running dconf (that was never a goal, for me; I just stumbled upon it) with xfconf; running my original setup with that installed actually caused settings to be saved perfectly.

> > 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.
This is where I'm still running into issues; I don't know if xfconf has any effect here (I haven't tested how things go without it installed) but I tried the Gnome setup that you demonstrated and, likewise, I was able to update and change (via gnome-tweaks) the icons. Out of curiosity, I tried XFCE as well (just the full setup) by adding to my services: (service xfce-desktop-service-type (xfce-desktop-configuration (xfce xfce))).

I also installed the hicolor and Adwaita icons as I read that Thunar (or maybe GTK app.s in general?) don't work at all if those aren't present (and, with mere light observance, that does seem to be true); logging into the XFCE desktop, it didn't seem like icons were working as the folders were all clearly Adwaita but, at some point, I realized that some of the icons were changing (namely, the files): it just wasn't changing all of them.

I took a look at my original setup, as well, and found the same result. I've attached some pictures of icon selection from within the XFCE desktop and it shows that the folders for a whole host of themes keep trying to use the Adwaita folders; not all of them but most.
(If I understood correctly,) you were saying that a similar setup to the Gnome example you gave could work with XFCE but running the full, plain XFCE (assuming I did that right) still resulted in this weird thing with the icons so I'm assuming there's something larger here, going on? It definitely works right, on Gnome, and I'm able to see all icons of the picked icon theme get loaded correctly but it seems, to me, that's not the case with XFCE.

Tangential but, bug-wise, unrelated: I mentioned rofi not showing application icons. Looking at the errors it produces, when run, I'm getting stuff like:
(process:30101): Helpers.IconFetcher-WARNING **: 06:23:32.467: Failed to load image: Couldn’t recognize the image file format for file “/run/current-system/profile/share/icons/Papirus-Light/96x96/apps/org.xfce.catfish.svg”

I tried searching for if anyone had run into a similar problem and found gdk-pixbuf2 2.32.1-1 with librsvg 2.40.10-1: "Couldn't recognize the image file format for file" error for SVG files · Issue #818 · msys2/MINGW-packages and [BUG] SVG rendering failed on rofi version 1.6.1 · Discussion #1235 · davatorium/rofi but the first didn't seem particularly related (beyond referencing the library, I think, rofi uses and, even then, Guix is on a later version, by now) and, in the second link, someone refers to Guix to reference how things should be setup so that didn't really bring much enlightenment, either.
I tried running rofi with G_MESSAGES_DEBUG=Helpers.IconFetcher, to get debugging messages and got:
Helpers.IconFetcher-INFO: 06:38:06.245: Add image extension: ani
Helpers.IconFetcher-INFO: 06:38:06.245: Add image extension: bmp
Helpers.IconFetcher-INFO: 06:38:06.245: Add image extension: gif
Helpers.IconFetcher-INFO: 06:38:06.245: Add image extension: icns
Helpers.IconFetcher-INFO: 06:38:06.245: Add image extension: ico
Helpers.IconFetcher-INFO: 06:38:06.245: Add image extension: cur
Helpers.IconFetcher-INFO: 06:38:06.245: Add image extension: jpeg
Helpers.IconFetcher-INFO: 06:38:06.245: Add image extension: jpe
Helpers.IconFetcher-INFO: 06:38:06.245: Add image extension: jpg
Helpers.IconFetcher-INFO: 06:38:06.245: Add image extension: png
Helpers.IconFetcher-INFO: 06:38:06.245: Add image extension: pnm
Helpers.IconFetcher-INFO: 06:38:06.245: Add image extension: pbm
Helpers.IconFetcher-INFO: 06:38:06.245: Add image extension: pgm
Helpers.IconFetcher-INFO: 06:38:06.245: Add image extension: ppm
Helpers.IconFetcher-INFO: 06:38:06.245: Add image extension: qtif
Helpers.IconFetcher-INFO: 06:38:06.245: Add image extension: qif
Helpers.IconFetcher-INFO: 06:38:06.245: Add image extension: tga
Helpers.IconFetcher-INFO: 06:38:06.245: Add image extension: targa
Helpers.IconFetcher-INFO: 06:38:06.245: Add image extension: tiff
Helpers.IconFetcher-INFO: 06:38:06.245: Add image extension: tif
Helpers.IconFetcher-INFO: 06:38:06.245: Add image extension: xbm
Helpers.IconFetcher-INFO: 06:38:06.245: Add image extension: xpm
(process:7244): Helpers.IconFetcher-DEBUG: 06:38:06.268: Query: preferences-desktop-theme(80)
(process:7244): Helpers.IconFetcher-DEBUG: 06:38:06.269: starting up icon fetching thread.
(process:7244): Helpers.IconFetcher-DEBUG: 06:38:06.270: Query: org.xfce.catfish(80)
(process:7244): Helpers.IconFetcher-DEBUG: 06:38:06.270: starting up icon fetching thread.
(process:7244): Helpers.IconFetcher-DEBUG: 06:38:06.271: Query: icecat(80)
(process:7244): Helpers.IconFetcher-DEBUG: 06:38:06.271: starting up icon fetching thread.
(process:7244): Helpers.IconFetcher-DEBUG: 06:38:06.271: Query: (80)
(process:7244): Helpers.IconFetcher-DEBUG: 06:38:06.271: Query: org.xfce.powermanager(80)
(process:7244): Helpers.IconFetcher-DEBUG: 06:38:06.272: Query: chromium(80)
(process:7244): Helpers.IconFetcher-DEBUG: 06:38:06.272: starting up icon fetching thread.
(process:7244): Helpers.IconFetcher-DEBUG: 06:38:06.272: found icon preferences-desktop-theme(80x80): /run/current-system/profile/share/icons/Papirus-Light/96x96/apps/preferences-desktop-theme.svg

(process:7244): Helpers.IconFetcher-WARNING **: 06:38:06.272: Failed to load image: Couldn’t recognize the image file format for file “/run/current-system/profile/share/icons/Papirus-Light/96x96/apps/preferences-desktop-theme.svg”
(process:7244): Helpers.IconFetcher-DEBUG: 06:38:06.272: starting up icon fetching thread.
(process:7244): Helpers.IconFetcher-DEBUG: 06:38:06.275: found icon org.xfce.catfish(80x80): /run/current-system/profile/share/icons/Papirus-Light/96x96/apps/org.xfce.catfish.svg

SVGs don't seem to be loaded as an extension, though librsvg is a dependency of rofi (I assume it's related to SVG handling for when rofi is running).

| 
| 
| 
|  |  |

 |

 |
| 
|  | 
[BUG] SVG rendering failed on rofi version 1.6.1 · Discussion #1235 · da...

SVG rendering failed on rofi version 1.6.1. Fallback the version to 1.5.4 and rendering works normally. Version ...
 |

 |

 |

| 
| 
| 
|  |  |

 |

 |
| 
|  | 
gdk-pixbuf2 2.32.1-1 with librsvg 2.40.10-1: "Couldn't recognize the im...

When MyPaint tries to load an icon for its initial runtime test, I get: ERROR: gui.application: Missing icon 'my...
 |

 |

 |

>
> 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